libcryptosec
|
static class to perform asymmetric ciphers, using asymmetric keys (eg. RSA keys) More...
#include <AsymmetricCipher.h>
Public Types | |
enum | Padding { NO_PADDING, PKCS1, SSLV23, PKCS1_OAEP } |
Static Public Member Functions | |
static ByteArray | encrypt (RSAPublicKey &key, ByteArray &data, AsymmetricCipher::Padding padding) throw (AsymmetricCipherException) |
static ByteArray | encrypt (RSAPublicKey &key, std::string &data, AsymmetricCipher::Padding padding) throw (AsymmetricCipherException) |
static ByteArray | decrypt (RSAPrivateKey &key, ByteArray &data, AsymmetricCipher::Padding padding) throw (AsymmetricCipherException) |
static class to perform asymmetric ciphers, using asymmetric keys (eg. RSA keys)
|
static |
decrypt encrypted data using a asymmetric private key
key | private key to decrypt encrypted data |
data | data to be decrypted type of padding to use in process (must be the same used to perform the encrypting operation |
AsymmetricCipherException | if any problem happen, throw this exception with a ENCRYPTING_DATA code. |
|
static |
encrypt unreadable data using a asymmetric public key
key | public key to encrypt data |
data | data to be encrypted type of padding to use in process |
AsymmetricCipherException | if any problem happen, throw this exception with a ENCRYPTING_DATA code. |
|
static |
encrypt readable data using a asymmetric public key
key | public key to encrypt data |
data | data to be encrypted type of padding to use in process |
AsymmetricCipherException | if any problem happen, throw this exception with a ENCRYPTING_DATA code. |