Package org.bouncycastle.bcpg.sig
Class PreferredAEADCiphersuites
java.lang.Object
org.bouncycastle.bcpg.SignatureSubpacket
org.bouncycastle.bcpg.sig.PreferredAlgorithms
org.bouncycastle.bcpg.sig.PreferredAEADCiphersuites
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAlgorithm combination of aSymmetricKeyAlgorithmTagsand aAEADAlgorithmTags. -
Field Summary
Fields inherited from class org.bouncycastle.bcpg.SignatureSubpacket
data -
Constructor Summary
ConstructorsConstructorDescriptionPreferredAEADCiphersuites(boolean critical, boolean isLongLength, byte[] data) Create a new PreferredAEADAlgorithms signature subpacket from raw data.PreferredAEADCiphersuites(boolean critical, PreferredAEADCiphersuites.Combination[] combinations) Create a new PreferredAEADAlgorithm signature subpacket. -
Method Summary
Modifier and TypeMethodDescriptionReturns AEAD algorithm preferences, including implicitly supported algorithm combinations.Return AEAD algorithm preferences.booleanisSupported(PreferredAEADCiphersuites.Combination combination) Return true, if the given algorithm combination is supported (explicitly or implicitly).Methods inherited from class org.bouncycastle.bcpg.sig.PreferredAlgorithms
getPreferencesMethods inherited from class org.bouncycastle.bcpg.SignatureSubpacket
encode, equals, getData, getType, hashCode, isCritical, isLongLength
-
Constructor Details
-
PreferredAEADCiphersuites
public PreferredAEADCiphersuites(boolean critical, boolean isLongLength, byte[] data) Create a new PreferredAEADAlgorithms signature subpacket from raw data.- Parameters:
critical- whether the subpacket is criticalisLongLength- whether the subpacket uses long length encodingdata- raw data
-
PreferredAEADCiphersuites
public PreferredAEADCiphersuites(boolean critical, PreferredAEADCiphersuites.Combination[] combinations) Create a new PreferredAEADAlgorithm signature subpacket.- Parameters:
critical- whether the subpacket is criticalcombinations- list of combinations, with the most preferred option first
-
-
Method Details
-
isSupported
Return true, if the given algorithm combination is supported (explicitly or implicitly).- Parameters:
combination- combination- Returns:
- true, if the combination is supported, false otherwise
-
getRawAlgorithms
Return AEAD algorithm preferences. The most preferred option comes first. This method returns the combinations as they are listed in the packet, possibly excluding implicitly supported combinations.- Returns:
- explicitly supported algorithm combinations
-
getAlgorithms
Returns AEAD algorithm preferences, including implicitly supported algorithm combinations.- Returns:
- all supported algorithm combinations
-