Class KeyMaterialUtils
java.lang.Object
com.kingsrook.qqq.backend.core.crypto.KeyMaterialUtils
Shared key handling: validating key ids and decoding base64 key text. Used
by the key providers and by RefreshTokenCipher. Messages name the setting,
never the key.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]decodeBase64Key(String base64Key, String settingName, int expectedLengthBytes) Decode base64 key text, requiring the given length in bytes.static voidvalidateKeyId(String keyId, String settingName) Make sure a key id (or version) can be embedded in a stored format.
-
Field Details
-
AES_256_KEY_LENGTH_BYTES
public static final int AES_256_KEY_LENGTH_BYTES- See Also:
-
-
Method Details
-
validateKeyId
Make sure a key id (or version) can be embedded in a stored format.- Throws:
QException
-
decodeBase64Key
public static byte[] decodeBase64Key(String base64Key, String settingName, int expectedLengthBytes) throws QException Decode base64 key text, requiring the given length in bytes.- Throws:
QException
-