org.jasypt.spring31.properties

## Class EncryptablePropertyOverrideConfigurer

- Object
- - org.springframework.core.io.support.PropertiesLoaderSupport
  - - org.springframework.beans.factory.config.PropertyResourceConfigurer
    - - org.springframework.beans.factory.config.PropertyOverrideConfigurer
      - - org.jasypt.spring31.properties.EncryptablePropertyOverrideConfigurer

- All Implemented Interfaces:
    org.springframework.beans.factory.config.BeanFactoryPostProcessor, org.springframework.core.Ordered, org.springframework.core.PriorityOrdered

      public final class EncryptablePropertyOverrideConfigurer
      extends org.springframework.beans.factory.config.PropertyOverrideConfigurer

  Subclass of `org.springframework.beans.factory.config.PropertyOverrideConfigurer` which can make use of a `StringEncryptor` or `TextEncryptor` object to decrypt property values if they are encrypted in the loaded resource locations.

  A value is considered "encrypted" when it appears surrounded by `ENC(...)`, like:

  `my.value=ENC(!"DGAS24FaIO$)`

  Encrypted and unencrypted objects can be combined in the same resources file.

  Since:
    1.9.0
  Author:
    Marcos Muíño García

- - ### Field Summary

    - ### Fields inherited from class org.springframework.beans.factory.config.PropertyOverrideConfigurer

      `DEFAULT_BEAN_NAME_SEPARATOR`

    - ### Fields inherited from class org.springframework.core.io.support.PropertiesLoaderSupport

      `localOverride, localProperties, logger, XML_FILE_EXTENSION`

    - ### Fields inherited from interface org.springframework.core.Ordered

      `HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `EncryptablePropertyOverrideConfigurer(org.jasypt.encryption.StringEncryptor stringEncryptor)` Creates an `EncryptablePropertyOverrideConfigurer` instance which will use the passed `StringEncryptor` object to decrypt encrypted values.
    `EncryptablePropertyOverrideConfigurer(org.jasypt.util.text.TextEncryptor textEncryptor)` Creates an `EncryptablePropertyOverrideConfigurer` instance which will use the passed `TextEncryptor` object to decrypt encrypted values.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected String` | `convertPropertyValue(String originalValue)`

    - ### Methods inherited from class org.springframework.beans.factory.config.PropertyOverrideConfigurer

      `applyPropertyValue, hasPropertyOverridesFor, processKey, processProperties, setBeanNameSeparator, setIgnoreInvalidKeys`

    - ### Methods inherited from class org.springframework.beans.factory.config.PropertyResourceConfigurer

      `convertProperties, convertProperty, getOrder, postProcessBeanFactory, setOrder`

    - ### Methods inherited from class org.springframework.core.io.support.PropertiesLoaderSupport

      `loadProperties, mergeProperties, setFileEncoding, setIgnoreResourceNotFound, setLocalOverride, setLocation, setLocations, setProperties, setPropertiesArray, setPropertiesPersister`

    - ### Methods inherited from class Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### EncryptablePropertyOverrideConfigurer

          public EncryptablePropertyOverrideConfigurer(org.jasypt.encryption.StringEncryptor stringEncryptor)

      Creates an `EncryptablePropertyOverrideConfigurer` instance which will use the passed `StringEncryptor` object to decrypt encrypted values.

      Parameters:
        `stringEncryptor` - the `StringEncryptor` to be used do decrypt values. It can not be null.

    - #### EncryptablePropertyOverrideConfigurer

          public EncryptablePropertyOverrideConfigurer(org.jasypt.util.text.TextEncryptor textEncryptor)

      Creates an `EncryptablePropertyOverrideConfigurer` instance which will use the passed `TextEncryptor` object to decrypt encrypted values.

      Parameters:
        `textEncryptor` - the `TextEncryptor` to be used do decrypt values. It can not be null.

  - ### Method Detail

    - #### convertPropertyValue

          protected String convertPropertyValue(String originalValue)

      Overrides:
        `convertPropertyValue` in class `org.springframework.beans.factory.config.PropertyResourceConfigurer`

Copyright © 2019 The JASYPT team. All rights reserved.