allow cbc, hmac and kex to be configured individually for client and server. #49
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.
This PR deprecates
require_cbc
,weak_hmac
andweak_kex
from the['ssh']
attribute namespace and moves them to['ssh']['client']
and['ssh']['server']
instead.The attributes in 'client' only affect the client, whereas 'server' affects only the configuration of the server.
I.e.
node['ssh']['client']['weak_hmac']
only adds hmac_sha1 to the MACs of ssh_config without weakening the hmacs of the server in sshd_config, and so forth.Real-world usecase: gitlab server with developers using Eclipse. For EGit we have to support hmac_sha1 on the server, but I don't want to allow that for the installed client.
The PR contains compat suport for the old attributes and tests to verify the precedence logic.
The reason why I don't let the client- and server-variants take precedence over the corresponding legacy value is that an existing chef client might still have the legacy value stored, and the user may not have noticed the new attributes yet.
Instead the following logic is applied (and documented in the code):
true
and both client and server variants are both unaltered from their default valuefalse
, then the legacy attribute takes precedence and sets both totrue
.true
we assume the user has seen the new settings and ignore the legacy valuetrue
, a warning is emitted, mentioning the fate of the value for both client and server configs.TL;DR:
Please merge, everything will be fine ;-)