On 7/14/23 23:48, Michael Tokarev wrote:
15.07.2023 00:48, Harry G Coin wrote:
..

[] allowing wireguard interfaces to behave like all other interfaces when a namespace is destroyed  (moving back to the namespace where it was born and to which it retains connection anyhow)

The thing is that all interface types behave like this when a network namespace is removed: they're destroyed together with the namespace.  All which can be deleted anyway, for which an `ip link del' command works, - like, physical NICs are the only exception here b/c you
can't remove a physical NIC from a physical machine this way.

So in this context, wg interfaces are *already* behaving like all other virtual interfaces,
and this is done by linux network/namespace subsystem, not by wireguard.

/mjt


Oh dear.    It sure makes more sense to me for anything called 'an interface' to move in the same fashion as any other.  Having to 'just know' which ones will 'remain' and which ones will 'go away and need to be entirely reconfigured all the time' seems more than the security need calls for.  Just setting the link down when the netns goes away would be better, I can decide when, whether and how to create and destroy interfaces.   Or at least an option to 'treat all links the same when the netns goes away' somehow.

Off soap box now!

Thanks for the comments.


Reply via email to