Disclaimer: These reviews are done as is from what is on display in the master branch of the repo’s made available. This review is not a comment on the overall project, scope, or success thereof. This was done as an educational review by me and any comments in the article are simply my opinion. It should not be used as any comment or advice on the project as a whole.
Review Date: 24/02/2018
EDIT 26/03/2018 User @ckscrypto was kind enough to ask Wanchain for feedback on the below, they commented that Wanchain 2.0/3.0 code is not publicly available and won’t be made public until such time as Wanchain is comfortable. So the below is only a portrayal of the code provided publicly, and not the current active development
** Original article follows
Probably the most anticipated ICO of end 2017. Everything is waiting in anticipation for this beast to come online and in full swing. Boasting a team of 15 core developers, I honestly can’t contain my excitement at what I’m about to learn as I dissect their code.
So let’s jump right in. https://github.com/wanchain/go-wanchain
We start with an absolutely massive repository. Although don’t be scared, Wanchain afterall is a fork of go-ethereum, so this is to be expected. The thing I’m most excited to see is how they implemented PoS in Ethereum, so let’s run right over to the consensus package and get our hands dirty.
Oh, well, ok, so no PoS yet. But wait, Wanchain mainnet is already live? What is it running if it isn’t running PoS? Let’s get digging. So given the sheer size of the repo thanks to Ethereum, it would take us a very long time searching through each and every line of code, so instead we head over to the commits, let’s see what changes have the team made since inception.
776 commits since the inception of the initial commit on 14 May 2017. That’s 10 months worth of work. What wonderful things won’t we be able to learn from here.
Initial commit, just go-ethereum, let’s move on.
Commit #2 already looks excited, we see we add a new transaction type variable to all transactions
The new OTA transactions are added, OTA is the One Time Account mechanism of Wanchain, this is the mechanism that allows for private transactions.
Rest of the commit is mostly just methods being duplicated and some name changes to accommodate for the OTA transactions, for example duplicating SendTransaction and changing it to SendOTATransaction, I will be omitting these kinds of changes since it’s just grunt work and not really adding anything new to the system. But so far an ambitious start, we already start seeing the bare bones of the private transaction system.
Rest of may is just more boiler plate changes, some docker updates, nothing interesting. Nothing in June, and July starts the same. Mostly setup changes to compile and accommodate for new Wanchain directories instead of ethereum directories.
Around mid July we see some exciting changes to crypto.go, let’s have a look;
Sadly, nothing interesting, just some bug fixes for the previous OTA implementation. Rest of July, new build files, some name changes from ETH to WAN in documentation files and startup scripts.
In August we undo some of our original commit changes, every developer has seen this before, you go through code and wonder “why the hell did someone do this, there is a much better way” only to a few days later be back exactly there with the realization “Ooooh, that’s why they did it this way, let me revert”
Finally, middle August we see genesis starting to happen. This is the process of actually beginning a mainnet, the genesis file in Ethereum is where everything starts
No genesis yet, but let’s continue.
New updates, interesting though, this shows that they are looking at PoA, Proof of Authority. It’s a mechanism designed for Ethereum’s Rinkeby testnet. It is essentially a private mining network for a public ledger. It’s meant for centralization and control. Interesting start.
Rest of August just test updates, nothing interesting. 10 September we see a massive codebase change, let’s have a look
Oh, we are just renaming all instances of Ethereum to Wanchain. Ok, that’s cool I guess, let’s move on.
11 September we see Pluto being added! Is this the start of PoS?
No, Pluto is just a copy of Rinkeby and Clique, we are just busy renaming Rinkeby and Clique to Pluto. So at this point looks like Wanchain is going to go with Pluto, which is just PoA.
Rest of September just more Pluto updates, some OTA fixes, adding OTA stamps. Nothing really exciting at this point.
September and October see a lot of OTA updates, it’s a pretty smart mechanism actually, so your private key is used to generate a OTA account private/public key, you then send the funds to this which sort of deposits it back in the original smart contract. From the receiving account you can then generate a refund from the smart contract which will use a new OTA account for you to grab your funds from. It’s a smart way to implement privacy, but kind of boring, so I’m not going to go into it’s details all that much.
November, December, and January just sees a lot of test case updates and prep for mainnet launch.
Conclusion: And that’s all we have folks. So sorry, nothing exciting here. Essentially we just have go-ethereum where everything was renamed to Wanchain and Wancoin respectively, running in PoA (renamed to Pluto) with OTA transactions.
Wish I had more to show you guys. For 10 months of work. I don’t know how I feel about that. Hopefully we will see something exciting on the next review!