Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ODP.NET Integrated Security Invalid Connection String Argument

What am I missing?

<add name="test" 
    connectionString="Data Source=TEST_ORACLE;Integrated Security=Yes;" />

[ArgumentException: 'Integrated Security' is an invalid connection string attribute]
   Oracle.DataAccess.Client.OracleConnection.ParseConnectionString() +2707
   Oracle.DataAccess.Client.OracleConnection.set_ConnectionString(String value) +533
   Oracle.DataAccess.Client.OracleConnection..ctor(String connectionString) +210

ODP.NET: Oracle.DataAccess - 2.102.2.20 (I am using a bindingRedirect to this version.)

If I take out Integrated Security and declare User ID and password then it functions correctly. So, I know there is nothing wrong with ODP.NET.

like image 890
Travis Heseman Avatar asked Feb 09 '11 21:02

Travis Heseman


1 Answers

I don't think that ODP has the Integrated Security Attribute: http://download.oracle.com/docs/html/E10927_01/featConnecting.htm#i1006259

but this site (http://www.oracle.com/technetwork/topics/dotnet/code-154692.html) states

To migrate to ODP.NET, remove these attributes if they are part of the Microsoft OracleClient connection string.

* Integrated Security -- Set " User Id=/" in the ODP.NET connection

string for the equivalent operating system authentication.

which is the same that these guys go through: http://forums.oracle.com/forums/thread.jspa?threadID=583813&tstart=405

So use User Id=/ and see if that works

also make sure to have your sqlnet.ora have "SQLNET.AUTHENTICATION_SERVICES = (NTS)"

like image 113
Harrison Avatar answered Nov 07 '22 12:11

Harrison