Unknown YCP Module |
This module has an unstable interface. |
File: modules/CWMFirewallInterfaces.ycp
Package: Common widget manipulation, firewall interfaces widget
Summary: Routines for selecting interfaces opened in firewall
Authors: Jiri Srain
$Id$
WARNING: If you want to use this functionality of this module you should allways call 'SuSEFirewall::Read()' in the Read() function of you module and you should call 'SuSEFirewall::Write()' in the Write() function.
Functionality of this module only changes the SuSEFirewall settings in memory, it never Reads or Writes the settings.
List of all interfaces relevant for firewall settings
List of all items of interfaces to the selection box
List of interfaces that are allowed
Information if configuration was changed by user
`Any`-feature is supported in the firewall configuration
Enable or disable the firewall details widget according to the status of "open firewall" checkbox
Set the firewall status label
- Parameters:
-
status symbol one of `off, `closed, `open_all, `custom, `not_installed
Initialize the list of all known interfaces
Update the firewall status label according to the current status
Get the list of all interfaces that will be selected
- Parameters:
-
ifaces a list of interfaces selected by the user nm_ifaces_have_to_be_selected defines whether also NetworkManager have to be selected too
- Return value:
-
a list of interfaces that will be opened
Display popup with firewall settings details
- Parameters:
-
widget
Initialize the list of allowed interfaces Changes the internal variables
- Parameters:
-
services a list of services
Store the list of allowed interfaces Users the internal variables
- Parameters:
-
services a list of services
Init function of the widget
- Parameters:
-
widget key strnig the widget key
Handle function of the widget
- Parameters:
-
widget key strnig the widget key event map event to be handled
- Return value:
-
for wizard sequencer or nil
Store function of the widget
- Parameters:
-
widget key strnig the widget key event map that caused widget data storing
Validate function of the widget
- Parameters:
-
widget key strnig the widget key event map event that caused the validation
- Return value:
-
true if validation succeeded, false otherwise
Checks whether it is possible to change the firewall status
- Parameters:
-
new_status
Init function of the widget
- Parameters:
-
key strnig the widget key
Handle function of the widget
- Parameters:
-
key strnig the widget key event map event to be handled
- Return value:
-
for wizard sequencer or nil
Store function of the widget
- Parameters:
-
key strnig the widget key event map that caused widget data storing
Validate function of the widget
- Parameters:
-
key strnig the widget key event map event that caused the validation
- Return value:
-
true if validation succeeded, false otherwise
Get the widget description map
- Parameters:
-
settings a map of all parameters needed to create the widget properly Behavior manipulating functions (mandatory) - "get_allowed_interfaces" : list
() -- function that returns the list of allowed network interfaces - "set_allowed_interfaces" : void (list ) -- function that sets the list of allowed interfaces Additional settings: - "help" : string -- help to the whole widget. If not specified, generic help is used (button labels are patched correctly)
- Return value:
-
the widget description map
Display the firewall interfaces selection as a popup
- Parameters:
-
settings
- Return value:
-
return value of the dialog
Initialize the open firewall widget
- Parameters:
-
widget a map describing the whole widget key
Store function of the widget
- Parameters:
-
widget key strnig the widget key event map that caused widget data storing
Handle the immediate start and stop of the service
- Parameters:
-
widget a map describing the widget key strnig the widget key event
- Return value:
-
always nil
Init function of the widget
- Parameters:
-
key strnig the widget key
Store function of the widget
- Parameters:
-
key strnig the widget key event map that caused widget data storing
Handle the immediate start and stop of the service
- Parameters:
-
key strnig the widget key event
- Return value:
-
always nil
Check if the widget was modified
- Parameters:
-
key strnig the widget key
- Return value:
-
true if widget was modified
Enable the whole firewal widget
Disable the whole firewal widget
Check whether the whole firewall widget ( open port checkbox and fw details button) exists
- Return value:
-
true if both widgets exist
Get the template for the help text to the firewall opening widget
- Parameters:
-
restart_displayed shold be true if "Save and restart" is displayed
- Return value:
-
help text template with %1 and %2 placeholders
Get the help text to the firewall opening widget
- Parameters:
-
restart_displayed shold be true if "Save and restart" is displayed
- Return value:
-
help text
Get the widget description map of the firewall enablement widget
- Parameters:
-
settings a map of all parameters needed to create the widget properly - "services" : list
-- services identifications for the Firewall.ycp module - "display_details" : boolean -- true if the details button should be displayed - "firewall_details_handler" : symbol () -- function to handle the firewall details button. If returns something else than nil, dialog is exited with the returned symbol as value for wizard sequencer. If not specified, but "display_details" is true, common popup is used. - "open_firewall_checkbox" : string -- label of the check box - "firewall_details_button" : string -- label of the push button for changing firewall details - "help" : string -- help to the widget. If not specified, generic help is used
- Return value:
-
the widget description map
Check if settings were modified by the user
- Return value:
-
true if settings were modified