)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"e535f96b24b5b4abbceee6c0e62abb3d5b84dddf","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"b7a1b9a7_b8e26748","updated":"2024-03-25 01:15:22.000000000","message":"as far as I understand we can\u0027t restore the broken behavior unless we specify that macro or we switch to __snprintf. Both can\u0027t happen accidentally, therefore it\u0027s not possible introduce the buggy behavior by mistake.\nIn the worst case the code won\u0027t compile on old MS systems (pre-VS2015/VC14).","commit_id":"7370194dc6e9d3f13dca37814b19dcd16cce2ced"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"7f2eae44a57e1c9fb8fbe78765462f135308af92","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"7467c388_375f76b3","updated":"2024-03-25 11:14:07.000000000","message":"not -Werror clean yet","commit_id":"7370194dc6e9d3f13dca37814b19dcd16cce2ced"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"030e46e8d57edd744de5187cf6b22e6e636b0e96","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"f75f11f5_ca5b64a4","updated":"2024-04-08 08:22:27.000000000","message":"Unfortunately, this fails -Werror msbuild builds now, see comment in interactive.c","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"e482ee922a6ed74d8587e2f73195653fc11aef75","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"a1f16716_40d44646","updated":"2024-04-08 06:59:00.000000000","message":"closing some comments as they were commenting code that did not really change with this patch...\n\nThe only remaining comment is about a comment in the UT which is a bit cryptic. Maybe that can be adjusted on the fly.\n\nOther than that, the code looks good to me \u003c3","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"b926fc73dded566d0ca6a2cc1db0843feff402b3","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"fed05be0_acc064aa","updated":"2024-03-27 10:48:48.000000000","message":"some nit picks below..","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"}],"src/openvpn/proxy.c":[{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"b926fc73dded566d0ca6a2cc1db0843feff402b3","unresolved":true,"context_lines":[{"line_number":959,"context_line":"                                    response,"},{"line_number":960,"context_line":"                                    opaque_kv"},{"line_number":961,"context_line":"                                    );"},{"line_number":962,"context_line":"                if (sret \u003e\u003d sizeof(buf))"},{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"d2c89116_22dbc48e","line":962,"updated":"2024-03-27 10:48:48.000000000","message":"if this can truly happen, does it mean that the buffer is undersized compared to the size of all variables we are putting together?\n\nTherefore, wouldn\u0027t it make more sense to extend the size of the buffer to ensure that no matter what we save in those variables, we will always be able to create the HTTP header?\n\nOr there is a limit with the HTTP header that we have to deal with?\n\nMy concern is that we are not preventing people from filling those variables as they please, but we will then fail to put them together for no good reason.\n\ndoes it make sense?","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"e482ee922a6ed74d8587e2f73195653fc11aef75","unresolved":false,"context_lines":[{"line_number":959,"context_line":"                                    response,"},{"line_number":960,"context_line":"                                    opaque_kv"},{"line_number":961,"context_line":"                                    );"},{"line_number":962,"context_line":"                if (sret \u003e\u003d sizeof(buf))"},{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"f78adfbf_ca231ac7","line":962,"in_reply_to":"d2c89116_22dbc48e","updated":"2024-04-08 06:59:00.000000000","message":"Done","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"030e46e8d57edd744de5187cf6b22e6e636b0e96","unresolved":false,"context_lines":[{"line_number":959,"context_line":"                                    response,"},{"line_number":960,"context_line":"                                    opaque_kv"},{"line_number":961,"context_line":"                                    );"},{"line_number":962,"context_line":"                if (sret \u003e\u003d sizeof(buf))"},{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"b37effa6_d450b13a","line":962,"in_reply_to":"d2c89116_22dbc48e","updated":"2024-04-08 08:22:27.000000000","message":"this code is not part of the actual patchset, but a gerrit artefact due to rebasing.  *This* patchset only replaces openvpn_snprintf() with snprintf().","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"af31415528c2be476303a77f921f82b3b8471dde","unresolved":true,"context_lines":[{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"},{"line_number":966,"context_line":""},{"line_number":967,"context_line":"                msg(D_PROXY, \"Send to HTTP proxy: \u0027%s\u0027\", buf);"},{"line_number":968,"context_line":"                if (!send_line_crlf(sd, buf))"},{"line_number":969,"context_line":"                {"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"44a4b5a4_ab3ddf72","line":966,"updated":"2024-05-03 15:49:05.000000000","message":"Why this spurious change?","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"c544ca439d111604dd6d09d6db22264ccb56d646","unresolved":true,"context_lines":[{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"},{"line_number":966,"context_line":""},{"line_number":967,"context_line":"                msg(D_PROXY, \"Send to HTTP proxy: \u0027%s\u0027\", buf);"},{"line_number":968,"context_line":"                if (!send_line_crlf(sd, buf))"},{"line_number":969,"context_line":"                {"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"aac61c1c_be6f9120","line":966,"in_reply_to":"44a4b5a4_ab3ddf72","updated":"2024-05-03 16:44:39.000000000","message":"What do you mean with spurious? It changes openvpn_snprintf to snprintf","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"1fef64a6886b8c1e3a0791b291219763c8a67228","unresolved":true,"context_lines":[{"line_number":963,"context_line":"                {"},{"line_number":964,"context_line":"                    goto error;"},{"line_number":965,"context_line":"                }"},{"line_number":966,"context_line":""},{"line_number":967,"context_line":"                msg(D_PROXY, \"Send to HTTP proxy: \u0027%s\u0027\", buf);"},{"line_number":968,"context_line":"                if (!send_line_crlf(sd, buf))"},{"line_number":969,"context_line":"                {"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"1cc5661d_bc0d1f81","line":966,"in_reply_to":"aac61c1c_be6f9120","updated":"2024-05-06 10:00:53.000000000","message":"Sorry, seems I was too brief. I meant the empty line you inserted here. Either way, not important.","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"}],"src/openvpn/socks.c":[{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"b926fc73dded566d0ca6a2cc1db0843feff402b3","unresolved":true,"context_lines":[{"line_number":111,"context_line":"    }"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"    int sret \u003d snprintf(to_send, sizeof(to_send), \"\\x01%c%s%c%s\","},{"line_number":114,"context_line":"                        (int) strlen(creds.username), creds.username,"},{"line_number":115,"context_line":"                        (int) strlen(creds.password), creds.password);"},{"line_number":116,"context_line":"    ASSERT(sret \u003c\u003d sizeof(to_send));"},{"line_number":117,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":2,"id":"8bdf0e3c_8356c931","line":114,"updated":"2024-03-27 10:48:48.000000000","message":"normally we don\u0027t put a paceb etween the cast and the variable name.\nThis comments applies to all other casts below","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"e482ee922a6ed74d8587e2f73195653fc11aef75","unresolved":false,"context_lines":[{"line_number":111,"context_line":"    }"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"    int sret \u003d snprintf(to_send, sizeof(to_send), \"\\x01%c%s%c%s\","},{"line_number":114,"context_line":"                        (int) strlen(creds.username), creds.username,"},{"line_number":115,"context_line":"                        (int) strlen(creds.password), creds.password);"},{"line_number":116,"context_line":"    ASSERT(sret \u003c\u003d sizeof(to_send));"},{"line_number":117,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":2,"id":"0f6508ea_b21108c0","line":114,"in_reply_to":"8bdf0e3c_8356c931","updated":"2024-04-08 06:59:00.000000000","message":"Done","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"b926fc73dded566d0ca6a2cc1db0843feff402b3","unresolved":true,"context_lines":[{"line_number":113,"context_line":"    int sret \u003d snprintf(to_send, sizeof(to_send), \"\\x01%c%s%c%s\","},{"line_number":114,"context_line":"                        (int) strlen(creds.username), creds.username,"},{"line_number":115,"context_line":"                        (int) strlen(creds.password), creds.password);"},{"line_number":116,"context_line":"    ASSERT(sret \u003c\u003d sizeof(to_send));"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    size \u003d send(sd, to_send, strlen(to_send), MSG_NOSIGNAL);"},{"line_number":119,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":2,"id":"b417986e_a5f333df","line":116,"updated":"2024-03-27 10:48:48.000000000","message":"why ASSERT here while in other cases we just go to error or cleanup?","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"e482ee922a6ed74d8587e2f73195653fc11aef75","unresolved":false,"context_lines":[{"line_number":113,"context_line":"    int sret \u003d snprintf(to_send, sizeof(to_send), \"\\x01%c%s%c%s\","},{"line_number":114,"context_line":"                        (int) strlen(creds.username), creds.username,"},{"line_number":115,"context_line":"                        (int) strlen(creds.password), creds.password);"},{"line_number":116,"context_line":"    ASSERT(sret \u003c\u003d sizeof(to_send));"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    size \u003d send(sd, to_send, strlen(to_send), MSG_NOSIGNAL);"},{"line_number":119,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":2,"id":"b4ed3e45_e9af3876","line":116,"in_reply_to":"b417986e_a5f333df","updated":"2024-04-08 06:59:00.000000000","message":"Done","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"}],"src/openvpnserv/interactive.c":[{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"030e46e8d57edd744de5187cf6b22e6e636b0e96","unresolved":true,"context_lines":[{"line_number":2004,"context_line":"        goto out;"},{"line_number":2005,"context_line":"    }"},{"line_number":2006,"context_line":"    swprintf(cmdline, cmdline_size, L\"openvpn %ls --msg-channel %\" PRIuPTR,"},{"line_number":2007,"context_line":"             sud.options, svc_pipe);"},{"line_number":2008,"context_line":""},{"line_number":2009,"context_line":"    if (!CreateEnvironmentBlock(\u0026user_env, imp_token, FALSE))"},{"line_number":2010,"context_line":"    {"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"918c9772_0150ba41","line":2007,"updated":"2024-04-08 08:22:27.000000000","message":"This makes GHA msbuild build fails now, with\n\n```\n D:\\a\\openvpn\\openvpn\\src\\openvpnserv\\interactive.c(2006,37): warning C4477: \u0027swprintf\u0027 : format string \u0027%llu\u0027 requires an argument of type \u0027unsigned __int64\u0027, but variadic argument 2 has type \u0027HANDLE\u0027 [D:\\a\\openvpn\\openvpn\\out\\build\\win-amd64-release\\src\\openvpnserv\\openvpnserv.vcxproj]\n ```\n \n so it seems the cast to something-int (`DWORD`?) is needed.","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"128f97e7f321527953e76a49a778b5e0fb793937","unresolved":false,"context_lines":[{"line_number":2004,"context_line":"        goto out;"},{"line_number":2005,"context_line":"    }"},{"line_number":2006,"context_line":"    swprintf(cmdline, cmdline_size, L\"openvpn %ls --msg-channel %\" PRIuPTR,"},{"line_number":2007,"context_line":"             sud.options, svc_pipe);"},{"line_number":2008,"context_line":""},{"line_number":2009,"context_line":"    if (!CreateEnvironmentBlock(\u0026user_env, imp_token, FALSE))"},{"line_number":2010,"context_line":"    {"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"a795b02d_09b66782","line":2007,"in_reply_to":"918c9772_0150ba41","updated":"2024-05-02 17:44:31.000000000","message":"Done","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"}],"tests/unit_tests/openvpn/test_buffer.c":[{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"b926fc73dded566d0ca6a2cc1db0843feff402b3","unresolved":true,"context_lines":[{"line_number":366,"context_line":"     */"},{"line_number":367,"context_line":""},{"line_number":368,"context_line":"    /* Instead of trying to trick the compiler here, disable the warnings"},{"line_number":369,"context_line":"     * for this unit test. We know that are doing this that are truncated"},{"line_number":370,"context_line":"     * and we want to test that */"},{"line_number":371,"context_line":"#if defined(__GNUC__)"},{"line_number":372,"context_line":"/* some clang version do not understand -Wformat-truncation, so ignore the"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"f8c8a505_dbfb9729","line":369,"updated":"2024-03-27 10:48:48.000000000","message":"I think there is some typ0 here.\nMaybe something like: \"We know that results will be truncated and we actually want to test that\".","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"128f97e7f321527953e76a49a778b5e0fb793937","unresolved":false,"context_lines":[{"line_number":366,"context_line":"     */"},{"line_number":367,"context_line":""},{"line_number":368,"context_line":"    /* Instead of trying to trick the compiler here, disable the warnings"},{"line_number":369,"context_line":"     * for this unit test. We know that are doing this that are truncated"},{"line_number":370,"context_line":"     * and we want to test that */"},{"line_number":371,"context_line":"#if defined(__GNUC__)"},{"line_number":372,"context_line":"/* some clang version do not understand -Wformat-truncation, so ignore the"}],"source_content_type":"text/x-csrc","patch_set":2,"id":"f9701207_7c4b904b","line":369,"in_reply_to":"f8c8a505_dbfb9729","updated":"2024-05-02 17:44:31.000000000","message":"Done","commit_id":"54e5d7fe487cc2453c949140f3dff95e819130cc"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"af31415528c2be476303a77f921f82b3b8471dde","unresolved":true,"context_lines":[{"line_number":398,"context_line":""},{"line_number":399,"context_line":"#if defined(__GNUC__)"},{"line_number":400,"context_line":"#if defined(__clang__)"},{"line_number":401,"context_line":"#pragma GCC diagnostic pop"},{"line_number":402,"context_line":"#endif"},{"line_number":403,"context_line":"#pragma GCC diagnostic pop"},{"line_number":404,"context_line":"#endif"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"9f564a6c_9986bda3","line":401,"updated":"2024-05-03 15:49:05.000000000","message":"Should that be \"clang\" instead of \"GCC\"?","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"c544ca439d111604dd6d09d6db22264ccb56d646","unresolved":true,"context_lines":[{"line_number":398,"context_line":""},{"line_number":399,"context_line":"#if defined(__GNUC__)"},{"line_number":400,"context_line":"#if defined(__clang__)"},{"line_number":401,"context_line":"#pragma GCC diagnostic pop"},{"line_number":402,"context_line":"#endif"},{"line_number":403,"context_line":"#pragma GCC diagnostic pop"},{"line_number":404,"context_line":"#endif"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"e325e787_1f2bea7f","line":401,"in_reply_to":"9f564a6c_9986bda3","updated":"2024-05-03 16:44:39.000000000","message":"yeah, although it seems work this way as well. Will fix.","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"},{"author":{"_account_id":1000003,"name":"plaisthos","display_name":"Arne Schwabe","email":"arne-openvpn@rfc2549.org","username":"plaisthos"},"change_message_id":"ea088217c8fd9805efca543f9a0c695c1bba8f2d","unresolved":false,"context_lines":[{"line_number":398,"context_line":""},{"line_number":399,"context_line":"#if defined(__GNUC__)"},{"line_number":400,"context_line":"#if defined(__clang__)"},{"line_number":401,"context_line":"#pragma GCC diagnostic pop"},{"line_number":402,"context_line":"#endif"},{"line_number":403,"context_line":"#pragma GCC diagnostic pop"},{"line_number":404,"context_line":"#endif"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"4a0f4211_d038f0d1","line":401,"in_reply_to":"e325e787_1f2bea7f","updated":"2024-05-03 16:48:06.000000000","message":"Done","commit_id":"85ce1b1d22d792b1e597f698e3f875e24109ac3b"}]}
