>full node
>no blocks
pick one
Why?
Is it not possible to join the P2P network without having all blocks? Just to be able to listen to blocks and inject transactions without needing a separate server.
I'm just trying to understand this without having to code a test program.
Can you do it? Sure. Can you do it securely? Probably not. The ugly part is it likely will work for some time until a dedicated attacker tries to exploit your paper thin security and then when it fails it (and given enough time it will), it will fail hard and cost either you or someone who relied on your a massive amount of funds.
Don't get me wrong. I'm interested in designing a secure solution, and that's why I'm bringing it up for discussion. I want to learn.
Without at least the blockheaders your node has no way of knowing what other nodes are telling you is truthful.
How do the blockheaders help?
How long do you think it would take a single GPU computer to generate 6 (or 60) blocks of fake history at difficulty 1? If all your node does is ask for 6 most recent blocks ... ok here are 6 blocks I made for you and see your massive payment of 500 BTC is there, so please send me the gold/wire transfer/computer hardware I asked for. Only later do you find out that you were fed a false history. Yes I have 500 BTC but in the "real" blockchain I sent them to myself not you. A double spent that you could not only not prevent, you couldn't even see that it had occurred.
Thanks for the input, I get your point.
However, surely I could verify that a block was generated with a valid difficulty? If I have the latest generated block, and am given a subsequent block referencing the previous block, there must be a formula for verifying that the new block was calculated with a valid difficulty?
For an attacker to generate say six 'fake' blocks with a valid difficulty and the first one referring to the previous truly valid block must be reasonably difficult (similar to actually 'mining' those blocks)?
But wait you say I connect to 8 independent nodes? Do you? If there is enough incentive to steal don't you think a botnet for example could produce tens of thousands of "independent" nodes and poison the pool of potential nodes around you. Now currently there is very limited value in an attacker doing that as each full node (in in the case of electrum the electrum server is doing the full node validation) implicitly does NOT TRUST anything any nodes tells it and validates every block, every transactions, every output back to the genesis block if necessary. So a "poisened node" strategy has very little utility.
But against a "naive node" well that is a different story. Let the false history games begin.
Thanks for the input.