#include <Cipher.h>
Public Member Functions | |
std::string | b64decrypt (const std::string &input) |
std::string | b64encrypt (const std::string &input) |
Cipher (const std::string &key) | |
std::string | decrypt (const unsigned char *input, size_t inputSize) |
size_t | encrypt (const std::string &input, unsigned char *&output) |
~Cipher () | |
Private Member Functions | |
size_t | bf_process_alloc (const unsigned char *input, size_t input_size, unsigned char *&output, bool decrypt=false) |
Private Attributes | |
BLOWFISH_CTX * | m_ctx |
|
explicit |
Definition at line 10 of file Cipher.cc.
References Blowfish_Init(), gen::k, and m_ctx.
std::string cond::auth::Cipher::b64decrypt | ( | const std::string & | input | ) |
Definition at line 117 of file Cipher.cc.
References base64_decode_alloc, decrypt(), input, AlCaHLTBitMon_QueryRunRegistry::string, and cond::throwException().
Referenced by cond::CredentialStore::exportAll(), cond::CredentialStore::importForPrincipal(), cond::CredentialStore::listConnections(), cond::CredentialStore::resetAdmin(), cond::CredentialStore::selectForUser(), cond::CredentialStore::setPermission(), cond::CredentialStore::startSession(), cond::updateConnectionData(), cond::CredentialStore::updatePrincipal(), and cond::updatePrincipalData().
std::string cond::auth::Cipher::b64encrypt | ( | const std::string & | input | ) |
Definition at line 105 of file Cipher.cc.
References base64_encode_alloc(), bf_process_alloc(), funct::false, MillePedeFileConverter_cfg::out, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by cond::setPermissionData(), cond::updateConnectionData(), and cond::updatePrincipalData().
|
private |
Definition at line 20 of file Cipher.cc.
References Blowfish_Decrypt(), Blowfish_Encrypt(), mps_fire::i, dttmaxenums::L, m_ctx, and dttmaxenums::R.
Referenced by b64encrypt(), decrypt(), and encrypt().
std::string cond::auth::Cipher::decrypt | ( | const unsigned char * | input, |
size_t | inputSize | ||
) |
Definition at line 79 of file Cipher.cc.
References bf_process_alloc(), mps_fire::i, MillePedeFileConverter_cfg::out, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by b64decrypt(), and cond::auth::DecodingKey::init().
size_t cond::auth::Cipher::encrypt | ( | const std::string & | input, |
unsigned char *& | output | ||
) |
Definition at line 71 of file Cipher.cc.
References bf_process_alloc(), funct::false, and convertSQLitetoXML_cfg::output.
Referenced by cond::auth::DecodingKey::flush().
|
private |
Definition at line 34 of file Cipher.h.
Referenced by bf_process_alloc(), Cipher(), and ~Cipher().