Bug 71 - pasta doesn't properly handle RTA_PREFSRC elements when copying routes
Summary: pasta doesn't properly handle RTA_PREFSRC elements when copying routes
Status: RESOLVED FIXED
Alias: None
Product: passt
Classification: Unclassified
Component: pasta (show other bugs)
Version: unspecified
Hardware: All Linux
: Normal normal
Assignee: nobody
URL:
Depends on:
Blocks:
 
Reported: 2023-08-23 06:38 UTC by David Gibson
Modified: 2023-08-24 00:26 UTC (History)
0 users

See Also:


Attachments

Description David Gibson 2023-08-23 06:38:49 UTC
By default we copy host routes to the container with pasta and --config-net.  However, this can fail if those routes contain RTA_SRC attributes and we use -a to give the container an address different from that on the host.

Setting a route with RTA_SRC musc give an address which is set on an interface in the namespace, so if we copy an RTA_SRC from the host with a host address to a namespace with a different address, we get an -EINVAL on the NEWROUTE, causing --config-net to fail entirely.

This is the root cause of at least one of the failures noted in https://github.com/containers/podman/pull/19699#issuecomment-1688769287
Comment 1 David Gibson 2023-08-23 07:03:09 UTC
Oops, it's actually RTA_PREFSRC, not RTA_SRC that's the issue.

Note You need to log in before you can comment on or make changes to this bug.