Index |
Overview |
Starting with Wrapper version 3.6.0, the Standard and Professional Editions make it possible to obfuscate passwords or sensitive data to store them more securely in your configuration files. Obfuscation should be distinguished from true encryption, but provides some level of security by hiding the actual text or password and making it very difficult for a casual observer to remember the encoded value. When loading the configuration, the Wrapper will decode any obfuscated tokens and mark the property values where they are referenced as sensitive. A property value marked as sensitive will be treated with additional precautions, firstly by ensuring that it was loaded from a secure file, and secondly by ensuring that it is only used for its intended purpose without clear-text disclosure. To exclude the use of properties whose values may appear in the console, emails, logs, command line, etc., only a limited set of properties are allowed to contain obfuscated tokens in their values. Usage in variable definitions is also prohibited to prevent leakage to the environment. NOTEProperties allowed to contain obfuscated tokens in their values are limited to the following:
A property value containing sensitive data will be handled with the following security precautions:
Several methods are available to encode/obfuscate your passwords. For some of them a private key can be used. The Wrapper provide commands to encode your data and generate private keys. This page will describe the options for each command. WARNINGThe obfuscation methods offered by the Wrapper, along with the associated security measures described above, are primarily designed to prevent the leakage of sensitive data in clear text outside the Java application. By using the wrapper.app.property.<n> properties or setting wrapper.app.parameter.backend to TRUE, it is possible to pass the system properties and application parameters safely to your Java application. However, keep in mind that once received by the Java code, these values will be stored as clear text in system properties or in a string array. Please be aware of the following issues: - Someone who came into possession of your obfuscated secrets (or configuration files) could create a simple Java application to dump system properties, use the Wrapper to launch it, and thus easily discover your passwords. It is therefore important that the Wrapper configuration files containing sensitive data are always accessible only to authorized users. That is why the Wrapper checks the permissions of sensitive files everytime it starts and provide guidance on how to adjust them, but it is up to you to actually edit the file permissions. It is also recommended to use a private key file with file permissions set as restricted as possible. - Someone with access to your machine could use a debugger to trace the memory of your Java application and discover the String values where clear text passwords are stored. Always make sure to run your Java application in a secure environment. |
Obfuscate data |
|||||||||||||||||||||||||||||||
The --cipher command can be used to encode passwords or sensitive data with the Wrapper and generate the associated "cipher" configuration. To specify exactly how to encode your values, several parameters are needed when using the --cipher command. The section below will described how to configure each parameter, but first lets have a look at how encoded values will look like in your configuration file. The following syntax is used:
The encoding of value(s) can be configured with the following set of properties.
Some methods define a default configuration, in which case the above properties can be omitted. Such default configurations do not use a custom private key and the <cipher_name> is the same as the method name. Now let's go into the details of using the --cipher command. 'wrapper --help' will print the following output, which we will further explain below:
|
Generate Private Keys |
|||||||||||
The Wrapper provides the --keygen command to generate private keys that are used by certain encoding methods. WARNINGBy default, the Wrapper will generate a key with read and write permissions granted to only the user running the Wrapper. On Unix systems, this user will be the "owner" of the file and only the owner will have read-write permissions. These permissions can be changed afterwards, but please keep in mind that they should be granted to the bare minimum. Usually only the user running the Wrapper should be allowed to access the private key. Please read this page to learn how to adjust the permissions of your private key. 'wrapper --help' will print the following output, which we will further explain below:
|
Verweis: Sicherheit |
Cipher configuration:
Secure Files:
Commands: |