Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Evergreen:11.2
engine_pkcs11
search-certs-by-label.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File search-certs-by-label.patch of Package engine_pkcs11
--- engine_pkcs11-0.1.6/src/engine_pkcs11.c +++ engine_pkcs11-0.1.6/src/engine_pkcs11.c @@ -492,7 +492,17 @@ fprintf(stderr, "Found %u cert%s:\n", cert_count, (cert_count <= 1) ? "" : "s"); } - if ((s_slot_cert_id && *s_slot_cert_id) || (cert_id_len == 0)) { + + if (cert_label) { + for (n = 0; n < cert_count; n++) { + PKCS11_CERT *k = certs + n; + + if (k->label && strcmp (k->label, cert_label)) + selected_cert = k; + } + + free(cert_label); + } else if ((s_slot_cert_id && *s_slot_cert_id) || (cert_id_len == 0)) { for (n = 0; n < cert_count; n++) { PKCS11_CERT *k = certs + n; @@ -512,8 +522,6 @@ } x509 = X509_dup(selected_cert->x509); - if (cert_label != NULL) - free(cert_label); return x509; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor