Bug 2051594

Summary: SELinux is preventing snap-confine from 'getattr' accesses on the chr_file /dev/snd/hwC0D0.
Product: [Fedora] Fedora Reporter: and <dibicono>
Component: snapdAssignee: Zygmunt Krynicki <me>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 35CC: go-sig, maciek.borzecki, me, ngompa13
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:b0ea04de1a309194f0b3c13682a5ad1cb619cabdd30a728c0ef1bae4ed223fa4;VARIANT_ID=xfce;
Fixed In Version: snapd-2.54.3-1.fc37 snapd-2.54.3-1.fc36 snapd-2.54.3-1.fc34 snapd-2.54.3-1.fc35 Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-02-17 18:27:54 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description and 2022-02-07 15:14:53 UTC
Description of problem:
SELinux is preventing snap-confine from 'getattr' accesses on the chr_file /dev/snd/hwC0D0.

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

Si cree que de manera predeterminada se debería permitir a snap-confine el acceso getattr sobre  hwC0D0 chr_file.     
Then debería reportar esto como un error.
Puede generar un módulo de política local para permitir este acceso.
Do
permita el acceso temporalmente ejecutando:
# ausearch -c 'snap-confine' --raw | audit2allow -M mi-snapconfine
# semodule -X 300 -i mi-snapconfine.pp

Additional Information:
Source Context                system_u:system_r:snappy_confine_t:s0
Target Context                system_u:object_r:sound_device_t:s0
Target Objects                /dev/snd/hwC0D0 [ chr_file ]
Source                        snap-confine
Source Path                   snap-confine
Port                          <Desconocido>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
SELinux Policy RPM            selinux-policy-targeted-35.11-1.fc35.noarch
Local Policy RPM              snapd-selinux-2.54.2-1.fc35.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 5.15.16-200.fc35.x86_64 #1 SMP Thu
                              Jan 20 15:38:18 UTC 2022 x86_64 x86_64
Alert Count                   1
First Seen                    2022-02-07 09:04:57 -05
Last Seen                     2022-02-07 09:04:57 -05
Local ID                      7bec3fb6-5388-416a-a4ff-b995436e6309

Raw Audit Messages
type=AVC msg=audit(1644242697.911:216): avc:  denied  { getattr } for  pid=1063 comm="snap-confine" path="/dev/snd/hwC0D0" dev="devtmpfs" ino=481 scontext=system_u:system_r:snappy_confine_t:s0 tcontext=system_u:object_r:sound_device_t:s0 tclass=chr_file permissive=1


Hash: snap-confine,snappy_confine_t,sound_device_t,chr_file,getattr

Version-Release number of selected component:
selinux-policy-targeted-35.11-1.fc35.noarch

Additional info:
component:      snapd
reporter:       libreport-2.15.2
hashmarkername: setroubleshoot
kernel:         5.15.16-200.fc35.x86_64
type:           libreport

Comment 1 Fedora Update System 2022-02-17 18:24:06 UTC
FEDORA-2022-9d711dbc98 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-9d711dbc98

Comment 2 Fedora Update System 2022-02-17 18:25:19 UTC
FEDORA-2022-59c701f3ef has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2022-59c701f3ef

Comment 3 Fedora Update System 2022-02-17 18:27:54 UTC
FEDORA-2022-9d711dbc98 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 4 Fedora Update System 2022-02-17 18:28:24 UTC
FEDORA-2022-59c701f3ef has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 5 Fedora Update System 2022-02-17 18:36:52 UTC
FEDORA-2022-82bea71e5a has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2022-82bea71e5a

Comment 6 Fedora Update System 2022-02-17 18:37:23 UTC
FEDORA-2022-5df8b52ba4 has been submitted as an update to Fedora 35. https://bodhi.fedoraproject.org/updates/FEDORA-2022-5df8b52ba4

Comment 7 Fedora Update System 2022-02-18 01:17:42 UTC
FEDORA-2022-82bea71e5a has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2022-82bea71e5a`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-82bea71e5a

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 Fedora Update System 2022-02-18 02:11:47 UTC
FEDORA-2022-5df8b52ba4 has been pushed to the Fedora 35 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2022-5df8b52ba4`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-5df8b52ba4

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 9 Fedora Update System 2022-02-20 00:41:50 UTC
FEDORA-2022-82bea71e5a has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2022-02-20 01:09:30 UTC
FEDORA-2022-5df8b52ba4 has been pushed to the Fedora 35 stable repository.
If problem still persists, please make note of it in this bug report.