MCPcopy Create free account
hub / github.com/bitcoinxt/bitcoinxt / EncodeBase58Check

Function EncodeBase58Check

src/base58.cpp:112–119  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110}
111
112std::string EncodeBase58Check(const std::vector<unsigned char>& vchIn)
113{
114 // add 4-byte hash check to the end
115 std::vector<unsigned char> vch(vchIn);
116 uint256 hash = Hash(vch.begin(), vch.end());
117 vch.insert(vch.end(), (unsigned char*)&hash, (unsigned char*)&hash + 4);
118 return EncodeBase58(vch);
119}
120
121bool DecodeBase58Check(const char* psz, std::vector<unsigned char>& vchRet)
122{

Callers 1

ToStringMethod · 0.85

Calls 5

EncodeBase58Function · 0.85
HashFunction · 0.70
beginMethod · 0.45
endMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected