Bug 591 - use PKCS#15 private key label as a comment in case of OpenSC
Summary: use PKCS#15 private key label as a comment in case of OpenSC
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: Smartcard (show other bugs)
Version: -current
Hardware: All Linux
: P2 enhancement
Assignee: OpenSSH Bugzilla mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-06-10 21:18 AEST by Nils Larsch
Modified: 2004-04-14 12:31 AEST (History)
0 users

See Also:


Attachments
suggested patch (2.71 KB, patch)
2003-06-10 21:22 AEST, Nils Larsch
no flags Details | Diff
changes to openbsd. (2.17 KB, patch)
2003-06-13 05:13 AEST, Markus Friedl
no flags Details | Diff
new patch for the portable release (based on Markus openbsd patch) (2.94 KB, patch)
2003-06-17 21:14 AEST, Nils Larsch
no flags Details | Diff
fix: sc_get_key_label should *not* return NULL (3.08 KB, patch)
2003-06-17 23:28 AEST, Nils Larsch
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nils Larsch 2003-06-10 21:18:54 AEST
Attached is patch with which the ssh-agent will use the optional PKCS#15
private key label (if existing) as the comment for the smartcard key
(instead of the standard comment "smartcard key"). In case sc_get_key_label
returns NULL the standard comment is used.

Comments etc. are welcome,
Nils
Comment 1 Nils Larsch 2003-06-10 21:22:47 AEST
Created attachment 325 [details]
suggested patch
Comment 2 Markus Friedl 2003-06-13 05:13:39 AEST
Created attachment 326 [details]
changes to openbsd.

i've commited this to openbsd.

ssh and ssh-agent assume that sc_get_key_label() always
return a xfree()-able string.
Comment 3 Nils Larsch 2003-06-17 20:21:33 AEST
Hi Markus, applying your patch to the portable cvs version and patching
scard-opensc.c with my patch (plus removing the 'const' in the sc_get_key_label
argument in scard-opensc.c) works fine for me with OpenSC.
Comment 4 Nils Larsch 2003-06-17 21:14:59 AEST
Created attachment 329 [details]
new patch for the portable release (based on Markus openbsd patch)
Comment 5 Nils Larsch 2003-06-17 23:28:18 AEST
Created attachment 330 [details]
fix: sc_get_key_label should *not* return NULL
Comment 6 Damien Miller 2003-06-28 18:02:59 AEST
Applied - thanks.
Comment 7 Damien Miller 2004-04-14 12:31:27 AEST
Mass change of VERIFIED bugs to CLOSED