Commit Graph

6 Commits

Author SHA1 Message Date
Tadge Dryja
4535b965cd implement hard mode
seems to work OK.  Could be sped up by local filters instead of
ingesting every tx from the block but I can do that later if
performance (mostly disk i/o) is an issue

once multiple connections are implemented, hard mode should forward
txs to blend in.
2016-02-06 22:48:54 -08:00
Tadge Dryja
8518be13f7 add hard mode test methods
really simple to check block merkle root
next can modify "ingestMerkleBlock" to ingest either type of block.
2016-02-06 19:15:35 -08:00
Tadge Dryja
63b5926e01 add getalltxs, dup checks
Start of double spend detection for mempool and reorgs
2016-02-05 01:59:40 -08:00
Tadge Dryja
25d90f5345 reorganize lots of files, add rebroadcast
move methods to new files to keep things a bit organized.
add rebroadcast of unconfirmed txs after sync
mutex on OKtxid map
deal with doublespends next
2016-02-05 01:16:45 -08:00
Tadge Dryja
9eccb0638a I think this fixes all sync problems
add a bool to the HashAndHeight struct;
can indicate "final".  When the block market final comes in,
we don't enter wait state, but instead ask for headers.
when you don't get any headers, you wont need any blocks, and that
will assert the wait state.
2016-02-03 20:26:12 -08:00
Tadge Dryja
624e776987 add shell spv testing mode
To try uspv, do ./lnd -spv
The remote node is hardcoded in shell.go.  If you aren't
running a full node on localhost, specify where to connect to.
Nearby nodes will be much faster but random testnet nodes on the
internet should also work.
2016-02-02 23:37:29 -08:00