Introduction to Blockchain
Lecture 2: Cryptographic Hash Function (Example: SHA256)$\sum$指所有可能出现的字符. $\sum^* = \sum^0 \cup \sum^1 \cup …$。上面的数字指的是字符序列长度
$f: \sum^* \rightarrow \sum^n$ map from infinite to finite
Hash function characteristic:
Collision-resistance: It is hard to find $x, y \in \sum^*$, s.t., $x \neq y$ and $f(x) = f(y)$
Hiding: Given a hash value $h$, it is hard to find same $x$ s.t. $f(x) = h$
Puzzle friendliness
Problem: Finding Files
I have huge files $F_1, F_2, …, F_n$. Given a new file, find i ...