Description of problem: SELinux is preventing systemd from 'create' accesses on the tcp_socket port None. This is trying to start leafnode.socket systemd service on Fedora 25. ***** Plugin catchall (100. confidence) suggests ************************** If you believe that systemd should be allowed create access on the port None tcp_socket 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 'systemd' --raw | audit2allow -M my-systemd # semodule -X 300 -i my-systemd.pp Additional Information: Source Context system_u:system_r:init_t:s0 Target Context system_u:system_r:unconfined_service_t:s0 Target Objects port None [ tcp_socket ] Source systemd Source Path systemd Port <Unknown> Host (removed) Source RPM Packages Target RPM Packages Policy RPM selinux-policy-3.13.1-224.fc25.noarch Selinux Enabled True Policy Type targeted Enforcing Mode Enforcing Host Name (removed) Platform Linux (removed) 4.8.10-300.fc25.x86_64 #1 SMP Mon Nov 21 18:59:16 UTC 2016 x86_64 x86_64 Alert Count 12 First Seen 2016-11-27 00:20:28 CET Last Seen 2016-11-29 17:37:03 CET Local ID 8b394ab9-3a43-42d4-92ef-b91a6c94995b Raw Audit Messages type=AVC msg=audit(1480437423.975:644): avc: denied { create } for pid=1 comm="systemd" scontext=system_u:system_r:init_t:s0 tcontext=system_u:system_r:unconfined_service_t:s0 tclass=tcp_socket permissive=0 Hash: systemd,init_t,unconfined_service_t,tcp_socket,create Version-Release number of selected component: selinux-policy-3.13.1-224.fc25.noarch Additional info: reporter: libreport-2.8.0 hashmarkername: setroubleshoot kernel: 4.8.10-300.fc25.x86_64 type: libreport Potential duplicate: bug 1372754
In the end I had to create this policy module: mitmanek:~# cat leafnode.te module leafnode 1.2; require { type init_t; type unconfined_service_t; class tcp_socket { accept bind create getattr listen setopt }; } #============= init_t ============== allow init_t unconfined_service_t:tcp_socket { accept getattr }; allow init_t unconfined_service_t:tcp_socket { bind create listen setopt }; mitmanek:~#
Description of problem: Happened during upgrade to F25 Version-Release number of selected component: selinux-policy-3.13.1-191.14.fc24.noarch Additional info: reporter: libreport-2.8.0 hashmarkername: setroubleshoot kernel: 4.8.8-300.fc25.x86_64 type: libreport
Description of problem: I was trying to start tangd.socket reproducer: 1. dnf install tang 2. make keys # sudo jose gen -t '{"alg":"ES256"}' -o /var/db/tang/sig.jwk # sudo jose gen -t '{"kty":"EC","crv":"P-256","key_ops":["deriveKey"]}' \ -o /var/db/tang/exc.jwk 3. start services # sudo systemctl enable tangd-update.path # sudo systemctl start tangd-update.path # sudo systemctl enable tangd.socket # sudo systemctl start tangd.socket it causes fail of starting socket and selinux alert. Version-Release number of selected component: selinux-policy-3.13.1-225.6.fc25.noarch Additional info: reporter: libreport-2.8.0 hashmarkername: setroubleshoot kernel: 4.9.3-200.fc25.x86_64 type: libreport
(In reply to Kazuo Moriwaka from comment #3) > Description of problem: > I was trying to start tangd.socket > > reproducer: > 1. dnf install tang > 2. make keys > # sudo jose gen -t '{"alg":"ES256"}' -o /var/db/tang/sig.jwk > > # sudo jose gen -t '{"kty":"EC","crv":"P-256","key_ops":["deriveKey"]}' \ > -o /var/db/tang/exc.jwk > 3. start services > # sudo systemctl enable tangd-update.path > # sudo systemctl start tangd-update.path > # sudo systemctl enable tangd.socket > # sudo systemctl start tangd.socket > > it causes fail of starting socket and selinux alert. > > Version-Release number of selected component: > selinux-policy-3.13.1-225.6.fc25.noarch > > Additional info: > reporter: libreport-2.8.0 > hashmarkername: setroubleshoot > kernel: 4.9.3-200.fc25.x86_64 > type: libreport Just FYI, enabling tang requires just: 1. dnf install tang 2. systemctl enable --now tangd.socket Don't bother with all those extra commands.
This message is a reminder that Fedora 25 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 25. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '25'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 25 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
For the record, I just hit something very similar (same?) on Fedora 27 when attempting the two-step process from comment 4: bug 1529068.
*** This bug has been marked as a duplicate of bug 1366968 ***