SEC-1201: PropertyPlaceholderConfigurer does not work for intercept-url attributes #1447

Closed
spring-issuemaster opened this Issue Jul 17, 2009 · 3 comments

1 participant

@spring-issuemaster

Marc Rohlfs (Migrated from SEC-1201) said:

Hello,

I need to define a property placeholder to configure the access for an intercept URL pattern:
security:http

/security:http

As the HttpSecurityBeanDefinitionParser doesn't create BeanDefinitions for any the properties (and sub-properties) that are passed to the FilterSecurityInterceptor, the PropertyPlaceholderConfigurer can't substitute them. This issue looks very equal to SEC-975, but I guess it's a little harder to solve as the pattern-access map resides deeper in the object hierarchy.

Kind regards

Marc

@spring-issuemaster

Marc Rohlfs said:

BTW: Adding the following bean definitions to the Spring context serves as a workaround for the problem - but it looks a little wired, doesn't it?































@spring-issuemaster

David Findlay said:

It doesn't expand parameters in the requires-channel attributed of intercept-url or in form-login either.

        <security:intercept-url pattern="/${web.auth.login_url}" access="ROLE_ANONYMOUS"/>
        <security:intercept-url pattern="/${web.auth.failure_url}" access="ROLE_ANONYMOUS"/>
        <security:intercept-url pattern="/**" access="ROLE_USER" requires-channel='${web.auth.requires.channel}'/>
        <security:form-login login-page='${web.auth.login_url}'
                    authentication-failure-url='${web.auth.failure_url}'
                    default-target-url='${web.auth.success_url}'/
@spring-issuemaster

Luke Taylor said:

Should all be fixed in trunk. Please try with a snapshot build.

@spring-issuemaster spring-issuemaster added this to the 3.0.0 RC1 milestone Feb 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment