DescriptionImprove ssh auth key utils
This branch addesses some of the issues raised by
jam in https://codereview.appspot.com/37560043/. I
landed the branch before seeing the comments.
It's not quite perfect yet. Lines in the auth keys
file which have "command" or "from" et al directives
are preserved, but the key on those lines is not
recognised for dup checking when adding etc. Also,
when keys are changed and written out, all of the
"non key" lines are written at the top of the file,
followed by the juju keys.
The above issues are not critical for juju. Nodes
managed by juju will have auth key files fully managed
by juju so the issues are irrelevant unless the user
edits the auth keys file by hand. For manually
provisioned nodes, the auth key file is more likely
to be hand edited. But in all cases, lines Juju doesn't
recognise are never deleted. The worst that will happen
is a duplicate key might be added if there were a manually
added line with a command prefixing the key and the same key is
added to Juju.
A future branch will address the above remaining issue.
https://code.launchpad.net/~wallyworld/juju-core/ssh-auth-keys-fixes/+merge/198747
Requires: https://code.launchpad.net/~wallyworld/juju-core/keymanager-add-delete/+merge/198673
(do not edit description out of merge proposal)
Patch Set 1 #
Total comments: 4
Patch Set 2 : Improve ssh auth key utils #
Total comments: 6
Patch Set 3 : Improve ssh auth key utils #
MessagesTotal messages: 7
|