12 Mart 2018 Pazartesi

SpringSecurity Encryptors Sınıfı

text metodu
Şöyle yaparız.
final String password = "A private password that you need to keep secret.";  
final String salt = KeyGenerators.string().generateKey();
TextEncryptor encryptor = Encryptors.text(password, salt);

String cipherText = encryptor.encrypt(textToEncrypt);

String decryptedText = encryptor.decrypt(cipherText);

Hiç yorum yok:

Yorum Gönder