My Raspberry Pi 2 is configured as access point, working with the following iptables
settings:
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -i eth0 -o wlan0 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i wlan0 -o eth0 -j ACCEPT
I'm using the Python binding of the libnetfilter_queue
library.
I'm trying to make a rudimental Qos reading (with success) the source port of every packet I get (with the -j NFQUEUE --queue-num x
rule), and depending on the packet sent from port 25, 80 or 5060 I may delay or send immediately the packet.
My question is: which of the last two rules should be applied to the NFQUEUE
target?
Until now I only put packets in --queue-num
from wlan0
to eth0
, but I guess there is no need to apply the NFQUEUE
target to the last rule too and monitoring packets from eth0
to wlan0
...right?