An elliptic curve \(E\) is the graph of an equation of the form \(y^2=x^3+Ax+B\), where \(A\) and \(B\) are constants. This will be referred to as the Weierstraß equation for an elliptic curve. We will need to specify what set \(A,B,x\) and \(y\) belong to. Usually, they will be taken to be elements of a field, for example, the real numbers \(\mathbb R\), the complex numbers \(\mathbb C\), the rational numbers \(\mathbb Q\), one of the finite fields \(\mathbb F_p(=\mathbb Z/p\mathbb Z)\) for a prime \(p\), or one of the finite fields \(\mathbb F_q\), where \(q=p^k\) with \(k\geq 1\). If \(K\) is a field with \(A,B\in K\), then we say that \(E\) is defined over \(K\).
Why it works? \[f(aP+bQ)=f(aP+b\color{red}x\color{black}P)=f(\frac{h+\color{red}x\color{blue}r\color{black}}{s}P)=f(kP)\]
opcode | mnemonic | description |
---|---|---|
0x01–0x4b | push next opcode bytes of data | |
0x69 | OP_VERIFY | if (pop() != true) then fail |
0x76 | OP_DUP | let x := pop() in push(x) push(x) |
0x87 | OP_EQUAL | push(pop() == pop()) |
0x88 | OP_EQUALVERIFY | = OP_EQUAL OP_VERIFY |
0xa9 | OP_HASH160 | push(RIPEND160(SHA256(pop()))) |
0xac | OP_CHECKSIG | verify signature |
contract NameRegistry {
mapping(bytes32 => address) public registryTable;
function claimName(bytes32 name) {
if (msg.value < 10) {
throw;
}
if (registryTable[name] == 0) {
registryTable[name] = msg.sender;
}
}
}