You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to read nflogs issued by iptables logging lines on multicast group, but without any success.
tcpdump is able to read it.
reproduce:
add this line to iptables and ping it from a different host:
iptables -A INPUT -j NFLOG --nflog-prefix="[NFLOG_PREFIX:]" --nflog-group 1
tcpdump -ni nflog:1
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on nflog:1, link-type NFLOG (Linux netfilter log messages), snapshot length 262144 bytes
13:10:10.198076 IP 172.17.0.2.3635 > 172.17.0.4.0: Flags [none], win 512, length 0
13:10:10.198453 IP 172.17.0.2.3636 > 172.17.0.4.0: Flags [none], win 512, length 0
# code snippet what is mimicking, maybe I'm wrong here
# running with root privilege
from pyroute2.netlink.nlsocket import NetlinkSocket
ns = NetlinkSocket()
GROUP = 1
ns.bind(groups=GROUP)
print('bind_ok')
ns.add_membership(GROUP)
print('member_ok')
print(ns.get())
I've been trying adding to different groups, removing add_membership, nothing helps.
Just waits endless in get() loop.
Any idea?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
HI,
I would like to read nflogs issued by iptables logging lines on multicast group, but without any success.
tcpdump is able to read it.
reproduce:
add this line to iptables and ping it from a different host:
iptables -A INPUT -j NFLOG --nflog-prefix="[NFLOG_PREFIX:]" --nflog-group 1
tcpdump -ni nflog:1
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on nflog:1, link-type NFLOG (Linux netfilter log messages), snapshot length 262144 bytes
13:10:10.198076 IP 172.17.0.2.3635 > 172.17.0.4.0: Flags [none], win 512, length 0
13:10:10.198453 IP 172.17.0.2.3636 > 172.17.0.4.0: Flags [none], win 512, length 0
I've been trying adding to different groups, removing add_membership, nothing helps.
Just waits endless in get() loop.
Any idea?
Br
B.
Beta Was this translation helpful? Give feedback.
All reactions