Class SecurityTestUtils (1.43.0)

public final class SecurityTestUtils

Beta
Utilities and constants related to testing the library util package.

Inheritance

java.lang.Object > SecurityTestUtils

Static Methods

newEncodedRsaPrivateKeyBytes()

public static byte[] newEncodedRsaPrivateKeyBytes()

Returns a new copy of a sample encoded RSA private key that matches #newEncodedRsaPublicKeyBytes().

Returns
TypeDescription
byte[]

newEncodedRsaPublicKeyBytes()

public static byte[] newEncodedRsaPublicKeyBytes()

Returns a new copy of a sample encoded public key that matches #newEncodedRsaPrivateKeyBytes().

Returns
TypeDescription
byte[]

newRsaPrivateKey()

public static RSAPrivateKey newRsaPrivateKey()

Returns a new sample RSA private key that matches #newRsaPublicKey().

Returns
TypeDescription
RSAPrivateKey
Exceptions
TypeDescription
GeneralSecurityException

newRsaPublicKey()

public static RSAPublicKey newRsaPublicKey()

Returns a new sample RSA public key that matches #newRsaPrivateKey().

Returns
TypeDescription
RSAPublicKey
Exceptions
TypeDescription
GeneralSecurityException