Patch to discourage unencrypted key generation

John Hawkinson jhawk at MIT.EDU
Sat Jun 1 00:58:56 EST 2013

Nico Kadel-Garcia <nkadel at> wrote on Fri, 31 May 2013
at 09:40:31 -0400 in <5B00EEF4-A27B-4D1B-B7F0-C1F2524E32AF at>:

> Generating host keys, which are normally passphrase free and done by
> root. That can be written into the init script, where such keys are
> usually generated, and complex test cases avoided.

This just isn't compelling.

It is BAD PRACTICE to have root behave differently from other users.
It should only be used in extreme cases. (I asked the question, kind of
hoping there was some stronger justification).

It promotes confusion when software behaves differently when run under
different UIDs. It also does nothing to repair the bad habits some
users may have while running as root (oh boy). And there are legit
needs to generate keypairs as non-root users.

Non-root users should be able to generate keypairs without human interaction,
too, if root users do. They also have automation requirements.

Please drop the root check and make it a simple command-line check.

--jhawk at
  John Hawkinson

More information about the openssh-unix-dev mailing list