Created
January 26, 2011 18:12
-
-
Save wwitzel3/797139 to your computer and use it in GitHub Desktop.
Why forbidden? ..
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class UserContainer(ModelContainer): | |
__acl__ = [ | |
(Allow, 'admin', ('add', 'edit', 'delete')), | |
(Deny, Everyone, ALL_PERMISSIONS) | |
] | |
@view_config(renderer='users_browse.mako', context=UserContainer, permission='view') | |
def browse(request): | |
return dict() | |
=== DEBUG OUTPUT === | |
2011-01-26 13:04:25,785 debug_authorization of url http://127.0.0.1:6543/users | |
(view name u'' against context Forbidden("debug_authorization of url http://127.0.0.1:6543/users | |
(view name u'' against context <riotoustools.models.root.UserContainer object at 0x104588350>): | |
ACLDenied permission 'view' via ACE ('Deny', 'system.Everyone', <pyramid.security.AllPermissionsList object at 0x10226dd90>) in ACL [ | |
('Allow', 'admin', ('add', 'edit', 'delete')), | |
('Deny', 'system.Everyone', <pyramid.security.AllPermissionsList object at 0x10226dd90>) | |
] on context <riotoustools.models.root.UserContainer object at 0x104588350> for principals [ | |
'system.Everyone', 'system.Authenticated', 1, Group(id=1, name=admin) | |
]",)): Allowed (no permission registered) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment