Hello Jens Peter Secher

thanks for your answer,

maybe the problem is a bad RSA encryption in my Java Application or a non 
standard RSA encryption ?

I will try standard hex encoder in the java program for extracting the 
ciphertext



"Jens Peter Secher" <[EMAIL PROTECTED]> a écrit dans le message de news: 
[EMAIL PROTECTED]
>
> If they are raw, binary data, you should not use HexDecoder.  But if I do
>
> int main() {
> FileSource privFile( "privatekey.bin", true, 0 );
> RSAES_OAEP_SHA_Decryptor priv( privFile );
> std::string result;
> RandomPool randPool;
> FileSource ciphertext(
> "ciphertext.bin",
> true,
> new PK_DecryptorFilter( randPool, priv, new StringSink( result ) )
> );
> std::cout << '[' << result << ']';
> return 0;
> }
>
> I also get 'invalid ciphertext', so it seems one of the files are
> corrupted, maybe CR/LF problems?  Try using standard hex encodings to
> make sure there are no such problems.
>
> Cheers,
> --
>                                                    Jens Peter Secher
> _DD6A 05B0 174E BFB2 D4D9 B52E 0EE5 978A FE63 E8A1 jpsecher gmail com_
>
> 



Reply via email to