Proof of work explained

Proof of work (PoW) is a form of cryptographic proof in which one party (the prover) proves to others (the verifiers) that a certain amount of a specific computational effort has been expended.[1] Verifiers can subsequently confirm this expenditure with minimal effort on their part. The concept was invented by Moni Naor and Cynthia Dwork in 1993 as a way to deter denial-of-service attacks and other service abuses such as spam on a network by requiring some work from a service requester, usually meaning processing time by a computer. The term "proof of work" was first coined and formalized in a 1999 paper by Markus Jakobsson and Ari Juels. The concept was adapted to digital tokens by Hal Finney in 2004 through the idea of "reusable proof of work" using the 160-bit secure hash algorithm 1 (SHA-1).[2] [3]

Proof of work was later popularized by Bitcoin as a foundation for consensus in a permissionless decentralized network, in which miners compete to append blocks and mine new currency, each miner experiencing a success probability proportional to the computational effort expended. PoW and PoS (proof of stake) remain the two best known Sybil deterrence mechanisms. In the context of cryptocurrencies they are the most common mechanisms.[4]

A key feature of proof-of-work schemes is their asymmetry: the work – the computation – must be moderately hard (yet feasible) on the prover or requester side but easy to check for the verifier or service provider. This idea is also known as a CPU cost function, client puzzle, computational puzzle, or CPU pricing function. Another common feature is built-in incentive-structures that reward allocating computational capacity to the network with value in the form of cryptocurrency.[5] [6]

The purpose of proof-of-work algorithms is not proving that certain work was carried out or that a computational puzzle was "solved", but deterring manipulation of data by establishing large energy and hardware-control requirements to be able to do so. Proof-of-work systems have been criticized by environmentalists for their energy consumption.[7]

Background

The concept of Proof of Work (PoW) has its roots in early research on combating spam and preventing denial-of-service attacks. One of the earliest implementations of PoW was Hashcash, created by British cryptographer Adam Back in 1997[8] . Hashcash was designed as an anti-spam mechanism that required email senders to perform a small computational task, effectively proving that they expended resources (in the form of CPU time) before sending an email. This task was trivial for legitimate users but would impose a significant cost on spammers attempting to send bulk messages.

Hashcash's system was based on the concept of finding a hash value that met certain criteria, a task that required computational effort and thus served as a "proof of work." The idea was that by making it computationally expensive to send large volumes of email, spamming would be reduced.

One popular system, used in Hashcash, uses partial hash inversions to prove that computation was done, as a goodwill token to send an e-mail. For instance, the following header represents about 252 hash computations to send a message to calvin@comics.net on January 19, 2038:

X-Hashcash: 1:52:380119:calvin@comics.net:::9B760005E92F0DAE

It is verified with a single computation by checking that the SHA-1 hash of the stamp (omit the header name X-Hashcash: including the colon and any amount of whitespace following it up to the digit '1') begins with 52 binary zeros, that is 13 hexadecimal zeros:

0000000000000756af69e2ffbdb930261873cd71

Whether PoW systems can actually solve a particular denial-of-service issue such as the spam problem is subject to debate;[9] [10] the system must make sending spam emails obtrusively unproductive for the spammer, but should also not prevent legitimate users from sending their messages. In other words, a genuine user should not encounter any difficulties when sending an email, but an email spammer would have to expend a considerable amount of computing power to send out many emails at once. Proof-of-work systems are being used by other, more complex cryptographic systems such as bitcoin, which uses a system similar to Hashcash.

Variants

There are two classes of proof-of-work protocols.

Known-solution protocols tend to have slightly lower variance than unbounded probabilistic protocols because the variance of a rectangular distribution is lower than the variance of a Poisson distribution (with the same mean). A generic technique for reducing variance is to use multiple independent sub-challenges, as the average of multiple samples will have a lower variance.

There are also fixed-cost functions such as the time-lock puzzle.

Moreover, the underlying functions used by these schemes may be:

Finally, some PoW systems offer shortcut computations that allow participants who know a secret, typically a private key, to generate cheap PoWs. The rationale is that mailing-list holders may generate stamps for every recipient without incurring a high cost. Whether such a feature is desirable depends on the usage scenario.

List of proof-of-work functions

Here is a list of known proof-of-work functions:

Proof of useful work (PoUW)

At the IACR conference Crypto 2022 researchers presented a paper describing Ofelimos, a blockchain protocol with a consensus mechanism based on "proof of useful work" (PoUW). Rather than miners consuming energy in solving complex, but essentially useless, puzzles to validate transactions, Ofelimos achieves consensus while simultaneously providing a decentralized optimization problem solver. The protocol is built around Doubly Parallel Local Search (DPLS), a local search algorithm that is used as the PoUW component. The paper gives an example that implements a variant of WalkSAT, a local search algorithm to solve Boolean problems.[25]

