Bug 623626 - SELinux verhindert /usr/libexec/gam_server "search" Zugriff on /var/named.
Summary: SELinux verhindert /usr/libexec/gam_server "search" Zugriff on /var/named.
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
(Show other bugs)
Version: 13
Hardware: x86_64 Linux
low
medium
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: setroubleshoot_trace_hash:bfed028cec6...
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-08-12 10:44 UTC by Stefan Jensen
Modified: 2010-08-17 05:39 UTC (History)
2 users (show)

Fixed In Version: selinux-policy-3.7.19-47.fc13
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-08-17 05:39:45 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Stefan Jensen 2010-08-12 10:44:19 UTC
Zusammenfassung:

SELinux verhindert /usr/libexec/gam_server "search" Zugriff on /var/named.

Detaillierte Beschreibung:

SELinux verweigerte den von gam_server angeforderten Zugriff. Da nicht davon
ausgegangen wird, dass dieser Zugriff von gam_server benötigt wird,
signalisiert dies möglicherweise einen Einbruchsversuch. Es ist ausserdem
möglich, dass diese spezielle Version oder Konfiguration der Anwendung den
zusätzlichen Zugriff verursacht.

Zugriff erlauben:

Sie können ein lokales Richtlininenmodul generieren, um diesen Zugriff zu
erlauben siehe FAQ (http://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385)
Bitte reichen Sie einen Fehlerbericht ein.

Zusätzliche Informationen:

Quellkontext                  unconfined_u:system_r:fail2ban_t:s0
Zielkontext                   system_u:object_r:named_zone_t:s0
Zielobjekte                   /var/named [ dir ]
Quelle                        gam_server
Quellpfad                     gam_server
Port                          <Unbekannt>
Host                          (entfernt)
RPM-Pakete der Quelle         gamin-0.1.10-7.fc13
RPM-Pakete des Ziels          bind-9.7.1-2.P2.fc13
Richtlinien-RPM               selinux-policy-3.7.19-44.fc13
SELinux aktiviert             True
Richtlinientyp                targeted
Enforcing-Modus               Enforcing
Plugin-Name                   catchall
Rechnername                   (entfernt)
Plattform                     Linux (entfernt)
                              2.6.33.6-147.2.4.fc13.x86_64 #1 SMP Fri Jul 23
                              17:14:44 UTC 2010 x86_64 x86_64
Anzahl der Alarme             6
Zuerst gesehen                Do 12 Aug 2010 11:36:29 CEST
Zuletzt gesehen               Do 12 Aug 2010 11:36:41 CEST
Lokale ID                     fe868e0a-66d4-48ae-95f7-9d23eb84d8a2
Zeilennummern                 

Raw-Audit-Meldungen           

node=(entfernt) type=AVC msg=audit(1281605801.535:3630): avc:  denied  { search } for  pid=28588 comm="gam_server" name="named" dev=md2 ino=3413501 scontext=unconfined_u:system_r:fail2ban_t:s0 tcontext=system_u:object_r:named_zone_t:s0 tclass=dir

node=(entfernt) type=SYSCALL msg=audit(1281605801.535:3630): arch=c000003e syscall=254 success=no exit=-13 a0=3 a1=68e590 a2=1002fc6 a3=1 items=0 ppid=1 pid=28588 auid=500 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=521 comm="gam_server" exe="/usr/libexec/gam_server" subj=unconfined_u:system_r:fail2ban_t:s0 key=(null)



Hash String generated from  catchall,gam_server,fail2ban_t,named_zone_t,dir,search
audit2allow suggests:

#============= fail2ban_t ==============
allow fail2ban_t named_zone_t:dir search;

Comment 1 Stefan Jensen 2010-08-12 10:49:43 UTC
This happend, when fail2ban is configured to monitor binds logs in a non-chroot environment. I would suggest, that this is allowed by default. I see no problems with this being a default.

best regards

Comment 2 Daniel Walsh 2010-08-12 20:44:34 UTC
Can you turn off the gam_server by changing fail2ban to polling.

Miroslav add

########################################
## <summary>
##	Read BIND log files.
## </summary>
## <param name="domain">
##	<summary>
##	Domain allowed access.
##	</summary>
## </param>
#
interface(`bind_read_log',`
	gen_require(`
		type named_zone_t;
		type named_log_t;
	')

	files_search_var($1)
	allow $1 named_zone_t:dir search_dir_perms;
	read_files_pattern($1, named_log_t, named_log_t)
')

optional_policy(`
	bind_read_log(fail2ban_t)
')

Comment 3 Miroslav Grepl 2010-08-13 06:09:03 UTC
Fixed in selinux-policy-3.7.19-47.fc13.

Comment 4 Fedora Update System 2010-08-13 14:19:15 UTC
selinux-policy-3.7.19-47.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-47.fc13

Comment 5 Fedora Update System 2010-08-13 21:07:41 UTC
selinux-policy-3.7.19-47.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update selinux-policy'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-47.fc13

Comment 6 Fedora Update System 2010-08-17 05:38:29 UTC
selinux-policy-3.7.19-47.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.


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