Bug 1912385 - SELinux is preventing systemd-sleep from 'getattr' accesses on the blk_file /dev/dm-1.
Summary: SELinux is preventing systemd-sleep from 'getattr' accesses on the blk_file /...
Keywords:
Status: CLOSED DUPLICATE of bug 1928539
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 34
Hardware: x86_64
OS: Unspecified
medium
medium
Target Milestone: ---
Assignee: Zdenek Pytela
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:e0e483b8ba7f4af03a44506f187...
Depends On: 1812955
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-01-04 10:38 UTC by Francisco Magalhães Filho
Modified: 2023-09-15 00:56 UTC (History)
8 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2021-02-22 13:21:19 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Francisco Magalhães Filho 2021-01-04 10:38:32 UTC
Description of problem:
ao iniciar o computador depois da atualização aparece o erro reportado
SELinux is preventing systemd-sleep from 'getattr' accesses on the blk_file /dev/dm-1.

*****  Plugin catchall (100. confidence) suggests   **************************

Se você acredita nisso systemd-sleep deve ser permitido getattr acesso no dm-1 blk_file por padrão.
Then você deve informar que este é um erro.
Você pode gerar um módulo de política local para permitir este acesso.
Do
permitir este acesso por agora executando: # ausearch -c 'systemd-sleep'--raw | audit2allow -M my-systemdsleep # semodule -X 300 -i my-systemdsleep.pp

Additional Information:
Source Context                system_u:system_r:systemd_sleep_t:s0
Target Context                system_u:object_r:fixed_disk_device_t:s0
Target Objects                /dev/dm-1 [ blk_file ]
Source                        systemd-sleep
Source Path                   systemd-sleep
Port                          <Desconhecido>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
SELinux Policy RPM            selinux-policy-targeted-3.14.7-13.fc34.noarch
Local Policy RPM              selinux-policy-targeted-3.14.7-13.fc34.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 5.10.0-0.rc6.20201204git34816d20f1
                              73.92.fc34.x86_64 #1 SMP Fri Dec 4 13:56:15 UTC
                              2020 x86_64 x86_64
Alert Count                   1
First Seen                    2021-01-03 12:54:32 -03
Last Seen                     2021-01-03 12:54:32 -03
Local ID                      b17048fe-1428-48e8-8e89-f5ed59f286e3

Raw Audit Messages
type=AVC msg=audit(1609689272.753:615): avc:  denied  { getattr } for  pid=2528 comm="systemd-sleep" path="/dev/dm-1" dev="devtmpfs" ino=399 scontext=system_u:system_r:systemd_sleep_t:s0 tcontext=system_u:object_r:fixed_disk_device_t:s0 tclass=blk_file permissive=0


Hash: systemd-sleep,systemd_sleep_t,fixed_disk_device_t,blk_file,getattr

Version-Release number of selected component:
selinux-policy-targeted-3.14.7-13.fc34.noarch

Additional info:
component:      selinux-policy
reporter:       libreport-2.14.0
hashmarkername: setroubleshoot
kernel:         5.10.0-0.rc6.20201204git34816d20f173.92.fc34.x86_64
type:           libreport

Comment 1 Zdenek Pytela 2021-01-05 10:45:34 UTC
Hi,

Can you specify at which moment this denial appears? Is it e. g. at the service start, sleep, resume? Do you use swap partition or a swapfile?

Comment 2 Ben Cotton 2021-02-09 16:24:34 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 34 development cycle.
Changing version to 34.

Comment 3 Zdenek Pytela 2021-02-22 13:21:19 UTC

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

Comment 4 Red Hat Bugzilla 2023-09-15 00:56:58 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 500 days


Note You need to log in before you can comment on or make changes to this bug.