Bitcoin-type proof of work

In 2009, the Bitcoin network went online. Bitcoin is a proof-of-work digital currency that, like Finney's RPoW, is also based on the Hashcash PoW. But in Bitcoin, double-spend protection is provided by a decentralized P2P protocol for tracking transfers of coins, rather than the hardware trusted computing function used by RPoW. Bitcoin has better trustworthiness because it is protected by computation. Bitcoins are "mined" using the Hashcash proof-of-work function by individual miners and verified by the decentralized nodes in the P2P bitcoin network. The difficulty is periodically adjusted to keep the block time around a target time.

Energy consumption

Since the creation of Bitcoin, proof-of-work has been the predominant design of Peer-to-peer cryptocurrency. Studies have estimated the total energy consumption of cryptocurrency mining.[26] The PoW mechanism requires a vast amount of computing resources, which consume a significant amount of electricity. 2018 estimates from the University of Cambridge equate Bitcoin's energy consumption to that of Switzerland.[4]

History modification

Each block that is added to the blockchain, starting with the block containing a given transaction, is called a confirmation of that transaction. Ideally, merchants and services that receive payment in the cryptocurrency should wait for at least one confirmation to be distributed over the network, before assuming that the payment was done. The more confirmations that the merchant waits for, the more difficult it is for an attacker to successfully reverse the transaction in a blockchain—unless the attacker controls more than half the total network power, in which case it is called a 51% attack.[27]

ASICs and mining pools

Within the Bitcoin community there are groups working together in mining pools.[28] Some miners use application-specific integrated circuits (ASICs) for PoW.[29] This trend toward mining pools and specialized ASICs has made mining some cryptocurrencies economically infeasible for most players without access to the latest ASICs, nearby sources of inexpensive energy, or other special advantages.[30]

Some PoWs claim to be ASIC-resistant,[31] i.e. to limit the efficiency gain that an ASIC can have over commodity hardware, like a GPU, to be well under an order of magnitude. ASIC resistance has the advantage of keeping mining economically feasible on commodity hardware, but also contributes to the corresponding risk that an attacker can briefly rent access to a large amount of unspecialized commodity processing power to launch a 51% attack against a cryptocurrency.[32]

Environmental concerns

See also: Environmental impact of bitcoin. Miners compete to solve crypto challenges on the Bitcoin blockchain, and their solutions must be agreed upon by all nodes and reach consensus. The solutions are then used to validate transactions, add blocks and generate new bitcoins. Miners are rewarded for solving these puzzles and successfully adding new blocks. However, the Bitcoin-style mining process is very energy intensive because the proof of work shaped like a lottery mechanism. The underlying computational work has no other use but to provide security to the network that provides open access and has to work in adversarial conditions. Miners have to use a lot of energy to add a new block containing a transaction to the blockchain. The energy used in this competition is what fundamentally gives bitcoin its level of security and resistance to attacks. Also, miners have to invest computer hardwares that need large spaces as fixed cost.[33]

In January 2022 Vice-Chair of the European Securities and Markets Authority Erik Thedéen called on the EU to ban the proof of work model in favor of the proof of stake model due its lower energy emissions.[34]

In November 2022 the state of New York enacted a two-year moratorium on cryptocurrency mining that does not completely use renewable energy as a power source for two years. Existing mining companies will be grandfathered in to continue mining without the use of renewable energy but they will not be allowed to expand or renew permits with the state, no new mining companies that do not completely use renewable energy will not also not be allowed to begin mining.[35]

See also

Notes

External links

