Class CasConfigurationJasyptCipherExecutor

  • All Implemented Interfaces:
    org.apereo.cas.CipherExecutor<java.lang.String,​java.lang.String>

    public class CasConfigurationJasyptCipherExecutor
    extends java.lang.Object
    implements org.apereo.cas.CipherExecutor<java.lang.String,​java.lang.String>
    Since:
    5.1.0
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String ENCRYPTED_VALUE_PREFIX
      Prefix inserted at the beginning of a value to indicate it's encrypted.
      • Fields inherited from interface org.apereo.cas.CipherExecutor

        DEFAULT_CONTENT_ENCRYPTION_ALGORITHM, DEFAULT_STRINGABLE_ENCRYPTION_KEY_SIZE, DEFAULT_STRINGABLE_SIGNING_KEY_SIZE, LOGGER
    • Constructor Summary

      Constructors 
      Constructor Description
      CasConfigurationJasyptCipherExecutor​(org.springframework.core.env.Environment environment)
      Instantiates a new Cas configuration jasypt cipher executor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String decode​(java.lang.String value, java.lang.Object[] parameters)  
      java.lang.String decryptValue​(java.lang.String value)
      Decrypt value string.
      java.lang.String decryptValuePropagateExceptions​(java.lang.String value)
      Decrypt value string.
      java.lang.String encode​(java.lang.String value, java.lang.Object[] parameters)  
      java.lang.String encryptValue​(java.lang.String value)
      Encrypt value string.
      java.lang.String encryptValuePropagateExceptions​(java.lang.String value)
      Encrypt value string (but don't log error, for use in shell).
      java.lang.String getName()  
      void setAlgorithm​(java.lang.String alg)
      Sets algorithm.
      void setKeyObtentionIterations​(java.lang.String iter)
      Sets key obtention iterations.
      void setPassword​(java.lang.String psw)
      Sets password.
      void setProviderName​(java.lang.String pName)
      Sets provider name.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.apereo.cas.CipherExecutor

        decode, decode, encode, isEnabled
    • Field Detail

      • ENCRYPTED_VALUE_PREFIX

        public static final java.lang.String ENCRYPTED_VALUE_PREFIX
        Prefix inserted at the beginning of a value to indicate it's encrypted.
        See Also:
        Constant Field Values
    • Constructor Detail

      • CasConfigurationJasyptCipherExecutor

        public CasConfigurationJasyptCipherExecutor​(org.springframework.core.env.Environment environment)
        Instantiates a new Cas configuration jasypt cipher executor.
        Parameters:
        environment - the environment
    • Method Detail

      • setAlgorithm

        public void setAlgorithm​(java.lang.String alg)
        Sets algorithm.
        Parameters:
        alg - the alg
      • setPassword

        public void setPassword​(java.lang.String psw)
        Sets password.
        Parameters:
        psw - the psw
      • setKeyObtentionIterations

        public void setKeyObtentionIterations​(java.lang.String iter)
        Sets key obtention iterations.
        Parameters:
        iter - the iter
      • setProviderName

        public void setProviderName​(java.lang.String pName)
        Sets provider name.
        Parameters:
        pName - the p name
      • encode

        public java.lang.String encode​(java.lang.String value,
                                       java.lang.Object[] parameters)
        Specified by:
        encode in interface org.apereo.cas.CipherExecutor<java.lang.String,​java.lang.String>
      • decode

        public java.lang.String decode​(java.lang.String value,
                                       java.lang.Object[] parameters)
        Specified by:
        decode in interface org.apereo.cas.CipherExecutor<java.lang.String,​java.lang.String>
      • getName

        public java.lang.String getName()
        Specified by:
        getName in interface org.apereo.cas.CipherExecutor<java.lang.String,​java.lang.String>
      • encryptValue

        public java.lang.String encryptValue​(java.lang.String value)
        Encrypt value string.
        Parameters:
        value - the value
        Returns:
        the string
      • encryptValuePropagateExceptions

        public java.lang.String encryptValuePropagateExceptions​(java.lang.String value)
        Encrypt value string (but don't log error, for use in shell).
        Parameters:
        value - the value
        Returns:
        the string
      • decryptValue

        public java.lang.String decryptValue​(java.lang.String value)
        Decrypt value string.
        Parameters:
        value - the value
        Returns:
        the string
      • decryptValuePropagateExceptions

        public java.lang.String decryptValuePropagateExceptions​(java.lang.String value)
        Decrypt value string. (but don't log error, for use in shell).
        Parameters:
        value - the value
        Returns:
        the string