Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

RSA Encryption / Decryption does not work

 
Markus Schmider
Ranch Hand
Posts: 137
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
to try out Java security features I have written the following class (I know I would not be really usefull, just for trying the API):



I call it with the following code



However the original messages is not restored.
decrypted contains a String of zero-length.

Where is the mistake??

Thanks for any input,

Hans
 
Rob Spoor
Sheriff
Posts: 20822
68
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check out line 22.
 
Markus Schmider
Ranch Hand
Posts: 137
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I must be blind...

Thanks a lot

 
Rob Spoor
Sheriff
Posts: 20822
68
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're welcome
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!