summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorYASUOKA Masahiko <yasuoka@cvs.openbsd.org>2024-09-27 00:38:50 +0000
committerYASUOKA Masahiko <yasuoka@cvs.openbsd.org>2024-09-27 00:38:50 +0000
commitc58eb915d2e9949f635194ec88c3f169fe2eef8f (patch)
treebb71d3ec5f520a9e74c1f64bc2f1a65367b74366 /sys
parenta5dc9c055700351e00ff2a2ef81b3e53c236886f (diff)
Previous pipex.c,v 1.155 was broken if the client was not behind a NAT.
ok mvs
Diffstat (limited to 'sys')
-rw-r--r--sys/net/pipex.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/net/pipex.c b/sys/net/pipex.c
index c1bb5a86bcf..a5e0a49540a 100644
--- a/sys/net/pipex.c
+++ b/sys/net/pipex.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pipex.c,v 1.155 2024/07/26 15:45:31 yasuoka Exp $ */
+/* $OpenBSD: pipex.c,v 1.156 2024/09/27 00:38:49 yasuoka Exp $ */
/*-
* Copyright (c) 2009 Internet Initiative Japan Inc.
@@ -2031,7 +2031,8 @@ pipex_l2tp_input(struct mbuf *m0, int off0, struct pipex_session *session,
mtx_enter(&session->pxs_mtx);
l2tp_session = &session->proto.l2tp;
- if (l2tp_session->ipsecflowinfo != ipsecflowinfo) {
+ if (l2tp_session->ipsecflowinfo > 0 &&
+ l2tp_session->ipsecflowinfo != ipsecflowinfo) {
pipex_session_log(session, LOG_DEBUG,
"received message is %s",
(ipsecflowinfo != 0)? "from invalid ipsec flow" :