UdpMatch¶
The UdpMatch class uses the same
SourcePortCriterion
and
DestPortCriterion
as the TcpMatch class.
Example:
>>> from linuxnet.iptables import UdpMatch
>>> m = UdpMatch()
>>> m.dest_port().equals(53)
<linuxnet.iptables.match.UdpMatch object at 0x7ff96e466f98>
>>> m.to_iptables_args()
['-m', 'udp', '--dport', '53']
- class UdpMatch[source]¶
Match against the source/destination UDP ports.
- source_port() SourcePortCriterion[source]¶
Match against the source port
- dest_port() DestPortCriterion[source]¶
Match against the destination port