Parity Wallet security alert
paritytech.io
paritytech.io
They decided it'd be nice if people could have a lower transaction fee when they deployed a new wallet. So they made one master contract that has all the code. Now when you deploy a new wallet, what you actually deploy is a stub that forwards function calls to the master contract, using a "delegatecall" which lets the master execute its functions in the context of the stub contract.
However, they didn't think through how they might want to change the master contract code in this new situation. In particular, they didn't remove the selfdestruct function. Self destruct is perfectly sensible when it's your own contract that you're not using anymore, but it's not so great when it's shared code used by lots of people.
They also forgot to initialize a function setting contract ownership. Someone came along and made themselves the owner, then called the selfdestruct. They posted about it on github, apparently unaware of the full impact of what they'd just done, which was to destroy the code used by all the stub contracts deployed since July 20. Now those stubs no longer have access to functions for withdrawing the ETH they contain.
This master/stub design was also the root cause of Parity's previous multisig hack. Apparently they didn't get a clue and pay for a fresh round of external audits, which I think would have easily caught this problem. In fact, at the end of a post-mortem of the previous hack, published on July 20, they complained that they lacked funds for such things:
https://paritytech.io/blog/the-multi-sig-hack-a-postmortem.h...
In an enterprise or company, when it is growing from startup to market gorilla, there are often tales of screw ups like this that happened to some poor sysadmin or programmer. And the company develops a sort of genetic memory of what not to do. Like children, companies that learn the 'dangerous' things early before they can do real harm, grow up to be less likely to do something really stupid later in their existence.
But I don't know what vector could be used to pass this sort of cultural knowledge between ethereum contract writers from generation to generation. It needs a 'book of sins' that everyone can read and contribute to in order to insure that new contracts won't suffer the problems of the early ones.
I vividly remember doing it a second time some months later. But never again.
In my defense I was an idiot and was 8 or 9 years old, so fortunately it was just some shareware game disk that I was trying to copy for a friend only to lose my only copy.
The error made here is in an enormously more complex domain, but kind feels like they just accidentally low-level formatted an important diskette.
I do think there's a need for a much simpler standard multisig than the ones being used now.
True multisig transactions like you're talking about are supposed to become possible with the next Ethereum upgrade.
This probably could have been fixed with basic testing.
Just look at all the companies like Microsoft or Apple with millions to spare, or massive community efforts like Linux kernel, either with no shortage of means and resources to make their systems resistant to simple programming bugs.
But history clearly shows that no amount of processes, audits, static analysis or eyepairs help: bugs just keep on being found where ever security folks look for them, and the harder they look, the more they find. Upside is, these systems can be patched, which is comforting as clearly there just is no bug-free code.
Yet, people keep on pouring millions of dollars worth of virtual tokens to these experimental blockchain systems that are fundamentally designed so that any bug of certain class means the money is forever, irreversibly lost - as if these crypto contracts were some mythical new breed of software written by infallible Gods.
The fact that you can do these things doesn't save you from people who don't. Parity's last audit happened before they made a major architectural change; if they'd gotten new audits this probably would have been caught. They also have the most complex wallet code I've seen, often dipping into assembly.
It's true that you can't be completely sure of avoiding bugs, but with decent practices I think it's less of a problem on Ethereum that it is in medical equipment, airliners, and nuclear reactors.
You probably won't do it on the first try. And you wouldn't immediately bet a million dollar on it. But is it possible?
Yes.
A multisig wallet shouldn't be more complicated.
Could you prove the correctness of the 6502 chess? Sure. Formal methods are not black magic. You need a semantics of the machine and a formalization of the rules.
Can you make mistakes in specifying? Yeah, duh. So combine it with peer review and throw in a bug bounty and fuzzing.
https://en.wikipedia.org/wiki/Castling#Requirements
and some people may neglect or misimplement en passant
https://en.wikipedia.org/wiki/En_passant
and the rules related to repetitive situations in the end game:
https://en.wikipedia.org/wiki/Threefold_repetition
https://en.wikipedia.org/wiki/Fifty-move_rule
(Implementing the threefold repetition rule requires maintaining historical state of a different kind than any other chess rule!)
I've seen impressive hyperminimalist chess implementations that were missing these things, but that totally felt like real chess almost all of the time.
A perfect chess implementation from before those rule changes would no longer be correct!
It’s possible to prove that code perfectly implements a formal spec. It’s tough to prove that the formal spec perfectly describes what you want it to describe.
This is a very strong if. It means the rule cannot be reduced in plain logic.
The example of forward castling rule is a good one.
A missing definition of some en passant situations is caught too. (E.g. situations of check.)
Completely missing rule cannot be caught with these techniques. You also need to ask the prover right questions.
Say: when does a chess game end. Proof requires proving the existence of a halting Oracle for any game state. Not quite easy but possible. To actually verify, you will have to provide reduction rules unless you happen to own a supercluster.
It takes time and sometimes serious math skills.
But its proving in my experience to be a much more practical foundation, and going forward there is a lot of value in that.
For instance:
sudo rm -rf /
Every part of that is completely sound and correct. There are no buffer overflows, emory corruption, or anything. You wrote a completely correct command to do something (probably) really wrong.Then there are systems that just prevent ambiguous rules if you really dig into it. (Speaking of assisted theorem prover such as Coq and Isabelle.)
In this case it was fully specified that sudo should run rm with all privileges, which in turn will recursively deleted the root filesystem.
The entire execution is fully specified and will execute without fault. There is no mistake in `sudo rm -rf /`.
Logical faults may not be preventable with provers, such as when underlying assumptions are wrong.
For example, a prover could have verified the parity library as fully okay because it assumes that the initialization function will not be called without delegation. This underlying assumption X -!> Y (X cannot lead to Y) is wrong and X -> Y is the case but the prover only verified that Y -!> X.
Provers essentially duplicate your code, forcing you to express the solution and/or problem twice such that if you basically typo on the way, one of the pieces will complain about the other.
But it cannot and is incapable of preventing higher level mistakes.
Bugs happen no matter the language, even if LLVM was in Rust it would have them.
Security-related compiler bugs very rare, but they do exist, at least in graphics shader compilers: http://www.doc.ic.ac.uk/~afd/homepages/papers/pdfs/2017/OOPS... . My impression is that many of these shader compilers are based on LLVM, but this is mostly conjecture. (I do recall a video game crashing on me with internal LLVM errors from the graphics driver.)
He had no reason to make the github issue afterwards, if he was a blackhat who knew what he was doing. His entire presentation doesn't seem like that. (Or even like "someone who is trying for no real reason to try to look innocent". He didn't have to be public at all.)
What are you talking about? Do you mean this issue: https://github.com/paritytech/parity/issues/6995 ? What list are you referring to?
The previous bug with these was very trivial and could have been caught by a unit test or a simple code review, and it resulted in around 9 figures (USD) of Ether being stolen.
This bug looks like it's exactly the same. A very simple bug that could have been caught by a simple test or manual audit, and has resulted in 9 figures USD being locked instead of stolen this time.
As mentioned by others it's possible at some point (not any time soon) that this frozen ETH can be recovered (https://github.com/ethereum/EIPs/issues/156) by adding rules to recover it in the next Ethereum hard fork. Not creating a specific hard fork just for this, but adding it to one that is planned in the future. That might come across as controversial, and cannot be guaranteed though.
For safely storing Ethereum I would advise to keep it out of smart contracts, period. Cold storage and hardware wallets exist, and they are much less likely to have critical bugs related to them than a smart contract is.
“Code is Law” fails again.
There will probably be a hardfork and increased moral hazard for auditing contract code. Why spend money finding bugs if the "immutable" blockchain can be rolled back?
Ethereum has had one particularly controversial fork, and so did Bitcoin. In both cases, both chains survived, with one significantly more popular than the other (in both hash rate, transactions, and market cap). (Un)fortunately, traditional law in real life does not permit two realities to coexist, so there the analogy falls apart somewhat.
Like, imagine if twenty members of congress kept their life savings in cash in uninsured briefcases and surprise, those briefcases were stolen. And they responded by passing emergency legislation invalidating the specific serial numbers stolen, and requiring every merchant and bank to screen for those serial numbers (and not those from any other e.g. bank robbery).
I would consider that kind of action to be very delegitimizing to the currency.
[1] I would consider it to be analogous to a fork when they e.g. deprecate an old design or migrate to the Euro.
I do think that calling blockchains "immutable" can be confusing to users not familiar with the concept and its nuances. And I personally hold no opinion on whether the currently locked up funds need to be returned to their owner with a fork. There is something to be said for both options, specifically in this case where there the "rightful owner" is clear (like the other cases mentioned in https://github.com/ethereum/EIPs/issues/156 ).
At the time of the DAO hack there also hadn’t been a public demonstration of the scale and danger of contract hacking. That’s also no longer true.
That said, ETH is an anarchist federation in the end, and the market will decide which reality is most valuable: the one in which the parity hack happened or the one in which it didn’t.
https://github.com/pirapira/bamboo
The Bamboo manifest:
https://github.com/pirapira/bamboo/blob/master/doc/manifest....
There is a project under way to formalize Viper, which is the other newly developed programming language for Ethereum, as well:
Every time I read opinions like this, it's mostly by people not using Ethereum.
> For safely storing Ethereum I would advise to keep it out of smart contracts, period
This is what I don't understand. Why would anyone use these things?
> Parity's goal is to be the fastest, lightest, and most secure Ethereum client.
with all the recent past in mind, makes it sound pathetic. I'll continue to use geth, although it didn't board the cool-kids-Rust-train.
bug bounties compete among themselves. Honest researchers will be busy finding some mobile game bugs for $700 a pop or improving security at google or yahoo for up to $10k instead of helping your company save from a 9 figure bug because you only offer $100
This is the minimal bounty.
They do state "Rewards over the minimum are at our discretion, but we will pay significantly more for particularly serious issues, i.e. that the identified issue could put a significant number of users at risk of severe damage, monetary or otherwise."
What they consider significant is anyone's guess. Given the stakes, even a 10000% increase would still be underwhelming for a high impact bug.
EDIT: apparently one of the wallets affected holds $90 million raised for the Polkadot project [1,2], which is their own. A quote from the previous incident[3]:
> Unfortunately, since Parity is a small, minimally-funded start-up, we have not the resources to do this alone. Outside of a few tips to the shoe fund, Parity has received no funding whatsoever from any organisations within the Ethereum ecosystem.
[2] http://www.trustnodes.com/2017/10/15/polkadot-ico-raises-130...
[3] https://paritytech.io/blog/the-multi-sig-hack-a-postmortem.h...
Maybe the people who lost that Eth didn't lose all that much?
They did a good job optimizing the contract to use minimal gas upon deployment, but maybe that's not the best thing to optimize for contracts that will hold millions of dollars. They also don't appear to have gotten fresh external audits when they made changes.
Incidentally, there are other Ethereum languages in development that are better suited for formal verification, including Viper and Bamboo.
We talking about >100$ here?
(I also think you'd be better off using a different wallet entirely; Parity's isn't the most popular anyway, especially lately.)
I have no strong opinions on Solidity, btw - just generally interested in people's views on developer experience.
1) There's no need for a garbage collector, because there's very limited computation within each transaction, and complete cleanup of non-permanent storage after each one.
2) The author doesn't appear to realize that the list of mis-compilation bugs is a list of fixed bugs. The list is only available in json because its purpose is just to let tools display warnings for obsolete compilers.
3) I have a hard time dreaming up an application that would need a string library in Solidity, because storage on chain is very expensive, and you only need to compute things on chain that require global consensus. Strings on chain are usually very short and static; for longer stuff we just store their hashes on chain and use client code to manipulate the strings.
What the smart contract can't do is ensure that the funded project actually delivers on its promises. But neither can Kickstarter...
The advantage would be avoiding the 5% Kickstarter fee + (according to Wikipedia) 3% to 9% payment processor fees. The computation fees charged by the blockchain are presumably well below that. [On the other hand, maybe they aren't. Calling this suicide function on the Parity multi-sig wallet apparently cost 27 cents. If the crowdfunding contract is more complex, and submitting a payment costs, say, a dollar, then the average contribution would have to be on the order of 10 dollars to break even vs. Kickstarter.]
What value?
> no one decides if the project delivered properly
Same as Kickstarter. They release the funds to the creator after a certain deadline, after which they do not get involved in deciding whether the project delivered. Which is what I wrote above.
EDIT: I should add that I do very much agree with the general point you're not making: Smart contracts are only smart inside the closed world of the computer system running them; they don't magically know things about the "real world", and they cannot affect the "real world". I agree that many smart contract aficionados act as if they didn't understand this basic point. That's why I deliberately chose the Kickstarter example, which is also a system that does not make guarantees about the real world once payments have been made.
I suppose in this case the nice thing with the smart contract (assuming it works as advertised) is it's simple and verifiable. You know you'll get an instant payout if publicly available data shows your flight was delayed > 2 hours (regardless of reason). There's no human in the loop and no signed contract with weasel words that gets AXA off the hook from paying.
(Sorry, the website won't display anything here.)
You can sign-up for the cover up to 15 days before departure. Apparently you input your flight number and credit card details. If the flight ends up being delayed more than 2 hours, their smart contract triggers an automatic payout to your card, no questions asked.
Yes, and it's sad that they continue to try to patch around and nibble at the problem. The foundation is borked, start over.
https://gist.github.com/banteg/f61d256d12158b8c344d7889266f4...
It looks like if this EIP is implemented in the future, the address that created the original multi-sig wallet contract created after July 20th, would just be sent the ether balance in the wallet. I'm not sure on this, but it seems like, if implemented in the future, an owner of a multi sig wallet that is frozen can call this contract from the same address they created the wallet with and it will retrieve the ether from the address where the contract is now blown away?
Another option would be during the next planned fork (upgrade), to just say, any contract that matches the byte code of the frozen wallet one, just replace the code with this code and move on. Although the first option is MUCH nicer and future proof.
People will write bad code and things like this will happen. I think the more often and earlier on we find these types of flaws and can fix them, the better for the whole ecosystem. It's $300 million today... in 10 years, a mistake like this that hasn't been worked out could cause a shock to the entire world economy. (run on the banks, but there are no banks and everyone's funds are frozen...panic!) So better now than later!
Have you lost faith in the Pound yet?
Better yet, people who have the mindset that it's ok to have these hipster "modular" features that spread out the responsibility (for whose benefit?) should really not be working on such fundamental pieces of technology. If you write software that holds people's money and you fuck up, you and only you are responsible for it.
This is a recurring theme with the Ethereum community where people complain about how there was a bug in the system which resulted in a huge hack and people losing tons of money, and developers say "hey don't blame me I just used some library, it's the library's fault".
Having modularity in these things only amplifies the damage when something DOES happen.
I'm not saying it is bad to have a centralized auditing of contracts, but I am saying it's not a good thing to simply import libraries and inherit some other abstract contract you don't fully understand when it comes to irreversible contracts.
This is a new type of problem we as a humanity have never faced before, so we need a different type of solution.
Could you elaborate on that? How is it a new problem? I would think it's similar to problems with hardware components or FPGA libraries, but maybe I'm missing something?
But with cryptocurrencies, it's not just about technology but ties into other issues that normally have been tackled on a social level. So in this case there is no "bank" you can complain to or no one to sue.
Of course, you could say Ethereum as a whole can do a hard fork just for this, but that's another discussion altogether.
Who really says that?
Also, a while ago some guy complained about how he lost his money using myetherwallet, and the problem was NOT because of myetherwallet but a library they used. So the guy from myetherwallet told reddit that it's not their fault, which is again technically true, but again fits into what I'm talking about.
Dependency spreads out responsibility, which works out fine for traditional finance because everything is reversible, but not in this new economy.
For the most part, they work just fine.
I love this feeling of living on the edge when I know that I just evaded a critical bug that could have cost me a lot of money.
Though, a lot of people who aren't me will be a lot more angry, especially (and probably only) people actively using the multisig.
The language used is unsafe, and developers didn't test properly.
What can be done? Fork I guess.
Or maybe leave the developers developing on the Ethereum platform to just fail?
Many would argue the correct thing to do is to not fork and say that people knew the risks beforehand, etc. But that's what people said last time and they still forked, with no (apparent) severe consequences other than complaining about integrity. Two forks may be harder to justify.
It's just funny how decentralized currency is so easily swayed by a few individuals to serve their purpose.
Parity's refactoring of the official audited multi-sig contract code has fucked up again. I wonder if they even audited their code.
The post-mortem of the last incident https://blog.ethcore.io/the-multi-sig-hack-a-postmortem/ evades that question under the paragraph "Was the wallet not audited?".
If they used a library instead of a contract, this wouldn't have been possible. I hope they had a reason to use a contract otherwise they clearly have noone else to blame this time.
It's actually the opposite, using a library allowed this to break all the wallets using it. However, an Ethereum "library" isn't what you'd expect a software "library" to be - it's an executable contract that just is never supposed to be executed directly. But oops, nothing prevented that from happening.
The concept of everyone using a common, well-audited contract makes sense though. Virtually all Bitcoin multisignature transactions use the same script construction and it has never been hacked, despite being much older.
Just Parity's contract was neither common nor well audited.
> Virtually all Bitcoin multisignature transactions use the same script construction and it has never been hacked, despite being much older.
The only multi-sig issue that I'm aware of in Bitcoin was the Bitfinex hack but I don't know in what relation BitGo's multi-sig implementation is to the standard multi-sig.
The EF multi-sig implementation has been audited and AFAIK there has also never been an issue with it.
It's ethereum, they'll just hardfork those coins back
Apparently almost $300M stuck - I don't see them not bringing up another hard fork to retrieve them
Perhaps it can be fixed though, as part of the next hard fork.
No idea why everyone ignores this metric. And that's why Bitcoin is still somewhat blockchain (also poor sync, but doable)
https://www.reddit.com/r/ethereum/comments/6zcoja/10_gb_in_2...
Shouldn't believe random charts on the internet!
Eventually other solutions will be needed, like sharding. One solution for the never ending growth of spent transaction and block header data is snapshots. Practically, you can safely not validate tx data older than X, if X is a sufficient length of time.
A solution for neverending state size growth is storage rent with pruning of entries that default on rent payment.
Isn't sharding major compromise on security? I thought snapshots mean you just download the exact state at block X and never bother about tx older than X. And you do that not because of time, but because at the point of installing of blockchains you already trust _someone_ with node software, so you should also trust with latest state (and treat it just like genesis block).
Speaking of storage tax, Ethereum should have implemented one like yesterday.
If the average block size is 13 KB, then there should be 546 MB added per week (13 KB / block * 6000 blocks / day * 7 days / week).
I don't know enough about sharding to offer an informed opinion on it, though I imagine the security compromises are tolerable.
With regard to a snapshot, yes that is one way they're used. I was suggesting that archival nodes could even rely on snapshots to cap their storage requirements.
Additionally, Ethereum, unlike Bitcoin, does not want everyone to run a full node, you can certainly run Archival nodes, but most people should be using light clients or nodes which do not store the full history of the chain (only recent history)
Assuming, the user wants to have a daemon running full time. They just downloaded your thing and you're imposing your rules? Deleted.
> Additionally, Ethereum, unlike Bitcoin, does not want everyone to run a full node
To me a full node is the one that verified every single block since the install point. (Not from genesis, a snapshot is fine). I'm strongly against archiving the blocks for normal users, only the state should be stored.
When you run software you kinda accept that this software imposes rules on you.
Or do you delete Firefox or Chrome because they enforce Certificate Validation on HTTPS with HSTS?
Bandwidth and storage are only getting cheaper
Also "Ethereum failed as a blockchain"? They're the 2nd largest coin after bitcoin, it can hardly be called failed
It's a lot on average.
https://medium.com/@homakov/weekly-sync-friction-the-most-im...
>They're the 2nd largest coin after bitcoin, it can hardly be called failed
"caps" are short term hypes, they are not definition of blockchain. Say, Ripple is not a blockchain at all. Try critical thinking, highly recommended.
This seems unnecessarily combative.
https://medium.com/@homakov/weekly-sync-friction-the-most-im...
https://twitter.com/polkadotnetwork/status/92788076205302170...
edit: they just put out a post to say that not all of their funds were in a Parity multisig wallet:
https://medium.com/web3foundation/web-3-multi-sig-wallet-upd...
A similar recovery already happened once, after somebody exploited a bug in The DAO, resulting in a fork into Ethereum and Ethereum Classic, which rejected changing the rules to bail out bugged but too-big-to-fail smart contracts.
> In May of 2016, a venture capital fund called The DAO built on Ethereum raised around $168 million, with the intention of investing in projects using smart contracts. In the same month a paper was released detailing security vulnerabilities with The DAO that could allow ether to be stolen. In June, 3.6 million Ether (approximately $50 million USD) was taken from accounts in The DAO and moved to another account without the owners' consent, exploiting one of the vulnerabilities that had been raised in May. Members of The DAO and the Ethereum community debated what actions, if any, should occur to resolve the situation. A vote occurred and in July 2016 it was decided to implement a hard fork in the Ethereum code and to move the Ether taken in the exploit to a new smart contract through which it would be restored to the owners from whom it had been taken.
> Ethereum Classic came into existence when some members of the Ethereum community rejected the hard fork on the grounds of "immutability", the principle that the blockchain cannot be changed, and decided to keep using the unforked version of Ethereum.
From what I've read about Ethereum's contract language, it doesn't make itself easy to statically verify properties you want to check so I don't see how problems like this are going to go away until another language is used.
The parity wallet uses a "shared library" in which the actual logic is implemented. All individual wallets have their own data storages and coin balances, but contain just a little bit of logic code that redirects calls to this shared codebase.
This shared library itself is also just a contract, except that it's intended to be called internally by other contracts (the different wallets). Though it typically doesn't happen, it can be called directly by humans. This is what the makers of this "shared library" apparently forgot to consider, until somebody called the "initialization function" of the shared library directly. By doing this, the shared library initialized itself as if it was one of the individual wallets that normally call the library. It therefore used its own (previously unused) data store, in which it correctly entered the caller of the init function as owner.
This wasn't of use for anything, as there are no ethers at all on the shared library, so the owner could not steal any funds. But being the owner, he was able to trigger the kill switch! Since this particular "multisig wallet" was actually not a wallet, but the shared library, killing it not only killed the (empty) wallet, but also the core functionality of all the real wallets that contain real money out there! And of course that functionality is mandatory to work with the funds of these wallets. Without it, the money cannot be moved anywhere.
Now comes the fun part: suiciding a contract normally transfers all ethers on that contract to the caller of the suicide function. Knowing this, you could expect that the individual wallet owners could just as easily suicide their now "brain-dead" multisig wallets as well, thereby recovering their funds...but that doesn't work, as performing the suicide requires a call to the shared library to check whether the callers' signatures qualify the caller to perform that suicide ;-)
This sounds really similar to the big Ethereum wallet hack from earlier this year.
My wife once left the car running and went to buy gum in a drug store, the car wasn't their when she got back. Shit happens I guess.
I would say there are many ways to look at this with regard of "what went wrong":
- You could say that it's a very, very bad idea to share ANY code between individual wallets which - from a functional standpoint - should not have any intersections between them whatsoever (except of using the same blockchain of course). Individual wallets are DESIGNED to fully isolate the contained tokens and state from each other, so why not also fully isolate their code by duplicating it? Is saving a bit of gas on wallet creation actually worth the additional complexity that comes with code sharing? Seems like someone took the "DRY" principle to a very unhealthy extreme here.
- Apparently the explicit construct of libraries described here (http://solidity.readthedocs.io/en/develop/contracts.html#lib...) is not very well-known in the Ethereum community. I did not know about it (someone here on HN pointed me to it), and while this is understandable considering that I have just a tiny stake in ETH and don't write Ethereum contracts for a living, the fact that Gavin Wood - co-creator of Ethereum - did apparently also not know about it (or for some reason decided not to use it for this library, which would be equally concerning, because if it's not usable for a textbook example like this, it must be seriously flawed) should cause a bit of head-shrugging. Because according to the docs, this construct delivers a crucial limitation with which this entire drama would have been impossible: libraries don't need their own state! So it's just consequential to not allow them to have any state (like an owner, or ETH funds), which apparently is exactly what the library construct does.
- Maybe this incident is just another bit of proof to the theory that the combination of immutability, handling of huge monetary values without any human oversight at all, and the idea of a Turing-complete language just don't mingle together very well. If you're not able to manually interfere in case stuff goes wrong in a way you didn't anticipate, you need to be able to basically anticipate absolutely all ways in which stuff can go wrong beforehand. A Turing-complete language seriously complicates doing this, possibly to an extent that kicks the entire concept beyond the realm of practicability. If this turns out to be true, the entire value proposition of Ethereum would be void right from the beginning.
https://www.reddit.com/r/ethereum/comments/7bem7v/solidity_l...
Rather, formal verification is just one piece in the puzzle. The software responsible for contracts in Ethereum needs to be equally well and thoroughly developed as if it was sending people to the Moon in the 60s or to Mars in the current Decade.
It'll probably take blood, sweat, money and mistakes just like in many other disciplines but we'll get there.
What problems specific to Ethereum do you see? Formal verification has been applied to complex domains and large projects before.
Work on this has indeed been going on for decades, and its very limited adoption so far is a testament to its difficulty. Only a tiny fraction of the code in the domains you mention is formally verified, and I notice that banking and finance are not on your list. The answer to "why would how useful Ethereum is or could be make a difference?" is that if Ethereum becomes as useful and important as intended, the size and scope of the problem will be well beyond anything that has been achieved so far. Arguably, given the value at risk, it has already crossed that threshold by a wide margin.
There are, however, people working on it, such as at Cardano [1], which is an exciting development. Ultimately, I think it will be more successful than trying to fix Ethereum.
If you don't have experience writing formally-verified code, I suggest the F* tutorial [2].
They then compounded this poor choice with an Ethereum programming language with poor and insecure semantics.
I applaud the ambition behind Ethereum, but not it's technical choices.
Wait, am I reading this right? All multi-sig wallets are frozen due to this? This is surely concerning, as I've seen others recommend multi-sig wallets as a security best practice.
Can anyone comment on the method in which they might revert this? Would it require a hard fork.. again?
All multi-sig Ethereum wallets created by Parity (or using the Parity contract code).
> Can anyone comment on the method in which they might revert this? Would it require a hard fork.. again?
So far, it doesn't look like you can do anything about it. Of course you can change everything with a hard fork but as this time it doesn't compromise the move to PoS, I don't think a hard fork will be the favored solution.
But this time, there is no deadline, so it can be discussed thoroughly.
Parity multi-sig wallets are an entirely different beast.
Bit of a confusing naming issue:
Parity wallet: light client software that accesses the blockchain.
Parity multi-sig wallet: a smart contract deployed on the blockchain, with the coins stored within this contract.
The latter is what was affected.
Unless I am recalling incorrectly, the bug during the summer did not impact anyone on the Ethereum team, while this one did.
Which would make the motivation behind a hard fork in this specific case ... questionable.
I think that would be the time I divest myself of the ETH I hold.
Disclaimer: (If it wasn't obvious from the above :) ) I hold a decent amount of ETH (thankfully not in a parity multi-sig wallet!)
Get your Amazing Super Safe Cash Box today! With loads of advanced features that may or may not be useful in the future! Made by some of the cleverest people in the world!
You decide to store your cash in this amazing device, so of course you do a bit of due diligence on the construction and find that well, while there was a huge catastrophic construction failure causing millions of dollars of loss a few months ago, the new version was quickly released fixing the specific issue... so it should be fine, right? It definitely probably won't set all my cash on fire...
Never mind the lack of independent audits, and the fact that the whole thing is way too complicated for its purpose...
I hope and predict that these disasters become million dollar lessons on what kinds of autonomous functions you can trust with money, and what "security auditing" actually means, so that in a couple of years, given that the notion of a smart contract is actually useful, people won't put funds into bad, faulty logic.
Safety-deposit boxes are dumb stores for objects. They've never been marketed on features; in fact the opposite, they're marketed partially on the idea that nobody can open them but you. Therefore, no services (e.g. automatic transfers) can be built that depend on someone being able to automatically do things to your safety deposit box without you there to watch.
Banks (specifically, checking and savings accounts) are not dumb stores of money. They don't even hold onto your money; they leverage it into investments. Banks have always been built on "loads of advanced features" like compound interest, wire transfers, cheques, etc.—things the bank can do to your money because it is not, in fact, a Super Safe Cash Box. It's a convenient, maybe-safe money-management agent.
Bank accounts are only really trustworthy because of 1. a long track-record, and 2. being insured against losses (in banks' case, by the government.) Those are the same requirements I would put on any digital-currency+contracts system before I considered it trustworthy. Digital-currency+contracts is trying to do banking with banking features, so hold it to the expectations of a bank.
There are bound to be many more incidents such as this in various cryptocurrencies. There are now thousands of them. But it would be ignorant to dismiss the technology for a lack of understanding it.
The analog in national currencies would be if everyone had to immediately stop using the old notes and replace them with new ones that a new anti-counterfeit feature. Or migration to the Euro.
When banks are hacked or whatever, they have some kind of insurance that just replaces the money. They don't have to get the rest of the system to update anything.
{!} Thanks to today's progressive reforms the State now also employs women with guns. We should just say people with guns to not be sexist.
Foreign shell companies are already hard enough for most governments to deal with—and that's with trade agreements that enable them to compel disclosure of ownership. DACs are foreign shell companies without a governing state to point guns at.
Sure, if the DAC does business in the US, the US government can shut that business down—much like the US government can shut down a domain name associated with foreign illegal activity. But that doesn't stop the business from operating anywhere else. Nobody has the ability to shut down the whole business.
https://gist.github.com/banteg/f61d256d12158b8c344d7889266f4...
Has this extra layer of complexity really been injected just to save some bytes on the blockchain?
> I made myself the owner of "0x863df6bfa4469f3ead0be8f9f2aae51c91a907b4" contract
How is that possible?
AFAIK this feature was introduced to make owners capable of deactivating contracts which contain known security bugs (so at least nobody can accidentially send any more money to those contracts). And because that's the intended purpose, a suicide is non-revokable, so a dead contract remains dead forever.
A library apparently can be nuked because Ethereum does not explicitly have a concept of "libraries". They are after all just contracts, with the only difference being that they are intended to be called by other contracts instead of humans.
I see the next controversial, but eventually Vitalik-blessed hard fork incoming...
That's not correct. There is a construct "library" that is different from a normal contract. But the code in question didn't use that (for whatever reason).
http://solidity.readthedocs.io/en/develop/contracts.html#lib...
> I see the next controversial, but eventually Vitalik-blessed hard fork incoming...
I wouldn't be so sure.
It's only about 1% of all ETH and the funds are frozen. The DAO hack was ~15% and would have put those funds into the hand of a single entity which would endangered the eventual move to PoS.
Thanks for pointing me to this! Didn't know that yet...but in that case I'm really wondering why this strange "library" from Parity even worked the way it did...? If it's necessary to use the library construct in order to have the code not access its own contracts' data storage and funds, but those of the calling contract (this is at least how I understand the description you linked to), how could the Parity library even work the way it did without this construct?
So far, it really looks like almost a criminal sloppy refactoring of the official multi sig contract from the EF that has been extensively audited.
https://gitter.im/paritytech/parity?at=5a01b9d2b20c6424299b0...
It's not a vulnerability of Ethereum.
It's sort of how like a "use after free" bug in a program written in a non-GC'd language isn't a vulnerability of the language itself.
Languages encourage or discourage (or even eliminate) lasses of bugs based on their design. Etherum's is particularly bad in this regard.
Bullet #1: Prepare for failure
Sadly I forgot the service name :(
Or you could use secret sharing for BTC or Eth, but people tend not to.
See http://docs.electrum.org/en/latest/multisig.html for an example, and https://en.bitcoin.it/wiki/Multisignature for more background (including links to SSSS).
You don't need a smart contract to achieve this. I suppose it's more convenient since your co-signers can just submit their M signatures onto the blockchain, instead of having to collaborate offline to generate a valid signed block.
But putting the multisig logic into a smart contract is quite obviously not fail-safe, as these vulnerabilities show.
https://cryptoshirt.io/products/devops199-quote-i-accidental...
#ethereum #eth #ether #parity #devops199
Are these guys ever going to learn?
Of course I've briefly entertained the idea but on the other hand, a bet between two mostly-honest individuals doesn't need a blockchain contract, similar to how I don't need a blockchain contract to borrow money from my sister and pay it back later.
In any case, if there would be a hardfork, it would include the replay protection, so a simple but working solution would be to prepare a transaction for the fork chain and one for the non-fork chain, the participants can then publish the transactions once either chain becomes available and claim the reward.
An example betting contract for anyone interested (note it was eventually refunded and not run):
https://etherscan.io/address/0xf4b8ccc5734ed7d2d8beb5fddd223...
And an overview with some reasonable criticism:
https://www.reddit.com/r/ethdev/comments/6sd8hl/mayweather_v...