Bitcoin Forum
May 06, 2024, 07:07:06 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Code Question?  (Read 1783 times)
wb3 (OP)
Member
**
Offline Offline

Activity: 112
Merit: 10


^Check Out^ Isle 3


View Profile
March 05, 2011, 09:13:07 AM
 #1

I haven't run through all the code yet, I figure I might save time if I ask an operation question here:

I have multiple machines running multiple instances of BitCoin, and generating:

Question:

Assuming just local LAN connections (no internet), if I send BTC to another instance: will the other instance receive it ?

Assuming one of the machines finds a block, will that transmission be encapsulated ?

And if this happens several times for multiple blocks, And when Internet comes back, will the blocks be added to the chain ?


I am assuming yes to all of these, because the app will think the LAN is the Internet. (the LAN spans multiple IPs).

Or basically is it truly a distributed P2P?


The reason I am asking is that I think I found something interesting in the .dat hexfile and am going to try a white hat attack.


Net Worth = 0.10    Hah, "Net" worth Smiley
"Governments are good at cutting off the heads of a centrally controlled networks like Napster, but pure P2P networks like Gnutella and Tor seem to be holding their own." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714979226
Hero Member
*
Offline Offline

Posts: 1714979226

View Profile Personal Message (Offline)

Ignore
1714979226
Reply with quote  #2

1714979226
Report to moderator
1714979226
Hero Member
*
Offline Offline

Posts: 1714979226

View Profile Personal Message (Offline)

Ignore
1714979226
Reply with quote  #2

1714979226
Report to moderator
tcatm
Sr. Member
****
qt
Offline Offline

Activity: 337
Merit: 265


View Profile
March 05, 2011, 11:01:30 AM
 #2

> Assuming just local LAN connections (no internet), if I send BTC to another instance: will the other instance receive it ?
yes (assuming they're connected to each other)

> Assuming one of the machines finds a block, will that transmission be encapsulated ?
yes, the transaction will be included in that block

> And if this happens several times for multiple blocks, And when Internet comes back, will the blocks be added to the chain ?
only if your chain is longer than the "other" chain. If it's shorter, the transactions will be ripped from your blocks and included in future blocks (as long as the transactions are still valid)
TiagoTiago
Hero Member
*****
Offline Offline

Activity: 616
Merit: 500


Firstbits.com/1fg4i :)


View Profile
March 05, 2011, 11:06:16 AM
 #3

If i'm not mistaken, only coins generated by solving blocks that were also solved in the rest of the Internet will go away.

(I dont always get new reply notifications, pls send a pm when you think it has happened)

Wanna gimme some BTC/BCH for any or no reason? 1FmvtS66LFh6ycrXDwKRQTexGJw4UWiqDX Smiley

The more you believe in Bitcoin, and the more you show you do to other people, the faster the real value will soar!

Do you like mmmBananas?!
wb3 (OP)
Member
**
Offline Offline

Activity: 112
Merit: 10


^Check Out^ Isle 3


View Profile
March 06, 2011, 11:37:03 PM
 #4

