Bug 1441638

Summary: Regression: AttributeError: module 'seobject' has no attribute 'boolean_desc'
Product: [Fedora] Fedora Reporter: Marius Vollmer <mvollmer>
Component: setroubleshootAssignee: Daniel Walsh <dwalsh>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 26CC: dwalsh, mgrepl, plautrba, pmoore, stefw, vmojzis
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-04-26 07:04:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Marius Vollmer 2017-04-12 11:42:04 UTC
Description of problem:

The setroubleshootd daemon does not emit the "alert" signal when a new alert is detected.  It also crashes in the get_alert method.  In both cases, this error appears:

    AttributeError: module 'seobject' has no attribute 'boolean_desc'

With get_alert, there is a full backtrace:

Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/dbus/service.py", line 707, in _message_cb
    retval = candidate_method(self, *args, **keywords)
  File "/usr/lib/python3.6/site-packages/setroubleshoot/server.py", line 584, in get_alert
    _("If ") + alert.substitute(plugin.get_if_text(avc, args)),
  File "/usr/share/setroubleshoot/plugins/catchall_boolean.py", line 60, in get_if_text
    txt=seobject.boolean_desc(args[0])
AttributeError: module 'seobject' has no attribute 'boolean_desc'

Version-Release number of selected component (if applicable):
setroubleshoot-server-3.3.11-3.fc26.x86_64

How reproducible:
Always

Steps to Reproduce:

# gdbus call -y -d org.fedoraproject.Setroubleshootd -o /org/fedoraproject/Setroubleshootd -m org.fedoraproject.SetroubleshootdIface.get_all_alerts
(@a(ssi) [],)

# gdbus monitor -y -d org.fedoraproject.Setroubleshootd &
[1] 1370
Monitoring signals from all objects owned by org.fedoraproject.Setroubleshootd
The name org.fedoraproject.Setroubleshootd is owned by :1.21

# <cause a alert>

<no "alert" signals are emitted>

# journalctl -t setroubleshoot
-- Logs begin at Wed 2017-04-12 07:25:19 EDT, end at Wed 2017-04-12 07:35:23 EDT. --
Apr 12 07:26:04 localhost.localdomain setroubleshoot[1277]: SELinux is preventing ls from read access on the directory admin. For complete SELinux messages. run sealert -l 8d268d8d-3540-4350-9b
Apr 12 07:26:04 localhost.localdomain setroubleshoot[1277]: Exception during AVC analysis: module 'seobject' has no attribute 'boolean_desc'
Apr 12 07:26:04 localhost.localdomain setroubleshoot[1277]: SELinux is preventing ls from read access on the directory builder. For complete SELinux messages. run sealert -l 8d268d8d-3540-4350-
Apr 12 07:26:04 localhost.localdomain setroubleshoot[1277]: Exception during AVC analysis: module 'seobject' has no attribute 'boolean_desc'

# gdbus call -y -d org.fedoraproject.Setroubleshootd -o /org/fedoraproject/Setroubleshootd -m org.fedoraproject.SetroubleshootdIface.get_all_alerts
([('8d268d8d-3540-4350-9bc3-f749e1917a03', 'SELinux is preventing ls from read access on the directory builder.', 2)],)

# gdbus call -y -d org.fedoraproject.Setroubleshootd -o /org/fedoraproject/Setroubleshootd -m org.fedoraproject.SetroubleshootdIface.get_alert 8d268d8d-3540-4350-9bc3-f749e1917a03
Error: GDBus.Error:org.freedesktop.DBus.Python.AttributeError: Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/dbus/service.py", line 707, in _message_cb
    retval = candidate_method(self, *args, **keywords)
  File "/usr/lib/python3.6/site-packages/setroubleshoot/server.py", line 584, in get_alert
    _("If ") + alert.substitute(plugin.get_if_text(avc, args)),
  File "/usr/share/setroubleshoot/plugins/catchall_boolean.py", line 60, in get_if_text
    txt=seobject.boolean_desc(args[0])
AttributeError: module 'seobject' has no attribute 'boolean_desc'

# sealert -l 8d268d8d-3540-4350-9bc3-f749e1917a03
failed to connect to server: module 'seobject' has no attribute 'boolean_desc'

Comment 1 Stef Walter 2017-04-25 07:10:35 UTC
This breaks Cockpit and was detected by the Cockpit integration tests. We are tracking cases of this failure here:

https://github.com/cockpit-project/cockpit/issues/6332

Comment 2 Vit Mojzis 2017-04-26 07:04:28 UTC

*** This bug has been marked as a duplicate of bug 1444549 ***