Repository navigation
Commit 47dd693
xfrm: state and policy should fail if XFRMA_IF_ID 0
[ Upstream commit 68ac0f3 ]
xfrm ineterface does not allow xfrm if_id = 0
fail to create or update xfrm state and policy.
With this commit:
ip xfrm policy add src 192.0.2.1 dst 192.0.2.2 dir out if_id 0
RTNETLINK answers: Invalid argument
ip xfrm state add src 192.0.2.1 dst 192.0.2.2 proto esp spi 1 \
reqid 1 mode tunnel aead 'rfc4106(gcm(aes))' \
0x1111111111111111111111111111111111111111 96 if_id 0
RTNETLINK answers: Invalid argument
v1->v2 change:
- add Fixes: tag
Fixes: 9f8550e ("xfrm: fix disable_xfrm sysctl when used on xfrm interfaces")
Signed-off-by: Antony Antony <antony.antony@secunet.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent db36904 commit 47dd693
1 file changed
Lines changed: 18 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
621 | 621 | | |
622 | 622 | | |
623 | 623 | | |
624 | | - | |
| 624 | + | |
625 | 625 | | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
626 | 631 | | |
627 | 632 | | |
628 | 633 | | |
| |||
1353 | 1358 | | |
1354 | 1359 | | |
1355 | 1360 | | |
1356 | | - | |
| 1361 | + | |
1357 | 1362 | | |
| 1363 | + | |
| 1364 | + | |
| 1365 | + | |
| 1366 | + | |
| 1367 | + | |
1358 | 1368 | | |
1359 | 1369 | | |
1360 | 1370 | | |
| |||
1667 | 1677 | | |
1668 | 1678 | | |
1669 | 1679 | | |
1670 | | - | |
| 1680 | + | |
1671 | 1681 | | |
| 1682 | + | |
| 1683 | + | |
| 1684 | + | |
| 1685 | + | |
| 1686 | + | |
1672 | 1687 | | |
1673 | 1688 | | |
1674 | 1689 | | |
| |||
0 commit comments