# Configure the Java agent

The standard installation for all agents uses this order of precedence.

You can configure the Java agent using:

### Tip

Use the Contrast agent configuration editor to create or upload a YAML configuration file, validate YAML and get setting recommendations.

You may need to configure your application’s Java environment to work effectively with the agent if your system uses:

• Multi-tenant application configuration: If your JVM application server hosts multiple applications during a deployment, you can distinguish applications from each other and then apply individual configuration options.

• TLS certificates

• Java 9 Modules

• Java 2 Security

• Integrations: The Contrast Java agent, can also be configured and run in conjunction with several third-party tools, plugins and integrations. Consult the remote product documentation for information about how other products work.

## Java system properties

Substitute <YourContrastJarPath> with the path to your Contrast JAR, and use these commands to learn more about system properties:

• To generate a list of general properties using the Contrast agent JAR, use:

 java -jar <YourContrastJarPath> properties
• Use command line with tools to search for commands. For example, these commands display a list of proxy-related properties:

Using the built-in filter:

java -jar <YourContrastJarPath> properties --filter=proxy

## Java YAML configuration template

Use this template to configure the Java agent using a YAML configuration file. (Learn more about YAML configuration.)

Place your YAML file in the default location:

• Unix: /etc/contrast/java/contrast_security.yaml

• Windows: C:/ProgramData/contrast/java/contrast_security.yaml

https://docs.contrastsecurity.com/common-agent-config/java_contrast_security.yaml