File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Referring the U.S.Export Policy and localPolicy while creating the Executable Jar

 
Gurumoorthy Doraiswamy
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am a .NET developer and very new to Java. I have created a program which requires 256-bit AES encryption in .NET and Decryption in java. To include the support of 256-bit encryption in Java i downloaded the followed the steps as given in the below url

http://www.ngs.ac.uk/tools/jcepolicyfiles

And to create the executable from jar i used java -cp "jar name". The issue is when i run the program in Netbeans the application works normally. But when i try to run the exe seperately i get the "Illegal key size" error. To refer the external jars i used

java -cp "jar name; jars/*"

where jars is folder name under which i am referring all the necessary jars. The same exe runs normally when i use 128bit encryption. Kindly let me know where i am missing out.

Note: I also tried "jar2exe" wizard trial version but the same error occurs when i use 256-bit encryption and with 128-bit it works normally.
 
Campbell Ritchie
Sheriff
Pie
Posts: 47300
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch
You would have to explain lots more; I cannot understand how the question relates to the thread title.
I shall move this discussion because it is too difficult for “beginning Java”.
 
Richard Tookey
Bartender
Pie
Posts: 1166
17
Java Linux Netbeans IDE
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sounds like you are picking up a 'java' that has not had the unlimited strength files installed. If you are using Windows are you sure you installed it in both the JRE and the JDK? I suspect that Netbeans is using the JDK 'java' and your application when run from the command line is using the JRE 'java' .
 
Gurumoorthy Doraiswamy
Greenhorn
Posts: 21
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Many thanks Richard Tookey. yes it is my mistake the JRE and JDK path which referes does not refer the policies. Really you have saved me
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic