YaST2 Developers Documentation: Network Configuration

Network Configuration

modules/SuSEFirewall4Network.ycp
Module for handling interfaces in SuSEfirewall2
  • Lukas Ocilka

This module has an unstable interface.

Copyright 2004, Novell, Inc. All rights reserved. Module for handling network interfaces in SuSEfirewall2 using SuSEFirewall module.

Imports

  • Stage
  • SuSEFirewall
  • SuSEFirewallProposal

Global Functions

global Read () -> boolean

Function reads configuration of SuSEFirewall.

Return value:
if successful
global Write () -> boolean

Function writes configuration of SuSEFirewall.

Return value:
if successful
global IsOn () -> boolean

Return value:
whether enabled and started
global FirewallZonesComboBoxItems () -> list< list<string> >

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:
item list for CWM
global IsProtectedByFirewall (string interface) -> boolean

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).

Parameters:
interface
Return value:
if it is protected
global GetZoneOfInterface (string interface) -> string

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.

Parameters:
interface
Return value:
zone
global ProtectByFirewall (string interface, string zone, boolean protect_status) -> boolean

Functions sets protection of interface by the protect-status.
protect==true -> add interface into selected firewall zone, sets firewall to be started and enabled when booting.
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.

Parameters:
interface
zone
protect_status
Return value:
if successful
global UnconfiguredIsBlocked () -> boolean

Return value:
Whether the UI should warn about interfaces that are not in any zone
global ChangedByUser (boolean changed) -> void

Function sets that a firewall proposal was changed by user by editing firewall zone of network interface (applicable during 2nd stage of installation only)

Parameters:
changed