asp:Login works with Windows users email address only

Posted on 2012-08-13
Medium Priority
Last Modified: 2012-08-30
I have an ASP.NET application in C#.
I am using Forms Authentication with AD.

My login screen uses .NET provieded <asp:Login> control.
I am able to logon using user name ase FirstName.LastName@CompName.Com BUT I am not able to logon using CompName\FirstName.LastName .
What am I missing in the application ?
Question by:vu3lmg
  • 2
LVL 84

Expert Comment

by:David Johnson, CD, MVP
ID: 38293888
CompName\FirstName.LastName try networkname\FirstName.LastName
for example my network is windows8tips.local
windows8tips\FirstName.LastName works as does FirstName.LastName@windows8tips.local

Computername is only applicable for local users and not AD users. and it has to be the computer that the iis server is running on to get the authentication records.
LVL 51

Expert Comment

by:Ted Bouskill
ID: 38294905
If the website is used in an intranet with domain users, then you shouldn't be using forms authentication.  You should use Windows Integrated Authentication in IIS.  Is this an intranet application?

Accepted Solution

vu3lmg earned 0 total points
ID: 38302708
OK I got it to work with attribute : attributeMapUsername="sAMAccountName"In the membership - providers' section.
Thanks for your help


Author Closing Comment

ID: 38315501
Following is my provider string for membership

<membership defaultProvider="MyADMembershipProvider">
            <add name="MyADMembershipProvider" type="System.Web.Security.ActiveDirectoryMembershipProvider, System.Web, Version=,  Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="ADConnectionString"                          attributeMapUsername="sAMAccountName"/>

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses
Course of the Month16 days, 15 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question