Post
Topic
Board Altcoin Discussion
Re: Where is hashing algorithm code?
by
hatshepsut93
on 30/06/2018, 13:32:20 UTC
So bitcoin uses sha256, litecoin scrypt, dash x11.

Where is revision location(source code filename, approx line position)  of this algorithm?

Is it widespread and hard to revise? or easy to change?

How change to x11 algorithm? Some site says x11 is best algorithm.



I'm not a C++ developer, but I think the SHA256 implementation used by Bitcoin Core client is here: https://github.com/bitcoin/bitcoin/blob/master/src/crypto/sha256.cpp

I would strongly advice against modifying anything in this or any other hashing algorithm, they were carefully tuned to be as secure as possible, and changing just a few constants can drastically reduce their security.

If you want to create a fork of Bitcoin with different algorithm, you'll have to do a lot of work. You will very likely fail if you are not an experienced programmer.