connection to disable an interface



Hi

Is it somehow possible to disable an interface via NetworkManager?

I am thinking of something like:

nmcli connection modify con-eth0 802-3-ethernet.phy disabled
nmcli connection up con-eth0

which would basically have the same effect as:

ip link set eth0 down


nmcli connection modify con-eth0 802-3-ethernet.phy enabled
nmcli connection up con-eth0

which would basically have the same effect as:

ip link set eth0 up


The background is a security requirement. Unused interfaces must
ideally remain disabled at the physical layer when a cable is plugged
in. Ideally, the LEDs would also remain dark.

If this function does not exist yet, would it be interesting for
NetworkManager?
Could the functionality be implemented with reasonable effort or would
it be difficult to implement?

Thank you and regards,
Adrian


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]