From: "flichtenheld (Code Review)" Date: Tue, 9 Jan 2024 09:15:29 +0000 In-Reply-To: References: Reply-To: frank@...2641..., arne-openvpn@...1227..., heiko@...515..., openvpn-devel@lists.sourceforge.net, gert@...1296... Message-ID: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="wd3T3nvubbc="; charset=UTF-8 Subject: [Openvpn-devel] [L] Change in openvpn[master]: Windows: enforce 'block-local' with WFP filters List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: d12fk Cc: cron2 , plaisthos , openvpn-devel --wd3T3nvubbc= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Attention is currently required from: d12fk, plaisthos. flichtenheld has posted comments on this change. ( http://gerrit.openvpn.ne= t/c/openvpn/+/489?usp=3Demail ) Change subject: Windows: enforce 'block-local' with WFP filters ...................................................................... Patch Set 1: Code-Review-1 (9 comments) File doc/man-sections/vpn-network-options.rst: http://gerrit.openvpn.net/c/openvpn/+/489/comment/fae460bf_083f3462 : PS1, Line 357: Push this flag to defend against the TunnelCrack attac= ks. Should explain a bit more what this protects against. A reference to Tunnel= Crack is fine but the documentation should be understandable without lookin= g it up. File src/openvpn/init.c: http://gerrit.openvpn.net/c/openvpn/+/489/comment/c60f4d43_2e7f9790 : PS1, Line 1971: /* Fortify 'redirect-gateway block-local' with fire= wall rules? */ Since this hunk and the previous are completely identical I would move them= to a separate function. 12 lines are definitely worth it IMHO. File src/openvpn/route.h: http://gerrit.openvpn.net/c/openvpn/+/489/comment/703fcdb5_6ee704b9 : PS1, Line 248: * is connected. This definatly returns false when not redir= ecting the gateway Typo "definatly" File src/openvpn/route.c: http://gerrit.openvpn.net/c/openvpn/+/489/comment/39e95055_e284408d : PS1, Line 612: size_t i; no reason to leave that on its own line File src/openvpn/wfp_block.c: http://gerrit.openvpn.net/c/openvpn/+/489/comment/d821e3e7_d0986f52 : PS1, Line 167: * Block outgoing port 53 traffic except for "port 53" needs to be changed to reflect the new functionality http://gerrit.openvpn.net/c/openvpn/+/489/comment/81797d0e_701d2e70 : PS1, Line 197: FWPM_FILTER_CONDITION0 Condition[2]; Why remove the "=3D {0}" here? http://gerrit.openvpn.net/c/openvpn/+/489/comment/d1a0883e_d9fb0c63 : PS1, Line 294: /* Third filter. Block IPv4 to port 53 or all besided lo= opback. */ "besides"? Or maybe "except"? http://gerrit.openvpn.net/c/openvpn/+/489/comment/919ec205_02180481 : PS1, Line 303: /* Forth filter. Block IPv6 to port 53 or all besides lo= opback */ "Fourth" File src/openvpn/win32.c: http://gerrit.openvpn.net/c/openvpn/+/489/comment/8c406c41_df81902d : PS1, Line 1225: if (ret =3D=3D false) Simplify to "!win_get_exe_path(openvpnpath, _countof(openvpnpath))" -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/489?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: Ic9bf797bfc7e2d471998a84cb0f071db3e4832ba Gerrit-Change-Number: 489 Gerrit-PatchSet: 1 Gerrit-Owner: d12fk Gerrit-Reviewer: flichtenheld Gerrit-Reviewer: plaisthos Gerrit-CC: cron2 Gerrit-CC: openvpn-devel Gerrit-Attention: plaisthos Gerrit-Attention: d12fk Gerrit-Comment-Date: Tue, 09 Jan 2024 09:15:29 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: Yes Gerrit-MessageType: comment --wd3T3nvubbc= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Attention is currently required from: d12fk, plaisthos.

Patch set 1:Code-Review -1=

Vi= ew Change

9 comments:

  • File doc/man-sections/vpn-netwo= rk-options.rst:

    • Pa= tch Set #1, Line 357: = Push this flag to defend against the TunnelCrack attacks.

      Should explain a b= it more what this protects against. A reference to TunnelCrack is fine but = the documentation should be understandable without looking it up.

    • <= /ul>
    • File src/openvpn/init.c:

      • Patch Set #1, Line 1= 971: /* Fortify= 'redirect-gateway block-local' with firewall rules? */

        <= p style=3D"white-space: pre-wrap; word-wrap: break-word;">Since this hunk a= nd the previous are completely identical I would move them to a separate fu= nction. 12 lines are definitely worth it IMHO.

    • File src/openvpn/route.h:

      • =

        Patch Set #1, Line 248: * is connected. This definatly retu= rns false when not redirecting the gateway

        Typo "definatly"

      • File src/openvpn/route.c:

      • File src/openvpn/wfp_block.c:

        • Patch Set #1, Line 167: * Block outgoing port 53 traffic except for<= /p>

          "port 53= " needs to be changed to reflect the new functionality

        • Patch Set #1, Line 197: FWPM_FILTER_CONDITION0 Condition[2];

          Why remove the "=3D {0}" he= re?

        • Patch Set #1, Line 294: /* Third filter. Block IPv4 to port 53 or all bes= ided loopback. */

          "besides"? Or maybe "except"?

        • <= a href=3D"http://gerrit.openvpn.net/c/openvpn/+/489/comment/919ec205_021804= 81">Patch Set #1, Line 303: /* Forth filter. Block IPv6 to port 53 or all besides loopback */<= /code>

          "= Fourth"

      • File= src/openvpn/win32.c:

        • Patch Set #1, Line 1225: if (ret =3D=3D false)

          Simplify to "!win_get_exe_path(openvpnpath, _= countof(openvpnpath))"

      To view, visit change 489.= To unsubscribe, or for help writing mail filters, visit settings.

      Gerrit-Project: openvpn
      Gerrit-Branch: master
      Gerrit-Change-Id: Ic9bf797bfc7e2d471998a84cb0f= 071db3e4832ba
      Gerrit-Change-Number: 489
      Gerrit-PatchSet: 1
      Gerrit-Owner: d12fk <heiko@...515...>
      Gerrit-Reviewer: flichtenheld <frank@...2716...= 1...>
      Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...= .1227...>
      Gerrit-CC: cron2 <gert@...1296...>
      Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
      Gerrit-Attention: plaisthos <arne-openvpn@...220...= ..1227...>
      Gerrit-Attention: d12fk <heiko@...515...>= ;
      Gerrit-Comment-Date: Tue, 09 Jan 2024 09:15:29= +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      Gerrit-MessageType: comment
      --wd3T3nvubbc=--