Package org.nuxeo.common.codec
Class CryptoProperties
- All Implemented Interfaces:
Serializable,Cloneable,Map<Object,Object>
Properties with crypto capabilities.The cryptographic algorithms depend on:
- Environment.SERVER_STATUS_KEY
- Environment.CRYPT_KEYALIAS && Environment.CRYPT_KEYSTORE_PATH || getProperty(Environment.JAVA_DEFAULT_KEYSTORE)
- Environment.CRYPT_KEY
- Since:
- 7.4
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class java.util.Properties
defaults -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetProperty(String key) getProperty(String key, boolean raw) getRawProperty(String key) getRawProperty(String key, String defaultValue) Searches for the property with the specified key in this property list.voidload(InputStream inStream) voidvoidmerge(Object key, Object value, BiFunction<? super Object, ? super Object, ? extends Object> remappingFunction) voidputIfAbsent(Object key, Object value) booleanbooleanMethods inherited from class java.util.Properties
clear, clone, compute, computeIfAbsent, computeIfPresent, contains, containsKey, containsValue, elements, entrySet, equals, forEach, get, getOrDefault, getProperty, hashCode, isEmpty, keys, keySet, list, list, propertyNames, rehash, replaceAll, save, setProperty, size, store, store, storeToXML, storeToXML, storeToXML, stringPropertyNames, toString, values
-
Constructor Details
-
CryptoProperties
-
CryptoProperties
public CryptoProperties()
-
-
Method Details
-
getCrypto
-
load
- Overrides:
loadin classProperties- Throws:
IOException
-
load
- Overrides:
loadin classProperties- Throws:
IOException
-
loadFromXML
- Overrides:
loadFromXMLin classProperties- Throws:
IOExceptionInvalidPropertiesFormatException
-
put
-
putAll
-
putIfAbsent
- Specified by:
putIfAbsentin interfaceMap<Object,Object> - Overrides:
putIfAbsentin classProperties
-
replace
-
replace
-
merge
-
getRawProperty
- Returns:
- the "raw" property: not decrypted if it was provided encrypted
-
getRawProperty
Searches for the property with the specified key in this property list. If the key is not found in this property list, the default property list, and its defaults, recursively, are then checked. The method returns the default value argument if the property is not found.- Returns:
- the "raw" property (not decrypted if it was provided encrypted) or the
defaultValueif not found - See Also:
-
getProperty
- Overrides:
getPropertyin classProperties
-
getProperty
- Parameters:
raw- if the encrypted values must be returned encrypted (raw==true) or decrypted (raw==false)- Returns:
- the property value or null
-
remove
-
remove
-