Skip to content

Handling of NLM_F_DUMP_INTR is apparently missing #874

Closed
@crosser

Description

@crosser

We got a hard to reproduce condition in our tests, when a dump of network interfaces and addresses returned incomplete information. Because we have already encountered a related problem with nftables that turned out to be related to improper reaction NLM_F_DUMP_INTR condition, I suspect that the same thing is happening in pythoute2.

The point is, when the kernel is producing a dump of a kernel structure over multiple netlink messages, and the structure changes in the mid-way, NLM_F_DUMP_INTR is added to the header flags, that must be treated by userspace as an indication that the requested dump contains inconsistent data and must be re-requested. See function nl_dump_check_consistent() in the kernel source include/net/netlink.h.

I cannot find related functionality in pyroute2, which may explain the error that we encountered. I suspect that the necessary check for the flag NLM_F_DUMP_INTR in the received netlink messages is missing.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions