You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by Sushil Vegad <vs...@serebrum.com> on 2008/03/31 23:08:26 UTC

Webdav AccessManager, canAccess(String workspaceName)

Hello,
We want to implement a custom access manager to check user permissions when
a user accesses the repository through Webdav. We wrote a class
MyAccessManager that implements
org.apache.jackrabbit.core.security.AccessManager and declared it in the
repository.xml

What I see is only three callback methods are getting called: init(AMContext
context), isGranted(ItemId id, int permissions) and close(). Also, init is
getting called twice (and sometimes even more) and isGranted is called
multiple times every time init is called.

checkPermission(ItemId id, int permissions) and canAccess(String
workspaceName) are not called at all. We were hoping to use canAccess to
check if the user has permission for the repository?

Am I missing something here? How can I authorize the user?

Thanks a lot,
Sushil

 
-- 
View this message in context: http://www.nabble.com/Webdav-AccessManager%2C-canAccess%28String-workspaceName%29-tp16399087p16399087.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


Re: Webdav AccessManager, canAccess(String workspaceName)

Posted by Tobias Bocanegra <to...@day.com>.
canAccess() should be called during init() when logging into the
repository. At this time a new access manager is created the access
manager checks if access is allowed.

--
Toby

On 3/31/08, Sushil Vegad <vs...@serebrum.com> wrote:
>
>  Hello,
>  We want to implement a custom access manager to check user permissions when
>  a user accesses the repository through Webdav. We wrote a class
>  MyAccessManager that implements
>  org.apache.jackrabbit.core.security.AccessManager and declared it in the
>  repository.xml
>
>  What I see is only three callback methods are getting called: init(AMContext
>  context), isGranted(ItemId id, int permissions) and close(). Also, init is
>  getting called twice (and sometimes even more) and isGranted is called
>  multiple times every time init is called.
>
>  checkPermission(ItemId id, int permissions) and canAccess(String
>  workspaceName) are not called at all. We were hoping to use canAccess to
>  check if the user has permission for the repository?
>
>  Am I missing something here? How can I authorize the user?
>
>  Thanks a lot,
>  Sushil
>
>
>
>  --
>  View this message in context: http://www.nabble.com/Webdav-AccessManager%2C-canAccess%28String-workspaceName%29-tp16399087p16399087.html
>  Sent from the Jackrabbit - Users mailing list archive at Nabble.com.
>
>