[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[iaik-jce] RSA + demo-Keystore



hello,

i tried to compile the demo keystore with  IAIK Evaluation Version 2.51  but
I received an error:

Installed security providers providers:

Provider 1: IAIK  version: 2.5100000000000002
Provider 2: SUN  version: 1.2

Create new KeyStore in directory: c:\....\....\DemoIAIK [y]y
KeyStore will be saved to: c:\....\....\DemoIAIK\jce.keystore

generate RSA KeyPair for CA certificate [1024 bits]...
generate RSA KeyPair for a test certificate [512 bits]...
generate RSA KeyPair for a test certificate [1024 bits]...
generate RSA KeyPair for a test certificate [2048 bits]...
generate DSA KeyPair for CA certificate [1024 bits]...
generate DSA KeyPair for a test certificate [512 bits]...
generate DSA KeyPair for a server certificate [1024 bits]...
generate DSA KeyPair for a server certificate [2048 bits]...
generate DH KeyPair for a test certificate [512 bits]...
generate DH KeyPair for a server certificate [1024 bits]...
generate DH KeyPair for a server certificate [2048 bits]...
create self signed RSA CA certificate...

Exception: java.lang.RuntimeException: Error creating the certificate:
InitSign error: java.security.NoSuchAlgorithmException: Algorithm RSA not
implemenated.
----------------------------------------------------------------------------
----------------------------------------------------------------------------
---------

I received an error when I try to run the following code:
....
                 import java.io.*;
                 import java.math.BigInteger;
                 import java.security.*;
                 import iaik.security.rsa.* ;
                 import iaik.security.provider.IAIK;

                 KeyPairGenerator key_gen =
KeyPairGenerator.getInstance("RSA","IAIK");
                 RSAKeyPairGenerator rsa_key_gen =
(RSAKeyPairGenerator)key_gen;
                 SecureRandom random = SecureRandom.getInstance("SHA1PRNG",
"SUN");
                 rsa_key_gen.initialize(1024, random);

                 KeyPair rsa_pair = rsa_key_gen.generateKeyPair();
                 PrivateKey rsa_priv = rsa_pair.getPrivate();
                 PublicKey rsa_pub = rsa_pair.getPublic();

                 Signature sharsa = Signature.getInstance("SHA/RSA","IAIK");
---->         sharsa.initSign(rsa_priv);

                 "Exception: InitSign error:
java.security.NoSuchAlgorithmException: Algorithm RSA not implemenated."



                 P.S:: the word "implemenated" is NOT my implementation !
:-)
----------------------------------------------------------------------------
-----------------------------------------------

                Question : Is RSA not full implemented in the
Evaluation-Version and only available in the commercial version ?
                                or because of the RSA- patent ( it end's
september 2000 ) ?
                                or what's wrong ?

                                The RSA Keys are generated in the first and
also in the second code !
                                It looks like that SUN-JCE try to execute
RSA and throw out an error and not IAIK !?

Thank you
Henrik




--
Mailinglist-archive at http://jcewww.iaik.at/mailarchive/iaik-jce/jcethreads.html

To unsubscribe send an email to listserv@iaik.at with the folowing content: UNSUBSCRIBE iaik-jce