| 415 | } |
| 416 | |
| 417 | string RSADecryptString(const char *privFilename, const char *ciphertext) |
| 418 | { |
| 419 | FileSource privFile(privFilename, true, new HexDecoder); |
| 420 | RSAES_OAEP_SHA_Decryptor priv(privFile); |
| 421 | |
| 422 | string result; |
| 423 | StringSource(ciphertext, true, new HexDecoder(new PK_DecryptorFilter(GlobalRNG(), priv, new StringSink(result)))); |
| 424 | return result; |
| 425 | } |
| 426 | |
| 427 | void RSASignFile(const char *privFilename, const char *messageFilename, const char *signatureFilename) |
| 428 | { |
no test coverage detected