Bug 1062386 - qemu-guest-agent lacks permission to execute settimeofday
Summary: qemu-guest-agent lacks permission to execute settimeofday
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: selinux-policy
Version: 20
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Grepl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1061936
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-02-06 19:00 UTC by Marcelo Tosatti
Modified: 2014-04-03 12:46 UTC (History)
18 users (show)

Fixed In Version:
Clone Of: 1061936
Environment:
Last Closed: 2014-03-03 10:09:09 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
patch to add necessary permissions to qemu-guest-agent (1.36 KB, patch)
2014-02-06 19:13 UTC, Marcelo Tosatti
no flags Details | Diff

Comment 1 Marcelo Tosatti 2014-02-06 19:13:23 UTC
Created attachment 860298 [details]
patch to add necessary permissions to qemu-guest-agent

Comment 3 Cole Robinson 2014-02-07 14:05:20 UTC
From the private comment:

Steps to Reproduce:
1. virsh qemu-agent-command DOMAIN '{ "execute": "guest-set-time", "arguments":{"time":1}} 

Actual results:

SELinux is preventing /usr/bin/qemu-ga from using the sys_time capability.

*****  Plugin catchall (100. confidence) suggests   **************************

If you believe that qemu-ga should have the sys_time capability 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:
# grep qemu-ga /var/log/audit/audit.log | audit2allow -M mypol
# semodule -i mypol.pp

Additional Information:
Source Context                system_u:system_r:virt_qemu_ga_t:s0
Target Context                system_u:system_r:virt_qemu_ga_t:s0
Target Objects                 [ capability ]
Source                        qemu-ga
Source Path                   /usr/bin/qemu-ga
Port                          <Unknown>
Host                          localhost.localdomain
Source RPM Packages           qemu-guest-agent-1.6.1-3.fc20.x86_64
Target RPM Packages           
Policy RPM                    selinux-policy-3.12.1-106.fc20.noarch
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Host Name                     localhost.localdomain
Platform                      Linux localhost.localdomain

Comment 4 Miroslav Grepl 2014-02-10 08:18:08 UTC
Cole,
could you attach raw AVC msgs which are needed for this policy.

Comment 5 Cole Robinson 2014-02-10 15:26:57 UTC
There's a RHEL bug with the info over here, but looks like you commented there already:

https://bugzilla.redhat.com/show_bug.cgi?id=1061936


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