Bug 1091068

Summary: overprotected api
Product: [Fedora] Fedora Reporter: Matthias Clasen <mclasen>
Component: firewalldAssignee: Thomas Woerner <twoerner>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: bnocera, jpopelka, twoerner
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: firewalld-0.3.10-1.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-19 22:58:45 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
patch none

Description Matthias Clasen 2014-04-24 18:47:47 UTC
It is awkward that even the readonly apis are behind polkit - I should be able to read zone configuration without needing to be root. That also goes for the zone config files - the descriptions in there is not exposed through the api, and the files are only readable as root.

Comment 1 Jiri Popelka 2014-04-25 15:03:47 UTC
Created attachment 889786 [details]
patch

(In reply to Matthias Clasen from comment #0)
> It is awkward that even the readonly apis are behind polkit

I actually already moved the readonly functions under 'always authorized' polkit action (PK_ACTION_INFO). [1]
However Thomas don't want this for 'server' so here (attached patch) I move the functions into separate polkit actions.
The idea is to have separate org.fedoraproject.FirewallD1.policy files for server and for desktop, where on desktop the implicit authorizations for these new actions will be 'yes' instead of 'auth_admin_keep'.

[1] https://git.fedorahosted.org/cgit/firewalld.git/commit/?id=63cf455b305c3208d99524c1c3df193b23c8b8cf
    https://git.fedorahosted.org/cgit/firewalld.git/commit/?id=cdf4e49fa17671c56601197a5f61dd850680b004
    https://git.fedorahosted.org/cgit/firewalld.git/commit/?id=b915a9c9dbbba9bdaecd9d99d779dceb504da8a7

Comment 2 Jiri Popelka 2014-04-29 13:55:05 UTC
There's pk branch with these changes:
https://git.fedorahosted.org/cgit/firewalld.git/log/?h=pk

Comment 3 Jiri Popelka 2014-05-14 15:47:36 UTC
With the following commit one just needs to run 'firewall-offline-cmd --policy-desktop' to change the Polkit actions to 'desktop':
https://git.fedorahosted.org/cgit/firewalld.git/commit/?id=b903cc639c5ff6618b5f023e94ff9f49a08fd7fa

Comment 4 Fedora Update System 2014-05-29 09:08:50 UTC
firewalld-0.3.10-1.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/firewalld-0.3.10-1.fc20

Comment 5 Fedora Update System 2014-05-29 23:23:35 UTC
Package firewalld-0.3.10-1.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing firewalld-0.3.10-1.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-6834/firewalld-0.3.10-1.fc20
then log in and leave karma (feedback).

Comment 6 Fedora Update System 2014-06-19 22:58:45 UTC
firewalld-0.3.10-1.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.