LDAP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsDatabasesLDAP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 4th, 2004, 11:01 PM
bubby bubby is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 2 bubby User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question ldap_search_s() error via C API

Does anyone know why I get an "Operations Error" when I try and search the directory via ldap_search_s() in the C API?

The only way i get a result back is if a specify NULL for the DN and FILTER, and set the scope as the LDAP_SCOPE_BASE. This will print out the contents of the node at the "RootDSE", not the "Domain" naming context which I want.

How do I reference the "Domain" naming context instead?

Thanks!
bubby

Reply With Quote
  #2  
Old October 5th, 2004, 10:39 AM
Viper_SB's Avatar
Viper_SB Viper_SB is offline
Psycho Canadian
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: Jan 2001
Location: Canada
Posts: 4,845 Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level)Viper_SB User rank is Brigadier General (60000 - 70000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 20 h 16 m 27 sec
Reputation Power: 634
care to post the code you're trying?

Reply With Quote
  #3  
Old October 6th, 2004, 09:49 AM
bubby bubby is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 2 bubby User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Smile

Quote:
Originally Posted by bubby
Does anyone know why I get an "Operations Error" when I try and search the directory via ldap_search_s() in the C API?

The only way i get a result back is if a specify NULL for the DN and FILTER, and set the scope as the LDAP_SCOPE_BASE. This will print out the contents of the node at the "RootDSE", not the "Domain" naming context which I want.

How do I reference the "Domain" naming context instead?

Thanks!
bubby


Nevermind. I figured it out. I need to authenticate to the directory with the appropriate credentials. I was binding to the directory using NULL as the ID/pwd. Doing it this way only allows me access to the RootDSE. After reading a bit, I found that you have to use valid credentials, other than NULL, to see the Domain subtree.

Thanks!

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesLDAP Programming > ldap_search_s() error via C API

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap