Can you provide relevant snippets of your code, please? If you're using
AuthDynamicFeature, then you're presumably still creating an AuthFilter to
pass to its constructor. In which case you still have access to the
`ContainerRequestContext` within `AuthFilter.authenticate`.

If you're relying on an AuthFilterBuilder to create a filter for use with
AuthDynamicFeature, then perhaps you can simply manually create an
AuthFilter subclass in order to regain access to `ContainerRequestContext`s.

On Mon, Jul 11, 2016 at 1:28 PM, Saumitra Bhave <[email protected]>
wrote:

> I just moved from custom AuthFilter to dropwizard's authentication
> Feature, One problem I am facing is that I can not access "PathParams" in
> the authorize method.
>
> Basically, my requirement is simple, in that, For Eg. User A has signed in
> and he has access to modify user B, I have this information stored in the
> UserPrincipal at the time of authenticate call. Now, I want A to be able to
> access PUT /users/A and PUT /users/B but not anything else.
>
> In the custom implementation, I used to store UriInfo.getPathParameters()
> into the security context, and I could use user principal and the Path
> together to resolve complex Authorization queries.
>
> Is there anyway I can achieve the same using DropWizard's
> AuthDynamicFeature?
>
> Regards,
> Saumitra
>
> --
> You received this message because you are subscribed to the Google Groups
> "dropwizard-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Evan Meagher

-- 
You received this message because you are subscribed to the Google Groups 
"dropwizard-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to