Bugzilla – Attachment 2393 Details for
Bug 2187
ssh-add unnecessarily prompts for PKCS#11 pin when removing key
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
tweaked patch
pkcs11-remove-nopin.diff (text/plain), 943 bytes, created by
Damien Miller
on 2013-12-19 10:42:29 AEDT
(
hide
)
Description:
tweaked patch
Filename:
MIME Type:
Creator:
Damien Miller
Created:
2013-12-19 10:42:29 AEDT
Size:
943 bytes
patch
obsolete
>Index: ssh-add.c >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/ssh-add.c,v >retrieving revision 1.107 >diff -u -p -r1.107 ssh-add.c >--- ssh-add.c 15 Dec 2013 18:17:26 -0000 1.107 >+++ ssh-add.c 18 Dec 2013 23:41:28 -0000 >@@ -287,14 +287,17 @@ add_file(AuthenticationConnection *ac, c > static int > update_card(AuthenticationConnection *ac, int add, const char *id) > { >- char *pin; >+ char *pin = NULL; > int ret = -1; > >- pin = read_passphrase("Enter passphrase for PKCS#11: ", RP_ALLOW_STDIN); >- if (pin == NULL) >- return -1; >+ if (add) { >+ if ((pin = read_passphrase("Enter passphrase for PKCS#11: ", >+ RP_ALLOW_STDIN)) == NULL) >+ return -1; >+ } > >- if (ssh_update_card(ac, add, id, pin, lifetime, confirm)) { >+ if (ssh_update_card(ac, add, id, pin == NULL ? "" : pin, >+ lifetime, confirm)) { > fprintf(stderr, "Card %s: %s\n", > add ? "added" : "removed", id); > ret = 0;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
dtucker
:
ok+
Actions:
View
|
Diff
Attachments on
bug 2187
:
2392
| 2393 |
2624