When it debuted, Bitcoin (BTC -1.04%) was considered innovative as the world's first secured peer-to-peer electronic cash payment system. Its most striking features (compared to other digital money predecessors) were its cryptography and verification process. Without these, Bitcoin would be nothing more than a string of code anyone could copy and paste -- which would quickly break down trust.
But its novel process for confirming transactions, called proof of work, also has its drawbacks. If an entity, like a government, took control of 51% of the network's hash rate, or mining computational power, it would be able to reverse transactions, block new transactions from taking place, and more. It's not just Bitcoin; altcoins that use a PoW consensus mechanism, such as Ethereum Classic and Bitcoin Gold, have all suffered 51% attacks in the past. So how concerned should you be?
Hash attack economics
Starting with the basics, Bitcoin is encrypted by transactions using what's called a Secure Hashing Algorithm 256 (shortened to SHA-256). It is a one-way function, meaning that it's easy for anyone to compute an output (or a value that comes out) using an input (a number that feeds into an algorithm), but it is very difficult to compute the input using the output. For each new block, its network publishes a target hash, and the first miner to compute the correct hash takes the rewards home.
Right now, the hash rate of the Bitcoin networks stands at 133.494 million terahashes per second. That means mining machines across the globe are making 1.33494 * 10^20 (a 21-digit number) guesses every second as to what the correct hash is to verify blocks.
To put it economically: it would cost over $2 million every hour in electric bills for hackers to launch a 51% hash attack against the Bitcoin network. And that's just the maintenance cost. Hackers would also first have to invest tens of billions of dollars in state-of-the-art computers and circuit machines to build up hundreds of millions of terahashes to mount the offensive.
But the variables are slightly more accessible for some altcoins. It would cost less than $200,000 per hour and $30,000 per hour for hackers to launch 51% attacks against Litecoin and Bitcoin Cash, respectively. And it would take less than $20,000 per hour to temporarily take over popular privacy coin PoW networks like Dash and ZCash.
The real threat
That brings up the main point: The lower a PoW coin's market cap, the lower its network hash rate, which means it's easier for invaders to attack it. Indeed, it costs as little as $1 an hour to take over 51% of the hash rate for cryptocurrencies trading below a market cap of $10 billion. But correlation does not necessarily equal causation. There are outliers like Dogecoin, which has a huge market cap but may cost as little as $40,900 per hour to control 51% of its hash rate.
Also keep in mind that it's not just hackers who can use 51% hash attacks as a means to an end but also regulatory agencies. Due to its decentralized structure, the industry has a substantial share of scams or fraudulent activity. So don't be surprised if the U.S. Securities and Exchange Commission starts launching it own hash attacks to take regulatory delinquent altcoins offline.
Bitcoin investors shouldn't worry too much about these threats -- but they're something that PoW altcoin investors should at least bear in mind before investing.