public final class EncryptableServletContextPropertyPlaceholderConfigurer
extends org.springframework.web.context.support.ServletContextPropertyPlaceholderConfigurer
Subclass of
org.springframework.web.context.support.ServletContextPropertyPlaceholderConfigurer
which can make use of a StringEncryptor
or
TextEncryptor
object to decrypt servlet context parameter values
if they are encrypted in the loaded resource locations.
A value is considered "encrypted" when it appears surrounded by ENC(...), like:
DEFAULT_PLACEHOLDER_PREFIX, DEFAULT_PLACEHOLDER_SUFFIX, DEFAULT_VALUE_SEPARATOR, SYSTEM_PROPERTIES_MODE_FALLBACK, SYSTEM_PROPERTIES_MODE_NEVER, SYSTEM_PROPERTIES_MODE_OVERRIDE
Constructor and Description |
---|
EncryptableServletContextPropertyPlaceholderConfigurer(org.jasypt.encryption.StringEncryptor stringEncryptor)
Creates an EncryptableServletContextPropertyPlaceholderConfigurer instance
which will use the passed
StringEncryptor object to decrypt
encrypted values. |
EncryptableServletContextPropertyPlaceholderConfigurer(org.jasypt.util.text.TextEncryptor textEncryptor)
Creates an EncryptableServletContextPropertyPlaceholderConfigurer instance which will use the
passed
TextEncryptor object to decrypt encrypted values. |
Modifier and Type | Method and Description |
---|---|
protected String |
convertPropertyValue(String originalValue) |
protected String |
resolvePlaceholder(String placeholder,
Properties props) |
resolvePlaceholder, setContextOverride, setSearchContextAttributes, setServletContext
parseStringValue, processProperties, resolvePlaceholder, resolveSystemProperty, setBeanFactory, setBeanName, setIgnoreUnresolvablePlaceholders, setNullValue, setPlaceholderPrefix, setPlaceholderSuffix, setSearchSystemEnvironment, setSystemPropertiesMode, setSystemPropertiesModeName
convertProperties, getOrder, postProcessBeanFactory, setOrder
public EncryptableServletContextPropertyPlaceholderConfigurer(org.jasypt.encryption.StringEncryptor stringEncryptor)
Creates an EncryptableServletContextPropertyPlaceholderConfigurer instance
which will use the passed StringEncryptor
object to decrypt
encrypted values.
stringEncryptor
- the StringEncryptor
to be used do decrypt values. It
can not be null.public EncryptableServletContextPropertyPlaceholderConfigurer(org.jasypt.util.text.TextEncryptor textEncryptor)
Creates an EncryptableServletContextPropertyPlaceholderConfigurer instance which will use the
passed TextEncryptor
object to decrypt encrypted values.
textEncryptor
- the TextEncryptor
to be used do decrypt values. It can
not be null.protected String convertPropertyValue(String originalValue)
convertPropertyValue
in class org.springframework.beans.factory.config.PropertyResourceConfigurer
protected String resolvePlaceholder(String placeholder, Properties props)
resolvePlaceholder
in class org.springframework.web.context.support.ServletContextPropertyPlaceholderConfigurer
Copyright © 2019 The JASYPT team. All rights reserved.