Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

xfrm: Don't prohibit AH from using ESN feature

Clear checking when user try to use ESN through netlink keymgr for AH.
As only ESP and AH support ESN feature according to RFC.

Signed-off-by: Fan Du <fan.du@windriver.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>

authored by

Fan Du and committed by
Steffen Klassert
01714109 8d6da6f3

+2 -1
+2 -1
net/xfrm/xfrm_user.c
··· 142 142 if (!rt) 143 143 return 0; 144 144 145 - if (p->id.proto != IPPROTO_ESP) 145 + /* As only ESP and AH support ESN feature. */ 146 + if ((p->id.proto != IPPROTO_ESP) && (p->id.proto != IPPROTO_AH)) 146 147 return -EINVAL; 147 148 148 149 if (p->replay_window != 0)