)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"626a546f_115ce6fb","updated":"2024-06-03 03:04:01.000000000","message":"I can\u0027t comment on the usefulness of this, but the changes look easy to maintain and clean, so a conditional feature-ACK from me.\n\nAt least one function call involves network search in the AD, a test report of what happens when no DC\u0027s are reachable would help. If that could cause a slow timeout, or error, we should document it. In typical setups DCs are often unreachable before the tunnel is up.","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"421eaeac5309f614b8a6dd19e2df6a0f1512bba0","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"47483e39_17f7bf31","updated":"2024-05-28 17:43:34.000000000","message":"This was originally sent by Heigo Wundram [1], and I\u0027m reposting it (with\nsome small changes) because I also need this.\n\nChanges since v2:\n- Added man page docu for cryptoapicert \"TMPL:\"\n- Removed the if() of the first CryptFindOIDInfo call as was suggested.\n- Removed the \"V1 extension (Windows 2K and below)\" part, or does openvpn\n  still support Win2K?\n- Call find_oid only if Objid doesn\u0027t match the template name.\n- The code in find_certificate_in_store was a bit reordered, it should\n  be easier to understand now.\n\n[1] https://patchwork.openvpn.net/project/openvpn2/patch/20210525092510.27517-1-heiko.wundram@gehrkens.it/","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b33d1442_8091ed47","updated":"2024-06-03 14:35:28.000000000","message":"The new patch should resolve all comments.","commit_id":"7776e7f7988e245b05b2a20d9f48377872ab7c4c"}],"doc/man-sections/windows-options.rst":[{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":true,"context_lines":[{"line_number":59,"context_line":"  OID of the template:"},{"line_number":60,"context_line":"  ::"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"     cryptoapicert \"TMPL:1.3.6.1.4...\""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"  The first non-expired certificate found in the user\u0027s store or the"},{"line_number":65,"context_line":"  machine store that matches the select-string is used."}],"source_content_type":"text/x-rst","patch_set":1,"id":"98846a64_c997a4b3","line":62,"updated":"2024-06-03 03:04:01.000000000","message":"Add an example where the template name is used instead of OID?","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[{"line_number":59,"context_line":"  OID of the template:"},{"line_number":60,"context_line":"  ::"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"     cryptoapicert \"TMPL:1.3.6.1.4...\""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"  The first non-expired certificate found in the user\u0027s store or the"},{"line_number":65,"context_line":"  machine store that matches the select-string is used."}],"source_content_type":"text/x-rst","patch_set":1,"id":"dea7be4c_cb1afe99","line":62,"in_reply_to":"98846a64_c997a4b3","updated":"2024-06-03 14:35:28.000000000","message":"Done","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"}],"src/openvpn/cryptoapi.c":[{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":true,"context_lines":[{"line_number":214,"context_line":"    if (!info)"},{"line_number":215,"context_line":"    {"},{"line_number":216,"context_line":"        info \u003d CryptFindOIDInfo(keytype, (void*)key, groupid);"},{"line_number":217,"context_line":"    }"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    /* fall back to all groups if not found yet and fallback requested */"},{"line_number":220,"context_line":"    if (!info \u0026\u0026 fallback \u0026\u0026 groupid)"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"41d62b25_9fc645be","line":217,"updated":"2024-06-03 03:04:01.000000000","message":"I think I said this in response to the original in 2021 as well: why separate into two calls like this? The use of the flag is to avoid network calls, but if we are anyway going to allow network access, its more efficient to allow it in the first place. I\u0027m assuming the call will return quickly if a local search succeeds even if the flag is not there.","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[{"line_number":214,"context_line":"    if (!info)"},{"line_number":215,"context_line":"    {"},{"line_number":216,"context_line":"        info \u003d CryptFindOIDInfo(keytype, (void*)key, groupid);"},{"line_number":217,"context_line":"    }"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    /* fall back to all groups if not found yet and fallback requested */"},{"line_number":220,"context_line":"    if (!info \u0026\u0026 fallback \u0026\u0026 groupid)"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"63f95189_515a1777","line":217,"in_reply_to":"41d62b25_9fc645be","updated":"2024-06-03 14:35:28.000000000","message":"Done","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":true,"context_lines":[{"line_number":217,"context_line":"    }"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    /* fall back to all groups if not found yet and fallback requested */"},{"line_number":220,"context_line":"    if (!info \u0026\u0026 fallback \u0026\u0026 groupid)"},{"line_number":221,"context_line":"    {"},{"line_number":222,"context_line":"        info \u003d CryptFindOIDInfo(keytype, (void*)key, 0);"},{"line_number":223,"context_line":"    }"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"aa376a5e_4ae3dc25","line":220,"updated":"2024-06-03 03:04:01.000000000","message":"I see the only place this is called is with fallback\u003dtrue, so we do not need that argument and can always fallback if groupid !\u003d 0.","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[{"line_number":217,"context_line":"    }"},{"line_number":218,"context_line":""},{"line_number":219,"context_line":"    /* fall back to all groups if not found yet and fallback requested */"},{"line_number":220,"context_line":"    if (!info \u0026\u0026 fallback \u0026\u0026 groupid)"},{"line_number":221,"context_line":"    {"},{"line_number":222,"context_line":"        info \u003d CryptFindOIDInfo(keytype, (void*)key, 0);"},{"line_number":223,"context_line":"    }"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"404e038e_7d02372b","line":220,"in_reply_to":"aa376a5e_4ae3dc25","updated":"2024-06-03 14:35:28.000000000","message":"Done","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":true,"context_lines":[{"line_number":274,"context_line":"     * SUBJ:\u003ccertificate substring to match\u003e"},{"line_number":275,"context_line":"     * THUMB:\u003ccertificate thumbprint hex value\u003e, e.g."},{"line_number":276,"context_line":"     *     THUMB:f6 49 24 41 01 b4 fb 44 0c ce f4 36 ae d0 c4 c9 df 7a b6 28"},{"line_number":277,"context_line":"     * TMPL:\u003ctemplate name\u003e"},{"line_number":278,"context_line":"     * The first matching certificate that has not expired is returned."},{"line_number":279,"context_line":"     */"},{"line_number":280,"context_line":"    const CERT_CONTEXT *rv \u003d NULL;"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"9ee83cff_cbebf4f4","line":277,"updated":"2024-06-03 03:04:01.000000000","message":"template name or OID ?","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[{"line_number":274,"context_line":"     * SUBJ:\u003ccertificate substring to match\u003e"},{"line_number":275,"context_line":"     * THUMB:\u003ccertificate thumbprint hex value\u003e, e.g."},{"line_number":276,"context_line":"     *     THUMB:f6 49 24 41 01 b4 fb 44 0c ce f4 36 ae d0 c4 c9 df 7a b6 28"},{"line_number":277,"context_line":"     * TMPL:\u003ctemplate name\u003e"},{"line_number":278,"context_line":"     * The first matching certificate that has not expired is returned."},{"line_number":279,"context_line":"     */"},{"line_number":280,"context_line":"    const CERT_CONTEXT *rv \u003d NULL;"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"f5b1a275_d56ff8fa","line":277,"in_reply_to":"9ee83cff_cbebf4f4","updated":"2024-06-03 14:35:28.000000000","message":"Done","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000009,"name":"Selva Nair","display_name":"Selva Nair","email":"selva.nair@gmail.com","username":"selvanair"},"change_message_id":"2bd78e8fe192563a135fa0fedcf0ef62a2509ade","unresolved":true,"context_lines":[{"line_number":311,"context_line":"    {"},{"line_number":312,"context_line":"        cert_prop +\u003d 5;"},{"line_number":313,"context_line":"        find_param \u003d NULL;"},{"line_number":314,"context_line":"        find_type \u003d CERT_FIND_ANY;"},{"line_number":315,"context_line":"    }"},{"line_number":316,"context_line":"    else"},{"line_number":317,"context_line":"    {"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"fcc24a46_78a084ec","line":314,"updated":"2024-06-03 03:04:01.000000000","message":"Shouldn\u0027t we use a more restrictive search with, say, CERT_FIND_HAS_PRIVATE_KEY? If there are multiple users on the client machine with certificates for each installed in the machine store, matching the template name alone could pick a certificate for which the user has no access to the private key and error out later.\n\nThis could also significantly reduce the number of certificates to walk through.","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"},{"author":{"_account_id":1000037,"name":"ssbssa","display_name":"Hannes Domani","email":"ssbssa@yahoo.de","username":"ssbssa"},"change_message_id":"1c43eb315e089099b7b5341b27633b1fb177ada4","unresolved":false,"context_lines":[{"line_number":311,"context_line":"    {"},{"line_number":312,"context_line":"        cert_prop +\u003d 5;"},{"line_number":313,"context_line":"        find_param \u003d NULL;"},{"line_number":314,"context_line":"        find_type \u003d CERT_FIND_ANY;"},{"line_number":315,"context_line":"    }"},{"line_number":316,"context_line":"    else"},{"line_number":317,"context_line":"    {"}],"source_content_type":"text/x-csrc","patch_set":1,"id":"79d659be_2fe54731","line":314,"in_reply_to":"fcc24a46_78a084ec","updated":"2024-06-03 14:35:28.000000000","message":"Done","commit_id":"2b1e725d8ed5905abdb0f518cb851a9c814c8f6a"}]}
