Views accessible via url even if user doesn't match policy rules

Bug #1741051 reported by David Gutman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
Wishlist
David Gutman

Bug Description

When a user doesn't match the policy rules of a panel then the panel tab is removed from the menu of the left, but panel views are still accessible using directly the url (ex /admin/flavors/).

In most of the case, views won't work correctly because of the lack of right in the backend, but it may cause trouble when you play with policies.

I think it could be more elegant to return directly a "You are not authorized to access this page" from the frontend when user try to access a view of a panel (via url) without matching the policy rules.

Changed in horizon:
assignee: nobody → David Gutman (david.gutman)
Changed in horizon:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (master)

Fix proposed to branch: master
Review: https://review.openstack.org/530928

Changed in horizon:
assignee: David Gutman (david.gutman) → Ivan Kolodyazhny (e0ne)
Changed in horizon:
assignee: Ivan Kolodyazhny (e0ne) → David Gutman (david.gutman)
Changed in horizon:
assignee: David Gutman (david.gutman) → Akihiro Motoki (amotoki)
Akihiro Motoki (amotoki)
Changed in horizon:
assignee: Akihiro Motoki (amotoki) → David Gutman (david.gutman)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (master)

Reviewed: https://review.openstack.org/530928
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=3f585d3b1efca1b2379d6c0a80246fd6e5a87640
Submitter: Zuul
Branch: master

commit 3f585d3b1efca1b2379d6c0a80246fd6e5a87640
Author: David Gutman <email address hidden>
Date: Wed Jan 3 14:25:46 2018 +0100

    Views accessible via url even if user doesn't match policy rules

    When a user doesn't match the policy rules of a panel then the panel tab
    is removed from the menu of the left, but panel views are still
    accessible using directly the url (ex /admin/flavors/).

    In most of the case, views won't work correctly because of the lack of
    right in the backend, but it may cause trouble when you play with
    policies.

    I think it could be more elegant to return directly a "You are not
    authorized to access this page" from the frontend when user try to
    access a view of a panel (via url) without matching the policy rules.

    Change-Id: I7bc93fed29568adfc14d5bcadfc8728d3b5cf633
    Closes-Bug: #1741051

Changed in horizon:
status: In Progress → Fix Released
Akihiro Motoki (amotoki)
Changed in horizon:
importance: Undecided → Wishlist
milestone: none → queens-rc1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/horizon 13.0.0.0rc1

This issue was fixed in the openstack/horizon 13.0.0.0rc1 release candidate.

tags: added: pike-backport-potential
tags: added: ocata-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/542726

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/542746

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/542839

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on horizon (stable/pike)

Change abandoned by David Gutman (<email address hidden>) on branch: stable/pike
Review: https://review.openstack.org/542726
Reason: Replaced by an appropriate cherry pick with the expected tag. See review https://review.openstack.org/#/c/542839/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on horizon (stable/ocata)

Change abandoned by David Gutman (<email address hidden>) on branch: stable/ocata
Review: https://review.openstack.org/542746
Reason: Replaced by an appropriate cherry pick with the expected tag. See review https://review.openstack.org/#/c/542839/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/542845

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (stable/pike)

Reviewed: https://review.openstack.org/542845
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=1870b536e20213b89122c5eded9ce0d40e572cfd
Submitter: Zuul
Branch: stable/pike

commit 1870b536e20213b89122c5eded9ce0d40e572cfd
Author: David Gutman <email address hidden>
Date: Wed Jan 3 14:25:46 2018 +0100

    Views accessible via url even if user doesn't match policy rules

    When a user doesn't match the policy rules of a panel then the panel tab
    is removed from the menu of the left, but panel views are still
    accessible using directly the url (ex /admin/flavors/).

    In most of the case, views won't work correctly because of the lack of
    right in the backend, but it may cause trouble when you play with
    policies.

    I think it could be more elegant to return directly a "You are not
    authorized to access this page" from the frontend when user try to
    access a view of a panel (via url) without matching the policy rules.

    Change-Id: I7bc93fed29568adfc14d5bcadfc8728d3b5cf633
    Closes-Bug: #1741051
    (cherry picked from commit 3f585d3b1efca1b2379d6c0a80246fd6e5a87640)

tags: added: in-stable-pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on horizon (stable/ocata)

Change abandoned by David Gutman (<email address hidden>) on branch: stable/ocata
Review: https://review.openstack.org/542839
Reason: See the comment from Akihiro Motoki

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/horizon 12.0.3

This issue was fixed in the openstack/horizon 12.0.3 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.