Bug 1314378 - gnome-keyring sets incorrect label (and ID) on certificates
gnome-keyring sets incorrect label (and ID) on certificates
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: gnome-keyring (Show other bugs)
23
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Matthias Clasen
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-03-03 08:24 EST by David Woodhouse
Modified: 2016-12-20 14:13 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-12-20 14:13:08 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description David Woodhouse 2016-03-03 08:24:34 EST
p11tool --load-certificate ~/.fedora.cert  --write 'pkcs11:token=Gnome2%20Key%20Storage'  --login
warning: The object's label was not specified.
Label: FedoraCert
[dwoodhou@i7 ~]$ p11tool --list-all-certs  'pkcs11:token=Gnome2%20Key%20Storage;object=FedoraCert'  --login
No matching objects found


Hm. It got added with the wrong label, taken from the certificate's Subject field.

In fact the ID doesn't match the X509v3 Subject Key Identifier *either*, wasn't it supposed to? Didn't we fix that once already?

$ openssl x509 -in ~/.fedora.cert -noout -text | grep -A1 Subject\ Key\ Iden
            X509v3 Subject Key Identifier: 
                75:3B:F3:AA:E3:03:D7:F4:42:73:BB:34:54:58:A8:AD:EB:6E:37:BB

But what got imported was:

Object 0:
	URL: pkcs11:model=1.0;manufacturer=Gnome%20Keyring;serial=1%3aUSER%3aDEFAULT;token=Gnome2%20Key%20Storage;id=%bf%5f%fc%40%4e%4a%a4%14%05%35%f0%4a%ab%11%19%68%ac%3d%d7%e3;object=dwmw2;type=cert
	Type: X.509 Certificate
	Label: dwmw2
	ID: bf:5f:fc:40:4e:4a:a4:14:05:35:f0:4a:ab:11:19:68:ac:3d:d7:e3
Comment 1 Nikos Mavrogiannopoulos 2016-03-03 08:50:38 EST
Cannot reproduce with softhsm. Are you sure that this is an issue on p11tool and not the gnome key storage?
Comment 2 David Woodhouse 2016-03-07 06:42:51 EST
Hm, maybe. And in fact now you come to mention it, ISTR fixing precisely such an issue with CKA_ID generation in gnome-keyring. Perhaps it regressed...
Comment 3 David Woodhouse 2016-03-07 06:45:30 EST
12: C_CreateObject
2016-03-07 11:43:59.635
[in] hSession = 0x518
[in] pTemplate[9]: 
    CKA_CLASS             CKO_CERTIFICATE      
    CKA_ID                00007ffc0beb2ae0 / 20
    00000000  75 3B F3 AA E3 03 D7 F4 42 73 BB 34 54 58 A8 AD  u;......Bs.4TX..
    00000010  EB 6E 37 BB                                      .n7.            
    CKA_VALUE             0000557df7fb46f0 / 1841
    00000000  30 82 07 2D 30 82 03 21 A0 03 02 01 02 02 03 00  0..-0..!........
...
    00000720  5B 01 50 0B 38 C3 E7 F3 13 FA FE 2A B6 4D A0 36  [.P.8......*.M.6
    00000730  A8                                               .               
    CKA_TOKEN             True
    CKA_CERTIFICATE_TYPE  CKC_X_509
    CKA_SUBJECT           0000557df7fb9685 / 145
    00000000  30 81 8E 31 0B 30 09 06 03 55 04 06 13 02 55 53  0..1.0...U....US
...
    00000090  67                                               g               
    DN: C=US, ST=North Carolina, O=Fedora Project, OU=Fedora User Cert, CN=dwmw2/emailAddress=dwmw2@infradead.org
    CKA_ISSUER            0000557df7fb95b1 / 180
    00000000  30 81 B1 31 0B 30 09 06 03 55 04 06 13 02 55 53  0..1.0...U....US
...
    000000B0  2E 6F 72 67                                      .org            
    DN: C=US, ST=North Carolina, L=Raleigh, O=Fedora Project, OU=Fedora Project CA, CN=Fedora Project CA/emailAddress=admin@fedoraproject.org
    CKA_SERIAL_NUMBER     00007ffc0beb2b00 / 3
    00000000  00 8B B2                                         ...             
    CKA_LABEL             0000557df7cffd20 / 10
    4665646F 72614365 7274
     F e d o  r a C e  r t
[out] *phObject = 0x2a72
Returned:  0 CKR_OK
Comment 4 Fedora End Of Life 2016-11-24 10:54:24 EST
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '23'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 5 Fedora End Of Life 2016-12-20 14:13:08 EST
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.