Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only set IFLA_XFRM_IF_ID if not 0 #735

Merged
merged 1 commit into from
Feb 24, 2022

Conversation

tklauser
Copy link
Contributor

A value of 0 for IFLA_XFRM_IF_ID is not valid and will be rejected by
the kernel by returning EINVAL, see [1]. Thus, only set the
IFLA_XFRM_IF_ID attribute in case Xfrmi.Ifid != 0.

[1] https://github.com/torvalds/linux/blob/8efd0d9c316af470377894a6a0f9ff63ce18c177/net/xfrm/xfrm_interface.c#L645-L648

A value of 0 for IFLA_XFRM_IF_ID is not valid and will be rejected by
the kernel by returning EINVAL, see [1]. Thus, only set the
IFLA_XFRM_IF_ID attribute in case Xfrmi.Ifid != 0.

[1] https://github.com/torvalds/linux/blob/8efd0d9c316af470377894a6a0f9ff63ce18c177/net/xfrm/xfrm_interface.c#L645-L648
@tklauser
Copy link
Contributor Author

@vishvananda @aboch could one of you please take a look?

@aboch aboch merged commit f7fd7af into vishvananda:main Feb 24, 2022
@tklauser tklauser deleted the fix-ifla_xfrm_if_id branch February 24, 2022 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants