Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How Do I Use The ODP.NET Managed Driver and LDAP ?

Scott BakerFeb 13 2014 — edited Feb 14 2014

I have a .NET 4.5 application using Entity Framework 5.0.0. and I am referencing the current ODP.NET Managed Driver, v.4.121.1.0.  According to the release notes, this version supports LDAP - Huzzah!   The only thing I don't understand is how to use it - documentation is thin on implementing all the aspects of this feature (or, equally possible, I am just a little slow on the uptake).

I have the following structure set in my web.config:


  <oracle.manageddataaccess.client>

    <version number="*">

     <LDAPsettings>

       <LDAPsetting name="DIRECTORY_SERVERS" value="(oid1.mycompany.com:3097:3121,

                                               oid2.mycompany.com:3097:3121,

                                               oid3.stl.mycompany.com:3097:3121,

                                               oid4.mycompany.com:3097:3121)"/>

        <LDAPsetting name="DIRECTORY_SERVER_TYPE" value="oid"/>

        <LDAPsetting name="DEFAULT_ADMIN_CONTEXT" value="dc=mycompanydb"/>

      </LDAPsettings>

      <settings>

        <setting name="NAMES.DIRECTORY_PATH" value="(LDAP)"/>

      </settings>

    </version>

  </oracle.manageddataaccess.client>


Questions about this structure: 

    1. The ldap.ora file has parenthesis around the DIRECTORY_SERVERS value - are the parenthesis required (like I have them here for the LDAPsetting element) or are they not?  Are they optional?
    2. Is the NAMES.DIRECTORY_PATH setting required?  I'm not reading from an ldap.ora or any other .ora file - is this setting necessary?

I also have the following line in the <ConfigSections /> element:

<section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess"/>

I haven't found anything in the documentation that says this is required, but the only other example of this structure had it.  Do I need this?

  1. What else is missing from my configuration to use LDAP? 
  2. How do I get this web.config to work with Server Explorer?
  3. Do I need a <DataSources /> subtree? 
  4. If this web.config is complete, how do I make a request?  How do I say "Hey LDAP - get me the "Wonka" database!"
This post has been answered by Scott Baker on Feb 14 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 14 2014
Added on Feb 13 2014
4 comments
16,935 views