Bitcoin: A Peer-to-Peer Electronic Cash System

64 阅读4分钟

bitcoin.org/bitcoin.pdf

Abstract

使用p2p网络来解决双花; 通过将网络时间戳交易哈希到一个正在运行的链里,形成一个无法篡改的记录,除非再做一遍proof-of-work; 最长的链不仅是已发生事件证明,同时是最强CPU算力的证明,只要大多数的CPU不是被攻击者控制,他们就会产生最长链并且抵御攻击者,网络自身需要很少的结构。信息尽最大努力广播。

Introduction

需要一种新的基于加密验证而不是信任的支付体系,使得交易双方可以直接交易而不需要权威第三方机构。 本文采用P2P分布式时间戳服务器,提出了一种防止双花的解决方式。只要诚实的节点CPU算力比攻击者节点算力大,系统就是安全的。

Transaction

每个货币的拥有者通过 给前一个交易的哈希签名 签下一个拥有者的公钥 。 收款人能验证签名。 我们需要一种方式能让收款人知道付款方没有签其他交易。我们的目的是,最早的交易时有效的,那么后续的双花我们无需关注。 交易需要向公众进行广播,我们需要让参与者在独一无二的历史顺序上实现共识

收款方需要去证明每个交易到达的时候,大多数节点都认可它是第一次到达。

Timestamp Server

首先有个时间戳服务器。 时间戳证明数据在这个时候已经存在了。 每个时间戳包括之前的时间戳,形成一个链,逐步强化。

Proof-of-work

As later blocks are chained after it, the work to change the block would include redoing all the blocks after it. 需要重做从当前链往后的所有块-the longest chain

NetWork

新交易被广播到所有节点。 每个节点将新交易放在一个区块里。 每一个节点做proof-of-work。 当一个节点完成proof-of-work, 广播这个区块给所有节点。 只有一个区块里的所有交易都是有效并且不存在双花,节点们才接受区块。 节点们以接受了的区块为基础,开始挖下一个块。

如果两个节点广播了几乎同时不同的区块,其他节点可能收到这两个区块里的任意一个,这种情况下,他们会沿着他们第一个收到的区块继续工作,同时保留另外一个区块的分支,以防他变成更长的链。

Incentive

出块奖励和交易费

Reclaiming Disk Space

Merkle Tree: 只有跟根包含在区块里的哈希里。

Simplified Payment Verification

不用运行所有的网络节点也可以去验证支付。用户仅仅需要最长链保存区块头的副本。它可以通过咨询网络结点,然后获取Merkle分支。他不能自己检验交易,但是通过连接这个交易到链的某处 ,他可以看到网络节点已经接受。??

因此,只要诚实的节点控制着网络,验证就是可信的。

Combining and Spliting Value

一个交易包括多个输入和输出。正常情况下,将会有一个来自更大前置交易的单个输出或者多个小输入,一般至多两个输出,一个用来支付,一个用来找零。如果还有的话,就返给发送者。

Privacy

The public can see that someone is sending an amount to someone else, but without information linking the transaction to anyone. As an additional firewall, a new key pair should be used for each transaction to keep them from being linked to a common owner.

  • 公钥不和个人信息进行管理(不实名认证)。
  • 每一笔交易使用不同的公私钥对。

Calculations

没看懂

Conclusion

We have proposed a system for electronic transactions without relying on trust. We started with the usual framework of coins made from digital signatures, which provides strong control of ownership, but is incomplete without a way to prevent double-spending. To solve this, we proposed a peer-to-peer network using proof-of-work to record a public history of transactions that quickly becomes computationally impractical for an attacker to change if honest nodes control a majority of CPU power. The network is robust in its unstructured simplicity. Nodes work all at once with little coordination. They do not need to be identified, since messages are not routed to any particular place and only need to be delivered on a best effort basis. Nodes can leave and rejoin the network at will, accepting the proof-of-work chain as proof of what happened while they were gone. They vote with their CPU power, expressing their acceptance of valid blocks by working on extending them and rejecting invalid blocks by refusing to work on them. Any needed rules and incentives can be enforced with this consensus mechanism.

  • 我们提出了一个不基于信任的电子交易系统。我们通过数字签名确保了归属权问题。通过p2p网络和pow来记录交易历史。它保证了如果大部分发的CPU算力掌握在诚实的节点手中,就可以抵抗攻击。