@@ -5,12 +5,14 @@ NetfilterQueue
5
5
NetfilterQueue provides access to packets matched by an iptables rule in
6
6
Linux. Packets so matched can be accepted, dropped, altered, or given a mark.
7
7
8
- Libnetfilter_queue (the netfilter library, not this module) is part of the `Netfilter project <http://netfilter.org/projects/libnetfilter_queue/ >`_.
8
+ Libnetfilter_queue (the netfilter library, not this module) is part of the
9
+ `Netfilter project <http://netfilter.org/projects/libnetfilter_queue/ >`_.
9
10
10
11
Example
11
12
=======
12
13
13
- The following script prints a short description of each packet before accepting it. ::
14
+ The following script prints a short description of each packet before accepting
15
+ it. ::
14
16
15
17
from netfilterqueue import NetfilterQueue
16
18
@@ -32,7 +34,8 @@ To send packets destined for your LAN to the script, type something like::
32
34
Installation
33
35
============
34
36
35
- NetfilterQueue is a C extention module that links against libnetfilter_queue. Before installing, ensure you have:
37
+ NetfilterQueue is a C extention module that links against libnetfilter_queue.
38
+ Before installing, ensure you have:
36
39
37
40
1. A C compiler
38
41
71
74
``NetfilterQueue.COPY_META ``
72
75
73
76
``NetfilterQueue.COPY_PACKET ``
74
- These constants specify how much of the packet should be given to the script- nothing, metadata, or the whole packet.
77
+ These constants specify how much of the packet should be given to the
78
+ script- nothing, metadata, or the whole packet.
75
79
76
80
NetfilterQueue objects
77
81
----------------------
@@ -184,8 +188,8 @@ More details coming soon...
184
188
* Probably other stuff is omitted too
185
189
186
190
* When a packet has been marked, we use nfq_set_verdict_mark rather than
187
- nfq_set_verdict2. Apparently nfq_set_verdict_mark
188
- `is broken <http://netfilter.org/projects/libnetfilter_queue/doxygen/group__Queue.html#ga1986d6387c5aa2a837c02e87ae3b45ff >`_,
191
+ nfq_set_verdict2. Apparently nfq_set_verdict_mark is
192
+ `broken <http://netfilter.org/projects/libnetfilter_queue/doxygen/group__Queue.html#ga1986d6387c5aa2a837c02e87ae3b45ff >`_,
189
193
although it works for me.
190
194
191
195
Source
@@ -199,3 +203,4 @@ License
199
203
Copyright (c) 2011, Kerkhoff Technologies, Inc.
200
204
201
205
`MIT licensed <https://github.com/kti/python-netfilterqueue/blob/master/LICENSE.txt >`_
206
+
0 commit comments