You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@shiro.apache.org by armandoxxx <ar...@dropchop.com> on 2012/06/01 15:33:43 UTC

How to implement string token filter ?

Hey 

I have a question regarding writing custom string token access control
filter.

I'm not sure where (in what method) to write the code that evaluates token
request parameter and decides whether to allow access or not.

I was thinking of extending AccessControlFilter and isAccessAllowed method.

Any advice would be greatly appreciated. 

Kind regards

Armando


--
View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-implement-string-token-filter-tp7577456.html
Sent from the Shiro User mailing list archive at Nabble.com.

Re: How to implement string token filter ?

Posted by Les Hazlewood <lh...@apache.org>.
That's a good option.  However, if you want to support redirect to an
unauthorized URL, you can extend AuthorizationFilter instead (and
still override isAccessAllowed).

Cheers,

--
Les Hazlewood
CTO, Stormpath | http://stormpath.com | 888.391.5282
twitter: @lhazlewood | http://twitter.com/lhazlewood
blog: http://leshazlewood.com
stormpath blog: http://www.stormpath.com/blog


On Fri, Jun 1, 2012 at 6:33 AM, armandoxxx <ar...@dropchop.com> wrote:
> Hey
>
> I have a question regarding writing custom string token access control
> filter.
>
> I'm not sure where (in what method) to write the code that evaluates token
> request parameter and decides whether to allow access or not.
>
> I was thinking of extending AccessControlFilter and isAccessAllowed method.
>
> Any advice would be greatly appreciated.
>
> Kind regards
>
> Armando
>
>
> --
> View this message in context: http://shiro-user.582556.n2.nabble.com/How-to-implement-string-token-filter-tp7577456.html
> Sent from the Shiro User mailing list archive at Nabble.com.