【问题标题】:In selinux enforcing mode, startx failed. Xorg.0.log show: xf86EnableIOPorts: failed to set IOPL for I/O (Operation not permitted)在 selinux 强制模式下,startx 失败。 Xorg.0.log show: xf86EnableIOPorts: failed to set IOPL for I/O (Operation not allowed)
【发布时间】:2016-12-23 11:08:06
【问题描述】:

我有一个安装了自定义 Selinux 策略并处于强制模式的 Suse 11 Sp3 系统。

我的内核版本是:

uname -a

Linux WUH1000070872 3.0.76-0.11-default #1 SMP Fri Jun 14 08:21:43 UTC 2013 (ccab990) x86_64 x86_64 x86_64 GNU/Linux

当我运行 startx 时,它失败了,在 Xorg.0.log 中,它报告如下:

xf86EnableIOPorts: 未能为 I/O 设置 IOPL(不允许操作)

在 /var/log/audit/audit.log 中,我得到以下信息:

type=AVC msg=audit(1482486805.380:10): avc: denied { 0x20 } for pid=6670 comm="X" capability=37 scontext=system_u:unconfined_r:unconfined_t:s0: c0 tcontext=system_u:unconfined_r:unconfined_t:s0:c0 tclass=capability2

但实际上有一些规则:

sesearch -s unconfined_t -t unconfined_t -ccapability2 --allow

找到 2 个语义 av 规则:

允许 common_domain unconfined_t :capability2 { mac_override mac_admin syslog wake_alarm block_suspend audit_read };

允许 unconfined_t unconfined_t :capability2 { mac_override mac_admin syslog wake_alarm block_suspend audit_read };

我的政策如下:

类型 unconfined_t、common_domain、file_type;

允许 common_domain unconfined_t:capability2 *;

我已授予所有权限,但仍然拒绝访问。问题是什么?并且错误“ avc: denied { 0x20 }”令人困惑,这里应该是一个权限字符串而不是一个数字。如何解决?

【问题讨论】:

    标签: x11 selinux


    【解决方案1】:

    看来我的内核可能需要一些补丁来解决这个问题。在另一台内核版本为 3.0.101-0.47.86-default 的 linux 机器上,执行相同的策略,XWindow 可以启动。

    【讨论】:

      猜你喜欢
      • 2022-08-03
      • 2015-09-01
      • 1970-01-01
      • 2019-07-24
      • 2018-03-11
      • 2020-08-07
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多