• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem in getting Keystore through Browser

 
amit vishnoi
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I am trying you provide signing feature through web(JSP) application.I have written a applet for signing any document. But when i m using MVM(Microsoft virtual machine), I am getting following error on signing that data.
java.lang.ClassNotFoundException: java.security.KeyStore
at com/ms/vm/loader/URLClassLoader.loadClass
at java/lang/ClassLoader.loadClassInternal
at com/newgen/sign/DigSignApplet.signData
Obviously it seems that browser dont have these java.security classes with it.But ideally i can say those are core java classes which should be available with any VM.
Can anyone help me how i can direct a browser so that it can those classes.
Thanks and Best Regards
Amit Vishnoi
 
Joe Ess
Bartender
Posts: 9340
10
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The class you are trying to access was added to the Java API in version 1.2. The Microsoft Java VM was frozen with the 1.1.4 API, will not be updated, and will not be supported after September 30, 2004. I suggest you look into the Java Plug-In
 
amit vishnoi
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanx,
That means I have to ask my clients to migrate from MVM to java plug-in.One more problem I am facing with java plugin access problem
I am using following version of VM
Plug-in: Version 1.4.1_07
Using JRE version 1.4.1_07 Java HotSpot(TM) Client VM
Although I have signed my applet and also given explisit permission for fileIO in code like
.............
if(System.getProperty("java.vendor").indexOf("Microsoft") != -1)
{
try
{
System.out.println("I am assigning permission");
PolicyEngine.assertPermission(PermissionID.NETIO);
PolicyEngine.assertPermission(PermissionID.FILEIO);
PolicyEngine.assertPermission(PermissionID.SYSTEM);
}
catch(Throwable e)
{
System.out.println("some exception in asserting permission");
e.printStackTrace();
}
}
else if((System.getProperty("java.vendor").indexOf("Netscape") != -1) ||
(System.getProperty("java.vendor").indexOf("Apple") != -1) ||
(System.getProperty("java.vendor").indexOf("Sun") != -1))
{
try
{
PrivilegeManager.enablePrivilege("UniversalFileAccess");
}
catch(Throwable e)
{
}
}
............
But still it giving me following error on file reading......

access denied (java.io.FilePermission -------------------
But If i grant permission in the policy file in following manner
grant
{
permission java.security.AllPermissions;
permission java.io.FilePermission
"E://pgp//My Testing//keyparse//privatefile", "read,write";
};
But i dont find this very impressive because i have to ask my clients specifcally for granting permission to do there specific file.
As above mentioned above granting permission in applet code.Although I tried it for sun vendor but its not working.
Please suggest....
Thanks and Best Regards
Amit Vishnoi
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic