Provides cryptographic functions.
More...
#include <Crypto.h>
|
static const string | rsa_encrypt (const char *public_key, const string &message) |
| Encrypts a message with RSA algorithm. More...
|
|
static const string | rsa_decrypt (const char *private_key, const string &message) |
| Decrypts a message with RSA algorithm. More...
|
|
static const string | rsa_signature_encrypt (const char *key, bool key_is_public, const string &message) |
| Computes RSA signature for message. More...
|
|
static const string | rsa_signature_decrypt (const char *key, bool key_is_public, const string &signature) |
| Recovers message from RSA signature. More...
|
|
Provides cryptographic functions.
Definition at line 40 of file Crypto.h.
const string Crypto::rsa_decrypt |
( |
const char * |
private_key, |
|
|
const string & |
message |
|
) |
| |
|
static |
Decrypts a message with RSA algorithm.
- Parameters
-
private_key | NULL terminated RSA private key string |
message | Message to decrypt |
- Returns
- Decrypted message
Definition at line 123 of file Crypto.cc.
const string Crypto::rsa_encrypt |
( |
const char * |
public_key, |
|
|
const string & |
message |
|
) |
| |
|
static |
Encrypts a message with RSA algorithm.
- Parameters
-
public_key | NULL terminated RSA public key string |
message | Message to encrypt |
- Returns
- Encrypted message
Definition at line 66 of file Crypto.cc.
const string Crypto::rsa_signature_decrypt |
( |
const char * |
key, |
|
|
bool |
key_is_public, |
|
|
const string & |
signature |
|
) |
| |
|
static |
Recovers message from RSA signature.
- Parameters
-
key | NULL terminated key string |
key_is_public | Flag indicating if key is public key |
signature | RSA signature of message to decrypt |
- Returns
- Decrypted message
Definition at line 213 of file Crypto.cc.
const string Crypto::rsa_signature_encrypt |
( |
const char * |
key, |
|
|
bool |
key_is_public, |
|
|
const string & |
message |
|
) |
| |
|
static |
Computes RSA signature for message.
- Parameters
-
key | NULL terminated key string |
key_is_public | Flag indicating if key is public key |
message | Message to encrypt RSA signature |
- Returns
- Encrypted message
Definition at line 188 of file Crypto.cc.
The documentation for this class was generated from the following files:
- /home/doug/src/hypertable/src/cc/Common/Crypto.h
- /home/doug/src/hypertable/src/cc/Common/Crypto.cc