silb/dropwizard-shiro

Unauthorized access even after logging in

Closed this issue · 1 comments

I wrote some rest web services in dropwizard. I wanted to secure the resources with shiro. So I used this dropwizard-shiro bundle. I followed all the steps given here and annotated the resources with @RequiresAuthentication and @RequiresRole("***"). The login and logout are also written as services. I have the swagger UI embedded with my services. Everything works fine in the swagger UI. But when i consume the services from another application, the user is getting logged in but the when trying to access the annotated resources, it gives unauthorized access. What mistake did I make? Or am I missing some step?

silb commented

Check if the requests performed by Swagger UI and the other application differ.