[7.x] Secure password for monitoring HTTP exporter#51775
Merged
danhermann merged 3 commits intoelastic:7.xfrom Feb 3, 2020
Merged
[7.x] Secure password for monitoring HTTP exporter#51775danhermann merged 3 commits intoelastic:7.xfrom
danhermann merged 3 commits intoelastic:7.xfrom
Conversation
Adds a secure and reloadable SECURE_AUTH_PASSWORD setting to allow keystore entries in the form "xpack.monitoring.exporters.*.auth.secure_password" to securely supply passwords for monitoring HTTP exporters. Also deprecates the insecure `AUTH_PASSWORD` setting.
Collaborator
|
Pinging @elastic/es-core-features (:Core/Features/Monitoring) |
dakrone
reviewed
Jan 31, 2020
...onitoring/src/test/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterIT.java
Outdated
Show resolved
Hide resolved
…/monitoring/exporter/http/HttpExporterIT.java Co-Authored-By: Lee Hinman <dakrone@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds reloadable SECURE_AUTH_PASSWORD to allow keystore entries in the form xpack.monitoring.exporters.*.secure_auth_password to securely supply passwords for monitoring exporters. Deprecates the insecure AUTH_PASSWORD setting.
It would have been ideal to include validation that only one of either the AUTH_PASSWORD or SECURE_AUTH_PASSWORD were set but the settings validation framework does not support secure settings. Additionally, the validation on the AUTH_USERNAME setting that required a password to be set if the username was set had to be removed because the password can now be set via a secure setting that the validation framework cannot see. It might be possible to extend the validation framework to handle secure settings, but if so, that would definitely be a separate work effort.
Making the SECURE_AUTH_PASSWORD setting reloadable meant that the Monitoring plugin had to be able to trigger a reload of any HTTP exporters when the cluster received a _nodes/reload_secure_settings request. This necessitated (unless I missed a cleaner approach) the addition of a reference to Exporters within the Monitoring class.
Fixes #50197.
Backport of #50919.