Results 1 to 7 of 7

Thread: Ldap Authentication failed message comes up "No AuthenticationProvider..."

  1. #1

    Default Ldap Authentication failed message comes up "No AuthenticationProvider..."

    Hi,

    Using Ldap for Authentication. Authentication is working fine when entering the correct username/password. When the username or password is entered incorrectly this error message appears:

    2008-08-22 11:27:11,543 DEBUG [org.springframework.security.ui.webapp.Authenticat ionProcessingFilter] - Authentication request failed: org.springframework.security.providers.ProviderNot FoundException: No AuthenticationProvider found for org.springframework.security.providers.UsernamePas swordAuthenticationToken

    I'd like to know if it's possible to get a more meaningful error message like incorrect username or incorrect password. The error message is propagated to the UI, the "No AuthenticationProvider found ..." error message doesn't make much sense to the normal user.

    thanks

  2. #2
    Join Date
    Oct 2008
    Posts
    6

    Default LDAP authentication problem

    Hi

    I am trying to use LDAP authentication or petclinic example but I am getting follwing error message on my login page.

    ===================================
    Your login attempt was not successful, try again.

    Reason: No AuthenticationProvider found for org.springframework.security.providers.UsernamePas swordAuthenticationToken
    =====================================
    attached is my appcontext file.


    can anyone please help me?
    Attached Files Attached Files

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

    Default

    You are using Acegi Security and Spring Security jars in the same app. This won't work.

  4. #4
    Join Date
    Oct 2008
    Posts
    6

    Default LDAP authentication fails : No Authentication Providers found

    Thank you so much for the reply.
    I am trying to do LDAP authentication for last 3 days but still no luck.
    I updated the applicationcontext file to use pure spring security removing acegi references but still I am getting the same error. Please help.
    attached is my updated file.
    Attached Files Attached Files

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

    Default

    Start with the LDAP sample application - i.e. a working configuration. Then modify it to fit your needs. You cannot configure a ProviderManager for use with the namespace - this is explained in the reference manual.

  6. #6
    Join Date
    Oct 2008
    Posts
    6

    Default

    Thnaks

    I tried to look for a sample LDAP authentication application on net but could not get one. Could you please provide me some link?

  7. #7
    Join Date
    Oct 2008
    Posts
    6

    Default

    Hi
    I got the sample application from link given in reference mannual and realised that I was missing below tag in my ldap authentication bean definition.

    <s:custom-authentication-provider/>


    I finally got LDAP Authentication thing working

    thanks for the help.

Posting Permissions

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