)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"557c7a34924b904da9ad7b7c928f192bc7c43e99","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"24699f3e_9f415d19","updated":"2025-07-23 18:02:13.000000000","message":"So it has passed the t_server testbed, and also a bit of stare-at-code.\n\nI do want to do more tests - especially float with interesting timings, multiple instances with individual counters (crosstalk...?), peers timing out or being killed from userspace, and so on.","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"d1d7e492_854b1260","updated":"2025-07-23 18:13:35.000000000","message":"more polish needed","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"a6e2b356f0ce8086f38ebe2954d7d7c9c8565df5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"38a680df_5c14cf58","updated":"2025-07-25 17:20:30.000000000","message":"Hah, gotcha\n\n```\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_get_peer_stats_multi\nJul 25 19:18:56 ubuntu2004 tun-udp-p2p-tls-sha256[186220]: dco_do_read\nJul 25 19:18:56 ubuntu2004 tun-udp-p2p-tls-sha256[186220]: ovpn-dco: received netlink message type\u003d31 cmd\u003d11 flags\u003d0000\nJul 25 19:18:56 ubuntu2004 tun-udp-p2p-tls-sha256[186220]: ovpn-dco: ignoring message for foreign ifindex 982\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn-dco: received netlink message type\u003d31 cmd\u003d11 flags\u003d0000\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn-dco: received CMD_PEER_FLOAT_NTF, ifindex: 982, peer-id 2, address: [AF_INET]193.149.48.173:59979\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn-dco: received netlink message type\u003d31 cmd\u003d3 flags\u003d0x0002\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn_handle_peer_multi: parsing message...\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / dco_read_bytes(0): 615704\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / dco_write_bytes(0): 625840\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / tun_read_bytes(0): 562992\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / tun_write_bytes(0): 568872\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn-dco: received netlink message type\u003d31 cmd\u003d3 flags\u003d0x0002\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: ovpn_handle_peer_multi: parsing message...\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / dco_read_bytes(2): 11732\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / dco_write_bytes(2): 11392\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / tun_read_bytes(2): 9256\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_update_peer_stat / tun_write_bytes(2): 9256\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_do_read\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: dco_do_read: netlink reports blocking read - aborting wait\nJul 25 19:18:56 ubuntu2004 tun-udp-p2mp[186147]: peer 2 (cron2-freebsd-tc-amd64) floated from udp6:193.149.48.172:59979 to [AF_INET6]::ffff:193.149.48.173:59979\nJul 25 19:18:57 ubuntu2004 kernel: [294871.134548] tun1: peer 2 floated to 193.149.48.173:59979\n```\n\nthis is precisely the situation that makes the pre-1100 code lose the \"FLOAT!\" message, because it arrives *after* `dco_get_peer_stats_multi()` starts running (or just before, but we do not look at DCO events) and before the actual cmd\u003d3 reply comes in.\n\nGood work!","commit_id":"7c22c9285686c519deed1f036d708070bbd139df"}],"src/openvpn/dco_linux.c":[{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":167,"context_line":"}"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"/**"},{"line_number":170,"context_line":" * Send a prepared netlink message and registers cb as callback if non-null."},{"line_number":171,"context_line":" *"},{"line_number":172,"context_line":" * The method will also free nl_msg"},{"line_number":173,"context_line":" * @param dco       The dco context to use"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"24854dbd_add7b22c","line":170,"updated":"2025-07-23 18:13:35.000000000","message":"this comment needs changing, though... \"and registers cb\"","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":false,"context_lines":[{"line_number":167,"context_line":"}"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"/**"},{"line_number":170,"context_line":" * Send a prepared netlink message and registers cb as callback if non-null."},{"line_number":171,"context_line":" *"},{"line_number":172,"context_line":" * The method will also free nl_msg"},{"line_number":173,"context_line":" * @param dco       The dco context to use"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"b17821a3_854b55f6","line":170,"in_reply_to":"24854dbd_add7b22c","updated":"2025-07-23 21:55:04.000000000","message":"Acknowledged","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":900,"context_line":""},{"line_number":901,"context_line":"    if (!tb_peer[OVPN_A_PEER_ID])"},{"line_number":902,"context_line":"    {"},{"line_number":903,"context_line":"        msg(M_WARN, \"%s: no peer-id provided in reply\", __func__);"},{"line_number":904,"context_line":"        return NL_SKIP;"},{"line_number":905,"context_line":"    }"},{"line_number":906,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":4,"id":"6281b84e_49f7ecd7","line":903,"updated":"2025-07-23 18:13:35.000000000","message":"maybe change the \"reply\" to \"whatever this message type is\", similar to the other \"no peer-id provided\" things?","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":false,"context_lines":[{"line_number":900,"context_line":""},{"line_number":901,"context_line":"    if (!tb_peer[OVPN_A_PEER_ID])"},{"line_number":902,"context_line":"    {"},{"line_number":903,"context_line":"        msg(M_WARN, \"%s: no peer-id provided in reply\", __func__);"},{"line_number":904,"context_line":"        return NL_SKIP;"},{"line_number":905,"context_line":"    }"},{"line_number":906,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":4,"id":"6d73e782_65951dfb","line":903,"in_reply_to":"6281b84e_49f7ecd7","updated":"2025-07-23 21:55:04.000000000","message":"the difference is that here we print the function name, so the context is obvious. In the other messages we only have the \"ovpn-dco\" prefix (because that code was all embedded in ovpn_handle_msg() before this patch).\n\nI think it makes sense to follow your suggestion, but I will also switch to the \"ovpn-dco:\" prefix","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":935,"context_line":""},{"line_number":936,"context_line":"    if (!tb_peer[OVPN_A_PEER_ID])"},{"line_number":937,"context_line":"    {"},{"line_number":938,"context_line":"        msg(M_WARN, \"%s: no peer-id provided in reply\", __func__);"},{"line_number":939,"context_line":"        return NL_SKIP;"},{"line_number":940,"context_line":"    }"},{"line_number":941,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":4,"id":"94873fa3_d40d8bb4","line":938,"updated":"2025-07-23 18:13:35.000000000","message":"as well","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":false,"context_lines":[{"line_number":935,"context_line":""},{"line_number":936,"context_line":"    if (!tb_peer[OVPN_A_PEER_ID])"},{"line_number":937,"context_line":"    {"},{"line_number":938,"context_line":"        msg(M_WARN, \"%s: no peer-id provided in reply\", __func__);"},{"line_number":939,"context_line":"        return NL_SKIP;"},{"line_number":940,"context_line":"    }"},{"line_number":941,"context_line":""}],"source_content_type":"text/x-csrc","patch_set":4,"id":"69bbc8ae_718dd631","line":938,"in_reply_to":"94873fa3_d40d8bb4","updated":"2025-07-23 21:55:04.000000000","message":"Acknowledged","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":948,"context_line":"    }"},{"line_number":949,"context_line":"    else"},{"line_number":950,"context_line":"    {"},{"line_number":951,"context_line":"        struct multi_instance *mi \u003d dco-\u003ec-\u003emulti-\u003einstances[peer_id];"},{"line_number":952,"context_line":"        if (!mi)"},{"line_number":953,"context_line":"        {"},{"line_number":954,"context_line":"            msg(M_WARN, \"%s: received data for a non-existing peer %u\", __func__, peer_id);"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"41388847_81aa443f","line":951,"updated":"2025-07-23 18:13:35.000000000","message":"how can we ever end here?","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":false,"context_lines":[{"line_number":948,"context_line":"    }"},{"line_number":949,"context_line":"    else"},{"line_number":950,"context_line":"    {"},{"line_number":951,"context_line":"        struct multi_instance *mi \u003d dco-\u003ec-\u003emulti-\u003einstances[peer_id];"},{"line_number":952,"context_line":"        if (!mi)"},{"line_number":953,"context_line":"        {"},{"line_number":954,"context_line":"            msg(M_WARN, \"%s: received data for a non-existing peer %u\", __func__, peer_id);"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"c0bbb1b8_731eaf6c","line":951,"in_reply_to":"41388847_81aa443f","updated":"2025-07-23 21:55:04.000000000","message":"check_timeout() for --inactive. In that code path we sadly check each peer one by one and thus we call PEER_GET on each specific peer one by one.","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":1179,"context_line":"            /* this message is part of a peer list dump, hence triggered"},{"line_number":1180,"context_line":"             * by a MP/server instance"},{"line_number":1181,"context_line":"             */"},{"line_number":1182,"context_line":"            if (nlh-\u003enlmsg_flags \u0026 NLM_F_MULTI)"},{"line_number":1183,"context_line":"            {"},{"line_number":1184,"context_line":"                return ovpn_handle_peer_multi(dco, attrs);"},{"line_number":1185,"context_line":"            }"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"5c6b04ae_b5f56bc3","line":1182,"updated":"2025-07-23 18:13:35.000000000","message":"I\u0027m not sure I understand this.  p2mp peer messages are sent multicast, and p2p messages not?  Or what does `NLM_F_MULTI` signal?","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":false,"context_lines":[{"line_number":1179,"context_line":"            /* this message is part of a peer list dump, hence triggered"},{"line_number":1180,"context_line":"             * by a MP/server instance"},{"line_number":1181,"context_line":"             */"},{"line_number":1182,"context_line":"            if (nlh-\u003enlmsg_flags \u0026 NLM_F_MULTI)"},{"line_number":1183,"context_line":"            {"},{"line_number":1184,"context_line":"                return ovpn_handle_peer_multi(dco, attrs);"},{"line_number":1185,"context_line":"            }"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"25f2c886_37016329","line":1182,"in_reply_to":"5c6b04ae_b5f56bc3","updated":"2025-07-23 21:55:04.000000000","message":"hehe!\nCheck: https://elixir.bootlin.com/linux/v6.16-rc6/source/include/uapi/linux/netlink.h#L63\n\nThis flag means this message is part of a set of messages, together forming the actual reply.\nWe get this kind of reply when we issue a PEER_GET with no specific peer-id.\nWhich is what the P2MP code does to fetch the stats.\n\nP2P will never call this because it always query its one specific peer.","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"f58f5435b57f16431986ed8537bec76e83d394ac","unresolved":true,"context_lines":[{"line_number":1186,"context_line":"            else"},{"line_number":1187,"context_line":"            {"},{"line_number":1188,"context_line":"                return ovpn_handle_peer(dco, attrs);"},{"line_number":1189,"context_line":"            }"},{"line_number":1190,"context_line":"        }"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        case OVPN_CMD_PEER_DEL_NTF:"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"a876ff1f_882629d9","line":1189,"updated":"2025-07-23 18:13:35.000000000","message":"I do wonder if this `if()` shouldn\u0027t just look at p-\u003emode?  Since `multi` does not want to deal with MODE_P2P, and _peer() now has extra code to deal with !MODE_P\"P, just check beforehand?","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000002,"name":"cron2","display_name":"Gert Doering","email":"gert@greenie.muc.de","username":"cron2"},"change_message_id":"46cd4dd4aacec241045b3a594744b7f072451326","unresolved":true,"context_lines":[{"line_number":1186,"context_line":"            else"},{"line_number":1187,"context_line":"            {"},{"line_number":1188,"context_line":"                return ovpn_handle_peer(dco, attrs);"},{"line_number":1189,"context_line":"            }"},{"line_number":1190,"context_line":"        }"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        case OVPN_CMD_PEER_DEL_NTF:"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"acf86e82_8c8c0854","line":1189,"in_reply_to":"131162e2_128a7d4a","updated":"2025-07-25 17:04:49.000000000","message":"Now you got me started... if we need to have one function handle both P2P and P2MP modes anyway, why do we need two functions?  They look similar enough that using `ovpn_handle_peer()` for all `OVPN_CMD_PEER_GET` replies might just work (possibly moving the peer-id check inside the P2P clause to avoid having it in the MP path where it\u0027s more like an CANTHAPPEN...)?","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"},{"author":{"_account_id":1000007,"name":"ordex","display_name":"Antonio Quartulli","email":"antonio@mandelbit.com","username":"ordex"},"change_message_id":"bec2f9433a9bb3ccbc100b8f0178fc33aa5db0dd","unresolved":true,"context_lines":[{"line_number":1186,"context_line":"            else"},{"line_number":1187,"context_line":"            {"},{"line_number":1188,"context_line":"                return ovpn_handle_peer(dco, attrs);"},{"line_number":1189,"context_line":"            }"},{"line_number":1190,"context_line":"        }"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        case OVPN_CMD_PEER_DEL_NTF:"}],"source_content_type":"text/x-csrc","patch_set":4,"id":"131162e2_128a7d4a","line":1189,"in_reply_to":"a876ff1f_882629d9","updated":"2025-07-23 21:55:04.000000000","message":"as mentioned above, MODE_MP may still need to call ovpn_handle_peer()","commit_id":"5a3b755f23f963d8b3c0892a799668f4bb7484dc"}]}