Notes and References

  1. Lachtar . Nada . Elkhail . Abdulrahman Abu . Bacha . Anys . Malik . Hafiz . 2020-07-01 . A Cross-Stack Approach Towards Defending Against Cryptojacking . IEEE Computer Architecture Letters . 19 . 2 . 126–129 . 10.1109/LCA.2020.3017457 . 222070383 . 1556-6056. free .
  2. Web site: RPOW - Reusable Proofs of Work . 2024-01-17 . nakamotoinstitute.org . 2023-06-19 . https://web.archive.org/web/20230619102132/https://nakamotoinstitute.org/finney/rpow/index.html . live .
  3. Web site: What Is Proof of Work (PoW) in Blockchain? . 2024-01-17 . Investopedia . en . 2024-01-17 . https://web.archive.org/web/20240117014743/https://www.investopedia.com/terms/p/proof-work.asp . live .
  4. Web site: July 2018 . Cryptocurrencies and blockchain . 29 October 2020 . . the two best-known – and in the context of cryptocurrencies also most commonly used . 27 June 2023 . https://web.archive.org/web/20230627212856/https://www.europarl.europa.eu/cmsdata/150761/TAX3%20Study%20on%20cryptocurrencies%20and%20blockchain.pdf . live .
  5. Web site: Proof of Work Explained in Simple Terms - The Chain Bulletin . 2023-04-01 . chainbulletin.com . en . 2023-04-01 . https://web.archive.org/web/20230401162119/https://chainbulletin.com/proof-of-work-explained-in-simple-terms . live .
  6. News: The Only Crypto Story You Need, by Matt Levine . en . Bloomberg.com . 2023-04-01 . 2023-04-07 . https://web.archive.org/web/20230407014836/https://www.bloomberg.com/features/2022-the-crypto-story/ . live .
  7. News: Kharif . Olga . Analysis Bye-Bye, Miners! How Ethereum's Big Change Will Work . 13 January 2022 . . . November 30, 2021 . 2 December 2021 . https://web.archive.org/web/20211202031349/https://www.washingtonpost.com/business/bye-bye-miners-how-ethereums-big-change-will-work/2021/11/30/234cabda-5201-11ec-83d2-d9dab0e23b7e_story.html . live .
  8. Web site: Back . Adam . August 2002 . Hashcash - A Denial of Service Counter-Measure .
  9. Ben . Laurie . Richard . Clayton . Proof-of-work proves not to work . Workshop on the Economics of Information Security 2004 . May 2004.
  10. Web site: Debin . Liu . L. Jean . Camp . Proof of Work can work - Fifth Workshop on the Economics of Information Security . June 2006 . 2015-12-29 . 2017-08-20 . https://web.archive.org/web/20170820195332/http://www.econinfosec.org/archive/weis2006/prog.html . live .
  11. http://wayback.vefsafn.is/wayback/20130721202930/http://downloadsquad.switched.com/2009/07/20/how-powerful-was-the-apollo-11-computer/ How powerful was the Apollo 11 computer?
  12. Book: Cynthia . Dwork . Cynthia Dwork . Moni . Naor . Advances in Cryptology — CRYPTO' 92 . Pricing via Processing or Combatting Junk Mail . Lecture Notes in Computer Science . 740 . Moni Naor . Springer . 1993 . 139–147 . http://www.wisdom.weizmann.ac.il/~naor/PAPERS/pvp.ps . 10.1007/3-540-48071-4_10 . 978-3-540-57340-1 . free . 2012-09-10 . 2017-11-26 . https://web.archive.org/web/20171126072840/http://www.wisdom.weizmann.ac.il/~naor/PAPERS/pvp.ps . live .
  13. Web site: Adam . Back . HashCash . 2005-03-02 . 2017-09-29 . https://web.archive.org/web/20170929102830/http://www.hashcash.org/ . live . A popular PoW system. First announced in March 1997.
  14. Gabber . Eran . Jakobsson . Markus . Matias . Yossi . Mayer . Alain J. . 1998 . Curbing junk e-mail via secure classification . Financial Cryptography.
  15. Xiao-Feng . Wang . Michael . Reiter . Defending against denial-of-service attacks with puzzle auctions . IEEE Symposium on Security and Privacy '03 . May 2003 . 2013-04-15 . 2016-03-03 . https://web.archive.org/web/20160303220133/http://cs.unc.edu/~reiter/papers/2003/SP.pdf . dead .
  16. Book: Matthew K. . Franklin . Matthew K. Franklin . Dahlia . Malkhi . Financial Cryptography . Auditable metering with lightweight security . Dahlia Malkhi . 1318 . 151–160 . 1997 . 10.1007/3-540-63594-7_75 . Lecture Notes in Computer Science . 978-3-540-63594-9 . registration . https://archive.org/details/financialcryptog0000fcco/page/151 . Updated version May 4, 1998.
  17. Ari . Juels . John . Brainard . Client puzzles: A cryptographic defense against connection depletion attacks . NDSS 99 . 1999 .
  18. Brent . Waters . Ari . Juels . John A. . Halderman . Edward W. . Felten . Edward Felten . New client puzzle outsourcing techniques for DoS resistance . 11th ACM Conference on Computer and Communications Security . 2004 . 2019-08-06 . 2021-04-21 . https://web.archive.org/web/20210421083218/https://www.cs.utexas.edu/~bwaters/publications/papers/outsource_paper.pdf . live .
  19. Martín . Abadi . Martín Abadi . Mike . Burrows . Mark . Manasse . Ted . Wobber . Moderately hard, memory-bound functions . 5 . 2 . 299–327 . 2005 .
  20. Book: Cynthia . Dwork . Cynthia Dwork . Andrew . Goldberg . Andrew V. Goldberg . Moni . Naor . Advances in Cryptology - CRYPTO 2003 . On Memory-Bound Functions for Fighting Spam . Moni Naor . 2729 . 426–444 . Springer . 2003. 10.1007/978-3-540-45146-4_25 . Lecture Notes in Computer Science . 978-3-540-40674-7 . free .
  21. Fabien . Coelho . Exponential memory-bound functions for proof of work protocols . Cryptology ePrint Archive, Report . 2005 . 2007-11-04 . 2018-04-09 . https://web.archive.org/web/20180409043045/https://eprint.iacr.org/2005/356 . live .
  22. Book: Tromp , John . Financial Cryptography and Data Security . Cuckoo Cycle: A Memory Bound Graph-Theoretic Proof-of-Work . https://eprint.iacr.org/2014/059.pdf . 8976 . Springer . 49–62 . 2015 . 10.1007/978-3-662-48051-9_4 . Lecture Notes in Computer Science . 978-3-662-48050-2 . 2015-09-30 . 2017-07-05 . https://web.archive.org/web/20170705204246/https://eprint.iacr.org/2014/059.pdf . live.
  23. Fabien . Coelho . An (almost) constant-effort solution-verification proof-of-work protocol based on Merkle trees . Cryptology ePrint Archive, Report . 2007 . 2007-11-25 . 2016-08-26 . https://web.archive.org/web/20160826093458/http://eprint.iacr.org/2007/433 . live.
  24. Book: Mehmud . Abliz . Taieb . Znati . 2009 Annual Computer Security Applications Conference . A Guided Tour Puzzle for Denial of Service Prevention . 279–288 . Honolulu, HI . December 2009 . 10.1109/ACSAC.2009.33 . 978-1-4244-5327-6 . 10.1.1.597.6304 . 14434713 .
  25. Web site: Fitzi . Matthias . Combinatorial Optimization via Proof-of-Useful-Work . 9 September 2022 . IACR conference Crypto 2022 . 9 September 2022 . https://web.archive.org/web/20220909071908/https://crypto.iacr.org/2022/papers/538804_1_En_12_Chapter_OnlinePDF.pdf . live .
  26. Web site: Cambridge Bitcoin Electricity Consumption Index . Cambridge Center For Alternative Finance . 30 September 2020 . 29 September 2020 . https://web.archive.org/web/20200929201811/https://cbeci.org/ . live .
  27. News: Michael J. Casey . Paul Vigna . Short-Term Fixes To Avert "51% Attack" . 30 June 2014 . Money Beat . Wall Street Journal . 16 June 2014 . 15 August 2020 . https://web.archive.org/web/20200815203333/https://blogs.wsj.com/moneybeat/2014/06/16/bitbeat-a-51-attack-what-is-it-and-could-it-happen/ . live .
  28. https://blockchain.info/pools Overview of the Bitcoin mining pools
  29. https://www.digitaltrends.com/computing/what-is-an-asic-miner/ What is an ASIC miner
  30. Web site: Vorick. David. The State of Cryptocurrency Mining. 13 May 2018. 28 October 2020. 10 March 2020. https://web.archive.org/web/20200310021448/https://blog.sia.tech/the-state-of-cryptocurrency-mining-538004a37f9b. live.
  31. https://github.com/tevador/randomx tevador/RandomX: Proof of work algorithm based on random code execution
  32. Cryptocurrency Value and 51% Attacks: Evidence from Event Studies. Savva Shanaev. Arina Shuraeva. Mikhail Vasenin. Maksim Kuznetsov. The Journal of Alternative Investments. 2019. 22. 3. 65–77. 10.3905/jai.2019.1.081. 211422987. 2020-10-28. 2021-02-06. https://web.archive.org/web/20210206092143/https://jai.pm-research.com/content/22/3/65.short. live.
  33. Ciaian . Pavel . Kancs . d’Artis . Rajcaniova . Miroslava . 2021-10-21 . The economic dependency of bitcoin security . Applied Economics . en . 53 . 49 . 5738–5755 . 10.1080/00036846.2021.1931003 . 231942439 . 0003-6846. free . 10419/251105 . free .
  34. Web site: Bateman. Tom. 2022-01-19. Ban proof of work crypto mining to save energy, EU regulator says. 2022-01-22. euronews. en. 2022-04-19. https://web.archive.org/web/20220419190031/https://www.euronews.com/next/2022/01/19/eu-regulator-calls-for-a-ban-on-proof-of-work-bitcoin-mining-to-save-renewable-energy. live.
  35. Web site: Sigalos . MacKenzie . New York governor signs first-of-its-kind law cracking down on bitcoin mining — here's everything that's in it . 2022-12-04 . CNBC . 23 November 2022 . en . 2022-12-03 . https://web.archive.org/web/20221203180017/https://www.cnbc.com/2022/11/23/new-york-governor-signs-law-cracking-down-on-bitcoin-mining.html . live .