aspose file tools*
The moose likes Security and the fly likes Not able to access BouncyCastle jar from Application jar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Security
Bookmark "Not able to access BouncyCastle jar from Application jar" Watch "Not able to access BouncyCastle jar from Application jar" New topic
Author

Not able to access BouncyCastle jar from Application jar

Shah Jenish
Greenhorn

Joined: Feb 19, 2009
Posts: 13
Hello All,

I have made jar file for my application. One of the class of my application uses BouncyCastleProvider class of BC jar.

I have created one folder "lib" in the same parent folder where my application jar is residing.

I have changed my machine CLASSPATH to point to this new lib folder. But when I run my application it gives me classnotfound exception.

But if I copy this BC jar file to my jre/lib/ext then everything works fine.

Can anybody tell me what I need to do to access BC jar file from my lib directory?

Thanks in Advance,
Jenish
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42935
    
  68
CLASSPATH needs to point to the jar file itself, not the directory it's in.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Not able to access BouncyCastle jar from Application jar