Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
I created a local shared sub-network to allow secondary computer to share connections of the main computer. Connection seemed to work, but I was only able to ping the main computer from the secondary one. Pings to other system (neither local nor internet ones) did not work.
Connections from the main computer to local network and internet were functional (from the main computer). SELinux was set to enforcing mode.
Version-Release number of selected component (if applicable):
selinux-policy-34.1.18-1.el9.noarch
NetworkManager-1.34.0-0.1.el9.x86_64
nftables-0.9.8-9.el9.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Have a computer (nb1) with 2 network ports (I use built-in ethernet + USB-to-ethernet adapter) and RHEL 9 installed.
2. Have nb1 connected to local network (and internet) via one of the ports. (Try "ping www.redhat.com")
3. Create a shared sub-net connection (on nb1):
nmcli connection add type ethernet con-name USB-eth-shared ipv4.method shared ipv4.addresses 192.168.81.1/24
4. Activate the shared sub-net connection on the other network port (list available ports with "ip a"):
nmcli connection up USB-eth-shared ifname <your_if_name>
5. Connect the second computer (nb2) to the second network port on nb1.
6. nb2 should get network auto-configured (DHCP) having nb1 as default gateway and you should be able to ping nb1.
7. Try "ping www.redhat.com" on nb2.
Actual results:
- New SELinux security alert appears (step 4).
- ping from nb2 to internet does not work (100 % packet loss).
Expected results:
- No SELinux alert should appear.
- ping from nb2 to internet should work.
Additional info:
Works with SELinux in permisive mode - workaround (on nb1):
1. nmcli connection down USB-eth-shared
2. sudo setenforce 0
3. nmcli connection up USB-eth-shared ifname <your_if_name>
SELinux is preventing /usr/sbin/nft from open access on the fifo_file fifo_file.
***** Plugin catchall (100. confidence) suggests **************************
If you believe that nft should be allowed open access on the fifo_file fifo_file 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 'nft' --raw | audit2allow -M my-nft
# semodule -X 300 -i my-nft.pp
Additional Information:
Source Context system_u:system_r:iptables_t:s0
Target Context system_u:system_r:NetworkManager_t:s0
Target Objects fifo_file [ fifo_file ]
Source nft
Source Path /usr/sbin/nft
Port <Unknown>
Host p3551
Source RPM Packages nftables-0.9.8-9.el9.x86_64
Target RPM Packages
SELinux Policy RPM selinux-policy-targeted-34.1.18-1.el9.noarch
Local Policy RPM selinux-policy-targeted-34.1.18-1.el9.noarch
Selinux Enabled True
Policy Type targeted
Enforcing Mode Enforcing
Host Name p3551
Platform Linux p3551 5.14.0-8.el9.x86_64 #1 SMP Tue Oct 19
03:58:57 EDT 2021 x86_64 x86_64
Alert Count 5
First Seen 2021-11-12 17:26:08 CET
Last Seen 2021-11-15 11:51:19 CET
Local ID 39dfc045-862c-45e6-a90c-166958fa29b3
Raw Audit Messages
type=AVC msg=audit(1636973479.219:4177): avc: denied { open } for pid=174956 comm="nft" path="pipe:[2186495]" dev="pipefs" ino=2186495 scontext=system_u:system_r:iptables_t:s0 tcontext=system_u:system_r:NetworkManager_t:s0 tclass=fifo_file permissive=0
type=SYSCALL msg=audit(1636973479.219:4177): arch=x86_64 syscall=openat success=no exit=EACCES a0=ffffff9c a1=7f42c61643a1 a2=0 a3=0 items=0 ppid=1750 pid=174956 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=nft exe=/usr/sbin/nft subj=system_u:system_r:iptables_t:s0 key=(null)
Hash: nft,iptables_t,NetworkManager_t,fifo_file,open
I can confirm.
selinux-policy-34.1.20-1.el9 works fine for me.
Even with enforcing SELinux, the connection is established and nb2 (connected to the created subnet) has access to internet.
Than you for the fix.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (new packages: selinux-policy), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHBA-2022:3918
Description of problem: I created a local shared sub-network to allow secondary computer to share connections of the main computer. Connection seemed to work, but I was only able to ping the main computer from the secondary one. Pings to other system (neither local nor internet ones) did not work. Connections from the main computer to local network and internet were functional (from the main computer). SELinux was set to enforcing mode. Version-Release number of selected component (if applicable): selinux-policy-34.1.18-1.el9.noarch NetworkManager-1.34.0-0.1.el9.x86_64 nftables-0.9.8-9.el9.x86_64 How reproducible: Always Steps to Reproduce: 1. Have a computer (nb1) with 2 network ports (I use built-in ethernet + USB-to-ethernet adapter) and RHEL 9 installed. 2. Have nb1 connected to local network (and internet) via one of the ports. (Try "ping www.redhat.com") 3. Create a shared sub-net connection (on nb1): nmcli connection add type ethernet con-name USB-eth-shared ipv4.method shared ipv4.addresses 192.168.81.1/24 4. Activate the shared sub-net connection on the other network port (list available ports with "ip a"): nmcli connection up USB-eth-shared ifname <your_if_name> 5. Connect the second computer (nb2) to the second network port on nb1. 6. nb2 should get network auto-configured (DHCP) having nb1 as default gateway and you should be able to ping nb1. 7. Try "ping www.redhat.com" on nb2. Actual results: - New SELinux security alert appears (step 4). - ping from nb2 to internet does not work (100 % packet loss). Expected results: - No SELinux alert should appear. - ping from nb2 to internet should work. Additional info: Works with SELinux in permisive mode - workaround (on nb1): 1. nmcli connection down USB-eth-shared 2. sudo setenforce 0 3. nmcli connection up USB-eth-shared ifname <your_if_name> SELinux is preventing /usr/sbin/nft from open access on the fifo_file fifo_file. ***** Plugin catchall (100. confidence) suggests ************************** If you believe that nft should be allowed open access on the fifo_file fifo_file 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 'nft' --raw | audit2allow -M my-nft # semodule -X 300 -i my-nft.pp Additional Information: Source Context system_u:system_r:iptables_t:s0 Target Context system_u:system_r:NetworkManager_t:s0 Target Objects fifo_file [ fifo_file ] Source nft Source Path /usr/sbin/nft Port <Unknown> Host p3551 Source RPM Packages nftables-0.9.8-9.el9.x86_64 Target RPM Packages SELinux Policy RPM selinux-policy-targeted-34.1.18-1.el9.noarch Local Policy RPM selinux-policy-targeted-34.1.18-1.el9.noarch Selinux Enabled True Policy Type targeted Enforcing Mode Enforcing Host Name p3551 Platform Linux p3551 5.14.0-8.el9.x86_64 #1 SMP Tue Oct 19 03:58:57 EDT 2021 x86_64 x86_64 Alert Count 5 First Seen 2021-11-12 17:26:08 CET Last Seen 2021-11-15 11:51:19 CET Local ID 39dfc045-862c-45e6-a90c-166958fa29b3 Raw Audit Messages type=AVC msg=audit(1636973479.219:4177): avc: denied { open } for pid=174956 comm="nft" path="pipe:[2186495]" dev="pipefs" ino=2186495 scontext=system_u:system_r:iptables_t:s0 tcontext=system_u:system_r:NetworkManager_t:s0 tclass=fifo_file permissive=0 type=SYSCALL msg=audit(1636973479.219:4177): arch=x86_64 syscall=openat success=no exit=EACCES a0=ffffff9c a1=7f42c61643a1 a2=0 a3=0 items=0 ppid=1750 pid=174956 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm=nft exe=/usr/sbin/nft subj=system_u:system_r:iptables_t:s0 key=(null) Hash: nft,iptables_t,NetworkManager_t,fifo_file,open