Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old July 26th, 2004, 12:20 PM
Registered User
 
Join Date: Jul 2004
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default LDAP Authentication -- Need Help

Hi,
I need to build a small function that is passed user name and password from an asp.net form, authenticate against iPlanet 5.1 directory server using VB.Net.

I am currently trying to fetch the DN of the required entry by doing a filter on data obtained.
ie. DirectoryEntry("LDAP://SERVERNAME:PORTNO/ROOT_DN(OR SUFFIX)", USERName, Password)
SearchResults(DirectoryEntry)
SearchResults.Filter("(uid=" & PassedInUserName & ")")
SearchResult.FineOne()
If not SearchResults is nothing I get the path (which is teh DN of the user record).
Obviously this is not the exact code...but should give you the idea.

Post this I take the path and try getting a directory entry with the path and the given user name and password. If there is no exception that means the bind is successful else some info is wrong (either user name or password or some other login criteria such as expiry etc is not in the right state).

Is this the right approach ? Assuming it is; I am still having trouble getting this to work.

DirectoryEntry takes an AuthenticationType enum. If I set it to Anonymous the call goes through without any user info or even if its is incorrect user info as no authentication is being attempted. If I set the Authentication type to ServerBind or None I get an exception that says the Object is not available on the server.

What should the Authenticaton type be set as in case of connecting to iPlanet 5.1 ? Is there something else Im missing ? Is there a better approach ?

I'm new to LDAP and directory services....any help/guidance/suggestions/ideas will help.
Thanks and regards
Avinash
Reply With Quote
  #2 (permalink)  
Old May 25th, 2006, 12:13 AM
lch lch is offline
Authorized User
 
Join Date: Jan 2005
Location: , , .
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i also meet with this problem , can u share your solution with me ?

i wan to know :
1. is it the possible using C#.Net or ASP.net work on the sun product
-Iplanet server directory ?i wan to do the authentication/authorization

2. how to implement it , can u give me the related hyperlink or some
source
code samples ?

what i wan is :

login.aspx --> login.aspx.cs --> iplanet directory -->login.aspx.cs

i need to develop a security module , which can work on window(c#.net)
platform and unix (java) platform
iplanet will be the server directory !!!

if java.jndi have the method to connect to the MS AD, then i will
suggest my
project manager to use the AD to be the server directory

ASP/JSP --> AD ?
ASP/JSP --> Iplanet ?

which one will be more stable and more powerful ?


actually ....i advise my project manager to use the AD as the server direcotry for the authentication and authorization, bcos ....AD will compatible with the C# project

but ...after complete the C# version , then it will convert to Java version
and java version will run on the unix server ...

so ....my project manager decline to use the AD bcos ..he will afraid to occur imcompatible error in the future

do u have other solution for it

the server directory used for the authentication , just store username, userid, indexid


i have asked this question at
http://forums.microsoft.com/MSDN/Sho...iteID=1&mode=1

but i cant get the answer ....

my contact email is : lauchunhui@yahoo.com

pls contact me ASAP, thx

regards
lau chun hui



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

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
LDAP Authentication Problem zicaden Classic ASP Basics 6 January 14th, 2007 06:23 PM
Help Using LDAP user authentication in ASP page dreamzentrue Classic ASP Basics 0 November 11th, 2005 01:33 PM
LDAP bmains ASP.NET 1.0 and 1.1 Professional 0 May 26th, 2004 07:47 AM



All times are GMT -4. The time now is 01:13 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.