From: "flichtenheld (Code Review)"
Date: Wed, 5 Mar 2025 10:47:07 +0000
In-Reply-To:
References:
Reply-To: frank@...2641..., arne-openvpn@...1227..., heiko@...515...,
openvpn-devel@lists.sourceforge.net
Message-ID:
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Content-Disposition: inline
Content-Type: multipart/alternative; boundary="s9l1+24/L+4="; charset=UTF-8
Subject: [Openvpn-devel] [L] Change in openvpn[master]: dns: apply settings
via script on unixoid systems
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
To: d12fk
Cc: plaisthos , openvpn-devel
--s9l1+24/L+4=
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/+/838?usp=3Demail )
Change subject: dns: apply settings via script on unixoid systems
......................................................................
Patch Set 9: Code-Review-2
(8 comments)
Patchset:
PS9:
You broke it
File distro/dns-scripts/systemd-dns-updown.sh:
http://gerrit.openvpn.net/c/openvpn/+/838/comment/57d1206f_56136b77 :
PS7, Line 91: [[ "$(readlink /etc/resolv.conf)" =3D~ systemd ]] || retu=
rn 1
> In that case, yeah. [=E2=80=A6]
Done
File distro/dns-scripts/systemd-dns-updown.sh:
http://gerrit.openvpn.net/c/openvpn/+/838/comment/4b946c0f_aa2c619b :
PS9, Line 75: "$
Maybe we could add a comment here like: "Add as a routing-only domain (~ pr=
efix) unless already configured as a search domain". Sure, this is document=
ed in systemd documentation, but unless you're intimately familiar with tha=
t this code just looks like gibberish.
http://gerrit.openvpn.net/c/openvpn/+/838/comment/80d52a50_87e35eb1 :
PS9, Line 75: =3D~
This broken now. If this matches it does continue but it does not increase =
"i" so it is an endless loop.
http://gerrit.openvpn.net/c/openvpn/+/838/comment/1795ad88_bac2fb33 :
PS9, Line 116: [ -n "${!transport_var}" -a "${!transport_var}" =3D =
"DoH" ] || break
I think this line could use a comment like "skip DoH dns entries", otherwis=
e it takes a while to understand what this does.
File doc/man-sections/script-options.rst:
http://gerrit.openvpn.net/c/openvpn/+/838/comment/ebb56b30_2366159f :
PS9, Line 258: environment values will be passed to ``--up`` and ``--down=
`` if no ``--dns``
This sentence is too complicated. After reading it I'm now more confused th=
an before how --dhcp-option and --dns interact.
File src/openvpn/options.c:
http://gerrit.openvpn.net/c/openvpn/+/838/comment/39eeba0b_9ae2c8e3 :
PS7, Line 8045: else if (streq(p[0], "dns-script") && p[1])
> Actually missed pushing the doc commit the whole time, thanks for pointin=
g it out.
Done
File src/openvpn/options.c:
http://gerrit.openvpn.net/c/openvpn/+/838/comment/8ee3982a_93d7f782 :
PS9, Line 531: "--dns-script cmd : Run cmd as user defined dns configur=
ation script\n"
Would change this to `--dns-script disable|cmd`
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/838?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: Ifbe4ffb44d3bfcaa50adb38cacb3436fcdc71b10
Gerrit-Change-Number: 838
Gerrit-PatchSet: 9
Gerrit-Owner: d12fk
Gerrit-Reviewer: flichtenheld
Gerrit-Reviewer: plaisthos
Gerrit-CC: openvpn-devel
Gerrit-Attention: plaisthos
Gerrit-Attention: d12fk
Gerrit-Comment-Date: Wed, 05 Mar 2025 10:47:07 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: flichtenheld
Comment-In-Reply-To: d12fk
Gerrit-MessageType: comment
--s9l1+24/L+4=
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Attention is currently required from: d12fk, plaisthos.
Patch set 9:Code-Review -2=
Vi=
ew Change
8 comments:
Patchset:
File distro/dns-scripts/systemd-dns-updown.sh:
Patch Set #7, Line 91=
: [[ "$(readli=
nk /etc/resolv.conf)" =3D~ systemd ]] || return 1
In that case, yeah. [=E2=80=A6]
Done
File distro/dns-scripts/systemd-dns-updown.sh:
Patch Set #9, Line 75: "$
Maybe we could add a co=
mment here like: "Add as a routing-only domain (~ prefix) unless alrea=
dy configured as a search domain". Sure, this is documented in systemd=
documentation, but unless you're intimately familiar with that this co=
de just looks like gibberish.
Patch Set #9, Line 75: <=
code style=3D"font-family:monospace,monospace">=3D~
This broken now. If this matc=
hes it does continue but it does not increase "i" so it is an end=
less loop.
Patch Set #9, Line 116: [ -n "${!transport_var}" -=
a "${!transport_var}" =3D "DoH" ] || break
I think this line =
could use a comment like "skip DoH dns entries", otherwise it tak=
es a while to understand what this does.
File doc/man-sections/script-options.rst:
Patch Set #9, Line 258: =
environment values will b=
e passed to ``--up`` and ``--down`` if no ``--dns``
This sentence is too complica=
ted. After reading it I'm now more confused than before how --dhcp-opti=
on and --dns interact.
File src/openvpn/options.c:
Done
File src/openvpn/options.c:
Patch Set #9, Line 531: "--dns-script cmd : Run cmd a=
s user defined dns configuration script\n"
Would change this to `--dns-scrip=
t disable|cmd`
To view, visit change 838. To unsubscri=
be, or for help writing mail filters, visit settings.
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ifbe4ffb44d3bfcaa50adb38cacb=
3436fcdc71b10
Gerrit-Change-Number: 838
Gerrit-PatchSet: 9
Gerrit-Owner: d12fk <heiko@...515...> =
div>
Gerrit-Reviewer: flichtenheld <frank@...2716...=
1...>
Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...=
.1227...>
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: Wed, 05 Mar 2025 10:47:07=
+0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: flichtenheld <frank@...1186...=
.2641...>
Comment-In-Reply-To: d12fk <heiko@...515...=
>
Gerrit-MessageType: comment
--s9l1+24/L+4=--