policycoreutils/selinux-gui-fedora.patch
Petr Lautrbach 203045ec1e gui: Several python 3 related fixes from fedora-selinux/selinux
- gui/polgengui.py: Fix sepolicy.generate import in polgengui.py
- gui/polgengui.py: Convert polgen.glade to Builder format polgen.ui
- python/sepolicy: Use list instead of map
- python/sepolicy: Do not use types.BooleanType
2018-02-15 21:29:23 +01:00

6108 lines
316 KiB
Diff

diff --git selinux-gui-2.7/Makefile selinux-gui-2.7/Makefile
index 4fc2c1a..ff0fd00 100644
--- selinux-gui-2.7/Makefile
+++ selinux-gui-2.7/Makefile
@@ -11,14 +11,13 @@ domainsPage.py \
fcontextPage.py \
html_util.py \
loginsPage.py \
-mappingsPage.py \
modulesPage.py \
-polgen.glade \
+polgen.ui \
portsPage.py \
semanagePage.py \
statusPage.py \
-system-config-selinux.glade \
system-config-selinux.png \
+system-config-selinux.ui \
usersPage.py
all: $(TARGETS) system-config-selinux.py polgengui.py
diff --git selinux-gui-2.7/booleansPage.py selinux-gui-2.7/booleansPage.py
index a5d04bf..7849bea 100644
--- selinux-gui-2.7/booleansPage.py
+++ selinux-gui-2.7/booleansPage.py
@@ -18,13 +18,8 @@
# You should have received a copy of the GNU General Public License
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
-import string
-import gtk
-import gtk.glade
-import os
-import gobject
import sys
-import tempfile
+from gi.repository import Gdk, GObject, Gtk
import seobject
import semanagePage
@@ -61,8 +56,6 @@ except:
import __builtin__
__builtin__.__dict__['_'] = unicode
-from glob import fnmatch
-
class Modifier:
@@ -94,56 +87,53 @@ class booleansPage:
def __init__(self, xml, doDebug=None):
self.xml = xml
- self.window = self.xml.get_widget("mainWindow").get_root_window()
+ self.window = self.xml.get_object("mainWindow").get_root_window()
self.local = False
self.types = []
self.selinuxsupport = True
self.typechanged = False
self.doDebug = doDebug
- self.busy_cursor = gtk.gdk.Cursor(gtk.gdk.WATCH)
- self.ready_cursor = gtk.gdk.Cursor(gtk.gdk.LEFT_PTR)
+ self.busy_cursor = Gdk.Cursor.new(Gdk.CursorType.WATCH)
+ self.ready_cursor = Gdk.Cursor.new(Gdk.CursorType.LEFT_PTR)
# Bring in widgets from glade file.
- self.typeHBox = xml.get_widget("typeHBox")
- self.booleanSW = xml.get_widget("booleanSW")
- self.booleansFilter = xml.get_widget("booleansFilter")
+ self.booleansFilter = xml.get_object("booleansFilter")
self.booleansFilter.connect("focus_out_event", self.filter_changed)
self.booleansFilter.connect("activate", self.filter_changed)
+ self.booleansFilter.connect("changed", self.filter_changed)
- self.booleansView = xml.get_widget("booleansView")
- self.typeLabel = xml.get_widget("typeLabel")
- self.modifySeparator = xml.get_widget("modifySeparator")
+ self.booleansView = xml.get_object("booleansView")
- self.revertButton = xml.get_widget("booleanRevertButton")
+ self.revertButton = xml.get_object("booleanRevertButton")
self.revertButton.set_sensitive(self.local)
self.revertButton.connect("clicked", self.on_revert_clicked)
- listStore = gtk.ListStore(gobject.TYPE_STRING)
- cell = gtk.CellRendererText()
+ listStore = Gtk.ListStore(GObject.TYPE_STRING)
+ cell = Gtk.CellRendererText()
- self.store = gtk.ListStore(gobject.TYPE_BOOLEAN, gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
- self.store.set_sort_column_id(1, gtk.SORT_ASCENDING)
+ self.store = Gtk.ListStore(GObject.TYPE_BOOLEAN, GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING)
+ self.store.set_sort_column_id(1, Gtk.SortType.ASCENDING)
self.booleansView.set_model(self.store)
- checkbox = gtk.CellRendererToggle()
+ checkbox = Gtk.CellRendererToggle()
checkbox.connect("toggled", self.boolean_toggled)
- col = gtk.TreeViewColumn('Active', checkbox, active=ACTIVE)
+ col = Gtk.TreeViewColumn('Active', checkbox, active=ACTIVE)
col.set_clickable(True)
col.set_sort_column_id(ACTIVE)
self.booleansView.append_column(col)
- col = gtk.TreeViewColumn("Module", gtk.CellRendererText(), text=MODULE)
+ col = Gtk.TreeViewColumn("Module", Gtk.CellRendererText(), text=MODULE)
col.set_sort_column_id(MODULE)
col.set_resizable(True)
self.booleansView.append_column(col)
- col = gtk.TreeViewColumn("Description", gtk.CellRendererText(), text=DESC)
- col.set_sizing(gtk.TREE_VIEW_COLUMN_FIXED)
+ col = Gtk.TreeViewColumn("Description", Gtk.CellRendererText(), text=DESC)
+ col.set_sizing(Gtk.TreeViewColumnSizing.FIXED)
col.set_fixed_width(400)
col.set_sort_column_id(DESC)
col.set_resizable(True)
self.booleansView.append_column(col)
- col = gtk.TreeViewColumn("Name", gtk.CellRendererText(), text=BOOLEAN)
+ col = Gtk.TreeViewColumn("Name", Gtk.CellRendererText(), text=BOOLEAN)
col.set_sort_column_id(BOOLEAN)
col.set_resizable(True)
self.booleansView.set_search_equal_func(self.__search)
@@ -152,10 +142,10 @@ class booleansPage:
self.load(self.filter)
def error(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_ERROR,
- gtk.BUTTONS_CLOSE,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.ERROR,
+ Gtk.ButtonsType.CLOSE,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
dlg.run()
dlg.destroy()
@@ -178,11 +168,11 @@ class booleansPage:
def deleteDialog(self):
store, iter = self.booleansView.get_selection().get_selected()
- if iter == None:
+ if iter is None:
return
boolean = store.get_value(iter, BOOLEAN)
# change cursor
- if boolean == None:
+ if boolean is None:
return
try:
self.wait()
diff --git selinux-gui-2.7/domainsPage.py selinux-gui-2.7/domainsPage.py
index 66f882a..bad5140 100644
--- selinux-gui-2.7/domainsPage.py
+++ selinux-gui-2.7/domainsPage.py
@@ -16,19 +16,14 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
import os
try:
from subprocess import getstatusoutput
except ImportError:
from commands import getstatusoutput
-import gobject
import sys
-import seobject
-import selinux
+from gi.repository import GObject, Gtk
import sepolicy
from semanagePage import *
@@ -58,26 +53,26 @@ class domainsPage(semanagePage):
def __init__(self, xml):
semanagePage.__init__(self, xml, "domains", _("Process Domain"))
- self.domain_filter = xml.get_widget("domainsFilterEntry")
+ self.domain_filter = xml.get_object("domainsFilterEntry")
self.domain_filter.connect("focus_out_event", self.filter_changed)
self.domain_filter.connect("activate", self.filter_changed)
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING)
self.view.set_model(self.store)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Domain Name"), gtk.CellRendererText(), text=0)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Domain Name"), Gtk.CellRendererText(), text=0)
col.set_sort_column_id(0)
col.set_resizable(True)
self.view.append_column(col)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Mode"), gtk.CellRendererText(), text=1)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Mode"), Gtk.CellRendererText(), text=1)
col.set_sort_column_id(1)
col.set_resizable(True)
self.view.append_column(col)
self.view.get_selection().connect("changed", self.itemSelected)
- self.permissive_button = xml.get_widget("permissiveButton")
- self.enforcing_button = xml.get_widget("enforcingButton")
+ self.permissive_button = xml.get_object("permissiveButton")
+ self.enforcing_button = xml.get_object("enforcingButton")
self.domains = sepolicy.get_all_entrypoint_domains()
self.load()
@@ -112,7 +107,7 @@ class domainsPage(semanagePage):
def itemSelected(self, selection):
store, iter = selection.get_selected()
- if iter == None:
+ if iter is None:
return
p = store.get_value(iter, 1) == _("Permissive")
self.permissive_button.set_sensitive(not p)
diff --git selinux-gui-2.7/fcontextPage.py selinux-gui-2.7/fcontextPage.py
index 2e26666..a6577ef 100644
--- selinux-gui-2.7/fcontextPage.py
+++ selinux-gui-2.7/fcontextPage.py
@@ -16,10 +16,7 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import gtk
-import gtk.glade
-import os
-import gobject
+from gi.repository import GObject, Gtk
import seobject
try:
from subprocess import getstatusoutput
@@ -73,40 +70,40 @@ class fcontextPage(semanagePage):
def __init__(self, xml):
semanagePage.__init__(self, xml, "fcontext", _("File Labeling"))
- self.fcontextFilter = xml.get_widget("fcontextFilterEntry")
+ self.fcontextFilter = xml.get_object("fcontextFilterEntry")
self.fcontextFilter.connect("focus_out_event", self.filter_changed)
self.fcontextFilter.connect("activate", self.filter_changed)
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
- self.view = xml.get_widget("fcontextView")
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING)
+ self.view = xml.get_object("fcontextView")
self.view.set_model(self.store)
self.view.set_search_equal_func(self.search)
- col = gtk.TreeViewColumn(_("File\nSpecification"), gtk.CellRendererText(), text=SPEC_COL)
- col.set_sizing(gtk.TREE_VIEW_COLUMN_FIXED)
+ col = Gtk.TreeViewColumn(_("File\nSpecification"), Gtk.CellRendererText(), text=SPEC_COL)
+ col.set_sizing(Gtk.TreeViewColumnSizing.FIXED)
col.set_fixed_width(250)
col.set_sort_column_id(SPEC_COL)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("Selinux\nFile Type"), gtk.CellRendererText(), text=TYPE_COL)
+ col = Gtk.TreeViewColumn(_("Selinux\nFile Type"), Gtk.CellRendererText(), text=TYPE_COL)
- col.set_sizing(gtk.TREE_VIEW_COLUMN_FIXED)
+ col.set_sizing(Gtk.TreeViewColumnSizing.FIXED)
col.set_fixed_width(250)
col.set_sort_column_id(TYPE_COL)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("File\nType"), gtk.CellRendererText(), text=2)
+ col = Gtk.TreeViewColumn(_("File\nType"), Gtk.CellRendererText(), text=2)
col.set_sort_column_id(FTYPE_COL)
col.set_resizable(True)
self.view.append_column(col)
- self.store.set_sort_column_id(SPEC_COL, gtk.SORT_ASCENDING)
+ self.store.set_sort_column_id(SPEC_COL, Gtk.SortType.ASCENDING)
self.load()
- self.fcontextEntry = xml.get_widget("fcontextEntry")
- self.fcontextFileTypeCombo = xml.get_widget("fcontextFileTypeCombo")
- self.fcontextTypeEntry = xml.get_widget("fcontextTypeEntry")
- self.fcontextMLSEntry = xml.get_widget("fcontextMLSEntry")
+ self.fcontextEntry = xml.get_object("fcontextEntry")
+ self.fcontextFileTypeCombo = xml.get_object("fcontextFileTypeCombo")
+ self.fcontextTypeEntry = xml.get_object("fcontextTypeEntry")
+ self.fcontextMLSEntry = xml.get_object("fcontextMLSEntry")
def match(self, fcon_dict, k, filter):
try:
@@ -192,7 +189,7 @@ class fcontextPage(semanagePage):
mls = self.fcontextMLSEntry.get_text().strip()
list_model = self.fcontextFileTypeCombo.get_model()
it = self.fcontextFileTypeCombo.get_active_iter()
- ftype = list_model.get_value(it,0)
+ ftype = list_model.get_value(it, 0)
self.wait()
(rc, out) = getstatusoutput("semanage fcontext -a -t %s -r %s -f '%s' '%s'" % (type, mls, seobject.file_type_str_to_option[ftype], fspec))
self.ready()
diff --git selinux-gui-2.7/loginsPage.py selinux-gui-2.7/loginsPage.py
index 1f35a57..b67eb8b 100644
--- selinux-gui-2.7/loginsPage.py
+++ selinux-gui-2.7/loginsPage.py
@@ -16,17 +16,13 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
-import os
-import gobject
import sys
try:
from subprocess import getstatusoutput
except ImportError:
from commands import getstatusoutput
+from gi.repository import GObject, Gtk
import seobject
from semanagePage import *
@@ -57,23 +53,23 @@ class loginsPage(semanagePage):
def __init__(self, xml):
self.firstTime = False
semanagePage.__init__(self, xml, "logins", _("User Mapping"))
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING)
self.view.set_model(self.store)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Login\nName"), gtk.CellRendererText(), text=0)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Login\nName"), Gtk.CellRendererText(), text=0)
col.set_sort_column_id(0)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("SELinux\nUser"), gtk.CellRendererText(), text=1)
+ col = Gtk.TreeViewColumn(_("SELinux\nUser"), Gtk.CellRendererText(), text=1)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("MLS/\nMCS Range"), gtk.CellRendererText(), text=2)
+ col = Gtk.TreeViewColumn(_("MLS/\nMCS Range"), Gtk.CellRendererText(), text=2)
col.set_resizable(True)
self.view.append_column(col)
self.load()
- self.loginsNameEntry = xml.get_widget("loginsNameEntry")
- self.loginsSelinuxUserCombo = xml.get_widget("loginsSelinuxUserCombo")
- self.loginsMLSEntry = xml.get_widget("loginsMLSEntry")
+ self.loginsNameEntry = xml.get_object("loginsNameEntry")
+ self.loginsSelinuxUserCombo = xml.get_object("loginsSelinuxUserCombo")
+ self.loginsMLSEntry = xml.get_object("loginsMLSEntry")
def load(self, filter=""):
self.filter = filter
@@ -91,12 +87,12 @@ class loginsPage(semanagePage):
self.view.get_selection().select_path((0,))
def __dialogSetup(self):
- if self.firstTime == True:
+ if self.firstTime:
return
self.firstTime = True
- liststore = gtk.ListStore(gobject.TYPE_STRING)
+ liststore = Gtk.ListStore(GObject.TYPE_STRING)
self.loginsSelinuxUserCombo.set_model(liststore)
- cell = gtk.CellRendererText()
+ cell = Gtk.CellRendererText()
self.loginsSelinuxUserCombo.pack_start(cell, True)
self.loginsSelinuxUserCombo.add_attribute(cell, 'text', 0)
diff --git selinux-gui-2.7/modulesPage.py selinux-gui-2.7/modulesPage.py
index 3767896..34c5d9e 100644
--- selinux-gui-2.7/modulesPage.py
+++ selinux-gui-2.7/modulesPage.py
@@ -16,21 +16,16 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
-import os
+import sys
+from subprocess import Popen, PIPE
try:
from subprocess import getstatusoutput
except ImportError:
from commands import getstatusoutput
-import gobject
-import sys
-import seobject
+from gi.repository import GObject, Gtk
import selinux
from semanagePage import *
-from subprocess import Popen, PIPE
##
## I18N
@@ -58,27 +53,33 @@ class modulesPage(semanagePage):
def __init__(self, xml):
semanagePage.__init__(self, xml, "modules", _("Policy Module"))
- self.module_filter = xml.get_widget("modulesFilterEntry")
+ self.module_filter = xml.get_object("modulesFilterEntry")
self.module_filter.connect("focus_out_event", self.filter_changed)
self.module_filter.connect("activate", self.filter_changed)
self.audit_enabled = False
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING,
+ GObject.TYPE_STRING)
self.view.set_model(self.store)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Module Name"), gtk.CellRendererText(), text=0)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Module Name"), Gtk.CellRendererText(), text=0)
col.set_sort_column_id(0)
col.set_resizable(True)
self.view.append_column(col)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Version"), gtk.CellRendererText(), text=1)
- self.enable_audit_button = xml.get_widget("enableAuditButton")
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Priority"), Gtk.CellRendererText(), text=1)
+ self.enable_audit_button = xml.get_object("enableAuditButton")
self.enable_audit_button.connect("clicked", self.enable_audit)
- self.new_button = xml.get_widget("newModuleButton")
+ self.new_button = xml.get_object("newModuleButton")
self.new_button.connect("clicked", self.new_module)
col.set_sort_column_id(1)
col.set_resizable(True)
self.view.append_column(col)
+ self.store.set_sort_column_id(2, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Kind"), Gtk.CellRendererText(), text=2)
+ col.set_sort_column_id(2)
+ col.set_resizable(True)
+ self.view.append_column(col)
self.store.set_sort_func(1, self.sort_int, "")
status, self.policy_type = selinux.selinux_getpolicytype()
@@ -100,16 +101,17 @@ class modulesPage(semanagePage):
self.filter = filter
self.store.clear()
try:
- fd = Popen("semodule -l", shell=True, stdout=PIPE).stdout
+ fd = Popen("semodule -lfull", shell=True, stdout=PIPE).stdout
l = fd.readlines()
fd.close()
for i in l:
- module, ver, newline = i.split('\t')
- if not (self.match(module, filter) or self.match(ver, filter)):
+ priority, module, kind = i.decode('utf-8').split()
+ if not (self.match(module, filter) or self.match(priority, filter)):
continue
iter = self.store.append()
self.store.set_value(iter, 0, module.strip())
- self.store.set_value(iter, 1, ver.strip())
+ self.store.set_value(iter, 1, priority.strip())
+ self.store.set_value(iter, 2, kind.strip())
except:
pass
self.view.get_selection().select_path((0,))
@@ -170,20 +172,20 @@ class modulesPage(semanagePage):
return
def addDialog(self):
- dialog = gtk.FileChooserDialog(_("Load Policy Module"),
+ dialog = Gtk.FileChooserDialog(_("Load Policy Module"),
None,
- gtk.FILE_CHOOSER_ACTION_OPEN,
- (gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,
- gtk.STOCK_OPEN, gtk.RESPONSE_OK))
- dialog.set_default_response(gtk.RESPONSE_OK)
+ Gtk.FileChooserAction.OPEN,
+ (Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
+ Gtk.STOCK_OPEN, Gtk.ResponseType.OK))
+ dialog.set_default_response(Gtk.ResponseType.OK)
- filter = gtk.FileFilter()
+ filter = Gtk.FileFilter()
filter.set_name("Policy Files")
filter.add_pattern("*.pp")
dialog.add_filter(filter)
response = dialog.run()
- if response == gtk.RESPONSE_OK:
+ if response == Gtk.ResponseType.OK:
self.add(dialog.get_filename())
dialog.destroy()
diff --git selinux-gui-2.7/polgen.ui selinux-gui-2.7/polgen.ui
new file mode 100644
index 0000000..aa4c70a
--- /dev/null
+++ selinux-gui-2.7/polgen.ui
@@ -0,0 +1,2417 @@
+<?xml version="1.0"?>
+<interface>
+ <!-- interface-requires gtk+ 2.6 -->
+ <!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAboutDialog" id="about_dialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">5</property>
+ <property name="type_hint">normal</property>
+ <property name="copyright" translatable="yes">Red Hat 2007</property>
+ <property name="website">www.redhat.com</property>
+ <property name="license" translatable="yes">GPL</property>
+ <property name="authors">Daniel Walsh &lt;dwalsh@redhat.com&gt;</property>
+ <property comments="TRANSLATORS: Replace this string with your names, one name per line." name="translator_credits" translatable="yes">translator-credits</property>
+ <child internal-child="vbox">
+ <object class="GtkVBox" id="dialog-vbox3">
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkHButtonBox" id="dialog-action_area3">
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <object class="GtkDialog" id="boolean_dialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">12</property>
+ <property name="title" translatable="yes">Add Booleans Dialog</property>
+ <property name="window_position">mouse</property>
+ <property name="default_width">400</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkVBox" id="dialog-vbox2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child internal-child="action_area">
+ <object class="GtkHButtonBox" id="dialog-action_area2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="cancelbutton1">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="okbutton1">
+ <property name="label">gtk-add</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="table6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label48">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Boolean Name</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label49">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Description</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="boolean_name_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="boolean_description_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">cancelbutton1</action-widget>
+ <action-widget response="-5">okbutton1</action-widget>
+ </action-widgets>
+ </object>
+ <object class="GtkFileChooserDialog" id="filechooserdialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">5</property>
+ <property name="window_position">mouse</property>
+ <property name="type_hint">dialog</property>
+ <property name="select_multiple">True</property>
+ <property name="show_hidden">True</property>
+ <child internal-child="vbox">
+ <object class="GtkVBox" id="dialog-vbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">24</property>
+ <child internal-child="action_area">
+ <object class="GtkHButtonBox" id="dialog-action_area1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="button5">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button6">
+ <property name="label">gtk-add</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">button5</action-widget>
+ <action-widget response="-5">button6</action-widget>
+ </action-widgets>
+ </object>
+ <object class="GtkWindow" id="main_window">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">SELinux Policy Generation Tool</property>
+ <child>
+ <object class="GtkVBox" id="vbox11">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">18</property>
+ <child>
+ <object class="GtkNotebook" id="notebook">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tab_pos">left</property>
+ <property name="show_tabs">False</property>
+ <child>
+ <object class="GtkVBox" id="vbox59">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_type_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select the policy type for the application or user role you want to confine:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox58">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkVBox" id="vbox14">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkHBox" id="hbox16">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox18">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label41">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Applications&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox17">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label52">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkRadioButton" id="init_radiobutton">
+ <property name="label" translatable="yes">Standard Init Daemon</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Standard Init Daemon are daemons started on boot via init scripts. Usually requires a script in /etc/rc.d/init.d</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="dbus_radiobutton">
+ <property name="label" translatable="yes">DBUS System Daemon</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Standard Init Daemon are daemons started on boot via init scripts. Usually requires a script in /etc/rc.d/init.d</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="inetd_radiobutton">
+ <property name="label" translatable="yes">Internet Services Daemon (inetd)</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Internet Services Daemon are daemons started by xinetd</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="cgi_radiobutton">
+ <property name="label" translatable="yes">Web Application/Script (CGI)</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Web Applications/Script (CGI) CGI scripts started by the web server (apache)</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="user_radiobutton">
+ <property name="label" translatable="yes">User Application</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">User Application are any application that you would like to confine that is started by a user</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="sandbox_radiobutton">
+ <property name="label" translatable="yes">Sandbox</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">User Application are any application that you would like to confine that is started by a user</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">5</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox19">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label42">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Login Users&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox18">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label53">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkRadioButton" id="existing_user_radiobutton">
+ <property name="label" translatable="yes">Existing User Roles</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Modify an existing login user record.</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="terminal_user_radiobutton">
+ <property name="label" translatable="yes">Minimal Terminal User Role</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">This user will login to a machine only via a terminal or remote login. By default this user will have no setuid, no networking, no su, no sudo.</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="xwindows_user_radiobutton">
+ <property name="label" translatable="yes">Minimal X Windows User Role</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">This user can login to a machine via X or terminal. By default this user will have no setuid, no networking, no sudo, no su</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="login_user_radiobutton">
+ <property name="label" translatable="yes">User Role</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">User with full networking, no setuid applications without transition, no sudo, no su.</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="admin_user_radiobutton">
+ <property name="label" translatable="yes">Admin User Role</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">User with full networking, no setuid applications without transition, no su, can sudo to Root Administration Roles</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox20">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label50">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Root Users&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox19">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label54">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox21">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkRadioButton" id="root_user_radiobutton">
+ <property name="label" translatable="yes">Root Admin User Role</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Select Root Administrator User Role, if this user will be used to administer the machine while running as root. This user will not be able to login to the system directly.</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">init_radiobutton</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label104">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Main Tab</property>
+ </object>
+ <packing>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox60">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_name_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Enter name of application or user role:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkTable" id="table5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="n_rows">3</property>
+ <property name="n_columns">3</property>
+ <property name="column_spacing">12</property>
+ <property name="row_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Name</property>
+ </object>
+ <packing>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="exec_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Enter complete path for executable to be confined.</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="exec_button">
+ <property name="label" translatable="yes">...</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <signal handler="on_exec_select_clicked" name="clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="name_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Enter unique name for the confined application or user role.</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">3</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Executable</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label40">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Init script</property>
+ </object>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="init_script_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Enter complete path to init script used to start the confined application.</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="init_script_button">
+ <property name="label" translatable="yes">...</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <signal handler="on_init_script_select_clicked" name="clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"/>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="select_name_label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Name Tab</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox61">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_existing_role_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select existing role to modify:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow5">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="existing_user_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Select the user roles that will transiton to the %s domain.</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label106">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">role tab</property>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox62">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select roles that %s will transition to:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow12">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkTreeView" id="transition_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Select applications domains that %s will transition to.</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label107">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">transition
+role tab</property>
+ </object>
+ <packing>
+ <property name="position">3</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox63">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_user_roles_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select the user_roles that will transition to %s:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow13">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkTreeView" id="user_transition_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Select the user roles that will transiton to this applications domains.</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label108">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">User Tab</property>
+ </object>
+ <packing>
+ <property name="position">4</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox64">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_domain_admin_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select domains that %s will administer:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow14">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkTreeView" id="admin_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Select the domains that you would like this user administer.</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label109">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Admin Tab</property>
+ </object>
+ <packing>
+ <property name="position">5</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox65">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_role_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select additional roles for %s:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow15">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkTreeView" id="role_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Select the domains that you would like this user administer.</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="in_net_page">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Roles Tab</property>
+ </object>
+ <packing>
+ <property name="position">6</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="in_net_page1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_in_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Enter network ports that %s binds on:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox22">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label55">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;TCP Ports&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox20">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label56">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox23">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox21">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkCheckButton" id="in_tcp_all_checkbutton">
+ <property name="label" translatable="yes">All</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to bind to any udp port</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="in_tcp_reserved_checkbutton">
+ <property name="label" translatable="yes">600-1024</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allow %s to call bindresvport with 0. Binding to port 600-1024</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="in_tcp_unreserved_checkbutton">
+ <property name="label" translatable="yes">Unreserved Ports (&gt;1024)</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Enter a comma separated list of udp ports or ranges of ports that %s binds to. Example: 612, 650-660</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox22">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label57">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Select Ports</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="in_tcp_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to bind to any udp ports &gt; 1024</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox24">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label58">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;UDP Ports&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox23">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label59">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox25">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkHBox" id="hbox24">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkCheckButton" id="in_udp_all_checkbutton">
+ <property name="label" translatable="yes">All</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to bind to any udp port</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="in_udp_reserved_checkbutton">
+ <property name="label" translatable="yes">600-1024</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allow %s to call bindresvport with 0. Binding to port 600-1024</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="in_udp_unreserved_checkbutton">
+ <property name="label" translatable="yes">Unreserved Ports (&gt;1024)</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Enter a comma separated list of udp ports or ranges of ports that %s binds to. Example: 612, 650-660</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox25">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label60">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Select Ports</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="in_udp_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to bind to any udp ports &gt; 1024</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label113">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Network
+Bind tab</property>
+ </object>
+ <packing>
+ <property name="position">7</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox75">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_out_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select network ports that %s connects to:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox26">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label37">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;TCP Ports&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox26">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label61">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkCheckButton" id="out_tcp_all_checkbutton">
+ <property name="label" translatable="yes">All</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to connect to any tcp port</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label38">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Select Ports</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="out_tcp_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Enter a comma separated list of tcp ports or ranges of ports that %s connects to. Example: 612, 650-660</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox27">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label23">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;UDP Ports&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox27">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label62">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label"> </property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox12">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkCheckButton" id="out_udp_all_checkbutton">
+ <property name="label" translatable="yes">All</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip-text" translatable="yes">Allows %s to connect to any udp port</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label22">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Select Ports</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="out_udp_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Enter a comma separated list of udp ports or ranges of ports that %s connects to. Example: 612, 650-660</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label114">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Network
+Connect Tab</property>
+ </object>
+ <packing>
+ <property name="position">8</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox68">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_common_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select common application traits for %s:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkCheckButton" id="syslog_checkbutton">
+ <property name="label" translatable="yes">Writes syslog messages </property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="tmp_checkbutton">
+ <property name="label" translatable="yes">Create/Manipulate temporary files in /tmp</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="pam_checkbutton">
+ <property name="label" translatable="yes">Uses Pam for authentication</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="uid_checkbutton">
+ <property name="label" translatable="yes">Uses nsswitch or getpw* calls</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="dbus_checkbutton">
+ <property name="label" translatable="yes">Uses dbus</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="audit_checkbutton">
+ <property name="label" translatable="yes">Sends audit messages</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">5</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="terminal_checkbutton">
+ <property name="label" translatable="yes">Interacts with the terminal</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">6</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="mail_checkbutton">
+ <property name="label" translatable="yes">Sends email</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">7</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label115">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Common
+Tab</property>
+ </object>
+ <packing>
+ <property name="position">9</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox69">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_manages_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Add files/directories that %s manages&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkButton" id="button2">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <signal handler="on_add_clicked" name="clicked" swapped="no"/>
+ <child>
+ <object class="GtkAlignment" id="alignment6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-add</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label17">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label">Add File</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button9">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <signal handler="on_add_dir_clicked" name="clicked" swapped="no"/>
+ <child>
+ <object class="GtkAlignment" id="alignment5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-add</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label16">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label">Add Directory</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button4">
+ <property name="label">gtk-delete</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ <signal handler="on_delete_clicked" name="clicked" swapped="no"/>
+ <accelerator key="Delete" signal="clicked"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">4</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow2">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="write_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Files/Directories which the %s "manages". Pid Files, Log Files, /var/lib Files ...</property>
+ <property name="headers_visible">False</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="label116">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="no">Add Tab</property>
+ </object>
+ <packing>
+ <property name="position">10</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox70">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_booleans_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Add booleans from the %s policy:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkVBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkButton" id="button1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <signal handler="on_add_boolean_clicked" name="clicked" swapped="no"/>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-add</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label">Add Boolean</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button3">
+ <property name="label">gtk-delete</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ <signal handler="on_delete_boolean_clicked" name="clicked" swapped="no"/>
+ <accelerator key="Delete" signal="clicked"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">4</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">automatic</property>
+ <property name="vscrollbar_policy">automatic</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="boolean_treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip-text" translatable="yes">Add/Remove booleans used by the %s domain</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="position">11</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkVBox" id="vbox71">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="select_dir_label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">&lt;b&gt;Which directory you will generate the %s policy?&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label18">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Policy Directory</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="output_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">&#x2022;</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="output_button">
+ <property name="label" translatable="yes">...</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">12</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="tab">
+ <object class="GtkLabel" id="GtkLabel1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="position">12</property>
+ <property name="tab_fill">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHButtonBox" id="hbuttonbox2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="cancel_button">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="back_button">
+ <property name="label">gtk-go-back</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="forward_button">
+ <property name="label">gtk-go-forward</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+</interface>
diff --git selinux-gui-2.7/polgengui.py selinux-gui-2.7/polgengui.py
index 7460cce..cd73ea6 100644
--- selinux-gui-2.7/polgengui.py
+++ selinux-gui-2.7/polgengui.py
@@ -22,11 +22,11 @@
#
import signal
import string
-import gtk
-import gtk.glade
+import gi
+gi.require_version('Gtk', '3.0')
+from gi.repository import Gtk
import os
-import gobject
-import gnome
+from gi.repository import GObject
import sys
try:
import sepolicy
@@ -34,7 +34,9 @@ except ValueError as e:
sys.stderr.write("%s: %s\n" % (e.__class__.__name__, str(e)))
sys.exit(1)
+import sepolicy.generate
import sepolicy.interface
+
try:
from subprocess import getstatusoutput
except ImportError:
@@ -79,8 +81,6 @@ except:
import __builtin__
__builtin__.__dict__['_'] = unicode
-gnome.program_init("SELinux Policy Generation Tool", "5")
-
version = "1.0"
sys.path.append('/usr/share/system-config-selinux')
@@ -95,10 +95,12 @@ def foreach(model, path, iter, selected):
##
## Pull in the Glade file
##
-if os.access("polgen.glade", os.F_OK):
- xml = gtk.glade.XML("polgen.glade", domain=PROGNAME)
+xml = Gtk.Builder()
+xml.set_translation_domain(PROGNAME)
+if os.access("polgen.ui", os.F_OK):
+ xml.add_from_file("polgen.ui")
else:
- xml = gtk.glade.XML("/usr/share/system-config-selinux/polgen.glade", domain=PROGNAME)
+ xml.add_from_file("/usr/share/system-config-selinux/polgen.ui")
FILE = 1
DIR = 2
@@ -123,82 +125,82 @@ class childWindow:
def __init__(self):
self.xml = xml
- self.notebook = xml.get_widget("notebook")
+ self.notebook = xml.get_object("notebook")
self.label_dict = {}
self.tooltip_dict = {}
- label = xml.get_widget("select_label")
+ label = xml.get_object("select_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_user_roles_label")
+ label = xml.get_object("select_user_roles_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_dir_label")
+ label = xml.get_object("select_dir_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_domain_admin_label")
+ label = xml.get_object("select_domain_admin_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_in_label")
+ label = xml.get_object("select_in_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_out_label")
+ label = xml.get_object("select_out_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_common_label")
+ label = xml.get_object("select_common_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_manages_label")
+ label = xml.get_object("select_manages_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("select_booleans_label")
+ label = xml.get_object("select_booleans_label")
self.label_dict[label] = label.get_text()
- label = xml.get_widget("existing_user_treeview")
+ label = xml.get_object("existing_user_treeview")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("transition_treeview")
+ label = xml.get_object("transition_treeview")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_tcp_all_checkbutton")
+ label = xml.get_object("in_tcp_all_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_tcp_reserved_checkbutton")
+ label = xml.get_object("in_tcp_reserved_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_tcp_unreserved_checkbutton")
+ label = xml.get_object("in_tcp_unreserved_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_tcp_entry")
+ label = xml.get_object("in_tcp_entry")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_udp_all_checkbutton")
+ label = xml.get_object("in_udp_all_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_udp_reserved_checkbutton")
+ label = xml.get_object("in_udp_reserved_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_udp_unreserved_checkbutton")
+ label = xml.get_object("in_udp_unreserved_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("in_udp_entry")
+ label = xml.get_object("in_udp_entry")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("out_tcp_entry")
+ label = xml.get_object("out_tcp_entry")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("out_udp_entry")
+ label = xml.get_object("out_udp_entry")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("out_tcp_all_checkbutton")
+ label = xml.get_object("out_tcp_all_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("out_udp_all_checkbutton")
+ label = xml.get_object("out_udp_all_checkbutton")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("boolean_treeview")
+ label = xml.get_object("boolean_treeview")
self.tooltip_dict[label] = label.get_tooltip_text()
- label = xml.get_widget("write_treeview")
+ label = xml.get_object("write_treeview")
self.tooltip_dict[label] = label.get_tooltip_text()
try:
@@ -214,23 +216,26 @@ class childWindow:
self.error(str(e))
self.name = ""
- xml.signal_connect("on_delete_clicked", self.delete)
- xml.signal_connect("on_delete_boolean_clicked", self.delete_boolean)
- xml.signal_connect("on_exec_select_clicked", self.exec_select)
- xml.signal_connect("on_init_script_select_clicked", self.init_script_select)
- xml.signal_connect("on_add_clicked", self.add)
- xml.signal_connect("on_add_boolean_clicked", self.add_boolean)
- xml.signal_connect("on_add_dir_clicked", self.add_dir)
- xml.signal_connect("on_about_clicked", self.on_about_clicked)
- xml.get_widget("cancel_button").connect("clicked", self.quit)
- self.forward_button = xml.get_widget("forward_button")
+ handlers = {
+ "on_delete_clicked": self.delete,
+ "on_delete_boolean_clicked": self.delete_boolean,
+ "on_exec_select_clicked": self.exec_select,
+ "on_init_script_select_clicked": self.init_script_select,
+ "on_add_clicked": self.add,
+ "on_add_boolean_clicked": self.add_boolean,
+ "on_add_dir_clicked": self.add_dir,
+ "on_about_clicked": self.on_about_clicked
+ }
+ xml.connect_signals(handlers)
+ xml.get_object("cancel_button").connect("clicked", self.quit)
+ self.forward_button = xml.get_object("forward_button")
self.forward_button.connect("clicked", self.forward)
- self.back_button = xml.get_widget("back_button")
+ self.back_button = xml.get_object("back_button")
self.back_button.connect("clicked", self.back)
- self.boolean_dialog = xml.get_widget("boolean_dialog")
- self.boolean_name_entry = xml.get_widget("boolean_name_entry")
- self.boolean_description_entry = xml.get_widget("boolean_description_entry")
+ self.boolean_dialog = xml.get_object("boolean_dialog")
+ self.boolean_name_entry = xml.get_object("boolean_name_entry")
+ self.boolean_description_entry = xml.get_object("boolean_description_entry")
self.pages = {}
for i in sepolicy.generate.USERS:
@@ -249,77 +254,77 @@ class childWindow:
self.network_buttons = {}
- self.in_tcp_all_checkbutton = xml.get_widget("in_tcp_all_checkbutton")
- self.in_tcp_reserved_checkbutton = xml.get_widget("in_tcp_reserved_checkbutton")
- self.in_tcp_unreserved_checkbutton = xml.get_widget("in_tcp_unreserved_checkbutton")
- self.in_tcp_entry = self.xml.get_widget("in_tcp_entry")
+ self.in_tcp_all_checkbutton = xml.get_object("in_tcp_all_checkbutton")
+ self.in_tcp_reserved_checkbutton = xml.get_object("in_tcp_reserved_checkbutton")
+ self.in_tcp_unreserved_checkbutton = xml.get_object("in_tcp_unreserved_checkbutton")
+ self.in_tcp_entry = self.xml.get_object("in_tcp_entry")
self.network_buttons[self.in_tcp_all_checkbutton] = [self.in_tcp_reserved_checkbutton, self.in_tcp_unreserved_checkbutton, self.in_tcp_entry]
- self.out_tcp_all_checkbutton = xml.get_widget("out_tcp_all_checkbutton")
- self.out_tcp_reserved_checkbutton = xml.get_widget("out_tcp_reserved_checkbutton")
- self.out_tcp_unreserved_checkbutton = xml.get_widget("out_tcp_unreserved_checkbutton")
- self.out_tcp_entry = self.xml.get_widget("out_tcp_entry")
+ self.out_tcp_all_checkbutton = xml.get_object("out_tcp_all_checkbutton")
+ self.out_tcp_reserved_checkbutton = xml.get_object("out_tcp_reserved_checkbutton")
+ self.out_tcp_unreserved_checkbutton = xml.get_object("out_tcp_unreserved_checkbutton")
+ self.out_tcp_entry = self.xml.get_object("out_tcp_entry")
self.network_buttons[self.out_tcp_all_checkbutton] = [self.out_tcp_entry]
- self.in_udp_all_checkbutton = xml.get_widget("in_udp_all_checkbutton")
- self.in_udp_reserved_checkbutton = xml.get_widget("in_udp_reserved_checkbutton")
- self.in_udp_unreserved_checkbutton = xml.get_widget("in_udp_unreserved_checkbutton")
- self.in_udp_entry = self.xml.get_widget("in_udp_entry")
+ self.in_udp_all_checkbutton = xml.get_object("in_udp_all_checkbutton")
+ self.in_udp_reserved_checkbutton = xml.get_object("in_udp_reserved_checkbutton")
+ self.in_udp_unreserved_checkbutton = xml.get_object("in_udp_unreserved_checkbutton")
+ self.in_udp_entry = self.xml.get_object("in_udp_entry")
self.network_buttons[self.in_udp_all_checkbutton] = [self.in_udp_reserved_checkbutton, self.in_udp_unreserved_checkbutton, self.in_udp_entry]
- self.out_udp_all_checkbutton = xml.get_widget("out_udp_all_checkbutton")
- self.out_udp_entry = self.xml.get_widget("out_udp_entry")
+ self.out_udp_all_checkbutton = xml.get_object("out_udp_all_checkbutton")
+ self.out_udp_entry = self.xml.get_object("out_udp_entry")
self.network_buttons[self.out_udp_all_checkbutton] = [self.out_udp_entry]
for b in self.network_buttons.keys():
b.connect("clicked", self.network_all_clicked)
- self.boolean_treeview = self.xml.get_widget("boolean_treeview")
- self.boolean_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.boolean_treeview = self.xml.get_object("boolean_treeview")
+ self.boolean_store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING)
self.boolean_treeview.set_model(self.boolean_store)
- self.boolean_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Name"), gtk.CellRendererText(), text=0)
+ self.boolean_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Name"), Gtk.CellRendererText(), text=0)
self.boolean_treeview.append_column(col)
- col = gtk.TreeViewColumn(_("Description"), gtk.CellRendererText(), text=1)
+ col = Gtk.TreeViewColumn(_("Description"), Gtk.CellRendererText(), text=1)
self.boolean_treeview.append_column(col)
- self.role_treeview = self.xml.get_widget("role_treeview")
- self.role_store = gtk.ListStore(gobject.TYPE_STRING)
+ self.role_treeview = self.xml.get_object("role_treeview")
+ self.role_store = Gtk.ListStore(GObject.TYPE_STRING)
self.role_treeview.set_model(self.role_store)
- self.role_treeview.get_selection().set_mode(gtk.SELECTION_MULTIPLE)
- self.role_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Role"), gtk.CellRendererText(), text=0)
+ self.role_treeview.get_selection().set_mode(Gtk.SelectionMode.MULTIPLE)
+ self.role_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Role"), Gtk.CellRendererText(), text=0)
self.role_treeview.append_column(col)
- self.existing_user_treeview = self.xml.get_widget("existing_user_treeview")
- self.existing_user_store = gtk.ListStore(gobject.TYPE_STRING)
+ self.existing_user_treeview = self.xml.get_object("existing_user_treeview")
+ self.existing_user_store = Gtk.ListStore(GObject.TYPE_STRING)
self.existing_user_treeview.set_model(self.existing_user_store)
- self.existing_user_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Existing_User"), gtk.CellRendererText(), text=0)
+ self.existing_user_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Existing_User"), Gtk.CellRendererText(), text=0)
self.existing_user_treeview.append_column(col)
for i in self.all_roles:
iter = self.role_store.append()
self.role_store.set_value(iter, 0, i[:-2])
- self.in_tcp_reserved_checkbutton = xml.get_widget("in_tcp_reserved_checkbutton")
+ self.in_tcp_reserved_checkbutton = xml.get_object("in_tcp_reserved_checkbutton")
- self.transition_treeview = self.xml.get_widget("transition_treeview")
- self.transition_store = gtk.ListStore(gobject.TYPE_STRING)
+ self.transition_treeview = self.xml.get_object("transition_treeview")
+ self.transition_store = Gtk.ListStore(GObject.TYPE_STRING)
self.transition_treeview.set_model(self.transition_store)
- self.transition_treeview.get_selection().set_mode(gtk.SELECTION_MULTIPLE)
- self.transition_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Application"), gtk.CellRendererText(), text=0)
+ self.transition_treeview.get_selection().set_mode(Gtk.SelectionMode.MULTIPLE)
+ self.transition_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Application"), Gtk.CellRendererText(), text=0)
self.transition_treeview.append_column(col)
- self.user_transition_treeview = self.xml.get_widget("user_transition_treeview")
- self.user_transition_store = gtk.ListStore(gobject.TYPE_STRING)
+ self.user_transition_treeview = self.xml.get_object("user_transition_treeview")
+ self.user_transition_store = Gtk.ListStore(GObject.TYPE_STRING)
self.user_transition_treeview.set_model(self.user_transition_store)
- self.user_transition_treeview.get_selection().set_mode(gtk.SELECTION_MULTIPLE)
- self.user_transition_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Application"), gtk.CellRendererText(), text=0)
+ self.user_transition_treeview.get_selection().set_mode(Gtk.SelectionMode.MULTIPLE)
+ self.user_transition_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Application"), Gtk.CellRendererText(), text=0)
self.user_transition_treeview.append_column(col)
for i in self.all_users:
@@ -328,12 +333,12 @@ class childWindow:
iter = self.existing_user_store.append()
self.existing_user_store.set_value(iter, 0, i[:-2])
- self.admin_treeview = self.xml.get_widget("admin_treeview")
- self.admin_store = gtk.ListStore(gobject.TYPE_STRING)
+ self.admin_treeview = self.xml.get_object("admin_treeview")
+ self.admin_store = Gtk.ListStore(GObject.TYPE_STRING)
self.admin_treeview.set_model(self.admin_store)
- self.admin_treeview.get_selection().set_mode(gtk.SELECTION_MULTIPLE)
- self.admin_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
- col = gtk.TreeViewColumn(_("Application"), gtk.CellRendererText(), text=0)
+ self.admin_treeview.get_selection().set_mode(Gtk.SelectionMode.MULTIPLE)
+ self.admin_store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
+ col = Gtk.TreeViewColumn(_("Application"), Gtk.CellRendererText(), text=0)
self.admin_treeview.append_column(col)
try:
@@ -383,17 +388,17 @@ class childWindow:
if self.pages[type][self.current_page] == self.FINISH_PAGE:
self.generate_policy()
- self.xml.get_widget("cancel_button").set_label(gtk.STOCK_CLOSE)
+ self.xml.get_object("cancel_button").set_label(Gtk.STOCK_CLOSE)
else:
self.current_page = self.current_page + 1
self.notebook.set_current_page(self.pages[type][self.current_page])
if self.pages[type][self.current_page] == self.FINISH_PAGE:
- self.forward_button.set_label(gtk.STOCK_APPLY)
+ self.forward_button.set_label(Gtk.STOCK_APPLY)
def back(self, arg):
type = self.get_type()
if self.pages[type][self.current_page] == self.FINISH_PAGE:
- self.forward_button.set_label(gtk.STOCK_GO_FORWARD)
+ self.forward_button.set_label(Gtk.STOCK_GO_FORWARD)
self.current_page = self.current_page - 1
self.notebook.set_current_page(self.pages[type][self.current_page])
@@ -406,30 +411,30 @@ class childWindow:
b.set_sensitive(not active)
def verify(self, message, title=""):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_INFO,
- gtk.BUTTONS_YES_NO,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.INFO,
+ Gtk.ButtonsType.YES_NO,
message)
dlg.set_title(title)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
rc = dlg.run()
dlg.destroy()
return rc
def info(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_INFO,
- gtk.BUTTONS_OK,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.INFO,
+ Gtk.ButtonsType.OK,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
dlg.run()
dlg.destroy()
def error(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_ERROR,
- gtk.BUTTONS_CLOSE,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.ERROR,
+ Gtk.ButtonsType.CLOSE,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
dlg.run()
dlg.destroy()
@@ -550,7 +555,7 @@ class childWindow:
self.boolean_description_entry.set_text("")
rc = self.boolean_dialog.run()
self.boolean_dialog.hide()
- if rc == gtk.RESPONSE_CANCEL:
+ if rc == Gtk.ResponseType.CANCEL:
return
iter = self.boolean_store.append()
self.boolean_store.set_value(iter, 0, self.boolean_name_entry.get_text())
@@ -559,7 +564,7 @@ class childWindow:
def __add(self, type):
rc = self.file_dialog.run()
self.file_dialog.hide()
- if rc == gtk.RESPONSE_CANCEL:
+ if rc == Gtk.ResponseType.CANCEL:
return
for i in self.file_dialog.get_filenames():
iter = self.store.append()
@@ -569,29 +574,29 @@ class childWindow:
def exec_select(self, args):
self.file_dialog.set_select_multiple(0)
self.file_dialog.set_title(_("Select executable file to be confined."))
- self.file_dialog.set_action(gtk.FILE_CHOOSER_ACTION_OPEN)
+ self.file_dialog.set_action(Gtk.FileChooserAction.OPEN)
self.file_dialog.set_current_folder("/usr/sbin")
rc = self.file_dialog.run()
self.file_dialog.hide()
- if rc == gtk.RESPONSE_CANCEL:
+ if rc == Gtk.ResponseType.CANCEL:
return
self.exec_entry.set_text(self.file_dialog.get_filename())
def init_script_select(self, args):
self.file_dialog.set_select_multiple(0)
self.file_dialog.set_title(_("Select init script file to be confined."))
- self.file_dialog.set_action(gtk.FILE_CHOOSER_ACTION_OPEN)
+ self.file_dialog.set_action(Gtk.FileChooserAction.OPEN)
self.file_dialog.set_current_folder("/etc/rc.d/init.d")
rc = self.file_dialog.run()
self.file_dialog.hide()
- if rc == gtk.RESPONSE_CANCEL:
+ if rc == Gtk.ResponseType.CANCEL:
return
self.init_script_entry.set_text(self.file_dialog.get_filename())
def add(self, args):
self.file_dialog.set_title(_("Select file(s) that confined application creates or writes"))
self.file_dialog.set_current_folder("/")
- self.file_dialog.set_action(gtk.FILE_CHOOSER_ACTION_OPEN)
+ self.file_dialog.set_action(Gtk.FileChooserAction.OPEN)
self.file_dialog.set_select_multiple(1)
self.__add(FILE)
@@ -599,71 +604,71 @@ class childWindow:
self.file_dialog.set_title(_("Select directory(s) that the confined application owns and writes into"))
self.file_dialog.set_current_folder("/")
self.file_dialog.set_select_multiple(1)
- self.file_dialog.set_action(gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER)
+ self.file_dialog.set_action(Gtk.FileChooserAction.SELECT_FOLDER)
self.__add(DIR)
def on_about_clicked(self, args):
- dlg = xml.get_widget("about_dialog")
+ dlg = xml.get_object("about_dialog")
dlg.run()
dlg.hide()
def quit(self, args):
- gtk.main_quit()
+ Gtk.main_quit()
def setupScreen(self):
# Bring in widgets from glade file.
- self.mainWindow = self.xml.get_widget("main_window")
- self.druid = self.xml.get_widget("druid")
+ self.mainWindow = self.xml.get_object("main_window")
+ self.druid = self.xml.get_object("druid")
self.type = 0
- self.name_entry = self.xml.get_widget("name_entry")
+ self.name_entry = self.xml.get_object("name_entry")
self.name_entry.connect("insert_text", self.on_name_entry_changed)
self.name_entry.connect("focus_out_event", self.on_focus_out_event)
- self.exec_entry = self.xml.get_widget("exec_entry")
- self.exec_button = self.xml.get_widget("exec_button")
- self.init_script_entry = self.xml.get_widget("init_script_entry")
- self.init_script_button = self.xml.get_widget("init_script_button")
- self.output_entry = self.xml.get_widget("output_entry")
+ self.exec_entry = self.xml.get_object("exec_entry")
+ self.exec_button = self.xml.get_object("exec_button")
+ self.init_script_entry = self.xml.get_object("init_script_entry")
+ self.init_script_button = self.xml.get_object("init_script_button")
+ self.output_entry = self.xml.get_object("output_entry")
self.output_entry.set_text(os.getcwd())
- self.xml.get_widget("output_button").connect("clicked", self.output_button_clicked)
-
- self.xwindows_user_radiobutton = self.xml.get_widget("xwindows_user_radiobutton")
- self.terminal_user_radiobutton = self.xml.get_widget("terminal_user_radiobutton")
- self.root_user_radiobutton = self.xml.get_widget("root_user_radiobutton")
- self.login_user_radiobutton = self.xml.get_widget("login_user_radiobutton")
- self.admin_user_radiobutton = self.xml.get_widget("admin_user_radiobutton")
- self.existing_user_radiobutton = self.xml.get_widget("existing_user_radiobutton")
-
- self.user_radiobutton = self.xml.get_widget("user_radiobutton")
- self.init_radiobutton = self.xml.get_widget("init_radiobutton")
- self.inetd_radiobutton = self.xml.get_widget("inetd_radiobutton")
- self.dbus_radiobutton = self.xml.get_widget("dbus_radiobutton")
- self.cgi_radiobutton = self.xml.get_widget("cgi_radiobutton")
- self.sandbox_radiobutton = self.xml.get_widget("sandbox_radiobutton")
- self.tmp_checkbutton = self.xml.get_widget("tmp_checkbutton")
- self.uid_checkbutton = self.xml.get_widget("uid_checkbutton")
- self.pam_checkbutton = self.xml.get_widget("pam_checkbutton")
- self.dbus_checkbutton = self.xml.get_widget("dbus_checkbutton")
- self.audit_checkbutton = self.xml.get_widget("audit_checkbutton")
- self.terminal_checkbutton = self.xml.get_widget("terminal_checkbutton")
- self.mail_checkbutton = self.xml.get_widget("mail_checkbutton")
- self.syslog_checkbutton = self.xml.get_widget("syslog_checkbutton")
- self.view = self.xml.get_widget("write_treeview")
- self.file_dialog = self.xml.get_widget("filechooserdialog")
-
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_INT)
+ self.xml.get_object("output_button").connect("clicked", self.output_button_clicked)
+
+ self.xwindows_user_radiobutton = self.xml.get_object("xwindows_user_radiobutton")
+ self.terminal_user_radiobutton = self.xml.get_object("terminal_user_radiobutton")
+ self.root_user_radiobutton = self.xml.get_object("root_user_radiobutton")
+ self.login_user_radiobutton = self.xml.get_object("login_user_radiobutton")
+ self.admin_user_radiobutton = self.xml.get_object("admin_user_radiobutton")
+ self.existing_user_radiobutton = self.xml.get_object("existing_user_radiobutton")
+
+ self.user_radiobutton = self.xml.get_object("user_radiobutton")
+ self.init_radiobutton = self.xml.get_object("init_radiobutton")
+ self.inetd_radiobutton = self.xml.get_object("inetd_radiobutton")
+ self.dbus_radiobutton = self.xml.get_object("dbus_radiobutton")
+ self.cgi_radiobutton = self.xml.get_object("cgi_radiobutton")
+ self.sandbox_radiobutton = self.xml.get_object("sandbox_radiobutton")
+ self.tmp_checkbutton = self.xml.get_object("tmp_checkbutton")
+ self.uid_checkbutton = self.xml.get_object("uid_checkbutton")
+ self.pam_checkbutton = self.xml.get_object("pam_checkbutton")
+ self.dbus_checkbutton = self.xml.get_object("dbus_checkbutton")
+ self.audit_checkbutton = self.xml.get_object("audit_checkbutton")
+ self.terminal_checkbutton = self.xml.get_object("terminal_checkbutton")
+ self.mail_checkbutton = self.xml.get_object("mail_checkbutton")
+ self.syslog_checkbutton = self.xml.get_object("syslog_checkbutton")
+ self.view = self.xml.get_object("write_treeview")
+ self.file_dialog = self.xml.get_object("filechooserdialog")
+
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_INT)
self.view.set_model(self.store)
- col = gtk.TreeViewColumn("", gtk.CellRendererText(), text=0)
+ col = Gtk.TreeViewColumn("", Gtk.CellRendererText(), text=0)
col.set_resizable(True)
self.view.append_column(col)
self.view.get_selection().select_path((0,))
def output_button_clicked(self, *args):
self.file_dialog.set_title(_("Select directory to generate policy files in"))
- self.file_dialog.set_action(gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER)
+ self.file_dialog.set_action(Gtk.FileChooserAction.SELECT_FOLDER)
self.file_dialog.set_select_multiple(0)
rc = self.file_dialog.run()
self.file_dialog.hide()
- if rc == gtk.RESPONSE_CANCEL:
+ if rc == Gtk.ResponseType.CANCEL:
return
self.output_entry.set_text(self.file_dialog.get_filename())
@@ -675,11 +680,11 @@ class childWindow:
name = entry.get_text()
if self.name != name:
if name in self.all_types:
- if self.verify(_("Type %s_t already defined in current policy.\nDo you want to continue?") % name, _("Verify Name")) == gtk.RESPONSE_NO:
+ if self.verify(_("Type %s_t already defined in current policy.\nDo you want to continue?") % name, _("Verify Name")) == Gtk.ResponseType.NO:
entry.set_text("")
return False
if name in self.all_modules:
- if self.verify(_("Module %s already loaded in current policy.\nDo you want to continue?") % name, _("Verify Name")) == gtk.RESPONSE_NO:
+ if self.verify(_("Module %s already loaded in current policy.\nDo you want to continue?") % name, _("Verify Name")) == Gtk.ResponseType.NO:
entry.set_text("")
return False
@@ -696,16 +701,16 @@ class childWindow:
def on_in_net_page_next(self, *args):
try:
- generate.verify_ports(self.in_tcp_entry.get_text())
- generate.verify_ports(self.in_udp_entry.get_text())
+ sepolicy.generate.verify_ports(self.in_tcp_entry.get_text())
+ sepolicy.generate.verify_ports(self.in_udp_entry.get_text())
except ValueError as e:
self.error(e.message)
return True
def on_out_net_page_next(self, *args):
try:
- generate.verify_ports(self.out_tcp_entry.get_text())
- generate.verify_ports(self.out_udp_entry.get_text())
+ sepolicy.generate.verify_ports(self.out_tcp_entry.get_text())
+ sepolicy.generate.verify_ports(self.out_udp_entry.get_text())
except ValueError as e:
self.error(e.message)
return True
@@ -741,7 +746,7 @@ class childWindow:
if exe == "":
self.error(_("You must enter a executable"))
return True
- policy = generate.policy(name, self.get_type())
+ policy = sepolicy.generate.policy(name, self.get_type())
policy.set_program(exe)
policy.gen_writeable()
policy.gen_symbols()
@@ -770,7 +775,7 @@ class childWindow:
self.mainWindow.connect("destroy", self.quit)
self.mainWindow.show_all()
- gtk.main()
+ Gtk.main()
if __name__ == "__main__":
signal.signal(signal.SIGINT, signal.SIG_DFL)
diff --git selinux-gui-2.7/portsPage.py selinux-gui-2.7/portsPage.py
index b8fdaad..03179c5 100644
--- selinux-gui-2.7/portsPage.py
+++ selinux-gui-2.7/portsPage.py
@@ -16,12 +16,8 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
-import os
-import gobject
import sys
+from gi.repository import GObject, Gtk
import seobject
TYPE_COL = 0
@@ -40,6 +36,12 @@ from semanagePage import *
## I18N
##
PROGNAME = "policycoreutils"
+
+TYPE_COL = 0
+PROTOCOL_COL = 1
+MLS_COL = 2
+PORT_COL = 3
+
try:
import gettext
kwargs = {}
@@ -62,18 +64,19 @@ class portsPage(semanagePage):
def __init__(self, xml):
semanagePage.__init__(self, xml, "ports", _("Network Port"))
- xml.signal_connect("on_group_clicked", self.on_group_clicked)
+ group_listview = xml.get_object("listViewButton")
+ group_listview.connect("clicked", self.on_group_clicked)
self.group = False
- self.ports_filter = xml.get_widget("portsFilterEntry")
+ self.ports_filter = xml.get_object("portsFilterEntry")
self.ports_filter.connect("focus_out_event", self.filter_changed)
self.ports_filter.connect("activate", self.filter_changed)
- self.ports_name_entry = xml.get_widget("portsNameEntry")
- self.ports_protocol_combo = xml.get_widget("portsProtocolCombo")
- self.ports_number_entry = xml.get_widget("portsNumberEntry")
- self.ports_mls_entry = xml.get_widget("portsMLSEntry")
- self.ports_add_button = xml.get_widget("portsAddButton")
- self.ports_properties_button = xml.get_widget("portsPropertiesButton")
- self.ports_delete_button = xml.get_widget("portsDeleteButton")
+ self.ports_name_entry = xml.get_object("portsNameEntry")
+ self.ports_protocol_combo = xml.get_object("portsProtocolCombo")
+ self.ports_number_entry = xml.get_object("portsNumberEntry")
+ self.ports_mls_entry = xml.get_object("portsMLSEntry")
+ self.ports_add_button = xml.get_object("portsAddButton")
+ self.ports_properties_button = xml.get_object("portsPropertiesButton")
+ self.ports_delete_button = xml.get_object("portsDeleteButton")
liststore = self.ports_protocol_combo.get_model()
iter = liststore.get_iter_first()
self.ports_protocol_combo.set_active_iter(iter)
@@ -90,28 +93,28 @@ class portsPage(semanagePage):
self.group_load(filter)
def init_store(self):
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING)
self.view.set_model(self.store)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
self.view.set_search_equal_func(self.search)
- col = gtk.TreeViewColumn(_("SELinux Port\nType"), gtk.CellRendererText(), text=TYPE_COL)
+ col = Gtk.TreeViewColumn(_("SELinux Port\nType"), Gtk.CellRendererText(), text=TYPE_COL)
col.set_sort_column_id(TYPE_COL)
col.set_resizable(True)
self.view.append_column(col)
- self.store.set_sort_column_id(TYPE_COL, gtk.SORT_ASCENDING)
+ self.store.set_sort_column_id(TYPE_COL, Gtk.SortType.ASCENDING)
- col = gtk.TreeViewColumn(_("Protocol"), gtk.CellRendererText(), text=PROTOCOL_COL)
+ col = Gtk.TreeViewColumn(_("Protocol"), Gtk.CellRendererText(), text=PROTOCOL_COL)
col.set_sort_column_id(PROTOCOL_COL)
col.set_resizable(True)
self.view.append_column(col)
- self.mls_col = gtk.TreeViewColumn(_("MLS/MCS\nLevel"), gtk.CellRendererText(), text=MLS_COL)
+ self.mls_col = Gtk.TreeViewColumn(_("MLS/MCS\nLevel"), Gtk.CellRendererText(), text=MLS_COL)
self.mls_col.set_resizable(True)
self.mls_col.set_sort_column_id(MLS_COL)
self.view.append_column(self.mls_col)
- col = gtk.TreeViewColumn(_("Port"), gtk.CellRendererText(), text=PORT_COL)
+ col = Gtk.TreeViewColumn(_("Port"), Gtk.CellRendererText(), text=PORT_COL)
col.set_sort_column_id(PORT_COL)
col.set_resizable(True)
self.view.append_column(col)
@@ -139,7 +142,7 @@ class portsPage(semanagePage):
continue
iter = self.store.append()
if k[0] == k[1]:
- self.store.set_value(iter, PORT_COL, k[0])
+ self.store.set_value(iter, PORT_COL, str(k[0]))
else:
rec = "%s-%s" % k[:2]
self.store.set_value(iter, PORT_COL, rec)
diff --git selinux-gui-2.7/semanagePage.py selinux-gui-2.7/semanagePage.py
index 27367f3..560ec07 100644
--- selinux-gui-2.7/semanagePage.py
+++ selinux-gui-2.7/semanagePage.py
@@ -16,13 +16,8 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
-import os
-import gobject
import sys
-import seobject
+from gi.repository import Gdk, Gtk
##
## I18N
@@ -47,24 +42,25 @@ except:
def idle_func():
- while gtk.events_pending():
- gtk.main_iteration()
+ while Gtk.events_pending():
+ Gtk.main_iteration()
class semanagePage:
def __init__(self, xml, name, description):
self.xml = xml
- self.window = self.xml.get_widget("mainWindow").get_root_window()
- self.busy_cursor = gtk.gdk.Cursor(gtk.gdk.WATCH)
- self.ready_cursor = gtk.gdk.Cursor(gtk.gdk.LEFT_PTR)
+ self.window = self.xml.get_object("mainWindow").get_root_window()
+ self.busy_cursor = Gdk.Cursor.new(Gdk.CursorType.WATCH)
+ self.ready_cursor = Gdk.Cursor.new(Gdk.CursorType.LEFT_PTR)
self.local = False
- self.view = xml.get_widget("%sView" % name)
- self.dialog = xml.get_widget("%sDialog" % name)
- self.filter_entry = xml.get_widget("%sFilterEntry" % name)
+ self.view = xml.get_object("%sView" % name)
+ self.dialog = xml.get_object("%sDialog" % name)
+ self.filter_entry = xml.get_object("%sFilterEntry" % name)
self.filter_entry.connect("focus_out_event", self.filter_changed)
self.filter_entry.connect("activate", self.filter_changed)
+ self.filter_entry.connect("changed", self.filter_changed)
self.view.connect("row_activated", self.rowActivated)
self.view.get_selection().connect("changed", self.itemSelected)
@@ -81,7 +77,7 @@ class semanagePage:
def get_description(self):
return self.description
- def itemSelected(self, args):
+ def itemSelected(self, selection):
return
def filter_changed(self, *arg):
@@ -110,28 +106,28 @@ class semanagePage:
self.propertiesDialog()
def verify(self, message, title=""):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_INFO,
- gtk.BUTTONS_YES_NO,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.INFO,
+ Gtk.ButtonsType.YES_NO,
message)
dlg.set_title(title)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
rc = dlg.run()
dlg.destroy()
return rc
def error(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_ERROR,
- gtk.BUTTONS_CLOSE,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.ERROR,
+ Gtk.ButtonsType.CLOSE,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
dlg.run()
dlg.destroy()
def deleteDialog(self):
store, it = self.view.get_selection().get_selected()
- if (it is not None) and (self.verify(_("Are you sure you want to delete %s '%s'?" % (self.description, store.get_value(it, 0))), _("Delete %s" % self.description)) == gtk.RESPONSE_YES):
+ if (it is not None) and (self.verify(_("Are you sure you want to delete %s '%s'?" % (self.description, store.get_value(it, 0))), _("Delete %s" % self.description)) == Gtk.ResponseType.YES):
self.delete()
def use_menus(self):
@@ -140,11 +136,11 @@ class semanagePage:
def addDialog(self):
self.dialogClear()
self.dialog.set_title(_("Add %s" % self.description))
- self.dialog.set_position(gtk.WIN_POS_MOUSE)
+ self.dialog.set_position(Gtk.WindowPosition.MOUSE)
- while self.dialog.run() == gtk.RESPONSE_OK:
+ while self.dialog.run() == Gtk.ResponseType.OK:
try:
- if self.add() == False:
+ if not self.add():
continue
break
except ValueError as e:
@@ -154,10 +150,10 @@ class semanagePage:
def propertiesDialog(self):
self.dialogInit()
self.dialog.set_title(_("Modify %s" % self.description))
- self.dialog.set_position(gtk.WIN_POS_MOUSE)
- while self.dialog.run() == gtk.RESPONSE_OK:
+ self.dialog.set_position(Gtk.WindowPosition.MOUSE)
+ while self.dialog.run() == Gtk.ResponseType.OK:
try:
- if self.modify() == False:
+ if not self.modify():
continue
break
except ValueError as e:
diff --git selinux-gui-2.7/statusPage.py selinux-gui-2.7/statusPage.py
index 23d0d0f..766854b 100644
--- selinux-gui-2.7/statusPage.py
+++ selinux-gui-2.7/statusPage.py
@@ -16,23 +16,14 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
import os
-import gobject
import sys
-import tempfile
+from gi.repository import Gtk
import selinux
INSTALLPATH = '/usr/share/system-config-selinux'
sys.path.append(INSTALLPATH)
-try:
- from subprocess import getstatusoutput
-except ImportError:
- from commands import getstatusoutput
-
ENFORCING = 1
PERMISSIVE = 0
DISABLED = -1
@@ -71,12 +62,11 @@ class statusPage:
self.type = selinux.selinux_getpolicytype()
# Bring in widgets from glade file.
- self.typeHBox = xml.get_widget("typeHBox")
- self.selinuxTypeOptionMenu = xml.get_widget("selinuxTypeOptionMenu")
- self.typeLabel = xml.get_widget("typeLabel")
- self.enabledOptionMenu = xml.get_widget("enabledOptionMenu")
- self.currentOptionMenu = xml.get_widget("currentOptionMenu")
- self.relabel_checkbutton = xml.get_widget("relabelCheckbutton")
+ self.selinuxTypeOptionMenu = xml.get_object("selinuxTypeOptionMenu")
+ self.typeLabel = xml.get_object("typeLabel")
+ self.enabledOptionMenu = xml.get_object("enabledOptionMenu")
+ self.currentOptionMenu = xml.get_object("currentOptionMenu")
+ self.relabel_checkbutton = xml.get_object("relabelCheckbutton")
self.relabel_checkbutton.set_active(self.is_relabel())
self.relabel_checkbutton.connect("toggled", self.on_relabel_toggle)
if self.get_current_mode() == ENFORCING or self.get_current_mode() == PERMISSIVE:
@@ -90,7 +80,7 @@ class statusPage:
self.currentOptionMenu.set_active(0)
self.currentOptionMenu.set_sensitive(False)
- if self.read_selinux_config() == None:
+ if self.read_selinux_config() is None:
self.selinuxsupport = False
else:
self.enabledOptionMenu.connect("changed", self.enabled_changed)
@@ -131,10 +121,10 @@ class statusPage:
os.unlink(RELABELFILE)
def verify(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_INFO,
- gtk.BUTTONS_YES_NO,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.INFO,
+ Gtk.ButtonsType.YES_NO,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
rc = dlg.run()
dlg.destroy()
@@ -144,7 +134,7 @@ class statusPage:
type = self.get_type()
enabled = self.enabledOptionMenu.get_active()
if self.initialtype != type:
- if self.verify(_("Changing the policy type will cause a relabel of the entire file system on the next boot. Relabeling takes a long time depending on the size of the file system. Do you wish to continue?")) == gtk.RESPONSE_NO:
+ if self.verify(_("Changing the policy type will cause a relabel of the entire file system on the next boot. Relabeling takes a long time depending on the size of the file system. Do you wish to continue?")) == Gtk.ResponseType.NO:
menu.set_active(self.typeHistory)
return None
@@ -158,12 +148,12 @@ class statusPage:
type = self.get_type()
if self.initEnabled != DISABLED and enabled == DISABLED:
- if self.verify(_("Changing to SELinux disabled requires a reboot. It is not recommended. If you later decide to turn SELinux back on, the system will be required to relabel. If you just want to see if SELinux is causing a problem on your system, you can go to permissive mode which will only log errors and not enforce SELinux policy. Permissive mode does not require a reboot Do you wish to continue?")) == gtk.RESPONSE_NO:
+ if self.verify(_("Changing to SELinux disabled requires a reboot. It is not recommended. If you later decide to turn SELinux back on, the system will be required to relabel. If you just want to see if SELinux is causing a problem on your system, you can go to permissive mode which will only log errors and not enforce SELinux policy. Permissive mode does not require a reboot Do you wish to continue?")) == Gtk.ResponseType.NO:
combo.set_active(self.enabled)
return None
if self.initEnabled == DISABLED and enabled < 2:
- if self.verify(_("Changing to SELinux enabled will cause a relabel of the entire file system on the next boot. Relabeling takes a long time depending on the size of the file system. Do you wish to continue?")) == gtk.RESPONSE_NO:
+ if self.verify(_("Changing to SELinux enabled will cause a relabel of the entire file system on the next boot. Relabeling takes a long time depending on the size of the file system. Do you wish to continue?")) == Gtk.ResponseType.NO:
combo.set_active(self.enabled)
return None
self.relabel_checkbutton.set_active(True)
diff --git selinux-gui-2.7/system-config-selinux.py selinux-gui-2.7/system-config-selinux.py
index ed41e98..ce7c74b 100644
--- selinux-gui-2.7/system-config-selinux.py
+++ selinux-gui-2.7/system-config-selinux.py
@@ -20,20 +20,19 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
+import os
import signal
-import string
import sys
+import gi
+gi.require_version('Gtk', '3.0')
try:
- import gtk
+ from gi.repository import Gtk
except RuntimeError as e:
print("system-config-selinux:", e)
print("This is a graphical application and requires DISPLAY to be set.")
sys.exit(1)
-import gtk.glade
-import os
-import gobject
-import gnome
+from gi.repository import GObject
import statusPage
import booleansPage
import loginsPage
@@ -64,8 +63,6 @@ except:
import __builtin__
__builtin__.__dict__['_'] = unicode
-gnome.program_init("SELinux Management Tool", "5")
-
version = "1.0"
sys.path.append('/usr/share/system-config-selinux')
@@ -74,10 +71,12 @@ sys.path.append('/usr/share/system-config-selinux')
##
## Pull in the Glade file
##
-if os.access("system-config-selinux.glade", os.F_OK):
- xml = gtk.glade.XML("system-config-selinux.glade", domain=PROGNAME)
+xml = Gtk.Builder()
+xml.set_translation_domain(PROGNAME)
+if os.access("system-config-selinux.ui", os.F_OK):
+ xml.add_from_file("system-config-selinux.ui")
else:
- xml = gtk.glade.XML("/usr/share/system-config-selinux/system-config-selinux.glade", domain=PROGNAME)
+ xml.add_from_file("/usr/share/system-config-selinux/system-config-selinux.ui")
class childWindow:
@@ -85,11 +84,16 @@ class childWindow:
def __init__(self):
self.tabs = []
self.xml = xml
- xml.signal_connect("on_quit_activate", self.destroy)
- xml.signal_connect("on_delete_clicked", self.delete)
- xml.signal_connect("on_add_clicked", self.add)
- xml.signal_connect("on_properties_clicked", self.properties)
- xml.signal_connect("on_local_clicked", self.on_local_clicked)
+ xml.connect_signals({
+ "on_quit_activate": self.destroy,
+ "on_delete_clicked": self.delete,
+ "on_add_clicked": self.add,
+ "on_properties_clicked": self.properties,
+ "on_local_clicked": self.on_local_clicked,
+ "on_policy_activate": self.policy,
+ "on_logging_activate": self.logging,
+ "on_about_activate": self.on_about_activate,
+ })
self.add_page(statusPage.statusPage(xml))
if selinux.is_selinux_enabled() > 0:
try:
@@ -103,20 +107,15 @@ class childWindow:
except ValueError as e:
self.error(e.message)
- xml.signal_connect("on_quit_activate", self.destroy)
- xml.signal_connect("on_policy_activate", self.policy)
- xml.signal_connect("on_logging_activate", self.logging)
- xml.signal_connect("on_about_activate", self.on_about_activate)
-
- self.add_menu = xml.get_widget("add_menu_item")
- self.properties_menu = xml.get_widget("properties_menu_item")
- self.delete_menu = xml.get_widget("delete_menu_item")
+ self.add_menu = xml.get_object("add_menu_item")
+ self.properties_menu = xml.get_object("properties_menu_item")
+ self.delete_menu = xml.get_object("delete_menu_item")
def error(self, message):
- dlg = gtk.MessageDialog(None, 0, gtk.MESSAGE_ERROR,
- gtk.BUTTONS_CLOSE,
+ dlg = Gtk.MessageDialog(None, 0, Gtk.MessageType.ERROR,
+ Gtk.ButtonsType.CLOSE,
message)
- dlg.set_position(gtk.WIN_POS_MOUSE)
+ dlg.set_position(Gtk.WindowPosition.MOUSE)
dlg.show_all()
dlg.run()
dlg.destroy()
@@ -143,12 +142,12 @@ class childWindow:
self.tabs[self.notebook.get_current_page()].on_local_clicked(button)
def on_about_activate(self, args):
- dlg = xml.get_widget("aboutWindow")
+ dlg = xml.get_object("aboutWindow")
dlg.run()
dlg.hide()
def destroy(self, args):
- gtk.main_quit()
+ Gtk.main_quit()
def use_menus(self, use_menus):
self.add_menu.set_sensitive(use_menus)
@@ -166,13 +165,13 @@ class childWindow:
def setupScreen(self):
# Bring in widgets from glade file.
- self.mainWindow = self.xml.get_widget("mainWindow")
- self.notebook = self.xml.get_widget("notebook")
- self.view = self.xml.get_widget("selectView")
+ self.mainWindow = self.xml.get_object("mainWindow")
+ self.notebook = self.xml.get_object("notebook")
+ self.view = self.xml.get_object("selectView")
self.view.get_selection().connect("changed", self.itemSelected)
- self.store = gtk.ListStore(gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING)
self.view.set_model(self.store)
- col = gtk.TreeViewColumn("", gtk.CellRendererText(), text=0)
+ col = Gtk.TreeViewColumn("", Gtk.CellRendererText(), text=0)
col.set_resizable(True)
self.view.append_column(col)
@@ -189,7 +188,7 @@ class childWindow:
self.mainWindow.connect("destroy", self.destroy)
self.mainWindow.show_all()
- gtk.main()
+ Gtk.main()
if __name__ == "__main__":
signal.signal(signal.SIGINT, signal.SIG_DFL)
diff --git selinux-gui-2.7/system-config-selinux.ui selinux-gui-2.7/system-config-selinux.ui
new file mode 100644
index 0000000..7cc1cc5
--- /dev/null
+++ selinux-gui-2.7/system-config-selinux.ui
@@ -0,0 +1,2024 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.20.0 -->
+<!--*- mode: xml -*-->
+<interface>
+ <requires lib="gtk+" version="3.0"/>
+ <object class="GtkAboutDialog" id="aboutWindow">
+ <property name="name">system-config-selinux</property>
+ <property name="can_focus">False</property>
+ <property name="border_width">5</property>
+ <property name="type_hint">normal</property>
+ <property name="copyright" translatable="yes">Copyright (c)2006 Red Hat, Inc.
+Copyright (c) 2006 Dan Walsh &lt;dwalsh@redhat.com&gt;</property>
+ <property name="authors">Daniel Walsh &lt;dwalsh@redhat.com&gt;
+</property>
+ <property name="translator_credits" translatable="yes" comments="TRANSLATORS: Replace this string with your names, one name per line.">translator-credits</property>
+ <property name="logo">system-config-selinux.png</property>
+ <child internal-child="vbox">
+ <object class="GtkBox">
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox">
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <object class="GtkImage" id="image13">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-add</property>
+ </object>
+ <object class="GtkImage" id="image14">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-properties</property>
+ </object>
+ <object class="GtkImage" id="image15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-delete</property>
+ </object>
+ <object class="GtkDialog" id="loginsDialog">
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">Add SELinux Login Mapping</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="cancelbutton1">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="okbutton1">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkGrid" id="table1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">4</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Login Name</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label16">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">SELinux User</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label17">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">MLS/MCS Range</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="loginsNameEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="loginsSelinuxUserCombo">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="loginsMLSEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">cancelbutton1</action-widget>
+ <action-widget response="-5">okbutton1</action-widget>
+ </action-widgets>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <object class="GtkListStore" id="model1">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0">tcp</col>
+ </row>
+ <row>
+ <col id="0">udp</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkDialog" id="portsDialog">
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">Add SELinux Network Ports</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="vbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="hbuttonbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="button1">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button2">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkGrid" id="table2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">4</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label18">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Port Number</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label19">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Protocol</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label20">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">SELinux Type</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="portsNumberEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="portsProtocolCombo">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="model">model1</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="portsNameEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label21">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">MLS/MCS
+Level</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="portsMLSEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">button1</action-widget>
+ <action-widget response="-5">button2</action-widget>
+ </action-widgets>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <object class="GtkListStore" id="model2">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">all files</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">regular file</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">directory</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">character device</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">block device</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">socket file</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">symbolic link</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">named pipe</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkDialog" id="fcontextDialog">
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">Add SELinux Login Mapping</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="vbox7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="hbuttonbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="button5">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button6">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox8">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkGrid" id="table4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">4</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label25">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">File Specification</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label26">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">File Type</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label27">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">SELinux Type</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="fcontextEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="fcontextFileTypeCombo">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="model">model2</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer2"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="fcontextTypeEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label31">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">MLS</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="fcontextMLSEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">button5</action-widget>
+ <action-widget response="-5">button6</action-widget>
+ </action-widgets>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <object class="GtkListStore" id="model3">
+ <columns>
+ <!-- column-name gchararray -->
+ <column type="gchararray"/>
+ </columns>
+ <data>
+ <row>
+ <col id="0" translatable="yes">Disabled</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Permissive</col>
+ </row>
+ <row>
+ <col id="0" translatable="yes">Enforcing</col>
+ </row>
+ </data>
+ </object>
+ <object class="GtkApplicationWindow" id="mainWindow">
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">SELinux Administration</property>
+ <property name="default_width">800</property>
+ <property name="default_height">500</property>
+ <property name="icon">system-config-selinux.png</property>
+ <child>
+ <object class="GtkBox">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkMenuBar" id="menubar1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkMenuItem" id="file1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">_File</property>
+ <property name="use_underline">True</property>
+ <child type="submenu">
+ <object class="GtkMenu" id="file1_menu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkImageMenuItem" id="add_menu_item">
+ <property name="label" translatable="yes">_Add</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ <property name="image">image13</property>
+ <property name="use_stock">False</property>
+ <signal name="activate" handler="on_add_clicked" swapped="no"/>
+ <accelerator key="a" signal="activate" modifiers="GDK_CONTROL_MASK"/>
+ </object>
+ </child>
+ <child>
+ <object class="GtkImageMenuItem" id="properties_menu_item">
+ <property name="label" translatable="yes">_Properties</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ <property name="image">image14</property>
+ <property name="use_stock">False</property>
+ <signal name="activate" handler="on_properties_clicked" swapped="no"/>
+ <accelerator key="p" signal="activate" modifiers="GDK_CONTROL_MASK"/>
+ </object>
+ </child>
+ <child>
+ <object class="GtkImageMenuItem" id="delete_menu_item">
+ <property name="label" translatable="yes">_Delete</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ <property name="image">image15</property>
+ <property name="use_stock">False</property>
+ <accelerator key="Delete" signal="activate"/>
+ </object>
+ </child>
+ <child>
+ <object class="GtkImageMenuItem" id="quit">
+ <property name="label">gtk-quit</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ <property name="use_stock">True</property>
+ <signal name="activate" handler="on_quit_activate" swapped="no"/>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="GtkMenuItem" id="help1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">_Help</property>
+ <property name="use_underline">True</property>
+ <child type="submenu">
+ <object class="GtkMenu" id="help1_menu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkImageMenuItem" id="about">
+ <property name="label">gtk-about</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ <property name="use_stock">True</property>
+ <signal name="activate" handler="on_about_activate" swapped="no"/>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkPaned" id="hpaned1">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <child>
+ <object class="GtkFrame" id="frame1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="border_width">5</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">none</property>
+ <child>
+ <object class="GtkAlignment" id="alignment1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkTreeView" id="selectView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">Select Management Object</property>
+ <property name="headers_visible">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label45">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">&lt;b&gt;Select:&lt;/b&gt;</property>
+ <property name="use_markup">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="resize">True</property>
+ <property name="shrink">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkNotebook" id="notebook">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="show_tabs">False</property>
+ <child>
+ <object class="GtkBox" id="vbox1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkGrid" id="table6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">5</property>
+ <property name="column_spacing">5</property>
+ <child>
+ <object class="GtkLabel" id="label29">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">System Default Enforcing Mode</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="enabledOptionMenu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="model">model3</property>
+ <child>
+ <object class="GtkCellRendererText" id="renderer3"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label48">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Current Enforcing Mode</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="currentOptionMenu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="typeLabel">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">System Default Policy Type: </property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBoxText" id="selinuxTypeOptionMenu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="relabelCheckbutton">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Select if you wish to relabel then entire file system on next reboot. Relabeling can take a very long time, depending on the size of the system. If you are changing policy types or going from disabled to enforcing, a relabel is required.</property>
+ <property name="hexpand">False</property>
+ <property name="draw_indicator">True</property>
+ <child>
+ <object class="GtkAlignment" id="alignment4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="xscale">0</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkBox" id="hbox6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkImage" id="image2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-refresh</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label49">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Relabel on next reboot.</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox18">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar9">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="booleanRevertButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Revert boolean setting to system default</property>
+ <property name="stock_id">gtk-revert-to-saved</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton34">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Toggle between Customized and All Booleans</property>
+ <property name="label" translatable="yes">Customized</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-find</property>
+ <signal name="clicked" handler="on_local_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label51">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="booleansFilter">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">10</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow18">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="booleansView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">Boolean</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox11">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="toolbutton5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Add File Context</property>
+ <property name="stock_id">gtk-add</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Modify File Context</property>
+ <property name="stock_id">gtk-properties</property>
+ <signal name="clicked" handler="on_properties_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Delete File Context</property>
+ <property name="stock_id">gtk-delete</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="customizedButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Toggle between all and customized file context</property>
+ <property name="label" translatable="yes">Customized</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-find</property>
+ <signal name="clicked" handler="on_local_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox14">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label58">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="fcontextFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow19">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="fcontextView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">File Labeling</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox12">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="toolbutton8">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Add SELinux User Mapping</property>
+ <property name="stock_id">gtk-add</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton29">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Modify SELinux User Mapping</property>
+ <property name="stock_id">gtk-properties</property>
+ <signal name="clicked" handler="on_properties_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton10">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Delete SELinux User Mapping</property>
+ <property name="stock_id">gtk-delete</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox13">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label57">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="loginsFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow16">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="loginsView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">User Mapping</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox14">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="toolbutton14">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Add User</property>
+ <property name="stock_id">gtk-add</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Modify User</property>
+ <property name="stock_id">gtk-properties</property>
+ <signal name="clicked" handler="on_properties_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton16">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Delete User</property>
+ <property name="stock_id">gtk-delete</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox12">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label56">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="usersFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow11">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="usersView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">SELinux User</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="portsAddButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Add Network Port</property>
+ <property name="stock_id">gtk-add</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="portsPropertiesButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Edit Network Port</property>
+ <property name="stock_id">gtk-properties</property>
+ <signal name="clicked" handler="on_properties_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="portsDeleteButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Delete Network Port</property>
+ <property name="stock_id">gtk-delete</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolItem" id="toolitem2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkSeparator" id="vseparator1">
+ <property name="width_request">32</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="listViewButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Toggle between Customized and All Ports</property>
+ <property name="label" translatable="yes">Group View</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-indent</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton35">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Toggle between Customized and All Ports</property>
+ <property name="label" translatable="yes">Customized</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-find</property>
+ <signal name="clicked" handler="on_local_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox9">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label53">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="portsFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow13">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="portsView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">Network Port</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">5</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox17">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar8">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="newModuleButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Generate new policy module</property>
+ <property name="stock_id">gtk-new</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton23">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Load policy module</property>
+ <property name="stock_id">gtk-add</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="toolbutton25">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Remove loadable policy module</property>
+ <property name="stock_id">gtk-remove</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolItem" id="toolitem3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkSeparator" id="vseparator2">
+ <property name="width_request">10</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">False</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="enableAuditButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Enable/Disable additional audit rules, that are normally not reported in the log files.</property>
+ <property name="label" translatable="yes">Enable Audit</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-zoom-in</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox11">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label55">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="modulesFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow15">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="modulesView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">Policy Module</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">6</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox19">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkToolbar" id="toolbar10">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="toolbar_style">both</property>
+ <child>
+ <object class="GtkToolButton" id="permissiveButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Change process mode to permissive.</property>
+ <property name="label" translatable="yes">Permissive</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-dialog-warning</property>
+ <signal name="clicked" handler="on_add_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkToolButton" id="enforcingButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="tooltip_text" translatable="yes">Change process mode to enforcing</property>
+ <property name="label" translatable="yes">Enforcing</property>
+ <property name="use_underline">True</property>
+ <property name="stock_id">gtk-dialog-error</property>
+ <signal name="clicked" handler="on_delete_clicked" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="hbox15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label60">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Filter</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">10</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="domainsFilterEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">•</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow" id="scrolledwindow20">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hscrollbar_policy">always</property>
+ <property name="vscrollbar_policy">always</property>
+ <child>
+ <object class="GtkTreeView" id="domainsView">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">Process Domain</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="position">7</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="resize">True</property>
+ <property name="shrink">True</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <child type="titlebar">
+ <placeholder/>
+ </child>
+ </object>
+ <object class="GtkDialog" id="usersDialog">
+ <property name="can_focus">False</property>
+ <property name="title" translatable="yes">Add SELinux User</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="vbox9">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="hbuttonbox4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="button7">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="button8">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="vbox10">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkGrid" id="table5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="row_spacing">4</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkLabel" id="label32">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">SELinux User</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label34">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">MLS/MCS Range</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="mlsRangeEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label36">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">SELinux Roles</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="selinuxRolesEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="selinuxUserEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">*</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">button7</action-widget>
+ <action-widget response="-5">button8</action-widget>
+ </action-widgets>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+</interface>
diff --git selinux-gui-2.7/usersPage.py selinux-gui-2.7/usersPage.py
index 75b0547..26794ed 100644
--- selinux-gui-2.7/usersPage.py
+++ selinux-gui-2.7/usersPage.py
@@ -16,17 +16,13 @@
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
## Author: Dan Walsh
-import string
-import gtk
-import gtk.glade
-import os
-import gobject
import sys
try:
from subprocess import getstatusoutput
except ImportError:
from commands import getstatusoutput
+from gi.repository import GObject, Gtk
import seobject
from semanagePage import *
@@ -57,27 +53,27 @@ class usersPage(semanagePage):
def __init__(self, xml):
semanagePage.__init__(self, xml, "users", _("SELinux User"))
- self.store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
+ self.store = Gtk.ListStore(GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING, GObject.TYPE_STRING)
self.view.set_model(self.store)
- self.store.set_sort_column_id(0, gtk.SORT_ASCENDING)
+ self.store.set_sort_column_id(0, Gtk.SortType.ASCENDING)
- col = gtk.TreeViewColumn(_("SELinux\nUser"), gtk.CellRendererText(), text=0)
+ col = Gtk.TreeViewColumn(_("SELinux\nUser"), Gtk.CellRendererText(), text=0)
col.set_sort_column_id(0)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("MLS/\nMCS Range"), gtk.CellRendererText(), text=1)
+ col = Gtk.TreeViewColumn(_("MLS/\nMCS Range"), Gtk.CellRendererText(), text=1)
col.set_resizable(True)
self.view.append_column(col)
- col = gtk.TreeViewColumn(_("SELinux Roles"), gtk.CellRendererText(), text=2)
+ col = Gtk.TreeViewColumn(_("SELinux Roles"), Gtk.CellRendererText(), text=2)
col.set_resizable(True)
self.view.append_column(col)
self.load()
- self.selinuxUserEntry = xml.get_widget("selinuxUserEntry")
- self.mlsRangeEntry = xml.get_widget("mlsRangeEntry")
- self.selinuxRolesEntry = xml.get_widget("selinuxRolesEntry")
+ self.selinuxUserEntry = xml.get_object("selinuxUserEntry")
+ self.mlsRangeEntry = xml.get_object("mlsRangeEntry")
+ self.selinuxRolesEntry = xml.get_object("selinuxRolesEntry")
def load(self, filter=""):
self.filter = filter
@@ -95,10 +91,6 @@ class usersPage(semanagePage):
self.store.set_value(iter, 2, dict[k][3])
self.view.get_selection().select_path((0,))
- def delete(self):
- if semanagePage.delete(self) == gtk.RESPONSE_NO:
- return None
-
def dialogInit(self):
store, iter = self.view.get_selection().get_selected()
self.selinuxUserEntry.set_text(store.get_value(iter, 0))