From: "cron2 (Code Review)"
Date: Thu, 16 Oct 2025 10:46:58 +0000
In-Reply-To:
References:
Reply-To: gert@...1296..., arne-openvpn@...1227...,
openvpn-devel@lists.sourceforge.net, frank@...2641...
Message-ID:
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Content-Disposition: inline
Content-Type: multipart/alternative; boundary="MOm/UkjVV70="; charset=UTF-8
Subject: [Openvpn-devel] [XS] Change in openvpn[master]: init: Fix
datav2_enabled check in options import
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
To: flichtenheld , plaisthos
Cc: openvpn-devel
--MOm/UkjVV70=
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
cron2 has uploaded a new patch set (#2) to the change originally created by=
flichtenheld. ( http://gerrit.openvpn.net/c/openvpn/+/1273?usp=3Demail )
The following approvals got outdated and were removed:
Code-Review+2 by plaisthos
Change subject: init: Fix datav2_enabled check in options import
......................................................................
init: Fix datav2_enabled check in options import
peer_id is unsigned, so the previous check was partly
useless. Instead check use_peer_id.
Change-Id: Ia713a2ecfcad7032863867630a0c306ff9f90385
Signed-off-by: Frank Lichtenheld
Acked-by: Arne Schwabe
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1273
Message-Id: <20251016103308.4685-1-gert@...1296...>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg33=
365.html
Signed-off-by: Gert Doering
---
M src/openvpn/init.c
1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/73/1273/2
diff --git a/src/openvpn/init.c b/src/openvpn/init.c
index aaa0573..aa2611d 100644
--- a/src/openvpn/init.c
+++ b/src/openvpn/init.c
@@ -2728,8 +2728,8 @@
/* Ensure that for epoch data format is only enabled if also data v2
* is enabled */
- bool epoch_data =3D (c->options.imported_protocol_flags & CO_EPOCH_DAT=
A_KEY_FORMAT);
- bool datav2_enabled =3D (c->options.peer_id >=3D 0 && c->options.peer_=
id < MAX_PEER_ID);
+ bool epoch_data =3D c->options.imported_protocol_flags & CO_EPOCH_DATA=
_KEY_FORMAT;
+ bool datav2_enabled =3D c->options.use_peer_id && c->options.peer_id <=
MAX_PEER_ID;
if (epoch_data && !datav2_enabled)
{
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1273?usp=3Demail
To unsubscribe, or for help writing mail filters, visit http://gerrit.openv=
pn.net/settings?usp=3Demail
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ia713a2ecfcad7032863867630a0c306ff9f90385
Gerrit-Change-Number: 1273
Gerrit-PatchSet: 2
Gerrit-Owner: flichtenheld
Gerrit-Reviewer: plaisthos
Gerrit-CC: openvpn-devel
--MOm/UkjVV70=
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
cron2 upl=
oaded patch set #2 to the change originally created by flichtenhel=
d.
View Change
The following approvals got outdated and were remove=
d:
Code-Review+2 by plaisthos
init: Fix datav2_enabled check =
in options import
peer_id is unsigned, so the previous check was par=
tly
useless. Instead check use_peer_id.
Change-Id: Ia713a2ecfcad7=
032863867630a0c306ff9f90385
Signed-off-by: Frank Lichtenheld <frank@...220...=
..2641...>
Acked-by: Arne Schwabe <arne-openvpn@...1227...>
=
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1273
Message-Id: <=
20251016103308.4685-1-gert@...1296...>
URL: https://www.mail-archive.=
com/openvpn-devel@lists.sourceforge.net/msg33365.html
Signed-off-by: Ger=
t Doering <gert@...1296...>
---
M src/openvpn/init.c
1 file =
changed, 2 insertions(+), 2 deletions(-)
git pul=
l ssh://gerrit.openvpn.net:29418/openvpn refs/changes/73/1273/2
dif=
f --git a/src/openvpn/init.c b/src/openvpn/init.c
index aaa=
0573..aa2611d 100644
--- a/src/openvpn/init.c
+++ b/src/openvpn/init.c
@@ -2728,8 +2728,8 @@
/* Ensure that for epoch data format is only =
enabled if also data v2
* is enabled */
- bool epoch_data =3D (c->opti=
ons.imported_protocol_flags & CO_EPOCH_DATA_KEY_FORMAT);
- bool datav2_enabled =3D (c->o=
ptions.peer_id >=3D 0 && c->options.peer_id < MAX_PEER_ID)=
;
+ bool epoch_dat=
a =3D c->options.imported_protocol_flags & CO_EPOCH_DATA_KEY_FORMAT;=
+ bool datav2_ena=
bled =3D c->options.use_peer_id && c->options.peer_id < MA=
X_PEER_ID;
if (epoch_data &&=
!datav2_enabled)
{
<=
p>To view, visit change 1273. To unsubscribe, or for help writing mail filters=
, visit settings=
.
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ia713a2ecfcad7032863867630a0=
c306ff9f90385
Gerrit-Change-Number: 1273
Gerrit-PatchSet: 2
Gerrit-Owner: flichtenheld <frank@...2723...=
.>
Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...=
.1227...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...=
ts.sourceforge.net>
=
--MOm/UkjVV70=--