• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

PolicyTool

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have just upgraded my jdk to 1.3...
I am now running into security excepetions when trying to exec a java applet with jdbc accessing a local (to my machine) ms-access database. I can access the ms-access database, with a data source name of 'accessDB' via batch.
If my database exists in c:\java\data
How can I use PolicyToool so that all of my applets can perform
sql: create... drop... insert... update... select ...
Please Help....
Monty6
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to use the PolicyTool utility.
I have done this on an NT box access ms-access via odbc using
the standard jdbc driver.
1. Open a DOS or UNIX command prompt.
2. type POLICYTOOL
3. you will get an error message after starting POLICYTOOL.
write down the popup box dir name
4. press "OK" button
5. press "ADD POLICY" button
6. set "all permissions"
7. press "DONE" button
8. save policy file as "temp.java.policy" in you current directory
9. copy "temp.java.policy" to the dir name you wrote down in step 3.
10. using the DOS or UNIX command line. rename "temp.java.policy" to ".java.policy".
*** the leading "." is very important.
should work perfectly if setup correctly...
doc's on this tool is very poor.
take your time....
TTFN, Monty6
[This message has been edited by monty6 (edited September 11, 2000).]
 
Jeff Grant
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is an old thread, but it just solved my problem... sort of.
I can now access my Oracle DB no problem (it's not even local) using the same code as an applet I had written previously.
Anyways, I was curious if it was possible to just have the user download the file or somehow make this process automated so they don't have to do it manually. I know there must be other ways to connect to the DB so the user does not have to do this. But through much searching about servlets and things which are mentioned, this is the only post that actually gave any answers.
Thanks.
 
Jeff Grant
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
UPDATE:
I tested it on someone else's machine now and with the policytool file run. It worked! Surprised me.
Then I deleted the .java.policy file and it still worked! Now I am curious if it would work if I had never run the policyfile to begin with!
But overall, I give my experience today a
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic