Dash Core Source Documentation (0.16.0.1)
Find detailed information regarding the Dash Core source code.
#include <keepass.h>
Classes | |
class | CKeePassEntry |
class | CKeePassRequest |
class | CKeePassResponse |
Public Member Functions | |
CKeePassIntegrator () | |
void | init () |
void | rpcAssociate (std::string &strIdRet, SecureString &sKeyBase64Ret) |
SecureString | retrievePassphrase () |
void | updatePassphrase (const SecureString &sWalletPassphrase) |
Static Public Member Functions | |
static SecureString | generateKeePassKey () |
Private Member Functions | |
void | doHTTPPost (const std::string &strRequest, int &nStatusRet, std::string &strResponseRet) |
void | rpcTestAssociation (bool bTriggerUnlock) |
std::vector< CKeePassEntry > | rpcGetLogins () |
void | rpcSetLogin (const SecureString &sWalletPass, const SecureString &sEntryId) |
Static Private Member Functions | |
static SecureString | generateRandomKey (size_t nSize) |
static std::string | constructHTTPPost (const std::string &strMsg, const std::map< std::string, std::string > &mapRequestHeaders) |
Private Attributes | |
bool | bIsActive |
unsigned int | nPort |
SecureString | sKeyBase64 |
SecureString | sKey |
SecureString | sUrl |
std::string | strKeePassId |
std::string | strKeePassEntryName |
Static Private Attributes | |
static const int | KEEPASS_CRYPTO_KEY_SIZE = 32 |
static const int | KEEPASS_CRYPTO_BLOCK_SIZE = 16 |
static const int | KEEPASS_HTTP_CONNECT_TIMEOUT = 30 |
static const char * | KEEPASS_HTTP_HOST = "localhost" |
Detailed Description
Constructor & Destructor Documentation
◆ CKeePassIntegrator()
CKeePassIntegrator::CKeePassIntegrator | ( | ) |
Definition at line 91 of file keepass.cpp.
References bIsActive, DEFAULT_KEEPASS_HTTP_PORT, nPort, sKey, sKeyBase64, and sUrl.
Member Function Documentation
◆ constructHTTPPost()
|
staticprivate |
Definition at line 237 of file keepass.cpp.
References FormatFullVersion().
◆ doHTTPPost()
|
private |
Definition at line 287 of file keepass.cpp.
References DEFAULT_KEEPASS_HTTP_PORT, UniValue::empty(), FormatFullVersion(), UniValue::get_obj(), UniValue::get_str(), HTTP_BAD_REQUEST, HTTP_INTERNAL_SERVER_ERROR, HTTP_NOT_FOUND, http_request_done(), BCLog::KEEPASS, KEEPASS_HTTP_CONNECT_TIMEOUT, KEEPASS_HTTP_HOST, LogPrint, UniValue::read(), strprintf, and UniValue::VSTR.
Referenced by rpcAssociate(), rpcGetLogins(), rpcSetLogin(), and rpcTestAssociation().
◆ generateKeePassKey()
|
static |
Definition at line 453 of file keepass.cpp.
References EncodeBase64Secure(), generateRandomKey(), KEEPASS_CRYPTO_KEY_SIZE, sKey, and sKeyBase64.
Referenced by keepass().
◆ generateRandomKey()
|
staticprivate |
Definition at line 225 of file keepass.cpp.
References GetStrongRandBytes(), and sKey.
Referenced by generateKeePassKey(), CKeePassIntegrator::CKeePassRequest::init(), and rpcAssociate().
◆ init()
void CKeePassIntegrator::init | ( | ) |
Definition at line 102 of file keepass.cpp.
References bIsActive, DecodeBase64Secure(), DEFAULT_KEEPASS_HTTP_PORT, gArgs, ArgsManager::GetArg(), ArgsManager::GetBoolArg(), nPort, sKey, sKeyBase64, strKeePassEntryName, strKeePassId, and sUrl.
Referenced by WalletInit::InitKeePass().
◆ retrievePassphrase()
SecureString CKeePassIntegrator::retrievePassphrase | ( | ) |
Definition at line 499 of file keepass.cpp.
References rpcGetLogins(), sKey, strKeePassEntryName, and strKeePassId.
Referenced by CWallet::ChangeWalletPassphrase(), and CWallet::Unlock().
◆ rpcAssociate()
void CKeePassIntegrator::rpcAssociate | ( | std::string & | strIdRet, |
SecureString & | sKeyBase64Ret | ||
) |
Definition at line 460 of file keepass.cpp.
References CKeePassIntegrator::CKeePassRequest::addStrParameter(), doHTTPPost(), EncodeBase64Secure(), generateRandomKey(), CKeePassIntegrator::CKeePassRequest::getJson(), CKeePassIntegrator::CKeePassResponse::getStr(), CKeePassIntegrator::CKeePassResponse::getSuccess(), itostr(), BCLog::KEEPASS, KEEPASS_CRYPTO_KEY_SIZE, LogPrint, and sKey.
Referenced by keepass().
◆ rpcGetLogins()
|
private |
Definition at line 362 of file keepass.cpp.
References CKeePassIntegrator::CKeePassRequest::addStrParameter(), DecodeBase64Secure(), doHTTPPost(), CKeePassIntegrator::CKeePassResponse::getEntries(), CKeePassIntegrator::CKeePassRequest::getJson(), CKeePassIntegrator::CKeePassResponse::getSuccess(), itostr(), BCLog::KEEPASS, LogPrint, sKey, sKeyBase64, strKeePassId, and sUrl.
Referenced by retrievePassphrase(), and updatePassphrase().
◆ rpcSetLogin()
|
private |
Definition at line 404 of file keepass.cpp.
References CKeePassIntegrator::CKeePassRequest::addStrParameter(), DecodeBase64Secure(), doHTTPPost(), CKeePassIntegrator::CKeePassRequest::getJson(), CKeePassIntegrator::CKeePassResponse::getSuccess(), itostr(), BCLog::KEEPASS, LogPrint, sKey, sKeyBase64, strKeePassId, and sUrl.
Referenced by updatePassphrase().
◆ rpcTestAssociation()
|
private |
Definition at line 349 of file keepass.cpp.
References CKeePassIntegrator::CKeePassRequest::addStrParameter(), doHTTPPost(), CKeePassIntegrator::CKeePassRequest::getJson(), BCLog::KEEPASS, LogPrint, and sKey.
◆ updatePassphrase()
void CKeePassIntegrator::updatePassphrase | ( | const SecureString & | sWalletPassphrase | ) |
Definition at line 533 of file keepass.cpp.
References rpcGetLogins(), rpcSetLogin(), sKey, strKeePassEntryName, and strKeePassId.
Referenced by CWallet::ChangeWalletPassphrase(), CWallet::EncryptWallet(), and keepass().
Member Data Documentation
◆ bIsActive
|
private |
Definition at line 25 of file keepass.h.
Referenced by CKeePassIntegrator(), and init().
◆ KEEPASS_CRYPTO_BLOCK_SIZE
|
staticprivate |
Definition at line 21 of file keepass.h.
Referenced by CKeePassIntegrator::CKeePassRequest::init().
◆ KEEPASS_CRYPTO_KEY_SIZE
|
staticprivate |
Definition at line 20 of file keepass.h.
Referenced by generateKeePassKey(), and rpcAssociate().
◆ KEEPASS_HTTP_CONNECT_TIMEOUT
|
staticprivate |
Definition at line 22 of file keepass.h.
Referenced by doHTTPPost().
◆ KEEPASS_HTTP_HOST
|
staticprivate |
Definition at line 23 of file keepass.h.
Referenced by doHTTPPost().
◆ nPort
|
private |
Definition at line 26 of file keepass.h.
Referenced by CKeePassIntegrator(), and init().
◆ sKey
|
private |
Definition at line 28 of file keepass.h.
Referenced by CKeePassIntegrator::CKeePassRequest::addStrParameter(), CKeePassIntegrator(), CKeePassIntegrator::CKeePassResponse::decrypt(), generateKeePassKey(), generateRandomKey(), init(), retrievePassphrase(), rpcAssociate(), rpcGetLogins(), rpcSetLogin(), rpcTestAssociation(), and updatePassphrase().
◆ sKeyBase64
|
private |
Definition at line 27 of file keepass.h.
Referenced by CKeePassIntegrator(), generateKeePassKey(), init(), rpcGetLogins(), and rpcSetLogin().
◆ strKeePassEntryName
|
private |
Definition at line 32 of file keepass.h.
Referenced by init(), retrievePassphrase(), and updatePassphrase().
◆ strKeePassId
|
private |
Definition at line 31 of file keepass.h.
Referenced by init(), retrievePassphrase(), rpcGetLogins(), rpcSetLogin(), and updatePassphrase().
◆ sUrl
|
private |
Definition at line 29 of file keepass.h.
Referenced by CKeePassIntegrator(), init(), rpcGetLogins(), and rpcSetLogin().
The documentation for this class was generated from the following files:
- src/keepass.h
- src/keepass.cpp