Merged mining + timetravel fix @19200 - must upgrade

hashman
Posts: 4
Joined: Thu Sep 08, 2011 2:19 pm

Re: Merged mining block number - 19200 - must upgrade

Post by hashman »

jtimon wrote:
hashman wrote: Well I like the algebra but I think there is a problem here because the block formally contains the nonce. You can see them in the block explorers. Last NMC block (18903) had inside it

Nonce: 2250928270

The nonce alone is never hashed, the hash is done of the whole block which contains the nonce. So indeed you ARE repeatedly hashing the block.
When you hash a message, you hash it in blocks.
Hash(Hash(Hash(Block1), Block2), Block3)
If the nounce is the last data block you hash, you don't have to re-hash the whole bitcoin/namecoin block for every nounce you try.
Sorry, but actually you do. The block is a chunk of data including the nonce. The hash of the block is just that: SHA(block). If you change even one bit of the block (e.g. by incrementing the nonce by 1), the hash of the block will change completely. That's the whole point of hash functions. Go back to the Satoshi paper if this is confusing. At no point is there any reason to "hash the nonce". It is the hash of the whole block (including the nonce) which must be below the difficulty limit.

Your gold & silver analogy is less than pleasing. For gold & silver miners there is no hard limit on the amount of gold and silver pulled from the earth every 10 minutes. For BTC / NMC there is a hard limit: 50 BTC / 10 min & 100 NMC / 10 min.

I can already mine for both by using a pool that picks between which one to mine in the getWork function or by running an instance of each.

Let me reiterate: even if the new code is perfect and LukeJr. was bluffing about his exploit, the difficulty will just go up and you will be mining at the same profitability as before.

Merged mining gets the gas face. :P

jtimon
Posts: 27
Joined: Fri Jul 22, 2011 5:36 pm
os: linux

Re: Merged mining block number - 19200 - must upgrade

Post by jtimon »

hashman wrote: Sorry, but actually you do. The block is a chunk of data including the nonce. The hash of the block is just that: SHA(block). If you change even one bit of the block (e.g. by incrementing the nonce by 1), the hash of the block will change completely. That's the whole point of hash functions. Go back to the Satoshi paper if this is confusing. At no point is there any reason to "hash the nonce". It is the hash of the whole block (including the nonce) which must be below the difficulty limit.
I'll try it again. When you hash a message, you don't hash it in a single operation. You divide it in blocks, hashman, and then you hash it step by step.
Let's say your block is composed of 4 blocks
M = {m0, m1, m2, m3}
H(M) = H(H(H(m0, m1), m2), m3) = H(B, m3)

If the last part m3 is the nounce, you don't have to calculate B=H(H(m0, m1), m2) again and again because you already know it. You can try different m3 just calculating H(B, m3) for each try.
hashman wrote: I can already mine for both by using a pool that picks between which one to mine in the getWork function or by running an instance of each.
But you're mining with different hash power for each network !!! At different times or with different cores.
You're wasting twice the time and electricity.
hashman wrote: Let me reiterate: even if the new code is perfect and LukeJr. was bluffing about his exploit, the difficulty will just go up and you will be mining at the same profitability as before.
I'm not mining. And the purpose of merged mining is not making miners richer but making namecoin more secure.
If you keep mining only in bitcoin, a merged miner will have more profits than you.
It will make unprofitable to mine only one of them if you prefer.
Whatever how you want to see it: is going to be stupid not to mine both networks at the same time.

Seraphim401
Posts: 10
Joined: Wed Sep 07, 2011 4:39 pm
os: windows

Re: Merged mining block number - 19200 - must upgrade

Post by Seraphim401 »

Could someone please update Dot-Bit with the latest windows client?


Thanks.

nodemaster
Posts: 172
Joined: Wed Jun 15, 2011 12:46 pm
os: linux

Re: Merged mining block number - 19200 - must upgrade

Post by nodemaster »

Seraphim401 wrote:Could someone please update Dot-Bit with the latest windows client?
If you are searching for the windows client. twobit has compiled and uploaded it here:

http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/

But I agree it should make its way to the main page. khal? :mrgreen:
Access .bit domains with Firefox in 4 easy steps: https://masterpool.eu/proxy
MasterPool Namecoin Mining Pool

Seraphim401
Posts: 10
Joined: Wed Sep 07, 2011 4:39 pm
os: windows

Re: Merged mining block number - 19200 - must upgrade

Post by Seraphim401 »

nodemaster wrote:
Seraphim401 wrote:Could someone please update Dot-Bit with the latest windows client?
If you are searching for the windows client. twobit has compiled and uploaded it here:

http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/

But I agree it should make its way to the main page. khal? :mrgreen:
Thanks man,but isn't the latest version 0.3.24.61?Think there was some issue with 0.3.24.60:http://dot-bit.org/forum/viewtopic.php?f=2&t=286
Or am I missing something?


