Query on User Authentication aganist ADS


A

apondu

Hi

I have a query, i have put the code here.

I am using VS 2005, C#.Net.

This is working fine when i am install the Win OS 2003 with ADS, but

after few days it starts entering the exception and gives the message
"

Logon Failure : unknown user name or bad password"

I am a bit confused and want to know the reason for this.

Can someone help me and let me know the reason and solution for this

because i cann't reinstall the OS all the time.


// Start of Code


using (DirectoryEntry deDirEntry = new

DirectoryEntry("LDAP://" + UserDomainTextBox.Text,


UserNameTextBox.Text,


UserPassTextBox.Text,


AuthenticationTypes.Secure))

try
{
string name = deDirEntry.Name.ToString();

MessageBox.Show("Welcome to '" + deDirEntry.Name
+

"'");

}
catch (Exception exp)
{
MessageBox.Show("Sorry, Invalid User");

}

// End of Code


Thanks for the help

Regards,
Govardhan
 
Ad

Advertisements


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top