Bug 608483 - SELinux is preventing /usr/libexec/git-core/git-daemon "getattr" access on /var/lib/git.
SELinux is preventing /usr/libexec/git-core/git-daemon "getattr" access ...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
13
x86_64 Linux
low Severity medium
: ---
: ---
Assigned To: Miroslav Grepl
Fedora Extras Quality Assurance
setroubleshoot_trace_hash:4a5426fcb96...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-06-27 14:34 EDT by Giovanni Campagna
Modified: 2010-07-06 13:09 EDT (History)
4 users (show)

See Also:
Fixed In Version: selinux-policy-3.7.19-33.fc13
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-07-06 13:09:37 EDT
Type: ---
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 Giovanni Campagna 2010-06-27 14:34:52 EDT
Sommario:

SELinux is preventing /usr/libexec/git-core/git-daemon "getattr" access on
/var/lib/git.

Descrizione dettagliata:

SELinux denied access requested by git-daemon. It is not expected that this
access is required by git-daemon and this access may signal an intrusion
attempt. It is also possible that the specific version or configuration of the
application is causing it to require additional access.

Abilitazione accesso in corso:

You can generate a local policy module to allow this access - see FAQ
(http://docs.fedoraproject.org/selinux-faq-fc5/#id2961385) Please file a bug
report.

Informazioni aggiuntive:

Contesto della sorgente       system_u:system_r:git_system_t:s0-s0:c0.c1023
Contesto target               system_u:object_r:httpd_git_content_t:s0
Oggetti target                /var/lib/git [ dir ]
Sorgente                      git-daemon
Percorso della sorgente       /usr/libexec/git-core/git-daemon
Porta                         <Sconosciuto>
Host                          (removed)
Sorgente Pacchetti RPM        git-daemon-1.7.0.1-1.fc13
Pacchetti RPM target          git-daemon-1.7.0.1-1.fc13
RPM della policy              selinux-policy-3.7.19-28.fc13
Selinux abilitato             True
Tipo di policy                targeted
Modalità Enforcing           Enforcing
Nome plugin                   catchall
Host Name                     (removed)
Piattaforma                   Linux (removed)
                              2.6.33.5-124.fc13.x86_64 #1 SMP Fri Jun 11
                              09:38:12 UTC 2010 x86_64 x86_64
Conteggio avvisi              1
Primo visto                   dom 27 giu 2010 20:33:29 CEST
Ultimo visto                  dom 27 giu 2010 20:33:29 CEST
ID locale                     232627e9-387b-4173-8428-7f657fc3a641
Numeri di linea               

Messaggi Raw Audit            

node=(removed) type=AVC msg=audit(1277663609.887:50): avc:  denied  { getattr } for  pid=14160 comm="git-daemon" path="/var/lib/git" dev=dm-0 ino=140055 scontext=system_u:system_r:git_system_t:s0-s0:c0.c1023 tcontext=system_u:object_r:httpd_git_content_t:s0 tclass=dir

node=(removed) type=SYSCALL msg=audit(1277663609.887:50): arch=c000003e syscall=4 success=no exit=-13 a0=7fffa079eeaf a1=7fffa079dc80 a2=7fffa079dc80 a3=7fffa079da00 items=0 ppid=13459 pid=14160 auid=4294967295 uid=99 gid=99 euid=99 suid=99 fsuid=99 egid=99 sgid=99 fsgid=99 tty=(none) ses=4294967295 comm="git-daemon" exe="/usr/libexec/git-core/git-daemon" subj=system_u:system_r:git_system_t:s0-s0:c0.c1023 key=(null)



Hash String generated from  catchall,git-daemon,git_system_t,httpd_git_content_t,dir,getattr
audit2allow suggests:

#============= git_system_t ==============
allow git_system_t httpd_git_content_t:dir getattr;
Comment 1 Miroslav Grepl 2010-06-28 08:01:32 EDT
Could you try to execute:

chcon -Rt  git_system_content_t /var/lib/git

It should work.
Comment 2 Dominick Grift 2010-06-30 04:13:38 EDT
$ matchpathcon /var/lib/git
/var/lib/git    system_u:object_r:git_system_content_t:s0

Instead, cgit and gitweb can read git_system_content.
Comment 3 Miroslav Grepl 2010-06-30 04:30:37 EDT
I need to fix the label.
Comment 4 Miroslav Grepl 2010-06-30 07:04:17 EDT
Fixed in selinux-policy-3.7.19-33.fc13
Comment 5 Fedora Update System 2010-06-30 15:55:23 EDT
selinux-policy-3.7.19-33.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/selinux-policy-3.7.19-33.fc13
Comment 6 Fedora Update System 2010-07-01 14:49:21 EDT
selinux-policy-3.7.19-33.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-33.fc13
Comment 7 Fedora Update System 2010-07-06 13:07:40 EDT
selinux-policy-3.7.19-33.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.