You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: security/fma-multi-threaded-64-bit-cannon.md
+23-23Lines changed: 23 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -54,42 +54,42 @@ This document covers the conversion of the [Cannon Fault Proof VM](https://docs.
54
54
### Unimplemented syscalls or opcodes needed by `op-program`
55
55
56
56
-**Description:** We only aim to implement syscalls and opcodes that are required by `op-program` so there are some unimplemented. The risk is that there is some previously untested code path that uses an opcode or syscall that we haven't implemented and this code path ends up being exercised by an input condition some time in the future.
57
-
-**Risk Assessment:***Simple low/medium/high rating of impact (severity) + likelihood.*
58
-
-**Mitigations:***What mitigations are in place, or what should we add, to reduce the chance of this occurring?*
59
-
-**Detection:***How do we detect if this occurs?*
60
-
-**Recovery Path(s)**: *How do we resolve this? Is it a simple, quick recovery or a big effort? Would recovery require a governance vote or a hard fork?*
-**Mitigations:**We periodically use Cannon to execute the op-program using inputs from op-mainnet and op-sepolia. This periodic cannon runner (vm-runner) runs on oplabs infrastructure.
59
+
-**Detection:**Alerting is setup to notify the proofs team whenever the vm-runner fails to complete a cannon run.
60
+
-**Recovery Path(s)**: See [Fault Proof Recovery](https://www.notion.so/oplabs/RB-000-Fault-Proofs-Recovery-Runbook-8dad0f1e6d4644c281b0e946c89f345f).
61
61
62
62
### Failure to run correct VM based on prestate input
63
63
64
-
-**Description:** The off-chain Cannon [attempts to run the correct VM version based on the prestate input](https://github.com/ethereum-optimism/design-docs/pull/88/files). If it doesn't work correctly the on-chain steps would not match.
65
-
-**Risk Assessment:***Simple low/medium/high rating of impact (severity) + likelihood.*
66
-
-**Mitigations:***What mitigations are in place, or what should we add, to reduce the chance of this occurring?*
67
-
-**Detection:***How do we detect if this occurs?*
68
-
-**Recovery Path(s)**: *How do we resolve this? Is it a simple, quick recovery or a big effort? Would recovery require a governance vote or a hard fork?*
64
+
-**Description:** The off-chain Cannon [attempts to run the correct VM version based on the prestate input](https://github.com/ethereum-optimism/design-docs/blob/0034943e42b8ab5f9dd9ded2ef2b6b55359c922c/cannon-state-versioning.md). If it doesn't work correctly the on-chain steps would not match.
-**Mitigations:**Multicannon mitigates this issue by embedding a variety of cannon STFs into a single binary. This shifts the concern of ensuring the correct VM selection to multicannon. We also run multicannon on oplabs infra via the vm-runner, to assert the multicannon binary was built correctly.
67
+
-**Detection:**This can be detected by manual review. Failing that, it would only be detected when malicious activity occurs and an honest op-challenger fails to generate a fault proof.
68
+
-**Recovery Path(s)**: Fix the op-challenger multicannon configuration.
69
69
70
70
### Mismatch between on-chain and off-chain execution
71
71
72
72
-**Description:** There could be bugs in the implementation of either the Solidity or Go versions that make them incompatible with each other.
73
-
-**Risk Assessment:***Simple low/medium/high rating of impact (severity) + likelihood.*
74
-
-**Mitigations:***What mitigations are in place, or what should we add, to reduce the chance of this occurring?*
-**Mitigations:**Diffeerential testing asserts identical on-chain and off-chain execution. A third-party audit (in progress) review of both VMs.
75
75
-**Detection:***How do we detect if this occurs?*
76
-
-**Recovery Path(s)**: *How do we resolve this? Is it a simple, quick recovery or a big effort? Would recovery require a governance vote or a hard fork?*
76
+
-**Recovery Path(s)**: Depends on the specifics. If the onchain VM implementation is "more correct", then fixing this can be done solely offchain. Otherwise, a governance vote will be needed. As usual, the [Fault Proof Recovery](https://www.notion.so/oplabs/RB-000-Fault-Proofs-Recovery-Runbook-8dad0f1e6d4644c281b0e946c89f345f) provides the best guidance on this.
77
77
78
78
### Livelocks in the fault proof
79
79
80
-
-**Description:***Details of the failure mode go here. What the causes and effects of this failure?*
81
-
-**Risk Assessment:***Simple low/medium/high rating of impact (severity) + likelihood.*
82
-
-**Mitigations:***What mitigations are in place, or what should we add, to reduce the chance of this occurring?*
83
-
-**Detection:***How do we detect if this occurs?*
84
-
-**Recovery Path(s)**: *How do we resolve this? Is it a simple, quick recovery or a big effort? Would recovery require a governance vote or a hard fork?*
80
+
-**Description:**A livelocked execution prevents an honest challenger from generating a fault proof.
-**Mitigations:**Manual review of the op-program and a quick review of Go runtime internals. The op-program uses 3 threads, and only one of those threads are used by the mutator main function. This makes livelocks very unlikely.
83
+
-**Detection:**This would manifest as an execution that runs forever. Eventually, but well before the dispute period ends, op-dispute-mon will indicate that a game is forecasted to resolve incorrectly.
84
+
-**Recovery Path(s)**: See [Fault Proof Recovery](https://www.notion.so/oplabs/RB-000-Fault-Proofs-Recovery-Runbook-8dad0f1e6d4644c281b0e946c89f345f).
85
85
86
86
### Execution traces too long for the fault proof
87
87
88
-
-**Description:***Details of the failure mode go here. What the causes and effects of this failure?*
89
-
-**Risk Assessment:***Simple low/medium/high rating of impact (severity) + likelihood.*
90
-
-**Mitigations:***What mitigations are in place, or what should we add, to reduce the chance of this occurring?*
91
-
-**Detection:***How do we detect if this occurs?*
92
-
-**Recovery Path(s)**: *How do we resolve this? Is it a simple, quick recovery or a big effort? Would recovery require a governance vote or a hard fork?*
88
+
-**Description:**It's possible that introducing multi-threading/gc greatly increases the execution time of the op-program.
-**Mitigations:**Based on vm-runner executions of 64-bit Cannon and 32-bit singlethreaded cannon, the 64-bit VM executes the op-program much faster than the 32-bit VM. However, we can always use CPUs with beefier single-core performance to mitigate.
91
+
-**Detection:**op-dispute-mon notifies proofs team if the op-challenger stops interacting with a game.
92
+
-**Recovery Path(s)**: By migrating the op-challenger to a beefier CPU. [Fault Proof Recovery](https://www.notion.so/oplabs/RB-000-Fault-Proofs-Recovery-Runbook-8dad0f1e6d4644c281b0e946c89f345f) provides guidance on when it'll be appropriate to do so.
93
93
94
94
### [Name of Failure Mode]
95
95
@@ -110,7 +110,7 @@ See [./fma-generic-hardfork.md](./fma-generic-hardfork.md).
110
110
111
111
Below is what needs to be done before launch to reduce the chances of the above failure modes occurring, and to ensure they can be detected and recovered from:
112
112
113
-
-[ ]Resolve all comments on this document and incorporate them into the document itself (Assignee: document author)
113
+
-[ ]Third-party audit the offchain and onchain VM implementation and specification (Assignee: document author)
0 commit comments