PC Review


Reply
Thread Tools Rate Thread

Accessing AD via ASP through NT Authentication

 
 
=?Utf-8?B?Sm9obiBTd2lkb3Jza2k=?=
Guest
Posts: n/a
 
      18th Nov 2004
I wish to access AD via ASP though NT Authentication, but I am having
problems. The following code produces a Provider error '80040e37'. The code
works fine under Anonymous access but when I change to NT Authentication is
fails. I end with with a 'Table does not exist.' error on the last line of
the code. I once heard that you can't access ADSI via NT Authentication on a
web server.

Thanks, John

samAccountName = a valid network id...

========

sub CheckUser(samAccountName)
Dim strUserName
Dim objConnection, objCommand, objRecordSet
Dim objRootDSE, objItem
Dim strAMAccountName
Dim strInfo, strSplit, strAllowIn, strReports

strUserName = samAccountName

Set objConnection = CreateObject("ADODB.Connection")
objConnection.Open "Provider=ADsDSOObject;"
Set objCommand = CreateObject("ADODB.Command")
objCommand.ActiveConnection = objConnection
objCommand.CommandText = "<LDAP://dc=meemic,dc=ins>;(&(objectCategory=User)
(samAccountName=" & strUserName &
"));sAMAccountName,distinguishedName;subtree"

Set objRecordSet = objCommand.Execute

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Accessing Authentication Cookie with js Khafancoder Microsoft ASP .NET 4 5th Feb 2007 08:07 AM
Using Windows Authentication while accessing Web Service from a mo =?Utf-8?B?SGl0ZXNo?= Microsoft Dot NET Compact Framework 0 3rd Jan 2006 02:34 PM
user authentication while accessing network PCs Brijesh Microsoft Windows 2000 Security 0 18th Feb 2004 09:03 AM
asp.net app accessing my SQLSERVER DB using windows authentication Paul Microsoft ASP .NET 1 13th Nov 2003 10:06 PM
authentication box when accessing router Dwid Windows Networking 4 6th Jul 2003 05:28 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:54 PM.