Bug 1833795 - SELinux prevents journalctl when run from logwatch to read /run/log/journal
Summary: SELinux prevents journalctl when run from logwatch to read /run/log/journal
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 34
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
Assignee: Zdenek Pytela
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1812955
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-05-10 16:43 UTC by Göran Uddeborg
Modified: 2022-06-08 06:29 UTC (History)
6 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2022-06-08 06:29:16 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Göran Uddeborg 2020-05-10 16:43:51 UTC
Description of problem:
I get these types of errors.  I beleive they started after the most recent upgrade of selinux-policy:

type=AVC msg=audit(1589073362.222:4132): avc:  denied  { read } for  pid=173910
comm="journalctl" name="journal" dev="tmpfs" ino=1511
scontext=system_u:system_r:logwatch_t:s0-s0:c0.c1023
tcontext=system_u:object_r:syslogd_var_run_t:s0 tclass=dir permissive=0


Version-Release number of selected component (if applicable):
selinux-policy-targeted-3.14.5-38.fc32.noarch


How reproducible:
Every night.

Steps to Reproduce:
1. Enable logwatch


Actual results:
The above AVC.


Expected results:
No AVC.


Additional info:
I see in the policy logwatch_t IS allowed to read directories with types having the "logfile" attribute.  It seems /run/log/journal ought to have a type with that attribute, as it is a log directory just as much as /var/log/journal is.  I leave it to those who understand this better to judge if it is the type of the directory that is wrong, or if the type is correct and it should have the attribute.

Comment 1 Fedora Program Management 2021-04-29 17:16:19 UTC
This message is a reminder that Fedora 32 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 32 on 2021-05-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 '32'.

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 32 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 Göran Uddeborg 2021-05-07 19:42:16 UTC
I still see these AVC:s in F34 using selinux-policy-targeted-34.4-1.fc34.noarch.

Comment 3 Ben Cotton 2022-05-12 16:56:17 UTC
This message is a reminder that Fedora Linux 34 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 34 on 2022-06-07.
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
'version' of '34'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 34 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 Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.

Comment 4 Ben Cotton 2022-06-08 06:29:16 UTC
Fedora Linux 34 entered end-of-life (EOL) status on 2022-06-07.

Fedora Linux 34 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.

Thank you for reporting this bug and we are sorry it could not be fixed.


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