diff options
Diffstat (limited to 'ssh-keygen.c')
-rw-r--r-- | ssh-keygen.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/ssh-keygen.c b/ssh-keygen.c index 8183c2fa0..a788b710a 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssh-keygen.c,v 1.282 2015/11/19 01:12:32 djm Exp $ */ | 1 | /* $OpenBSD: ssh-keygen.c,v 1.283 2015/11/20 23:04:01 halex Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1994 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -1429,9 +1429,11 @@ do_change_comment(struct passwd *pw) | |||
1429 | identity_file, ssh_err(r)); | 1429 | identity_file, ssh_err(r)); |
1430 | } | 1430 | } |
1431 | } | 1431 | } |
1432 | /* XXX what about new-format keys? */ | 1432 | |
1433 | if (private->type != KEY_RSA1) { | 1433 | if (private->type != KEY_RSA1 && private->type != KEY_ED25519 && |
1434 | error("Comments are only supported for RSA1 keys."); | 1434 | !use_new_format) { |
1435 | error("Comments are only supported for RSA1 or keys stored in " | ||
1436 | "the new format (-o)."); | ||
1435 | explicit_bzero(passphrase, strlen(passphrase)); | 1437 | explicit_bzero(passphrase, strlen(passphrase)); |
1436 | sshkey_free(private); | 1438 | sshkey_free(private); |
1437 | exit(1); | 1439 | exit(1); |