Skip to content

Rotate hook does not work on Fedora (SELinux?!) #116

@martin-ueding

Description

@martin-ueding

Ever since I switched to Fedora, the rotate hook does not work any more. Now I finally have the time to fix this.

The event is the following, the first one is close, the second one to open:

# acpi_listen
video/tabletmode TBLT 0000008A 00000001
video/tabletmode TBLT 0000008A 00000000

The event does match:

event=video/tabletmode TBLT 0000008A 0000000[01].*

Then I ran journalctl -f and this is what I got:

Mär 27 17:39:50 martin-friese.fritz.box thinkpad-rotate-hook[28661]: video/tabletmode TBLT 0000008A 00000001
Mär 27 17:39:50 martin-friese.fritz.box audit[28666]: AVC avc:  denied  { setgid } for  pid=28666 comm="sudo" capability=6  scontext=system_u:system_r:apmd_t:s0 tcontext=system_u:system_r:apmd_t:s0 tclass=capability permissive=0
Mär 27 17:39:50 martin-friese.fritz.box python3[28663]: detected unhandled Python exception in '/usr/bin/thinkpad-rotate-hook'
Mär 27 17:39:51 martin-friese.fritz.box abrt-server[28668]: Package 'thinkpad-scripts' isn't signed with proper key
Mär 27 17:39:51 martin-friese.fritz.box abrt-server[28668]: 'post-create' on '/var/spool/abrt/Python3-2016-03-27-17:39:50-28663' exited with 1
Mär 27 17:39:51 martin-friese.fritz.box abrt-server[28668]: Deleting problem directory '/var/spool/abrt/Python3-2016-03-27-17:39:50-28663'
Mär 27 17:39:52 martin-friese.fritz.box thinkpad-rotate-hook[28671]: video/tabletmode TBLT 0000008A 00000000
Mär 27 17:39:52 martin-friese.fritz.box audit[28676]: AVC avc:  denied  { setgid } for  pid=28676 comm="sudo" capability=6  scontext=system_u:system_r:apmd_t:s0 tcontext=system_u:system_r:apmd_t:s0 tclass=capability permissive=0
Mär 27 17:39:52 martin-friese.fritz.box python3[28673]: detected unhandled Python exception in '/usr/bin/thinkpad-rotate-hook'
Mär 27 17:39:52 martin-friese.fritz.box abrt-server[28678]: Not saving repeating crash in '/usr/bin/thinkpad-rotate-hook'

From my limited knowledge of SELinux, the _r and _t sound very much like that. Now I have to read up on SELinux in order to find out to enable an exception for this.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions