lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZijFmMDST_ksUUnk@hog>
Date: Wed, 24 Apr 2024 10:40:56 +0200
From: Sabrina Dubroca <sd@...asysnail.net>
To: Nicolas Dichtel <nicolas.dichtel@...nd.com>
Cc: antony.antony@...unet.com,
	Steffen Klassert <steffen.klassert@...unet.com>,
	Herbert Xu <herbert@...dor.apana.org.au>, netdev@...r.kernel.org,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	devel@...ux-ipsec.org, Leon Romanovsky <leon@...nel.org>,
	Eyal Birger <eyal.birger@...il.com>
Subject: Re: [PATCH ipsec-next v12 3/4] xfrm: Add dir validation to "in" data
 path lookup

2024-04-23, 17:27:37 +0200, Nicolas Dichtel wrote:
> Le 23/04/2024 à 14:50, Antony Antony a écrit :
> > Introduces validation for the x->dir attribute within the XFRM input
> > data lookup path. If the configured direction does not match the
> > expected direction, input, increment the XfrmInStateDirError counter
> > and drop the packet to ensure data integrity and correct flow handling.
> > 
> > grep -vw 0 /proc/net/xfrm_stat
> > XfrmInStateDirError     	1
> > 
> > Signed-off-by: Antony Antony <antony.antony@...unet.com>
> > ---
> > v11 -> 12
> >  - add documentation to xfrm_proc.rst
> > 
> > v10->v11
> >  - rename error s/XfrmInDirError/XfrmInStateDirError/
> > ---
> >  Documentation/networking/xfrm_proc.rst |  3 +++
> >  include/uapi/linux/snmp.h              |  1 +
> >  net/ipv6/xfrm6_input.c                 |  7 +++++++
> >  net/xfrm/xfrm_input.c                  | 11 +++++++++++
> >  net/xfrm/xfrm_proc.c                   |  1 +
> >  5 files changed, 23 insertions(+)
> > 
> > diff --git a/Documentation/networking/xfrm_proc.rst b/Documentation/networking/xfrm_proc.rst
> > index c237bef03fb6..b4f4d9552dea 100644
> > --- a/Documentation/networking/xfrm_proc.rst
> > +++ b/Documentation/networking/xfrm_proc.rst
> > @@ -73,6 +73,9 @@ XfrmAcquireError:
> >  XfrmFwdHdrError:
> >  	Forward routing of a packet is not allowed
> > 
> > +XfrmInStateDirError:
> > +        State direction input mismatched with lookup path direction
> It's a bit confusing because when this error occurs, the state direction is not
> 'input'.

Agree.

> This statistic is under 'Inbound errors', so may something like this is enough:
> 'State direction is output.'

Maybe something like:

State direction mismatch (lookup found an output state on the input path, expected input or no direction)

It's a bit verbose, but I think those extra details would help users
understand what went wrong.

-- 
Sabrina


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