)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":1000053,"name":"razvanc","display_name":"Razvan Cojocaru","email":"razvanc@mailbox.org","username":"razvanc"},"change_message_id":"8624160d4895f30fb70169e65caad745eccebfa3","unresolved":true,"context_lines":[{"line_number":7,"context_line":"init: Fix conversion warnings"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Can be separated in mostly two classes of issues:"},{"line_number":10,"context_line":" - Return type of get_random is long, but we ensure that value"},{"line_number":11,"context_line":"   is in range so we can cast it to whatever we need."},{"line_number":12,"context_line":" - Doing MTU match in size_t even though most of the input"},{"line_number":13,"context_line":"   values are int."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":19,"id":"b634d84c_8d885174","line":10,"updated":"2026-08-26 05:25:31.000000000","message":"In crypto.c the return value of `get_random()` is `int64_t` (not `long`). Am I missing something?","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"b9c04bf1281fa5a7e86539be3a0c5c36363dc4f5","unresolved":false,"context_lines":[{"line_number":7,"context_line":"init: Fix conversion warnings"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Can be separated in mostly two classes of issues:"},{"line_number":10,"context_line":" - Return type of get_random is long, but we ensure that value"},{"line_number":11,"context_line":"   is in range so we can cast it to whatever we need."},{"line_number":12,"context_line":" - Doing MTU match in size_t even though most of the input"},{"line_number":13,"context_line":"   values are int."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":19,"id":"1038b607_e2084492","line":10,"in_reply_to":"18815376_8c1227a1","updated":"2026-08-26 11:52:44.000000000","message":"Done","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"c1b200419e8c4dccc29fafb77ff0ce280aa6b6a1","unresolved":true,"context_lines":[{"line_number":7,"context_line":"init: Fix conversion warnings"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Can be separated in mostly two classes of issues:"},{"line_number":10,"context_line":" - Return type of get_random is long, but we ensure that value"},{"line_number":11,"context_line":"   is in range so we can cast it to whatever we need."},{"line_number":12,"context_line":" - Doing MTU match in size_t even though most of the input"},{"line_number":13,"context_line":"   values are int."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":19,"id":"18815376_8c1227a1","line":10,"in_reply_to":"b634d84c_8d885174","updated":"2026-08-26 11:06:52.000000000","message":"Yes, you\u0027re missing how old this commit is 😊\n\nThe return type of get_random was changed recently.","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"}],"/PATCHSET_LEVEL":[{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"0acded612b2c4ae01fae6cc4e7975e56ef5890f3","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":1,"id":"90893b1d_b01dc462","updated":"2025-10-10 11:04:33.000000000","message":"I am not happy with this - there\u0027s a number of clear \"positive integer values only\" variables involved that now change to \"int\" (like headroom, tailroom).  I can see that it\u0027s tricky (because ce.*mtu are all \"int\" as well and that change would affect more places).  Not sure whether I have a useful suggestion right now.","commit_id":"21dc6bc38376a79137df03f6226d9479779c8635"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"5d1e6a7319fb4684a7c5e38584f997a31d62f575","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":1,"id":"cb2d054a_88c53f3a","in_reply_to":"13e257ab_2e637cdf","updated":"2026-03-13 16:39:56.000000000","message":"Came up with a compromise?","commit_id":"21dc6bc38376a79137df03f6226d9479779c8635"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"ebf50184ba4db77c3541858560b2dbac96c72adc","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":1,"id":"13e257ab_2e637cdf","in_reply_to":"90893b1d_b01dc462","updated":"2025-10-27 11:52:47.000000000","message":"I have rechecked my changes. I really think this is the best possible code without changing the types of struct frame and struct buffer. Both of which would have widespread repercussions (obviously more for buffer than frame). So I would recommend we go with this for now.","commit_id":"21dc6bc38376a79137df03f6226d9479779c8635"}],"src/openvpn/init.c":[{"author":{"_account_id":1000053,"name":"razvanc","display_name":"Razvan Cojocaru","email":"razvanc@mailbox.org","username":"razvanc"},"change_message_id":"8624160d4895f30fb70169e65caad745eccebfa3","unresolved":true,"context_lines":[{"line_number":476,"context_line":"        int i;"},{"line_number":477,"context_line":"        for (i \u003d l-\u003elen - 1; i \u003e 0; --i)"},{"line_number":478,"context_line":"        {"},{"line_number":479,"context_line":"            const long j \u003d get_random() % (i + 1);"},{"line_number":480,"context_line":"            if (i !\u003d j)"},{"line_number":481,"context_line":"            {"},{"line_number":482,"context_line":"                struct connection_entry *tmp;"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"1b2e3467_cda3bcc1","line":479,"updated":"2026-08-26 05:25:31.000000000","message":"On systems where `int64_t` (which is what `get_random()` really returns) is larger than `long` (which is theoretically possible), this would be a narrowing conversion.","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"6bc383a027a6d464781b306b279120cd79be3ac2","unresolved":false,"context_lines":[{"line_number":476,"context_line":"        int i;"},{"line_number":477,"context_line":"        for (i \u003d l-\u003elen - 1; i \u003e 0; --i)"},{"line_number":478,"context_line":"        {"},{"line_number":479,"context_line":"            const long j \u003d get_random() % (i + 1);"},{"line_number":480,"context_line":"            if (i !\u003d j)"},{"line_number":481,"context_line":"            {"},{"line_number":482,"context_line":"                struct connection_entry *tmp;"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"ded92b20_f010bc69","line":479,"in_reply_to":"1b2e3467_cda3bcc1","updated":"2026-08-26 11:52:23.000000000","message":"Done","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000053,"name":"razvanc","display_name":"Razvan Cojocaru","email":"razvanc@mailbox.org","username":"razvanc"},"change_message_id":"8624160d4895f30fb70169e65caad745eccebfa3","unresolved":true,"context_lines":[{"line_number":2865,"context_line":""},{"line_number":2866,"context_line":"    if (mtu \u003c TUN_MTU_MIN)"},{"line_number":2867,"context_line":"    {"},{"line_number":2868,"context_line":"        msg(M_WARN, \"TUN MTU value (%zu) must be at least %u\", mtu, TUN_MTU_MIN);"},{"line_number":2869,"context_line":"        frame_print(\u0026c-\u003ec2.frame, M_FATAL, \"MTU is too small\");"},{"line_number":2870,"context_line":"    }"},{"line_number":2871,"context_line":"    if (mtu \u003e UINT_MAX)"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"8709b5ec_0784e73f","line":2868,"updated":"2026-08-26 05:25:31.000000000","message":"Didn\u0027t `TUN_MTU_MIN` stay `int`?","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"6bc383a027a6d464781b306b279120cd79be3ac2","unresolved":false,"context_lines":[{"line_number":2865,"context_line":""},{"line_number":2866,"context_line":"    if (mtu \u003c TUN_MTU_MIN)"},{"line_number":2867,"context_line":"    {"},{"line_number":2868,"context_line":"        msg(M_WARN, \"TUN MTU value (%zu) must be at least %u\", mtu, TUN_MTU_MIN);"},{"line_number":2869,"context_line":"        frame_print(\u0026c-\u003ec2.frame, M_FATAL, \"MTU is too small\");"},{"line_number":2870,"context_line":"    }"},{"line_number":2871,"context_line":"    if (mtu \u003e UINT_MAX)"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"0abac177_ddf43818","line":2868,"in_reply_to":"8709b5ec_0784e73f","updated":"2026-08-26 11:52:23.000000000","message":"Done","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000053,"name":"razvanc","display_name":"Razvan Cojocaru","email":"razvanc@mailbox.org","username":"razvanc"},"change_message_id":"8624160d4895f30fb70169e65caad745eccebfa3","unresolved":true,"context_lines":[{"line_number":2872,"context_line":"    {"},{"line_number":2873,"context_line":"        mtu \u003d UINT_MAX;"},{"line_number":2874,"context_line":"    }"},{"line_number":2875,"context_line":"    return (unsigned int)mtu;"},{"line_number":2876,"context_line":"}"},{"line_number":2877,"context_line":""},{"line_number":2878,"context_line":"/*"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"5a083aa3_5ac86eec","line":2875,"updated":"2026-08-26 05:25:31.000000000","message":"`frame_finalize_options()` calls `get_frame_mtu()` and puts the return value in a plain `int` (`frame-\u003etun_mtu`).\n\nIf the clamp above occurs, then I think that will make `frame-\u003etun_mtu` `-1`.","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"6bc383a027a6d464781b306b279120cd79be3ac2","unresolved":false,"context_lines":[{"line_number":2872,"context_line":"    {"},{"line_number":2873,"context_line":"        mtu \u003d UINT_MAX;"},{"line_number":2874,"context_line":"    }"},{"line_number":2875,"context_line":"    return (unsigned int)mtu;"},{"line_number":2876,"context_line":"}"},{"line_number":2877,"context_line":""},{"line_number":2878,"context_line":"/*"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"53d215a9_4e3811ea","line":2875,"in_reply_to":"5a083aa3_5ac86eec","updated":"2026-08-26 11:52:23.000000000","message":"Done","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000053,"name":"razvanc","display_name":"Razvan Cojocaru","email":"razvanc@mailbox.org","username":"razvanc"},"change_message_id":"8624160d4895f30fb70169e65caad745eccebfa3","unresolved":true,"context_lines":[{"line_number":2902,"context_line":""},{"line_number":2903,"context_line":"    /* we need to be also large enough to hold larger control channel packets"},{"line_number":2904,"context_line":"     * if configured */"},{"line_number":2905,"context_line":"    payload_size \u003d max_int(payload_size, o-\u003ece.tls_mtu);"},{"line_number":2906,"context_line":""},{"line_number":2907,"context_line":"    /* The extra tun needs to be added to the payload size */"},{"line_number":2908,"context_line":"    if (o-\u003ece.tun_mtu_defined)"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"d9a9b82d_20f14b0a","line":2905,"updated":"2026-08-26 05:25:31.000000000","message":"Should this be `max_uint()` now?","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"},{"author":{"_account_id":1000001,"name":"flichtenheld","display_name":"Frank Lichtenheld","email":"frank@lichtenheld.com","username":"flichtenheld","status":"OpenVPN Inc."},"change_message_id":"6bc383a027a6d464781b306b279120cd79be3ac2","unresolved":false,"context_lines":[{"line_number":2902,"context_line":""},{"line_number":2903,"context_line":"    /* we need to be also large enough to hold larger control channel packets"},{"line_number":2904,"context_line":"     * if configured */"},{"line_number":2905,"context_line":"    payload_size \u003d max_int(payload_size, o-\u003ece.tls_mtu);"},{"line_number":2906,"context_line":""},{"line_number":2907,"context_line":"    /* The extra tun needs to be added to the payload size */"},{"line_number":2908,"context_line":"    if (o-\u003ece.tun_mtu_defined)"}],"source_content_type":"text/x-csrc","patch_set":19,"id":"baaa181d_0575fb2a","line":2905,"in_reply_to":"d9a9b82d_20f14b0a","updated":"2026-08-26 11:52:23.000000000","message":"Done","commit_id":"27a30f12ef7b9a1d4b225c948d0444472aa5dd1c"}]}
