p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional ASP.NET 2.0 Security, Membership, and Role Management ISBN: 978-0-7645-9698-8
This is the forum to discuss the Wrox book Professional ASP.NET 2.0 Security, Membership, and Role Management by Stefan Schackow; ISBN: 9780764596988

Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional ASP.NET 2.0 Security, Membership, and Role Management ISBN: 978-0-7645-9698-8 section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 12th, 2008, 09:06 AM
Registered User
Points: 13, Level: 1
Points: 13, Level: 1 Points: 13, Level: 1 Points: 13, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Nov 2008
Location: Lagos, Lagos, Nigeria.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ad Login

Hi People,

I am trying to use the authentication with Ad but getting this error?

"Logon failure: unknown user name or bad password.
 (C:\Book_Code\Chapter 12\wwwroot\ADProvider\web.config line 57)"

Can somebody kindly assist me.

Thank you,
Yinka Onisarotu

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #2 (permalink)  
Old November 12th, 2008, 10:00 PM
Wrox Author
Points: 228, Level: 4
Points: 228, Level: 4 Points: 228, Level: 4 Points: 228, Level: 4
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2006
Location: Redmond, Washington, USA.
Posts: 76
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The sample website has dummy values for username and password in the provider configuration sections. Those need to be changed based on however you setup your own test AD environment.

-Stefan
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #3 (permalink)  
Old November 13th, 2008, 03:09 AM
Registered User
Points: 13, Level: 1
Points: 13, Level: 1 Points: 13, Level: 1 Points: 13, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Nov 2008
Location: Lagos, Lagos, Nigeria.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Stefan,

Thank you for your quick response. I have changed the user id and password to an account on my domain, and the account is an administrator on the domain.

this is the web.config settings:

 <add name="DirectoryConnection" connectionString="LDAP://HQDC06.Sterlingbank.com"/>

<membership defaultProvider="adminprovider">
    <providers>
        <clear/>


<add name="adminprovider"
        type="System.Web.Security.ActiveDirectoryMembershi pProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
        enableSearchMethods="true"
        connectionUsername="Test03@sterlingbank.com"
        connectionPassword="1234568"
        attributeMapPasswordQuestion="ampPasswordQuestion"
        attributeMapPasswordAnswer="ampPasswordAnswer"
        attributeMapFailedPasswordAnswerCount="ampFailedPa sswordAnswerCount"
        attributeMapFailedPasswordAnswerTime="ampFailedPas swordAnswerTime"
        attributeMapFailedPasswordAnswerLockoutTime="ampFa iledPasswordAnswerLockoutTime"
        enablePasswordReset="true"
        requiresQuestionAndAnswer="true"
        connectionStringName="DirectoryConnection" />
<add name="readonlyprovider"
        type="System.Web.Security.ActiveDirectoryMembershi pProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
        enableSearchMethods="true"
        connectionUsername="test03@sterlingbankng.com"
        connectionPassword="1234568"
        attributeMapPasswordQuestion="ampPasswordQuestion"
        attributeMapPasswordAnswer="ampPasswordAnswer"
        attributeMapFailedPasswordAnswerCount="ampFailedPa sswordAnswerCount"
        attributeMapFailedPasswordAnswerTime="ampFailedPas swordAnswerTime"
        attributeMapFailedPasswordAnswerLockoutTime="ampFa iledPasswordAnswerLockoutTime"
        enablePasswordReset="true"
        requiresQuestionAndAnswer="true"
        connectionStringName="DirectoryConnection" />
</providers>
</membership>

Regards,
Yinka Onisarotu

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #4 (permalink)  
Old November 13th, 2008, 01:49 PM
Wrox Author
Points: 228, Level: 4
Points: 228, Level: 4 Points: 228, Level: 4 Points: 228, Level: 4
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Feb 2006
Location: Redmond, Washington, USA.
Posts: 76
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Just looking at the configuration below, I see a few potential issues:
   -different values for the connection username
   -the word "banking" mis-spelled in one case
   -is it "banking" or "bank"
   -Is the AD that you are using really allowing passwords like "1234568"? I know on a default AD installation that kind of password would fail the default password strength rules

Overall I'm still guessing that the problem has to do with the username/password combo that has been configured for the provider.

-Stefan
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #5 (permalink)  
Old November 17th, 2008, 04:01 AM
Registered User
Points: 13, Level: 1
Points: 13, Level: 1 Points: 13, Level: 1 Points: 13, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Nov 2008
Location: Lagos, Lagos, Nigeria.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Stefan,

Thank you for prompt response. All the information is correct please help me look for solution.

Thank you

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Add existing AD user to AD group via ADSI? thiazi Classic ASP Basics 0 August 24th, 2007 10:27 PM
Getting a Handle on Windows Login with AD dparsons C# 0 February 28th, 2007 09:30 PM
AD Credentials gygaxx Visual Basic 2005 Basics 4 January 10th, 2007 08:32 AM
AD Usernames ldoodle Classic ASP Basics 1 June 29th, 2005 03:36 PM
Ad ImpressionCount? developerz BOOK: ASP.NET Website Programming Problem-Design-Solution 0 November 17th, 2003 12:34 PM



All times are GMT -4. The time now is 11:40 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc