- C9414DD278719A028B904826086E3D241AC1402BBCBAF265C6E03B2DFE0451833A8E6CC11CDCC90E67E64C41056C9A2725CEC1F0A6E251A0EF76835BA3D173B4
+ 935818D95D5E80E25A0992801B4A01D8F18998A63A6949B46832C2D1AE0A6DBBB4AC7CCA5AD4E857D1B7A1AF3B537C7FCD6A60727C1B211FCFD0723E00D96314
bitcoin/src/base58.h
(252 . 14)(252 . 14)
5 };
6
7 // base58-encoded bitcoin addresses
8 // Addresses have version 0 or 111 (testnet)
9 // Addresses have version 0
10 // The data vector contains RIPEMD160(SHA256(pubkey)), where pubkey is the serialized public key
11 class CBitcoinAddress : public CBase58Data
12 {
13 public:
14 bool SetHash160(const uint160& hash160)
15 {
16 SetData(fTestNet ? 111 : 0, &hash160, 20);
17 SetData(0, &hash160, 20);
18 return true;
19 }
20
(271 . 20)(271 . 15)
22 bool IsValid() const
23 {
24 int nExpectedSize = 20;
25 bool fExpectTestNet = false;
26 switch(nVersion)
27 {
28 case 0:
29 break;
30
31 case 111:
32 fExpectTestNet = true;
33 break;
34
35 default:
36 return false;
37 }
38 return fExpectTestNet == fTestNet && vchData.size() == nExpectedSize;
39 return vchData.size() == nExpectedSize;
40 }
41
42 CBitcoinAddress()