To scramble sensitive information in a
.properties file or in
engineSignEncryptConfig.xml:
- Open the file for editing.
Append .encrypted
to any sensitive keys in the file, for example password
or pin
. When the system starts, the values will be encrypted with a key stored in PRIME. See the examples below.
Example with database.properties:
# A placeholder:
maxActive=200
# A property override:
dataSource.jdbcUrl=jdbc:h2:mem:prime;DB_CLOSE_DELAY=-1;LOCK_TIMEOUT=60000
dataSource.user.encrypted=sa
dataSource.password.encrypted=s3cr3t!
Example result:
# A placeholder:
maxActive=200
# A property override:
dataSource.jdbcUrl=jdbc:h2:mem:prime;DB_CLOSE_DELAY=-1;LOCK_TIMEOUT=60000
dataSource.user=encrypted:3I5rVis6scgAzEGg0MtqLw==
dataSource.password=encrypted:K41LmsAmxiIMcTq3k8sAS8l=
Example with engineSignEncryptConfig.xml:
</key>
<key name="encCert">
<type name="pkcs12" locationValue="classpath:hybridEncKeypair2.p12" pin.encrypted="1234567"/>
</key>
Example result:
</key>
<key name="encCert">
<type name="pkcs12" locationValue="classpath:hybridEncKeypair2.p12" pin=encrypted:JMyVZtk9WIWQQEfpC4CEVg== />
</key>