Class FirewallRule
Inherited Variables
Inherited from Engine
Engine::$errors
- Engine::__construct()
- Engine constructor.
Returns protocol flag for given protocol name.
- string $protocol: protocol name
Disable rule.
Enable rule.
Get rule address.
return string address Rule address
Get rule type and flags.
Get rule group name.
Get rule name.
Get rule parameter value.
Get rule port.
Get rule protocol.
Return validated rule in packed format.
Rule format, 7 fields with a pipe '|' delimiter: name|group|flags|proto|addr|port|param
Returns type description.
Is rule enabled?
Compare this object with another, return true if equal.
- object $val: FirewallRule object to compare against
Do the rule flags make sense?
- int $flags: Rule flags to validate
Validation routine for IPs.
- string $ip: ip IP address
Is this (MAC/HW) address valid? (eg AA:BB:CC:DD:EE:FF)
- string $mac: Hardware address to validate
Is the rule name (or group name) valid?
- string $name: Firewall rule name
Validates TCP port.
- integer $port: port address
Is the rule protocol valid/supported?
- int $proto: Numeric port address to validate
Is this (hostname, IPv4, and soon IPv6) address valid? localhost || 192.168.0.1 || 192.168.0.1/24 || 192.168.0.1/255.255.255.0 || 192.168.0.1:192.168.1.1
TODO: hostname validation should be moved to IsValidHostname TODO: network validation should be moved to IsValidNetwork TODO: this class should extend Network() and use the standard validation
- string $ip: hostname, IPv4 address to validate
Reset class field members to default state.
Set rule address.
- string $val: Rule address
Set rule type and flags.
- int $val: Rule flags
Set rule group name.
- string $val: Firewall group name
Set rule name.
- string $val: Firewall name value
Set rule parameter value.
- mixed $val: Rule parameter value
Set rule port.
- int $port: port address
Set rule port range.
- int $from: from port
- int $to: to port
Set rule protocol.
- int $val: Rule numeric protocol
Set class members from packed format input.
Rule format, 7 fields seperated by a pipe '|' delimiter: name|group|flags|proto|addr|port|param
- string $input: Packed firewall rule
Inherited Methods
Inherited From Engine
Engine::__construct()
Engine::AddValidationError()
Engine::CheckValidationErrors()
Engine::CopyValidationErrors()
Engine::GetValidationErrors()
Engine::Log()
Engine::__destruct()
BANDWIDTH_BASIC
= 0x00004000
(line 111)
BANDWIDTH_PRIO
= 0x00002000
(line 110)
BANDWIDTH_RATE
= 0x00001000
(line 109)
CUSTOM
= 0x20000000
(line 126)
DMZ_INCOMING
= 0x00000020
(line 102)
DMZ_PINHOLE
= 0x00000010
(line 101)
ENABLED
= 0x10000000
(line 125)
EXTERNAL_ADDR
= 0x00200000
(line 118)
FORWARD
= 0x00000008
(line 100)
IFADDRESS
= 0x04000000
(line 123)
IFNETWORK
= 0x08000000
(line 124)
INCOMING_ALLOW
= 0x00000001
(line 97)
INCOMING_BLOCK
= 0x00000002
(line 98)
L7FILTER_BYPASS
= 0x00800000
(line 120)
LOCAL_NETWORK
= 0x00100000
(line 117)
MAC_FILTER
= 0x00000200
(line 106)
MAC_SOURCE
= 0x01000000
(line 121)
ONE_TO_ONE
= 0x00000080
(line 104)
OUTGOING_BLOCK
= 0x00000004
(line 99)
PPTP_FORWARD
= 0x00000100
(line 105)
PROTO_AH
= 51
(line 135)
PROTO_ESP
= 50
(line 134)
PROTO_GRE
= 47
(line 133)
PROTO_IP
= 0
(line 130)
PROTO_TCP
= 6
(line 131)
PROTO_UDP
= 17
(line 132)
PROXY_BYPASS
= 0x00400000
(line 119)
RESERVED_0
= 0x00000040
(line 103)
RESERVED_1
= 0x00008000
(line 112)
RESERVED_2
= 0x00010000
(line 113)
RESERVED_3
= 0x00020000
(line 114)
RESERVED_4
= 0x00040000
(line 115)
RESERVED_5
= 0x00080000
(line 116)
RESERVED_6
= 0x40000000
(line 127)
RESERVED_7
= 0x80000000
(line 128)
SBR_HOST
= 0x00000800
(line 108)
SBR_PORT
= 0x00000400
(line 107)
WIFI
= 0x02000000
(line 122)
Inherited Constants
Inherited from Engine
Engine::COMMAND_API
Documentation generated on Fri, 28 Aug 2009 20:32:09 -0400 by phpDocumentor 1.3.2

