[ 
https://issues.apache.org/jira/browse/SHINDIG-792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12662581#action_12662581
 ] 

Henning Schmiedehausen commented on SHINDIG-792:
------------------------------------------------

I can not readily see what two patches that would be. Actually, I'd like to 
apply the patch as is. :-)

> UrlParameterAuthenticationHandler is not extensible
> ---------------------------------------------------
>
>                 Key: SHINDIG-792
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-792
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>    Affects Versions: 1.0.x-incubating
>            Reporter: Henning Schmiedehausen
>         Attachments: SHINDIG-792.patch
>
>
> The URLParameterAuthenticationHandler is injected at some places inside the 
> Shindig codebase (AuthenticationModule, AuthenticationHandlerProvider) so to 
> override it, one must extend it. However, the class itself is not really 
> extensible. With this patch, it is possible to do e.g. the following thing:
> --- cut ---
> public class MyAuthenticationHandler extends UrlParameterAuthenticationHandler
> {
>     @Inject
>     public NingAuthenticationHandler(SecurityTokenDecoder 
> securityTokenDecoder)
>     {
>         super(securityTokenDecoder);
>     }
>     @Override
>     protected Map<String, String> getMappedParameters(final 
> HttpServletRequest req) {
>         final Map<String, String> params = new HashMap<String, 
> String>(super.getMappedParameters(req));
>         params.put("param1", req.getParameter("param1"));
>         params.put("param2", req.getParameter("param2"));
>         params.put("param3", req.getParameter("param3"));
>         return params;
>     }
> }
> --- cut ---
> Which in concert with the injected SecurityTokenDecoder allows custom 
> decoding. Else, the whole injection of the token decoder is moot because you 
> can't pass additional parameters into it.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to