Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

applet connecting to a database

2 views
Skip to first unread message

.nathan.

unread,
Aug 15, 2000, 3:00:00 AM8/15/00
to
I am trying to connect to an oracle 8.1.5 database via an applet. The
database and the server launching the applet are on the same machine. I have
accessed the database by changing the java.policy in the jre of my browser.
I don't want to do this however (or use servlets). Is there someway for a
client to access the
database through the applet without having to change anything on their side?
Here is the error that I am receiving

java.security.AccessControlException: access denied
(java.net.SocketPermission my.IP.add.ress:1521 connect,resolve)
at java.security.AccessControlContext.checkPermission(Unknown Source)
at java.security.AccessController.checkPermission(Unknown Source)
at java.lang.SecurityManager.checkPermission(Unknown Source)
at java.lang.SecurityManager.checkConnect(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
blah
blah
blah

.thanks.
.nathan.


Bob Beaty

unread,
Aug 16, 2000, 3:00:00 AM8/16/00
to
In <FzCCJ...@boss.cs.ohiou.edu> ".nathan." wrote:
> I am trying to connect to an oracle 8.1.5 database via an applet. The
> database and the server launching the applet are on the same machine.
...snip...

> Is there someway for a client to access the
> database through the applet without having to change anything on their
side?

Yes, go to Verisign and spend $400/yr for a digital certificate and
create a signed JAR for your Netscape users and signed CAB for your IE
users.

Unfortunately, Netscape and IE won't agree to a common trusting scheme so
you also have to have some form of scripting that looks for the type of
browser and uses the right <APPLET> tag for the signed JAR or the signed
CAB - depending on the browser.

There's no other way around it... and it doesn't matter that the servers
are the same box - I've done literally dozens of tests and a lot of
research into this only to see that there is no "one size fits all"
solution to the problem.

IE has a SecurityManager you can fiddle with in code, but then when you
go to a non-Microsoft platform you get errors... you can't have a single
signed package because Microsoft won't acknowledge a signed JAR and
Netscape doesn't believe in the CAB file format.

It's a big pain in the neck...

Thanks,
Bob (bobb...@mediaone.net)
The Man from S.P.U.D.
We will write no code before it's designed.


a.v

unread,
Aug 17, 2000, 3:00:00 AM8/17/00
to
First of all you don't need to go to Verisign, if you just want to use that
application for internal (any private or firm-internal) use, where no other
users (coming from the internet ) can access - so maybe in an intranet.
Also you don't need to buy some verisign-certicate, if you just want to
develop and test the Applet. You also are able to let it run if you give it
permission of accessing by Signing it.
Go to http://developer.netscape.com/docs/manuals/signedobj/capsapi.html
http://developer.netscape.com/docs/manuals/signedobj/javadoc/Package-netscap
e_security.html
http://developer.netscape.com/docs/manuals/signedobj/capabilities/index.html
There will all the necessary information.

"Bob Beaty" <bobb...@mediaone.net> schrieb im Newsbeitrag
news:z%zm5.2444$Fo1.372580@elnws01...

0 new messages