From: "cron2 (Code Review)" Date: Thu, 30 Oct 2025 20:58:39 +0000 In-Reply-To: References: Reply-To: gert@...1296..., arne-openvpn@...1227..., openvpn-devel@lists.sourceforge.net, frank@...2641... Message-ID: <0255953b50c2714d660ce071e9b6c69fdd38f36e-HTML@...2715...> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="or1Est+nOSc="; charset=UTF-8 Subject: [Openvpn-devel] [XS] Change in openvpn[master]: fix key_state_gen_auth_control_files probably checking file creation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: plaisthos Cc: flichtenheld , openvpn-devel --or1Est+nOSc= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable cron2 has submitted this change. ( http://gerrit.openvpn.net/c/openvpn/+/13= 27?usp=3Demail ) Change subject: fix key_state_gen_auth_control_files probably checking file= creation ...................................................................... fix key_state_gen_auth_control_files probably checking file creation When the auth_failed_reason_file was added, it was forgotten to also add it to the conditions that determine if the file creation was successful. Reported-by: Joshua Rogers Found-by: ZeroPath (https://zeropath.com/) Change-Id: I94d2bdd234a1c416b78924d044bf7e57f1bed8c4 Signed-off-by: Arne Schwabe Acked-by: Gert Doering Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1327 Message-Id: <20251030193940.1295-1-gert@...1296...> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg34= 067.html Signed-off-by: Gert Doering --- M src/openvpn/ssl_verify.c 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/openvpn/ssl_verify.c b/src/openvpn/ssl_verify.c index 993d22c..a16f5fa 100644 --- a/src/openvpn/ssl_verify.c +++ b/src/openvpn/ssl_verify.c @@ -992,7 +992,7 @@ const char *apf =3D platform_create_temp_file(opt->tmp_dir, "apf", &gc= ); const char *afr =3D platform_create_temp_file(opt->tmp_dir, "afr", &gc= ); - if (acf && apf) + if (acf && apf && afr) { ads->auth_control_file =3D string_alloc(acf, NULL); ads->auth_pending_file =3D string_alloc(apf, NULL); @@ -1004,7 +1004,7 @@ } gc_free(&gc); - return (acf && apf); + return (acf && apf && afr); } /** -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1327?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings?usp=3Demail Gerrit-MessageType: merged Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: I94d2bdd234a1c416b78924d044bf7e57f1bed8c4 Gerrit-Change-Number: 1327 Gerrit-PatchSet: 2 Gerrit-Owner: plaisthos Gerrit-Reviewer: cron2 Gerrit-Reviewer: flichtenheld Gerrit-CC: openvpn-devel --or1Est+nOSc= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

cron2 sub= mitted this change.

View Change

fix key_state_gen_auth_control_files probably ch=
ecking file creation

When the auth_failed_reason_file was added, it = was forgotten to also add it
to the conditions that determine if the fil= e creation was successful.

Reported-by: Joshua Rogers <contact@...1186...= .2949...>
Found-by: ZeroPath (https://zeropath.com/)
Change-Id: I9= 4d2bdd234a1c416b78924d044bf7e57f1bed8c4
Signed-off-by: Arne Schwabe <= arne@...1227...>
Acked-by: Gert Doering <gert@...1296...>
Ge= rrit URL: https://gerrit.openvpn.net/c/openvpn/+/1327
Message-Id: <20= 251030193940.1295-1-gert@...1296...>
URL: https://www.mail-archive.co= m/openvpn-devel@lists.sourceforge.net/msg34067.html
Signed-off-by: Gert = Doering <gert@...1296...>
---
M src/openvpn/ssl_verify.c
1 f= ile changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/openvpn/ssl_verify.c b/src/openvpn/ssl_verify.c<=
br>index 993d22c..a16f5fa 100644
--- a/src/openvpn/ss= l_verify.c
+++ b/src/openvpn/ssl_verify.c
@= @ -992,7 +992,7 @@
const char *apf =3D platform_create= _temp_file(opt->tmp_dir, "apf", &gc);
= const char *afr =3D platform_create_temp_file(opt->tmp_dir, "afr&q= uot;, &gc);

- if (acf && apf)
+ if (acf && apf && afr)
{
ads->auth_control_file =3D string_al= loc(acf, NULL);
ads->auth_pending_file =3D stri= ng_alloc(apf, NULL);
@@ -1004,7 +1004,7 @@
= }

gc_free(&gc);
<= span style=3D"color: hsl(0, 100%, 40%);">- return (acf && apf);<= /span>
+ return (acf &= ;& apf && afr);
}

= /**

To view, visit change 1327. To u= nsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I94d2bdd234a1c416b78924d044b= f7e57f1bed8c4
Gerrit-Change-Number: 1327
Gerrit-PatchSet: 2
Gerrit-Owner: plaisthos <arne-openvpn@...1711...= 27...>
Gerrit-Reviewer: cron2 <gert@...1296...>=
Gerrit-Reviewer: flichtenheld <frank@...2716...= 1...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
= --or1Est+nOSc=--