On 1/18/2010 8:22 PM, Pedro Felix wrote:
Hi,
I'm currently developing a plugin with a component implementing
IPermissionGroupProvider, to provide groups based on OAuth WRAP tokens
received in the request's headers. In this context
1) When is the get_permission_groups method called? In every
request?
No, only once in a while, see
trac.perm.DefaultPermissionPolicy.check_permission.
Also when called explicitly in a few cases (e.g. restrict_owner).
But there are a few problems with IPermissionGroupProvider, see below.
2) How can I access the request info? Is the mod_python Request
object available?
No, on purpose, the idea here is to dissociate the authorization from
the authentication, therefore the permission system only needs to
consider the username.
I've already looked in the Trac developer wiki, however the
information regarding these issues is rather scarce.
See http://trac.edgewall.org/ticket/5648 which summarizes the issues
with groups.
-- Christian
--
You received this message because you are subscribed to the Google Groups "Trac
Development" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/trac-dev?hl=en.