Data Collector can use Vault functions to access information, a.k.a. secrets, stored in Hashicorp Vault. However, the Vault functions are now deprecated and will be removed in a future release. We recommend using the credential functions available with the Vault credential store integration.
You can use Vault secrets in place of username and password properties, similar properties such as AWS access key IDs and secret access keys, and in HTTP headers and bodies when using HTTPS.
To access Vault secrets using the Vault functions, configure properties for Data Collector to access Vault. Then, use Vault functions in the pipeline to access Vault at run time.
To enable Data Collector to connect to Vault, configure the following files located in the $SDC_CONF directory:
| Vault Property | Description |
|---|---|
| credentialStore.vault.config.addr | Required. Vault server URL entered in the following
format:https://<host name>:<port number> Use HTTPS to avoid unencrypted communication. |
| credentialStore.vault.config.role.id | Required. Vault Role ID that Data Collector uses to authenticate with Vault.
The Role ID is configured within Vault by your Vault administrator. The Data Collector Vault integration relies on
Vault's App Role authentication backend.
Important: The App ID authentication
backend has been deprecated by Hashicorp and will be removed in a future release. As a
result, do not configure the credentialStore.vault.config.app.id property
for new installations.
|
| credentialStore.vault.config.secret.id | Required. Vault Secret ID that Data Collector uses to authenticate with Vault.
The Secret ID is configured within Vault by your Vault administrator. Enter one of the
following:
|
| credentialStore.vault.config.lease.renewal.interval.sec | Optional. Seconds to wait before checking for leases that need renewal. Default is 60. |
| credentialStore.vault.config.lease.expiration.buffer.sec | Optional. Buffer for expiring leases. Data Collector renews leases that expire in less
than the specified number of seconds. Default is 120. |
| credentialStore.vault.config.open.timeout | Optional. Timeout to establish an HTTP connection to Vault in milliseconds. Default is 0 for no limit. |
| credentialStore.vault.config.proxy.address | Optional. Proxy URL. Configure to use a proxy to access Vault. |
| credentialStore.vault.config.proxy.port | Optional. Proxy port. Configure to use a proxy to access Vault. |
| credentialStore.vault.config.proxy.username | Optional. Proxy username. Configure to use a proxy to access Vault. |
| credentialStore.vault.config.proxy.password | Optional. Proxy password. Configure to use a proxy to access Vault. |
| credentialStore.vault.config.read.timeout | Optional. Milliseconds to wait for data before timing out. Default is 0 for no limit. |
| credentialStore.vault.config.ssl.enabled.protocols | Optional. SSL/TLS-enabled protocols. Versions TLSv1.2 or later are
recommended. Default is TLSv1.2,TLSv1.3. |
| credentialStore.vault.config.ssl.truststore.file | Optional. Path to a Java truststore file. Required when using a private CA or certificates not trusted by the Java default truststore. |
| credentialStore.vault.config.ssl.truststore.password | Optional. Password for the truststore file. |
| credentialStore.vault.config.ssl.verify | Optional. Whether to verify that the Vault server hostname matches its
certificate. Default is true. False is not recommended. |
| credentialStore.vault.config.ssl.timeout | Optional. Timeout for the SSL/TLS handshake in milliseconds. Default is 0 for no limit. |
| credentialStore.vault.config.timeout | Optional. Timeout to read from Vault in milliseconds, after a connection has been
established. Default is 0 for no limit. |
Restart Data Collector to enable the changes to both files.
After enabling Data Collector to access Vault, use the Vault functions in pipeline and stage properties to access Vault secrets.
The expression language provides Vault functions to return Vault secrets. You can use Vault functions in username, password, and similar properties such as AWS access key IDs and secret access keys. You can also use the functions in HTTP headers and bodies when using HTTPS.
For more information, see Miscellaneous Functions.