Module for handling interfaces in SuSEfirewall2
List of Global Functions
FirewallZonesComboBoxItems - Function returns list of items for combo box with all known firewall zones. There's also an item for "" (no zone or fw off).
GetZoneOfInterface - Function returns the firewall zone of interface, "" if no zone includes the interface. Error is reported when interface is found in multiple firewall zones, then the first appearance is returned. If firewall is off, "" is returned.
IsOn -
IsProtectedByFirewall - Function returns if interface is protected by firewall. It means: Firewall is Running and Enabled. Interface is included in any protected firewall zone (means EXT, DMZ or INT).
ProtectByFirewall - Functions sets protection of interface by the protect-status.<br> protect==true -> add interface into selected firewall zone, sets firewall to be started and enabled when booting.<br> protect==false -> removes interface from all firewall zones, if there are no other interfaces protected by firewall, stops it and removes it from boot process.
Read - Function reads configuration of SuSEFirewall.
Write - Function writes configuration of SuSEFirewall.
List of Global Variables
Function returns list of items for combo box with all known firewall zones. There's also an item for "" (no zone or fw off).
Return value
list< list<string> > - item list for CWM
Function returns the firewall zone of interface, "" if no zone includes the interface. Error is reported when interface is found in multiple firewall zones, then the first appearance is returned. If firewall is off, "" is returned.
Function parameters
string interface
Return value
string - zone
Function returns if interface is protected by firewall. It means: Firewall is Running and Enabled. Interface is included in any protected firewall zone (means EXT, DMZ or INT).
Function parameters
string interface
Return value
boolean - if it is protected
Functions sets protection of interface by the protect-status.<br> protect==true -> add interface into selected firewall zone, sets firewall to be started and enabled when booting.<br> protect==false -> removes interface from all firewall zones, if there are no other interfaces protected by firewall, stops it and removes it from boot process.
Function parameters
string interface
string zone
boolean protect_status
Return value
boolean - if successful
Return value
boolean - Whether the UI should warn about interfaces that are not in any zone