IpNetnsExecFilter does not qualify the path of nested commands
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
oslo.rootwrap |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
When invoking a command via IpNetnsExecFilter, the 'ip' command is automatically qualified depending on where it has been found via exec_dirs (e.g. the 'ip' command is found at '/sbin/ip' and that qualified command is executed). However, a command invoked by ip netns is not similarly qualified such that it being found is entirely dependent on the PATH environment. This is causing problems for neutron functional testing where the target command is in a venv bin directory and a qualified path is required, e.g.
The following command is executed:
sudo /usr/local/
Resulting in:
exec of "neutron-
This despite exec_dirs including the path of the neutron-
What should be executed: /sbin/ip netns exec mynamespace /[path to proxy]/
What is being executed: /sbin/ip netns exec mynamespace neutron-
Changed in oslo.rootwrap: | |
assignee: | nobody → Maru Newby (maru) |
description: | updated |
Changed in oslo.rootwrap: | |
assignee: | Maru Newby (maru) → Miguel Angel Ajo (mangelajo) |
Changed in oslo.rootwrap: | |
status: | In Progress → Confirmed |
Changed in oslo.rootwrap: | |
assignee: | Stephen Ma (stephen-ma) → nobody |
I suppose we may need to extend IpNetnsExecFilter to actually qualify the path for the ip netns exec wrapped executable.
I will look at that tomorrow morning.