Results 1 to 3 of 3

Thread: Custom filters in multiple files

  1. #1
    Join Date
    Jun 2010
    Location
    Warsaw, Poland
    Posts
    1

    Default Custom filters in multiple files

    Hi, I want to migrate my application from Spring Security 2 to version 3 because of better API. In fact, I've got trouble with custom filters.

    In Spring Security 2.0 I can have multiple XML contexts with custom filters defined for example like:

    Code:
      <bean id="myPreAuthenticatedProcessingFilter"
            class="test.MyPreAuthenticatedProcessingFilter">
        <security:custom-filter position="PRE_AUTH_FILTER"/>
        <property name="authenticationManager" ref="authenticationManager"/>
        <property name="authenticationDetailsSource" ref="myPreDetailsSource"/>
      </bean>
    where MyPreAuthenticatedProcessingFilter extends AbstractPreAuthenticatedProcessingFilter. In 3.0 the security:custom-filter element was moved to security:http element.

    Is there any solution to configure custom filters in multiple files in 3.0 version?
    Last edited by Bartłomiej Chmielewski; Jun 24th, 2010 at 07:14 AM.

  2. #2

    Default

    I too have this same problem. Must a <custom-filter> element exist only inside a <http> element? The schema suggests so, but just wish to confirm.

  3. #3
    Luke Taylor is offline Senior Member Acegi Security System TeamSpring Team
    Join Date
    Aug 2004
    Location
    Glasgow, Scotland
    Posts
    3,449

    Default

    Yes, it has to go inside the <http> element. Otherwise (amongst other things) we would not be able to support multiple filter chains in the namespace.
    Spring - by Pivotal
    twitter @tekul

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •