| |
|
|
|
|
|
|
|
|
| |
Rules like tcp://192.0.2.7:22 or udp://192.0.2.0/24:5000-5100 in a user's
egress rules (managed with fc-egress as before) go into the nftables set
allow_USER, and connections from that user's guests that match get
forwarded (NATed to the host's address), or let in, if they're for one
of the host's addresses. fcbr0-firewall fills the sets whenever a
user's rules change, and after nftables reloads. Forwarding needs
net.ipv4.ip_forward, which networking.nat used to set.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The host module takes users = { NAME = TAPS; ... } instead of a single
user: each user gets that many taps, and rules of their own, in
/var/lib/fc-egress/USER/allowed, managed with fc-egress as before.
The proxy tells whose a guest is by its address: each tap has a fixed
one, handed out by dnsmasq by MAC address (derived from the tap's number,
as the run script does), and the bridge drops anything a guest sends from
another address. The decrypting server gets a socket per user, as it
can't see the guest's address. The run script only takes the user's own
taps.
|