diff options
author | Nalin Dahyabhai <nalin@dahyabhai.net> | 2013-02-26 17:59:01 -0500 |
---|---|---|
committer | Greg Hudson <ghudson@mit.edu> | 2013-05-08 01:12:37 -0400 |
commit | c45b83c1ce2b7300dea04ca81aabec5af948e98f (patch) | |
tree | a18a4483d8752000b16de7c3f30e8c0a4bd91f69 /src | |
parent | 1e7d7018e7a29c91c86ce4222cff9e44cf8b62a2 (diff) | |
download | krb5-c45b83c1ce2b7300dea04ca81aabec5af948e98f.tar.gz krb5-c45b83c1ce2b7300dea04ca81aabec5af948e98f.tar.xz krb5-c45b83c1ce2b7300dea04ca81aabec5af948e98f.zip |
Make reassembled PKCS11 names parseable
The reassembled names used "," as a separator between attributes, when
passed-in values use ":". This was due to the original submitter being
confused - they weren't intended to be different.
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/preauth/pkinit/pkinit_crypto_nss.c | 10 | ||||
-rw-r--r-- | src/plugins/preauth/pkinit/pkinit_crypto_openssl.c | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/plugins/preauth/pkinit/pkinit_crypto_nss.c b/src/plugins/preauth/pkinit/pkinit_crypto_nss.c index ec6db2d136..26901986b6 100644 --- a/src/plugins/preauth/pkinit/pkinit_crypto_nss.c +++ b/src/plugins/preauth/pkinit/pkinit_crypto_nss.c @@ -2057,23 +2057,23 @@ reassemble_pkcs11_name(PLArenaPool *pool, pkinit_identity_opts *idopts) k5_buf_add(&buf, "PKCS11:"); n = 0; if (idopts->p11_module_name != NULL) { - k5_buf_add_fmt(&buf, "%smodule_name=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%smodule_name=%s", n++ ? ":" : "", idopts->p11_module_name); } if (idopts->token_label != NULL) { - k5_buf_add_fmt(&buf, "%stoken=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%stoken=%s", n++ ? ":" : "", idopts->token_label); } if (idopts->cert_label != NULL) { - k5_buf_add_fmt(&buf, "%scertlabel=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%scertlabel=%s", n++ ? ":" : "", idopts->cert_label); } if (idopts->cert_id_string != NULL) { - k5_buf_add_fmt(&buf, "%scertid=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%scertid=%s", n++ ? ":" : "", idopts->cert_id_string); } if (idopts->slotid != PK_NOSLOT) { - k5_buf_add_fmt(&buf, "%sslotid=%ld", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%sslotid=%ld", n++ ? ":" : "", (long)idopts->slotid); } if (k5_buf_len(&buf) >= 0) diff --git a/src/plugins/preauth/pkinit/pkinit_crypto_openssl.c b/src/plugins/preauth/pkinit/pkinit_crypto_openssl.c index ee94f088cc..a706911973 100644 --- a/src/plugins/preauth/pkinit/pkinit_crypto_openssl.c +++ b/src/plugins/preauth/pkinit/pkinit_crypto_openssl.c @@ -4514,23 +4514,23 @@ reassemble_pkcs11_name(pkinit_identity_opts *idopts) k5_buf_add(&buf, "PKCS11:"); n = 0; if (idopts->p11_module_name != NULL) { - k5_buf_add_fmt(&buf, "%smodule_name=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%smodule_name=%s", n++ ? ":" : "", idopts->p11_module_name); } if (idopts->token_label != NULL) { - k5_buf_add_fmt(&buf, "%stoken=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%stoken=%s", n++ ? ":" : "", idopts->token_label); } if (idopts->cert_label != NULL) { - k5_buf_add_fmt(&buf, "%scertlabel=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%scertlabel=%s", n++ ? ":" : "", idopts->cert_label); } if (idopts->cert_id_string != NULL) { - k5_buf_add_fmt(&buf, "%scertid=%s", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%scertid=%s", n++ ? ":" : "", idopts->cert_id_string); } if (idopts->slotid != PK_NOSLOT) { - k5_buf_add_fmt(&buf, "%sslotid=%ld", n++ ? "," : "", + k5_buf_add_fmt(&buf, "%sslotid=%ld", n++ ? ":" : "", (long)idopts->slotid); } if (k5_buf_len(&buf) >= 0) |