Summary
The value of nvdApiKey
configuration parameter is logged in clear text in debug mode.
Details
The NVD API key is a kind of secret and should be treated like other secrets when logging in debug mode.
Expecting the same behavior as for several password configurations: just print ******
Note that while the NVD API Key is an access token for the NVD API - they are not that sensitive. The only thing an NVD API Token grants is a higher rate limit when making calls to publicly available data. The data available from the NVD API is the same whether you have an API Key or not.
Regarding Maven Configuration
Per standard maven debug logging (e.g. mvn package -X
) the configuration options are displayed - including credentials, API keys, etc. Per Maven's documentation, the server ID configuration options should be used to store sensitive data: https://maven.apache.org/guides/mini/guide-encryption.html
PoC
The nvdApiKey is configured to use an environment variable; when running mvn -X dependency-check:check
the clear value is logged twice.
Impact
The NVD API key is a kind of secret and should not be exposed. If stolen, an attacker can use this key to obtain already public information.
Summary
The value of
nvdApiKey
configuration parameter is logged in clear text in debug mode.Details
The NVD API key is a kind of secret and should be treated like other secrets when logging in debug mode.
Expecting the same behavior as for several password configurations: just print
******
Note that while the NVD API Key is an access token for the NVD API - they are not that sensitive. The only thing an NVD API Token grants is a higher rate limit when making calls to publicly available data. The data available from the NVD API is the same whether you have an API Key or not.
Regarding Maven Configuration
Per standard maven debug logging (e.g.
mvn package -X
) the configuration options are displayed - including credentials, API keys, etc. Per Maven's documentation, the server ID configuration options should be used to store sensitive data: https://maven.apache.org/guides/mini/guide-encryption.htmlPoC
The nvdApiKey is configured to use an environment variable; when running
mvn -X dependency-check:check
the clear value is logged twice.Impact
The NVD API key is a kind of secret and should not be exposed. If stolen, an attacker can use this key to obtain already public information.