Bug 2355930 - SELinux is preventing (pcscd) from using the 'nnp_transition' accesses on a process.
Summary: SELinux is preventing (pcscd) from using the 'nnp_transition' accesses on a p...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: rawhide
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Zdenek Pytela
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:90dae7b4519e7ca500f82018001...
: 2356058 2357154 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-03-29 12:32 UTC by Zephyr Lykos
Modified: 2025-04-08 19:17 UTC (History)
9 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2025-04-08 19:17:35 UTC
Type: ---
Embargoed:
zpytela: mirror+


Attachments (Terms of Use)
File: description (1.91 KB, text/plain)
2025-03-29 12:32 UTC, Zephyr Lykos
no flags Details
File: os_info (795 bytes, text/plain)
2025-03-29 12:32 UTC, Zephyr Lykos
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github fedora-selinux selinux-policy pull 2609 0 None open Allow init_t nnp domain transition to pcscd_t 2025-03-30 13:10:24 UTC
Red Hat Issue Tracker FC-1549 0 None None None 2025-04-03 10:51:17 UTC

Description Zephyr Lykos 2025-03-29 12:32:33 UTC
Description of problem:
1. systemctl enable pcscd.service --now
2. plug in Yubikey, `gpg --sign` with it
3. see AVC denial
SELinux is preventing (pcscd) from using the 'nnp_transition' accesses on a process.

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

If you believe that (pcscd) should be allowed nnp_transition access on processes labeled pcscd_t by default.
Then you should report this as a bug.
You can generate a local policy module to allow this access.
Do
allow this access for now by executing:
# ausearch -c '(pcscd)' --raw | audit2allow -M my-pcscd
# semodule -X 300 -i my-pcscd.pp

Additional Information:
Source Context                system_u:system_r:init_t:s0
Target Context                system_u:system_r:pcscd_t:s0
Target Objects                Unknown [ process2 ]
Source                        (pcscd)
Source Path                   (pcscd)
Port                          <Unknown>
Host                          (removed)
Source RPM Packages           
Target RPM Packages           
SELinux Policy RPM            selinux-policy-targeted-41.34-1.fc43.noarch
Local Policy RPM              selinux-policy-targeted-41.34-1.fc43.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     (removed)
Platform                      Linux (removed) 6.14.0-
                              0.rc7.20250321gitb3ee1e460951.60.fc43.x86_64 #1
                              SMP PREEMPT_DYNAMIC Fri Mar 21 17:27:07 UTC 2025
                              x86_64
Alert Count                   8
First Seen                    2025-03-28 17:13:01 CST
Last Seen                     2025-03-29 20:19:21 CST
Local ID                      9169605e-1fd4-4c90-951c-3aaf884189dc

Raw Audit Messages
type=AVC msg=audit(1743250761.970:222): avc:  denied  { nnp_transition } for  pid=6605 comm="(pcscd)" scontext=system_u:system_r:init_t:s0 tcontext=system_u:system_r:pcscd_t:s0 tclass=process2 permissive=0


Hash: (pcscd),init_t,pcscd_t,process2,nnp_transition

Version-Release number of selected component:
selinux-policy-targeted-41.34-1.fc43.noarch

Additional info:
reporter:       libreport-2.17.15
reason:         SELinux is preventing (pcscd) from using the 'nnp_transition' accesses on a process.
package:        selinux-policy-targeted-41.34-1.fc43.noarch
component:      selinux-policy
hashmarkername: setroubleshoot
type:           libreport
kernel:         6.14.0-0.rc7.20250321gitb3ee1e460951.60.fc43.x86_64
component:      selinux-policy

Comment 1 Zephyr Lykos 2025-03-29 12:32:36 UTC
Created attachment 2082505 [details]
File: description

Comment 2 Zephyr Lykos 2025-03-29 12:32:38 UTC
Created attachment 2082506 [details]
File: os_info

Comment 3 Milos Malik 2025-04-03 08:38:29 UTC
I believe the problem is caused by the changes in the pcscd.service file:

# rpm -qa pcsc\* seli\* | sort
pcsc-lite-2.3.2-1.fc43.x86_64
pcsc-lite-ccid-1.6.2-1.fc43.x86_64
pcsc-lite-libs-2.3.2-1.fc43.x86_64
selinux-policy-41.35-1.fc43.noarch
selinux-policy-targeted-41.35-1.fc43.noarch
# grep -i nonew /usr/lib/systemd/system/pcscd.service 
NoNewPrivileges=yes
# sesearch -t pcscd_t -p nnp_transition -A
#

Comment 4 Zdenek Pytela 2025-04-03 10:52:39 UTC
*** Bug 2356058 has been marked as a duplicate of this bug. ***

Comment 5 Zdenek Pytela 2025-04-03 10:52:51 UTC
*** Bug 2357154 has been marked as a duplicate of this bug. ***


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