Forum Stats

  • 3,815,580 Users
  • 2,259,053 Discussions
  • 7,893,174 Comments

Discussions

wallet_location in ODP Managed Provider config has no effect

Niels Jespersen
Niels Jespersen Member Posts: 77 Blue Ribbon
edited Jan 15, 2016 7:06AM in ODP.NET

Hello all

Has anyone had any luck specifying the location of an Oracle Wallet in the configuration  of the managed provider. I can get Oracle Wallets working with both the managed provider and the unmanaged one, but only by specifying wallet_location in sqlnet.ora.

The setting in e.g. the configuration for managed provider does not seem to have any effect. My working example stops to work if i remove wallet_location from sqlnet.ora. c:\snot\wallet includes ewallet.p12, cwallet.sso, ewallet.lck, and cwallet.lck These were made using mkstore -create and mkstore -createcredential. The wallet works, if just sqlnet.ora references it, but I would rather prefer this configuration to be app-specific.

Here is my config, just for reference:

<?xml version="1.0" encoding="utf-8" ?>

<configuration>

  <oracle.manageddataaccess.client>

    <version number="4.121.2.0">

      <settings>

        <setting name="WALLET_LOCATION" value="(SOURCE = (METHOD = FILE)(METHOD_DATA =(DIRECTORY = c:\snot\wallet)))"/>

        <setting name="TNS_ADMIN" value="c:\snot" />

      </settings>

    </version>

  </oracle.manageddataaccess.client>

</configuration>

Regards Niels Jespersen

Niels JespersenSMerrill8

Best Answer

  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Nov 26, 2015 3:38AM Answer ✓

    Added details, found out that wallet_override fooled me.

    If sqlnet.wallet_override = true is in sqlnet.ora then  wallet_location in the config seems to work.  Now I just need support for wallet_override in the .net config. That is not there, as of now, is it? 

    Regards Niels

    Niels Jespersen

Answers

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,057 Employee
    edited Nov 25, 2015 3:02PM

    Are you seeing any ODP.NET or Oracle errors, such as ORA-01017 invalid password?

    Is this for ODP.NET from ODAC 12c Release 4?

    Niels Jespersen
  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Nov 26, 2015 2:23AM

    If I point tns_admin in my configuration to a location, where sqlnet.ora has a wallet_location, it reads username, password from the wallet and logs on. If tns_admin points to a location where sqlnet.ora has no wallet_location, then logon fails with ORA-1017, as it tries external logon and my windows user has no counterpart on Oracle that is identified externally. Since tns_admin is interpreted correctly, I conclude that my configuration-file is read ok.

    Yes, this is ODAC 12c Release 4. The Productversion of Oracle.managedDataAccess.dll is 4.121.2.20150926 ODAC RELEASE 4.

    I am on Windows 7 Enterprise x64, and my .net-project is compiled as x64. ODAC is installed/configured both as x86 and x64.

  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Nov 26, 2015 3:38AM Answer ✓

    Added details, found out that wallet_override fooled me.

    If sqlnet.wallet_override = true is in sqlnet.ora then  wallet_location in the config seems to work.  Now I just need support for wallet_override in the .net config. That is not there, as of now, is it? 

    Regards Niels

    Niels Jespersen
  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,057 Employee
    edited Nov 26, 2015 12:09PM

    WALLET_OVERRIDE is not yet supported in the .NET config.

    Niels Jespersen
  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Nov 27, 2015 1:35AM

    Thank you for helping me get to the bottom of this. I will consider if I dare put wallet_override=true in a sqlnet.ora shared between 600 users. I may end up doing that and hoping it it will not break anything (I don't think it will).

    I consider this resolved.

    Regards Niels Jespersen

  • Alex Keh-Oracle
    Alex Keh-Oracle Posts: 3,057 Employee
    edited Dec 1, 2015 7:16PM

    I need to correct myself. WALLET_OVERRIDE is supported. Oracle just hasn't documented it yet. That will be done with the next iteration of the doc.

    The config file should like the following:

    <?xml version="1.0" encoding="utf-8" ?>

    <configuration>

      <oracle.manageddataaccess.client>

      <version number="*">

      <settings>

      <setting name="sqlnet.WALLET_OVERRIDE" value="true"/>

      </settings>

      </version>

      </oracle.manageddataaccess.client>

    </configuration>

    Niels JespersenSMerrill8Niels Jespersen
  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Jan 15, 2016 5:40AM

    Wow. Cool. I will try this out.

    /Niels

  • Niels Jespersen
    Niels Jespersen Member Posts: 77 Blue Ribbon
    edited Jan 15, 2016 7:06AM

    Wallet.override works like a charm. Great!

    Best Regards Niels Jespersen

This discussion has been closed.