Package totalcross.crypto.cipher
Class RSAPrivateKey
- java.lang.Object
-
- totalcross.crypto.cipher.Key
-
- totalcross.crypto.cipher.RSAPrivateKey
-
public class RSAPrivateKey extends Key
This class implements the RSA cryptographic cipher private key.
-
-
Constructor Summary
Constructors Constructor Description RSAPrivateKey(byte[] e, byte[] d, byte[] n)Creates a new RSAPublicKey object, given the public and private exponents and the modulus.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]getModulus()Returns a copy of the byte array containing the modulus.byte[]getPrivateExponent()Returns a copy of the byte array containing the private exponent.byte[]getPublicExponent()Returns a copy of the byte array containing the public exponent.
-
-
-
Constructor Detail
-
RSAPrivateKey
public RSAPrivateKey(byte[] e, byte[] d, byte[] n)Creates a new RSAPublicKey object, given the public and private exponents and the modulus.- Parameters:
e- A byte array containing the public exponent.d- A byte array containing the private exponent.n- A byte array containing the modulus.
-
-
Method Detail
-
getModulus
public byte[] getModulus()
Returns a copy of the byte array containing the modulus.- Returns:
- A copy of the byte array containing the modulus.
-
getPublicExponent
public byte[] getPublicExponent()
Returns a copy of the byte array containing the public exponent.- Returns:
- A copy of the byte array containing the public exponent.
-
getPrivateExponent
public byte[] getPrivateExponent()
Returns a copy of the byte array containing the private exponent.- Returns:
- A copy of the byte array containing the private exponent.
-
-