Path: dp-news.maxwell.syr.edu!spool.maxwell.syr.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!postnews.google.com!b28g2000cwb.googlegroups.com!not-for-mail
From: "joel garry" <joel-garry@home.com>
Newsgroups: comp.databases.oracle.misc
Subject: Re: help connecting to oracle via javascript with osauthent
Date: 8 Aug 2006 16:52:03 -0700
Organization: http://groups.google.com
Lines: 47
Message-ID: <1155081123.778461.139120@b28g2000cwb.googlegroups.com>
References: <1155050872.386959.163370@i42g2000cwa.googlegroups.com>
NNTP-Posting-Host: 67.116.125.178
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
X-Trace: posting.google.com 1155081128 14221 127.0.0.1 (8 Aug 2006 23:52:08 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Tue, 8 Aug 2006 23:52:08 +0000 (UTC)
In-Reply-To: <1155050872.386959.163370@i42g2000cwa.googlegroups.com>
User-Agent: G2/0.2
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0),gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.0 ISA2K4-OC1
Complaints-To: groups-abuse@google.com
Injection-Info: b28g2000cwb.googlegroups.com; posting-host=67.116.125.178;
   posting-account=YRNZ5wwAAAAg-yYjMFwy3FyWUbPiwNdq
Xref: dp-news.maxwell.syr.edu comp.databases.oracle.misc:129151


Wyatt wrote:
> I'm trying to connect to an oracle 10g database with javascript using
> os authentication.  For now, I'm running the script on the database
> host.
>
> Using sql*plus, I can connect with "connect / as sysdba"
>
> this script works
> var connectionString = 	"Provider=OraOLEDB.Oracle;"
> 			+ "Data Source=orcl;"
> 			+ "OSAuthent=0;"
> 			+ "DBA Privilege=SYSDBA;"
> 			+ "User Id=system;"
> 			+ "Password=***;";
>
> var cn = WScript.CreateObject("ADODB.Connection");
> cn.Open(connectionString);
> cn.Close();
>
> This script does not work, with error:
> ORA-01017:invalid username/password; logon denied
> var connectionString = 	"Provider=OraOLEDB.Oracle;"
> 			+ "Data Source=orcl;"
> 			+ "OSAuthent=1;";
>
> var cn = WScript.CreateObject("ADODB.Connection");
> cn.Open(connectionString);
> cn.Close();
>
> I've tried variations ofthe connectionstring, but get the same error
> message.
> Am I missing and argument in the connectionstring?
> Is there a different method to use?
>
> Thanks in advance.

There is an init.ora parameter called OS_AUTHENT_PREFIX.  It defaults
to OPS$.  So you would have to have a user named OPS$SYSTEM if it is
the default.

jg
--
@home.com is bogus.
http://online.wsj.com/public/article/SB115457177198425388.html?mod=technorati
propaganda 101

