Java Code Examples for org.jasypt.encryption.pbe.StandardPBEStringEncryptor#setPasswordCharArray()

The following examples show how to use org.jasypt.encryption.pbe.StandardPBEStringEncryptor#setPasswordCharArray() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: HibernatePBEStringEncryptor.java    From jasypt with Apache License 2.0 5 votes vote down vote up
/**
 * Sets the password to be used by the internal encryptor (as a char[]), if a specific
 * encryptor has not been set with <tt>setEncryptor(...)</tt>.
 * 
 * @since 1.8
 * @param password the password to be set for the internal encryptor
 */
public void setPasswordCharArray(final char[] password) {
    if (this.encryptorSet) {
        throw new EncryptionInitializationException(
                "An encryptor has been already set: no " +
                "further configuration possible on hibernate wrapper");
    }
    final StandardPBEStringEncryptor standardPBEStringEncryptor =
        (StandardPBEStringEncryptor) this.encryptor;
    standardPBEStringEncryptor.setPasswordCharArray(password);
}
 
Example 2
Source File: HibernatePBEStringEncryptor.java    From jasypt with Apache License 2.0 5 votes vote down vote up
/**
 * Sets the password to be used by the internal encryptor (as a char[]), if a specific
 * encryptor has not been set with <tt>setEncryptor(...)</tt>.
 * 
 * @since 1.8
 * @param password the password to be set for the internal encryptor
 */
public void setPasswordCharArray(final char[] password) {
    if (this.encryptorSet) {
        throw new EncryptionInitializationException(
                "An encryptor has been already set: no " +
                "further configuration possible on hibernate wrapper");
    }
    final StandardPBEStringEncryptor standardPBEStringEncryptor =
        (StandardPBEStringEncryptor) this.encryptor;
    standardPBEStringEncryptor.setPasswordCharArray(password);
}
 
Example 3
Source File: HibernatePBEStringEncryptor.java    From jasypt with Apache License 2.0 5 votes vote down vote up
/**
 * Sets the password to be used by the internal encryptor (as a char[]), if a specific
 * encryptor has not been set with <tt>setEncryptor(...)</tt>.
 * 
 * @since 1.8
 * @param password the password to be set for the internal encryptor
 */
public void setPasswordCharArray(final char[] password) {
    if (this.encryptorSet) {
        throw new EncryptionInitializationException(
                "An encryptor has been already set: no " +
                "further configuration possible on hibernate wrapper");
    }
    final StandardPBEStringEncryptor standardPBEStringEncryptor =
        (StandardPBEStringEncryptor) this.encryptor;
    standardPBEStringEncryptor.setPasswordCharArray(password);
}
 
Example 4
Source File: HibernatePBEStringEncryptor.java    From jasypt with Apache License 2.0 5 votes vote down vote up
/**
 * Sets the password to be used by the internal encryptor (as a char[]), if a specific
 * encryptor has not been set with <tt>setEncryptor(...)</tt>.
 * 
 * @since 1.8
 * @param password the password to be set for the internal encryptor
 */
public void setPasswordCharArray(final char[] password) {
    if (this.encryptorSet) {
        throw new EncryptionInitializationException(
                "An encryptor has been already set: no " +
                "further configuration possible on hibernate wrapper");
    }
    final StandardPBEStringEncryptor standardPBEStringEncryptor =
        (StandardPBEStringEncryptor) this.encryptor;
    standardPBEStringEncryptor.setPasswordCharArray(password);
}