Skip to content

Commit 05cfffd

Browse files
committed
Rename keyrings to match AWS SDK V2 naming conventions.
1 parent fc85f39 commit 05cfffd

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/main/java/software/amazon/encryption/s3/materials/AESKeyring.java renamed to src/main/java/software/amazon/encryption/s3/materials/AesGcmKeyring.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
/**
1414
* AESKeyring will use an AES key to wrap the data key used to encrypt content.
1515
*/
16-
public class AESKeyring implements Keyring {
16+
public class AesGcmKeyring implements Keyring {
1717

1818
private static final String KEY_ALGORITHM = "AES";
1919
private static final String KEY_PROVIDER_ID = "AES/GCM";
@@ -26,7 +26,7 @@ public class AESKeyring implements Keyring {
2626
private final SecureRandom _secureRandom;
2727
private final DataKeyGenerator _dataKeyGenerator;
2828

29-
private AESKeyring(Builder builder) {
29+
private AesGcmKeyring(Builder builder) {
3030
_wrappingKey = builder._wrappingKey;
3131
_secureRandom = builder._secureRandom;
3232
_dataKeyGenerator = builder._dataKeyGenerator;
@@ -139,8 +139,8 @@ public Builder dataKeyGenerator(DataKeyGenerator dataKeyGenerator) {
139139
return this;
140140
}
141141

142-
public AESKeyring build() {
143-
return new AESKeyring(this);
142+
public AesGcmKeyring build() {
143+
return new AesGcmKeyring(this);
144144
}
145145
}
146146
}

src/main/java/software/amazon/encryption/s3/materials/KMSContextKeyring.java renamed to src/main/java/software/amazon/encryption/s3/materials/KmsContextKeyring.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
/**
1818
* AESKeyring will call to KMS to wrap the data key used to encrypt content.
1919
*/
20-
public class KMSContextKeyring implements Keyring {
20+
public class KmsContextKeyring implements Keyring {
2121

2222
private static final String KEY_PROVIDER_ID = "kms+context";
2323

@@ -29,7 +29,7 @@ public class KMSContextKeyring implements Keyring {
2929
private final String _wrappingKeyId;
3030
private final DataKeyGenerator _dataKeyGenerator;
3131

32-
public KMSContextKeyring(Builder builder) {
32+
public KmsContextKeyring(Builder builder) {
3333
_kmsClient = builder._kmsClient;
3434
_wrappingKeyId = builder._wrappingKeyId;
3535
_dataKeyGenerator = builder._dataKeyGenerator;
@@ -135,8 +135,8 @@ public Builder dataKeyGenerator(DataKeyGenerator dataKeyGenerator) {
135135
return this;
136136
}
137137

138-
public KMSContextKeyring build() {
139-
return new KMSContextKeyring(this);
138+
public KmsContextKeyring build() {
139+
return new KmsContextKeyring(this);
140140
}
141141
}
142142
}

0 commit comments

Comments
 (0)