Class PBECryptoAPI
java.lang.Object
ml.karmaconfigs.api.common.utils.security.data.PBECryptoAPI
Initialize the crypto API
-
Constructor Details
-
PBECryptoAPI
Initialize the crypt API- Parameters:
pwd- the passwordctn- the content
-
-
Method Details
-
generateSALT
public final byte[] generateSALT()Generate a salt token- Returns:
- a sal token
-
encrypt
Encrypt the data- Parameters:
salt- the salt token- Returns:
- the encrypted data
- Throws:
Exception- if something goes wrong
-
decrypt
Decrypt the data- Parameters:
salt- the salt token- Returns:
- the decrypted data
- Throws:
Exception- if something goes wrong
-