Skip to content

Commit b662130

Browse files
committed
Add link to Opinioned Blockchain Reading List
1 parent 15d522e commit b662130

4 files changed

Lines changed: 101 additions & 39 deletions

File tree

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
Blockchain Tutorial
22
===================
33

4-
[![Join the chat at https://gitter.im/liuchengxu/blockchain-tutorial](https://badges.gitter.im/liuchengxu/blockchain-tutorial.svg)](https://gitter.im/liuchengxu/blockchain-tutorial?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
4+
<h1 align="center"><a href="https://github.com/liuchengxu/blockchain-tutorial/wiki">Opinioned Blockchain Reading List</a></h1>
5+
<p align="center">A collection of blockchain resources.</p>
6+
7+
Wiki 维护了一个阅读列表: [Opinioned Blockchain Reading List](https://github.com/liuchengxu/blockchain-tutorial/wiki), 我会整理一些值得阅读研究的资源,大部分是英文的,欢迎贡献对应的中文资源。
8+
9+
----
510

611
:point_right: [目录](content/SUMMARY.md)
712

content/blockchain-consensus-attacks.md

Lines changed: 0 additions & 38 deletions
This file was deleted.
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
# 区块链共识级别的攻击
2+
3+
## Double spending attacks
4+
5+
推翻已经确认的交易。
6+
7+
- persistence
8+
9+
## Grinding attacks
10+
11+
恶意节点试图影响 slot leader selection 的过程,加大自己被选中为 slot leader 的概率。
12+
13+
这种攻击主要是由于随机性来源于链本身的原始数据,比如块头和交易,恶意节点可以尝试多个可能成为 slot leader 的 block header。
14+
15+
## Transaction denial attacks
16+
17+
阻止一笔交易被确认。恶意节点监控某个特殊的账户,不让它发交易。
18+
19+
liveness
20+
21+
## Desynchronization attacks
22+
23+
诚实节点无法与网络同步。
24+
25+
## Eclipse attacks
26+
27+
## 51% attacks
28+
29+
## Bribery attacks
30+
31+
- Short Range attack
32+
33+
Long-Range attack + checkpoint = short range attack
34+
35+
## Long-range attacks
36+
37+
所谓长程攻击,指的是恶意节点试图从创世块开始对链进行分叉,分叉链可能或包含于主链不同的交易和块,因此也叫 **Alternative History** 或者 **History Revision** 攻击。Long Range, Alternative History, Alternate History, History Revision 在很多情况下是通用的概念。
38+
39+
长程攻击之所以存在的主要原因是 Weak Subjectivity。
40+
41+
### Weak Subjectivity
42+
43+
这个问题主要会影响刚刚加入到网络的新节点和长时间离线后重新加入的节点。
44+
45+
当一个新节点刚刚加入网络时,创世块肯定是有的,也是毫无争议的。但是除了创世块,节点还会看到目前有好几条链 -- 主链与分叉链,即使并非恶意分叉,PoW 在末端自身也极易分叉。然后,节点并不能从这些链中判断出哪个是主链。
46+
47+
长时间离线后重新加入的节点也是如此。PoS 也是最长链原则,拥有最多块数的叉将成为主链。在 PoW 中,要投入大量算力才能获取出块权,对于 PoW 来说,最长链十分有效。
48+
49+
在 PoW 中,除非遭受 51% 攻击,否则不可能从创世块开始分叉。要伪造跟主链同样长度的分叉,需要投入大量的算力。因此,最长链原则已经可以解决 Weak Subjectivity 问题。
50+
51+
### Costless Simulation
52+
53+
对于 PoS 来说,最长链就不够用了,因为这里又出现了一个叫 Costless Simulation 的问题。PoS 的验证人不需要像矿工一样必须要进行大量计算,验证人只需要从交易池中取出交易,打包入块,最后广播出去。因此伪造跟主链一样长的链,毫无成本可言。
54+
55+
Weak Subjectivity 加上 Costless Simulation 导致最长链原则对 PoS 不再适用,长程攻击由此产生。
56+
57+
### Long Range Attacks
58+
59+
1. simple
60+
2. posterior corruption ==> Key Evolving Signature Scheme
61+
3. stake bleeding
62+
63+
- https://blog.positive.com/rewriting-history-a-brief-introduction-to-long-range-attacks-54e473acdba9
64+
- [Stake-Bleeding Attacks on Proof-of-Stake Blockchains](https://eprint.iacr.org/2018/248.pdf)
65+
66+
## Nothing at stake attacks
67+
68+
当发生分叉时,验证人的最优策略是承认每一条分叉,并在所有分叉上继续挖。这样无论哪一条叉最终胜出,验证人都能获得奖励。
69+
70+
- https://en.wikipedia.org/wiki/Proof-of-stake
71+
- https://blog.goldmint.io/nothing-at-stake-and-longrange-attack-in-pos-4ec486f1fc89
72+
- https://github.com/ethereum/wiki/wiki/Problems
73+
- https://pivx.org/nothing-considered-a-look-at-nothing-at-stake-vulnerability-for-cryptocurrencies/
74+
- https://medium.com/@abhisharm/understanding-proof-of-stake-through-its-flaws-part-2-nothing-s-at-stake-8d12d826956c
75+
- https://medium.com/coinmonks/understanding-proof-of-stake-the-nothing-at-stake-theory-1f0d71bc027
76+
77+
## Past majority attacks
78+
79+
nothing at stake 的一种特殊情况。
80+
81+
## Selfish-mining
82+
83+
自私挖矿,恶意挖到块以后,并不广播出去,而是偷偷藏在手里,然后继续挖。当监听到有节点挖出同样高度的块时,迅速将手里的块广播出去,如果恶意节点的网络更好, 那么恶意节点手中同高度的块就会被接受,如此一来,恶意节点就会更有优势挖到下面的块。
84+
85+
## Reference
86+
87+
- Ouroboros

content/solidity.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Solidity
2+
3+
- [Anonymous function in Solidity example code](https://ethereum.stackexchange.com/questions/24439/anonymous-function-in-solidity-example-code)
4+
5+
- [What is an Event?](https://ethereum.stackexchange.com/questions/11228/what-is-an-event)
6+
- [eth_newfilter](https://wiki.parity.io/JSONRPC-eth-module.html#eth_newfilter)
7+
- [Where do contract event logs get stored in the Ethereum architecture?](https://ethereum.stackexchange.com/questions/1302/where-do-contract-event-logs-get-stored-in-the-ethereum-architecture)
8+
- [How to implement events in solidity](https://ethereum.stackexchange.com/questions/2654/how-to-implement-events-in-solidity)

0 commit comments

Comments
 (0)