Bug 972432 - fetchmail is blocked by selinux
fetchmail is blocked by selinux
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: fetchmail (Show other bugs)
19
Unspecified Linux
unspecified Severity medium
: ---
: ---
Assigned To: Vitezslav Crhonek
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-06-09 07:26 EDT by Dietmar Kling
Modified: 2015-09-15 04:25 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-02-18 08:55:42 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Dietmar Kling 2013-06-09 07:26:30 EDT
Description of problem:
fetchmail is blocked by selinux with 


Version-Release number of selected component (if applicable):



How reproducible:
fetchmail-6.3.24-3.fc19.x86_64


Steps to Reproduce:
1.
Create "fetchmail.service" under /etc/systemd/system/multi-user.target.wants/fetchmail.service and put some account into /etc/fetchmailrc which can be used by fetchmail

--------------------------------------------------------------------
#
# Install
# in directory /lib/systemd/system

[Unit]
Description=fetchmail retrieves and forwards mail
After=local-fs.target network.target

[Service]
Type=simple
User=mail
ExecStart=/usr/bin/fetchmail -N -s --fetchmailrc /etc/fetchmailrc

[Install]
WantedBy=multi-user.target
--------------------------------------------------------------------

2. Start service


Actual results:
  Blocked by selinux
  --> cannot acces /etc/hosts and several other files.


Expected results:
  Run flawlessly

Additional info:

after several tries with selinux the following "mypol.te" made it work:

module mypol 1.0;

require {
        type net_conf_t;
        type fetchmail_t;
        class netlink_route_socket { bind getattr create };
        class file { read getattr open };
}

#============= fetchmail_t ==============
allow fetchmail_t net_conf_t:file getattr;

#!!!! This avc is allowed in the current policy
allow fetchmail_t net_conf_t:file { read open };
allow fetchmail_t self:netlink_route_socket getattr;

#!!!! This avc is allowed in the current policy
allow fetchmail_t self:netlink_route_socket { bind create };
Comment 1 Fedora End Of Life 2015-01-09 17:08:45 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

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 19 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.
Comment 2 Fedora End Of Life 2015-02-18 08:55:42 EST
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 3 Vitezslav Crhonek 2015-09-15 04:25:48 EDT
Just for your information - I added examples of fetchmail.service and very basic fetchmailrc file into the package, starting with fetchmail-6.3.26-7.fc24. I didn't experience any SELinux issues. If you do, please report them against selinux-policy component. Thanks!

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