Good day all,
I am working on an application in Grails where I am attempting to use spring security core and ui. Specifically I have used s2ui-override to override user, role, auth and layout.
Generally it seems to be working. I have encountered a very odd problem now though and I can't seem to fix it.
When I click on the login link on my home page, I am sent to the s2ui login page as expected. Once I fill in known credentials and click the login button, I receive a "Sorry you're not authorized to view this page" message; meanwhile the url displayed in the Firefox address panel is
http://localhost:8080/galaxy/plugins/jquery-ui-1.10.3/jquery-ui/themes/ui-lightness/jquery-ui-1.10.3.custom.css
I had this behaviour earlier but (I thought I had) corrected it by adding the following two lines to grails.plugin.springsecurity.controllerAnnotations.staticRules in my Config.groovy
'/login/**': ['permitAll'],
'/logout/**': ['permitAll']
The weird part of this is that if I click back in the browser, I return to the s2ui login panel (fields empty); if I fill them in again (same user) and click the login button, this time I am redirected to my home page as expected.
This behaviour is consistent as far as I can see, that is, it works the second time every time.