Changeset View
Changeset View
Standalone View
Standalone View
src/wallet/rpcwallet.cpp
Show First 20 Lines • Show All 4,456 Lines • ▼ Show 20 Lines | UniValue getaddressinfo(const Config &config, const JSONRPCRequest &request) { | ||||
if (spk_man) { | if (spk_man) { | ||||
if (const std::unique_ptr<CKeyMetadata> meta = | if (const std::unique_ptr<CKeyMetadata> meta = | ||||
spk_man->GetMetadata(dest)) { | spk_man->GetMetadata(dest)) { | ||||
ret.pushKV("timestamp", meta->nCreateTime); | ret.pushKV("timestamp", meta->nCreateTime); | ||||
if (meta->has_key_origin) { | if (meta->has_key_origin) { | ||||
ret.pushKV("hdkeypath", WriteHDKeypath(meta->key_origin.path)); | ret.pushKV("hdkeypath", WriteHDKeypath(meta->key_origin.path)); | ||||
ret.pushKV("hdseedid", meta->hd_seed_id.GetHex()); | ret.pushKV("hdseedid", meta->hd_seed_id.GetHex()); | ||||
ret.pushKV("hdmasterfingerprint", | ret.pushKV("hdmasterfingerprint", | ||||
HexStr(meta->key_origin.fingerprint, | HexStr(meta->key_origin.fingerprint)); | ||||
meta->key_origin.fingerprint + 4)); | |||||
} | } | ||||
} | } | ||||
} | } | ||||
// Return a `labels` array containing the label associated with the address, | // Return a `labels` array containing the label associated with the address, | ||||
// equivalent to the `label` field above. Currently only one label can be | // equivalent to the `label` field above. Currently only one label can be | ||||
// associated with an address, but we return an array so the API remains | // associated with an address, but we return an array so the API remains | ||||
// stable if we allow multiple labels to be associated with an address in | // stable if we allow multiple labels to be associated with an address in | ||||
▲ Show 20 Lines • Show All 617 Lines • Show Last 20 Lines |