Описание
Incus creates nftables rules that partially bypass security options
Summary
When using an ACL on a device connected to a bridge, Incus generates nftables rules that partially bypass security options security.mac_filtering
, security.ipv4_filtering
and security.ipv6_filtering
. This can lead to ARP spoofing on the bridge and to fully spoof another VM/container on the same bridge.
Details
In commit d137a063c2fe2a6983c995ba75c03731bee1557d, a few rules in the bridge input chain are moved to the top of the chain:
However, these rules accept packets that should be filtered and maybe dropped by later rules in the "MAC filtering", "IPv4 filtering" and "IPv6 filtering" snippets:
Basically, the added rules partially bypass the security options security.mac_filtering
, security.ipv4_filtering
and security.ipv6_filtering
. Doing so, they allow an attacker to perform ARP poisoning/spoofing attacks and send malicious Neighbor Advertisement (type 136).
PoC
With this terraform infrastructure:
An attacker in a VM (machine1) change their IP address to another VM (machine2)'s IP. The malicious change is reflected in the ARP table of the host, bypassing the MAC filtering. When the host emits or forwards a packet to machine2's IP, it is sent to machine1.
In addition, as ct state established,related accept
is now the first rule in bridge chain input, machine1 can even answer and thus fully spoof the victim on the network.
Impact
All versions since d137a063c2fe2a6983c995ba75c03731bee1557d, so basically v6.12 and v6.13.
Пакеты
github.com/lxc/incus/v6
>= 6.12, <= 6.13
6.14
Связанные уязвимости
Incus is a system container and virtual machine manager. When using an ACL on a device connected to a bridge, Incus versions 6.12 and 6.13generates nftables rules that partially bypass security options `security.mac_filtering`, `security.ipv4_filtering` and `security.ipv6_filtering`. This can lead to ARP spoofing on the bridge and to fully spoof another VM/container on the same bridge. Commit 254dfd2483ab8de39b47c2258b7f1cf0759231c8 contains a patch for the issue.
Incus is a system container and virtual machine manager. When using an ACL on a device connected to a bridge, Incus versions 6.12 and 6.13generates nftables rules that partially bypass security options `security.mac_filtering`, `security.ipv4_filtering` and `security.ipv6_filtering`. This can lead to ARP spoofing on the bridge and to fully spoof another VM/container on the same bridge. Commit 254dfd2483ab8de39b47c2258b7f1cf0759231c8 contains a patch for the issue.
Incus is a system container and virtual machine manager. When using an ...
Уязвимость системы управления контейнерами и менеджера виртуальных машин Incus, связанная с недостатками механизма авторизации, позволяющая нарушителю обойти существующие ограничения безопасности и проводить спуфинг-атаки