79539171

Date: 2025-03-27 14:28:33
Score: 1
Natty:
Report link

The usage can be found here: http://www.cypherspace.org/rsa/story2.html

If the code is place in a file called rsa, then it can be run with arguments -k for the key. The file to encrypt / decrypt is read from STDIN, and the result is written to STDOUT.

In short: to encrypt to a public key:

rsa -k=public-key -n=rsa-modulus < msg > msg.rsa

And to decrypt the message with the private key

rsa -k=private-key -n=rsa-modulus < msg.rsa > msg.out

The Perl code is a condensed version of the already small code which can be found here:

http://www.cypherspace.org/rsa/org-post.html

Reasons:
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: paulv