> Assuming just local LAN connections (no internet), if I send BTC to another instance: will the other instance receive it ?
yes (assuming they're connected to each other)

> Assuming one of the machines finds a block, will that transmission be encapsulated ?
yes, the transaction will be included in that block

> And if this happens several times for multiple blocks, And when Internet comes back, will the blocks be added to the chain ?
only if your chain is longer than the "other" chain. If it's shorter, the transactions will be ripped from your blocks and included in future blocks (as long as the transactions are still valid)

Very Helpful,

So if Lets call it Inet2 (of grid LAN,WAN), generates more Blocks than the Real BitCoin Blocks, then the Inet Blocks will be stripped and added to my chain.

Last question, Considering a fresh start of BitCoin on these machines in Inet2, What would the difficulty be in generating Blocks? Will it be as if it was a fresh start?

If so, the first proposal will be to do Inet2, and then Inet3, combine the blocks, and start Inet3 again, until blocks are larger than the real Inet. I should also be reaping the benefit of easier block creation.

Second,

It is then theoretically possible to create two BitCoin Inets running seperately until it is maxed out at 21 Million and then expose them to each other for a total of 42 Million BitCoins. Is this correct?



Net Worth = 0.10    Hah, "Net" worth Smiley
dirtyfilthy
Member
**
Offline Offline

Activity: 77
Merit: 10


View Profile
March 07, 2011, 12:11:29 AM
 #5


So if Lets call it Inet2 (of grid LAN,WAN), generates more Blocks than the Real BitCoin Blocks, then the Inet Blocks will be stripped and added to my chain.

Last question, Considering a fresh start of BitCoin on these machines in Inet2, What would the difficulty be in generating Blocks? Will it be as if it was a fresh start?

If so, the first proposal will be to do Inet2, and then Inet3, combine the blocks, and start Inet3 again, until blocks are larger than the real Inet.

Second,

It is then theoretically possible to create two BitCoin Inets running seperately until it is maxed out at 21 Million and then expose them to each other for a total of 42 Million BitCoins. Is this correct?


It's not a case of "more blocks"  but total difficulty. A block with a difficulty of 10 counts for five blocks of difficulty 2. So it's very unlikely you'll overtake the main chain starting from scratch.
wb3 (OP)
Member
**
Offline Offline

Activity: 112
Merit: 10


^Check Out^ Isle 3


View Profile
March 07, 2011, 12:38:56 AM
 #6


So if Lets call it Inet2 (of grid LAN,WAN), generates more Blocks than the Real BitCoin Blocks, then the Inet Blocks will be stripped and added to my chain.

Last question, Considering a fresh start of BitCoin on these machines in Inet2, What would the difficulty be in generating Blocks? Will it be as if it was a fresh start?

If so, the first proposal will be to do Inet2, and then Inet3, combine the blocks, and start Inet3 again, until blocks are larger than the real Inet.

Second,

It is then theoretically possible to create two BitCoin Inets running seperately until it is maxed out at 21 Million and then expose them to each other for a total of 42 Million BitCoins. Is this correct?


It's not a case of "more blocks"  but total difficulty. A block with a difficulty of 10 counts for five blocks of difficulty 2. So it's very unlikely you'll overtake the main chain starting from scratch.

OK,

That make more sense, I do like "unlikely" problems. 

The BitCoin's earned for those blocks will still be with in the clients though, when added to the Inet chain. Keeping the difficulty to where one earns 50BTC for a block and then confirmed. Or will they be stripped, and given to the other clients that generate new blocks?

If so, I really like "unlikely" problems. If not, then I should still reap rewards from lessor difficulty mining before adding to the main chain and start over by sending 0.01 BTC between clients and waiting for the Block.

The whole key to this was starting at least one client off grid with at least 0.01 BTC. The 0.01 BTC is a confirmed transaction from the real chain.

Net Worth = 0.10    Hah, "Net" worth Smiley
theymos
Administrator
Legendary
*
Offline Offline

Activity: 5194
Merit: 12972


View Profile
March 07, 2011, 02:56:54 AM
 #7

When the two networks combine, the generations in the smaller network become invalid. All transactions based on those generated coins also become invalid.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
we6jbo
Newbie
*
Offline Offline

Activity: 42
Merit: 0



View Profile
March 07, 2011, 04:04:06 AM
 #8

I might just be confusing the topic but what would happen if you had a LAN with more machines running bitcoin than all the machines running bitcoin on the Internet? In that case, would the LAN overtake the Internet?
theymos
Administrator
Legendary
*
Offline Offline

Activity: 5194
Merit: 12972


View Profile
March 07, 2011, 04:19:34 AM
 #9

I might just be confusing the topic but what would happen if you had a LAN with more machines running bitcoin than all the machines running bitcoin on the Internet? In that case, would the LAN overtake the Internet?

Only if the LAN has more CPU power.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
Garrett Burgwardt
Sr. Member
****
Offline Offline

Activity: 406
Merit: 256


View Profile
March 07, 2011, 05:05:41 AM
 #10

I might just be confusing the topic but what would happen if you had a LAN with more machines running bitcoin than all the machines running bitcoin on the Internet? In that case, would the LAN overtake the Internet?

Only if the LAN has more CPU power.



That's a big LAN
wb3 (OP)
Member
**
Offline Offline

Activity: 112
Merit: 10


^Check Out^ Isle 3


View Profile
March 07, 2011, 05:36:15 AM
 #11

When the two networks combine, the generations in the smaller network become invalid. All transactions based on those generated coins also become invalid.

So to take down the BitCoin network, generate a larger chain with a harder difficulty rating off the grid, and then when the blocks combine, all transactions based from the reward BTC (50,25,12.5, etc...) from the first network get voided, but the BTC Rewards from the off the grid BTC will continue. First Block on off grid matches Date, Time, etc of First Block on grid.

Ok, kind of hard from a LAN (even a significant one), but a Government (don't know). I think a couple of supper computers could do it relatively quickly. Currently China would be in the lead to take it down with 9.739 petaflops computer at hand.


I was hoping the first Block was an Anchor to which all others must be attached, with other anchors being added randomly.

Net Worth = 0.10    Hah, "Net" worth Smiley
bfever
Jr. Member
*
Offline Offline

Activity: 39
Merit: 1


View Profile WWW
March 07, 2011, 06:01:50 AM
 #12

The standard client has some built-in checks of the current block chain, so those will not accept another chain up to that point.

See the code in main.cpp:
Code:
    if (!fTestNet)
        if ((nHeight == 11111 && hash != uint256("0x0000000069e244f73d78e8fd29ba2fd2ed618bd6fa2ee92559f542fdb26e7c1d")) ||
            (nHeight == 33333 && hash != uint256("0x000000002dd5588a74784eaa7ab0507a18ad16a236e7b1ce69f00d7ddfb5d0a6")) ||
            (nHeight == 68555 && hash != uint256("0x00000000001e1b4903550a0b96e9a9405c8a95f387162e4944e8d9fbe501cd6a")) ||
            (nHeight == 70567 && hash != uint256("0x00000000006a49b14bcf27462068f1264c961f11fa2e0eddd2be0791e1d4124a")) ||
            (nHeight == 74000 && hash != uint256("0x0000000000573993a3c9e41ce34471c079dcf5f52a0e824a81e7f953b8661a20")))
            return error("AcceptBlock() : rejected by checkpoint lockin at %d", nHeight);

So everything up to block 74000 is locked. I presume other checks will be added with next versions of the client to prevent some "hostile takeover" of the main block chain.

theymos
Administrator
Legendary
*
Offline Offline

Activity: 5194
Merit: 12972


View Profile
March 07, 2011, 06:05:42 AM
 #13

0.3.20.2 includes another checkpoint at 105,000.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
marcus_of_augustus
Legendary
*
Offline Offline

Activity: 3920
Merit: 2348


Eadem mutata resurgo


View Profile
March 07, 2011, 08:29:40 AM
 #14

Quote
Currently China would be in the lead to take it down with 9.739 petaflops computer at hand.

Yes, but petaflops does not translate well into hashes ... flops are floating point ops, hashes are purely integer ops ... you'll have to go classified to get relevant numbers on hashing power that could threaten bitcoin network. A worthy exercise if you're of the sleuthing mindset.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!