-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
clarify documentation about encrypt parameter #3823
Comments
Hi @lesinigo once you've rotated the key it doesn't hurt to leave the parameter there, but I think you are correct that it can be removed once the local keyring file is established.
If an attacker got a hold of the encryption keys they could join the cluster and send spurious gossip messages (like causing leave and rejoin of servers, etc.). If the key gets compromised you'd need to rotate it out on the rest of the nodes. We can definitely improve the documentation around this. |
@slackpad so if I understand it correctly, from a security standpoint having someone reading the By extension I'd then say that assuming (related to this: maybe some documentation about how to rotate the encryption key of a whole cluster could be of help) |
Yes - the same user owns both the config file and the data directory where local.keyring is stored, so you are compromised when the consul user is compromised and leaving the encryption key in the config doesn't make it worse. You can use Also, we are working on making keyring management fully automated in a future release. |
@preetapan Just curious, do we have the keyring management in place yet? |
nothing automated yet. But since the original issues was resolved, I will close this issue now. |
I have observed (with consul-1.0.2 which is current at the time of this writing) that after an agent has completed joining an
encrypt
-enabled cluster I can remove theencrypt
parameter from the agent configuration and it will keep working correctly, even after a restart.It is my understanding that the
encrypt
parameter is needed only at join time and after that the agent will persist whatever data it needs in the local keyring - as is also referenced in issue #1299 for an older version. On the other hand, documentation is a little vague about this and seems to imply to always leave theencrypt
parameter in the agent configuration and I don't know if there is any other scenario where an agent would need that parameter even after a successful join.I have not tried keeping an agent disconnected from the cluster for a long time and I had not done any test on consul servers.
After bootstrapping the consul servers should I keep the
encrypt
parameter on them, or should it be removed?And what about agents, should I remove the parameter after they have joined the cluster?
A clarification would be appreciated, and IMHO the documentation should be updated to explicitly say:
encrypt
parameter on it gets compromised (and the attacker gains access to that nodelocal.keyring
) ?The text was updated successfully, but these errors were encountered: