Tried this configuration already: basic authentication filter created by your plugin setting useBasicAuth to true. While the api urls work as expected the other urls as well pop up the basic authentication box. May be the filter chain for /** is wrong!?
grails.plugins.springsecurity.useBasicAuth = true
grails.plugins.springsecurity.basic.realmName = "API"
grails.plugins.springsecurity.filterChain.chainMap = [
'/api/**': 'securityContextPersistenceFilter,logoutFilter,basicAuthenticationFilter,securityContextHolderAwareRequestFilter,exceptionTranslationFilter,filterInvocationInterceptor',
'/**':'securityContextPersistenceFilter,logoutFilter,authenticationProcessingFilter,securityContextHolderAwareRequestFilter,rememberMeAuthenticationFilter,anonymousAuthenticationFilter,exceptionTranslationFilter,filterInvocationInterceptor'
]
----- Original Message -----
From: "Burt Beckwith" <***@burtbeckwith.com>
To: ***@grails.codehaus.org
Sent: Friday, July 9, 2010 6:26:26 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [grails-user] Spring Security Core Plugin - Basic auth for rest url
Right - so keep the grails.plugins.springsecurity.filterChain.chainMap in Config.groovy, that's what it's for.
Burt
Post by Ingo BusseBut I do not want the whole application to use Basic Authentication but just the rest api urls, e.g. /<app>/rest/**
while the rest of the application uses form based authentication.
----- Original Message -----
Sent: Friday, July 9, 2010 6:07:55 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: [grails-user] Spring Security Core Plugin - Basic auth for rest url
You shouldn't need to do anything in resources.groovy, just add
grails.plugins.springsecurity.useBasicAuth = true
to Config.groovy as described in section 9.1 of the docs: http://burtbeckwith.github.com/grails-spring-security-core/docs/manual/
Burt
Post by Ingo BusseTried to configure a basic auth filter for a specific url by
- setting grails.plugins.springsecurity.filterChain.chainMap in Config.groovy
- configuring a basicAuthenticationFilter in resources.groovy
This results in a No bean named ... Exception. It seems that it tries to resolve the chain before the beans in resources groovy are constructed.
Any idea how to resolve this?
Thanx,
Ingo
BTW, I do have a working solution for the acegi plugin doing all the work in resource.groovy.
---------------------------------------------------------------------
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email