Skip to content
Chris Petersen edited this page Oct 21, 2015 · 1 revision

Returns RSA decrypted messsage.

Parameter Description
key key to use for decryption
msg message to decrypt

Example

> (define priv (rsa-key-gen 32))
> (define pub  (rsa-pub-key priv))
> (rsa-encrypt pub "test123")
#u8(28 154 84 21 192 44 49 206)
> (u8vector->string (rsa-decrypt priv '#u8(28 154 84 21 192 44 49 206)))
"test123"
Clone this wiki locally