For Programmers: Free Programming Magazines  


Home > Archive > Java Help > April 2005 > NoSuchAlgorithmException









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author NoSuchAlgorithmException
David B. Held

2005-03-31, 4:02 pm

I've been using the javax.crypto package for several months with no
incident. However, starting yesterday, my applications suddenly fail
with the exception noted in the subject. There must be something very
wrong with my installation, because even this trivial program fails:

import javax.crypto.Cipher;
public class Main
{
public static void main(String[] args)
{
try
{
Cipher.getInstance("Blowfish");
}
catch (Exception e)
{
e.printStackTrace();
}
}
}

It says: "Cannot find any provider supporting Blowfish". I'm using
jdk-1.5.0_01 with Eclipse 3.0.1. I also had the 1.5 jre installed as
well, but I uninstalled it to see if that made any difference. My
java.security file is the default, and appears to specify all the
normal security providers. I also have j2ee installed, but I don't see
why that should cause any problems. Any help would be appreciated.

Dave

Stefan Schulz

2005-04-06, 12:45 pm

On Thu, 31 Mar 2005 09:32:40 -0800, David B. Held wrote:

>
> It says: "Cannot find any provider supporting Blowfish". I'm using
> jdk-1.5.0_01 with Eclipse 3.0.1. I also had the 1.5 jre installed as
> well, but I uninstalled it to see if that made any difference. My
> java.security file is the default, and appears to specify all the
> normal security providers. I also have j2ee installed, but I don't see
> why that should cause any problems. Any help would be appreciated.


Try invoking from the command line. If this works, configure the settings
of your JRE in the Eclipse preferences (Preferences->Java->Installed
JREs->Configure) to "use system default libraries" I don't quite know what
causes this problem, but this fixes

--
In pioneer days they used oxen for heavy pulling, and when one ox
couldn't budge a log, they didn't try to grow a larger ox. We shouldn't
be trying for bigger computers, but for more systems of computers.
--- Rear Admiral Grace Murray Hopper

Roland

2005-04-06, 12:45 pm

On 4-4-2005 22:05, Stefan Schulz wrote:

> On Thu, 31 Mar 2005 09:32:40 -0800, David B. Held wrote:
>
>
>
>
> Try invoking from the command line. If this works, configure the settings
> of your JRE in the Eclipse preferences (Preferences->Java->Installed
> JREs->Configure) to "use system default libraries" I don't quite know what
> causes this problem, but this fixes
>

If 'Use system libraries' is unchecked (off), Eclipse adds the
'-Xbootclasspath' parameter --with all the libs in the list-- to the
java executable.
If it is checked, Eclipse doesn't add -Xbootclasspath, so it allows the
java executable to discover its own boot classpath.
--
Regards,

Roland de Ruiter
___ ___
/__/ w_/ /__/
/ \ /_/ / \
David B. Held

2005-04-20, 8:58 pm

Roland wrote:
> On 4-4-2005 22:05, Stefan Schulz wrote:
> [...]
> If 'Use system libraries' is unchecked (off), Eclipse adds the
> '-Xbootclasspath' parameter --with all the libs in the list-- to the
> java executable.
> If it is checked, Eclipse doesn't add -Xbootclasspath, so it allows

the
> java executable to discover its own boot classpath.


Thanks for the replies. It turns out that I had moved around my
JREs a bit and Eclipse. After getting all the paths
correct, I had to delete some files in a debug directory under
some configuration folder because they managed to store an absolute
path to the old JRE. Found that trick somewhere on the net. It
all works great now.

Dave

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com