owner based routing
Hello,
Quoted 2 lines · Ignatich
Quoted 2 lines
Since
ipt_ownerdoes not work in PREROUTING chain and fwmark is pointless, I thought thatipt_ROUTEfrom p-o-m can help me.
dr> Why is fwmark pointless?
Quoted 1 line
Quoted 1 line
Any ideas how to solve my problem?
dr> I would try -j MARK --set-mark $UID for your -m owner matched packets dr> and use a ip rule / ip route combination. I've not done this, but I dr> don't see why it wouldn't work.
It's pointless because ipt_owner does not work in PREROUTING table. So even if I mark packet routing decision is already made.
Signature · 1 line
Ignatich mailto:[email protected]
Quoted 4 lines · Ignatich
dr> Why is fwmark pointless?
It's pointless because
ipt_ownerdoes not work in PREROUTING table. So even if I mark packet routing decision is already made.
The mangle table OUTPUT chain is consulted before routing.
root@room101:~# iptables -vt mangle -A OUTPUT -m owner --uid-owner rob0 -j MARK --set-mark 0x80 MARK all opt -- in * out * 0.0.0.0/0 -> 0.0.0.0/0 OWNER UID match 1000 MARK set 0x80
Did you try this?
Signature · 2 lines
mail to this address is discarded unless "/dev/rob0"
or "not-spam" is in Subject: header