Package com.kheops.util
Class RsaClientCipher
java.lang.Object
com.kheops.util.RsaClientCipher
- All Implemented Interfaces:
EncryptionCipher
-
Constructor Summary
ConstructorsConstructorDescriptionRsaClientCipher(byte[] encodedPublicKey) Creates a new cipher client using the specified RSA public key. -
Method Summary
-
Constructor Details
-
RsaClientCipher
public RsaClientCipher(byte[] encodedPublicKey) Creates a new cipher client using the specified RSA public key.- Parameters:
encodedPublicKey- a RSA public key.
-
-
Method Details
-
init
Initializes the cipher instance.- Specified by:
initin interfaceEncryptionCipher- Throws:
Exception
-
encrypt
Encrypts the specified data.- Specified by:
encryptin interfaceEncryptionCipher- Parameters:
data- the data to encrypt.- Returns:
- a new byte array that contains encrypted data.
- Throws:
GeneralSecurityException
-