| Home | Trees | Index | Help |
|---|
| Module dnet :: Class fw |
|
object --+
|
fw
fw() -> Firewall ruleset object Open a handle to the local network firewall configuration.
| Method Summary | |
|---|---|
x.__init__(...) initializes x; see x.__class__.__doc__ for signature... | |
x.__iter__() <==> iter(x)... | |
T.__new__(S, ...) -> a new object with type S, a subtype of T... | |
Add a firewall rule specified as a dict. | |
Delete a firewall rule specified as a dict. | |
Iterate over the local firewall ruleset, invoking a user callback with each entry, returning the status of the callback routine. | |
| Inherited from object | |
x.__delattr__('name') <==> del x.name... | |
x.__getattribute__('name') <==> x.name... | |
x.__hash__() <==> hash(x)... | |
helper for pickle... | |
helper for pickle... | |
x.__repr__() <==> repr(x)... | |
x.__setattr__('name', value) <==> x.name = value... | |
x.__str__() <==> str(x)... | |
| Method Details |
|---|
__init__(...)
|
__iter__(x)x.__iter__() <==> iter(x)
|
__new__(T, S, ...)T.__new__(S, ...) -> a new object with type S, a subtype of T
|
add(...)Add a firewall rule specified as a dict. Dict values: device -- interface name (string) op -- operation (FW_OP_*) (integer) dir -- direction (FW_DIR_*) (integer) proto -- IP protocol (IP_PROTO_*) (integer) src -- source address / net (addr object) dst -- destination address / net (addr object) sport -- source port range or ICMP type/mask (list of 2 integers) dport -- dest port range or ICMP code/mask (list of 2 integers) |
delete(...)Delete a firewall rule specified as a dict. |
loop(...)
Iterate over the local firewall ruleset, invoking a user callback
with each entry, returning the status of the callback routine.
Keyword arguments:
callback -- callback function with (dict, arg) prototype.
If this function returns a non-zero value, the loop
will break early.
arg -- optional callback argument
|
| Home | Trees | Index | Help |
|---|
| Generated by Epydoc 2.1 on Thu Jan 19 13:24:11 2006 | http://epydoc.sf.net |