Thanks again for your help.

khal
Site Admin
Posts: 708
Joined: Mon May 09, 2011 5:09 pm
os: linux

Re: Merged mining block number - 19200 - must upgrade

Post by khal »

nodemaster wrote:
Seraphim401 wrote:Could someone please update Dot-Bit with the latest windows client?
If you are searching for the windows client. twobit has compiled and uploaded it here:

http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/

But I agree it should make its way to the main page. khal? :mrgreen:
I'm a bit reluctant to post a binary file from a person with only 1 post on this forum.
Is he an active member of the bitcoin forum too ?


ps : linux version updated to v0.3.24.61.
NamecoinID: id/khal
GPG : 9CC5B92E965D69A9
NMC: N1KHAL5C1CRzy58NdJwp1tbLze3XrkFxx9
BTC: 1KHAL8bUjnkMRMg9yd2dNrYnJgZGH8Nj6T

Register Namecoin domains with BTC
My bitcoin Identity - Send messages to bitcoin users
Charity Ad - Make a good deed without paying a cent

twobits
Posts: 26
Joined: Fri Sep 02, 2011 10:10 pm
os: bsd

Re: Merged mining block number - 19200 - must upgrade

Post by twobits »

Seraphim401 wrote:
nodemaster wrote:
Seraphim401 wrote:Could someone please update Dot-Bit with the latest windows client?
If you are searching for the windows client. twobit has compiled and uploaded it here:

http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/

But I agree it should make its way to the main page. khal? :mrgreen:
Thanks man,but isn't the latest version 0.3.24.61?Think there was some issue with 0.3.24.60:http://dot-bit.org/forum/viewtopic.php?f=2&t=286
Or am I missing something?


Thanks again for your help.
That issue is very minor. It would have started to fade away once enough people used the updated client. However the patch would make the issue worse for those who remain using .60. I find it a bit frustrating that my two questions on here have been ignored so far. Ah well.

In any case http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/

Seraphim401
Posts: 10
Joined: Wed Sep 07, 2011 4:39 pm
os: windows

Re: Merged mining block number - 19200 - must upgrade

Post by Seraphim401 »

That issue is very minor. It would have started to fade away once enough people used the updated client. However the patch would make the issue worse for those who remain using .60. I find it a bit frustrating that my two questions on here have been ignored so far. Ah well.In any case http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/
Thanks for the update man :)

moa
Posts: 255
Joined: Mon May 23, 2011 6:13 am

Re: Merged mining block number - 19200 - must upgrade

Post by moa »

twobits wrote:
That issue is very minor. It would have started to fade away once enough people used the updated client. However the patch would make the issue worse for those who remain using .60. I find it a bit frustrating that my two questions on here have been ignored so far. Ah well.

In any case http://www.wuala.com/jbw9/pub/Bitcoin/n ... /win32.7z/
Take heart, the really searching questions get ignored.

twobits
Posts: 26
Joined: Fri Sep 02, 2011 10:10 pm
os: bsd

Re: Merged mining block number - 19200 - must upgrade

Post by twobits »

twobits wrote:
However I get an error trying to compile on osx....
g++ -c -mmacosx-version-min=10.5 -arch i386 -Os -Wno-invalid-offsetof -Wformat -
g -DwxDEBUG_LEVEL=0 -I/usr/local/lib/wx/include/osx_cocoa-unicode-static-2.9 -I/
usr/local/include/wx-2.9 -D_FILE_OFFSET_BITS=64 -DwxDEBUG_LEVEL=0 -D__WXMAC__ -D
__WXOSX__ -D__WXOSX_COCOA__ -D__WXMAC_OSX__ -DNOPCH -DMSG_NOSIGNAL=0 -DUSE_SSL
-I"/usr/local/include" -I/usr/local/BerkeleyDB.4.7/include -o obj/nogui/namecoin
.o namecoin.cpp
/usr/include/c++/4.2.1/bits/stl_pair.h: In instantiation of ΓÇÿstd::pair<uint256
, const CTxIndex&>ΓÇÖ:
namecoin.cpp:1456: instantiated from here
/usr/include/c++/4.2.1/bits/stl_pair.h:84: error: forming reference to reference
type ΓÇÿconst CTxIndex&ΓÇÖ

The above was fixed with a suggestion from vinced to replace

BOOST_FOREACH(const PAIRTYPE(uint256, const CTxIndex&)& s, mapTestPool)

with:

BOOST_FOREACH(const PAIRTYPE(uint256, CTxIndex)& s, mapTestPool)


I have built binaries for nc0.3.24.62 now, and this time am able to include mac osx.

http://www.wuala.com/jbw9/pub/Bitcoin/n ... 0.3.24.62/

Post Reply