|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Objectorg.jasypt.util.numeric.StrongIntegerNumberEncryptor
public final class StrongIntegerNumberEncryptor
Utility class for easily performing normal-strength encryption of BigInteger objects.
This class internally holds a StandardPBEBigIntegerEncryptor
configured this way:
The required steps to use it are:
setPassword(String) or
setPasswordCharArray(char[])).encrypt(BigInteger) or
decrypt(BigInteger) operations.This class is thread-safe.
| Constructor Summary | |
|---|---|
StrongIntegerNumberEncryptor()
Creates a new instance of StrongIntegerNumberEncryptor. |
|
| Method Summary | |
|---|---|
java.math.BigInteger |
decrypt(java.math.BigInteger encryptedNumber)
Decrypts a number. |
java.math.BigInteger |
encrypt(java.math.BigInteger number)
Encrypts a number |
void |
setPassword(String password)
Sets a password. |
void |
setPasswordCharArray(char[] password)
Sets a password, as a char[]. |
| Methods inherited from class Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StrongIntegerNumberEncryptor()
| Method Detail |
|---|
public void setPassword(String password)
password - the password to be set.public void setPasswordCharArray(char[] password)
password - the password to be set.public java.math.BigInteger encrypt(java.math.BigInteger number)
encrypt in interface IntegerNumberEncryptornumber - the number to be encrypted.StandardPBEBigIntegerEncryptor.encrypt(BigInteger)public java.math.BigInteger decrypt(java.math.BigInteger encryptedNumber)
decrypt in interface IntegerNumberEncryptorencryptedNumber - the number to be decrypted.StandardPBEBigIntegerEncryptor.decrypt(BigInteger)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||