tree checksum vpatch file split hunks

all signers: mod6

antecedents: bitcoin-asciilifeform.4-goodbye-win32 asciilifeform_zap_showmyip_crud genesis asciilifeform_dnsseed_snipsnip

press order:

genesismod6
bitcoin-asciilifeform.1mod6
rm_rf_upnpmod6
bitcoin-asciilifeform.3-turdmeister-alert-snipmod6
bitcoin-asciilifeform.2-https_snipsnipmod6
bitcoin-asciilifeform.4-goodbye-win32mod6
asciilifeform_dnsseed_snipsnipmod6
asciilifeform_zap_hardcoded_seedsmod6
asciilifeform_zap_showmyip_crudmod6
asciilifeform_dns_thermonyukyoolar_kleansingmod6

patch:

- D68207833444EA7D6F91BC579CB5543121F9F5BB90A72B713CCA1D90A453BCA3A4E660AFE66E836FD8AD1E3E21EE322ECD54114FC541FB30924EBBB0D6544A41
+ 2A962F65FD9A55BFD5DB5ED17A95D57EC009905436EB550BCDA1C6A024935F1C88B62D509A4C5AC3DDDA00970412BFBA71AAE29F389C191AF22C2F1DCF758C07
bitcoin/src/init.cpp
(160 . 7)(160 . 6)
5 " -datadir=<dir> \t\t " + _("Specify data directory\n") +
6 " -timeout=<n> \t " + _("Specify connection timeout (in milliseconds)\n") +
7 " -proxy=<ip:port> \t " + _("Connect through socks4 proxy\n") +
8 " -dns \t " + _("Allow DNS lookups for addnode and connect\n") +
9 " -port=<port> \t\t " + _("Listen for connections on <port> (default: 8333 or testnet: 18333)\n") +
10 " -maxconnections=<n>\t " + _("Maintain at most <n> connections to peers (default: 125)\n") +
11 " -addnode=<ip> \t " + _("Add a node to connect to\n") +
(414 . 10)(413 . 8)
13 // Note: the GetBoolArg() calls for all of these must happen later.
14 SoftSetArg("-nolisten", true);
15 SoftSetArg("-noirc", true);
16 SoftSetArg("-dns", false);
17 }
18
19 fAllowDNS = GetBoolArg("-dns");
20 fNoListen = GetBoolArg("-nolisten");
21
22 // Command-line args override in-wallet settings:
(435 . 7)(432 . 7)
24 {
25 BOOST_FOREACH(string strAddr, mapMultiArgs["-addnode"])
26 {
27 CAddress addr(strAddr, fAllowDNS);
28 CAddress addr(strAddr);
29 addr.nTime = 0; // so it won't relay unless successfully connected
30 if (addr.IsValid())
31 AddAddress(addr);
- 775141F07CE491A331E51FE97B43D4F2D1891EB720FC6706D06747959653E8171CB46DAA77EFD73E202B1E1419F26036C92CC106DE34D22245489B3F7B333BCB
+ A2D021C40268E8DFADD89CE84F19A0FAE780599823CFF27D0AFEEFD7E842F4E1828B18D2BCF97497BA510EFBDFB927041A4FD4DCCF9E83DCAD04C73439AD1565
bitcoin/src/irc.cpp
(269 . 10)(269 . 6)
36 {
37 CAddress addrConnect("92.243.23.21", 6667); // irc.lfnet.org
38
39 CAddress addrIRC("irc.lfnet.org", 6667, true);
40 if (addrIRC.IsValid())
41 addrConnect = addrIRC;
42
43 SOCKET hSocket;
44 if (!ConnectSocket(addrConnect, hSocket))
45 {
- A5977F1E2AD59EEEEFBCB59E32A935724653FD328E65570D9B7A6270F1CA1F27A00E2221C05DA122372D203B3CCC82DD04D3EADC745A6D7F7ADD3F5CF6ACA410
+ EAF9888F03CFC0267577D217D24B0FBA45D5D141E9D8536081059B97195590A0F7AA8D27704CABD46D1AF5033733B96D1BB01C47DCFBD636DB659DB101CC4A45
bitcoin/src/net.cpp
(29 . 9)(29 . 8)
50 // Global state variables
51 //
52 bool fClient = false;
53 bool fAllowDNS = false;
54 uint64 nLocalServices = (fClient ? 0 : NODE_NETWORK);
55 CAddress addrLocalHost("0.0.0.0", 0, false, nLocalServices);
56 CAddress addrLocalHost("0.0.0.0", 0, nLocalServices);
57 static CNode* pnodeLocalHost = NULL;
58 uint64 nLocalHostNonce = 0;
59 array<int, 10> vnThreadsRunning;
(193 . 7)(192 . 7)
61 }
62
63 // portDefault is in host order
64 bool Lookup(const char *pszName, vector<CAddress>& vaddr, int nServices, int nMaxSolutions, bool fAllowLookup, int portDefault, bool fAllowPort)
65 bool Lookup(const char *pszName, vector<CAddress>& vaddr, int nServices, int nMaxSolutions, int portDefault, bool fAllowPort)
66 {
67 vaddr.clear();
68 if (pszName[0] == 0)
(231 . 33)(230 . 14)
70 return true;
71 }
72
73 if (!fAllowLookup)
74 return false;
75
76 struct hostent* phostent = gethostbyname(pszHost);
77 if (!phostent)
78 return false;
79
80 if (phostent->h_addrtype != AF_INET)
81 return false;
82
83 char** ppAddr = phostent->h_addr_list;
84 while (*ppAddr != NULL && vaddr.size() != nMaxSolutions)
85 {
86 CAddress addr(((struct in_addr*)ppAddr[0])->s_addr, port, nServices);
87 if (addr.IsValid())
88 vaddr.push_back(addr);
89 ppAddr++;
90 }
91
92 return (vaddr.size() > 0);
93 return false;
94 }
95
96 // portDefault is in host order
97 bool Lookup(const char *pszName, CAddress& addr, int nServices, bool fAllowLookup, int portDefault, bool fAllowPort)
98 bool Lookup(const char *pszName, CAddress& addr, int nServices, int portDefault, bool fAllowPort)
99 {
100 vector<CAddress> vaddr;
101 bool fRet = Lookup(pszName, vaddr, nServices, 1, fAllowLookup, portDefault, fAllowPort);
102 bool fRet = Lookup(pszName, vaddr, nServices, 1, portDefault, fAllowPort);
103 if (fRet)
104 addr = vaddr[0];
105 return fRet;
(972 . 7)(952 . 7)
107 {
108 BOOST_FOREACH(string strAddr, mapMultiArgs["-connect"])
109 {
110 CAddress addr(strAddr, fAllowDNS);
111 CAddress addr(strAddr);
112 if (addr.IsValid())
113 OpenNetworkConnection(addr);
114 for (int i = 0; i < 10 && i < nLoop; i++)
(990 . 7)(970 . 7)
116 {
117 BOOST_FOREACH(string strAddr, mapMultiArgs["-addnode"])
118 {
119 CAddress addr(strAddr, fAllowDNS);
120 CAddress addr(strAddr);
121 if (addr.IsValid())
122 {
123 OpenNetworkConnection(addr);
(1275 . 7)(1255 . 7)
125 void StartNode(void* parg)
126 {
127 if (pnodeLocalHost == NULL)
128 pnodeLocalHost = new CNode(INVALID_SOCKET, CAddress("127.0.0.1", 0, false, nLocalServices));
129 pnodeLocalHost = new CNode(INVALID_SOCKET, CAddress("127.0.0.1", 0, nLocalServices));
130
131 // Get local host ip
132 struct ifaddrs* myaddrs;
- 0B8486F417CA786ACCC0335C0381A2FD80393E842F79A9926C556F81D6B09E41615DE890477DADAD86816F672A07B1DF2A495D0B95C85A3BF2FD8A8AA67B2863
+ FD5E99A998637D3A0F154C2124A264A76649D115FE5B38BEBEB4BF3ABC1943DE9031EBD2CA002F81F1D7ED53C8E72F072689E16264BE1E6944AE2CF0926EA226
bitcoin/src/net.h
(26 . 8)(26 . 8)
137 static const unsigned int PUBLISH_HOPS = 5;
138
139 bool ConnectSocket(const CAddress& addrConnect, SOCKET& hSocketRet, int nTimeout=nConnectTimeout);
140 bool Lookup(const char *pszName, std::vector<CAddress>& vaddr, int nServices, int nMaxSolutions, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
141 bool Lookup(const char *pszName, CAddress& addr, int nServices, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
142 bool Lookup(const char *pszName, std::vector<CAddress>& vaddr, int nServices, int nMaxSolutions, int portDefault = 0, bool fAllowPort = false);
143 bool Lookup(const char *pszName, CAddress& addr, int nServices, int portDefault = 0, bool fAllowPort = false);
144 bool GetMyExternalIP(unsigned int& ipRet);
145 bool AddAddress(CAddress addr, int64 nTimePenalty=0, CAddrDB *pAddrDB=NULL);
146 void AddressCurrentlyConnected(const CAddress& addr);
- E5274FE2FF8AA6840CE5BE2E7797766DC4A70A19C2E08954BBFD9CFFF4AD9E27614606079A4CE7FC5AE150DFAF2906BEE118B543D889710DA78475BD12F24C56
+ 071F23CB1E017F72A89271924861D1036E3FB2D9C6459709D8A962CD7AA94F84FAA657618D0DD553650A135A6E341ECF4389E2CB911C5E71D8C87D5D24BD77AF
bitcoin/src/protocol.cpp
(9 . 8)(9 . 8)
151
152
153 // Prototypes from net.h, but that header (currently) stinks, can't #include it without breaking things
154 bool Lookup(const char *pszName, std::vector<CAddress>& vaddr, int nServices, int nMaxSolutions, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
155 bool Lookup(const char *pszName, CAddress& addr, int nServices, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
156 bool Lookup(const char *pszName, std::vector<CAddress>& vaddr, int nServices, int nMaxSolutions, int portDefault = 0, bool fAllowPort = false);
157 bool Lookup(const char *pszName, CAddress& addr, int nServices, int portDefault = 0, bool fAllowPort = false);
158
159 static const unsigned char pchIPv4[12] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0xff };
160 static const char* ppszTypeName[] =
(96 . 28)(96 . 28)
162 nServices = nServicesIn;
163 }
164
165 CAddress::CAddress(const char* pszIn, int portIn, bool fNameLookup, uint64 nServicesIn)
166 CAddress::CAddress(const char* pszIn, int portIn, uint64 nServicesIn)
167 {
168 Init();
169 Lookup(pszIn, *this, nServicesIn, fNameLookup, portIn);
170 Lookup(pszIn, *this, nServicesIn, portIn);
171 }
172
173 CAddress::CAddress(const char* pszIn, bool fNameLookup, uint64 nServicesIn)
174 CAddress::CAddress(const char* pszIn, uint64 nServicesIn)
175 {
176 Init();
177 Lookup(pszIn, *this, nServicesIn, fNameLookup, 0, true);
178 Lookup(pszIn, *this, nServicesIn, 0, true);
179 }
180
181 CAddress::CAddress(std::string strIn, int portIn, bool fNameLookup, uint64 nServicesIn)
182 CAddress::CAddress(std::string strIn, int portIn, uint64 nServicesIn)
183 {
184 Init();
185 Lookup(strIn.c_str(), *this, nServicesIn, fNameLookup, portIn);
186 Lookup(strIn.c_str(), *this, nServicesIn, portIn);
187 }
188
189 CAddress::CAddress(std::string strIn, bool fNameLookup, uint64 nServicesIn)
190 CAddress::CAddress(std::string strIn, uint64 nServicesIn)
191 {
192 Init();
193 Lookup(strIn.c_str(), *this, nServicesIn, fNameLookup, 0, true);
194 Lookup(strIn.c_str(), *this, nServicesIn, 0, true);
195 }
196
197 void CAddress::Init()
- 9438A1F1A661180998E98347B42EB49363F6C4FEF82F8D970D4D1E0A367AA32055A505431BD86F100929BEA481DCAF6FDD6FC95BB4E1D083E7044AEE102D4479
+ EA4FDF494F219F2F3F9215D5DC384554B5DFF4F18001CF08EAA39322FAD2E5C1D1B74FD2486EA05D40627974DF43BAFA05D16858C1D98FBD287CB4104006662F
bitcoin/src/protocol.h
(67 . 10)(67 . 10)
202 CAddress();
203 CAddress(unsigned int ipIn, unsigned short portIn=0, uint64 nServicesIn=NODE_NETWORK);
204 explicit CAddress(const struct sockaddr_in& sockaddr, uint64 nServicesIn=NODE_NETWORK);
205 explicit CAddress(const char* pszIn, int portIn, bool fNameLookup = false, uint64 nServicesIn=NODE_NETWORK);
206 explicit CAddress(const char* pszIn, bool fNameLookup = false, uint64 nServicesIn=NODE_NETWORK);
207 explicit CAddress(std::string strIn, int portIn, bool fNameLookup = false, uint64 nServicesIn=NODE_NETWORK);
208 explicit CAddress(std::string strIn, bool fNameLookup = false, uint64 nServicesIn=NODE_NETWORK);
209 explicit CAddress(const char* pszIn, int portIn, uint64 nServicesIn=NODE_NETWORK);
210 explicit CAddress(const char* pszIn, uint64 nServicesIn=NODE_NETWORK);
211 explicit CAddress(std::string strIn, int portIn, uint64 nServicesIn=NODE_NETWORK);
212 explicit CAddress(std::string strIn, uint64 nServicesIn=NODE_NETWORK);
213
214 void Init();
215