Commit Graph

153 Commits

Author SHA1 Message Date
Christopher Jeffrey
c81770c2b1 move some deps around. drop inherits. 2016-02-21 06:31:15 -08:00
Christopher Jeffrey
28274cdba4 rename methods. 2016-02-19 21:42:44 -08:00
Christopher Jeffrey
050d801849 standardness. chain. pool. 2016-02-18 15:26:03 -08:00
Christopher Jeffrey
d22dc02e8f wait for flush. 2016-02-17 19:40:56 -08:00
Christopher Jeffrey
5d9f106e2a event based system for chain error handling. 2016-02-17 15:30:33 -08:00
Christopher Jeffrey
9b1effdc66 pool improvements. 2016-02-17 05:08:19 -08:00
Christopher Jeffrey
f17575f864 queue 2016-02-17 02:53:43 -08:00
Christopher Jeffrey
d0d0378f3e queue. fixes. 2016-02-16 21:01:31 -08:00
Christopher Jeffrey
997f0acbb0 more refactoring. 2016-02-16 16:13:34 -08:00
Christopher Jeffrey
6cab97b265 listen on server socket for leech peers. 2016-02-08 18:46:09 -08:00
Christopher Jeffrey
2ec7989b6a no more dynamic heights. 2016-02-06 21:51:38 -08:00
Christopher Jeffrey
e0ab0ab88d minor changes/fixes. 2016-02-03 02:09:03 -08:00
Christopher Jeffrey
999cfefe54 more pool work. wallet.fill(). 2016-02-01 10:54:52 -08:00
Christopher Jeffrey
b0ee614432 misc sync fixes. 2016-01-31 00:50:13 -08:00
Christopher Jeffrey
8447790a84 remove peer backoff system. 2016-01-30 02:21:00 -08:00
Christopher Jeffrey
60c3db7cb9 better request handling. 2016-01-29 18:58:41 -08:00
Christopher Jeffrey
e8cb2102a3 work 2016-01-29 17:38:31 -08:00
Christopher Jeffrey
32c0f8ce3c do not request duplicate txs. 2016-01-29 14:44:43 -08:00
Christopher Jeffrey
07ddae9d33 misc fixes and improvements. 2016-01-27 19:43:24 -08:00
Christopher Jeffrey
f6dc42924b global debugging. script.isEncoded. 2016-01-20 12:25:19 -08:00
Christopher Jeffrey
47af5987ae better system to prevent DOSing. 2016-01-20 02:46:25 -08:00
Christopher Jeffrey
486c22d0e7 get rid of getStartHeight. 2016-01-19 20:36:48 -08:00
Christopher Jeffrey
27fd056316 minor. 2016-01-19 20:35:26 -08:00
Christopher Jeffrey
c11a651e9d better loader management. 2016-01-19 20:32:59 -08:00
Christopher Jeffrey
46b2983eb3 update preload. 2016-01-17 17:15:13 -08:00
Christopher Jeffrey
b1d46206a8 script fixes. 2016-01-15 19:28:17 -08:00
Christopher Jeffrey
4f8d24ba36 more int and packet work. 2016-01-13 18:31:07 -08:00
Christopher Jeffrey
10bd983899 version and addr packets. 2016-01-13 03:38:23 -08:00
Christopher Jeffrey
de455fa3e9 improve int functions and usage in parser and framer. 2016-01-12 18:13:32 -08:00
Christopher Jeffrey
df420a4a8b refactor. work. 2016-01-08 02:22:35 -08:00
Christopher Jeffrey
680bf01e98 add tx.isFinal. refactor chain usage. 2016-01-05 21:32:31 -08:00
Christopher Jeffrey
d0d5ab2c3b add mempool packet. miner refactor. 2016-01-05 12:46:30 -08:00
Christopher Jeffrey
2f618c961b fixes. peer improvements. 2016-01-05 02:28:06 -08:00
Christopher Jeffrey
019ecf4f2a switch to fullchain for both spv and fullnode. 2016-01-04 20:13:06 -08:00
Christopher Jeffrey
0f8819c78e minor fixes. refactor timestamps. 2016-01-04 04:12:26 -08:00
Christopher Jeffrey
a20cd7edbe refactor pool. improve chains. 2016-01-04 03:04:09 -08:00
Christopher Jeffrey
484b1f2817 use getheaders. 2016-01-03 06:47:27 -08:00
Christopher Jeffrey
350ca9c875 move all block sync logic to pool. 2015-12-29 18:40:31 -08:00
Christopher Jeffrey
a6e3024e9b peer address and port. 2015-12-22 03:19:27 -08:00
Christopher Jeffrey
52b653083c add features potentially useful for blockchain explorers. 2015-12-21 20:00:13 -08:00
Christopher Jeffrey
1db84a0528 wallet json and prefix. style. cleanup. 2015-12-20 01:43:09 -08:00
Christopher Jeffrey
cb2bcc21c6 prevent buffered _writes from binding thousands of events. 2015-12-19 02:52:51 -08:00
Christopher Jeffrey
a96f27682f style. fix addr timestamp. 2015-12-19 02:17:01 -08:00
Christopher Jeffrey
1e802c152f comments. more style consistency. 2015-12-18 22:53:31 -08:00
Christopher Jeffrey
5ece45091b style consistency. 2015-12-18 22:37:02 -08:00
Christopher Jeffrey
d1f8e9b5ff add chain.hasOrphan method. 2015-12-18 16:58:26 -08:00
Christopher Jeffrey
82983af52b pool wallets. chain errors. checkpoint failure. 2015-12-18 12:10:39 -08:00
Christopher Jeffrey
07a6788831 optimize block and tx rendering. script maxes. sync. 2015-12-17 16:06:08 -08:00
Christopher Jeffrey
88ddb3620c get blockchain sync working. fix pushdata ops. 2015-12-17 16:05:48 -08:00
Christopher Jeffrey
89f2a0dcc3 formatting. make use of helpers in hd. 2015-12-09 10:40:33 -08:00
Christopher Jeffrey
db0da78ae5 only start calculating startHeight and locatorHashes after chain load. 2015-12-05 18:34:18 -08:00
Christopher Jeffrey
c96a12bf2e fix validateAddress. cleanup. 2015-12-05 04:59:18 -08:00
Christopher Jeffrey
87eea1e398 fixes and minor style changes 2015-12-04 22:50:13 -08:00
Christopher Jeffrey
ea9af49f4b hd and p2sh 2015-12-04 18:01:31 -08:00
Christopher Jeffrey
3bfd10d0d0 work 2015-12-01 22:59:26 -08:00
Christopher Jeffrey
fcc9d661c1 satoshi: fix blockchain download. 2015-11-30 18:15:57 -08:00
Christopher Jeffrey
feda74523f peer/pool: add origin satoshi protocol. 2015-11-30 12:36:39 -08:00
Christopher Jeffrey
eadb7a50c7 pool: add version and peer events for peers. 2014-06-06 16:20:50 -05:00
Fedor Indutny
013a85c6a5 Merge pull request #16 from chjj/version-packet
Version packet
2014-05-26 22:12:36 +04:00
Christopher Jeffrey
7e38e4de7c pool: change pool.options.satoshi to pool.options.relay. 2014-05-26 12:43:41 -05:00
Christopher Jeffrey
a3b923ae76 peer: have updateWatch getblocks instead of filterload for the satoshi option. 2014-05-26 05:12:56 -05:00
Christopher Jeffrey
024350dbe4 peer/pool: improve handleInv. improve addPeer. 2014-05-26 04:03:23 -05:00
Christopher Jeffrey
9dc0063ea9 test/parser: add version test for height and relay / fix typo. 2014-05-24 02:16:59 -05:00
Christopher Jeffrey
a5f20114e8 framer: version packet options, relay and height. 2014-05-24 02:16:59 -05:00
Christopher Jeffrey
7de6964628 allow usage of the original non-spv pre BIP-37 satoshi protocol. 2014-05-23 10:56:02 -05:00
Christopher Jeffrey
793fed1974 framer: refactor.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:20 +04:00
Christopher Jeffrey
44fab2b58a peer: handle address timestamp better.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:20 +04:00
Christopher Jeffrey
a0c2f66169 peer: fix handleGetAddr. fix addr test.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:20 +04:00
Christopher Jeffrey
9bec16ca49 peer: minor style fix.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:19 +04:00
Christopher Jeffrey
29746b5164 utils: add simple utils.isIP in place of net.isIP.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:18 +04:00
Christopher Jeffrey
2edfdd8b36 peer: style fixes.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:18 +04:00
Christopher Jeffrey
6e8b03df96 peer: keep ips as arrays.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:18 +04:00
Christopher Jeffrey
aa383b984e peer: take into account omitted zeros for ipv6 addresses.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:18 +04:00
Christopher Jeffrey
e9ec9a5f0c peer: fix potential error.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:18 +04:00
Christopher Jeffrey
b2c4af302d peer: remove _getOwnIP.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:17 +04:00
Christopher Jeffrey
d0b14008d0 peer: implement response to getaddr.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-20 13:36:17 +04:00
Christopher Jeffrey
e04931026c block: add block subtype - block or merkleblock.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-18 21:00:56 +04:00
Christopher Jeffrey
4894f6965f peer: txs event - only emit hashes to mimic blocks event.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-18 18:09:41 +04:00
Christopher Jeffrey
01409b34af pool: emit blocks and txs event on pool.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-18 18:09:40 +04:00
Christopher Jeffrey
d331cfbb9e fix: take into account var_int for addr. move to parser.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-17 21:03:51 +04:00
lms
67298c60e0 peer: socket -> createSocket parameter
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-16 01:28:59 +04:00
Christopher Jeffrey
24779fb398 peer/pool: emit addr event on pool. refactor addr handler.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-16 01:28:17 +04:00
Christopher Jeffrey
b2ee0891a1 peer: remove useless map call.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-16 01:28:17 +04:00
Christopher Jeffrey
e76bed360f peer: handle addr packet.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
2014-05-15 00:55:45 +04:00
Fedor Indutny
f7300fb979 peer: backoff randomly to not spin on reconnect 2014-05-13 15:13:52 +04:00
Fedor Indutny
dfdc69aa3a lib: remove heavy modules 2014-05-11 14:27:05 +04:00
Fedor Indutny
6d99072caf pool: fix finalization 2014-05-11 11:42:48 +04:00
Fedor Indutny
ee9037e19a lib: jshint 2014-05-10 22:43:15 +04:00
Fedor Indutny
048bca0b8a wallet: store timestamp of transactions 2014-05-08 20:25:12 +04:00
Fedor Indutny
4a2c54827b chain: better preload generation algorithm 2014-05-07 04:13:30 +04:00
Fedor Indutny
2a4553f6c5 preload: script to update 2014-05-06 22:08:38 +04:00
Fedor Indutny
762b53a011 pool: lower timeouts 2014-05-06 17:15:23 +04:00
Fedor Indutny
403beca64b peer: proper reporting of reject 2014-05-06 13:42:17 +04:00
Fedor Indutny
f787590efe script: do not change inputs 2014-05-06 13:30:32 +04:00
Fedor Indutny
7f0ea92a43 peer: improvements 2014-05-06 00:55:24 +04:00
Fedor Indutny
62d9af1194 parser: parse reject 2014-05-05 16:52:17 +04:00
Fedor Indutny
4328d7c3ec wip 2014-05-05 13:46:29 +04:00
Fedor Indutny
1ac3208360 pool: refactor, make search work! 2014-05-03 16:11:06 +04:00
Fedor Indutny
9e0808eb39 pool: wip 2014-05-02 13:40:59 +04:00
Fedor Indutny
c71258103b pool: wip 2014-05-02 00:08:07 +04:00