Commit 73d5902c authored by mergify[bot]'s avatar mergify[bot] Committed by GitHub

Merge branch 'develop' into dependabot/go_modules/golang.org/x/term-0.12.0

parents ec3c1772 e984fe56
......@@ -56,8 +56,9 @@ def main():
deployment_dir = pjoin(contracts_bedrock_dir, 'deployments', 'devnetL1')
op_node_dir = pjoin(args.monorepo_dir, 'op-node')
ops_bedrock_dir = pjoin(monorepo_dir, 'ops-bedrock')
deploy_config_dir = pjoin(contracts_bedrock_dir, 'deploy-config'),
devnet_config_path = pjoin(contracts_bedrock_dir, 'deploy-config', 'devnetL1.json')
deploy_config_dir = pjoin(contracts_bedrock_dir, 'deploy-config')
devnet_config_path = pjoin(deploy_config_dir, 'devnetL1.json')
devnet_config_template_path = pjoin(deploy_config_dir, 'devnetL1-template.json')
ops_chain_ops = pjoin(monorepo_dir, 'op-chain-ops')
sdk_dir = pjoin(monorepo_dir, 'packages', 'sdk')
......@@ -69,6 +70,7 @@ def main():
l1_deployments_path=pjoin(deployment_dir, '.deploy'),
deploy_config_dir=deploy_config_dir,
devnet_config_path=devnet_config_path,
devnet_config_template_path=devnet_config_template_path,
op_node_dir=op_node_dir,
ops_bedrock_dir=ops_bedrock_dir,
ops_chain_ops=ops_chain_ops,
......@@ -124,10 +126,16 @@ def deploy_contracts(paths):
'--rpc-url', 'http://127.0.0.1:8545'
], env={}, cwd=paths.contracts_bedrock_dir)
def init_devnet_l1_deploy_config(paths, update_timestamp=False):
deploy_config = read_json(paths.devnet_config_template_path)
if update_timestamp:
deploy_config['l1GenesisBlockTimestamp'] = '{:#x}'.format(int(time.time()))
write_json(paths.devnet_config_path, deploy_config)
def devnet_l1_genesis(paths):
log.info('Generating L1 genesis state')
init_devnet_l1_deploy_config(paths)
geth = subprocess.Popen([
'geth', '--dev', '--http', '--http.api', 'eth,debug',
'--verbosity', '4', '--gcmode', 'archive', '--dev.gaslimit', '30000000'
......@@ -157,13 +165,13 @@ def devnet_deploy(paths):
if os.path.exists(paths.allocs_path) == False:
devnet_l1_genesis(paths)
devnet_config_backup = pjoin(paths.devnet_dir, 'devnetL1.json.bak')
shutil.copy(paths.devnet_config_path, devnet_config_backup)
deploy_config = read_json(paths.devnet_config_path)
deploy_config['l1GenesisBlockTimestamp'] = '{:#x}'.format(int(time.time()))
write_json(paths.devnet_config_path, deploy_config)
# It's odd that we want to regenerate the devnetL1.json file with
# an updated timestamp different than the one used in the devnet_l1_genesis
# function. But, without it, CI flakes on this test rather consistently.
# If someone reads this comment and understands why this is being done, please
# update this comment to explain.
init_devnet_l1_deploy_config(paths, update_timestamp=True)
outfile_l1 = pjoin(paths.devnet_dir, 'genesis-l1.json')
run_command([
'go', 'run', 'cmd/main.go', 'genesis', 'l1',
'--deploy-config', paths.devnet_config_path,
......
......@@ -9,7 +9,6 @@ import (
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
"github.com/urfave/cli/v2"
......@@ -331,12 +330,18 @@ func Run(ctx *cli.Context) error {
}
if proofAt(state) {
preStateHash := crypto.Keccak256Hash(state.EncodeWitness())
preStateHash, err := state.EncodeWitness().StateHash()
if err != nil {
return fmt.Errorf("failed to hash prestate witness: %w", err)
}
witness, err := stepFn(true)
if err != nil {
return fmt.Errorf("failed at proof-gen step %d (PC: %08x): %w", step, state.PC, err)
}
postStateHash := crypto.Keccak256Hash(state.EncodeWitness())
postStateHash, err := state.EncodeWitness().StateHash()
if err != nil {
return fmt.Errorf("failed to hash poststate witness: %w", err)
}
proof := &Proof{
Step: step,
Pre: preStateHash,
......
......@@ -5,7 +5,6 @@ import (
"os"
"github.com/ethereum-optimism/optimism/cannon/mipsevm"
"github.com/ethereum/go-ethereum/crypto"
"github.com/urfave/cli/v2"
)
......@@ -31,7 +30,10 @@ func Witness(ctx *cli.Context) error {
return fmt.Errorf("invalid input state (%v): %w", input, err)
}
witness := state.EncodeWitness()
h := crypto.Keccak256Hash(witness)
h, err := witness.StateHash()
if err != nil {
return fmt.Errorf("failed to compute witness hash: %w", err)
}
if output != "" {
if err := os.WriteFile(output, witness, 0755); err != nil {
return fmt.Errorf("writing output to %v: %w", output, err)
......
......@@ -15,7 +15,6 @@ import (
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/core/state"
"github.com/ethereum/go-ethereum/core/vm"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/eth/tracers/logger"
"github.com/stretchr/testify/require"
......@@ -92,7 +91,10 @@ func (m *MIPSEVM) Step(t *testing.T, stepWitness *StepWitness) []byte {
logs := m.evmState.Logs()
require.Equal(t, 1, len(logs), "expecting a log with post-state")
evmPost := logs[0].Data
require.Equal(t, crypto.Keccak256Hash(evmPost), postHash, "logged state must be accurate")
stateHash, err := StateWitness(evmPost).StateHash()
require.NoError(t, err, "state hash could not be computed")
require.Equal(t, stateHash, postHash, "logged state must be accurate")
m.env.StateDB.RevertToSnapshot(snap)
t.Logf("EVM step took %d gas, and returned stateHash %s", startingGas-leftOverGas, postHash)
......
......@@ -2,11 +2,16 @@ package mipsevm
import (
"encoding/binary"
"fmt"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/crypto"
)
// StateWitnessSize is the size of the state witness encoding in bytes.
var StateWitnessSize = 226
type State struct {
Memory *Memory `json:"memory"`
......@@ -37,7 +42,11 @@ type State struct {
LastHint hexutil.Bytes `json:"lastHint,omitempty"`
}
func (s *State) EncodeWitness() []byte {
func (s *State) VMStatus() uint8 {
return vmStatus(s.Exited, s.ExitCode)
}
func (s *State) EncodeWitness() StateWitness {
out := make([]byte, 0)
memRoot := s.Memory.MerkleRoot()
out = append(out, memRoot[:]...)
......@@ -60,3 +69,41 @@ func (s *State) EncodeWitness() []byte {
}
return out
}
type StateWitness []byte
const (
VMStatusValid = 0
VMStatusInvalid = 1
VMStatusPanic = 2
VMStatusUnfinished = 3
)
func (sw StateWitness) StateHash() (common.Hash, error) {
if len(sw) != 226 {
return common.Hash{}, fmt.Errorf("Invalid witness length. Got %d, expected at least 88", len(sw))
}
hash := crypto.Keccak256Hash(sw)
offset := 32*2 + 4*6
exitCode := sw[offset]
exited := sw[offset+1]
status := vmStatus(exited == 1, exitCode)
hash[0] = status
return hash, nil
}
func vmStatus(exited bool, exitCode uint8) uint8 {
if !exited {
return VMStatusUnfinished
}
switch exitCode {
case 0:
return VMStatusValid
case 1:
return VMStatusInvalid
default:
return VMStatusPanic
}
}
......@@ -82,6 +82,53 @@ func TestState(t *testing.T) {
}
}
// Run through all permutations of `exited` / `exitCode` and ensure that the
// correct witness, state hash, and VM Status is produced.
func TestStateHash(t *testing.T) {
cases := []struct {
exited bool
exitCode uint8
}{
{exited: false, exitCode: 0},
{exited: false, exitCode: 1},
{exited: false, exitCode: 2},
{exited: false, exitCode: 3},
{exited: true, exitCode: 0},
{exited: true, exitCode: 1},
{exited: true, exitCode: 2},
{exited: true, exitCode: 3},
}
exitedOffset := 32*2 + 4*6
for _, c := range cases {
state := &State{
Memory: NewMemory(),
Exited: c.exited,
ExitCode: c.exitCode,
}
actualWitness := state.EncodeWitness()
actualStateHash, err := StateWitness(actualWitness).StateHash()
require.NoError(t, err, "Error hashing witness")
require.Equal(t, len(actualWitness), StateWitnessSize, "Incorrect witness size")
expectedWitness := make(StateWitness, 226)
memRoot := state.Memory.MerkleRoot()
copy(expectedWitness[:32], memRoot[:])
expectedWitness[exitedOffset] = c.exitCode
var exited uint8
if c.exited {
exited = 1
}
expectedWitness[exitedOffset+1] = uint8(exited)
require.Equal(t, expectedWitness[:], actualWitness[:], "Incorrect witness")
expectedStateHash := crypto.Keccak256Hash(actualWitness)
expectedStateHash[0] = vmStatus(c.exited, c.exitCode)
require.Equal(t, expectedStateHash, actualStateHash, "Incorrect state hash")
}
}
func TestHello(t *testing.T) {
elfProgram, err := elf.Open("../example/bin/hello.elf")
require.NoError(t, err, "open ELF file")
......
......@@ -14,3 +14,4 @@ finalized and may change without notice.
* [Manual Usage](./manual.md)
* [Creating Traces with Cannon](./cannon.md)
* [Automation with `op-challenger`](./run-challenger.md)
* [Challenging Invalid Output Proposals](./invalid-proposals.md)
## Challenging Invalid Output Proposals
The dispute game factory deployed to Goerli reads from the permissioned L2 Output Oracle contract. This restricts games
to challenging valid output proposals and an honest challenger should win every game. To test creating games that
challenge an invalid output proposal, a custom chain is required. The simplest way to do this is using the end-to-end
test utilities in [`op-e2e`](https://github.com/ethereum-optimism/optimism/tree/develop/op-e2e).
A simple starting point has been provided in the `TestCannonProposedOutputRootInvalid` test case
in [`faultproof_test.go`](https://github.com/ethereum-optimism/optimism/blob/6e174ae2b2587d9ac5e2930d7574f85d254ca8b4/op-e2e/faultproof_test.go#L334).
This is a table test that takes the output root to propose, plus functions for move and step to counter the honest
claims. The test asserts that the defender always wins and thus the output root is found to be invalid.
......@@ -120,12 +120,12 @@ func LoadConfig(logger geth_log.Logger, path string) (Config, error) {
}
if conf.Chain.Preset != 0 {
knownContracts, ok := presetL1Contracts[conf.Chain.Preset]
if ok {
conf.Chain.L1Contracts = knownContracts
} else {
knownPreset, ok := presetConfigs[conf.Chain.Preset]
if !ok {
return conf, fmt.Errorf("unknown preset: %d", conf.Chain.Preset)
}
conf.Chain.L1Contracts = knownPreset.L1Contracts
conf.Chain.L1StartingHeight = knownPreset.L1StartingHeight
}
// Set polling defaults if not set
......
......@@ -54,10 +54,10 @@ func TestLoadConfig(t *testing.T) {
require.NoError(t, err)
require.Equal(t, conf.Chain.Preset, 420)
require.Equal(t, conf.Chain.L1Contracts.OptimismPortalProxy.String(), presetL1Contracts[420].OptimismPortalProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L1CrossDomainMessengerProxy.String(), presetL1Contracts[420].L1CrossDomainMessengerProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L1StandardBridgeProxy.String(), presetL1Contracts[420].L1StandardBridgeProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L2OutputOracleProxy.String(), presetL1Contracts[420].L2OutputOracleProxy.String())
require.Equal(t, conf.Chain.L1Contracts.OptimismPortalProxy.String(), presetConfigs[420].L1Contracts.OptimismPortalProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L1CrossDomainMessengerProxy.String(), presetConfigs[420].L1Contracts.L1CrossDomainMessengerProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L1StandardBridgeProxy.String(), presetConfigs[420].L1Contracts.L1StandardBridgeProxy.String())
require.Equal(t, conf.Chain.L1Contracts.L2OutputOracleProxy.String(), presetConfigs[420].L1Contracts.L2OutputOracleProxy.String())
require.Equal(t, conf.RPCs.L1RPC, "https://l1.example.com")
require.Equal(t, conf.RPCs.L2RPC, "https://l2.example.com")
require.Equal(t, conf.DB.Host, "127.0.0.1")
......
......@@ -5,49 +5,67 @@ import (
)
// in future presets can just be onchain config and fetched on initialization
// Mapping of l2 chain ids to their preset chain configurations
var presetL1Contracts = map[int]L1Contracts{
var presetConfigs = map[int]ChainConfig{
// OP Mainnet
10: {
OptimismPortalProxy: common.HexToAddress("0xbEb5Fc579115071764c7423A4f12eDde41f106Ed"),
L2OutputOracleProxy: common.HexToAddress("0xdfe97868233d1aa22e815a266982f2cf17685a27"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1"),
L1StandardBridgeProxy: common.HexToAddress("0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0xbEb5Fc579115071764c7423A4f12eDde41f106Ed"),
L2OutputOracleProxy: common.HexToAddress("0xdfe97868233d1aa22e815a266982f2cf17685a27"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1"),
L1StandardBridgeProxy: common.HexToAddress("0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1"),
// LegacyCanonicalTransactionChain: common.HexToAddress("0x5e4e65926ba27467555eb562121fac00d24e9dd2"),
},
L1StartingHeight: 13596466,
},
// OP Goerli
420: {
OptimismPortalProxy: common.HexToAddress("0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383"),
L2OutputOracleProxy: common.HexToAddress("0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x5086d1eEF304eb5284A0f6720f79403b4e9bE294"),
L1StandardBridgeProxy: common.HexToAddress("0x636Af16bf2f682dD3109e60102b8E1A089FedAa8"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383"),
L2OutputOracleProxy: common.HexToAddress("0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x5086d1eEF304eb5284A0f6720f79403b4e9bE294"),
L1StandardBridgeProxy: common.HexToAddress("0x636Af16bf2f682dD3109e60102b8E1A089FedAa8"),
},
L1StartingHeight: 7017096,
},
// Base Mainnet
8453: {
OptimismPortalProxy: common.HexToAddress("0x49048044D57e1C92A77f79988d21Fa8fAF74E97e"),
L2OutputOracleProxy: common.HexToAddress("0x56315b90c40730925ec5485cf004d835058518A0"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x866E82a600A1414e583f7F13623F1aC5d58b0Afa"),
L1StandardBridgeProxy: common.HexToAddress("0x3154Cf16ccdb4C6d922629664174b904d80F2C35"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0x49048044D57e1C92A77f79988d21Fa8fAF74E97e"),
L2OutputOracleProxy: common.HexToAddress("0x56315b90c40730925ec5485cf004d835058518A0"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x866E82a600A1414e583f7F13623F1aC5d58b0Afa"),
L1StandardBridgeProxy: common.HexToAddress("0x3154Cf16ccdb4C6d922629664174b904d80F2C35"),
},
L1StartingHeight: 17481768,
},
// Base Goerli
84531: {
OptimismPortalProxy: common.HexToAddress("0xe93c8cD0D409341205A592f8c4Ac1A5fe5585cfA"),
L2OutputOracleProxy: common.HexToAddress("0x2A35891ff30313CcFa6CE88dcf3858bb075A2298"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x8e5693140eA606bcEB98761d9beB1BC87383706D"),
L1StandardBridgeProxy: common.HexToAddress("0xfA6D8Ee5BE770F84FC001D098C4bD604Fe01284a"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0xe93c8cD0D409341205A592f8c4Ac1A5fe5585cfA"),
L2OutputOracleProxy: common.HexToAddress("0x2A35891ff30313CcFa6CE88dcf3858bb075A2298"),
L1CrossDomainMessengerProxy: common.HexToAddress("0x8e5693140eA606bcEB98761d9beB1BC87383706D"),
L1StandardBridgeProxy: common.HexToAddress("0xfA6D8Ee5BE770F84FC001D098C4bD604Fe01284a"),
},
L1StartingHeight: 8410981,
},
// Zora mainnet
7777777: {
OptimismPortalProxy: common.HexToAddress("0x1a0ad011913A150f69f6A19DF447A0CfD9551054"),
L2OutputOracleProxy: common.HexToAddress("0x9E6204F750cD866b299594e2aC9eA824E2e5f95c"),
L1CrossDomainMessengerProxy: common.HexToAddress("0xdC40a14d9abd6F410226f1E6de71aE03441ca506"),
L1StandardBridgeProxy: common.HexToAddress("0x3e2Ea9B92B7E48A52296fD261dc26fd995284631"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0x1a0ad011913A150f69f6A19DF447A0CfD9551054"),
L2OutputOracleProxy: common.HexToAddress("0x9E6204F750cD866b299594e2aC9eA824E2e5f95c"),
L1CrossDomainMessengerProxy: common.HexToAddress("0xdC40a14d9abd6F410226f1E6de71aE03441ca506"),
L1StandardBridgeProxy: common.HexToAddress("0x3e2Ea9B92B7E48A52296fD261dc26fd995284631"),
},
L1StartingHeight: 17473923,
},
// Zora goerli
999: {
OptimismPortalProxy: common.HexToAddress("0xDb9F51790365e7dc196e7D072728df39Be958ACe"),
L2OutputOracleProxy: common.HexToAddress("0xdD292C9eEd00f6A32Ff5245d0BCd7f2a15f24e00"),
L1CrossDomainMessengerProxy: common.HexToAddress("0xD87342e16352D33170557A7dA1e5fB966a60FafC"),
L1StandardBridgeProxy: common.HexToAddress("0x7CC09AC2452D6555d5e0C213Ab9E2d44eFbFc956"),
L1Contracts: L1Contracts{
OptimismPortalProxy: common.HexToAddress("0xDb9F51790365e7dc196e7D072728df39Be958ACe"),
L2OutputOracleProxy: common.HexToAddress("0xdD292C9eEd00f6A32Ff5245d0BCd7f2a15f24e00"),
L1CrossDomainMessengerProxy: common.HexToAddress("0xD87342e16352D33170557A7dA1e5fB966a60FafC"),
L1StandardBridgeProxy: common.HexToAddress("0x7CC09AC2452D6555d5e0C213Ab9E2d44eFbFc956"),
},
L1StartingHeight: 8942381,
},
}
......@@ -3,7 +3,7 @@
[chain]
# OP Goerli
preset = 420
preset = $INDEXER_CHAIN_PRESET
# L1 Config
l1-polling-interval = 0
......
......@@ -4,7 +4,7 @@ generator client {
datasource db {
provider = "postgresql"
url = "postgresql://db_username:db_password@localhost:5434/db_name"
url = env("DATABASE_URL")
}
model l1_bridged_tokens {
......@@ -111,7 +111,7 @@ model l2_block_headers {
hash String @id @db.VarChar
parent_hash String @unique @db.VarChar
number Decimal @unique @db.Decimal
timestamp Int @unique
timestamp Int
rlp_bytes String @db.VarChar
l2_contract_events l2_contract_events[]
}
......
......@@ -12,6 +12,7 @@ version:
compile:
cd $(contracts-dir) && \
forge clean && \
pnpm build
bindings: compile bindings-build
......
......@@ -31,7 +31,7 @@ var (
// AlphabetVMMetaData contains all meta data concerning the AlphabetVM contract.
var AlphabetVMMetaData = &bind.MetaData{
ABI: "[{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"postState_\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
Bin: "0x60a060405234801561001057600080fd5b50604051610a73380380610a7383398101604081905261002f91610090565b608081905260405161004090610083565b604051809103906000f08015801561005c573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b0392909216919091179055506100a9565b6106c5806103ae83390190565b6000602082840312156100a257600080fd5b5051919050565b6080516102eb6100c3600039600060ad01526102eb6000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100986100933660046101a8565b6100a6565b60405190815260200161007c565b60008060007f000000000000000000000000000000000000000000000000000000000000000087876040516100dc929190610214565b60405180910390200361010057600091506100f986880188610224565b905061011f565b61010c8688018861023d565b90925090508161011b8161028e565b9250505b8161012b8260016102c6565b6040805160208101939093528201526060016040516020818303038152906040528051906020012092505050949350505050565b60008083601f84011261017157600080fd5b50813567ffffffffffffffff81111561018957600080fd5b6020830191508360208285010111156101a157600080fd5b9250929050565b600080600080604085870312156101be57600080fd5b843567ffffffffffffffff808211156101d657600080fd5b6101e28883890161015f565b909650945060208701359150808211156101fb57600080fd5b506102088782880161015f565b95989497509550505050565b8183823760009101908152919050565b60006020828403121561023657600080fd5b5035919050565b6000806040838503121561025057600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036102bf576102bf61025f565b5060010190565b600082198211156102d9576102d961025f565b50019056fea164736f6c634300080f000a608060405234801561001057600080fd5b506106a5806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063e03110e11161005b578063e03110e114610111578063e159261114610139578063fe4ac08e1461014e578063fef2b4ed146101c357600080fd5b806361238bde146100825780638542cf50146100c05780639a1f5e7f146100fe575b600080fd5b6100ad610090366004610551565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100ee6100ce366004610551565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100b7565b6100ad61010c366004610573565b6101e3565b61012461011f366004610551565b6102b6565b604080519283526020830191909152016100b7565b61014c6101473660046105a5565b6103a7565b005b61014c61015c366004610573565b6000838152600260209081526040808320878452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558684528252808320968352958152858220939093559283529082905291902055565b6100ad6101d1366004610621565b60006020819052908152604090205481565b60006101ee856104b0565b90506101fb836008610669565b8211806102085750602083115b1561023f576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845287528083209483529386528382205581815293849052922055919050565b6000828152600260209081526040808320848452909152812054819060ff1661033f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b506000838152602081815260409091205461035b816008610669565b610366856020610669565b106103845783610377826008610669565b6103819190610681565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103c65763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82161761054b81600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b92915050565b6000806040838503121561056457600080fd5b50508035926020909101359150565b6000806000806080858703121561058957600080fd5b5050823594602084013594506040840135936060013592509050565b6000806000604084860312156105ba57600080fd5b83359250602084013567ffffffffffffffff808211156105d957600080fd5b818601915086601f8301126105ed57600080fd5b8135818111156105fc57600080fd5b87602082850101111561060e57600080fd5b6020830194508093505050509250925092565b60006020828403121561063357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000821982111561067c5761067c61063a565b500190565b6000828210156106935761069361063a565b50039056fea164736f6c634300080f000a",
Bin: "0x60a060405234801561001057600080fd5b50604051610add380380610add83398101604081905261002f91610090565b608081905260405161004090610083565b604051809103906000f08015801561005c573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b0392909216919091179055506100a9565b6106c58061041883390190565b6000602082840312156100a257600080fd5b5051919050565b6080516103556100c3600039600060af01526103556000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610212565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600888886040516100e292919061027e565b6040518091039020901b0361010857600091506101018688018861028e565b9050610127565b610114868801886102a7565b909250905081610123816102f8565b9250505b81610133826001610330565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f010000000000000000000000000000000000000000000000000000000000000017979650505050505050565b60008083601f8401126101db57600080fd5b50813567ffffffffffffffff8111156101f357600080fd5b60208301915083602082850101111561020b57600080fd5b9250929050565b6000806000806040858703121561022857600080fd5b843567ffffffffffffffff8082111561024057600080fd5b61024c888389016101c9565b9096509450602087013591508082111561026557600080fd5b50610272878288016101c9565b95989497509550505050565b8183823760009101908152919050565b6000602082840312156102a057600080fd5b5035919050565b600080604083850312156102ba57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610329576103296102c9565b5060010190565b60008219821115610343576103436102c9565b50019056fea164736f6c634300080f000a608060405234801561001057600080fd5b506106a5806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063e03110e11161005b578063e03110e114610111578063e159261114610139578063fe4ac08e1461014e578063fef2b4ed146101c357600080fd5b806361238bde146100825780638542cf50146100c05780639a1f5e7f146100fe575b600080fd5b6100ad610090366004610551565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100ee6100ce366004610551565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100b7565b6100ad61010c366004610573565b6101e3565b61012461011f366004610551565b6102b6565b604080519283526020830191909152016100b7565b61014c6101473660046105a5565b6103a7565b005b61014c61015c366004610573565b6000838152600260209081526040808320878452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558684528252808320968352958152858220939093559283529082905291902055565b6100ad6101d1366004610621565b60006020819052908152604090205481565b60006101ee856104b0565b90506101fb836008610669565b8211806102085750602083115b1561023f576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845287528083209483529386528382205581815293849052922055919050565b6000828152600260209081526040808320848452909152812054819060ff1661033f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b506000838152602081815260409091205461035b816008610669565b610366856020610669565b106103845783610377826008610669565b6103819190610681565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103c65763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82161761054b81600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b92915050565b6000806040838503121561056457600080fd5b50508035926020909101359150565b6000806000806080858703121561058957600080fd5b5050823594602084013594506040840135936060013592509050565b6000806000604084860312156105ba57600080fd5b83359250602084013567ffffffffffffffff808211156105d957600080fd5b818601915086601f8301126105ed57600080fd5b8135818111156105fc57600080fd5b87602082850101111561060e57600080fd5b6020830194508093505050509250925092565b60006020828403121561063357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000821982111561067c5761067c61063a565b500190565b6000828210156106935761069361063a565b50039056fea164736f6c634300080f000a",
}
// AlphabetVMABI is the input ABI used to generate the binding from.
......
......@@ -13,7 +13,7 @@ const AlphabetVMStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\":
var AlphabetVMStorageLayout = new(solc.StorageLayout)
var AlphabetVMDeployedBin = "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100986100933660046101a8565b6100a6565b60405190815260200161007c565b60008060007f000000000000000000000000000000000000000000000000000000000000000087876040516100dc929190610214565b60405180910390200361010057600091506100f986880188610224565b905061011f565b61010c8688018861023d565b90925090508161011b8161028e565b9250505b8161012b8260016102c6565b6040805160208101939093528201526060016040516020818303038152906040528051906020012092505050949350505050565b60008083601f84011261017157600080fd5b50813567ffffffffffffffff81111561018957600080fd5b6020830191508360208285010111156101a157600080fd5b9250929050565b600080600080604085870312156101be57600080fd5b843567ffffffffffffffff808211156101d657600080fd5b6101e28883890161015f565b909650945060208701359150808211156101fb57600080fd5b506102088782880161015f565b95989497509550505050565b8183823760009101908152919050565b60006020828403121561023657600080fd5b5035919050565b6000806040838503121561025057600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036102bf576102bf61025f565b5060010190565b600082198211156102d9576102d961025f565b50019056fea164736f6c634300080f000a"
var AlphabetVMDeployedBin = "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610212565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600888886040516100e292919061027e565b6040518091039020901b0361010857600091506101018688018861028e565b9050610127565b610114868801886102a7565b909250905081610123816102f8565b9250505b81610133826001610330565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f010000000000000000000000000000000000000000000000000000000000000017979650505050505050565b60008083601f8401126101db57600080fd5b50813567ffffffffffffffff8111156101f357600080fd5b60208301915083602082850101111561020b57600080fd5b9250929050565b6000806000806040858703121561022857600080fd5b843567ffffffffffffffff8082111561024057600080fd5b61024c888389016101c9565b9096509450602087013591508082111561026557600080fd5b50610272878288016101c9565b95989497509550505050565b8183823760009101908152919050565b6000602082840312156102a057600080fd5b5035919050565b600080604083850312156102ba57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610329576103296102c9565b5060010190565b60008219821115610343576103436102c9565b50019056fea164736f6c634300080f000a"
func init() {
if err := json.Unmarshal([]byte(AlphabetVMStorageLayoutJSON), AlphabetVMStorageLayout); err != nil {
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -13,7 +13,7 @@ const EASStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\":\"src/E
var EASStorageLayout = new(solc.StorageLayout)
var EASDeployedBin = "0x6080604052600436106101805760003560e01c8063b469318d116100d6578063e45d03f91161007f578063ed24911d11610059578063ed24911d1461049e578063f10b5cc8146104b3578063f17325e7146104e257600080fd5b8063e45d03f914610458578063e57a6b1b1461046b578063e71ff3651461047e57600080fd5b8063d45c4435116100b0578063d45c4435146103cf578063e13458fc14610406578063e30bb5631461041957600080fd5b8063b469318d14610322578063b83010d31461037c578063cf190f34146103af57600080fd5b8063469262671161013857806354fd4d501161011257806354fd4d50146102cd578063831e05a1146102e2578063a3112a64146102f557600080fd5b806346926267146102855780634cb7e9e51461029a5780634d003070146102ad57600080fd5b806317d7de7c1161016957806317d7de7c146102005780632d0335ab1461022257806344adc90e1461026557600080fd5b806312b11a171461018557806313893f61146101c7575b600080fd5b34801561019157600080fd5b507fdbfdf8dc2b135c26253e00d5b6cbe6f20457e003fd526d97cea183883570de615b6040519081526020015b60405180910390f35b3480156101d357600080fd5b506101e76101e23660046133a9565b6104f5565b60405167ffffffffffffffff90911681526020016101be565b34801561020c57600080fd5b5061021561053a565b6040516101be9190613459565b34801561022e57600080fd5b506101b461023d36600461349e565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6102786102733660046133a9565b61056a565b6040516101be91906134bb565b6102986102933660046134ff565b6106a1565b005b6102986102a83660046133a9565b610725565b3480156102b957600080fd5b506101e76102c8366004613517565b61080d565b3480156102d957600080fd5b5061021561081a565b6102786102f03660046133a9565b6108bd565b34801561030157600080fd5b50610315610310366004613517565b610b0e565b6040516101be9190613617565b34801561032e57600080fd5b506101e761033d36600461362a565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b34801561038857600080fd5b507fa98d02348410c9c76735e0d0bb1396f4015ac2bb9615f9c2611d19d7a8a996506101b4565b3480156103bb57600080fd5b506101e76103ca366004613517565b610cd1565b3480156103db57600080fd5b506101e76103ea366004613517565b60009081526033602052604090205467ffffffffffffffff1690565b6101b4610414366004613656565b610cdf565b34801561042557600080fd5b50610448610434366004613517565b600090815260326020526040902054151590565b60405190151581526020016101be565b6102986104663660046133a9565b610de2565b610298610479366004613691565b610f5d565b34801561048a57600080fd5b506101e76104993660046133a9565b611002565b3480156104aa57600080fd5b506101b461103a565b3480156104bf57600080fd5b5060405173420000000000000000000000000000000000002081526020016101be565b6101b46104f03660046136a3565b611044565b60004282825b8181101561052e5761052633878784818110610519576105196136de565b9050602002013585611102565b6001016104fb565b50909150505b92915050565b60606105657f0000000000000000000000000000000000000000000000000000000000000000611201565b905090565b606060008267ffffffffffffffff8111156105875761058761370d565b6040519080825280602002602001820160405280156105ba57816020015b60608152602001906001900390816105a55790505b509050600034815b8581101561068c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8601811436888884818110610602576106026136de565b9050602002810190610614919061373c565b9050600061063b823561062a602085018561377a565b610633916139f3565b33888761138f565b805190915061064a9086613a96565b94508060200151878581518110610663576106636136de565b6020026020010181905250806020015151860195505050506106858160010190565b90506105c2565b506106978383611aa1565b9695505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816106b85790505090506106f336839003830160208401613af8565b81600081518110610706576107066136de565b602090810291909101015261072082358233346001611b6e565b505050565b3460005b82811015610807577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8301811436858584818110610769576107696136de565b905060200281019061077b919061373c565b90506107e8813561078f6020840184613b14565b808060200260200160405190810160405280939291908181526020016000905b828210156107db576107cc60408302860136819003810190613af8565b815260200190600101906107af565b5050505050338786611b6e565b6107f29085613a96565b935050506108008160010190565b9050610729565b50505050565b60004261053483826121a8565b60606108457f000000000000000000000000000000000000000000000000000000000000000061226a565b61086e7f000000000000000000000000000000000000000000000000000000000000000061226a565b6108977f000000000000000000000000000000000000000000000000000000000000000061226a565b6040516020016108a993929190613b7c565b604051602081830303815290604052905090565b606060008267ffffffffffffffff8111156108da576108da61370d565b60405190808252806020026020018201604052801561090d57816020015b60608152602001906001900390816108f85790505b509050600034815b8581101561068c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8601811436888884818110610955576109556136de565b90506020028101906109679190613bf2565b9050366000610979602084018461377a565b909250905080158061099957506109936040840184613c26565b82141590505b156109d0576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610a9257610a8a604051806080016040528086600001358152602001858585818110610a0557610a056136de565b9050602002810190610a179190613c8d565b610a2090613cc1565b8152602001610a326040880188613c26565b85818110610a4257610a426136de565b905060600201803603810190610a589190613d38565b8152602001610a6d608088016060890161349e565b73ffffffffffffffffffffffffffffffffffffffff1690526123a7565b6001016109d3565b506000610abb8435610aa484866139f3565b610ab4608088016060890161349e565b8a8961138f565b8051909150610aca9088613a96565b96508060200151898781518110610ae357610ae36136de565b6020026020010181905250806020015151880197505050505050610b078160010190565b9050610915565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805491929161012084019190610c4890613d54565b80601f0160208091040260200160405190810160405280929190818152602001828054610c7490613d54565b8015610cc15780601f10610c9657610100808354040283529160200191610cc1565b820191906000526020600020905b815481529060010190602001808311610ca457829003601f168201915b5050505050815250509050919050565b600042610534338483611102565b6000610cf2610ced83613da1565b6123a7565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610d09579050509050610d776020840184613c8d565b610d8090613cc1565b81600081518110610d9357610d936136de565b6020908102919091010152610dbc833582610db460c0870160a0880161349e565b34600161138f565b60200151600081518110610dd257610dd26136de565b6020026020010151915050919050565b3460005b82811015610807577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff830181146000858584818110610e2757610e276136de565b9050602002810190610e399190613bf2565b610e4290613e86565b60208101518051919250901580610e5f5750816040015151815114155b15610e96576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8151811015610f2757610f1f604051806080016040528085600001518152602001848481518110610ecc57610ecc6136de565b6020026020010151815260200185604001518481518110610eef57610eef6136de565b60200260200101518152602001856060015173ffffffffffffffffffffffffffffffffffffffff16815250612560565b600101610e99565b50610f3d82600001518284606001518887611b6e565b610f479086613a96565b9450505050610f568160010190565b9050610de6565b610f74610f6f36839003830183613f65565b612560565b604080516001808252818301909252600091816020015b6040805180820190915260008082526020820152815260200190600190039081610f8b579050509050610fc636839003830160208401613af8565b81600081518110610fd957610fd96136de565b6020908102919091010152610720823582610ffa60e0860160c0870161349e565b346001611b6e565b60004282825b8181101561052e57611032868683818110611025576110256136de565b90506020020135846121a8565b600101611008565b60006105656125ee565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161105e5790505090506110cc6020840184613c8d565b6110d590613cc1565b816000815181106110e8576110e86136de565b6020908102919091010152610dbc8335823334600161138f565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611176576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b60208110156112cc576000858260208110611247576112476136de565b1a60f81b90507fff00000000000000000000000000000000000000000000000000000000000000811660000361127d57506112cc565b80848481518110611290576112906136de565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350506001918201910161122a565b5060008167ffffffffffffffff8111156112e8576112e861370d565b6040519080825280601f01601f191660200182016040528015611312576020820181803683370190505b50905060005b8281101561138657838181518110611332576113326136de565b602001015160f81c60f81b82828151811061134f5761134f6136de565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611318565b50949350505050565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff8111156113d4576113d461370d565b6040519080825280602002602001820160405280156113fd578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa15801561146f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526114b59190810190613fc1565b80519091506114f0576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff81111561150b5761150b61370d565b6040519080825280602002602001820160405280156115aa57816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816115295790505b50905060008467ffffffffffffffff8111156115c8576115c861370d565b6040519080825280602002602001820160405280156115f1578160200160208202803683370190505b50905060005b85811015611a805760008b8281518110611613576116136136de565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff161415801561165e57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15611695576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84604001511580156116a8575080604001515b156116df576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016117034290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6117a58382612722565b600081815260326020526040902054909250156117c45760010161179b565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff0000000000000000000000000000000000000000009091169290931691909117919091179055610120840151849190600682019061194490826140e7565b50505060608401511561199b57606084015160009081526032602052604090205461199b576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828786815181106119ae576119ae6136de565b60200260200101819052508360a001518686815181106119d0576119d06136de565b60200260200101818152505081896020015186815181106119f3576119f36136de565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b3585604051611a6391815260200190565b60405180910390a450505050611a798160010190565b90506115f7565b50611a9083838360008c8c612781565b845250919998505050505050505050565b606060008267ffffffffffffffff811115611abe57611abe61370d565b604051908082528060200260200182016040528015611ae7578160200160208202803683370190505b5090506000805b855181101561052e576000868281518110611b0b57611b0b6136de565b6020026020010151905060005b8151811015611b6457818181518110611b3357611b336136de565b6020026020010151858581518110611b4d57611b4d6136de565b602090810291909101015260019384019301611b18565b5050600101611aee565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611bdc573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611c229190810190613fc1565b8051909150611c5d576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff811115611c7a57611c7a61370d565b604051908082528060200260200182016040528015611d1957816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181611c985790505b50905060008267ffffffffffffffff811115611d3757611d3761370d565b604051908082528060200260200182016040528015611d60578160200160208202803683370190505b50905060005b8381101561218a5760008a8281518110611d8257611d826136de565b6020908102919091018101518051600090815260329092526040909120805491925090611ddb576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c816001015414611e18576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c8116911614611e6e576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff16611ec4576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff1615611f1e576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff161515610100820152600682018054839161012084019161202a90613d54565b80601f016020809104026020016040519081016040528092919081815260200182805461205690613d54565b80156120a35780601f10612078576101008083540402835291602001916120a3565b820191906000526020600020905b81548152906001019060200180831161208657829003601f168201915b5050505050815250508584815181106120be576120be6136de565b602002602001018190525081602001518484815181106120e0576120e06136de565b60200260200101818152505080600101548b73ffffffffffffffffffffffffffffffffffffffff168260040160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f615856000015160405161217891815260200190565b60405180910390a45050600101611d66565b5061219a84838360018b8b612781565b9a9950505050505050505050565b60008281526033602052604090205467ffffffffffffffff16156121f8576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b6060816000036122ad57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156122d757806122c181614201565b91506122d09050600a83614268565b91506122b1565b60008167ffffffffffffffff8111156122f2576122f261370d565b6040519080825280601f01601f19166020018201604052801561231c576020820181803683370190505b5090505b841561239f57612331600183613a96565b915061233e600a8661427c565b612349906030614290565b60f81b81838151811061235e5761235e6136de565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350612398600a86614268565b9450612320565b949350505050565b60208082015160408084015160608086015173ffffffffffffffffffffffffffffffffffffffff1660009081528086528381208054600181019091558751865187890151878901519589015160808a01518051908c01209851999a9799949895976124ad97612492977fdbfdf8dc2b135c26253e00d5b6cbe6f20457e003fd526d97cea183883570de619791939290918c9101978852602088019690965273ffffffffffffffffffffffffffffffffffffffff94909416604087015267ffffffffffffffff9290921660608601521515608085015260a084015260c083015260e08201526101000190565b60405160208183030381529060405280519060200120612b5b565b905061252385606001518285602001518660400151876000015160405160200161250f93929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b604051602081830303815290604052612b6e565b612559576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050565b60208181015160408084015160608086015173ffffffffffffffffffffffffffffffffffffffff1660009081528086528381208054600181019091558751865186517fa98d02348410c9c76735e0d0bb1396f4015ac2bb9615f9c2611d19d7a8a99650998101999099529588015291860193909352608085018190529293909291906124ad9060a001612492565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614801561265457507f000000000000000000000000000000000000000000000000000000000000000046145b1561267e57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b0151945160009961276399989796918c91016142a3565b60405160208183030381529060405280519060200120905092915050565b845160009060018190036127d9576127d188886000815181106127a6576127a66136de565b6020026020010151886000815181106127c1576127c16136de565b6020026020010151888888612d3d565b915050610697565b602088015173ffffffffffffffffffffffffffffffffffffffff811661286b5760005b8281101561285f57878181518110612816576128166136de565b6020026020010151600014612857576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001016127fc565b50600092505050610697565b6000805b8381101561299557600089828151811061288b5761288b6136de565b602002602001015190508060001415801561291257508373ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa1580156128ec573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129109190614381565b155b15612949576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b87811115612983576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9687900396919091019060010161286f565b508615612a70576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316906388e5b2d99083906129f2908d908d9060040161439e565b60206040518083038185885af1158015612a10573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612a359190614381565b612a6b576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b3f565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316906391db0b7e908390612ac6908d908d9060040161439e565b60206040518083038185885af1158015612ae4573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612b099190614381565b612b3f576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8415612b4e57612b4e86613053565b9998505050505050505050565b6000610534612b686125ee565b83613066565b6000806000612b7d85856130a8565b90925090506000816004811115612b9657612b96614457565b148015612bce57508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b15612bde57600192505050612d36565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b8888604051602401612c13929190614486565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909416939093179092529051612c9c919061449f565b600060405180830381855afa9150503d8060008114612cd7576040519150601f19603f3d011682016040523d82523d6000602084013e612cdc565b606091505b5091509150818015612cef575080516020145b8015612d2f575080517f1626ba7e0000000000000000000000000000000000000000000000000000000090612d2d90830160209081019084016144b1565b145b9450505050505b9392505050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff8116612da2578515612d98576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000915050610697565b8515801590612e1d57508073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612df7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e1b9190614381565b155b15612e54576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83861115612e8e576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393508415612f6b576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e1908890612eed908b90600401613617565b60206040518083038185885af1158015612f0b573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612f309190614381565b612f66576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613038565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c3505908890612fbf908b90600401613617565b60206040518083038185885af1158015612fdd573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906130029190614381565b613038576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156130475761304784613053565b50939695505050505050565b80156130635761306333826130ed565b50565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612763565b60008082516041036130de5760208301516040840151606085015160001a6130d28782858561324c565b945094505050506130e6565b506000905060025b9250929050565b8047101561315c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146131b6576040519150601f19603f3d011682016040523d82523d6000602084013e6131bb565b606091505b5050905080610720576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401613153565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115613283575060009050600361335b565b8460ff16601b1415801561329b57508460ff16601c14155b156132ac575060009050600461335b565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015613300573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166133545760006001925092505061335b565b9150600090505b94509492505050565b60008083601f84011261337657600080fd5b50813567ffffffffffffffff81111561338e57600080fd5b6020830191508360208260051b85010111156130e657600080fd5b600080602083850312156133bc57600080fd5b823567ffffffffffffffff8111156133d357600080fd5b6133df85828601613364565b90969095509350505050565b60005b838110156134065781810151838201526020016133ee565b50506000910152565b600081518084526134278160208601602086016133eb565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612d36602083018461340f565b73ffffffffffffffffffffffffffffffffffffffff8116811461306357600080fd5b80356134998161346c565b919050565b6000602082840312156134b057600080fd5b8135612d368161346c565b6020808252825182820181905260009190848201906040850190845b818110156134f3578351835292840192918401916001016134d7565b50909695505050505050565b60006060828403121561351157600080fd5b50919050565b60006020828403121561352957600080fd5b5035919050565b60006101408251845260208301516020850152604083015161355e604086018267ffffffffffffffff169052565b50606083015161357a606086018267ffffffffffffffff169052565b506080830151613596608086018267ffffffffffffffff169052565b5060a083015160a085015260c08301516135c860c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e08301516135f060e086018273ffffffffffffffffffffffffffffffffffffffff169052565b5061010083810151151590850152610120808401518186018390526106978387018261340f565b602081526000612d366020830184613530565b6000806040838503121561363d57600080fd5b82356136488161346c565b946020939093013593505050565b60006020828403121561366857600080fd5b813567ffffffffffffffff81111561367f57600080fd5b820160c08185031215612d3657600080fd5b600060e0828403121561351157600080fd5b6000602082840312156136b557600080fd5b813567ffffffffffffffff8111156136cc57600080fd5b820160408185031215612d3657600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc183360301811261377057600080fd5b9190910192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126137af57600080fd5b83018035915067ffffffffffffffff8211156137ca57600080fd5b6020019150600581901b36038213156130e657600080fd5b60405160c0810167ffffffffffffffff811182821017156138055761380561370d565b60405290565b6040516080810167ffffffffffffffff811182821017156138055761380561370d565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156138755761387561370d565b604052919050565b600067ffffffffffffffff8211156138975761389761370d565b5060051b60200190565b801515811461306357600080fd5b8035613499816138a1565b600067ffffffffffffffff8211156138d4576138d461370d565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f83011261391157600080fd5b813561392461391f826138ba565b61382e565b81815284602083860101111561393957600080fd5b816020850160208301376000918101602001919091529392505050565b600060c0828403121561396857600080fd5b6139706137e2565b9050813561397d8161346c565b8152602082013567ffffffffffffffff808216821461399b57600080fd5b8160208401526139ad604085016138af565b60408401526060840135606084015260808401359150808211156139d057600080fd5b506139dd84828501613900565b60808301525060a082013560a082015292915050565b6000613a0161391f8461387d565b80848252602080830192508560051b850136811115613a1f57600080fd5b855b81811015613a5b57803567ffffffffffffffff811115613a415760008081fd5b613a4d36828a01613956565b865250938201938201613a21565b50919695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8181038181111561053457610534613a67565b600060408284031215613abb57600080fd5b6040516040810181811067ffffffffffffffff82111715613ade57613ade61370d565b604052823581526020928301359281019290925250919050565b600060408284031215613b0a57600080fd5b612d368383613aa9565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613b4957600080fd5b83018035915067ffffffffffffffff821115613b6457600080fd5b6020019150600681901b36038213156130e657600080fd5b60008451613b8e8184602089016133eb565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551613bca816001850160208a016133eb565b60019201918201528351613be58160028401602088016133eb565b0160020195945050505050565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8183360301811261377057600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613c5b57600080fd5b83018035915067ffffffffffffffff821115613c7657600080fd5b60200191506060810236038213156130e657600080fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4183360301811261377057600080fd5b60006105343683613956565b600060608284031215613cdf57600080fd5b6040516060810181811067ffffffffffffffff82111715613d0257613d0261370d565b604052905080823560ff81168114613d1957600080fd5b8082525060208301356020820152604083013560408201525092915050565b600060608284031215613d4a57600080fd5b612d368383613ccd565b600181811c90821680613d6857607f821691505b602082108103613511577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060c08236031215613db357600080fd5b613dbb61380b565b82358152602083013567ffffffffffffffff811115613dd957600080fd5b613de536828601613956565b602083015250613df83660408501613ccd565b604082015260a0830135613e0b8161346c565b606082015292915050565b600082601f830112613e2757600080fd5b81356020613e3761391f8361387d565b82815260609283028501820192828201919087851115613e5657600080fd5b8387015b85811015613e7957613e6c8982613ccd565b8452928401928101613e5a565b5090979650505050505050565b600060808236031215613e9857600080fd5b613ea061380b565b8235815260208084013567ffffffffffffffff80821115613ec057600080fd5b9085019036601f830112613ed357600080fd5b8135613ee161391f8261387d565b81815260069190911b83018401908481019036831115613f0057600080fd5b938501935b82851015613f2957613f173686613aa9565b82528582019150604085019450613f05565b80868801525050506040860135925080831115613f4557600080fd5b5050613f5336828601613e16565b604083015250613e0b6060840161348e565b600060e08284031215613f7757600080fd5b613f7f61380b565b82358152613f908460208501613aa9565b6020820152613fa28460608501613ccd565b604082015260c0830135613fb58161346c565b60608201529392505050565b60006020808385031215613fd457600080fd5b825167ffffffffffffffff80821115613fec57600080fd5b908401906080828703121561400057600080fd5b61400861380b565b82518152838301516140198161346c565b81850152604083015161402b816138a1565b604082015260608301518281111561404257600080fd5b80840193505086601f84011261405757600080fd5b8251915061406761391f836138ba565b828152878584860101111561407b57600080fd5b61408a838683018787016133eb565b60608201529695505050505050565b601f82111561072057600081815260208120601f850160051c810160208610156140c05750805b601f850160051c820191505b818110156140df578281556001016140cc565b505050505050565b815167ffffffffffffffff8111156141015761410161370d565b6141158161410f8454613d54565b84614099565b602080601f83116001811461416857600084156141325750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556140df565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156141b557888601518255948401946001909101908401614196565b50858210156141f157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361423257614232613a67565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261427757614277614239565b500490565b60008261428b5761428b614239565b500690565b8082018082111561053457610534613a67565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b6058830152846059830152835161433c8160798501602088016133eb565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a9950505050505050505050565b60006020828403121561439357600080fd5b8151612d36816138a1565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614413577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614401868351613530565b955093820193908201906001016143c7565b50508584038187015286518085528782019482019350915060005b8281101561444a5784518452938101939281019260010161442e565b5091979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061239f604083018461340f565b600082516137708184602087016133eb565b6000602082840312156144c357600080fd5b505191905056fea164736f6c6343000813000a"
var EASDeployedBin = "0x60806040526004361061018b5760003560e01c806395411525116100d6578063d45c44351161007f578063ed24911d11610059578063ed24911d146104c9578063f10b5cc8146104de578063f17325e71461050d57600080fd5b8063d45c443514610433578063e30bb5631461046a578063e71ff365146104a957600080fd5b8063b469318d116100b0578063b469318d14610386578063b83010d3146103e0578063cf190f341461041357600080fd5b80639541152514610333578063a3112a6414610346578063a6d4dbc71461037357600080fd5b806344adc90e116101385780634d003070116101125780634d003070146102de57806354fd4d50146102fe57806379f7573a1461031357600080fd5b806344adc90e1461029857806346926267146102b85780634cb7e9e5146102cb57600080fd5b806317d7de7c1161016957806317d7de7c146102205780632d0335ab146102425780633c0427151461028557600080fd5b80630eabf6601461019057806312b11a17146101a557806313893f61146101e7575b600080fd5b6101a361019e366004613643565b610520565b005b3480156101b157600080fd5b507ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f5b6040519081526020015b60405180910390f35b3480156101f357600080fd5b50610207610202366004613643565b6106b7565b60405167ffffffffffffffff90911681526020016101de565b34801561022c57600080fd5b506102356106fc565b6040516101de91906136f3565b34801561024e57600080fd5b506101d461025d366004613738565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101d4610293366004613755565b61072c565b6102ab6102a6366004613643565b61082f565b6040516101de9190613790565b6101a36102c63660046137d4565b6109b0565b6101a36102d9366004613643565b610a34565b3480156102ea57600080fd5b506102076102f93660046137ec565b610b17565b34801561030a57600080fd5b50610235610b24565b34801561031f57600080fd5b506101a361032e3660046137ec565b610bc7565b6102ab610341366004613643565b610c5e565b34801561035257600080fd5b506103666103613660046137ec565b610ed1565b6040516101de91906138ec565b6101a36103813660046138ff565b611094565b34801561039257600080fd5b506102076103a1366004613912565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b3480156103ec57600080fd5b507f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c6101d4565b34801561041f57600080fd5b5061020761042e3660046137ec565b611139565b34801561043f57600080fd5b5061020761044e3660046137ec565b60009081526033602052604090205467ffffffffffffffff1690565b34801561047657600080fd5b506104996104853660046137ec565b600090815260326020526040902054151590565b60405190151581526020016101de565b3480156104b557600080fd5b506102076104c4366004613643565b611147565b3480156104d557600080fd5b506101d461117f565b3480156104ea57600080fd5b5060405173420000000000000000000000000000000000002081526020016101de565b6101d461051b36600461393e565b611189565b348160005b818110156106b0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82018114600086868481811061056657610566613979565b905060200281019061057891906139a8565b61058190613c3e565b602081015180519192509080158061059e57508260400151518114155b156105d5576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610679576106716040518060a001604052808660000151815260200185848151811061060a5761060a613979565b602002602001015181526020018660400151848151811061062d5761062d613979565b60200260200101518152602001866060015173ffffffffffffffffffffffffffffffffffffffff168152602001866080015167ffffffffffffffff16815250611247565b6001016105d8565b5061068f83600001518385606001518a88611434565b6106999088613d68565b9650505050506106a98160010190565b9050610525565b5050505050565b60004282825b818110156106f0576106e8338787848181106106db576106db613979565b9050602002013585611a63565b6001016106bd565b50909150505b92915050565b60606107277f0000000000000000000000000000000000000000000000000000000000000000611b62565b905090565b600061073f61073a83613e9d565b611cf0565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816107565790505090506107c46020840184613f18565b6107cd90613f4c565b816000815181106107e0576107e0613979565b602090810291909101015261080983358261080160c0870160a08801613738565b346001611e6d565b6020015160008151811061081f5761081f613979565b6020026020010151915050919050565b60608160008167ffffffffffffffff81111561084d5761084d6139e6565b60405190808252806020026020018201604052801561088057816020015b606081526020019060019003908161086b5790505b509050600034815b8481101561099a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff85018114368989848181106108c8576108c8613979565b90506020028101906108da9190613f58565b90506108e96020820182613f8c565b9050600003610924576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061094982356109386020850185613f8c565b61094191613ff4565b338887611e6d565b80519091506109589086613d68565b9450806020015187858151811061097157610971613979565b6020026020010181905250806020015151860195505050506109938160010190565b9050610888565b506109a5838361257f565b979650505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816109c7579050509050610a0236839003830160208401614068565b81600081518110610a1557610a15613979565b6020908102919091010152610a2f82358233346001611434565b505050565b348160005b818110156106b0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8201811436868684818110610a7957610a79613979565b9050602002810190610a8b9190613f58565b9050610af88135610a9f6020840184614084565b808060200260200160405190810160405280939291908181526020016000905b82821015610aeb57610adc60408302860136819003810190614068565b81526020019060010190610abf565b5050505050338886611434565b610b029086613d68565b94505050610b108160010190565b9050610a39565b6000426106f68382612669565b6060610b4f7f000000000000000000000000000000000000000000000000000000000000000061272b565b610b787f000000000000000000000000000000000000000000000000000000000000000061272b565b610ba17f000000000000000000000000000000000000000000000000000000000000000061272b565b604051602001610bb3939291906140ec565b604051602081830303815290604052905090565b33600090815260208190526040902054808211610c10576040517f756688fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152602081815260409182902084905581518381529081018490527f57b09af877df9068fd60a69d7b21f5576b8b38955812d6ae4ac52942f1e38fb7910160405180910390a15050565b60608160008167ffffffffffffffff811115610c7c57610c7c6139e6565b604051908082528060200260200182016040528015610caf57816020015b6060815260200190600190039081610c9a5790505b509050600034815b8481101561099a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8501811436898984818110610cf757610cf7613979565b9050602002810190610d0991906139a8565b9050366000610d1b6020840184613f8c565b909250905080801580610d3c5750610d366040850185614162565b90508114155b15610d73576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610e5457610e4c6040518060a0016040528087600001358152602001868685818110610da857610da8613979565b9050602002810190610dba9190613f18565b610dc390613f4c565b8152602001610dd56040890189614162565b85818110610de557610de5613979565b905060600201803603810190610dfb91906141c9565b8152602001610e106080890160608a01613738565b73ffffffffffffffffffffffffffffffffffffffff168152602001610e3b60a0890160808a016141e5565b67ffffffffffffffff169052611cf0565b600101610d76565b506000610e7d8535610e668587613ff4565b610e766080890160608a01613738565b8b8a611e6d565b8051909150610e8c9089613d68565b975080602001518a8881518110610ea557610ea5613979565b602002602001018190525080602001515189019850505050505050610eca8160010190565b9050610cb7565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff1615156101008201526006820180549192916101208401919061100b90614200565b80601f016020809104026020016040519081016040528092919081815260200182805461103790614200565b80156110845780601f1061105957610100808354040283529160200191611084565b820191906000526020600020905b81548152906001019060200180831161106757829003601f168201915b5050505050815250509050919050565b6110ab6110a63683900383018361424d565b611247565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816110c25790505090506110fd36839003830160208401614068565b8160008151811061111057611110613979565b6020908102919091010152610a2f82358261113160e0860160c08701613738565b346001611434565b6000426106f6338483611a63565b60004282825b818110156106f05761117786868381811061116a5761116a613979565b9050602002013584612669565b60010161114d565b6000610727612868565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816111a35790505090506112116020840184613f18565b61121a90613f4c565b8160008151811061122d5761122d613979565b602090810291909101015261080983358233346001611e6d565b608081015167ffffffffffffffff161580159061127b57504267ffffffffffffffff16816080015167ffffffffffffffff16105b156112b2576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401518451835184860151606088015173ffffffffffffffffffffffffffffffffffffffff166000908152968790529386208054959693959394611382947f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c94939287611327836142bb565b909155506080808b015160408051602081019890985287019590955260608601939093529184015260a083015267ffffffffffffffff1660c082015260e0015b6040516020818303038152906040528051906020012061299c565b90506113f88460600151828460200151856040015186600001516040516020016113e493929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b6040516020818303038152906040526129af565b61142e576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa1580156114a2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526114e891908101906142f3565b8051909150611523576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff811115611540576115406139e6565b6040519080825280602002602001820160405280156115df57816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161155e5790505b50905060008267ffffffffffffffff8111156115fd576115fd6139e6565b604051908082528060200260200182016040528015611626578160200160208202803683370190505b50905060005b83811015611a455760008a828151811061164857611648613979565b60209081029190910181015180516000908152603290925260409091208054919250906116a1576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c8160010154146116de576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c8116911614611734576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff1661178a576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff16156117e4576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805483916101208401916118f090614200565b80601f016020809104026020016040519081016040528092919081815260200182805461191c90614200565b80156119695780601f1061193e57610100808354040283529160200191611969565b820191906000526020600020905b81548152906001019060200180831161194c57829003601f168201915b50505050508152505085848151811061198457611984613979565b602002602001018190525081602001518484815181106119a6576119a6613979565b6020026020010181815250508c8b73ffffffffffffffffffffffffffffffffffffffff168685815181106119dc576119dc613979565b602002602001015160c0015173ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f6158560000151604051611a3391815260200190565b60405180910390a4505060010161162c565b50611a5584838360018b8b612b7e565b9a9950505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611ad7576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b6020811015611c2d576000858260208110611ba857611ba8613979565b1a60f81b90507fff000000000000000000000000000000000000000000000000000000000000008116600003611bde5750611c2d565b80848481518110611bf157611bf1613979565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053505060019182019101611b8b565b5060008167ffffffffffffffff811115611c4957611c496139e6565b6040519080825280601f01601f191660200182016040528015611c73576020820181803683370190505b50905060005b82811015611ce757838181518110611c9357611c93613979565b602001015160f81c60f81b828281518110611cb057611cb0613979565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611c79565b50949350505050565b608081015167ffffffffffffffff1615801590611d2457504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611d5b576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208082015160408084015184518351848601518486015160608088015160808901518051908b012060a08a0151928c015173ffffffffffffffffffffffffffffffffffffffff1660009081529a8b9052978a208054999a97999798611382987ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f989796959491928b611ded836142bb565b909155506080808f015160408051602081019c909c528b019990995273ffffffffffffffffffffffffffffffffffffffff90971660608a015267ffffffffffffffff9586169689019690965292151560a088015260c087019190915260e08601526101008501526101208401919091521661014082015261016001611367565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff811115611eb257611eb26139e6565b604051908082528060200260200182016040528015611edb578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611f4d573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f9391908101906142f3565b8051909150611fce576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff811115611fe957611fe96139e6565b60405190808252806020026020018201604052801561208857816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816120075790505b50905060008467ffffffffffffffff8111156120a6576120a66139e6565b6040519080825280602002602001820160405280156120cf578160200160208202803683370190505b50905060005b8581101561255e5760008b82815181106120f1576120f1613979565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff161415801561213c57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15612173576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8460400151158015612186575080604001515b156121bd576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016121e14290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6122838382612f6f565b600081815260326020526040902054909250156122a257600101612279565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff000000000000000000000000000000000000000000909116929093169190911791909117905561012084015184919060068201906124229082614419565b505050606084015115612479576060840151600090815260326020526040902054612479576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8287868151811061248c5761248c613979565b60200260200101819052508360a001518686815181106124ae576124ae613979565b60200260200101818152505081896020015186815181106124d1576124d1613979565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b358560405161254191815260200190565b60405180910390a4505050506125578160010190565b90506120d5565b5061256e83838360008c8c612b7e565b845250919998505050505050505050565b606060008267ffffffffffffffff81111561259c5761259c6139e6565b6040519080825280602002602001820160405280156125c5578160200160208202803683370190505b508451909150600090815b8181101561265e5760008782815181106125ec576125ec613979565b6020026020010151905060008151905060005b8181101561264a5782818151811061261957612619613979565b602002602001015187878151811061263357612633613979565b6020908102919091010152600195860195016125ff565b5050506126578160010190565b90506125d0565b509195945050505050565b60008281526033602052604090205467ffffffffffffffff16156126b9576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b60608160000361276e57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156127985780612782816142bb565b91506127919050600a83614562565b9150612772565b60008167ffffffffffffffff8111156127b3576127b36139e6565b6040519080825280601f01601f1916602001820160405280156127dd576020820181803683370190505b5090505b8415612860576127f2600183613d68565b91506127ff600a86614576565b61280a90603061458a565b60f81b81838151811061281f5761281f613979565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350612859600a86614562565b94506127e1565b949350505050565b60003073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161480156128ce57507f000000000000000000000000000000000000000000000000000000000000000046145b156128f857507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b60006106f66129a9612868565b83612fce565b60008060006129be8585613010565b909250905060008160048111156129d7576129d761459d565b148015612a0f57508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b15612a1f57600192505050612b77565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b8888604051602401612a549291906145cc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909416939093179092529051612add91906145e5565b600060405180830381855afa9150503d8060008114612b18576040519150601f19603f3d011682016040523d82523d6000602084013e612b1d565b606091505b5091509150818015612b30575080516020145b8015612b70575080517f1626ba7e0000000000000000000000000000000000000000000000000000000090612b6e90830160209081019084016145f7565b145b9450505050505b9392505050565b84516000906001819003612bd657612bce8888600081518110612ba357612ba3613979565b602002602001015188600081518110612bbe57612bbe613979565b6020026020010151888888613055565b915050612f65565b602088015173ffffffffffffffffffffffffffffffffffffffff8116612c775760005b82811015612c5c57878181518110612c1357612c13613979565b6020026020010151600014612c54576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600101612bf9565b508315612c6c57612c6c85613374565b600092505050612f65565b6000808273ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612cc5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ce99190614610565b905060005b84811015612da65760008a8281518110612d0a57612d0a613979565b6020026020010151905080600003612d225750612d9e565b82612d59576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b88811115612d93576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b978890039792909201915b600101612cee565b508715612e81576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906388e5b2d9908490612e03908e908e9060040161462d565b60206040518083038185885af1158015612e21573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612e469190614610565b612e7c576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612f50565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906391db0b7e908490612ed7908e908e9060040161462d565b60206040518083038185885af1158015612ef5573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612f1a9190614610565b612f50576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515612f5f57612f5f87613374565b50925050505b9695505050505050565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b01519451600099612fb099989796918c91016146e6565b60405160208183030381529060405280519060200120905092915050565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612fb0565b60008082516041036130465760208301516040840151606085015160001a61303a87828585613387565b9450945050505061304e565b506000905060025b9250929050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff81166130c95785156130b0576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156130bf576130bf84613374565b6000915050612f65565b85156131b4578073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa15801561311a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061313e9190614610565b613174576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b838611156131ae576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393505b841561328c576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e190889061320e908b906004016138ec565b60206040518083038185885af115801561322c573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906132519190614610565b613287576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613359565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c35059088906132e0908b906004016138ec565b60206040518083038185885af11580156132fe573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906133239190614610565b613359576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156133685761336884613374565b50939695505050505050565b801561338457613384338261349f565b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156133be5750600090506003613496565b8460ff16601b141580156133d657508460ff16601c14155b156133e75750600090506004613496565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa15801561343b573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff811661348f57600060019250925050613496565b9150600090505b94509492505050565b8047101561350e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114613568576040519150601f19603f3d011682016040523d82523d6000602084013e61356d565b606091505b5050905080610a2f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401613505565b60008083601f84011261361057600080fd5b50813567ffffffffffffffff81111561362857600080fd5b6020830191508360208260051b850101111561304e57600080fd5b6000806020838503121561365657600080fd5b823567ffffffffffffffff81111561366d57600080fd5b613679858286016135fe565b90969095509350505050565b60005b838110156136a0578181015183820152602001613688565b50506000910152565b600081518084526136c1816020860160208601613685565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612b7760208301846136a9565b73ffffffffffffffffffffffffffffffffffffffff8116811461338457600080fd5b803561373381613706565b919050565b60006020828403121561374a57600080fd5b8135612b7781613706565b60006020828403121561376757600080fd5b813567ffffffffffffffff81111561377e57600080fd5b820160e08185031215612b7757600080fd5b6020808252825182820181905260009190848201906040850190845b818110156137c8578351835292840192918401916001016137ac565b50909695505050505050565b6000606082840312156137e657600080fd5b50919050565b6000602082840312156137fe57600080fd5b5035919050565b600061014082518452602083015160208501526040830151613833604086018267ffffffffffffffff169052565b50606083015161384f606086018267ffffffffffffffff169052565b50608083015161386b608086018267ffffffffffffffff169052565b5060a083015160a085015260c083015161389d60c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e08301516138c560e086018273ffffffffffffffffffffffffffffffffffffffff169052565b506101008381015115159085015261012080840151818601839052612f65838701826136a9565b602081526000612b776020830184613805565b600061010082840312156137e657600080fd5b6000806040838503121561392557600080fd5b823561393081613706565b946020939093013593505050565b60006020828403121561395057600080fd5b813567ffffffffffffffff81111561396757600080fd5b820160408185031215612b7757600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff618336030181126139dc57600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613a3857613a386139e6565b60405290565b60405160c0810167ffffffffffffffff81118282101715613a3857613a386139e6565b6040516080810167ffffffffffffffff81118282101715613a3857613a386139e6565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613acb57613acb6139e6565b604052919050565b600067ffffffffffffffff821115613aed57613aed6139e6565b5060051b60200190565b600060408284031215613b0957600080fd5b6040516040810181811067ffffffffffffffff82111715613b2c57613b2c6139e6565b604052823581526020928301359281019290925250919050565b600060608284031215613b5857600080fd5b6040516060810181811067ffffffffffffffff82111715613b7b57613b7b6139e6565b604052905080823560ff81168114613b9257600080fd5b8082525060208301356020820152604083013560408201525092915050565b600082601f830112613bc257600080fd5b81356020613bd7613bd283613ad3565b613a84565b82815260609283028501820192828201919087851115613bf657600080fd5b8387015b85811015613c1957613c0c8982613b46565b8452928401928101613bfa565b5090979650505050505050565b803567ffffffffffffffff8116811461373357600080fd5b600060a08236031215613c5057600080fd5b613c58613a15565b8235815260208084013567ffffffffffffffff80821115613c7857600080fd5b9085019036601f830112613c8b57600080fd5b8135613c99613bd282613ad3565b81815260069190911b83018401908481019036831115613cb857600080fd5b938501935b82851015613ce157613ccf3686613af7565b82528582019150604085019450613cbd565b80868801525050506040860135925080831115613cfd57600080fd5b5050613d0b36828601613bb1565b604083015250613d1d60608401613728565b6060820152613d2e60808401613c26565b608082015292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b818103818111156106f6576106f6613d39565b801515811461338457600080fd5b600067ffffffffffffffff821115613da357613da36139e6565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600060c08284031215613de157600080fd5b613de9613a3e565b90508135613df681613706565b81526020613e05838201613c26565b818301526040830135613e1781613d7b565b604083015260608381013590830152608083013567ffffffffffffffff811115613e4057600080fd5b8301601f81018513613e5157600080fd5b8035613e5f613bd282613d89565b8181528684838501011115613e7357600080fd5b818484018583013760008483830101528060808601525050505060a082013560a082015292915050565b600060e08236031215613eaf57600080fd5b613eb7613a15565b82358152602083013567ffffffffffffffff811115613ed557600080fd5b613ee136828601613dcf565b602083015250613ef43660408501613b46565b604082015260a0830135613f0781613706565b6060820152613d2e60c08401613c26565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff418336030181126139dc57600080fd5b60006106f63683613dcf565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc18336030181126139dc57600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613fc157600080fd5b83018035915067ffffffffffffffff821115613fdc57600080fd5b6020019150600581901b360382131561304e57600080fd5b6000614002613bd284613ad3565b80848252602080830192508560051b85013681111561402057600080fd5b855b8181101561405c57803567ffffffffffffffff8111156140425760008081fd5b61404e36828a01613dcf565b865250938201938201614022565b50919695505050505050565b60006040828403121561407a57600080fd5b612b778383613af7565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126140b957600080fd5b83018035915067ffffffffffffffff8211156140d457600080fd5b6020019150600681901b360382131561304e57600080fd5b600084516140fe818460208901613685565b80830190507f2e00000000000000000000000000000000000000000000000000000000000000808252855161413a816001850160208a01613685565b60019201918201528351614155816002840160208801613685565b0160020195945050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261419757600080fd5b83018035915067ffffffffffffffff8211156141b257600080fd5b602001915060608102360382131561304e57600080fd5b6000606082840312156141db57600080fd5b612b778383613b46565b6000602082840312156141f757600080fd5b612b7782613c26565b600181811c9082168061421457607f821691505b6020821081036137e6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000610100828403121561426057600080fd5b614268613a15565b823581526142798460208501613af7565b602082015261428b8460608501613b46565b604082015260c083013561429e81613706565b60608201526142af60e08401613c26565b60808201529392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036142ec576142ec613d39565b5060010190565b6000602080838503121561430657600080fd5b825167ffffffffffffffff8082111561431e57600080fd5b908401906080828703121561433257600080fd5b61433a613a61565b825181528383015161434b81613706565b81850152604083015161435d81613d7b565b604082015260608301518281111561437457600080fd5b80840193505086601f84011261438957600080fd5b82519150614399613bd283613d89565b82815287858486010111156143ad57600080fd5b6143bc83868301878701613685565b60608201529695505050505050565b601f821115610a2f57600081815260208120601f850160051c810160208610156143f25750805b601f850160051c820191505b81811015614411578281556001016143fe565b505050505050565b815167ffffffffffffffff811115614433576144336139e6565b614447816144418454614200565b846143cb565b602080601f83116001811461449a57600084156144645750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555614411565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156144e7578886015182559484019460019091019084016144c8565b508582101561452357878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261457157614571614533565b500490565b60008261458557614585614533565b500690565b808201808211156106f6576106f6613d39565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061286060408301846136a9565b600082516139dc818460208701613685565b60006020828403121561460957600080fd5b5051919050565b60006020828403121561462257600080fd5b8151612b7781613d7b565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156146a2577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614690868351613805565b95509382019390820190600101614656565b50508584038187015286518085528782019482019350915060005b828110156146d9578451845293810193928101926001016146bd565b5091979650505050505050565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b6058830152846059830152835161477f816079850160208801613685565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a995050505050505050505056fea164736f6c6343000813000a"
func init() {
if err := json.Unmarshal([]byte(EASStorageLayoutJSON), EASStorageLayout); err != nil {
......
......@@ -37,8 +37,8 @@ type IFaultDisputeGameOutputProposal struct {
// FaultDisputeGameMetaData contains all meta data concerning the FaultDisputeGame contract.
var FaultDisputeGameMetaData = &bind.MetaData{
ABI: "[{\"inputs\":[{\"internalType\":\"GameType\",\"name\":\"_gameType\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"Duration\",\"name\":\"_gameDuration\",\"type\":\"uint64\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"},{\"internalType\":\"contractL2OutputOracle\",\"name\":\"_l2oo\",\"type\":\"address\"},{\"internalType\":\"contractBlockOracle\",\"name\":\"_blockOracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"L1HeadTooOld\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BLOCK_ORACLE\",\"outputs\":[{\"internalType\":\"contractBlockOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"GAME_DURATION\",\"outputs\":[{\"internalType\":\"Duration\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"L2_OUTPUT_ORACLE\",\"outputs\":[{\"internalType\":\"contractL2OutputOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"addLocalData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l1BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Head\",\"outputs\":[{\"internalType\":\"Hash\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"proposals\",\"outputs\":[{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"starting\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"disputed\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
Bin: "0x6101c06040523480156200001257600080fd5b5060405162002cb338038062002cb38339810160408190526200003591620000a1565b6000608081905260a052600860c05260ff9096166101a05260e094909452610100929092526001600160401b0316610120526001600160a01b039081166101405290811661016052166101805262000145565b6001600160a01b03811681146200009e57600080fd5b50565b600080600080600080600060e0888a031215620000bd57600080fd5b875160ff81168114620000cf57600080fd5b602089015160408a015160608b015192995090975095506001600160401b0381168114620000fc57600080fd5b60808901519094506200010f8162000088565b60a0890151909350620001228162000088565b60c0890151909250620001358162000088565b8091505092959891949750929550565b60805160a05160c05160e05161010051610120516101405161016051610180516101a051612a976200021c600039600081816105220152611e5d01526000818161035e01526116e701526000818161059b015281816114b40152818161158801526116610152600081816104ec015281816107450152611bdc0152600081816105cf01528181610ab7015261109801526000818161032a015281816109bf01528181610ed701526119e30152600081816102210152611b3f01526000610d3401526000610d0b01526000610ce20152612a976000f3fe6080604052600436106101ac5760003560e01c80636361506d116100ec578063c0c3a0921161008a578063c6f0308c11610064578063c6f0308c1461061d578063cf09e0d014610681578063d8cc1a3c146106a2578063fa24f743146106c257600080fd5b8063c0c3a09214610589578063c31b29ce146105bd578063c55cd0c71461060a57600080fd5b80638b85902b116100c65780638b85902b1461049a57806392931298146104da578063bbdc02db1461050e578063bcef3b551461054c57600080fd5b80636361506d1461045a5780638129fc1c146104705780638980e0cc1461048557600080fd5b8063363cc4271161015957806354fd4d501161013357806354fd4d501461038057806355ef20e6146103a2578063609d333414610432578063632247ea1461044757600080fd5b8063363cc427146102b95780634778efe814610318578063529184c91461034c57600080fd5b80632810e1d61161018a5780632810e1d614610251578063298c90051461026657806335fef567146102a657600080fd5b80631e27052a146101b1578063200d2ed2146101d3578063266198f91461020f575b600080fd5b3480156101bd57600080fd5b506101d16101cc366004612338565b6106e6565b005b3480156101df57600080fd5b506000546101f99068010000000000000000900460ff1681565b6040516102069190612389565b60405180910390f35b34801561021b57600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610206565b34801561025d57600080fd5b506101f96108a5565b34801561027257600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360400135610243565b6101d16102b4366004612338565b610ccb565b3480156102c557600080fd5b506000546102f3906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610206565b34801561032457600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b34801561035857600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561038c57600080fd5b50610395610cdb565b6040516102069190612440565b3480156103ae57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104249182565b60405161020692919061245a565b34801561043e57600080fd5b50610395610d7e565b6101d16104553660046124c3565b610d8c565b34801561046657600080fd5b5061024360015481565b34801561047c57600080fd5b506101d1611360565b34801561049157600080fd5b50600254610243565b3480156104a657600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360200135610243565b3480156104e657600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561051a57600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610206565b34801561055857600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335610243565b34801561059557600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b3480156105c957600080fd5b506105f17f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610206565b6101d1610618366004612338565b6118bd565b34801561062957600080fd5b5061063d6106383660046124f8565b6118c9565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610206565b34801561068d57600080fd5b506000546105f19067ffffffffffffffff1681565b3480156106ae57600080fd5b506101d16106bd36600461255a565b61193a565b3480156106ce57600080fd5b506106d7611e5b565b604051610206939291906125e4565b6000805468010000000000000000900460ff16600281111561070a5761070a61235a565b14610741576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107d2919061260f565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c8190526020859052909150600084600181146108395760028114610843576003811461084d576004811461085757600581146108675763ff137e656000526004601cfd5b600154915061086e565b600454915061086e565b600654915061086e565b60035460801c60c01b915061086e565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af161089f573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff1660028111156108cb576108cb61235a565b14610902576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60025460009061091490600190612674565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff8110156109fe5760006002828154811061094e5761094e61268b565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561099f5750610929565b60028101546000906109e3906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611eb8565b9050838110156109f7578093508260010194505b5050610929565b50600060028381548110610a1457610a1461268b565b600091825260208220600390910201805490925063ffffffff90811691908214610a7e5760028281548110610a4b57610a4b61268b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610aaa565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c16610aee67ffffffffffffffff831642612674565b610b0a836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610b1e91906126ba565b11610b55576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610bf7906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b610c019190612701565b67ffffffffffffffff16158015610c2857506fffffffffffffffffffffffffffffffff8414155b15610c365760029550610c3b565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610c8057610c8061235a565b021790556002811115610c9557610c9561235a565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b905090565b610cd782826000610d8c565b5050565b6060610d067f0000000000000000000000000000000000000000000000000000000000000000611f6d565b610d2f7f0000000000000000000000000000000000000000000000000000000000000000611f6d565b610d587f0000000000000000000000000000000000000000000000000000000000000000611f6d565b604051602001610d6a93929190612728565b604051602081830303815290604052905090565b6060610cc6602060406120aa565b6000805468010000000000000000900460ff166002811115610db057610db061235a565b14610de7576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610df3575080155b15610e2a576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610e3f57610e3f61268b565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610ed39190859061214116565b90507f0000000000000000000000000000000000000000000000000000000000000000610f92826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610fd4576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614611034576002836000015163ffffffff16815481106110035761100361268b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff164261106d846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff1661108191906126ba565b61108b9190612674565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff821611156110fe576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42179050600061111f888660009182526020526040902090565b60008181526007602052604090205490915060ff161561116b576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b9081106112e3576112e361268b565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff9093169290921790915560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff815260208101929092526002919081016113e57ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f00642061150e60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161152c91815260200190565b602060405180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d919061279e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae5576115b8600185612674565b6040518263ffffffff1660e01b81526004016115d691815260200190565b606060405180830381865afa1580156115f3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116179190612806565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa1580156116a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116cc9190612806565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161175891815260200190565b6040805180830381865afa158015611774573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117989190612892565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff16116117f7576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a081018252908190810180611812600189612674565b6fffffffffffffffffffffffffffffffff9081168252604088810151821660208085019190915298519281019290925291835280516060810182529782168852858101518216888801529451878601529085019590955280518051818601519087167001000000000000000000000000000000009188168202176003559084015160045590840151805194810151948616949095160292909217600555919091015160065551600155565b610cd782826001610d8c565b600281815481106118d957600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561195e5761195e61235a565b14611995576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600287815481106119aa576119aa61268b565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b9050611a097f000000000000000000000000000000000000000000000000000000000000000060016126ba565b611aa5826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611ae6576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808915611b6957611b0a836fffffffffffffffffffffffffffffffff16612149565b67ffffffffffffffff1615611b3d57611b34611b27600186612919565b865463ffffffff166121ef565b60010154611b5f565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611b83565b84600101549150611b80846001611b27919061294a565b90505b818989604051611b9492919061297e565b604051809103902014611bd3576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611c3994939291906129d7565b6020604051808303816000875af1158015611c58573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c7c919061279e565b600284810154929091149250600091611d27906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611dc3886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611dcd9190612a09565b611dd79190612701565b67ffffffffffffffff161590508115158103611e1f576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611eb1610d7e565b9050909192565b600080611f45847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b606081600003611fb057505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611fda5780611fc481612a2a565b9150611fd39050600a83612a62565b9150611fb4565b60008167ffffffffffffffff811115611ff557611ff56127b7565b6040519080825280601f01601f19166020018201604052801561201f576020820181803683370190505b5090505b84156120a257612034600183612674565b9150612041600a86612a76565b61204c9060306126ba565b60f81b8183815181106120615761206161268b565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061209b600a86612a62565b9450612023565b949350505050565b606060006120e184367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036126ba565b90508267ffffffffffffffff1667ffffffffffffffff811115612106576121066127b7565b6040519080825280601f01601f191660200182016040528015612130576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806121d6837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b60008061220d846fffffffffffffffffffffffffffffffff1661228c565b9050600283815481106122225761222261268b565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff82811691161461228557815460028054909163ffffffff169081106122705761227061268b565b90600052602060002090600302019150612233565b5092915050565b60008119600183011681612320827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b6000806040838503121561234b57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60208101600383106123c4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60005b838110156123e55781810151838201526020016123cd565b8381111561089f5750506000910152565b6000815180845261240e8160208601602086016123ca565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061245360208301846123f6565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c08101612453565b803580151581146124be57600080fd5b919050565b6000806000606084860312156124d857600080fd5b83359250602084013591506124ef604085016124ae565b90509250925092565b60006020828403121561250a57600080fd5b5035919050565b60008083601f84011261252357600080fd5b50813567ffffffffffffffff81111561253b57600080fd5b60208301915083602082850101111561255357600080fd5b9250929050565b6000806000806000806080878903121561257357600080fd5b86359550612583602088016124ae565b9450604087013567ffffffffffffffff808211156125a057600080fd5b6125ac8a838b01612511565b909650945060608901359150808211156125c557600080fd5b506125d289828a01612511565b979a9699509497509295939492505050565b60ff8416815282602082015260606040820152600061260660608301846123f6565b95945050505050565b60006020828403121561262157600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461245357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561268657612686612645565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082198211156126cd576126cd612645565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff8084168061271c5761271c6126d2565b92169190910692915050565b6000845161273a8184602089016123ca565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612776816001850160208a016123ca565b600192019182015283516127918160028401602088016123ca565b0160020195945050505050565b6000602082840312156127b057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff811681146124be57600080fd5b60006060828403121561281857600080fd5b6040516060810181811067ffffffffffffffff82111715612862577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405282518152612875602084016127e6565b6020820152612886604084016127e6565b60408201529392505050565b6000604082840312156128a457600080fd5b6040516040810167ffffffffffffffff82821081831117156128ef577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461290c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff8381169083168181101561294257612942612645565b039392505050565b60006fffffffffffffffffffffffffffffffff80831681851680830382111561297557612975612645565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b6040815260006129eb60408301868861298e565b82810360208401526129fe81858761298e565b979650505050505050565b600067ffffffffffffffff8381169083168181101561294257612942612645565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612a5b57612a5b612645565b5060010190565b600082612a7157612a716126d2565b500490565b600082612a8557612a856126d2565b50069056fea164736f6c634300080f000a",
ABI: "[{\"inputs\":[{\"internalType\":\"GameType\",\"name\":\"_gameType\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"Duration\",\"name\":\"_gameDuration\",\"type\":\"uint64\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"},{\"internalType\":\"contractL2OutputOracle\",\"name\":\"_l2oo\",\"type\":\"address\"},{\"internalType\":\"contractBlockOracle\",\"name\":\"_blockOracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"L1HeadTooOld\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BLOCK_ORACLE\",\"outputs\":[{\"internalType\":\"contractBlockOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"GAME_DURATION\",\"outputs\":[{\"internalType\":\"Duration\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"L2_OUTPUT_ORACLE\",\"outputs\":[{\"internalType\":\"contractL2OutputOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"addLocalData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l1BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Head\",\"outputs\":[{\"internalType\":\"Hash\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"proposals\",\"outputs\":[{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"starting\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"disputed\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
Bin: "0x6101c06040523480156200001257600080fd5b5060405162002d6238038062002d628339810160408190526200003591620000a1565b6000608081905260a052600960c05260ff9096166101a05260e094909452610100929092526001600160401b0316610120526001600160a01b039081166101405290811661016052166101805262000145565b6001600160a01b03811681146200009e57600080fd5b50565b600080600080600080600060e0888a031215620000bd57600080fd5b875160ff81168114620000cf57600080fd5b602089015160408a015160608b015192995090975095506001600160401b0381168114620000fc57600080fd5b60808901519094506200010f8162000088565b60a0890151909350620001228162000088565b60c0890151909250620001358162000088565b8091505092959891949750929550565b60805160a05160c05160e05161010051610120516101405161016051610180516101a051612b466200021c600039600081816105220152611f0c01526000818161035e015261178d01526000818161059b0152818161155a0152818161162e01526117070152600081816104ec015281816107450152611c8b0152600081816105cf01528181610ab7015261109801526000818161032a015281816109bf01528181610ed70152611a8a0152600081816102210152611be601526000610d3401526000610d0b01526000610ce20152612b466000f3fe6080604052600436106101ac5760003560e01c80636361506d116100ec578063c0c3a0921161008a578063c6f0308c11610064578063c6f0308c1461061d578063cf09e0d014610681578063d8cc1a3c146106a2578063fa24f743146106c257600080fd5b8063c0c3a09214610589578063c31b29ce146105bd578063c55cd0c71461060a57600080fd5b80638b85902b116100c65780638b85902b1461049a57806392931298146104da578063bbdc02db1461050e578063bcef3b551461054c57600080fd5b80636361506d1461045a5780638129fc1c146104705780638980e0cc1461048557600080fd5b8063363cc4271161015957806354fd4d501161013357806354fd4d501461038057806355ef20e6146103a2578063609d333414610432578063632247ea1461044757600080fd5b8063363cc427146102b95780634778efe814610318578063529184c91461034c57600080fd5b80632810e1d61161018a5780632810e1d614610251578063298c90051461026657806335fef567146102a657600080fd5b80631e27052a146101b1578063200d2ed2146101d3578063266198f91461020f575b600080fd5b3480156101bd57600080fd5b506101d16101cc3660046123e7565b6106e6565b005b3480156101df57600080fd5b506000546101f99068010000000000000000900460ff1681565b6040516102069190612438565b60405180910390f35b34801561021b57600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610206565b34801561025d57600080fd5b506101f96108a5565b34801561027257600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360400135610243565b6101d16102b43660046123e7565b610ccb565b3480156102c557600080fd5b506000546102f3906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610206565b34801561032457600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b34801561035857600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561038c57600080fd5b50610395610cdb565b60405161020691906124ef565b3480156103ae57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104249182565b604051610206929190612509565b34801561043e57600080fd5b50610395610d7e565b6101d1610455366004612572565b610d8c565b34801561046657600080fd5b5061024360015481565b34801561047c57600080fd5b506101d1611360565b34801561049157600080fd5b50600254610243565b3480156104a657600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360200135610243565b3480156104e657600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561051a57600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610206565b34801561055857600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335610243565b34801561059557600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b3480156105c957600080fd5b506105f17f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610206565b6101d16106183660046123e7565b611964565b34801561062957600080fd5b5061063d6106383660046125a7565b611970565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610206565b34801561068d57600080fd5b506000546105f19067ffffffffffffffff1681565b3480156106ae57600080fd5b506101d16106bd366004612609565b6119e1565b3480156106ce57600080fd5b506106d7611f0a565b60405161020693929190612693565b6000805468010000000000000000900460ff16600281111561070a5761070a612409565b14610741576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107d291906126be565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c8190526020859052909150600084600181146108395760028114610843576003811461084d576004811461085757600581146108675763ff137e656000526004601cfd5b600154915061086e565b600454915061086e565b600654915061086e565b60035460801c60c01b915061086e565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af161089f573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff1660028111156108cb576108cb612409565b14610902576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60025460009061091490600190612723565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff8110156109fe5760006002828154811061094e5761094e61273a565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561099f5750610929565b60028101546000906109e3906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611f67565b9050838110156109f7578093508260010194505b5050610929565b50600060028381548110610a1457610a1461273a565b600091825260208220600390910201805490925063ffffffff90811691908214610a7e5760028281548110610a4b57610a4b61273a565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610aaa565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c16610aee67ffffffffffffffff831642612723565b610b0a836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610b1e9190612769565b11610b55576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610bf7906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b610c0191906127b0565b67ffffffffffffffff16158015610c2857506fffffffffffffffffffffffffffffffff8414155b15610c365760029550610c3b565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610c8057610c80612409565b021790556002811115610c9557610c95612409565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b905090565b610cd782826000610d8c565b5050565b6060610d067f000000000000000000000000000000000000000000000000000000000000000061201c565b610d2f7f000000000000000000000000000000000000000000000000000000000000000061201c565b610d587f000000000000000000000000000000000000000000000000000000000000000061201c565b604051602001610d6a939291906127d7565b604051602081830303815290604052905090565b6060610cc660206040612159565b6000805468010000000000000000900460ff166002811115610db057610db0612409565b14610de7576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610df3575080155b15610e2a576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610e3f57610e3f61273a565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610ed3919085906121f016565b90507f0000000000000000000000000000000000000000000000000000000000000000610f92826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610fd4576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614611034576002836000015163ffffffff16815481106110035761100361273a565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff164261106d846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff166110819190612769565b61108b9190612723565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff821611156110fe576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42179050600061111f888660009182526020526040902090565b60008181526007602052604090205490915060ff161561116b576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b9081106112e3576112e361273a565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff9093169290921790915560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a60018114806113a0575060ff81166002145b611406576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff8152602081019290925260029190810161148b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f0064206115b460207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b81526004016115d291815260200190565b602060405180830381865afa1580156115ef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611613919061284d565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae55761165e600185612723565b6040518263ffffffff1660e01b815260040161167c91815260200190565b606060405180830381865afa158015611699573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116bd91906128b5565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa15801561174e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061177291906128b5565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b81526004016117fe91815260200190565b6040805180830381865afa15801561181a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061183e9190612941565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff161161189d576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a0810182529081908101806118b8600189612723565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b610cd782826001610d8c565b6002818154811061198057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff166002811115611a0557611a05612409565b14611a3c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028781548110611a5157611a5161273a565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b9050611ab07f00000000000000000000000000000000000000000000000000000000000000006001612769565b611b4c826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611b8d576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808915611c1057611bb1836fffffffffffffffffffffffffffffffff166121f8565b67ffffffffffffffff1615611be457611bdb611bce6001866129c8565b865463ffffffff1661229e565b60010154611c06565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611c2a565b84600101549150611c27846001611bce91906129f9565b90505b600882901b60088a8a604051611c41929190612a2d565b6040518091039020901b14611c82576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611ce89493929190612a86565b6020604051808303816000875af1158015611d07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d2b919061284d565b600284810154929091149250600091611dd6906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611e72886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611e7c9190612ab8565b611e8691906127b0565b67ffffffffffffffff161590508115158103611ece576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611f60610d7e565b9050909192565b600080611ff4847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361205f57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115612089578061207381612ad9565b91506120829050600a83612b11565b9150612063565b60008167ffffffffffffffff8111156120a4576120a4612866565b6040519080825280601f01601f1916602001820160405280156120ce576020820181803683370190505b5090505b8415612151576120e3600183612723565b91506120f0600a86612b25565b6120fb906030612769565b60f81b8183815181106121105761211061273a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061214a600a86612b11565b94506120d2565b949350505050565b6060600061219084367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003612769565b90508267ffffffffffffffff1667ffffffffffffffff8111156121b5576121b5612866565b6040519080825280601f01601f1916602001820160405280156121df576020820181803683370190505b509150828160208401375092915050565b151760011b90565b600080612285837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b6000806122bc846fffffffffffffffffffffffffffffffff1661233b565b9050600283815481106122d1576122d161273a565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff82811691161461233457815460028054909163ffffffff1690811061231f5761231f61273a565b906000526020600020906003020191506122e2565b5092915050565b600081196001830116816123cf827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b600080604083850312156123fa57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310612473577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60005b8381101561249457818101518382015260200161247c565b8381111561089f5750506000910152565b600081518084526124bd816020860160208601612479565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061250260208301846124a5565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c08101612502565b8035801515811461256d57600080fd5b919050565b60008060006060848603121561258757600080fd5b833592506020840135915061259e6040850161255d565b90509250925092565b6000602082840312156125b957600080fd5b5035919050565b60008083601f8401126125d257600080fd5b50813567ffffffffffffffff8111156125ea57600080fd5b60208301915083602082850101111561260257600080fd5b9250929050565b6000806000806000806080878903121561262257600080fd5b863595506126326020880161255d565b9450604087013567ffffffffffffffff8082111561264f57600080fd5b61265b8a838b016125c0565b9096509450606089013591508082111561267457600080fd5b5061268189828a016125c0565b979a9699509497509295939492505050565b60ff841681528260208201526060604082015260006126b560608301846124a5565b95945050505050565b6000602082840312156126d057600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461250257600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015612735576127356126f4565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000821982111561277c5761277c6126f4565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff808416806127cb576127cb612781565b92169190910692915050565b600084516127e9818460208901612479565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612825816001850160208a01612479565b60019201918201528351612840816002840160208801612479565b0160020195945050505050565b60006020828403121561285f57600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461256d57600080fd5b6000606082840312156128c757600080fd5b6040516060810181811067ffffffffffffffff82111715612911577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040528251815261292460208401612895565b602082015261293560408401612895565b60408201529392505050565b60006040828403121561295357600080fd5b6040516040810167ffffffffffffffff828210818311171561299e577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b81604052845183526020850151915080821682146129bb57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156129f1576129f16126f4565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115612a2457612a246126f4565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000612a9a604083018688612a3d565b8281036020840152612aad818587612a3d565b979650505050505050565b600067ffffffffffffffff838116908316818110156129f1576129f16126f4565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612b0a57612b0a6126f4565b5060010190565b600082612b2057612b20612781565b500490565b600082612b3457612b34612781565b50069056fea164736f6c634300080f000a",
}
// FaultDisputeGameABI is the input ABI used to generate the binding from.
......
......@@ -13,7 +13,7 @@ const FaultDisputeGameStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contr
var FaultDisputeGameStorageLayout = new(solc.StorageLayout)
var FaultDisputeGameDeployedBin = "0x6080604052600436106101ac5760003560e01c80636361506d116100ec578063c0c3a0921161008a578063c6f0308c11610064578063c6f0308c1461061d578063cf09e0d014610681578063d8cc1a3c146106a2578063fa24f743146106c257600080fd5b8063c0c3a09214610589578063c31b29ce146105bd578063c55cd0c71461060a57600080fd5b80638b85902b116100c65780638b85902b1461049a57806392931298146104da578063bbdc02db1461050e578063bcef3b551461054c57600080fd5b80636361506d1461045a5780638129fc1c146104705780638980e0cc1461048557600080fd5b8063363cc4271161015957806354fd4d501161013357806354fd4d501461038057806355ef20e6146103a2578063609d333414610432578063632247ea1461044757600080fd5b8063363cc427146102b95780634778efe814610318578063529184c91461034c57600080fd5b80632810e1d61161018a5780632810e1d614610251578063298c90051461026657806335fef567146102a657600080fd5b80631e27052a146101b1578063200d2ed2146101d3578063266198f91461020f575b600080fd5b3480156101bd57600080fd5b506101d16101cc366004612338565b6106e6565b005b3480156101df57600080fd5b506000546101f99068010000000000000000900460ff1681565b6040516102069190612389565b60405180910390f35b34801561021b57600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610206565b34801561025d57600080fd5b506101f96108a5565b34801561027257600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360400135610243565b6101d16102b4366004612338565b610ccb565b3480156102c557600080fd5b506000546102f3906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610206565b34801561032457600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b34801561035857600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561038c57600080fd5b50610395610cdb565b6040516102069190612440565b3480156103ae57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104249182565b60405161020692919061245a565b34801561043e57600080fd5b50610395610d7e565b6101d16104553660046124c3565b610d8c565b34801561046657600080fd5b5061024360015481565b34801561047c57600080fd5b506101d1611360565b34801561049157600080fd5b50600254610243565b3480156104a657600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360200135610243565b3480156104e657600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561051a57600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610206565b34801561055857600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335610243565b34801561059557600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b3480156105c957600080fd5b506105f17f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610206565b6101d1610618366004612338565b6118bd565b34801561062957600080fd5b5061063d6106383660046124f8565b6118c9565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610206565b34801561068d57600080fd5b506000546105f19067ffffffffffffffff1681565b3480156106ae57600080fd5b506101d16106bd36600461255a565b61193a565b3480156106ce57600080fd5b506106d7611e5b565b604051610206939291906125e4565b6000805468010000000000000000900460ff16600281111561070a5761070a61235a565b14610741576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107d2919061260f565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c8190526020859052909150600084600181146108395760028114610843576003811461084d576004811461085757600581146108675763ff137e656000526004601cfd5b600154915061086e565b600454915061086e565b600654915061086e565b60035460801c60c01b915061086e565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af161089f573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff1660028111156108cb576108cb61235a565b14610902576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60025460009061091490600190612674565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff8110156109fe5760006002828154811061094e5761094e61268b565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561099f5750610929565b60028101546000906109e3906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611eb8565b9050838110156109f7578093508260010194505b5050610929565b50600060028381548110610a1457610a1461268b565b600091825260208220600390910201805490925063ffffffff90811691908214610a7e5760028281548110610a4b57610a4b61268b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610aaa565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c16610aee67ffffffffffffffff831642612674565b610b0a836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610b1e91906126ba565b11610b55576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610bf7906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b610c019190612701565b67ffffffffffffffff16158015610c2857506fffffffffffffffffffffffffffffffff8414155b15610c365760029550610c3b565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610c8057610c8061235a565b021790556002811115610c9557610c9561235a565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b905090565b610cd782826000610d8c565b5050565b6060610d067f0000000000000000000000000000000000000000000000000000000000000000611f6d565b610d2f7f0000000000000000000000000000000000000000000000000000000000000000611f6d565b610d587f0000000000000000000000000000000000000000000000000000000000000000611f6d565b604051602001610d6a93929190612728565b604051602081830303815290604052905090565b6060610cc6602060406120aa565b6000805468010000000000000000900460ff166002811115610db057610db061235a565b14610de7576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610df3575080155b15610e2a576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610e3f57610e3f61268b565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610ed39190859061214116565b90507f0000000000000000000000000000000000000000000000000000000000000000610f92826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610fd4576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614611034576002836000015163ffffffff16815481106110035761100361268b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff164261106d846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff1661108191906126ba565b61108b9190612674565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff821611156110fe576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42179050600061111f888660009182526020526040902090565b60008181526007602052604090205490915060ff161561116b576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b9081106112e3576112e361268b565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff9093169290921790915560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff815260208101929092526002919081016113e57ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f00642061150e60207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161152c91815260200190565b602060405180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d919061279e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae5576115b8600185612674565b6040518263ffffffff1660e01b81526004016115d691815260200190565b606060405180830381865afa1580156115f3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116179190612806565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa1580156116a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116cc9190612806565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161175891815260200190565b6040805180830381865afa158015611774573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117989190612892565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff16116117f7576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a081018252908190810180611812600189612674565b6fffffffffffffffffffffffffffffffff9081168252604088810151821660208085019190915298519281019290925291835280516060810182529782168852858101518216888801529451878601529085019590955280518051818601519087167001000000000000000000000000000000009188168202176003559084015160045590840151805194810151948616949095160292909217600555919091015160065551600155565b610cd782826001610d8c565b600281815481106118d957600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561195e5761195e61235a565b14611995576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600287815481106119aa576119aa61268b565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b9050611a097f000000000000000000000000000000000000000000000000000000000000000060016126ba565b611aa5826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611ae6576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808915611b6957611b0a836fffffffffffffffffffffffffffffffff16612149565b67ffffffffffffffff1615611b3d57611b34611b27600186612919565b865463ffffffff166121ef565b60010154611b5f565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611b83565b84600101549150611b80846001611b27919061294a565b90505b818989604051611b9492919061297e565b604051809103902014611bd3576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611c3994939291906129d7565b6020604051808303816000875af1158015611c58573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c7c919061279e565b600284810154929091149250600091611d27906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611dc3886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611dcd9190612a09565b611dd79190612701565b67ffffffffffffffff161590508115158103611e1f576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611eb1610d7e565b9050909192565b600080611f45847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b606081600003611fb057505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611fda5780611fc481612a2a565b9150611fd39050600a83612a62565b9150611fb4565b60008167ffffffffffffffff811115611ff557611ff56127b7565b6040519080825280601f01601f19166020018201604052801561201f576020820181803683370190505b5090505b84156120a257612034600183612674565b9150612041600a86612a76565b61204c9060306126ba565b60f81b8183815181106120615761206161268b565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061209b600a86612a62565b9450612023565b949350505050565b606060006120e184367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036126ba565b90508267ffffffffffffffff1667ffffffffffffffff811115612106576121066127b7565b6040519080825280601f01601f191660200182016040528015612130576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806121d6837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b60008061220d846fffffffffffffffffffffffffffffffff1661228c565b9050600283815481106122225761222261268b565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff82811691161461228557815460028054909163ffffffff169081106122705761227061268b565b90600052602060002090600302019150612233565b5092915050565b60008119600183011681612320827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b6000806040838503121561234b57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60208101600383106123c4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60005b838110156123e55781810151838201526020016123cd565b8381111561089f5750506000910152565b6000815180845261240e8160208601602086016123ca565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061245360208301846123f6565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c08101612453565b803580151581146124be57600080fd5b919050565b6000806000606084860312156124d857600080fd5b83359250602084013591506124ef604085016124ae565b90509250925092565b60006020828403121561250a57600080fd5b5035919050565b60008083601f84011261252357600080fd5b50813567ffffffffffffffff81111561253b57600080fd5b60208301915083602082850101111561255357600080fd5b9250929050565b6000806000806000806080878903121561257357600080fd5b86359550612583602088016124ae565b9450604087013567ffffffffffffffff808211156125a057600080fd5b6125ac8a838b01612511565b909650945060608901359150808211156125c557600080fd5b506125d289828a01612511565b979a9699509497509295939492505050565b60ff8416815282602082015260606040820152600061260660608301846123f6565b95945050505050565b60006020828403121561262157600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461245357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561268657612686612645565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082198211156126cd576126cd612645565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff8084168061271c5761271c6126d2565b92169190910692915050565b6000845161273a8184602089016123ca565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612776816001850160208a016123ca565b600192019182015283516127918160028401602088016123ca565b0160020195945050505050565b6000602082840312156127b057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff811681146124be57600080fd5b60006060828403121561281857600080fd5b6040516060810181811067ffffffffffffffff82111715612862577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405282518152612875602084016127e6565b6020820152612886604084016127e6565b60408201529392505050565b6000604082840312156128a457600080fd5b6040516040810167ffffffffffffffff82821081831117156128ef577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461290c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff8381169083168181101561294257612942612645565b039392505050565b60006fffffffffffffffffffffffffffffffff80831681851680830382111561297557612975612645565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b6040815260006129eb60408301868861298e565b82810360208401526129fe81858761298e565b979650505050505050565b600067ffffffffffffffff8381169083168181101561294257612942612645565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612a5b57612a5b612645565b5060010190565b600082612a7157612a716126d2565b500490565b600082612a8557612a856126d2565b50069056fea164736f6c634300080f000a"
var FaultDisputeGameDeployedBin = "0x6080604052600436106101ac5760003560e01c80636361506d116100ec578063c0c3a0921161008a578063c6f0308c11610064578063c6f0308c1461061d578063cf09e0d014610681578063d8cc1a3c146106a2578063fa24f743146106c257600080fd5b8063c0c3a09214610589578063c31b29ce146105bd578063c55cd0c71461060a57600080fd5b80638b85902b116100c65780638b85902b1461049a57806392931298146104da578063bbdc02db1461050e578063bcef3b551461054c57600080fd5b80636361506d1461045a5780638129fc1c146104705780638980e0cc1461048557600080fd5b8063363cc4271161015957806354fd4d501161013357806354fd4d501461038057806355ef20e6146103a2578063609d333414610432578063632247ea1461044757600080fd5b8063363cc427146102b95780634778efe814610318578063529184c91461034c57600080fd5b80632810e1d61161018a5780632810e1d614610251578063298c90051461026657806335fef567146102a657600080fd5b80631e27052a146101b1578063200d2ed2146101d3578063266198f91461020f575b600080fd5b3480156101bd57600080fd5b506101d16101cc3660046123e7565b6106e6565b005b3480156101df57600080fd5b506000546101f99068010000000000000000900460ff1681565b6040516102069190612438565b60405180910390f35b34801561021b57600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610206565b34801561025d57600080fd5b506101f96108a5565b34801561027257600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360400135610243565b6101d16102b43660046123e7565b610ccb565b3480156102c557600080fd5b506000546102f3906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610206565b34801561032457600080fd5b506102437f000000000000000000000000000000000000000000000000000000000000000081565b34801561035857600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561038c57600080fd5b50610395610cdb565b60405161020691906124ef565b3480156103ae57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104249182565b604051610206929190612509565b34801561043e57600080fd5b50610395610d7e565b6101d1610455366004612572565b610d8c565b34801561046657600080fd5b5061024360015481565b34801561047c57600080fd5b506101d1611360565b34801561049157600080fd5b50600254610243565b3480156104a657600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900360200135610243565b3480156104e657600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b34801561051a57600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610206565b34801561055857600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335610243565b34801561059557600080fd5b506102f37f000000000000000000000000000000000000000000000000000000000000000081565b3480156105c957600080fd5b506105f17f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610206565b6101d16106183660046123e7565b611964565b34801561062957600080fd5b5061063d6106383660046125a7565b611970565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610206565b34801561068d57600080fd5b506000546105f19067ffffffffffffffff1681565b3480156106ae57600080fd5b506101d16106bd366004612609565b6119e1565b3480156106ce57600080fd5b506106d7611f0a565b60405161020693929190612693565b6000805468010000000000000000900460ff16600281111561070a5761070a612409565b14610741576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107d291906126be565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c8190526020859052909150600084600181146108395760028114610843576003811461084d576004811461085757600581146108675763ff137e656000526004601cfd5b600154915061086e565b600454915061086e565b600654915061086e565b60035460801c60c01b915061086e565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af161089f573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff1660028111156108cb576108cb612409565b14610902576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60025460009061091490600190612723565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff8110156109fe5760006002828154811061094e5761094e61273a565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561099f5750610929565b60028101546000906109e3906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611f67565b9050838110156109f7578093508260010194505b5050610929565b50600060028381548110610a1457610a1461273a565b600091825260208220600390910201805490925063ffffffff90811691908214610a7e5760028281548110610a4b57610a4b61273a565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610aaa565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c16610aee67ffffffffffffffff831642612723565b610b0a836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610b1e9190612769565b11610b55576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610bf7906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b610c0191906127b0565b67ffffffffffffffff16158015610c2857506fffffffffffffffffffffffffffffffff8414155b15610c365760029550610c3b565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610c8057610c80612409565b021790556002811115610c9557610c95612409565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b905090565b610cd782826000610d8c565b5050565b6060610d067f000000000000000000000000000000000000000000000000000000000000000061201c565b610d2f7f000000000000000000000000000000000000000000000000000000000000000061201c565b610d587f000000000000000000000000000000000000000000000000000000000000000061201c565b604051602001610d6a939291906127d7565b604051602081830303815290604052905090565b6060610cc660206040612159565b6000805468010000000000000000900460ff166002811115610db057610db0612409565b14610de7576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610df3575080155b15610e2a576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610e3f57610e3f61273a565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610ed3919085906121f016565b90507f0000000000000000000000000000000000000000000000000000000000000000610f92826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610fd4576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614611034576002836000015163ffffffff16815481106110035761100361273a565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff164261106d846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff166110819190612769565b61108b9190612723565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff821611156110fe576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42179050600061111f888660009182526020526040902090565b60008181526007602052604090205490915060ff161561116b576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b9081106112e3576112e361273a565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff9093169290921790915560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a60018114806113a0575060ff81166002145b611406576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff8152602081019290925260029190810161148b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f0064206115b460207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b81526004016115d291815260200190565b602060405180830381865afa1580156115ef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611613919061284d565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae55761165e600185612723565b6040518263ffffffff1660e01b815260040161167c91815260200190565b606060405180830381865afa158015611699573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116bd91906128b5565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa15801561174e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061177291906128b5565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b81526004016117fe91815260200190565b6040805180830381865afa15801561181a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061183e9190612941565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff161161189d576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a0810182529081908101806118b8600189612723565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b610cd782826001610d8c565b6002818154811061198057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff166002811115611a0557611a05612409565b14611a3c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028781548110611a5157611a5161273a565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b9050611ab07f00000000000000000000000000000000000000000000000000000000000000006001612769565b611b4c826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611b8d576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808915611c1057611bb1836fffffffffffffffffffffffffffffffff166121f8565b67ffffffffffffffff1615611be457611bdb611bce6001866129c8565b865463ffffffff1661229e565b60010154611c06565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611c2a565b84600101549150611c27846001611bce91906129f9565b90505b600882901b60088a8a604051611c41929190612a2d565b6040518091039020901b14611c82576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611ce89493929190612a86565b6020604051808303816000875af1158015611d07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d2b919061284d565b600284810154929091149250600091611dd6906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611e72886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611e7c9190612ab8565b611e8691906127b0565b67ffffffffffffffff161590508115158103611ece576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611f60610d7e565b9050909192565b600080611ff4847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361205f57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115612089578061207381612ad9565b91506120829050600a83612b11565b9150612063565b60008167ffffffffffffffff8111156120a4576120a4612866565b6040519080825280601f01601f1916602001820160405280156120ce576020820181803683370190505b5090505b8415612151576120e3600183612723565b91506120f0600a86612b25565b6120fb906030612769565b60f81b8183815181106121105761211061273a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061214a600a86612b11565b94506120d2565b949350505050565b6060600061219084367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003612769565b90508267ffffffffffffffff1667ffffffffffffffff8111156121b5576121b5612866565b6040519080825280601f01601f1916602001820160405280156121df576020820181803683370190505b509150828160208401375092915050565b151760011b90565b600080612285837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b6000806122bc846fffffffffffffffffffffffffffffffff1661233b565b9050600283815481106122d1576122d161273a565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff82811691161461233457815460028054909163ffffffff1690811061231f5761231f61273a565b906000526020600020906003020191506122e2565b5092915050565b600081196001830116816123cf827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b600080604083850312156123fa57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310612473577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60005b8381101561249457818101518382015260200161247c565b8381111561089f5750506000910152565b600081518084526124bd816020860160208601612479565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061250260208301846124a5565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c08101612502565b8035801515811461256d57600080fd5b919050565b60008060006060848603121561258757600080fd5b833592506020840135915061259e6040850161255d565b90509250925092565b6000602082840312156125b957600080fd5b5035919050565b60008083601f8401126125d257600080fd5b50813567ffffffffffffffff8111156125ea57600080fd5b60208301915083602082850101111561260257600080fd5b9250929050565b6000806000806000806080878903121561262257600080fd5b863595506126326020880161255d565b9450604087013567ffffffffffffffff8082111561264f57600080fd5b61265b8a838b016125c0565b9096509450606089013591508082111561267457600080fd5b5061268189828a016125c0565b979a9699509497509295939492505050565b60ff841681528260208201526060604082015260006126b560608301846124a5565b95945050505050565b6000602082840312156126d057600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461250257600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015612735576127356126f4565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000821982111561277c5761277c6126f4565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff808416806127cb576127cb612781565b92169190910692915050565b600084516127e9818460208901612479565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551612825816001850160208a01612479565b60019201918201528351612840816002840160208801612479565b0160020195945050505050565b60006020828403121561285f57600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461256d57600080fd5b6000606082840312156128c757600080fd5b6040516060810181811067ffffffffffffffff82111715612911577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040528251815261292460208401612895565b602082015261293560408401612895565b60408201529392505050565b60006040828403121561295357600080fd5b6040516040810167ffffffffffffffff828210818311171561299e577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b81604052845183526020850151915080821682146129bb57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156129f1576129f16126f4565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115612a2457612a246126f4565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000612a9a604083018688612a3d565b8281036020840152612aad818587612a3d565b979650505050505050565b600067ffffffffffffffff838116908316818110156129f1576129f16126f4565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612b0a57612b0a6126f4565b5060010190565b600082612b2057612b20612781565b500490565b600082612b3457612b34612781565b50069056fea164736f6c634300080f000a"
func init() {
if err := json.Unmarshal([]byte(FaultDisputeGameStorageLayoutJSON), FaultDisputeGameStorageLayout); err != nil {
......
......@@ -31,7 +31,7 @@ var (
// MIPSMetaData contains all meta data concerning the MIPS contract.
var MIPSMetaData = &bind.MetaData{
ABI: "[{\"inputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"_oracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"BRK_START\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"oracle_\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
Bin: "0x60a060405234801561001057600080fd5b50604051611e3e380380611e3e83398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b608051611dad61009160003960008181608501526115730152611dad6000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611cb2565b6100d0565b604051908152602001610062565b60006100da611bdf565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff169052606081015160009061020390826106c1565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff168261077d565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d1e565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d1e565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff166010610877565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d1e565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f6858784876108ea565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff166010610877565b9095019463fffffffc861661043a8160016106c1565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610afa565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b8961077d565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a161561127e565b8063ffffffff16600b03610546576104f3858963ffffffff8a16151561127e565b8063ffffffff16600c0361055c576104f3611364565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f381898988611898565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d1e565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611a92565b6106038583600161127e565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c51605482015261019f5160588201526101bf5160598201526101d851605a8201526000906102009060628101835b60208110156106ac57601c8401518252602090930192600490910190600101610688565b506000815281810382a0819003902092915050565b6000806106cd83611b36565b905060038416156106dd57600080fd5b6020810190358460051c8160005b601b8110156107435760208501943583821c6001168015610713576001811461072857610739565b60008481526020839052604090209350610739565b600082815260208590526040902093505b50506001016106eb565b50608051915081811461075e57630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b6000610787611bdf565b60809050806060015160040163ffffffff16816080015163ffffffff1614610810576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff90811690935285831690529085161561086657806008018261016001518663ffffffff166020811061085557610855611d1e565b63ffffffff90921660209290920201525b61086e610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b01826108d45760006108d6565b815b90861663ffffffff16179250505092915050565b60006108f4611bdf565b608090506000816060015160040163ffffffff16826080015163ffffffff161461097a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f740000000000000000000000006044820152606401610807565b8663ffffffff166004148061099557508663ffffffff166005145b15610a115760008261016001518663ffffffff16602081106109b9576109b9611d1e565b602002015190508063ffffffff168563ffffffff161480156109e157508763ffffffff166004145b80610a0957508063ffffffff168563ffffffff1614158015610a0957508763ffffffff166005145b915050610a8e565b8663ffffffff16600603610a2e5760008460030b13159050610a8e565b8663ffffffff16600703610a4a5760008460030b139050610a8e565b8663ffffffff16600103610a8e57601f601087901c166000819003610a735760008560030b1291505b8063ffffffff16600103610a8c5760008560030b121591505b505b606082018051608084015163ffffffff169091528115610ad4576002610ab98861ffff166010610877565b63ffffffff90811690911b8201600401166080840152610ae6565b60808301805160040163ffffffff1690525b610aee610619565b98975050505050505050565b6000603f601a86901c16801580610b29575060088163ffffffff1610158015610b295750600f8163ffffffff16105b15610f7f57603f86168160088114610b705760098114610b7957600a8114610b8257600b8114610b8b57600c8114610b9457600d8114610b9d57600e8114610ba657610bab565b60209150610bab565b60219150610bab565b602a9150610bab565b602b9150610bab565b60249150610bab565b60259150610bab565b602691505b508063ffffffff16600003610bd25750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610bf85750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610c2e57601f600688901c16610c2463ffffffff8716821c6020839003610877565b9350505050610611565b8063ffffffff16600403610c505750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610c725750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610ca557610c9c8663ffffffff168663ffffffff16901c87602003610877565b92505050610611565b8063ffffffff16600803610cbd578592505050610611565b8063ffffffff16600903610cd5578592505050610611565b8063ffffffff16600a03610ced578592505050610611565b8063ffffffff16600b03610d05578592505050610611565b8063ffffffff16600c03610d1d578592505050610611565b8063ffffffff16600f03610d35578592505050610611565b8063ffffffff16601003610d4d578592505050610611565b8063ffffffff16601103610d65578592505050610611565b8063ffffffff16601203610d7d578592505050610611565b8063ffffffff16601303610d95578592505050610611565b8063ffffffff16601803610dad578592505050610611565b8063ffffffff16601903610dc5578592505050610611565b8063ffffffff16601a03610ddd578592505050610611565b8063ffffffff16601b03610df5578592505050610611565b8063ffffffff16602003610e0e57505050828201610611565b8063ffffffff16602103610e2757505050828201610611565b8063ffffffff16602203610e4057505050818303610611565b8063ffffffff16602303610e5957505050818303610611565b8063ffffffff16602403610e7257505050828216610611565b8063ffffffff16602503610e8b57505050828217610611565b8063ffffffff16602603610ea457505050828218610611565b8063ffffffff16602703610ebe5750505082821719610611565b8063ffffffff16602a03610eef578460030b8660030b12610ee0576000610ee3565b60015b60ff1692505050610611565b8063ffffffff16602b03610f17578463ffffffff168663ffffffff1610610ee0576000610ee3565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e000000000000000000000000006044820152606401610807565b50610f17565b8063ffffffff16601c0361100357603f86166002819003610fa557505050828202610611565b8063ffffffff1660201480610fc057508063ffffffff166021145b15610f79578063ffffffff16602003610fd7579419945b60005b6380000000871615610ff9576401fffffffe600197881b169601610fda565b9250610611915050565b8063ffffffff16600f0361102557505065ffffffff0000601083901b16610611565b8063ffffffff16602003611059576101d38560031660080260180363ffffffff168463ffffffff16901c60ff166008610877565b8063ffffffff1660210361108e576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff166010610877565b8063ffffffff166022036110bd57505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036110d45782915050610611565b8063ffffffff16602403611106578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff16602503611139578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff1660260361116b57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff166028036111a157505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff166029036111d857505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361120757505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b0361121e5783915050610611565b8063ffffffff16602e0361125057505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112675782915050610611565b8063ffffffff16603803610f175783915050610611565b6000611288611bdf565b506080602063ffffffff8616106112fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c69642072656769737465720000000000000000000000000000000000006044820152606401610807565b63ffffffff85161580159061130d5750825b1561134157838161016001518663ffffffff166020811061133057611330611d1e565b63ffffffff90921660209290920201525b60808101805163ffffffff8082166060850152600490910116905261086e610619565b600061136e611bdf565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa036113e85781610fff8116156113b757610fff811661100003015b8363ffffffff166000036113de5760e08801805163ffffffff8382011690915295506113e2565b8395505b50611857565b8563ffffffff16610fcd036114035763400000009450611857565b8563ffffffff166110180361141b5760019450611857565b8563ffffffff166110960361145057600161012088015260ff8316610100880152611444610619565b97505050505050505090565b8563ffffffff16610fa3036116ba5763ffffffff831615611857577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116745760006114ab8363fffffffc1660016106c1565b60208901519091508060001a6001036115185761151581600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa1580156115b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115dd9190611d4d565b915091506003861680600403828110156115f5578092505b5081861015611602578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116598663fffffffc16600186611a92565b60408b018051820163ffffffff16905297506116b592505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff8416016116a957809450611857565b63ffffffff9450600993505b611857565b8563ffffffff16610fa4036117ab5763ffffffff8316600114806116e4575063ffffffff83166002145b806116f5575063ffffffff83166004145b1561170257809450611857565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff8416016116a95760006117428363fffffffc1660016106c1565b6020890151909150600384166004038381101561175d578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b17602088015260006040880152935083611857565b8563ffffffff16610fd703611857578163ffffffff1660030361184b5763ffffffff831615806117e1575063ffffffff83166005145b806117f2575063ffffffff83166003145b156118005760009450611857565b63ffffffff83166001148061181b575063ffffffff83166002145b8061182c575063ffffffff83166006145b8061183d575063ffffffff83166004145b156116a95760019450611857565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b01526004019091169052611444610619565b60006118a2611bdf565b506080600063ffffffff87166010036118c0575060c0810151611a29565b8663ffffffff166011036118df5763ffffffff861660c0830152611a29565b8663ffffffff166012036118f8575060a0810151611a29565b8663ffffffff166013036119175763ffffffff861660a0830152611a29565b8663ffffffff1660180361194b5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a29565b8663ffffffff1660190361197c5763ffffffff86811681871602602081901c821660c08501521660a0830152611a29565b8663ffffffff16601a036119d2578460030b8660030b8161199f5761199f611d71565b0763ffffffff1660c0830152600385810b9087900b816119c1576119c1611d71565b0563ffffffff1660a0830152611a29565b8663ffffffff16601b03611a29578463ffffffff168663ffffffff16816119fb576119fb611d71565b0663ffffffff90811660c084015285811690871681611a1c57611a1c611d71565b0463ffffffff1660a08301525b63ffffffff841615611a6457808261016001518563ffffffff1660208110611a5357611a53611d1e565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611a87610619565b979650505050505050565b6000611a9d83611b36565b90506003841615611aad57600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b2b5760208401933582821c6001168015611afb5760018114611b1057611b21565b60008581526020839052604090209450611b21565b600082815260208690526040902094505b5050600101611ad3565b505060805250505050565b60ff811661038002610184810190369061050401811015611bd9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f61746100000000000000000000000000000000000000000000000000000000006064820152608401610807565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611c45611c4a565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611c7b57600080fd5b50813567ffffffffffffffff811115611c9357600080fd5b602083019150836020828501011115611cab57600080fd5b9250929050565b60008060008060408587031215611cc857600080fd5b843567ffffffffffffffff80821115611ce057600080fd5b611cec88838901611c69565b90965094506020870135915080821115611d0557600080fd5b50611d1287828801611c69565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611d6057600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a",
Bin: "0x60a060405234801561001057600080fd5b50604051611eb2380380611eb283398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b608051611e2161009160003960008181608501526115e70152611e216000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d26565b6100d0565b604051908152602001610062565b60006100da611c53565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610735565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f1565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d92565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d92565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108eb565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d92565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f68587848761095e565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff1660106108eb565b9095019463fffffffc861661043a816001610735565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b6e565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f1565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f2565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f2565b8063ffffffff16600c0361055c576104f36113d8565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f38189898861190c565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d92565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611b06565b610603858360016112f2565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106b857601c8601518452602090950194600490930192600101610694565b506000835283830384a06000945080600181146106d85760039550610700565b8280156106f057600181146106f957600296506106fe565b600096506106fe565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074183611baa565b9050600384161561075157600080fd5b6020810190358460051c8160005b601b8110156107b75760208501943583821c6001168015610787576001811461079c576107ad565b600084815260208390526040902093506107ad565b600082815260208590526040902093505b505060010161075f565b5060805191508181146107d257630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fb611c53565b60809050806060015160040163ffffffff16816080015163ffffffff1614610884576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108da57806008018261016001518663ffffffff16602081106108c9576108c9611d92565b63ffffffff90921660209290920201525b6108e2610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b018261094857600061094a565b815b90861663ffffffff16179250505092915050565b6000610968611c53565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087b565b8663ffffffff1660041480610a0957508663ffffffff166005145b15610a855760008261016001518663ffffffff1660208110610a2d57610a2d611d92565b602002015190508063ffffffff168563ffffffff16148015610a5557508763ffffffff166004145b80610a7d57508063ffffffff168563ffffffff1614158015610a7d57508763ffffffff166005145b915050610b02565b8663ffffffff16600603610aa25760008460030b13159050610b02565b8663ffffffff16600703610abe5760008460030b139050610b02565b8663ffffffff16600103610b0257601f601087901c166000819003610ae75760008560030b1291505b8063ffffffff16600103610b005760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b48576002610b2d8861ffff1660106108eb565b63ffffffff90811690911b8201600401166080840152610b5a565b60808301805160040163ffffffff1690525b610b62610619565b98975050505050505050565b6000603f601a86901c16801580610b9d575060088163ffffffff1610158015610b9d5750600f8163ffffffff16105b15610ff357603f86168160088114610be45760098114610bed57600a8114610bf657600b8114610bff57600c8114610c0857600d8114610c1157600e8114610c1a57610c1f565b60209150610c1f565b60219150610c1f565b602a9150610c1f565b602b9150610c1f565b60249150610c1f565b60259150610c1f565b602691505b508063ffffffff16600003610c465750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610c6c5750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610ca257601f600688901c16610c9863ffffffff8716821c60208390036108eb565b9350505050610611565b8063ffffffff16600403610cc45750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610ce65750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610d1957610d108663ffffffff168663ffffffff16901c876020036108eb565b92505050610611565b8063ffffffff16600803610d31578592505050610611565b8063ffffffff16600903610d49578592505050610611565b8063ffffffff16600a03610d61578592505050610611565b8063ffffffff16600b03610d79578592505050610611565b8063ffffffff16600c03610d91578592505050610611565b8063ffffffff16600f03610da9578592505050610611565b8063ffffffff16601003610dc1578592505050610611565b8063ffffffff16601103610dd9578592505050610611565b8063ffffffff16601203610df1578592505050610611565b8063ffffffff16601303610e09578592505050610611565b8063ffffffff16601803610e21578592505050610611565b8063ffffffff16601903610e39578592505050610611565b8063ffffffff16601a03610e51578592505050610611565b8063ffffffff16601b03610e69578592505050610611565b8063ffffffff16602003610e8257505050828201610611565b8063ffffffff16602103610e9b57505050828201610611565b8063ffffffff16602203610eb457505050818303610611565b8063ffffffff16602303610ecd57505050818303610611565b8063ffffffff16602403610ee657505050828216610611565b8063ffffffff16602503610eff57505050828217610611565b8063ffffffff16602603610f1857505050828218610611565b8063ffffffff16602703610f325750505082821719610611565b8063ffffffff16602a03610f63578460030b8660030b12610f54576000610f57565b60015b60ff1692505050610611565b8063ffffffff16602b03610f8b578463ffffffff168663ffffffff1610610f54576000610f57565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087b565b50610f8b565b8063ffffffff16601c0361107757603f8616600281900361101957505050828202610611565b8063ffffffff166020148061103457508063ffffffff166021145b15610fed578063ffffffff1660200361104b579419945b60005b638000000087161561106d576401fffffffe600197881b16960161104e565b9250610611915050565b8063ffffffff16600f0361109957505065ffffffff0000601083901b16610611565b8063ffffffff166020036110cd576101d38560031660080260180363ffffffff168463ffffffff16901c60ff1660086108eb565b8063ffffffff16602103611102576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108eb565b8063ffffffff1660220361113157505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036111485782915050610611565b8063ffffffff1660240361117a578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff166025036111ad578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff166026036111df57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff1660280361121557505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff1660290361124c57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361127b57505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b036112925783915050610611565b8063ffffffff16602e036112c457505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112db5782915050610611565b8063ffffffff16603803610f8b5783915050610611565b60006112fc611c53565b506080602063ffffffff86161061136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087b565b63ffffffff8516158015906113815750825b156113b557838161016001518663ffffffff16602081106113a4576113a4611d92565b63ffffffff90921660209290920201525b60808101805163ffffffff808216606085015260049091011690526108e2610619565b60006113e2611c53565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa0361145c5781610fff81161561142b57610fff811661100003015b8363ffffffff166000036114525760e08801805163ffffffff838201169091529550611456565b8395505b506118cb565b8563ffffffff16610fcd0361147757634000000094506118cb565b8563ffffffff166110180361148f57600194506118cb565b8563ffffffff16611096036114c457600161012088015260ff83166101008801526114b8610619565b97505050505050505090565b8563ffffffff16610fa30361172e5763ffffffff8316156118cb577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116e857600061151f8363fffffffc166001610735565b60208901519091508060001a60010361158c5761158981600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa15801561162d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116519190611dc1565b91509150600386168060040382811015611669578092505b5081861015611676578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116cd8663fffffffc16600186611b06565b60408b018051820163ffffffff169052975061172992505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff84160161171d578094506118cb565b63ffffffff9450600993505b6118cb565b8563ffffffff16610fa40361181f5763ffffffff831660011480611758575063ffffffff83166002145b80611769575063ffffffff83166004145b15611776578094506118cb565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff84160161171d5760006117b68363fffffffc166001610735565b602089015190915060038416600403838110156117d1578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118cb565b8563ffffffff16610fd7036118cb578163ffffffff166003036118bf5763ffffffff83161580611855575063ffffffff83166005145b80611866575063ffffffff83166003145b1561187457600094506118cb565b63ffffffff83166001148061188f575063ffffffff83166002145b806118a0575063ffffffff83166006145b806118b1575063ffffffff83166004145b1561171d57600194506118cb565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114b8610619565b6000611916611c53565b506080600063ffffffff8716601003611934575060c0810151611a9d565b8663ffffffff166011036119535763ffffffff861660c0830152611a9d565b8663ffffffff1660120361196c575060a0810151611a9d565b8663ffffffff1660130361198b5763ffffffff861660a0830152611a9d565b8663ffffffff166018036119bf5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a9d565b8663ffffffff166019036119f05763ffffffff86811681871602602081901c821660c08501521660a0830152611a9d565b8663ffffffff16601a03611a46578460030b8660030b81611a1357611a13611de5565b0763ffffffff1660c0830152600385810b9087900b81611a3557611a35611de5565b0563ffffffff1660a0830152611a9d565b8663ffffffff16601b03611a9d578463ffffffff168663ffffffff1681611a6f57611a6f611de5565b0663ffffffff90811660c084015285811690871681611a9057611a90611de5565b0463ffffffff1660a08301525b63ffffffff841615611ad857808261016001518563ffffffff1660208110611ac757611ac7611d92565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611afb610619565b979650505050505050565b6000611b1183611baa565b90506003841615611b2157600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b9f5760208401933582821c6001168015611b6f5760018114611b8457611b95565b60008581526020839052604090209450611b95565b600082815260208690526040902094505b5050600101611b47565b505060805250505050565b60ff811661038002610184810190369061050401811015611c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087b565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cb9611cbe565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cef57600080fd5b50813567ffffffffffffffff811115611d0757600080fd5b602083019150836020828501011115611d1f57600080fd5b9250929050565b60008060008060408587031215611d3c57600080fd5b843567ffffffffffffffff80821115611d5457600080fd5b611d6088838901611cdd565b90965094506020870135915080821115611d7957600080fd5b50611d8687828801611cdd565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611dd457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a",
}
// MIPSABI is the input ABI used to generate the binding from.
......
......@@ -13,9 +13,9 @@ const MIPSStorageLayoutJSON = "{\"storage\":null,\"types\":{}}"
var MIPSStorageLayout = new(solc.StorageLayout)
var MIPSDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611cb2565b6100d0565b604051908152602001610062565b60006100da611bdf565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff169052606081015160009061020390826106c1565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff168261077d565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d1e565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d1e565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff166010610877565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d1e565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f6858784876108ea565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff166010610877565b9095019463fffffffc861661043a8160016106c1565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610afa565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b8961077d565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a161561127e565b8063ffffffff16600b03610546576104f3858963ffffffff8a16151561127e565b8063ffffffff16600c0361055c576104f3611364565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f381898988611898565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d1e565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611a92565b6106038583600161127e565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c51605482015261019f5160588201526101bf5160598201526101d851605a8201526000906102009060628101835b60208110156106ac57601c8401518252602090930192600490910190600101610688565b506000815281810382a0819003902092915050565b6000806106cd83611b36565b905060038416156106dd57600080fd5b6020810190358460051c8160005b601b8110156107435760208501943583821c6001168015610713576001811461072857610739565b60008481526020839052604090209350610739565b600082815260208590526040902093505b50506001016106eb565b50608051915081811461075e57630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b6000610787611bdf565b60809050806060015160040163ffffffff16816080015163ffffffff1614610810576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff90811690935285831690529085161561086657806008018261016001518663ffffffff166020811061085557610855611d1e565b63ffffffff90921660209290920201525b61086e610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b01826108d45760006108d6565b815b90861663ffffffff16179250505092915050565b60006108f4611bdf565b608090506000816060015160040163ffffffff16826080015163ffffffff161461097a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f740000000000000000000000006044820152606401610807565b8663ffffffff166004148061099557508663ffffffff166005145b15610a115760008261016001518663ffffffff16602081106109b9576109b9611d1e565b602002015190508063ffffffff168563ffffffff161480156109e157508763ffffffff166004145b80610a0957508063ffffffff168563ffffffff1614158015610a0957508763ffffffff166005145b915050610a8e565b8663ffffffff16600603610a2e5760008460030b13159050610a8e565b8663ffffffff16600703610a4a5760008460030b139050610a8e565b8663ffffffff16600103610a8e57601f601087901c166000819003610a735760008560030b1291505b8063ffffffff16600103610a8c5760008560030b121591505b505b606082018051608084015163ffffffff169091528115610ad4576002610ab98861ffff166010610877565b63ffffffff90811690911b8201600401166080840152610ae6565b60808301805160040163ffffffff1690525b610aee610619565b98975050505050505050565b6000603f601a86901c16801580610b29575060088163ffffffff1610158015610b295750600f8163ffffffff16105b15610f7f57603f86168160088114610b705760098114610b7957600a8114610b8257600b8114610b8b57600c8114610b9457600d8114610b9d57600e8114610ba657610bab565b60209150610bab565b60219150610bab565b602a9150610bab565b602b9150610bab565b60249150610bab565b60259150610bab565b602691505b508063ffffffff16600003610bd25750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610bf85750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610c2e57601f600688901c16610c2463ffffffff8716821c6020839003610877565b9350505050610611565b8063ffffffff16600403610c505750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610c725750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610ca557610c9c8663ffffffff168663ffffffff16901c87602003610877565b92505050610611565b8063ffffffff16600803610cbd578592505050610611565b8063ffffffff16600903610cd5578592505050610611565b8063ffffffff16600a03610ced578592505050610611565b8063ffffffff16600b03610d05578592505050610611565b8063ffffffff16600c03610d1d578592505050610611565b8063ffffffff16600f03610d35578592505050610611565b8063ffffffff16601003610d4d578592505050610611565b8063ffffffff16601103610d65578592505050610611565b8063ffffffff16601203610d7d578592505050610611565b8063ffffffff16601303610d95578592505050610611565b8063ffffffff16601803610dad578592505050610611565b8063ffffffff16601903610dc5578592505050610611565b8063ffffffff16601a03610ddd578592505050610611565b8063ffffffff16601b03610df5578592505050610611565b8063ffffffff16602003610e0e57505050828201610611565b8063ffffffff16602103610e2757505050828201610611565b8063ffffffff16602203610e4057505050818303610611565b8063ffffffff16602303610e5957505050818303610611565b8063ffffffff16602403610e7257505050828216610611565b8063ffffffff16602503610e8b57505050828217610611565b8063ffffffff16602603610ea457505050828218610611565b8063ffffffff16602703610ebe5750505082821719610611565b8063ffffffff16602a03610eef578460030b8660030b12610ee0576000610ee3565b60015b60ff1692505050610611565b8063ffffffff16602b03610f17578463ffffffff168663ffffffff1610610ee0576000610ee3565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e000000000000000000000000006044820152606401610807565b50610f17565b8063ffffffff16601c0361100357603f86166002819003610fa557505050828202610611565b8063ffffffff1660201480610fc057508063ffffffff166021145b15610f79578063ffffffff16602003610fd7579419945b60005b6380000000871615610ff9576401fffffffe600197881b169601610fda565b9250610611915050565b8063ffffffff16600f0361102557505065ffffffff0000601083901b16610611565b8063ffffffff16602003611059576101d38560031660080260180363ffffffff168463ffffffff16901c60ff166008610877565b8063ffffffff1660210361108e576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff166010610877565b8063ffffffff166022036110bd57505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036110d45782915050610611565b8063ffffffff16602403611106578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff16602503611139578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff1660260361116b57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff166028036111a157505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff166029036111d857505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361120757505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b0361121e5783915050610611565b8063ffffffff16602e0361125057505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112675782915050610611565b8063ffffffff16603803610f175783915050610611565b6000611288611bdf565b506080602063ffffffff8616106112fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c69642072656769737465720000000000000000000000000000000000006044820152606401610807565b63ffffffff85161580159061130d5750825b1561134157838161016001518663ffffffff166020811061133057611330611d1e565b63ffffffff90921660209290920201525b60808101805163ffffffff8082166060850152600490910116905261086e610619565b600061136e611bdf565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa036113e85781610fff8116156113b757610fff811661100003015b8363ffffffff166000036113de5760e08801805163ffffffff8382011690915295506113e2565b8395505b50611857565b8563ffffffff16610fcd036114035763400000009450611857565b8563ffffffff166110180361141b5760019450611857565b8563ffffffff166110960361145057600161012088015260ff8316610100880152611444610619565b97505050505050505090565b8563ffffffff16610fa3036116ba5763ffffffff831615611857577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116745760006114ab8363fffffffc1660016106c1565b60208901519091508060001a6001036115185761151581600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa1580156115b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115dd9190611d4d565b915091506003861680600403828110156115f5578092505b5081861015611602578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116598663fffffffc16600186611a92565b60408b018051820163ffffffff16905297506116b592505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff8416016116a957809450611857565b63ffffffff9450600993505b611857565b8563ffffffff16610fa4036117ab5763ffffffff8316600114806116e4575063ffffffff83166002145b806116f5575063ffffffff83166004145b1561170257809450611857565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff8416016116a95760006117428363fffffffc1660016106c1565b6020890151909150600384166004038381101561175d578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b17602088015260006040880152935083611857565b8563ffffffff16610fd703611857578163ffffffff1660030361184b5763ffffffff831615806117e1575063ffffffff83166005145b806117f2575063ffffffff83166003145b156118005760009450611857565b63ffffffff83166001148061181b575063ffffffff83166002145b8061182c575063ffffffff83166006145b8061183d575063ffffffff83166004145b156116a95760019450611857565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b01526004019091169052611444610619565b60006118a2611bdf565b506080600063ffffffff87166010036118c0575060c0810151611a29565b8663ffffffff166011036118df5763ffffffff861660c0830152611a29565b8663ffffffff166012036118f8575060a0810151611a29565b8663ffffffff166013036119175763ffffffff861660a0830152611a29565b8663ffffffff1660180361194b5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a29565b8663ffffffff1660190361197c5763ffffffff86811681871602602081901c821660c08501521660a0830152611a29565b8663ffffffff16601a036119d2578460030b8660030b8161199f5761199f611d71565b0763ffffffff1660c0830152600385810b9087900b816119c1576119c1611d71565b0563ffffffff1660a0830152611a29565b8663ffffffff16601b03611a29578463ffffffff168663ffffffff16816119fb576119fb611d71565b0663ffffffff90811660c084015285811690871681611a1c57611a1c611d71565b0463ffffffff1660a08301525b63ffffffff841615611a6457808261016001518563ffffffff1660208110611a5357611a53611d1e565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611a87610619565b979650505050505050565b6000611a9d83611b36565b90506003841615611aad57600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b2b5760208401933582821c6001168015611afb5760018114611b1057611b21565b60008581526020839052604090209450611b21565b600082815260208690526040902094505b5050600101611ad3565b505060805250505050565b60ff811661038002610184810190369061050401811015611bd9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f61746100000000000000000000000000000000000000000000000000000000006064820152608401610807565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611c45611c4a565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611c7b57600080fd5b50813567ffffffffffffffff811115611c9357600080fd5b602083019150836020828501011115611cab57600080fd5b9250929050565b60008060008060408587031215611cc857600080fd5b843567ffffffffffffffff80821115611ce057600080fd5b611cec88838901611c69565b90965094506020870135915080821115611d0557600080fd5b50611d1287828801611c69565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611d6057600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a"
var MIPSDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d26565b6100d0565b604051908152602001610062565b60006100da611c53565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610735565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f1565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d92565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d92565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108eb565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d92565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f68587848761095e565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff1660106108eb565b9095019463fffffffc861661043a816001610735565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b6e565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f1565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f2565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f2565b8063ffffffff16600c0361055c576104f36113d8565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f38189898861190c565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d92565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611b06565b610603858360016112f2565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106b857601c8601518452602090950194600490930192600101610694565b506000835283830384a06000945080600181146106d85760039550610700565b8280156106f057600181146106f957600296506106fe565b600096506106fe565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074183611baa565b9050600384161561075157600080fd5b6020810190358460051c8160005b601b8110156107b75760208501943583821c6001168015610787576001811461079c576107ad565b600084815260208390526040902093506107ad565b600082815260208590526040902093505b505060010161075f565b5060805191508181146107d257630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fb611c53565b60809050806060015160040163ffffffff16816080015163ffffffff1614610884576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108da57806008018261016001518663ffffffff16602081106108c9576108c9611d92565b63ffffffff90921660209290920201525b6108e2610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b018261094857600061094a565b815b90861663ffffffff16179250505092915050565b6000610968611c53565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087b565b8663ffffffff1660041480610a0957508663ffffffff166005145b15610a855760008261016001518663ffffffff1660208110610a2d57610a2d611d92565b602002015190508063ffffffff168563ffffffff16148015610a5557508763ffffffff166004145b80610a7d57508063ffffffff168563ffffffff1614158015610a7d57508763ffffffff166005145b915050610b02565b8663ffffffff16600603610aa25760008460030b13159050610b02565b8663ffffffff16600703610abe5760008460030b139050610b02565b8663ffffffff16600103610b0257601f601087901c166000819003610ae75760008560030b1291505b8063ffffffff16600103610b005760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b48576002610b2d8861ffff1660106108eb565b63ffffffff90811690911b8201600401166080840152610b5a565b60808301805160040163ffffffff1690525b610b62610619565b98975050505050505050565b6000603f601a86901c16801580610b9d575060088163ffffffff1610158015610b9d5750600f8163ffffffff16105b15610ff357603f86168160088114610be45760098114610bed57600a8114610bf657600b8114610bff57600c8114610c0857600d8114610c1157600e8114610c1a57610c1f565b60209150610c1f565b60219150610c1f565b602a9150610c1f565b602b9150610c1f565b60249150610c1f565b60259150610c1f565b602691505b508063ffffffff16600003610c465750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610c6c5750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610ca257601f600688901c16610c9863ffffffff8716821c60208390036108eb565b9350505050610611565b8063ffffffff16600403610cc45750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610ce65750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610d1957610d108663ffffffff168663ffffffff16901c876020036108eb565b92505050610611565b8063ffffffff16600803610d31578592505050610611565b8063ffffffff16600903610d49578592505050610611565b8063ffffffff16600a03610d61578592505050610611565b8063ffffffff16600b03610d79578592505050610611565b8063ffffffff16600c03610d91578592505050610611565b8063ffffffff16600f03610da9578592505050610611565b8063ffffffff16601003610dc1578592505050610611565b8063ffffffff16601103610dd9578592505050610611565b8063ffffffff16601203610df1578592505050610611565b8063ffffffff16601303610e09578592505050610611565b8063ffffffff16601803610e21578592505050610611565b8063ffffffff16601903610e39578592505050610611565b8063ffffffff16601a03610e51578592505050610611565b8063ffffffff16601b03610e69578592505050610611565b8063ffffffff16602003610e8257505050828201610611565b8063ffffffff16602103610e9b57505050828201610611565b8063ffffffff16602203610eb457505050818303610611565b8063ffffffff16602303610ecd57505050818303610611565b8063ffffffff16602403610ee657505050828216610611565b8063ffffffff16602503610eff57505050828217610611565b8063ffffffff16602603610f1857505050828218610611565b8063ffffffff16602703610f325750505082821719610611565b8063ffffffff16602a03610f63578460030b8660030b12610f54576000610f57565b60015b60ff1692505050610611565b8063ffffffff16602b03610f8b578463ffffffff168663ffffffff1610610f54576000610f57565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087b565b50610f8b565b8063ffffffff16601c0361107757603f8616600281900361101957505050828202610611565b8063ffffffff166020148061103457508063ffffffff166021145b15610fed578063ffffffff1660200361104b579419945b60005b638000000087161561106d576401fffffffe600197881b16960161104e565b9250610611915050565b8063ffffffff16600f0361109957505065ffffffff0000601083901b16610611565b8063ffffffff166020036110cd576101d38560031660080260180363ffffffff168463ffffffff16901c60ff1660086108eb565b8063ffffffff16602103611102576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108eb565b8063ffffffff1660220361113157505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036111485782915050610611565b8063ffffffff1660240361117a578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff166025036111ad578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff166026036111df57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff1660280361121557505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff1660290361124c57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361127b57505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b036112925783915050610611565b8063ffffffff16602e036112c457505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112db5782915050610611565b8063ffffffff16603803610f8b5783915050610611565b60006112fc611c53565b506080602063ffffffff86161061136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087b565b63ffffffff8516158015906113815750825b156113b557838161016001518663ffffffff16602081106113a4576113a4611d92565b63ffffffff90921660209290920201525b60808101805163ffffffff808216606085015260049091011690526108e2610619565b60006113e2611c53565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa0361145c5781610fff81161561142b57610fff811661100003015b8363ffffffff166000036114525760e08801805163ffffffff838201169091529550611456565b8395505b506118cb565b8563ffffffff16610fcd0361147757634000000094506118cb565b8563ffffffff166110180361148f57600194506118cb565b8563ffffffff16611096036114c457600161012088015260ff83166101008801526114b8610619565b97505050505050505090565b8563ffffffff16610fa30361172e5763ffffffff8316156118cb577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116e857600061151f8363fffffffc166001610735565b60208901519091508060001a60010361158c5761158981600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa15801561162d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116519190611dc1565b91509150600386168060040382811015611669578092505b5081861015611676578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116cd8663fffffffc16600186611b06565b60408b018051820163ffffffff169052975061172992505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff84160161171d578094506118cb565b63ffffffff9450600993505b6118cb565b8563ffffffff16610fa40361181f5763ffffffff831660011480611758575063ffffffff83166002145b80611769575063ffffffff83166004145b15611776578094506118cb565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff84160161171d5760006117b68363fffffffc166001610735565b602089015190915060038416600403838110156117d1578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118cb565b8563ffffffff16610fd7036118cb578163ffffffff166003036118bf5763ffffffff83161580611855575063ffffffff83166005145b80611866575063ffffffff83166003145b1561187457600094506118cb565b63ffffffff83166001148061188f575063ffffffff83166002145b806118a0575063ffffffff83166006145b806118b1575063ffffffff83166004145b1561171d57600194506118cb565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114b8610619565b6000611916611c53565b506080600063ffffffff8716601003611934575060c0810151611a9d565b8663ffffffff166011036119535763ffffffff861660c0830152611a9d565b8663ffffffff1660120361196c575060a0810151611a9d565b8663ffffffff1660130361198b5763ffffffff861660a0830152611a9d565b8663ffffffff166018036119bf5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a9d565b8663ffffffff166019036119f05763ffffffff86811681871602602081901c821660c08501521660a0830152611a9d565b8663ffffffff16601a03611a46578460030b8660030b81611a1357611a13611de5565b0763ffffffff1660c0830152600385810b9087900b81611a3557611a35611de5565b0563ffffffff1660a0830152611a9d565b8663ffffffff16601b03611a9d578463ffffffff168663ffffffff1681611a6f57611a6f611de5565b0663ffffffff90811660c084015285811690871681611a9057611a90611de5565b0463ffffffff1660a08301525b63ffffffff841615611ad857808261016001518563ffffffff1660208110611ac757611ac7611d92565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611afb610619565b979650505050505050565b6000611b1183611baa565b90506003841615611b2157600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b9f5760208401933582821c6001168015611b6f5760018114611b8457611b95565b60008581526020839052604090209450611b95565b600082815260208690526040902094505b5050600101611b47565b505060805250505050565b60ff811661038002610184810190369061050401811015611c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087b565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cb9611cbe565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cef57600080fd5b50813567ffffffffffffffff811115611d0757600080fd5b602083019150836020828501011115611d1f57600080fd5b9250929050565b60008060008060408587031215611d3c57600080fd5b843567ffffffffffffffff80821115611d5457600080fd5b611d6088838901611cdd565b90965094506020870135915080821115611d7957600080fd5b50611d8687828801611cdd565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611dd457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a"
var MIPSDeployedSourceMap = "1131:38919:105:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1710:45;;1745:10;1710:45;;;;;188:10:257;176:23;;;158:42;;146:2;131:18;1710:45:105;;;;;;;;2448:99;;;412:42:257;2534:6:105;400:55:257;382:74;;370:2;355:18;2448:99:105;211:251:257;24930:6339:105;;;;;;:::i;:::-;;:::i;:::-;;;1687:25:257;;;1675:2;1660:18;24930:6339:105;1541:177:257;24930:6339:105;25008:7;25051:18;;:::i;:::-;25198:4;25191:5;25188:15;25178:134;;25292:1;25289;25282:12;25178:134;25348:4;25342:11;25355;25339:28;25329:137;;25446:1;25443;25436:12;25329:137;25514:3;25496:16;25493:25;25483:150;;25613:1;25610;25603:12;25483:150;25677:3;25663:12;25660:21;25650:145;;25775:1;25772;25765:12;25650:145;26055:24;;26399:4;26101:20;26457:2;26159:21;;26055:24;26217:18;26101:20;26159:21;;;26055:24;26032:21;26028:52;;;26217:18;26101:20;;;26159:21;;;26055:24;26028:52;;26101:20;;26159:21;;;26055:24;26028:52;;26217:18;26101:20;26159:21;;;26055:24;26028:52;;26217:18;26101:20;26159:21;;;26055:24;26028:52;;26217:18;26101:20;26159:21;;;26055:24;26028:52;;;26217:18;26101:20;26159:21;;;26055:24;26032:21;26028:52;;;26217:18;26101:20;26159:21;;;26055:24;26028:52;;26217:18;26101:20;26159:21;;;26055:24;26028:52;;26217:18;26101:20;27075:10;26217:18;27065:21;;;26159;;;;27173:1;27158:77;27183:2;27180:1;27177:9;27158:77;;;26055:24;;26032:21;26028:52;26101:20;;27231:1;26159:21;;;;26043:2;26217:18;;;;27201:1;27194:9;27158:77;;;27162:14;;;27313:5;:12;;;27309:71;;;27352:13;:11;:13::i;:::-;27345:20;;;;;27309:71;27394:10;;;:15;;27408:1;27394:15;;;;;27479:8;;;;-1:-1:-1;;27471:20:105;;-1:-1:-1;27471:7:105;:20::i;:::-;27457:34;-1:-1:-1;27521:10:105;27529:2;27521:10;;;;27598:1;27588:11;;;:26;;;27603:6;:11;;27613:1;27603:11;27588:26;27584:310;;;27744:13;27813:1;27791:4;27798:10;27791:17;27790:24;;;;27761:5;:12;;;27776:10;27761:25;27760:54;27744:70;;27839:40;27850:6;:11;;27860:1;27850:11;:20;;27868:2;27850:20;;;27864:1;27850:20;27839:40;;27872:6;27839:10;:40::i;:::-;27832:47;;;;;;;;27584:310;28143:15;;;;27938:9;;;;28075:4;28069:2;28061:10;;;28060:19;;;28143:15;28168:2;28160:10;;;28159:19;28143:36;;;;;;;:::i;:::-;;;;;;-1:-1:-1;28208:5:105;28232:11;;;;;:29;;;28247:6;:14;;28257:4;28247:14;28232:29;28228:832;;;28324:5;:15;;;28340:5;28324:22;;;;;;;;;:::i;:::-;;;;;;-1:-1:-1;;28387:4:105;28381:2;28373:10;;;28372:19;28228:832;;;28425:4;28416:6;:13;;;28412:648;;;28546:6;:13;;28556:3;28546:13;:30;;;;28563:6;:13;;28573:3;28563:13;28546:30;:47;;;;28580:6;:13;;28590:3;28580:13;28546:47;28542:253;;;28656:4;28663:6;28656:13;28651:18;;28412:648;;28542:253;28755:21;28758:4;28765:6;28758:13;28773:2;28755;:21::i;:::-;28750:26;;28412:648;;;28829:4;28819:6;:14;;;;:32;;;;28837:6;:14;;28847:4;28837:14;28819:32;:50;;;;28855:6;:14;;28865:4;28855:14;28819:50;28815:245;;;28939:5;:15;;;28955:5;28939:22;;;;;;;;;:::i;:::-;;;;;28934:27;;29040:5;29032:13;;28815:245;29089:1;29079:6;:11;;;;:25;;;;;29103:1;29094:6;:10;;;29079:25;29078:42;;;;29109:6;:11;;29119:1;29109:11;29078:42;29074:125;;;29147:37;29160:6;29168:4;29174:5;29181:2;29147:12;:37::i;:::-;29140:44;;;;;;;;;;;29074:125;29232:13;29213:16;29384:4;29374:14;;;;29370:446;;29453:21;29456:4;29463:6;29456:13;29471:2;29453;:21::i;:::-;29447:27;;;;29511:10;29506:15;;29545:16;29506:15;29559:1;29545:7;:16::i;:::-;29539:22;;29593:4;29583:6;:14;;;;:32;;;;;29601:6;:14;;29611:4;29601:14;;29583:32;29579:223;;;29680:4;29668:16;;29782:1;29774:9;;29579:223;29390:426;29370:446;29849:10;29862:26;29870:4;29876:2;29880;29884:3;29862:7;:26::i;:::-;29891:10;29862:39;;;;-1:-1:-1;29987:4:105;29980:11;;;30019;;;:24;;;;;30042:1;30034:4;:9;;;;30019:24;:39;;;;;30054:4;30047;:11;;;30019:39;30015:847;;;30082:4;:9;;30090:1;30082:9;:22;;;;30095:4;:9;;30103:1;30095:9;30082:22;30078:144;;;30166:37;30177:4;:9;;30185:1;30177:9;:21;;30193:5;30177:21;;;30189:1;30177:21;30200:2;30166:10;:37::i;:::-;30159:44;;;;;;;;;;;;;;;30078:144;30244:4;:11;;30252:3;30244:11;30240:121;;30314:28;30323:5;30330:2;30334:7;;;;30314:8;:28::i;30240:121::-;30382:4;:11;;30390:3;30382:11;30378:121;;30452:28;30461:5;30468:2;30472:7;;;;;30452:8;:28::i;30378:121::-;30569:4;:11;;30577:3;30569:11;30565:80;;30611:15;:13;:15::i;30565:80::-;30748:4;30740;:12;;;;:27;;;;;30763:4;30756;:11;;;30740:27;30736:112;;;30798:31;30809:4;30815:2;30819;30823:5;30798:10;:31::i;30736:112::-;30922:6;:14;;30932:4;30922:14;:28;;;;-1:-1:-1;30940:10:105;;;;;30922:28;30918:93;;;30995:1;30970:5;:15;;;30986:5;30970:22;;;;;;;;;:::i;:::-;:26;;;;:22;;;;;;:26;30918:93;31057:9;:26;;31070:13;31057:26;31053:92;;31103:27;31112:9;31123:1;31126:3;31103:8;:27::i;:::-;31226:26;31235:5;31242:3;31247:4;31226:8;:26::i;:::-;31219:33;;;;;;;;;;;;;24930:6339;;;;;;;:::o;3092:1709::-;3639:4;3633:11;;3555:4;3358:31;3347:43;;3418:13;3358:31;3757:2;3457:13;;3347:43;3364:24;3358:31;3457:13;;;3347:43;;;;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3133:12;;4342:13;;3457;;;3133:12;4422:84;4447:2;4444:1;4441:9;4422:84;;;3374:13;3364:24;;3358:31;3347:43;;3378:2;3418:13;;;;4502:1;3457:13;;;;4465:1;4458:9;4422:84;;;4426:14;4569:1;4565:2;4558:13;4664:5;4660:2;4656:14;4649:5;4644:27;4770:14;;;4753:32;;;3092:1709;-1:-1:-1;;3092:1709:105:o;20985:1831::-;21058:11;21169:14;21186:24;21198:11;21186;:24::i;:::-;21169:41;;21318:1;21311:5;21307:13;21304:33;;;21333:1;21330;21323:12;21304:33;21466:2;21454:15;;;21407:20;21896:5;21893:1;21889:13;21931:4;21967:1;21952:343;21977:2;21974:1;21971:9;21952:343;;;22100:2;22088:15;;;22037:20;22135:12;;;22149:1;22131:20;22172:42;;;;22240:1;22235:42;;;;22124:153;;22172:42;21630:1;21623:12;;;21663:2;21656:13;;;21708:2;21695:16;;22181:31;;22172:42;;22235;21630:1;21623:12;;;21663:2;21656:13;;;21708:2;21695:16;;22244:31;;22124:153;-1:-1:-1;;21995:1:105;21988:9;21952:343;;;21956:14;22405:4;22399:11;22384:26;;22491:7;22485:4;22482:17;22472:124;;22533:10;22530:1;22523:21;22575:2;22572:1;22565:13;22472:124;-1:-1:-1;;22723:2:105;22712:14;;;;22700:10;22696:31;22693:1;22689:39;22757:16;;;;22775:10;22753:33;;20985:1831;-1:-1:-1;;;20985:1831:105:o;18095:823::-;18164:12;18251:18;;:::i;:::-;18319:4;18310:13;;18371:5;:8;;;18382:1;18371:12;18355:28;;:5;:12;;;:28;;;18351:95;;18403:28;;;;;2114:2:257;18403:28:105;;;2096:21:257;2153:2;2133:18;;;2126:30;2192:20;2172:18;;;2165:48;2230:18;;18403:28:105;;;;;;;;18351:95;18535:8;;;;;18568:12;;;;;18557:23;;;;;;;18594:20;;;;;18535:8;18726:13;;;18722:90;;18787:6;18796:1;18787:10;18759:5;:15;;;18775:8;18759:25;;;;;;;;;:::i;:::-;:38;;;;:25;;;;;;:38;18722:90;18888:13;:11;:13::i;:::-;18881:20;18095:823;-1:-1:-1;;;;;18095:823:105:o;2645:339::-;2706:11;2770:18;;;;2779:8;;;;2770:18;;;;;;2769:25;;;;;2786:1;2833:2;:9;;;2827:16;;;;;2826:22;;2825:32;;;;;;;2887:9;;2886:15;2769:25;2944:21;;2964:1;2944:21;;;2955:6;2944:21;2929:11;;;;;:37;;-1:-1:-1;;;2645:339:105;;;;:::o;12956:2026::-;13053:12;13139:18;;:::i;:::-;13207:4;13198:13;;13239:17;13299:5;:8;;;13310:1;13299:12;13283:28;;:5;:12;;;:28;;;13279:97;;13331:30;;;;;2461:2:257;13331:30:105;;;2443:21:257;2500:2;2480:18;;;2473:30;2539:22;2519:18;;;2512:50;2579:18;;13331:30:105;2259:344:257;13279:97:105;13446:7;:12;;13457:1;13446:12;:28;;;;13462:7;:12;;13473:1;13462:12;13446:28;13442:947;;;13494:9;13506:5;:15;;;13522:6;13506:23;;;;;;;;;:::i;:::-;;;;;13494:35;;13570:2;13563:9;;:3;:9;;;:25;;;;;13576:7;:12;;13587:1;13576:12;13563:25;13562:58;;;;13601:2;13594:9;;:3;:9;;;;:25;;;;;13607:7;:12;;13618:1;13607:12;13594:25;13547:73;;13476:159;13442:947;;;13732:7;:12;;13743:1;13732:12;13728:661;;13793:1;13785:3;13779:15;;;;13764:30;;13728:661;;;13897:7;:12;;13908:1;13897:12;13893:496;;13957:1;13950:3;13944:14;;;13929:29;;13893:496;;;14078:7;:12;;14089:1;14078:12;14074:315;;14166:4;14160:2;14151:11;;;14150:20;14136:10;14193:8;;;14189:84;;14253:1;14246:3;14240:14;;;14225:29;;14189:84;14294:3;:8;;14301:1;14294:8;14290:85;;14355:1;14347:3;14341:15;;;;14326:30;;14290:85;14092:297;14074:315;14465:8;;;;;14543:12;;;;14532:23;;;;;14699:178;;;;14790:1;14764:22;14767:5;14775:6;14767:14;14783:2;14764;:22::i;:::-;:27;;;;;;;14750:42;;14759:1;14750:42;14735:57;:12;;;:57;14699:178;;;14846:12;;;;;14861:1;14846:16;14831:31;;;;14699:178;14952:13;:11;:13::i;:::-;14945:20;12956:2026;-1:-1:-1;;;;;;;;12956:2026:105:o;31315:8733::-;31402:10;31464;31472:2;31464:10;;;;31503:11;;;:44;;;31529:1;31519:6;:11;;;;:27;;;;;31543:3;31534:6;:12;;;31519:27;31499:8490;;;31588:4;31581:11;;31712:6;31772:3;31767:25;;;;31847:3;31842:25;;;;31921:3;31916:25;;;;31996:3;31991:25;;;;32070:3;32065:25;;;;32143:3;32138:25;;;;32217:3;32212:25;;;;31705:532;;31767:25;31786:4;31778:12;;31767:25;;31842;31861:4;31853:12;;31842:25;;31916;31935:4;31927:12;;31916:25;;31991;32010:4;32002:12;;31991:25;;32065;32084:4;32076:12;;32065:25;;32138;32157:4;32149:12;;32138:25;;32212;32231:4;32223:12;;31705:532;;32300:4;:12;;32308:4;32300:12;32296:4023;;-1:-1:-1;;;32351:9:105;32343:26;;32364:4;32359:1;32351:9;;;32350:18;32343:26;32336:33;;32296:4023;32437:4;:12;;32445:4;32437:12;32433:3886;;-1:-1:-1;;;32488:9:105;32480:26;;32501:4;32496:1;32488:9;;;32487:18;32480:26;32473:33;;32433:3886;32574:4;:12;;32582:4;32574:12;32570:3749;;32639:4;32634:1;32626:9;;;32625:18;32672:27;32626:9;32675:11;;;;32688:2;:10;;;32672:2;:27::i;:::-;32665:34;;;;;;;32570:3749;32768:4;:12;;32776:4;32768:12;32764:3555;;-1:-1:-1;;;32811:17:105;;;32823:4;32818:9;;32811:17;32804:24;;32764:3555;32897:4;:11;;32905:3;32897:11;32893:3426;;-1:-1:-1;;;32939:17:105;;;32951:4;32946:9;;32939:17;32932:24;;32893:3426;33025:4;:12;;33033:4;33025:12;33021:3298;;33068:21;33077:2;33071:8;;:2;:8;;;;33086:2;33081;:7;33068:2;:21::i;:::-;33061:28;;;;;;33021:3298;33338:4;:12;;33346:4;33338:12;33334:2985;;33381:2;33374:9;;;;;;33334:2985;33452:4;:12;;33460:4;33452:12;33448:2871;;33495:2;33488:9;;;;;;33448:2871;33566:4;:12;;33574:4;33566:12;33562:2757;;33609:2;33602:9;;;;;;33562:2757;33680:4;:12;;33688:4;33680:12;33676:2643;;33723:2;33716:9;;;;;;33676:2643;33797:4;:12;;33805:4;33797:12;33793:2526;;33840:2;33833:9;;;;;;33793:2526;33957:4;:12;;33965:4;33957:12;33953:2366;;34000:2;33993:9;;;;;;33953:2366;34071:4;:12;;34079:4;34071:12;34067:2252;;34114:2;34107:9;;;;;;34067:2252;34185:4;:12;;34193:4;34185:12;34181:2138;;34228:2;34221:9;;;;;;34181:2138;34299:4;:12;;34307:4;34299:12;34295:2024;;34342:2;34335:9;;;;;;34295:2024;34413:4;:12;;34421:4;34413:12;34409:1910;;34456:2;34449:9;;;;;;34409:1910;34527:4;:12;;34535:4;34527:12;34523:1796;;34570:2;34563:9;;;;;;34523:1796;34642:4;:12;;34650:4;34642:12;34638:1681;;34685:2;34678:9;;;;;;34638:1681;34755:4;:12;;34763:4;34755:12;34751:1568;;34798:2;34791:9;;;;;;34751:1568;34869:4;:12;;34877:4;34869:12;34865:1454;;34912:2;34905:9;;;;;;34865:1454;35061:4;:12;;35069:4;35061:12;35057:1262;;-1:-1:-1;;;35105:7:105;;;35097:16;;35057:1262;35182:4;:12;;35190:4;35182:12;35178:1141;;-1:-1:-1;;;35226:7:105;;;35218:16;;35178:1141;35302:4;:12;;35310:4;35302:12;35298:1021;;-1:-1:-1;;;35346:7:105;;;35338:16;;35298:1021;35423:4;:12;;35431:4;35423:12;35419:900;;-1:-1:-1;;;35467:7:105;;;35459:16;;35419:900;35543:4;:12;;35551:4;35543:12;35539:780;;-1:-1:-1;;;35587:7:105;;;35579:16;;35539:780;35662:4;:12;;35670:4;35662:12;35658:661;;-1:-1:-1;;;35706:7:105;;;35698:16;;35658:661;35782:4;:12;;35790:4;35782:12;35778:541;;-1:-1:-1;;;35826:7:105;;;35818:16;;35778:541;35902:4;:12;;35910:4;35902:12;35898:421;;-1:-1:-1;;;35947:7:105;;;35945:10;35938:17;;35898:421;36024:4;:12;;36032:4;36024:12;36020:299;;36085:2;36067:21;;36073:2;36067:21;;;:29;;36095:1;36067:29;;;36091:1;36067:29;36060:36;;;;;;;;36020:299;36166:4;:12;;36174:4;36166:12;36162:157;;36214:2;36209:7;;:2;:7;;;:15;;36223:1;36209:15;;36162:157;36271:29;;;;;2810:2:257;36271:29:105;;;2792:21:257;2849:2;2829:18;;;2822:30;2888:21;2868:18;;;2861:49;2927:18;;36271:29:105;2608:343:257;36162:157:105;31549:4784;31499:8490;;;36389:6;:14;;36399:4;36389:14;36385:3590;;36448:4;36441:11;;36523:3;36515:11;;;36511:549;;-1:-1:-1;;;36568:21:105;;;36554:36;;36511:549;36675:4;:12;;36683:4;36675:12;:28;;;;36691:4;:12;;36699:4;36691:12;36675:28;36671:389;;;36735:4;:12;;36743:4;36735:12;36731:83;;36784:3;;;36731:83;36839:8;36877:127;36889:10;36884:15;;:20;36877:127;;36969:8;36936:3;36969:8;;;;;36936:3;36877:127;;;37036:1;-1:-1:-1;37029:8:105;;-1:-1:-1;;37029:8:105;36385:3590;37127:6;:14;;37137:4;37127:14;37123:2852;;-1:-1:-1;;37172:8:105;37178:2;37172:8;;;;37165:15;;37123:2852;37247:6;:14;;37257:4;37247:14;37243:2732;;37292:42;37310:2;37315:1;37310:6;37320:1;37309:12;37304:2;:17;37296:26;;:3;:26;;;;37326:4;37295:35;37332:1;37292:2;:42::i;37243:2732::-;37401:6;:14;;37411:4;37401:14;37397:2578;;37446:45;37464:2;37469:1;37464:6;37474:1;37463:12;37458:2;:17;37450:26;;:3;:26;;;;37480:6;37449:37;37488:2;37446;:45::i;37397:2578::-;37559:6;:14;;37569:4;37559:14;37555:2420;;-1:-1:-1;;37610:21:105;37629:1;37624;37619:6;;37618:12;37610:21;;37667:36;;;37738:5;37733:10;;37610:21;;;;;37732:18;37725:25;;37555:2420;37817:6;:14;;37827:4;37817:14;37813:2162;;37862:3;37855:10;;;;;37813:2162;37933:6;:14;;37943:4;37933:14;37929:2046;;37993:2;37998:1;37993:6;38003:1;37992:12;37987:2;:17;37979:26;;:3;:26;;;;38009:4;37978:35;37971:42;;;;;37929:2046;38082:6;:14;;38092:4;38082:14;38078:1897;;38142:2;38147:1;38142:6;38152:1;38141:12;38136:2;:17;38128:26;;:3;:26;;;;38158:6;38127:37;38120:44;;;;;38078:1897;38233:6;:14;;38243:4;38233:14;38229:1746;;-1:-1:-1;;38284:26:105;38308:1;38303;38298:6;;38297:12;38292:2;:17;38284:26;;38346:41;;;38422:5;38417:10;;38284:26;;;;;38416:18;38409:25;;38229:1746;38502:6;:14;;38512:4;38502:14;38498:1477;;-1:-1:-1;;38559:4:105;38553:34;38585:1;38580;38575:6;;38574:12;38569:2;:17;38553:34;;38643:27;;;38623:48;;;38701:10;;38554:9;;;38553:34;;38700:18;38693:25;;38498:1477;38786:6;:14;;38796:4;38786:14;38782:1193;;-1:-1:-1;;38843:6:105;38837:36;38871:1;38866;38861:6;;38860:12;38855:2;:17;38837:36;;38929:29;;;38909:50;;;38989:10;;38838:11;;;38837:36;;38988:18;38981:25;;38782:1193;39075:6;:14;;39085:4;39075:14;39071:904;;-1:-1:-1;;39126:20:105;39144:1;39139;39134:6;;39133:12;39126:20;;39182:36;;;39254:5;39248:11;;39126:20;;;;;39247:19;39240:26;;39071:904;39334:6;:14;;39344:4;39334:14;39330:645;;39379:2;39372:9;;;;;39330:645;39450:6;:14;;39460:4;39450:14;39446:529;;-1:-1:-1;;39501:25:105;39524:1;39519;39514:6;;39513:12;39508:2;:17;39501:25;;39562:41;;;39639:5;39633:11;;39501:25;;;;;39632:19;39625:26;;39446:529;39718:6;:14;;39728:4;39718:14;39714:261;;39763:3;39756:10;;;;;39714:261;39833:6;:14;;39843:4;39833:14;39829:146;;39878:2;39871:9;;;;;19199:782;19285:12;19372:18;;:::i;:::-;-1:-1:-1;19440:4:105;19547:2;19535:14;;;;19527:41;;;;;;;3158:2:257;19527:41:105;;;3140:21:257;3197:2;3177:18;;;3170:30;3236:16;3216:18;;;3209:44;3270:18;;19527:41:105;2956:338:257;19527:41:105;19664:14;;;;;;;:30;;;19682:12;19664:30;19660:102;;;19743:4;19714:5;:15;;;19730:9;19714:26;;;;;;;;;:::i;:::-;:33;;;;:26;;;;;;:33;19660:102;19817:12;;;;;19806:23;;;;:8;;;:23;19873:1;19858:16;;;19843:31;;;19951:13;:11;:13::i;4842:7728::-;4885:12;4971:18;;:::i;:::-;-1:-1:-1;5149:15:105;;:18;;;;5039:4;5309:18;;;;5353;;;;5397;;;;;5039:4;;5129:17;;;;5309:18;5353;5487;;;5501:4;5487:18;5483:6777;;5537:2;5566:4;5561:9;;:14;5557:144;;5677:4;5672:9;;5664:4;:18;5658:24;5557:144;5722:2;:7;;5728:1;5722:7;5718:161;;5758:10;;;;;5790:16;;;;;;;;5758:10;-1:-1:-1;5718:161:105;;;5858:2;5853:7;;5718:161;5507:386;5483:6777;;;5995:10;:18;;6009:4;5995:18;5991:6269;;1745:10;6033:14;;5991:6269;;;6131:10;:18;;6145:4;6131:18;6127:6133;;6174:1;6169:6;;6127:6133;;;6299:10;:18;;6313:4;6299:18;6295:5965;;6352:4;6337:12;;;:19;6374:26;;;:14;;;:26;6425:13;:11;:13::i;:::-;6418:20;;;;;;;;;4842:7728;:::o;6295:5965::-;6564:10;:18;;6578:4;6564:18;6560:5700;;6715:14;;;6711:2708;6560:5700;6711:2708;6885:22;;;;;6881:2538;;7010:10;7023:27;7031:2;7036:10;7031:15;7048:1;7023:7;:27::i;:::-;7134:17;;;;7010:40;;-1:-1:-1;7134:17:105;7112:19;7284:14;7303:1;7278:26;7274:131;;7346:36;7370:11;1277:21:106;1426:15;;;1467:8;1461:4;1454:22;1595:4;1582:18;;1602:19;1578:44;1624:11;1575:61;;1222:430;7346:36:105;7332:50;;7274:131;7491:20;;;;;7458:54;;;;;;;;3472:25:257;;;7458:54:105;3533:23:257;;;3513:18;;;3506:51;7427:11:105;;;;7458:19;:6;:19;;;;3445:18:257;;7458:54:105;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;7426:86;;;;7739:1;7735:2;7731:10;7836:9;7833:1;7829:17;7918:6;7911:5;7908:17;7905:40;;;7938:5;7928:15;;7905:40;;8021:6;8017:2;8014:14;8011:34;;;8041:2;8031:12;;8011:34;8147:3;8142:1;8134:6;8130:14;8125:3;8121:24;8117:34;8110:41;;8247:3;8243:1;8231:9;8222:6;8219:1;8215:14;8211:30;8207:38;8203:48;8196:55;;8402:1;8398;8394;8382:9;8379:1;8375:17;8371:25;8367:33;8363:41;8529:1;8525;8521;8512:6;8500:9;8497:1;8493:17;8489:30;8485:38;8481:46;8477:54;8459:72;;8660:10;8656:15;8650:4;8646:26;8638:34;;8776:3;8768:4;8764:9;8759:3;8755:19;8752:28;8745:35;;;;8922:33;8931:2;8936:10;8931:15;8948:1;8951:3;8922:8;:33::i;:::-;8977:20;;;:38;;;;;;;;;-1:-1:-1;6881:2538:105;;-1:-1:-1;;;6881:2538:105;;9134:18;;;;;9130:289;;9304:2;9299:7;;6560:5700;;9130:289;9358:10;9353:15;;2053:3;9390:10;;9130:289;6560:5700;;;9548:10;:18;;9562:4;9548:18;9544:2716;;9702:15;;;1824:1;9702:15;;:34;;-1:-1:-1;9721:15:105;;;1859:1;9721:15;9702:34;:57;;;-1:-1:-1;9740:19:105;;;1936:1;9740:19;9702:57;9698:1593;;;9788:2;9783:7;;9544:2716;;9698:1593;9914:23;;;;;9910:1381;;9961:10;9974:27;9982:2;9987:10;9982:15;9999:1;9974:7;:27::i;:::-;10077:17;;;;9961:40;;-1:-1:-1;10320:1:105;10312:10;;10414:1;10410:17;10489:13;;;10486:32;;;10511:5;10505:11;;10486:32;10797:14;;;10603:1;10793:22;;;10789:32;;;;10686:26;10710:1;10595:10;;;10690:18;;;10686:26;10785:43;10591:20;;10893:12;11021:17;;;:23;11089:1;11066:20;;;:24;10599:2;-1:-1:-1;10599:2:105;6560:5700;;9544:2716;11493:10;:18;;11507:4;11493:18;11489:771;;11603:2;:7;;11609:1;11603:7;11599:647;;11696:14;;;;;:40;;-1:-1:-1;11714:22:105;;;1978:1;11714:22;11696:40;:62;;;-1:-1:-1;11740:18:105;;;1897:1;11740:18;11696:62;11692:404;;;11791:1;11786:6;;11599:647;;11692:404;11837:15;;;1824:1;11837:15;;:34;;-1:-1:-1;11856:15:105;;;1859:1;11856:15;11837:34;:61;;;-1:-1:-1;11875:23:105;;;2021:1;11875:23;11837:61;:84;;;-1:-1:-1;11902:19:105;;;1936:1;11902:19;11837:84;11833:263;;;11954:1;11949:6;;6560:5700;;11599:647;12147:10;12142:15;;2087:4;12179:11;;11599:647;12335:15;;;;;:23;;;;:18;;;;:23;;;;12372:15;;:23;;;:18;;;;:23;-1:-1:-1;12461:12:105;;;;12450:23;;;:8;;;:23;12517:1;12502:16;12487:31;;;;;12540:13;:11;:13::i;15323:2480::-;15417:12;15503:18;;:::i;:::-;-1:-1:-1;15571:4:105;15603:10;15711:13;;;15720:4;15711:13;15707:1705;;-1:-1:-1;15750:8:105;;;;15707:1705;;;15869:5;:13;;15878:4;15869:13;15865:1547;;15902:14;;;:8;;;:14;15865:1547;;;16032:5;:13;;16041:4;16032:13;16028:1384;;-1:-1:-1;16071:8:105;;;;16028:1384;;;16190:5;:13;;16199:4;16190:13;16186:1226;;16223:14;;;:8;;;:14;16186:1226;;;16364:5;:13;;16373:4;16364:13;16360:1052;;16491:9;16437:17;16417;;;16437;;;;16417:37;16498:2;16491:9;;;;;16473:8;;;:28;16519:22;:8;;;:22;16360:1052;;;16678:5;:13;;16687:4;16678:13;16674:738;;16745:11;16731;;;16745;;;16731:25;16800:2;16793:9;;;;;16775:8;;;:28;16821:22;:8;;;:22;16674:738;;;17002:5;:13;;17011:4;17002:13;16998:414;;17072:3;17053:23;;17059:3;17053:23;;;;;;;:::i;:::-;;17035:42;;:8;;;:42;17113:23;;;;;;;;;;;;;:::i;:::-;;17095:42;;:8;;;:42;16998:414;;;17306:5;:13;;17315:4;17306:13;17302:110;;17356:3;17350:9;;:3;:9;;;;;;;:::i;:::-;;17339:20;;;;:8;;;:20;17388:9;;;;;;;;;;;:::i;:::-;;17377:20;;:8;;;:20;17302:110;17505:14;;;;17501:85;;17568:3;17539:5;:15;;;17555:9;17539:26;;;;;;;;;:::i;:::-;:32;;;;:26;;;;;;:32;17501:85;17640:12;;;;;17629:23;;;;:8;;;:23;17696:1;17681:16;;;17666:31;;;17773:13;:11;:13::i;:::-;17766:20;15323:2480;-1:-1:-1;;;;;;;15323:2480:105:o;23152:1654::-;23328:14;23345:24;23357:11;23345;:24::i;:::-;23328:41;;23477:1;23470:5;23466:13;23463:33;;;23492:1;23489;23482:12;23463:33;23631:2;23825:15;;;23650:2;23639:14;;23627:10;23623:31;23620:1;23616:39;23781:16;;;23566:20;;23766:10;23755:22;;;23751:27;23741:38;23738:60;24267:5;24264:1;24260:13;24338:1;24323:343;24348:2;24345:1;24342:9;24323:343;;;24471:2;24459:15;;;24408:20;24506:12;;;24520:1;24502:20;24543:42;;;;24611:1;24606:42;;;;24495:153;;24543:42;21630:1;21623:12;;;21663:2;21656:13;;;21708:2;21695:16;;24552:31;;24543:42;;24606;21630:1;21623:12;;;21663:2;21656:13;;;21708:2;21695:16;;24615:31;;24495:153;-1:-1:-1;;24366:1:105;24359:9;24323:343;;;-1:-1:-1;;24765:4:105;24758:18;-1:-1:-1;;;;23152:1654:105:o;20185:586::-;20507:20;;;20531:7;20507:32;20500:3;:40;;;20613:14;;20668:17;;20662:24;;;20654:72;;;;;;;4209:2:257;20654:72:105;;;4191:21:257;4248:2;4228:18;;;4221:30;4287:34;4267:18;;;4260:62;4358:5;4338:18;;;4331:33;4381:19;;20654:72:105;4007:399:257;20654:72:105;20740:14;20185:586;;;:::o;-1:-1:-1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;467:347:257:-;518:8;528:6;582:3;575:4;567:6;563:17;559:27;549:55;;600:1;597;590:12;549:55;-1:-1:-1;623:20:257;;666:18;655:30;;652:50;;;698:1;695;688:12;652:50;735:4;727:6;723:17;711:29;;787:3;780:4;771:6;763;759:19;755:30;752:39;749:59;;;804:1;801;794:12;749:59;467:347;;;;;:::o;819:717::-;909:6;917;925;933;986:2;974:9;965:7;961:23;957:32;954:52;;;1002:1;999;992:12;954:52;1042:9;1029:23;1071:18;1112:2;1104:6;1101:14;1098:34;;;1128:1;1125;1118:12;1098:34;1167:58;1217:7;1208:6;1197:9;1193:22;1167:58;:::i;:::-;1244:8;;-1:-1:-1;1141:84:257;-1:-1:-1;1332:2:257;1317:18;;1304:32;;-1:-1:-1;1348:16:257;;;1345:36;;;1377:1;1374;1367:12;1345:36;;1416:60;1468:7;1457:8;1446:9;1442:24;1416:60;:::i;:::-;819:717;;;;-1:-1:-1;1495:8:257;-1:-1:-1;;;;819:717:257:o;1723:184::-;1775:77;1772:1;1765:88;1872:4;1869:1;1862:15;1896:4;1893:1;1886:15;3568:245;3647:6;3655;3708:2;3696:9;3687:7;3683:23;3679:32;3676:52;;;3724:1;3721;3714:12;3676:52;-1:-1:-1;;3747:16:257;;3803:2;3788:18;;;3782:25;3747:16;;3782:25;;-1:-1:-1;3568:245:257:o;3818:184::-;3870:77;3867:1;3860:88;3967:4;3964:1;3957:15;3991:4;3988:1;3981:15"
var MIPSDeployedSourceMap = "1131:39544:105:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1710:45;;1745:10;1710:45;;;;;188:10:257;176:23;;;158:42;;146:2;131:18;1710:45:105;;;;;;;;2448:99;;;412:42:257;2534:6:105;400:55:257;382:74;;370:2;355:18;2448:99:105;211:251:257;25555:6339:105;;;;;;:::i;:::-;;:::i;:::-;;;1687:25:257;;;1675:2;1660:18;25555:6339:105;1541:177:257;25555:6339:105;25633:7;25676:18;;:::i;:::-;25823:4;25816:5;25813:15;25803:134;;25917:1;25914;25907:12;25803:134;25973:4;25967:11;25980;25964:28;25954:137;;26071:1;26068;26061:12;25954:137;26139:3;26121:16;26118:25;26108:150;;26238:1;26235;26228:12;26108:150;26302:3;26288:12;26285:21;26275:145;;26400:1;26397;26390:12;26275:145;26680:24;;27024:4;26726:20;27082:2;26784:21;;26680:24;26842:18;26726:20;26784:21;;;26680:24;26657:21;26653:52;;;26842:18;26726:20;;;26784:21;;;26680:24;26653:52;;26726:20;;26784:21;;;26680:24;26653:52;;26842:18;26726:20;26784:21;;;26680:24;26653:52;;26842:18;26726:20;26784:21;;;26680:24;26653:52;;26842:18;26726:20;26784:21;;;26680:24;26653:52;;;26842:18;26726:20;26784:21;;;26680:24;26657:21;26653:52;;;26842:18;26726:20;26784:21;;;26680:24;26653:52;;26842:18;26726:20;26784:21;;;26680:24;26653:52;;26842:18;26726:20;27700:10;26842:18;27690:21;;;26784;;;;27798:1;27783:77;27808:2;27805:1;27802:9;27783:77;;;26680:24;;26657:21;26653:52;26726:20;;27856:1;26784:21;;;;26668:2;26842:18;;;;27826:1;27819:9;27783:77;;;27787:14;;;27938:5;:12;;;27934:71;;;27977:13;:11;:13::i;:::-;27970:20;;;;;27934:71;28019:10;;;:15;;28033:1;28019:15;;;;;28104:8;;;;-1:-1:-1;;28096:20:105;;-1:-1:-1;28096:7:105;:20::i;:::-;28082:34;-1:-1:-1;28146:10:105;28154:2;28146:10;;;;28223:1;28213:11;;;:26;;;28228:6;:11;;28238:1;28228:11;28213:26;28209:310;;;28369:13;28438:1;28416:4;28423:10;28416:17;28415:24;;;;28386:5;:12;;;28401:10;28386:25;28385:54;28369:70;;28464:40;28475:6;:11;;28485:1;28475:11;:20;;28493:2;28475:20;;;28489:1;28475:20;28464:40;;28497:6;28464:10;:40::i;:::-;28457:47;;;;;;;;28209:310;28768:15;;;;28563:9;;;;28700:4;28694:2;28686:10;;;28685:19;;;28768:15;28793:2;28785:10;;;28784:19;28768:36;;;;;;;:::i;:::-;;;;;;-1:-1:-1;28833:5:105;28857:11;;;;;:29;;;28872:6;:14;;28882:4;28872:14;28857:29;28853:832;;;28949:5;:15;;;28965:5;28949:22;;;;;;;;;:::i;:::-;;;;;;-1:-1:-1;;29012:4:105;29006:2;28998:10;;;28997:19;28853:832;;;29050:4;29041:6;:13;;;29037:648;;;29171:6;:13;;29181:3;29171:13;:30;;;;29188:6;:13;;29198:3;29188:13;29171:30;:47;;;;29205:6;:13;;29215:3;29205:13;29171:47;29167:253;;;29281:4;29288:6;29281:13;29276:18;;29037:648;;29167:253;29380:21;29383:4;29390:6;29383:13;29398:2;29380;:21::i;:::-;29375:26;;29037:648;;;29454:4;29444:6;:14;;;;:32;;;;29462:6;:14;;29472:4;29462:14;29444:32;:50;;;;29480:6;:14;;29490:4;29480:14;29444:50;29440:245;;;29564:5;:15;;;29580:5;29564:22;;;;;;;;;:::i;:::-;;;;;29559:27;;29665:5;29657:13;;29440:245;29714:1;29704:6;:11;;;;:25;;;;;29728:1;29719:6;:10;;;29704:25;29703:42;;;;29734:6;:11;;29744:1;29734:11;29703:42;29699:125;;;29772:37;29785:6;29793:4;29799:5;29806:2;29772:12;:37::i;:::-;29765:44;;;;;;;;;;;29699:125;29857:13;29838:16;30009:4;29999:14;;;;29995:446;;30078:21;30081:4;30088:6;30081:13;30096:2;30078;:21::i;:::-;30072:27;;;;30136:10;30131:15;;30170:16;30131:15;30184:1;30170:7;:16::i;:::-;30164:22;;30218:4;30208:6;:14;;;;:32;;;;;30226:6;:14;;30236:4;30226:14;;30208:32;30204:223;;;30305:4;30293:16;;30407:1;30399:9;;30204:223;30015:426;29995:446;30474:10;30487:26;30495:4;30501:2;30505;30509:3;30487:7;:26::i;:::-;30516:10;30487:39;;;;-1:-1:-1;30612:4:105;30605:11;;;30644;;;:24;;;;;30667:1;30659:4;:9;;;;30644:24;:39;;;;;30679:4;30672;:11;;;30644:39;30640:847;;;30707:4;:9;;30715:1;30707:9;:22;;;;30720:4;:9;;30728:1;30720:9;30707:22;30703:144;;;30791:37;30802:4;:9;;30810:1;30802:9;:21;;30818:5;30802:21;;;30814:1;30802:21;30825:2;30791:10;:37::i;:::-;30784:44;;;;;;;;;;;;;;;30703:144;30869:4;:11;;30877:3;30869:11;30865:121;;30939:28;30948:5;30955:2;30959:7;;;;30939:8;:28::i;30865:121::-;31007:4;:11;;31015:3;31007:11;31003:121;;31077:28;31086:5;31093:2;31097:7;;;;;31077:8;:28::i;31003:121::-;31194:4;:11;;31202:3;31194:11;31190:80;;31236:15;:13;:15::i;31190:80::-;31373:4;31365;:12;;;;:27;;;;;31388:4;31381;:11;;;31365:27;31361:112;;;31423:31;31434:4;31440:2;31444;31448:5;31423:10;:31::i;31361:112::-;31547:6;:14;;31557:4;31547:14;:28;;;;-1:-1:-1;31565:10:105;;;;;31547:28;31543:93;;;31620:1;31595:5;:15;;;31611:5;31595:22;;;;;;;;;:::i;:::-;:26;;;;:22;;;;;;:26;31543:93;31682:9;:26;;31695:13;31682:26;31678:92;;31728:27;31737:9;31748:1;31751:3;31728:8;:27::i;:::-;31851:26;31860:5;31867:3;31872:4;31851:8;:26::i;:::-;31844:33;;;;;;;;;;;;;25555:6339;;;;;;;:::o;3092:2334::-;3639:4;3633:11;;3555:4;3358:31;3347:43;;3418:13;3358:31;3757:2;3457:13;;3347:43;3364:24;3358:31;3457:13;;;3347:43;;;;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3418:13;4185:11;3364:24;3358:31;3457:13;;;3347:43;3418:13;4280:11;3364:24;3358:31;3457:13;;;3347:43;3364:24;3358:31;3457:13;;;3347:43;3133:12;;4420:13;;3633:11;;3457:13;;;;4185:11;3133:12;4500:84;4525:2;4522:1;4519:9;4500:84;;;3374:13;3364:24;;3358:31;3347:43;;3378:2;3418:13;;;;4580:1;3457:13;;;;4543:1;4536:9;4500:84;;;4504:14;4647:1;4643:2;4636:13;4742:5;4738:2;4734:14;4727:5;4722:27;4816:1;4802:15;;4837:6;4861:1;4856:273;;;;5196:1;5186:11;;4830:369;;4856:273;4888:8;4946:22;;;;5025:1;5020:22;;;;5112:1;5102:11;;4881:234;;4946:22;4965:1;4955:11;;4946:22;;5020;5039:1;5029:11;;4881:234;;4830:369;-1:-1:-1;;;5322:14:105;;;5305:32;;5365:19;5361:30;5397:3;5393:16;;;;5358:52;;3092:2334;-1:-1:-1;3092:2334:105:o;21610:1831::-;21683:11;21794:14;21811:24;21823:11;21811;:24::i;:::-;21794:41;;21943:1;21936:5;21932:13;21929:33;;;21958:1;21955;21948:12;21929:33;22091:2;22079:15;;;22032:20;22521:5;22518:1;22514:13;22556:4;22592:1;22577:343;22602:2;22599:1;22596:9;22577:343;;;22725:2;22713:15;;;22662:20;22760:12;;;22774:1;22756:20;22797:42;;;;22865:1;22860:42;;;;22749:153;;22797:42;22255:1;22248:12;;;22288:2;22281:13;;;22333:2;22320:16;;22806:31;;22797:42;;22860;22255:1;22248:12;;;22288:2;22281:13;;;22333:2;22320:16;;22869:31;;22749:153;-1:-1:-1;;22620:1:105;22613:9;22577:343;;;22581:14;23030:4;23024:11;23009:26;;23116:7;23110:4;23107:17;23097:124;;23158:10;23155:1;23148:21;23200:2;23197:1;23190:13;23097:124;-1:-1:-1;;23348:2:105;23337:14;;;;23325:10;23321:31;23318:1;23314:39;23382:16;;;;23400:10;23378:33;;21610:1831;-1:-1:-1;;;21610:1831:105:o;18720:823::-;18789:12;18876:18;;:::i;:::-;18944:4;18935:13;;18996:5;:8;;;19007:1;18996:12;18980:28;;:5;:12;;;:28;;;18976:95;;19028:28;;;;;2114:2:257;19028:28:105;;;2096:21:257;2153:2;2133:18;;;2126:30;2192:20;2172:18;;;2165:48;2230:18;;19028:28:105;;;;;;;;18976:95;19160:8;;;;;19193:12;;;;;19182:23;;;;;;;19219:20;;;;;19160:8;19351:13;;;19347:90;;19412:6;19421:1;19412:10;19384:5;:15;;;19400:8;19384:25;;;;;;;;;:::i;:::-;:38;;;;:25;;;;;;:38;19347:90;19513:13;:11;:13::i;:::-;19506:20;18720:823;-1:-1:-1;;;;;18720:823:105:o;2645:339::-;2706:11;2770:18;;;;2779:8;;;;2770:18;;;;;;2769:25;;;;;2786:1;2833:2;:9;;;2827:16;;;;;2826:22;;2825:32;;;;;;;2887:9;;2886:15;2769:25;2944:21;;2964:1;2944:21;;;2955:6;2944:21;2929:11;;;;;:37;;-1:-1:-1;;;2645:339:105;;;;:::o;13581:2026::-;13678:12;13764:18;;:::i;:::-;13832:4;13823:13;;13864:17;13924:5;:8;;;13935:1;13924:12;13908:28;;:5;:12;;;:28;;;13904:97;;13956:30;;;;;2461:2:257;13956:30:105;;;2443:21:257;2500:2;2480:18;;;2473:30;2539:22;2519:18;;;2512:50;2579:18;;13956:30:105;2259:344:257;13904:97:105;14071:7;:12;;14082:1;14071:12;:28;;;;14087:7;:12;;14098:1;14087:12;14071:28;14067:947;;;14119:9;14131:5;:15;;;14147:6;14131:23;;;;;;;;;:::i;:::-;;;;;14119:35;;14195:2;14188:9;;:3;:9;;;:25;;;;;14201:7;:12;;14212:1;14201:12;14188:25;14187:58;;;;14226:2;14219:9;;:3;:9;;;;:25;;;;;14232:7;:12;;14243:1;14232:12;14219:25;14172:73;;14101:159;14067:947;;;14357:7;:12;;14368:1;14357:12;14353:661;;14418:1;14410:3;14404:15;;;;14389:30;;14353:661;;;14522:7;:12;;14533:1;14522:12;14518:496;;14582:1;14575:3;14569:14;;;14554:29;;14518:496;;;14703:7;:12;;14714:1;14703:12;14699:315;;14791:4;14785:2;14776:11;;;14775:20;14761:10;14818:8;;;14814:84;;14878:1;14871:3;14865:14;;;14850:29;;14814:84;14919:3;:8;;14926:1;14919:8;14915:85;;14980:1;14972:3;14966:15;;;;14951:30;;14915:85;14717:297;14699:315;15090:8;;;;;15168:12;;;;15157:23;;;;;15324:178;;;;15415:1;15389:22;15392:5;15400:6;15392:14;15408:2;15389;:22::i;:::-;:27;;;;;;;15375:42;;15384:1;15375:42;15360:57;:12;;;:57;15324:178;;;15471:12;;;;;15486:1;15471:16;15456:31;;;;15324:178;15577:13;:11;:13::i;:::-;15570:20;13581:2026;-1:-1:-1;;;;;;;;13581:2026:105:o;31940:8733::-;32027:10;32089;32097:2;32089:10;;;;32128:11;;;:44;;;32154:1;32144:6;:11;;;;:27;;;;;32168:3;32159:6;:12;;;32144:27;32124:8490;;;32213:4;32206:11;;32337:6;32397:3;32392:25;;;;32472:3;32467:25;;;;32546:3;32541:25;;;;32621:3;32616:25;;;;32695:3;32690:25;;;;32768:3;32763:25;;;;32842:3;32837:25;;;;32330:532;;32392:25;32411:4;32403:12;;32392:25;;32467;32486:4;32478:12;;32467:25;;32541;32560:4;32552:12;;32541:25;;32616;32635:4;32627:12;;32616:25;;32690;32709:4;32701:12;;32690:25;;32763;32782:4;32774:12;;32763:25;;32837;32856:4;32848:12;;32330:532;;32925:4;:12;;32933:4;32925:12;32921:4023;;-1:-1:-1;;;32976:9:105;32968:26;;32989:4;32984:1;32976:9;;;32975:18;32968:26;32961:33;;32921:4023;33062:4;:12;;33070:4;33062:12;33058:3886;;-1:-1:-1;;;33113:9:105;33105:26;;33126:4;33121:1;33113:9;;;33112:18;33105:26;33098:33;;33058:3886;33199:4;:12;;33207:4;33199:12;33195:3749;;33264:4;33259:1;33251:9;;;33250:18;33297:27;33251:9;33300:11;;;;33313:2;:10;;;33297:2;:27::i;:::-;33290:34;;;;;;;33195:3749;33393:4;:12;;33401:4;33393:12;33389:3555;;-1:-1:-1;;;33436:17:105;;;33448:4;33443:9;;33436:17;33429:24;;33389:3555;33522:4;:11;;33530:3;33522:11;33518:3426;;-1:-1:-1;;;33564:17:105;;;33576:4;33571:9;;33564:17;33557:24;;33518:3426;33650:4;:12;;33658:4;33650:12;33646:3298;;33693:21;33702:2;33696:8;;:2;:8;;;;33711:2;33706;:7;33693:2;:21::i;:::-;33686:28;;;;;;33646:3298;33963:4;:12;;33971:4;33963:12;33959:2985;;34006:2;33999:9;;;;;;33959:2985;34077:4;:12;;34085:4;34077:12;34073:2871;;34120:2;34113:9;;;;;;34073:2871;34191:4;:12;;34199:4;34191:12;34187:2757;;34234:2;34227:9;;;;;;34187:2757;34305:4;:12;;34313:4;34305:12;34301:2643;;34348:2;34341:9;;;;;;34301:2643;34422:4;:12;;34430:4;34422:12;34418:2526;;34465:2;34458:9;;;;;;34418:2526;34582:4;:12;;34590:4;34582:12;34578:2366;;34625:2;34618:9;;;;;;34578:2366;34696:4;:12;;34704:4;34696:12;34692:2252;;34739:2;34732:9;;;;;;34692:2252;34810:4;:12;;34818:4;34810:12;34806:2138;;34853:2;34846:9;;;;;;34806:2138;34924:4;:12;;34932:4;34924:12;34920:2024;;34967:2;34960:9;;;;;;34920:2024;35038:4;:12;;35046:4;35038:12;35034:1910;;35081:2;35074:9;;;;;;35034:1910;35152:4;:12;;35160:4;35152:12;35148:1796;;35195:2;35188:9;;;;;;35148:1796;35267:4;:12;;35275:4;35267:12;35263:1681;;35310:2;35303:9;;;;;;35263:1681;35380:4;:12;;35388:4;35380:12;35376:1568;;35423:2;35416:9;;;;;;35376:1568;35494:4;:12;;35502:4;35494:12;35490:1454;;35537:2;35530:9;;;;;;35490:1454;35686:4;:12;;35694:4;35686:12;35682:1262;;-1:-1:-1;;;35730:7:105;;;35722:16;;35682:1262;35807:4;:12;;35815:4;35807:12;35803:1141;;-1:-1:-1;;;35851:7:105;;;35843:16;;35803:1141;35927:4;:12;;35935:4;35927:12;35923:1021;;-1:-1:-1;;;35971:7:105;;;35963:16;;35923:1021;36048:4;:12;;36056:4;36048:12;36044:900;;-1:-1:-1;;;36092:7:105;;;36084:16;;36044:900;36168:4;:12;;36176:4;36168:12;36164:780;;-1:-1:-1;;;36212:7:105;;;36204:16;;36164:780;36287:4;:12;;36295:4;36287:12;36283:661;;-1:-1:-1;;;36331:7:105;;;36323:16;;36283:661;36407:4;:12;;36415:4;36407:12;36403:541;;-1:-1:-1;;;36451:7:105;;;36443:16;;36403:541;36527:4;:12;;36535:4;36527:12;36523:421;;-1:-1:-1;;;36572:7:105;;;36570:10;36563:17;;36523:421;36649:4;:12;;36657:4;36649:12;36645:299;;36710:2;36692:21;;36698:2;36692:21;;;:29;;36720:1;36692:29;;;36716:1;36692:29;36685:36;;;;;;;;36645:299;36791:4;:12;;36799:4;36791:12;36787:157;;36839:2;36834:7;;:2;:7;;;:15;;36848:1;36834:15;;36787:157;36896:29;;;;;2810:2:257;36896:29:105;;;2792:21:257;2849:2;2829:18;;;2822:30;2888:21;2868:18;;;2861:49;2927:18;;36896:29:105;2608:343:257;36787:157:105;32174:4784;32124:8490;;;37014:6;:14;;37024:4;37014:14;37010:3590;;37073:4;37066:11;;37148:3;37140:11;;;37136:549;;-1:-1:-1;;;37193:21:105;;;37179:36;;37136:549;37300:4;:12;;37308:4;37300:12;:28;;;;37316:4;:12;;37324:4;37316:12;37300:28;37296:389;;;37360:4;:12;;37368:4;37360:12;37356:83;;37409:3;;;37356:83;37464:8;37502:127;37514:10;37509:15;;:20;37502:127;;37594:8;37561:3;37594:8;;;;;37561:3;37502:127;;;37661:1;-1:-1:-1;37654:8:105;;-1:-1:-1;;37654:8:105;37010:3590;37752:6;:14;;37762:4;37752:14;37748:2852;;-1:-1:-1;;37797:8:105;37803:2;37797:8;;;;37790:15;;37748:2852;37872:6;:14;;37882:4;37872:14;37868:2732;;37917:42;37935:2;37940:1;37935:6;37945:1;37934:12;37929:2;:17;37921:26;;:3;:26;;;;37951:4;37920:35;37957:1;37917:2;:42::i;37868:2732::-;38026:6;:14;;38036:4;38026:14;38022:2578;;38071:45;38089:2;38094:1;38089:6;38099:1;38088:12;38083:2;:17;38075:26;;:3;:26;;;;38105:6;38074:37;38113:2;38071;:45::i;38022:2578::-;38184:6;:14;;38194:4;38184:14;38180:2420;;-1:-1:-1;;38235:21:105;38254:1;38249;38244:6;;38243:12;38235:21;;38292:36;;;38363:5;38358:10;;38235:21;;;;;38357:18;38350:25;;38180:2420;38442:6;:14;;38452:4;38442:14;38438:2162;;38487:3;38480:10;;;;;38438:2162;38558:6;:14;;38568:4;38558:14;38554:2046;;38618:2;38623:1;38618:6;38628:1;38617:12;38612:2;:17;38604:26;;:3;:26;;;;38634:4;38603:35;38596:42;;;;;38554:2046;38707:6;:14;;38717:4;38707:14;38703:1897;;38767:2;38772:1;38767:6;38777:1;38766:12;38761:2;:17;38753:26;;:3;:26;;;;38783:6;38752:37;38745:44;;;;;38703:1897;38858:6;:14;;38868:4;38858:14;38854:1746;;-1:-1:-1;;38909:26:105;38933:1;38928;38923:6;;38922:12;38917:2;:17;38909:26;;38971:41;;;39047:5;39042:10;;38909:26;;;;;39041:18;39034:25;;38854:1746;39127:6;:14;;39137:4;39127:14;39123:1477;;-1:-1:-1;;39184:4:105;39178:34;39210:1;39205;39200:6;;39199:12;39194:2;:17;39178:34;;39268:27;;;39248:48;;;39326:10;;39179:9;;;39178:34;;39325:18;39318:25;;39123:1477;39411:6;:14;;39421:4;39411:14;39407:1193;;-1:-1:-1;;39468:6:105;39462:36;39496:1;39491;39486:6;;39485:12;39480:2;:17;39462:36;;39554:29;;;39534:50;;;39614:10;;39463:11;;;39462:36;;39613:18;39606:25;;39407:1193;39700:6;:14;;39710:4;39700:14;39696:904;;-1:-1:-1;;39751:20:105;39769:1;39764;39759:6;;39758:12;39751:20;;39807:36;;;39879:5;39873:11;;39751:20;;;;;39872:19;39865:26;;39696:904;39959:6;:14;;39969:4;39959:14;39955:645;;40004:2;39997:9;;;;;39955:645;40075:6;:14;;40085:4;40075:14;40071:529;;-1:-1:-1;;40126:25:105;40149:1;40144;40139:6;;40138:12;40133:2;:17;40126:25;;40187:41;;;40264:5;40258:11;;40126:25;;;;;40257:19;40250:26;;40071:529;40343:6;:14;;40353:4;40343:14;40339:261;;40388:3;40381:10;;;;;40339:261;40458:6;:14;;40468:4;40458:14;40454:146;;40503:2;40496:9;;;;;19824:782;19910:12;19997:18;;:::i;:::-;-1:-1:-1;20065:4:105;20172:2;20160:14;;;;20152:41;;;;;;;3158:2:257;20152:41:105;;;3140:21:257;3197:2;3177:18;;;3170:30;3236:16;3216:18;;;3209:44;3270:18;;20152:41:105;2956:338:257;20152:41:105;20289:14;;;;;;;:30;;;20307:12;20289:30;20285:102;;;20368:4;20339:5;:15;;;20355:9;20339:26;;;;;;;;;:::i;:::-;:33;;;;:26;;;;;;:33;20285:102;20442:12;;;;;20431:23;;;;:8;;;:23;20498:1;20483:16;;;20468:31;;;20576:13;:11;:13::i;5467:7728::-;5510:12;5596:18;;:::i;:::-;-1:-1:-1;5774:15:105;;:18;;;;5664:4;5934:18;;;;5978;;;;6022;;;;;5664:4;;5754:17;;;;5934:18;5978;6112;;;6126:4;6112:18;6108:6777;;6162:2;6191:4;6186:9;;:14;6182:144;;6302:4;6297:9;;6289:4;:18;6283:24;6182:144;6347:2;:7;;6353:1;6347:7;6343:161;;6383:10;;;;;6415:16;;;;;;;;6383:10;-1:-1:-1;6343:161:105;;;6483:2;6478:7;;6343:161;6132:386;6108:6777;;;6620:10;:18;;6634:4;6620:18;6616:6269;;1745:10;6658:14;;6616:6269;;;6756:10;:18;;6770:4;6756:18;6752:6133;;6799:1;6794:6;;6752:6133;;;6924:10;:18;;6938:4;6924:18;6920:5965;;6977:4;6962:12;;;:19;6999:26;;;:14;;;:26;7050:13;:11;:13::i;:::-;7043:20;;;;;;;;;5467:7728;:::o;6920:5965::-;7189:10;:18;;7203:4;7189:18;7185:5700;;7340:14;;;7336:2708;7185:5700;7336:2708;7510:22;;;;;7506:2538;;7635:10;7648:27;7656:2;7661:10;7656:15;7673:1;7648:7;:27::i;:::-;7759:17;;;;7635:40;;-1:-1:-1;7759:17:105;7737:19;7909:14;7928:1;7903:26;7899:131;;7971:36;7995:11;1277:21:106;1426:15;;;1467:8;1461:4;1454:22;1595:4;1582:18;;1602:19;1578:44;1624:11;1575:61;;1222:430;7971:36:105;7957:50;;7899:131;8116:20;;;;;8083:54;;;;;;;;3472:25:257;;;8083:54:105;3533:23:257;;;3513:18;;;3506:51;8052:11:105;;;;8083:19;:6;:19;;;;3445:18:257;;8083:54:105;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;8051:86;;;;8364:1;8360:2;8356:10;8461:9;8458:1;8454:17;8543:6;8536:5;8533:17;8530:40;;;8563:5;8553:15;;8530:40;;8646:6;8642:2;8639:14;8636:34;;;8666:2;8656:12;;8636:34;8772:3;8767:1;8759:6;8755:14;8750:3;8746:24;8742:34;8735:41;;8872:3;8868:1;8856:9;8847:6;8844:1;8840:14;8836:30;8832:38;8828:48;8821:55;;9027:1;9023;9019;9007:9;9004:1;9000:17;8996:25;8992:33;8988:41;9154:1;9150;9146;9137:6;9125:9;9122:1;9118:17;9114:30;9110:38;9106:46;9102:54;9084:72;;9285:10;9281:15;9275:4;9271:26;9263:34;;9401:3;9393:4;9389:9;9384:3;9380:19;9377:28;9370:35;;;;9547:33;9556:2;9561:10;9556:15;9573:1;9576:3;9547:8;:33::i;:::-;9602:20;;;:38;;;;;;;;;-1:-1:-1;7506:2538:105;;-1:-1:-1;;;7506:2538:105;;9759:18;;;;;9755:289;;9929:2;9924:7;;7185:5700;;9755:289;9983:10;9978:15;;2053:3;10015:10;;9755:289;7185:5700;;;10173:10;:18;;10187:4;10173:18;10169:2716;;10327:15;;;1824:1;10327:15;;:34;;-1:-1:-1;10346:15:105;;;1859:1;10346:15;10327:34;:57;;;-1:-1:-1;10365:19:105;;;1936:1;10365:19;10327:57;10323:1593;;;10413:2;10408:7;;10169:2716;;10323:1593;10539:23;;;;;10535:1381;;10586:10;10599:27;10607:2;10612:10;10607:15;10624:1;10599:7;:27::i;:::-;10702:17;;;;10586:40;;-1:-1:-1;10945:1:105;10937:10;;11039:1;11035:17;11114:13;;;11111:32;;;11136:5;11130:11;;11111:32;11422:14;;;11228:1;11418:22;;;11414:32;;;;11311:26;11335:1;11220:10;;;11315:18;;;11311:26;11410:43;11216:20;;11518:12;11646:17;;;:23;11714:1;11691:20;;;:24;11224:2;-1:-1:-1;11224:2:105;7185:5700;;10169:2716;12118:10;:18;;12132:4;12118:18;12114:771;;12228:2;:7;;12234:1;12228:7;12224:647;;12321:14;;;;;:40;;-1:-1:-1;12339:22:105;;;1978:1;12339:22;12321:40;:62;;;-1:-1:-1;12365:18:105;;;1897:1;12365:18;12321:62;12317:404;;;12416:1;12411:6;;12224:647;;12317:404;12462:15;;;1824:1;12462:15;;:34;;-1:-1:-1;12481:15:105;;;1859:1;12481:15;12462:34;:61;;;-1:-1:-1;12500:23:105;;;2021:1;12500:23;12462:61;:84;;;-1:-1:-1;12527:19:105;;;1936:1;12527:19;12462:84;12458:263;;;12579:1;12574:6;;7185:5700;;12224:647;12772:10;12767:15;;2087:4;12804:11;;12224:647;12960:15;;;;;:23;;;;:18;;;;:23;;;;12997:15;;:23;;;:18;;;;:23;-1:-1:-1;13086:12:105;;;;13075:23;;;:8;;;:23;13142:1;13127:16;13112:31;;;;;13165:13;:11;:13::i;15948:2480::-;16042:12;16128:18;;:::i;:::-;-1:-1:-1;16196:4:105;16228:10;16336:13;;;16345:4;16336:13;16332:1705;;-1:-1:-1;16375:8:105;;;;16332:1705;;;16494:5;:13;;16503:4;16494:13;16490:1547;;16527:14;;;:8;;;:14;16490:1547;;;16657:5;:13;;16666:4;16657:13;16653:1384;;-1:-1:-1;16696:8:105;;;;16653:1384;;;16815:5;:13;;16824:4;16815:13;16811:1226;;16848:14;;;:8;;;:14;16811:1226;;;16989:5;:13;;16998:4;16989:13;16985:1052;;17116:9;17062:17;17042;;;17062;;;;17042:37;17123:2;17116:9;;;;;17098:8;;;:28;17144:22;:8;;;:22;16985:1052;;;17303:5;:13;;17312:4;17303:13;17299:738;;17370:11;17356;;;17370;;;17356:25;17425:2;17418:9;;;;;17400:8;;;:28;17446:22;:8;;;:22;17299:738;;;17627:5;:13;;17636:4;17627:13;17623:414;;17697:3;17678:23;;17684:3;17678:23;;;;;;;:::i;:::-;;17660:42;;:8;;;:42;17738:23;;;;;;;;;;;;;:::i;:::-;;17720:42;;:8;;;:42;17623:414;;;17931:5;:13;;17940:4;17931:13;17927:110;;17981:3;17975:9;;:3;:9;;;;;;;:::i;:::-;;17964:20;;;;:8;;;:20;18013:9;;;;;;;;;;;:::i;:::-;;18002:20;;:8;;;:20;17927:110;18130:14;;;;18126:85;;18193:3;18164:5;:15;;;18180:9;18164:26;;;;;;;;;:::i;:::-;:32;;;;:26;;;;;;:32;18126:85;18265:12;;;;;18254:23;;;;:8;;;:23;18321:1;18306:16;;;18291:31;;;18398:13;:11;:13::i;:::-;18391:20;15948:2480;-1:-1:-1;;;;;;;15948:2480:105:o;23777:1654::-;23953:14;23970:24;23982:11;23970;:24::i;:::-;23953:41;;24102:1;24095:5;24091:13;24088:33;;;24117:1;24114;24107:12;24088:33;24256:2;24450:15;;;24275:2;24264:14;;24252:10;24248:31;24245:1;24241:39;24406:16;;;24191:20;;24391:10;24380:22;;;24376:27;24366:38;24363:60;24892:5;24889:1;24885:13;24963:1;24948:343;24973:2;24970:1;24967:9;24948:343;;;25096:2;25084:15;;;25033:20;25131:12;;;25145:1;25127:20;25168:42;;;;25236:1;25231:42;;;;25120:153;;25168:42;22255:1;22248:12;;;22288:2;22281:13;;;22333:2;22320:16;;25177:31;;25168:42;;25231;22255:1;22248:12;;;22288:2;22281:13;;;22333:2;22320:16;;25240:31;;25120:153;-1:-1:-1;;24991:1:105;24984:9;24948:343;;;-1:-1:-1;;25390:4:105;25383:18;-1:-1:-1;;;;23777:1654:105:o;20810:586::-;21132:20;;;21156:7;21132:32;21125:3;:40;;;21238:14;;21293:17;;21287:24;;;21279:72;;;;;;;4209:2:257;21279:72:105;;;4191:21:257;4248:2;4228:18;;;4221:30;4287:34;4267:18;;;4260:62;4358:5;4338:18;;;4331:33;4381:19;;21279:72:105;4007:399:257;21279:72:105;21365:14;20810:586;;;:::o;-1:-1:-1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;467:347:257:-;518:8;528:6;582:3;575:4;567:6;563:17;559:27;549:55;;600:1;597;590:12;549:55;-1:-1:-1;623:20:257;;666:18;655:30;;652:50;;;698:1;695;688:12;652:50;735:4;727:6;723:17;711:29;;787:3;780:4;771:6;763;759:19;755:30;752:39;749:59;;;804:1;801;794:12;749:59;467:347;;;;;:::o;819:717::-;909:6;917;925;933;986:2;974:9;965:7;961:23;957:32;954:52;;;1002:1;999;992:12;954:52;1042:9;1029:23;1071:18;1112:2;1104:6;1101:14;1098:34;;;1128:1;1125;1118:12;1098:34;1167:58;1217:7;1208:6;1197:9;1193:22;1167:58;:::i;:::-;1244:8;;-1:-1:-1;1141:84:257;-1:-1:-1;1332:2:257;1317:18;;1304:32;;-1:-1:-1;1348:16:257;;;1345:36;;;1377:1;1374;1367:12;1345:36;;1416:60;1468:7;1457:8;1446:9;1442:24;1416:60;:::i;:::-;819:717;;;;-1:-1:-1;1495:8:257;-1:-1:-1;;;;819:717:257:o;1723:184::-;1775:77;1772:1;1765:88;1872:4;1869:1;1862:15;1896:4;1893:1;1886:15;3568:245;3647:6;3655;3708:2;3696:9;3687:7;3683:23;3679:32;3676:52;;;3724:1;3721;3714:12;3676:52;-1:-1:-1;;3747:16:257;;3803:2;3788:18;;;3782:25;3747:16;;3782:25;;-1:-1:-1;3568:245:257:o;3818:184::-;3870:77;3867:1;3860:88;3967:4;3964:1;3957:15;3991:4;3988:1;3981:15"
func init() {
if err := json.Unmarshal([]byte(MIPSStorageLayoutJSON), MIPSStorageLayout); err != nil {
......
......@@ -38,8 +38,8 @@ type SchemaRecord struct {
// SchemaRegistryMetaData contains all meta data concerning the SchemaRegistry contract.
var SchemaRegistryMetaData = &bind.MetaData{
ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyExists\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"registerer\",\"type\":\"address\"}],\"name\":\"Registered\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"}],\"name\":\"getSchema\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"contractISchemaResolver\",\"name\":\"resolver\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"schema\",\"type\":\"string\"}],\"internalType\":\"structSchemaRecord\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"schema\",\"type\":\"string\"},{\"internalType\":\"contractISchemaResolver\",\"name\":\"resolver\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"}],\"name\":\"register\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
Bin: "0x60e060405234801561001057600080fd5b506001608052600060a052600360c05260805160a05160c051610b1661004c600039600060fe0152600060d50152600060ac0152610b166000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806354fd4d501461004657806360d7a27814610064578063a2ea7c6e14610085575b600080fd5b61004e6100a5565b60405161005b9190610604565b60405180910390f35b61007761007236600461061e565b610148565b60405190815260200161005b565b6100986100933660046106d0565b6102f1565b60405161005b91906106e9565b60606100d07f0000000000000000000000000000000000000000000000000000000000000000610419565b6100f97f0000000000000000000000000000000000000000000000000000000000000000610419565b6101227f0000000000000000000000000000000000000000000000000000000000000000610419565b6040516020016101349392919061073a565b604051602081830303815290604052905090565b60008060405180608001604052806000801b81526020018573ffffffffffffffffffffffffffffffffffffffff168152602001841515815260200187878080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920182905250939094525092935091506101ca905082610556565b60008181526020819052604090205490915015610213576040517f23369fa600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80825260008181526020818152604091829020845181559084015160018201805493860151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00000000000000000000000000000000000000000090941673ffffffffffffffffffffffffffffffffffffffff9092169190911792909217909155606083015183919060028201906102af9082610881565b50506040513381528291507f7d917fcbc9a29a9705ff9936ffa599500e4fd902e4486bae317414fe967b307c9060200160405180910390a29695505050505050565b604080516080810182526000808252602082018190529181019190915260608082015260008281526020818152604091829020825160808101845281548152600182015473ffffffffffffffffffffffffffffffffffffffff8116938201939093527401000000000000000000000000000000000000000090920460ff16151592820192909252600282018054919291606084019190610390906107df565b80601f01602080910402602001604051908101604052809291908181526020018280546103bc906107df565b80156104095780601f106103de57610100808354040283529160200191610409565b820191906000526020600020905b8154815290600101906020018083116103ec57829003601f168201915b5050505050815250509050919050565b60608160000361045c57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156104865780610470816109ca565b915061047f9050600a83610a31565b9150610460565b60008167ffffffffffffffff8111156104a1576104a16107b0565b6040519080825280601f01601f1916602001820160405280156104cb576020820181803683370190505b5090505b841561054e576104e0600183610a45565b91506104ed600a86610a5e565b6104f8906030610a72565b60f81b81838151811061050d5761050d610a85565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610547600a86610a31565b94506104cf565b949350505050565b600081606001518260200151836040015160405160200161057993929190610ab4565b604051602081830303815290604052805190602001209050919050565b60005b838110156105b1578181015183820152602001610599565b50506000910152565b600081518084526105d2816020860160208601610596565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061061760208301846105ba565b9392505050565b6000806000806060858703121561063457600080fd5b843567ffffffffffffffff8082111561064c57600080fd5b818701915087601f83011261066057600080fd5b81358181111561066f57600080fd5b88602082850101111561068157600080fd5b6020928301965094505085013573ffffffffffffffffffffffffffffffffffffffff811681146106b057600080fd5b9150604085013580151581146106c557600080fd5b939692955090935050565b6000602082840312156106e257600080fd5b5035919050565b602081528151602082015273ffffffffffffffffffffffffffffffffffffffff60208301511660408201526040820151151560608201526000606083015160808084015261054e60a08401826105ba565b6000845161074c818460208901610596565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551610788816001850160208a01610596565b600192019182015283516107a3816002840160208801610596565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600181811c908216806107f357607f821691505b60208210810361082c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561087c57600081815260208120601f850160051c810160208610156108595750805b601f850160051c820191505b8181101561087857828155600101610865565b5050505b505050565b815167ffffffffffffffff81111561089b5761089b6107b0565b6108af816108a984546107df565b84610832565b602080601f83116001811461090257600084156108cc5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555610878565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561094f57888601518255948401946001909101908401610930565b508582101561098b57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036109fb576109fb61099b565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610a4057610a40610a02565b500490565b81810381811115610a5857610a5861099b565b92915050565b600082610a6d57610a6d610a02565b500690565b80820180821115610a5857610a5861099b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008451610ac6818460208901610596565b60609490941b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000169190930190815290151560f81b60148201526015019291505056fea164736f6c6343000813000a",
ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyExists\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"registerer\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"contractISchemaResolver\",\"name\":\"resolver\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"schema\",\"type\":\"string\"}],\"indexed\":false,\"internalType\":\"structSchemaRecord\",\"name\":\"schema\",\"type\":\"tuple\"}],\"name\":\"Registered\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"}],\"name\":\"getSchema\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"contractISchemaResolver\",\"name\":\"resolver\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"schema\",\"type\":\"string\"}],\"internalType\":\"structSchemaRecord\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"schema\",\"type\":\"string\"},{\"internalType\":\"contractISchemaResolver\",\"name\":\"resolver\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"}],\"name\":\"register\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]",
Bin: "0x60e060405234801561001057600080fd5b506001608052600260a052600060c05260805160a05160c051610b3161004c600039600060fe0152600060d50152600060ac0152610b316000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806354fd4d501461004657806360d7a27814610064578063a2ea7c6e14610085575b600080fd5b61004e6100a5565b60405161005b919061061f565b60405180910390f35b610077610072366004610639565b610148565b60405190815260200161005b565b6100986100933660046106eb565b61030c565b60405161005b9190610704565b60606100d07f0000000000000000000000000000000000000000000000000000000000000000610434565b6100f97f0000000000000000000000000000000000000000000000000000000000000000610434565b6101227f0000000000000000000000000000000000000000000000000000000000000000610434565b60405160200161013493929190610755565b604051602081830303815290604052905090565b60008060405180608001604052806000801b81526020018573ffffffffffffffffffffffffffffffffffffffff168152602001841515815260200187878080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920182905250939094525092935091506101ca905082610571565b60008181526020819052604090205490915015610213576040517f23369fa600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80825260008181526020818152604091829020845181559084015160018201805493860151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00000000000000000000000000000000000000000090941673ffffffffffffffffffffffffffffffffffffffff9092169190911792909217909155606083015183919060028201906102af908261089c565b509050503373ffffffffffffffffffffffffffffffffffffffff16817fd0b86852e21f9e5fa4bc3b0cff9757ffe243d50c4b43968a42202153d651ea5e846040516102fa9190610704565b60405180910390a39695505050505050565b604080516080810182526000808252602082018190529181019190915260608082015260008281526020818152604091829020825160808101845281548152600182015473ffffffffffffffffffffffffffffffffffffffff8116938201939093527401000000000000000000000000000000000000000090920460ff161515928201929092526002820180549192916060840191906103ab906107fa565b80601f01602080910402602001604051908101604052809291908181526020018280546103d7906107fa565b80156104245780601f106103f957610100808354040283529160200191610424565b820191906000526020600020905b81548152906001019060200180831161040757829003601f168201915b5050505050815250509050919050565b60608160000361047757505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156104a1578061048b816109e5565b915061049a9050600a83610a4c565b915061047b565b60008167ffffffffffffffff8111156104bc576104bc6107cb565b6040519080825280601f01601f1916602001820160405280156104e6576020820181803683370190505b5090505b8415610569576104fb600183610a60565b9150610508600a86610a79565b610513906030610a8d565b60f81b81838151811061052857610528610aa0565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610562600a86610a4c565b94506104ea565b949350505050565b600081606001518260200151836040015160405160200161059493929190610acf565b604051602081830303815290604052805190602001209050919050565b60005b838110156105cc5781810151838201526020016105b4565b50506000910152565b600081518084526105ed8160208601602086016105b1565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061063260208301846105d5565b9392505050565b6000806000806060858703121561064f57600080fd5b843567ffffffffffffffff8082111561066757600080fd5b818701915087601f83011261067b57600080fd5b81358181111561068a57600080fd5b88602082850101111561069c57600080fd5b6020928301965094505085013573ffffffffffffffffffffffffffffffffffffffff811681146106cb57600080fd5b9150604085013580151581146106e057600080fd5b939692955090935050565b6000602082840312156106fd57600080fd5b5035919050565b602081528151602082015273ffffffffffffffffffffffffffffffffffffffff60208301511660408201526040820151151560608201526000606083015160808084015261056960a08401826105d5565b600084516107678184602089016105b1565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516107a3816001850160208a016105b1565b600192019182015283516107be8160028401602088016105b1565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600181811c9082168061080e57607f821691505b602082108103610847577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561089757600081815260208120601f850160051c810160208610156108745750805b601f850160051c820191505b8181101561089357828155600101610880565b5050505b505050565b815167ffffffffffffffff8111156108b6576108b66107cb565b6108ca816108c484546107fa565b8461084d565b602080601f83116001811461091d57600084156108e75750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555610893565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561096a5788860151825594840194600190910190840161094b565b50858210156109a657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610a1657610a166109b6565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610a5b57610a5b610a1d565b500490565b81810381811115610a7357610a736109b6565b92915050565b600082610a8857610a88610a1d565b500690565b80820180821115610a7357610a736109b6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008451610ae18184602089016105b1565b60609490941b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000169190930190815290151560f81b60148201526015019291505056fea164736f6c6343000813000a",
}
// SchemaRegistryABI is the input ABI used to generate the binding from.
......@@ -363,37 +363,46 @@ func (it *SchemaRegistryRegisteredIterator) Close() error {
type SchemaRegistryRegistered struct {
Uid [32]byte
Registerer common.Address
Schema SchemaRecord
Raw types.Log // Blockchain specific contextual infos
}
// FilterRegistered is a free log retrieval operation binding the contract event 0x7d917fcbc9a29a9705ff9936ffa599500e4fd902e4486bae317414fe967b307c.
// FilterRegistered is a free log retrieval operation binding the contract event 0xd0b86852e21f9e5fa4bc3b0cff9757ffe243d50c4b43968a42202153d651ea5e.
//
// Solidity: event Registered(bytes32 indexed uid, address registerer)
func (_SchemaRegistry *SchemaRegistryFilterer) FilterRegistered(opts *bind.FilterOpts, uid [][32]byte) (*SchemaRegistryRegisteredIterator, error) {
// Solidity: event Registered(bytes32 indexed uid, address indexed registerer, (bytes32,address,bool,string) schema)
func (_SchemaRegistry *SchemaRegistryFilterer) FilterRegistered(opts *bind.FilterOpts, uid [][32]byte, registerer []common.Address) (*SchemaRegistryRegisteredIterator, error) {
var uidRule []interface{}
for _, uidItem := range uid {
uidRule = append(uidRule, uidItem)
}
var registererRule []interface{}
for _, registererItem := range registerer {
registererRule = append(registererRule, registererItem)
}
logs, sub, err := _SchemaRegistry.contract.FilterLogs(opts, "Registered", uidRule)
logs, sub, err := _SchemaRegistry.contract.FilterLogs(opts, "Registered", uidRule, registererRule)
if err != nil {
return nil, err
}
return &SchemaRegistryRegisteredIterator{contract: _SchemaRegistry.contract, event: "Registered", logs: logs, sub: sub}, nil
}
// WatchRegistered is a free log subscription operation binding the contract event 0x7d917fcbc9a29a9705ff9936ffa599500e4fd902e4486bae317414fe967b307c.
// WatchRegistered is a free log subscription operation binding the contract event 0xd0b86852e21f9e5fa4bc3b0cff9757ffe243d50c4b43968a42202153d651ea5e.
//
// Solidity: event Registered(bytes32 indexed uid, address registerer)
func (_SchemaRegistry *SchemaRegistryFilterer) WatchRegistered(opts *bind.WatchOpts, sink chan<- *SchemaRegistryRegistered, uid [][32]byte) (event.Subscription, error) {
// Solidity: event Registered(bytes32 indexed uid, address indexed registerer, (bytes32,address,bool,string) schema)
func (_SchemaRegistry *SchemaRegistryFilterer) WatchRegistered(opts *bind.WatchOpts, sink chan<- *SchemaRegistryRegistered, uid [][32]byte, registerer []common.Address) (event.Subscription, error) {
var uidRule []interface{}
for _, uidItem := range uid {
uidRule = append(uidRule, uidItem)
}
var registererRule []interface{}
for _, registererItem := range registerer {
registererRule = append(registererRule, registererItem)
}
logs, sub, err := _SchemaRegistry.contract.WatchLogs(opts, "Registered", uidRule)
logs, sub, err := _SchemaRegistry.contract.WatchLogs(opts, "Registered", uidRule, registererRule)
if err != nil {
return nil, err
}
......@@ -425,9 +434,9 @@ func (_SchemaRegistry *SchemaRegistryFilterer) WatchRegistered(opts *bind.WatchO
}), nil
}
// ParseRegistered is a log parse operation binding the contract event 0x7d917fcbc9a29a9705ff9936ffa599500e4fd902e4486bae317414fe967b307c.
// ParseRegistered is a log parse operation binding the contract event 0xd0b86852e21f9e5fa4bc3b0cff9757ffe243d50c4b43968a42202153d651ea5e.
//
// Solidity: event Registered(bytes32 indexed uid, address registerer)
// Solidity: event Registered(bytes32 indexed uid, address indexed registerer, (bytes32,address,bool,string) schema)
func (_SchemaRegistry *SchemaRegistryFilterer) ParseRegistered(log types.Log) (*SchemaRegistryRegistered, error) {
event := new(SchemaRegistryRegistered)
if err := _SchemaRegistry.contract.UnpackLog(event, "Registered", log); err != nil {
......
......@@ -13,7 +13,7 @@ const SchemaRegistryStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contrac
var SchemaRegistryStorageLayout = new(solc.StorageLayout)
var SchemaRegistryDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c806354fd4d501461004657806360d7a27814610064578063a2ea7c6e14610085575b600080fd5b61004e6100a5565b60405161005b9190610604565b60405180910390f35b61007761007236600461061e565b610148565b60405190815260200161005b565b6100986100933660046106d0565b6102f1565b60405161005b91906106e9565b60606100d07f0000000000000000000000000000000000000000000000000000000000000000610419565b6100f97f0000000000000000000000000000000000000000000000000000000000000000610419565b6101227f0000000000000000000000000000000000000000000000000000000000000000610419565b6040516020016101349392919061073a565b604051602081830303815290604052905090565b60008060405180608001604052806000801b81526020018573ffffffffffffffffffffffffffffffffffffffff168152602001841515815260200187878080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920182905250939094525092935091506101ca905082610556565b60008181526020819052604090205490915015610213576040517f23369fa600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80825260008181526020818152604091829020845181559084015160018201805493860151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00000000000000000000000000000000000000000090941673ffffffffffffffffffffffffffffffffffffffff9092169190911792909217909155606083015183919060028201906102af9082610881565b50506040513381528291507f7d917fcbc9a29a9705ff9936ffa599500e4fd902e4486bae317414fe967b307c9060200160405180910390a29695505050505050565b604080516080810182526000808252602082018190529181019190915260608082015260008281526020818152604091829020825160808101845281548152600182015473ffffffffffffffffffffffffffffffffffffffff8116938201939093527401000000000000000000000000000000000000000090920460ff16151592820192909252600282018054919291606084019190610390906107df565b80601f01602080910402602001604051908101604052809291908181526020018280546103bc906107df565b80156104095780601f106103de57610100808354040283529160200191610409565b820191906000526020600020905b8154815290600101906020018083116103ec57829003601f168201915b5050505050815250509050919050565b60608160000361045c57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156104865780610470816109ca565b915061047f9050600a83610a31565b9150610460565b60008167ffffffffffffffff8111156104a1576104a16107b0565b6040519080825280601f01601f1916602001820160405280156104cb576020820181803683370190505b5090505b841561054e576104e0600183610a45565b91506104ed600a86610a5e565b6104f8906030610a72565b60f81b81838151811061050d5761050d610a85565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610547600a86610a31565b94506104cf565b949350505050565b600081606001518260200151836040015160405160200161057993929190610ab4565b604051602081830303815290604052805190602001209050919050565b60005b838110156105b1578181015183820152602001610599565b50506000910152565b600081518084526105d2816020860160208601610596565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061061760208301846105ba565b9392505050565b6000806000806060858703121561063457600080fd5b843567ffffffffffffffff8082111561064c57600080fd5b818701915087601f83011261066057600080fd5b81358181111561066f57600080fd5b88602082850101111561068157600080fd5b6020928301965094505085013573ffffffffffffffffffffffffffffffffffffffff811681146106b057600080fd5b9150604085013580151581146106c557600080fd5b939692955090935050565b6000602082840312156106e257600080fd5b5035919050565b602081528151602082015273ffffffffffffffffffffffffffffffffffffffff60208301511660408201526040820151151560608201526000606083015160808084015261054e60a08401826105ba565b6000845161074c818460208901610596565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551610788816001850160208a01610596565b600192019182015283516107a3816002840160208801610596565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600181811c908216806107f357607f821691505b60208210810361082c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561087c57600081815260208120601f850160051c810160208610156108595750805b601f850160051c820191505b8181101561087857828155600101610865565b5050505b505050565b815167ffffffffffffffff81111561089b5761089b6107b0565b6108af816108a984546107df565b84610832565b602080601f83116001811461090257600084156108cc5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555610878565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561094f57888601518255948401946001909101908401610930565b508582101561098b57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036109fb576109fb61099b565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610a4057610a40610a02565b500490565b81810381811115610a5857610a5861099b565b92915050565b600082610a6d57610a6d610a02565b500690565b80820180821115610a5857610a5861099b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008451610ac6818460208901610596565b60609490941b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000169190930190815290151560f81b60148201526015019291505056fea164736f6c6343000813000a"
var SchemaRegistryDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c806354fd4d501461004657806360d7a27814610064578063a2ea7c6e14610085575b600080fd5b61004e6100a5565b60405161005b919061061f565b60405180910390f35b610077610072366004610639565b610148565b60405190815260200161005b565b6100986100933660046106eb565b61030c565b60405161005b9190610704565b60606100d07f0000000000000000000000000000000000000000000000000000000000000000610434565b6100f97f0000000000000000000000000000000000000000000000000000000000000000610434565b6101227f0000000000000000000000000000000000000000000000000000000000000000610434565b60405160200161013493929190610755565b604051602081830303815290604052905090565b60008060405180608001604052806000801b81526020018573ffffffffffffffffffffffffffffffffffffffff168152602001841515815260200187878080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920182905250939094525092935091506101ca905082610571565b60008181526020819052604090205490915015610213576040517f23369fa600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80825260008181526020818152604091829020845181559084015160018201805493860151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00000000000000000000000000000000000000000090941673ffffffffffffffffffffffffffffffffffffffff9092169190911792909217909155606083015183919060028201906102af908261089c565b509050503373ffffffffffffffffffffffffffffffffffffffff16817fd0b86852e21f9e5fa4bc3b0cff9757ffe243d50c4b43968a42202153d651ea5e846040516102fa9190610704565b60405180910390a39695505050505050565b604080516080810182526000808252602082018190529181019190915260608082015260008281526020818152604091829020825160808101845281548152600182015473ffffffffffffffffffffffffffffffffffffffff8116938201939093527401000000000000000000000000000000000000000090920460ff161515928201929092526002820180549192916060840191906103ab906107fa565b80601f01602080910402602001604051908101604052809291908181526020018280546103d7906107fa565b80156104245780601f106103f957610100808354040283529160200191610424565b820191906000526020600020905b81548152906001019060200180831161040757829003601f168201915b5050505050815250509050919050565b60608160000361047757505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156104a1578061048b816109e5565b915061049a9050600a83610a4c565b915061047b565b60008167ffffffffffffffff8111156104bc576104bc6107cb565b6040519080825280601f01601f1916602001820160405280156104e6576020820181803683370190505b5090505b8415610569576104fb600183610a60565b9150610508600a86610a79565b610513906030610a8d565b60f81b81838151811061052857610528610aa0565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610562600a86610a4c565b94506104ea565b949350505050565b600081606001518260200151836040015160405160200161059493929190610acf565b604051602081830303815290604052805190602001209050919050565b60005b838110156105cc5781810151838201526020016105b4565b50506000910152565b600081518084526105ed8160208601602086016105b1565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061063260208301846105d5565b9392505050565b6000806000806060858703121561064f57600080fd5b843567ffffffffffffffff8082111561066757600080fd5b818701915087601f83011261067b57600080fd5b81358181111561068a57600080fd5b88602082850101111561069c57600080fd5b6020928301965094505085013573ffffffffffffffffffffffffffffffffffffffff811681146106cb57600080fd5b9150604085013580151581146106e057600080fd5b939692955090935050565b6000602082840312156106fd57600080fd5b5035919050565b602081528151602082015273ffffffffffffffffffffffffffffffffffffffff60208301511660408201526040820151151560608201526000606083015160808084015261056960a08401826105d5565b600084516107678184602089016105b1565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516107a3816001850160208a016105b1565b600192019182015283516107be8160028401602088016105b1565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600181811c9082168061080e57607f821691505b602082108103610847577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561089757600081815260208120601f850160051c810160208610156108745750805b601f850160051c820191505b8181101561089357828155600101610880565b5050505b505050565b815167ffffffffffffffff8111156108b6576108b66107cb565b6108ca816108c484546107fa565b8461084d565b602080601f83116001811461091d57600084156108e75750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555610893565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561096a5788860151825594840194600190910190840161094b565b50858210156109a657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610a1657610a166109b6565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610a5b57610a5b610a1d565b500490565b81810381811115610a7357610a736109b6565b92915050565b600082610a8857610a88610a1d565b500690565b80820180821115610a7357610a736109b6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008451610ae18184602089016105b1565b60609490941b7fffffffffffffffffffffffffffffffffffffffff000000000000000000000000169190930190815290151560f81b60148201526015019291505056fea164736f6c6343000813000a"
func init() {
if err := json.Unmarshal([]byte(SchemaRegistryStorageLayoutJSON), SchemaRegistryStorageLayout); err != nil {
......
......@@ -139,16 +139,15 @@ func (l *loader) FetchClaims(ctx context.Context) ([]types.Claim, error) {
}
// FetchAbsolutePrestateHash fetches the hashed absolute prestate from the fault dispute game.
func (l *loader) FetchAbsolutePrestateHash(ctx context.Context) ([]byte, error) {
func (l *loader) FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error) {
callOpts := bind.CallOpts{
Context: ctx,
}
absolutePrestate, err := l.caller.ABSOLUTEPRESTATE(&callOpts)
if err != nil {
return nil, err
return common.Hash{}, err
}
returnValue := absolutePrestate[:]
return returnValue, nil
return absolutePrestate, nil
}
......@@ -16,7 +16,6 @@ import (
"github.com/ethereum-optimism/optimism/op-service/txmgr"
"github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
)
......@@ -159,22 +158,21 @@ func (g *GamePlayer) logGameStatus(ctx context.Context, status gameTypes.GameSta
}
type PrestateLoader interface {
FetchAbsolutePrestateHash(ctx context.Context) ([]byte, error)
FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error)
}
// ValidateAbsolutePrestate validates the absolute prestate of the fault game.
func ValidateAbsolutePrestate(ctx context.Context, trace types.TraceProvider, loader PrestateLoader) error {
providerPrestate, err := trace.AbsolutePreState(ctx)
providerPrestateHash, err := trace.AbsolutePreStateCommitment(ctx)
if err != nil {
return fmt.Errorf("failed to get the trace provider's absolute prestate: %w", err)
}
providerPrestateHash := crypto.Keccak256(providerPrestate)
onchainPrestate, err := loader.FetchAbsolutePrestateHash(ctx)
if err != nil {
return fmt.Errorf("failed to get the onchain absolute prestate: %w", err)
}
if !bytes.Equal(providerPrestateHash, onchainPrestate) {
return fmt.Errorf("trace provider's absolute prestate does not match onchain absolute prestate")
if !bytes.Equal(providerPrestateHash[:], onchainPrestate[:]) {
return fmt.Errorf("trace provider's absolute prestate does not match onchain absolute prestate: Provider: %s | Chain %s", providerPrestateHash.Hex(), onchainPrestate.Hex())
}
return nil
}
......@@ -6,6 +6,7 @@ import (
"fmt"
"testing"
"github.com/ethereum-optimism/optimism/cannon/mipsevm"
"github.com/ethereum-optimism/optimism/op-challenger/game/fault/types"
gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types"
"github.com/ethereum-optimism/optimism/op-node/testlog"
......@@ -120,8 +121,9 @@ func TestValidateAbsolutePrestate(t *testing.T) {
t.Run("ValidPrestates", func(t *testing.T) {
prestate := []byte{0x00, 0x01, 0x02, 0x03}
prestateHash := crypto.Keccak256(prestate)
prestateHash[0] = mipsevm.VMStatusUnfinished
mockTraceProvider := newMockTraceProvider(false, prestate)
mockLoader := newMockPrestateLoader(false, prestateHash)
mockLoader := newMockPrestateLoader(false, common.BytesToHash(prestateHash))
err := ValidateAbsolutePrestate(context.Background(), mockTraceProvider, mockLoader)
require.NoError(t, err)
})
......@@ -129,7 +131,7 @@ func TestValidateAbsolutePrestate(t *testing.T) {
t.Run("TraceProviderErrors", func(t *testing.T) {
prestate := []byte{0x00, 0x01, 0x02, 0x03}
mockTraceProvider := newMockTraceProvider(true, prestate)
mockLoader := newMockPrestateLoader(false, prestate)
mockLoader := newMockPrestateLoader(false, common.BytesToHash(prestate))
err := ValidateAbsolutePrestate(context.Background(), mockTraceProvider, mockLoader)
require.ErrorIs(t, err, mockTraceProviderError)
})
......@@ -137,14 +139,14 @@ func TestValidateAbsolutePrestate(t *testing.T) {
t.Run("LoaderErrors", func(t *testing.T) {
prestate := []byte{0x00, 0x01, 0x02, 0x03}
mockTraceProvider := newMockTraceProvider(false, prestate)
mockLoader := newMockPrestateLoader(true, prestate)
mockLoader := newMockPrestateLoader(true, common.BytesToHash(prestate))
err := ValidateAbsolutePrestate(context.Background(), mockTraceProvider, mockLoader)
require.ErrorIs(t, err, mockLoaderError)
})
t.Run("PrestateMismatch", func(t *testing.T) {
mockTraceProvider := newMockTraceProvider(false, []byte{0x00, 0x01, 0x02, 0x03})
mockLoader := newMockPrestateLoader(false, []byte{0x00})
mockLoader := newMockPrestateLoader(false, common.BytesToHash([]byte{0x00}))
err := ValidateAbsolutePrestate(context.Background(), mockTraceProvider, mockLoader)
require.Error(t, err)
})
......@@ -210,21 +212,31 @@ func (m *mockTraceProvider) AbsolutePreState(ctx context.Context) ([]byte, error
}
return m.prestate, nil
}
func (m *mockTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (common.Hash, error) {
prestate, err := m.AbsolutePreState(ctx)
if err != nil {
return common.Hash{}, err
}
hash := common.BytesToHash(crypto.Keccak256(prestate))
hash[0] = mipsevm.VMStatusUnfinished
return hash, nil
}
type mockLoader struct {
prestateError bool
prestate []byte
prestate common.Hash
}
func newMockPrestateLoader(prestateError bool, prestate []byte) *mockLoader {
func newMockPrestateLoader(prestateError bool, prestate common.Hash) *mockLoader {
return &mockLoader{
prestateError: prestateError,
prestate: prestate,
}
}
func (m *mockLoader) FetchAbsolutePrestateHash(ctx context.Context) ([]byte, error) {
func (m *mockLoader) FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error) {
if m.prestateError {
return nil, mockLoaderError
return common.Hash{}, mockLoaderError
}
return m.prestate, nil
}
package solver
import (
"bytes"
"context"
"errors"
"fmt"
......@@ -132,7 +133,7 @@ func (s *Solver) defend(ctx context.Context, claim types.Claim) (*types.Claim, e
// agreeWithClaim returns true if the claim is correct according to the internal [TraceProvider].
func (s *Solver) agreeWithClaim(ctx context.Context, claim types.ClaimData) (bool, error) {
ourValue, err := s.traceAtPosition(ctx, claim.Position)
return ourValue == claim.Value, err
return bytes.Equal(ourValue[:], claim.Value[:]), err
}
// traceAtPosition returns the [common.Hash] from internal [TraceProvider] at the given [Position].
......
......@@ -6,6 +6,7 @@ import (
"math/big"
"strings"
"github.com/ethereum-optimism/optimism/cannon/mipsevm"
"github.com/ethereum-optimism/optimism/op-challenger/game/fault/types"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto"
......@@ -58,7 +59,7 @@ func (ap *AlphabetTraceProvider) Get(ctx context.Context, i uint64) (common.Hash
if err != nil {
return common.Hash{}, err
}
return crypto.Keccak256Hash(claimBytes), nil
return alphabetStateHash(claimBytes), nil
}
// AbsolutePreState returns the absolute pre-state for the alphabet trace.
......@@ -66,11 +67,27 @@ func (ap *AlphabetTraceProvider) AbsolutePreState(ctx context.Context) ([]byte,
return common.Hex2Bytes("0000000000000000000000000000000000000000000000000000000000000060"), nil
}
func (ap *AlphabetTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (common.Hash, error) {
prestate, err := ap.AbsolutePreState(ctx)
if err != nil {
return common.Hash{}, err
}
hash := common.BytesToHash(crypto.Keccak256(prestate))
hash[0] = mipsevm.VMStatusUnfinished
return hash, nil
}
// BuildAlphabetPreimage constructs the claim bytes for the index and state item.
func BuildAlphabetPreimage(i uint64, letter string) []byte {
return append(IndexToBytes(i), LetterToBytes(letter)...)
}
func alphabetStateHash(state []byte) common.Hash {
h := crypto.Keccak256Hash(state)
h[0] = mipsevm.VMStatusInvalid
return h
}
// IndexToBytes converts an index to a byte slice big endian
func IndexToBytes(i uint64) []byte {
big := new(big.Int)
......
......@@ -6,12 +6,11 @@ import (
"testing"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto"
"github.com/stretchr/testify/require"
)
func alphabetClaim(index uint64, letter string) common.Hash {
return crypto.Keccak256Hash(BuildAlphabetPreimage(index, letter))
return alphabetStateHash(BuildAlphabetPreimage(index, letter))
}
// TestAlphabetProvider_Get_ClaimsByTraceIndex tests the [fault.AlphabetProvider] Get function.
......@@ -60,7 +59,7 @@ func FuzzIndexToBytes(f *testing.F) {
// returns the correct pre-image for a index.
func TestGetStepData_Succeeds(t *testing.T) {
ap := NewTraceProvider("abc", 2)
expected := BuildAlphabetPreimage(0, "a'")
expected := BuildAlphabetPreimage(0, "a")
retrieved, proof, data, err := ap.GetStepData(context.Background(), uint64(1))
require.NoError(t, err)
require.Equal(t, expected, retrieved)
......
......@@ -15,9 +15,10 @@ import (
"github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/ethclient"
"github.com/ethereum/go-ethereum/log"
"github.com/ethereum-optimism/optimism/cannon/mipsevm"
)
const (
......@@ -25,7 +26,7 @@ const (
)
type proofData struct {
ClaimValue hexutil.Bytes `json:"post"`
ClaimValue common.Hash `json:"post"`
StateData hexutil.Bytes `json:"state-data"`
ProofData hexutil.Bytes `json:"proof-data"`
OracleKey hexutil.Bytes `json:"oracle-key,omitempty"`
......@@ -86,7 +87,7 @@ func (p *CannonTraceProvider) Get(ctx context.Context, i uint64) (common.Hash, e
if err != nil {
return common.Hash{}, err
}
value := common.BytesToHash(proof.ClaimValue)
value := proof.ClaimValue
if value == (common.Hash{}) {
return common.Hash{}, errors.New("proof missing post hash")
......@@ -122,6 +123,18 @@ func (p *CannonTraceProvider) AbsolutePreState(ctx context.Context) ([]byte, err
return state.EncodeWitness(), nil
}
func (p *CannonTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (common.Hash, error) {
state, err := p.AbsolutePreState(ctx)
if err != nil {
return common.Hash{}, fmt.Errorf("cannot load absolute pre-state: %w", err)
}
hash, err := mipsevm.StateWitness(state).StateHash()
if err != nil {
return common.Hash{}, fmt.Errorf("cannot hash absolute pre-state: %w", err)
}
return hash, nil
}
// loadProof will attempt to load or generate the proof data at the specified index
// If the requested index is beyond the end of the actual trace it is extended with no-op instructions.
func (p *CannonTraceProvider) loadProof(ctx context.Context, i uint64) (*proofData, error) {
......@@ -151,9 +164,13 @@ func (p *CannonTraceProvider) loadProof(ctx context.Context, i uint64) (*proofDa
// Extend the trace out to the full length using a no-op instruction that doesn't change any state
// No execution is done, so no proof-data or oracle values are required.
witness := state.EncodeWitness()
witnessHash, err := mipsevm.StateWitness(witness).StateHash()
if err != nil {
return nil, fmt.Errorf("cannot hash witness: %w", err)
}
proof := &proofData{
ClaimValue: crypto.Keccak256(witness),
StateData: witness,
ClaimValue: witnessHash,
StateData: hexutil.Bytes(witness),
ProofData: []byte{},
OracleKey: nil,
OracleValue: nil,
......
......@@ -15,7 +15,6 @@ import (
"github.com/ethereum-optimism/optimism/op-node/testlog"
"github.com/ethereum-optimism/optimism/op-service/ioutil"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/log"
"github.com/stretchr/testify/require"
)
......@@ -43,7 +42,9 @@ func TestGet(t *testing.T) {
value, err := provider.Get(context.Background(), 7000)
require.NoError(t, err)
require.Contains(t, generator.generated, 7000, "should have tried to generate the proof")
require.Equal(t, crypto.Keccak256Hash(generator.finalState.EncodeWitness()), value)
stateHash, err := generator.finalState.EncodeWitness().StateHash()
require.NoError(t, err)
require.Equal(t, stateHash, value)
})
t.Run("MissingPostHash", func(t *testing.T) {
......@@ -86,7 +87,7 @@ func TestGetStepData(t *testing.T) {
Exited: true,
}
generator.proof = &proofData{
ClaimValue: common.Hash{0xaa}.Bytes(),
ClaimValue: common.Hash{0xaa},
StateData: []byte{0xbb},
ProofData: []byte{0xcc},
OracleKey: common.Hash{0xdd}.Bytes(),
......@@ -111,7 +112,7 @@ func TestGetStepData(t *testing.T) {
Exited: true,
}
generator.proof = &proofData{
ClaimValue: common.Hash{0xaa}.Bytes(),
ClaimValue: common.Hash{0xaa},
StateData: []byte{0xbb},
ProofData: []byte{0xcc},
OracleKey: common.Hash{0xdd}.Bytes(),
......@@ -185,7 +186,7 @@ func TestAbsolutePreState(t *testing.T) {
Step: 0,
Registers: [32]uint32{},
}
require.Equal(t, state.EncodeWitness(), preState)
require.Equal(t, []byte(state.EncodeWitness()), preState)
})
}
......
......@@ -74,6 +74,9 @@ type TraceProvider interface {
// AbsolutePreState is the pre-image value of the trace that transitions to the trace value at index 0
AbsolutePreState(ctx context.Context) (preimage []byte, err error)
// AbsolutePreStateCommitment is the commitment of the pre-image value of the trace that transitions to the trace value at index 0
AbsolutePreStateCommitment(ctx context.Context) (hash common.Hash, err error)
}
// ClaimData is the core of a claim. It must be unique inside a specific game.
......
......@@ -65,16 +65,16 @@ func (g *FaultGameHelper) MaxDepth(ctx context.Context) int64 {
}
func (g *FaultGameHelper) waitForClaim(ctx context.Context, errorMsg string, predicate func(claim ContractClaim) bool) {
ctx, cancel := context.WithTimeout(ctx, time.Minute)
timedCtx, cancel := context.WithTimeout(ctx, time.Minute)
defer cancel()
err := wait.For(ctx, time.Second, func() (bool, error) {
count, err := g.game.ClaimDataLen(&bind.CallOpts{Context: ctx})
err := wait.For(timedCtx, time.Second, func() (bool, error) {
count, err := g.game.ClaimDataLen(&bind.CallOpts{Context: timedCtx})
if err != nil {
return false, fmt.Errorf("retrieve number of claims: %w", err)
}
// Search backwards because the new claims are at the end and more likely the ones we want.
for i := count.Int64() - 1; i >= 0; i-- {
claimData, err := g.game.ClaimData(&bind.CallOpts{Context: ctx}, big.NewInt(i))
claimData, err := g.game.ClaimData(&bind.CallOpts{Context: timedCtx}, big.NewInt(i))
if err != nil {
return false, fmt.Errorf("retrieve claim %v: %w", i, err)
}
......@@ -127,10 +127,10 @@ func (g *FaultGameHelper) Resolve(ctx context.Context) {
func (g *FaultGameHelper) WaitForGameStatus(ctx context.Context, expected Status) {
g.t.Logf("Waiting for game %v to have status %v", g.addr, expected)
ctx, cancel := context.WithTimeout(ctx, time.Minute)
timedCtx, cancel := context.WithTimeout(ctx, time.Minute)
defer cancel()
err := wait.For(ctx, time.Second, func() (bool, error) {
ctx, cancel := context.WithTimeout(ctx, 30*time.Second)
err := wait.For(timedCtx, time.Second, func() (bool, error) {
ctx, cancel := context.WithTimeout(timedCtx, 30*time.Second)
defer cancel()
status, err := g.game.Status(&bind.CallOpts{Context: ctx})
if err != nil {
......@@ -139,7 +139,60 @@ func (g *FaultGameHelper) WaitForGameStatus(ctx context.Context, expected Status
g.t.Logf("Game %v has state %v, waiting for state %v", g.addr, Status(status), expected)
return expected == Status(status), nil
})
g.require.NoError(err, "wait for game status")
g.require.NoErrorf(err, "wait for game status. Game state: \n%v", g.gameData(ctx))
}
// Mover is a function that either attacks or defends the claim at parentClaimIdx
type Mover func(parentClaimIdx int64)
// Stepper is a function that attempts to perform a step against the claim at parentClaimIdx
type Stepper func(parentClaimIdx int64)
// DefendRootClaim uses the supplied Mover to perform moves in an attempt to defend the root claim.
// It is assumed that the output root being disputed is valid and that an honest op-challenger is already running.
// When the game has reached the maximum depth it waits for the honest challenger to counter the leaf claim with step.
func (g *FaultGameHelper) DefendRootClaim(ctx context.Context, performMove Mover) {
maxDepth := g.MaxDepth(ctx)
for claimCount := int64(1); claimCount < maxDepth; {
g.LogGameData(ctx)
claimCount++
// Wait for the challenger to counter
g.WaitForClaimCount(ctx, claimCount)
// Respond with our own move
performMove(claimCount - 1)
claimCount++
g.WaitForClaimCount(ctx, claimCount)
}
// Wait for the challenger to call step and counter our invalid claim
g.WaitForClaimAtMaxDepth(ctx, true)
}
// ChallengeRootClaim uses the supplied Mover and Stepper to perform moves and steps in an attempt to challenge the root claim.
// It is assumed that the output root being disputed is invalid and that an honest op-challenger is already running.
// When the game has reached the maximum depth it calls the Stepper to attempt to counter the leaf claim.
// Since the output root is invalid, it should not be possible for the Stepper to call step successfully.
func (g *FaultGameHelper) ChallengeRootClaim(ctx context.Context, performMove Mover, attemptStep Stepper) {
maxDepth := g.MaxDepth(ctx)
for claimCount := int64(1); claimCount < maxDepth; {
g.LogGameData(ctx)
// Perform our move
performMove(claimCount - 1)
claimCount++
g.WaitForClaimCount(ctx, claimCount)
// Wait for the challenger to counter
claimCount++
g.WaitForClaimCount(ctx, claimCount)
}
// Confirm the game has reached max depth and the last claim hasn't been countered
g.WaitForClaimAtMaxDepth(ctx, false)
g.LogGameData(ctx)
// It's on us to call step if we want to win but shouldn't be possible
attemptStep(maxDepth)
}
func (g *FaultGameHelper) Attack(ctx context.Context, claimIdx int64, claim common.Hash) {
......@@ -156,6 +209,19 @@ func (g *FaultGameHelper) Defend(ctx context.Context, claimIdx int64, claim comm
g.require.NoError(err, "Defend transaction was not OK")
}
type ErrWithData interface {
ErrorData() interface{}
}
// StepFails attempts to call step and verifies that it fails with ValidStep()
func (g *FaultGameHelper) StepFails(claimIdx int64, isAttack bool, stateData []byte, proof []byte) {
g.t.Logf("Attempting step against claim %v isAttack: %v", claimIdx, isAttack)
_, err := g.game.Step(g.opts, big.NewInt(claimIdx), isAttack, stateData, proof)
errData, ok := err.(ErrWithData)
g.require.Truef(ok, "Error should provide ErrorData method: %v", err)
g.require.Equal("0xfb4e40dd", errData.ErrorData(), "Revert reason should be abi encoded ValidStep()")
}
func (g *FaultGameHelper) gameData(ctx context.Context) string {
opts := &bind.CallOpts{Context: ctx}
maxDepth := int(g.MaxDepth(ctx))
......
......@@ -9,6 +9,7 @@ import (
"testing"
"time"
"github.com/ethereum-optimism/optimism/cannon/mipsevm"
"github.com/ethereum-optimism/optimism/op-bindings/bindings"
"github.com/ethereum-optimism/optimism/op-chain-ops/deployer"
"github.com/ethereum-optimism/optimism/op-chain-ops/genesis"
......@@ -174,6 +175,9 @@ func (h *FactoryHelper) StartCannonGameWithCorrectRoot(ctx context.Context, roll
provider := cannon.NewTraceProviderFromInputs(testlog.Logger(h.t, log.LvlInfo).New("role", "CorrectTrace"), metrics.NoopMetrics, cfg, inputs, cfg.Datadir)
rootClaim, err := provider.Get(ctx, math.MaxUint64)
h.require.NoError(err, "Compute correct root hash")
// Override the VM status to claim the root is invalid
// Otherwise creating the game will fail
rootClaim[0] = mipsevm.VMStatusInvalid
game := h.createCannonGame(ctx, l2BlockNumber, l1Head, rootClaim)
honestHelper := &HonestHelper{
......
......@@ -42,3 +42,18 @@ func (h *HonestHelper) Defend(ctx context.Context, claimIdx int64) {
h.game.require.NoErrorf(err, "Get correct claim at trace index %v", traceIdx)
h.game.Defend(ctx, claimIdx, value)
}
func (h *HonestHelper) StepFails(ctx context.Context, claimIdx int64, isAttack bool) {
ctx, cancel := context.WithTimeout(ctx, 2*time.Minute)
defer cancel()
claim := h.game.getClaim(ctx, claimIdx)
pos := types.NewPositionFromGIndex(claim.Position.Uint64())
traceIdx := pos.TraceIndex(int(h.game.MaxDepth(ctx)))
if !isAttack {
// If we're defending, then the step will be from the trace to the next one
traceIdx += 1
}
prestate, proofData, _, err := h.correctTrace.GetStepData(ctx, traceIdx)
h.require.NoError(err, "Get step data")
h.game.StepFails(claimIdx, isAttack, prestate, proofData)
}
......@@ -13,43 +13,6 @@ import (
"github.com/stretchr/testify/require"
)
func TestMultipleAlphabetGames(t *testing.T) {
InitParallel(t)
ctx := context.Background()
sys, l1Client := startFaultDisputeSystem(t)
t.Cleanup(sys.Close)
gameFactory := disputegame.NewFactoryHelper(t, ctx, sys.cfg.L1Deployments, l1Client)
// Start a challenger with the correct alphabet trace
gameFactory.StartChallenger(ctx, sys.NodeEndpoint("l1"), "TowerDefense",
challenger.WithAlphabet("abcdefg"),
challenger.WithPrivKey(sys.cfg.Secrets.Alice),
challenger.WithAgreeProposedOutput(true),
)
game1 := gameFactory.StartAlphabetGame(ctx, "abcxyz")
// Wait for the challenger to respond to the first game
game1.WaitForClaimCount(ctx, 2)
game2 := gameFactory.StartAlphabetGame(ctx, "zyxabc")
// Wait for the challenger to respond to the second game
game2.WaitForClaimCount(ctx, 2)
// Challenger should respond to new claims
game2.Attack(ctx, 1, common.Hash{0xaa})
game2.WaitForClaimCount(ctx, 4)
game1.Defend(ctx, 1, common.Hash{0xaa})
game1.WaitForClaimCount(ctx, 4)
gameDuration := game1.GameDuration(ctx)
sys.TimeTravelClock.AdvanceTime(gameDuration)
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
game1.WaitForGameStatus(ctx, disputegame.StatusChallengerWins)
game2.WaitForGameStatus(ctx, disputegame.StatusChallengerWins)
}
func TestMultipleCannonGames(t *testing.T) {
InitParallel(t)
......@@ -65,8 +28,8 @@ func TestMultipleCannonGames(t *testing.T) {
challenger.WithAgreeProposedOutput(true),
)
game1 := gameFactory.StartCannonGame(ctx, common.Hash{0xaa})
game2 := gameFactory.StartCannonGame(ctx, common.Hash{0xbb})
game1 := gameFactory.StartCannonGame(ctx, common.Hash{0x01, 0xaa})
game2 := gameFactory.StartCannonGame(ctx, common.Hash{0x01, 0xbb})
game1.WaitForClaimCount(ctx, 2)
game2.WaitForClaimCount(ctx, 2)
......@@ -106,36 +69,6 @@ func TestMultipleCannonGames(t *testing.T) {
challenger.WaitForGameDataDeletion(ctx, game1, game2)
}
func TestResolveDisputeGame(t *testing.T) {
InitParallel(t)
ctx := context.Background()
sys, l1Client := startFaultDisputeSystem(t)
t.Cleanup(sys.Close)
disputeGameFactory := disputegame.NewFactoryHelper(t, ctx, sys.cfg.L1Deployments, l1Client)
game := disputeGameFactory.StartAlphabetGame(ctx, "zyxwvut")
require.NotNil(t, game)
gameDuration := game.GameDuration(ctx)
game.WaitForGameStatus(ctx, disputegame.StatusInProgress)
game.StartChallenger(ctx, sys.NodeEndpoint("l1"), "HonestAlice",
challenger.WithAgreeProposedOutput(true),
challenger.WithAlphabet("abcdefg"),
challenger.WithPrivKey(sys.cfg.Secrets.Alice),
)
game.WaitForClaimCount(ctx, 2)
sys.TimeTravelClock.AdvanceTime(gameDuration)
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
// Challenger should resolve the game now that the clocks have expired.
game.WaitForGameStatus(ctx, disputegame.StatusChallengerWins)
}
func TestChallengerCompleteDisputeGame(t *testing.T) {
InitParallel(t)
......@@ -244,8 +177,8 @@ func TestCannonDisputeGame(t *testing.T) {
InitParallel(t)
tests := []struct {
name string
defendAtClaim int64
name string
defendClaimCount int64
}{
{"StepFirst", 0},
{"StepMiddle", 28},
......@@ -261,7 +194,7 @@ func TestCannonDisputeGame(t *testing.T) {
t.Cleanup(sys.Close)
disputeGameFactory := disputegame.NewFactoryHelper(t, ctx, sys.cfg.L1Deployments, l1Client)
game := disputeGameFactory.StartCannonGame(ctx, common.Hash{0xaa})
game := disputeGameFactory.StartCannonGame(ctx, common.Hash{0x01, 0xaa})
require.NotNil(t, game)
game.LogGameData(ctx)
......@@ -271,27 +204,15 @@ func TestCannonDisputeGame(t *testing.T) {
challenger.WithPrivKey(sys.cfg.Secrets.Alice),
)
maxDepth := game.MaxDepth(ctx)
for claimCount := int64(1); claimCount < maxDepth; {
game.LogGameData(ctx)
claimCount++
// Wait for the challenger to counter
game.WaitForClaimCount(ctx, claimCount)
// Post our own counter to the latest challenger claim
if claimCount == test.defendAtClaim {
// Defend one claim so we don't wind up executing from the absolute pre-state
game.Defend(ctx, claimCount-1, common.Hash{byte(claimCount)})
} else {
game.Attack(ctx, claimCount-1, common.Hash{byte(claimCount)})
}
claimCount++
game.WaitForClaimCount(ctx, claimCount)
}
game.LogGameData(ctx)
// Wait for the challenger to call step and counter our invalid claim
game.WaitForClaimAtMaxDepth(ctx, true)
game.DefendRootClaim(
ctx,
func(parentClaimIdx int64) {
if parentClaimIdx+1 == test.defendClaimCount {
game.Defend(ctx, parentClaimIdx, common.Hash{byte(parentClaimIdx)})
} else {
game.Attack(ctx, parentClaimIdx, common.Hash{byte(parentClaimIdx)})
}
})
sys.TimeTravelClock.AdvanceTime(game.GameDuration(ctx))
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
......@@ -310,7 +231,7 @@ func TestCannonDefendStep(t *testing.T) {
t.Cleanup(sys.Close)
disputeGameFactory := disputegame.NewFactoryHelper(t, ctx, sys.cfg.L1Deployments, l1Client)
game := disputeGameFactory.StartCannonGame(ctx, common.Hash{0xaa})
game := disputeGameFactory.StartCannonGame(ctx, common.Hash{0x01, 0xaa})
require.NotNil(t, game)
game.LogGameData(ctx)
......@@ -326,28 +247,15 @@ func TestCannonDefendStep(t *testing.T) {
challenger.WithPrivKey(sys.cfg.Secrets.Mallory),
)
maxDepth := game.MaxDepth(ctx)
for claimCount := int64(1); claimCount < maxDepth; {
game.LogGameData(ctx)
claimCount++
// Wait for the challenger to counter
game.WaitForClaimCount(ctx, claimCount)
game.DefendRootClaim(ctx, func(parentClaimIdx int64) {
// Post invalid claims for most steps to get down into the early part of the trace
if claimCount < 28 {
game.Attack(ctx, claimCount-1, common.Hash{byte(claimCount)})
if parentClaimIdx < 27 {
game.Attack(ctx, parentClaimIdx, common.Hash{byte(parentClaimIdx)})
} else {
// Post our own counter but using the correct hash in low levels to force a defense step
correctTrace.Attack(ctx, claimCount-1)
correctTrace.Attack(ctx, parentClaimIdx)
}
claimCount++
game.LogGameData(ctx)
game.WaitForClaimCount(ctx, claimCount)
}
game.LogGameData(ctx)
// Wait for the challenger to call step and counter our invalid claim
game.WaitForClaimAtMaxDepth(ctx, true)
})
sys.TimeTravelClock.AdvanceTime(game.GameDuration(ctx))
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
......@@ -358,41 +266,79 @@ func TestCannonDefendStep(t *testing.T) {
func TestCannonProposedOutputRootInvalid(t *testing.T) {
InitParallel(t)
// honestStepsFail attempts to perform both an attack and defend step using the correct trace.
honestStepsFail := func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64) {
// Attack step should fail
correctTrace.StepFails(ctx, parentClaimIdx, true)
// Defending should fail too
correctTrace.StepFails(ctx, parentClaimIdx, false)
}
tests := []struct {
// name is the name of the test
name string
ctx := context.Background()
sys, l1Client, game, correctTrace := setupDisputeGameForInvalidOutputRoot(t, common.Hash{0xab})
t.Cleanup(sys.Close)
maxDepth := game.MaxDepth(ctx)
// Now maliciously play the game and it should be impossible to win
// outputRoot is the invalid output root to propose
outputRoot common.Hash
for claimCount := int64(1); claimCount < maxDepth; {
// Attack everything but oddly using the correct hash.
correctTrace.Attack(ctx, claimCount-1)
claimCount++
game.LogGameData(ctx)
game.WaitForClaimCount(ctx, claimCount)
// performMove is called to respond to each claim posted by the honest op-challenger.
// It should either attack or defend the claim at parentClaimIdx
performMove func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64)
game.LogGameData(ctx)
// Wait for the challenger to counter
claimCount++
game.WaitForClaimCount(ctx, claimCount)
// performStep is called once the maximum game depth is reached. It should perform a step to counter the
// claim at parentClaimIdx. Since the proposed output root is invalid, the step call should always revert.
performStep func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64)
}{
{
name: "AttackWithCorrectTrace",
outputRoot: common.Hash{0xab},
performMove: func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64) {
// Attack everything but oddly using the correct hash.
correctTrace.Attack(ctx, parentClaimIdx)
},
performStep: honestStepsFail,
},
{
name: "DefendWithCorrectTrace",
outputRoot: common.Hash{0xab},
performMove: func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64) {
// Can only attack the root claim
if parentClaimIdx == 0 {
correctTrace.Attack(ctx, parentClaimIdx)
return
}
// Otherwise, defend everything using the correct hash.
correctTrace.Defend(ctx, parentClaimIdx)
},
performStep: honestStepsFail,
},
}
game.LogGameData(ctx)
// Wait for the challenger to call step and counter our invalid claim
game.WaitForClaimAtMaxDepth(ctx, false)
for _, test := range tests {
test := test
t.Run(test.name, func(t *testing.T) {
InitParallel(t)
// It's on us to call step if we want to win but shouldn't be possible
// Need to add support for this to the helper
ctx := context.Background()
sys, l1Client, game, correctTrace := setupDisputeGameForInvalidOutputRoot(t, test.outputRoot)
t.Cleanup(sys.Close)
// Time travel past when the game will be resolvable.
sys.TimeTravelClock.AdvanceTime(game.GameDuration(ctx))
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
// Now maliciously play the game and it should be impossible to win
game.ChallengeRootClaim(ctx,
func(parentClaimIdx int64) {
test.performMove(ctx, game, correctTrace, parentClaimIdx)
},
func(parentClaimIdx int64) {
test.performStep(ctx, game, correctTrace, parentClaimIdx)
})
game.WaitForGameStatus(ctx, disputegame.StatusDefenderWins)
game.LogGameData(ctx)
// Time travel past when the game will be resolvable.
sys.TimeTravelClock.AdvanceTime(game.GameDuration(ctx))
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
game.WaitForGameStatus(ctx, disputegame.StatusDefenderWins)
game.LogGameData(ctx)
})
}
}
// setupDisputeGameForInvalidOutputRoot sets up an L2 chain with at least one valid output root followed by an invalid output root.
......@@ -411,7 +357,7 @@ func setupDisputeGameForInvalidOutputRoot(t *testing.T, outputRoot common.Hash)
sys.L2OutputSubmitter.Stop()
sys.L2OutputSubmitter = nil
// Submit an invalid output rooot
// Submit an invalid output root
l2oo.PublishNextOutput(ctx, outputRoot)
l1Endpoint := sys.NodeEndpoint("l1")
......@@ -434,7 +380,6 @@ func setupDisputeGameForInvalidOutputRoot(t *testing.T, outputRoot common.Hash)
}
func TestCannonChallengeWithCorrectRoot(t *testing.T) {
t.Skip("Not currently handling this case as the correct approach will change when output root bisection is added")
InitParallel(t)
ctx := context.Background()
......@@ -457,23 +402,10 @@ func TestCannonChallengeWithCorrectRoot(t *testing.T) {
challenger.WithPrivKey(sys.cfg.Secrets.Alice),
)
maxDepth := game.MaxDepth(ctx)
for claimCount := int64(1); claimCount < maxDepth; {
game.LogGameData(ctx)
claimCount++
// Wait for the challenger to counter
game.WaitForClaimCount(ctx, claimCount)
game.DefendRootClaim(ctx, func(parentClaimIdx int64) {
// Defend everything because we have the same trace as the honest proposer
correctTrace.Defend(ctx, claimCount-1)
claimCount++
game.LogGameData(ctx)
game.WaitForClaimCount(ctx, claimCount)
}
game.LogGameData(ctx)
// Wait for the challenger to call step and counter our invalid claim
game.WaitForClaimAtMaxDepth(ctx, true)
correctTrace.Defend(ctx, parentClaimIdx)
})
sys.TimeTravelClock.AdvanceTime(game.GameDuration(ctx))
require.NoError(t, wait.ForNextBlock(ctx, l1Client))
......
......@@ -120,8 +120,9 @@ func DefaultSystemConfig(t *testing.T) SystemConfig {
ListenPort: 0,
EnableAdmin: true,
},
L1EpochPollInterval: time.Second * 2,
ConfigPersistence: &rollupNode.DisabledConfigPersistence{},
L1EpochPollInterval: time.Second * 2,
RuntimeConfigReloadInterval: time.Minute * 10,
ConfigPersistence: &rollupNode.DisabledConfigPersistence{},
},
"verifier": {
Driver: driver.Config{
......@@ -129,8 +130,9 @@ func DefaultSystemConfig(t *testing.T) SystemConfig {
SequencerConfDepth: 0,
SequencerEnabled: false,
},
L1EpochPollInterval: time.Second * 4,
ConfigPersistence: &rollupNode.DisabledConfigPersistence{},
L1EpochPollInterval: time.Second * 4,
RuntimeConfigReloadInterval: time.Minute * 10,
ConfigPersistence: &rollupNode.DisabledConfigPersistence{},
},
},
Loggers: map[string]log.Logger{
......
......@@ -30,6 +30,7 @@ import (
"github.com/ethereum-optimism/optimism/op-bindings/bindings"
"github.com/ethereum-optimism/optimism/op-bindings/predeploys"
"github.com/ethereum-optimism/optimism/op-e2e/config"
"github.com/ethereum-optimism/optimism/op-e2e/e2eutils/wait"
"github.com/ethereum-optimism/optimism/op-node/client"
"github.com/ethereum-optimism/optimism/op-node/metrics"
rollupNode "github.com/ethereum-optimism/optimism/op-node/node"
......@@ -1389,3 +1390,47 @@ func TestPendingBlockIsLatest(t *testing.T) {
t.Fatal("failed to get pending header with same number as latest header")
})
}
func TestRuntimeConfigReload(t *testing.T) {
InitParallel(t)
cfg := DefaultSystemConfig(t)
// to speed up the test, make it reload the config more often, and do not impose a long conf depth
cfg.Nodes["verifier"].RuntimeConfigReloadInterval = time.Second * 5
cfg.Nodes["verifier"].Driver.VerifierConfDepth = 1
sys, err := cfg.Start(t)
require.Nil(t, err, "Error starting up system")
defer sys.Close()
initialRuntimeConfig := sys.RollupNodes["verifier"].RuntimeConfig()
// close the EL node, since we want to block derivation, to solely rely on the reloading mechanism for updates.
sys.EthInstances["verifier"].Close()
l1 := sys.Clients["l1"]
// Change the system-config via L1
sysCfgContract, err := bindings.NewSystemConfig(cfg.L1Deployments.SystemConfigProxy, l1)
require.NoError(t, err)
newUnsafeBlocksSigner := common.Address{0x12, 0x23, 0x45}
require.NotEqual(t, initialRuntimeConfig.P2PSequencerAddress(), newUnsafeBlocksSigner, "changing to a different address")
opts, err := bind.NewKeyedTransactorWithChainID(cfg.Secrets.SysCfgOwner, cfg.L1ChainIDBig())
require.Nil(t, err)
// the unsafe signer address is part of the runtime config
tx, err := sysCfgContract.SetUnsafeBlockSigner(opts, newUnsafeBlocksSigner)
require.NoError(t, err)
// wait for the change to confirm
_, err = wait.ForReceiptOK(context.Background(), l1, tx.Hash())
require.NoError(t, err)
// wait for the address to change
_, err = retry.Do(context.Background(), 10, retry.Fixed(time.Second*10), func() (struct{}, error) {
v := sys.RollupNodes["verifier"].RuntimeConfig().P2PSequencerAddress()
if v == newUnsafeBlocksSigner {
return struct{}{}, nil
}
return struct{}{}, fmt.Errorf("no change yet, seeing %s but looking for %s", v, newUnsafeBlocksSigner)
})
require.NoError(t, err)
}
......@@ -146,6 +146,13 @@ var (
Required: false,
Value: time.Second * 12 * 32,
}
RuntimeConfigReloadIntervalFlag = &cli.DurationFlag{
Name: "l1.runtime-config-reload-interval",
Usage: "Poll interval for reloading the runtime config, useful when config events are not being picked up. Disabled if 0 or negative.",
EnvVars: prefixEnvVars("L1_RUNTIME_CONFIG_RELOAD_INTERVAL"),
Required: false,
Value: time.Minute * 10,
}
MetricsEnabledFlag = &cli.BoolFlag{
Name: "metrics.enabled",
Usage: "Enable the metrics server",
......@@ -261,6 +268,7 @@ var optionalFlags = []cli.Flag{
SequencerMaxSafeLagFlag,
SequencerL1Confs,
L1EpochPollIntervalFlag,
RuntimeConfigReloadIntervalFlag,
RPCEnableAdmin,
RPCAdminPersistence,
MetricsEnabledFlag,
......
......@@ -41,6 +41,12 @@ type Config struct {
ConfigPersistence ConfigPersistence
// RuntimeConfigReloadInterval defines the interval between runtime config reloads.
// Disabled if 0.
// Runtime config changes should be picked up from log-events,
// but if log-events are not coming in (e.g. not syncing blocks) then the reload ensures the config stays accurate.
RuntimeConfigReloadInterval time.Duration
// Optional
Tracer Tracer
Heartbeat HeartbeatConfig
......
......@@ -2,7 +2,6 @@ package node
import (
"context"
"errors"
"fmt"
"time"
......@@ -19,6 +18,7 @@ import (
"github.com/ethereum-optimism/optimism/op-node/rollup/driver"
"github.com/ethereum-optimism/optimism/op-node/sources"
"github.com/ethereum-optimism/optimism/op-service/eth"
"github.com/ethereum-optimism/optimism/op-service/retry"
)
type OpNode struct {
......@@ -159,27 +159,70 @@ func (n *OpNode) initRuntimeConfig(ctx context.Context, cfg *Config) error {
// attempt to load runtime config, repeat N times
n.runCfg = NewRuntimeConfig(n.log, n.l1Source, &cfg.Rollup)
for i := 0; i < 5; i++ {
confDepth := cfg.Driver.VerifierConfDepth
reload := func(ctx context.Context) (eth.L1BlockRef, error) {
fetchCtx, fetchCancel := context.WithTimeout(ctx, time.Second*10)
l1Head, err := n.l1Source.L1BlockRefByLabel(fetchCtx, eth.Unsafe)
fetchCancel()
if err != nil {
n.log.Error("failed to fetch L1 head for runtime config initialization", "err", err)
continue
return eth.L1BlockRef{}, err
}
// Apply confirmation-distance
blNum := l1Head.Number
if blNum >= confDepth {
blNum -= confDepth
}
fetchCtx, fetchCancel = context.WithTimeout(ctx, time.Second*10)
confirmed, err := n.l1Source.L1BlockRefByNumber(fetchCtx, blNum)
fetchCancel()
if err != nil {
n.log.Error("failed to fetch confirmed L1 block for runtime config loading", "err", err, "number", blNum)
return eth.L1BlockRef{}, err
}
fetchCtx, fetchCancel = context.WithTimeout(ctx, time.Second*10)
err = n.runCfg.Load(fetchCtx, l1Head)
err = n.runCfg.Load(fetchCtx, confirmed)
fetchCancel()
if err != nil {
n.log.Error("failed to fetch runtime config data", "err", err)
continue
return l1Head, err
}
return l1Head, nil
}
return nil
// initialize the runtime config before unblocking
if _, err := retry.Do(ctx, 5, retry.Fixed(time.Second*10), func() (eth.L1BlockRef, error) {
return reload(ctx)
}); err != nil {
return fmt.Errorf("failed to load runtime configuration repeatedly, last error: %w", err)
}
return errors.New("failed to load runtime configuration repeatedly")
// start a background loop, to keep reloading it at the configured reload interval
go func(ctx context.Context, reloadInterval time.Duration) {
if reloadInterval <= 0 {
n.log.Debug("not running runtime-config reloading background loop")
return
}
ticker := time.NewTicker(reloadInterval)
defer ticker.Stop()
for {
select {
case <-ticker.C:
// If the reload fails, we will try again the next interval.
// Missing a runtime-config update is not critical, and we do not want to overwhelm the L1 RPC.
if l1Head, err := reload(ctx); err != nil {
n.log.Warn("failed to reload runtime config", "err", err)
} else {
n.log.Debug("reloaded runtime config", "l1_head", l1Head)
}
case <-ctx.Done():
return
}
}
}(n.resourcesCtx, cfg.RuntimeConfigReloadInterval) // this keeps running after initialization
return nil
}
func (n *OpNode) initL2(ctx context.Context, cfg *Config, snapshotLog log.Logger) error {
......@@ -397,6 +440,10 @@ func (n *OpNode) P2P() p2p.Node {
return n.p2pNode
}
func (n *OpNode) RuntimeConfig() ReadonlyRuntimeConfig {
return n.runCfg
}
// Close closes all resources.
func (n *OpNode) Close() error {
var result *multierror.Error
......
......@@ -23,6 +23,10 @@ type RuntimeCfgL1Source interface {
ReadStorageAt(ctx context.Context, address common.Address, storageSlot common.Hash, blockHash common.Hash) (common.Hash, error)
}
type ReadonlyRuntimeConfig interface {
P2PSequencerAddress() common.Address
}
// RuntimeConfig maintains runtime-configurable options.
// These options are loaded based on initial loading + updates for every subsequent L1 block.
// Only the *latest* values are maintained however, the runtime config has no concept of chain history,
......
......@@ -82,9 +82,10 @@ func NewConfig(ctx *cli.Context, log log.Logger) (*node.Config, error) {
ListenAddr: ctx.String(flags.PprofAddrFlag.Name),
ListenPort: ctx.Int(flags.PprofPortFlag.Name),
},
P2P: p2pConfig,
P2PSigner: p2pSignerSetup,
L1EpochPollInterval: ctx.Duration(flags.L1EpochPollIntervalFlag.Name),
P2P: p2pConfig,
P2PSigner: p2pSignerSetup,
L1EpochPollInterval: ctx.Duration(flags.L1EpochPollIntervalFlag.Name),
RuntimeConfigReloadInterval: ctx.Duration(flags.RuntimeConfigReloadIntervalFlag.Name),
Heartbeat: node.HeartbeatConfig{
Enabled: ctx.Bool(flags.HeartbeatEnabledFlag.Name),
Moniker: ctx.String(flags.HeartbeatMonikerFlag.Name),
......
......@@ -18,9 +18,10 @@ COPY --from=builder /app/entrypoint.sh /bin/entrypoint.sh
COPY --from=builder /app/bin/ufm /bin/ufm
RUN apk update && \
apk add ca-certificates && \
chmod +x /bin/entrypoint.sh
RUN apk add ca-certificates jq curl bind-tools
VOLUME /etc/ufm
EXPOSE 8080
......
......@@ -39,12 +39,6 @@ address = "0x0000000000000000000000000000000000000000"
private_key = "0000000000000000000000000000000000000000000000000000000000000000"
# Transaction value in wei
tx_value = 100000000000000
# Gas limit
gas_limit = 21000
# Gas tip cap
gas_tip_cap = 2000000000
# Fee cap
gas_fee_cap = 20000000000
[providers.p1]
# URL to the RPC provider
......@@ -52,13 +46,15 @@ url = "http://localhost:8551"
# Read only providers are only used to check for transactions
read_only = true
# Interval to poll the provider for expected transactions
read_interval = "1s"
read_interval = "10s"
# Interval to submit new transactions to the provider
send_interval = "5s"
# Wallet to be used for sending transactions
wallet = "default"
# Network to pool transactions, i.e. providers in the same network will check transactions from each other
network = "op-goerli"
send_interval = "30s"
# Interval between send transaction when we get "already known" txpool err
send_transaction_retry_interval = "100ms"
# Max time to retry
send_transaction_retry_timeout = "5s"
# Interval between each send transaction to the same network
send_transaction_cool_down = "30s"
# Interval between receipt retrieval
receipt_retrieval_interval = "500ms"
# Max time to check for receipt
......@@ -72,13 +68,15 @@ url = "http://localhost:8552"
# Read only providers are only used to check for transactions
read_only = false
# Interval to poll the provider for expected transactions
read_interval = "2s"
read_interval = "10s"
# Interval to submit new transactions to the provider
send_interval = "3s"
# Wallet to be used for sending transactions
wallet = "default"
# Network to pool transactions, i.e. providers in the same network will check transactions from each other
network = "op-goerli"
send_interval = "30s"
# Interval between send transaction when we get "already known" txpool err
send_transaction_retry_interval = "100ms"
# Max time to retry
send_transaction_retry_timeout = "5s"
# Interval between each send transaction to the same network
send_transaction_cool_down = "30s"
# Interval between receipt retrieval
receipt_retrieval_interval = "500ms"
# Max time to check for receipt
......
......@@ -48,10 +48,7 @@ type WalletConfig struct {
PrivateKey string `toml:"private_key"`
// transaction parameters
TxValue big.Int `toml:"tx_value"`
GasLimit uint64 `toml:"gas_limit"`
GasTipCap big.Int `toml:"gas_tip_cap"`
GasFeeCap big.Int `toml:"gas_fee_cap"`
TxValue big.Int `toml:"tx_value"`
}
type ProviderConfig struct {
......@@ -64,6 +61,7 @@ type ProviderConfig struct {
SendInterval TOMLDuration `toml:"send_interval"`
SendTransactionRetryInterval TOMLDuration `toml:"send_transaction_retry_interval"`
SendTransactionRetryTimeout TOMLDuration `toml:"send_transaction_retry_timeout"`
SendTransactionCoolDown TOMLDuration `toml:"send_transaction_cool_down"`
ReceiptRetrievalInterval TOMLDuration `toml:"receipt_retrieval_interval"`
ReceiptRetrievalTimeout TOMLDuration `toml:"receipt_retrieval_timeout"`
......@@ -130,12 +128,6 @@ func (c *Config) Validate() error {
if wallet.TxValue.BitLen() == 0 {
return errors.Errorf("wallet [%s] tx_value is missing", name)
}
if wallet.GasLimit == 0 {
return errors.Errorf("wallet [%s] gas_limit is missing", name)
}
if wallet.GasFeeCap.BitLen() == 0 {
return errors.Errorf("wallet [%s] gas_fee_cap is missing", name)
}
}
for name, provider := range c.Providers {
......@@ -154,6 +146,9 @@ func (c *Config) Validate() error {
if provider.SendTransactionRetryTimeout == 0 {
return errors.Errorf("provider [%s] send_transaction_retry_timeout is missing", name)
}
if provider.SendTransactionCoolDown == 0 {
return errors.Errorf("provider [%s] send_transaction_cool_down is missing", name)
}
if provider.ReceiptRetrievalInterval == 0 {
return errors.Errorf("provider [%s] receipt_retrieval_interval is missing", name)
}
......
......@@ -2,6 +2,7 @@ package clients
import (
"context"
"math/big"
"time"
"github.com/ethereum-optimism/optimism/op-ufm/pkg/metrics"
......@@ -22,7 +23,7 @@ func Dial(providerName string, url string) (*InstrumentedEthClient, error) {
start := time.Now()
c, err := ethclient.Dial(url)
if err != nil {
metrics.RecordError(providerName, "ethclient.Dial")
metrics.RecordErrorDetails(providerName, "ethclient.Dial", err)
return nil, err
}
metrics.RecordRPCLatency(providerName, "ethclient", "Dial", time.Since(start))
......@@ -34,7 +35,7 @@ func (i *InstrumentedEthClient) TransactionByHash(ctx context.Context, hash comm
tx, isPending, err := i.c.TransactionByHash(ctx, hash)
if err != nil {
if !i.ignorableErrors(err) {
metrics.RecordError(i.providerName, "ethclient.TransactionByHash")
metrics.RecordErrorDetails(i.providerName, "ethclient.TransactionByHash", err)
}
return nil, false, err
}
......@@ -46,7 +47,7 @@ func (i *InstrumentedEthClient) PendingNonceAt(ctx context.Context, address stri
start := time.Now()
nonce, err := i.c.PendingNonceAt(ctx, common.HexToAddress(address))
if err != nil {
metrics.RecordError(i.providerName, "ethclient.PendingNonceAt")
metrics.RecordErrorDetails(i.providerName, "ethclient.PendingNonceAt", err)
return 0, err
}
metrics.RecordRPCLatency(i.providerName, "ethclient", "PendingNonceAt", time.Since(start))
......@@ -58,7 +59,7 @@ func (i *InstrumentedEthClient) TransactionReceipt(ctx context.Context, txHash c
receipt, err := i.c.TransactionReceipt(ctx, txHash)
if err != nil {
if !i.ignorableErrors(err) {
metrics.RecordError(i.providerName, "ethclient.TransactionReceipt")
metrics.RecordErrorDetails(i.providerName, "ethclient.TransactionReceipt", err)
}
return nil, err
}
......@@ -71,7 +72,7 @@ func (i *InstrumentedEthClient) SendTransaction(ctx context.Context, tx *types.T
err := i.c.SendTransaction(ctx, tx)
if err != nil {
if !i.ignorableErrors(err) {
metrics.RecordError(i.providerName, "ethclient.SendTransaction")
metrics.RecordErrorDetails(i.providerName, "ethclient.SendTransaction", err)
}
return err
}
......@@ -79,6 +80,39 @@ func (i *InstrumentedEthClient) SendTransaction(ctx context.Context, tx *types.T
return err
}
func (i *InstrumentedEthClient) EstimateGas(ctx context.Context, msg ethereum.CallMsg) (uint64, error) {
start := time.Now()
gas, err := i.c.EstimateGas(ctx, msg)
if err != nil {
metrics.RecordErrorDetails(i.providerName, "ethclient.EstimateGas", err)
return 0, err
}
metrics.RecordRPCLatency(i.providerName, "ethclient", "EstimateGas", time.Since(start))
return gas, err
}
func (i *InstrumentedEthClient) SuggestGasTipCap(ctx context.Context) (*big.Int, error) {
start := time.Now()
gasTipCap, err := i.c.SuggestGasTipCap(ctx)
if err != nil {
metrics.RecordErrorDetails(i.providerName, "ethclient.SuggestGasTipCap", err)
return nil, err
}
metrics.RecordRPCLatency(i.providerName, "ethclient", "SuggestGasTipCap", time.Since(start))
return gasTipCap, err
}
func (i *InstrumentedEthClient) HeaderByNumber(ctx context.Context, number *big.Int) (*types.Header, error) {
start := time.Now()
header, err := i.c.HeaderByNumber(ctx, number)
if err != nil {
metrics.RecordErrorDetails(i.providerName, "ethclient.HeaderByNumber", err)
return nil, err
}
metrics.RecordRPCLatency(i.providerName, "ethclient", "HeaderByNumber", time.Since(start))
return header, err
}
func (i *InstrumentedEthClient) ignorableErrors(err error) bool {
msg := err.Error()
// we dont use errors.Is because eth client actually uses errors.New,
......
......@@ -22,7 +22,7 @@ func NewSignerClient(providerName string, logger log.Logger, endpoint string, tl
start := time.Now()
c, err := signer.NewSignerClient(logger, endpoint, tlsConfig)
if err != nil {
metrics.RecordError(providerName, "signer.NewSignerClient")
metrics.RecordErrorDetails(providerName, "signer.NewSignerClient", err)
return nil, err
}
metrics.RecordRPCLatency(providerName, "signer", "NewSignerClient", time.Since(start))
......@@ -33,7 +33,7 @@ func (i *InstrumentedSignerClient) SignTransaction(ctx context.Context, chainId
start := time.Now()
tx, err := i.c.SignTransaction(ctx, chainId, tx)
if err != nil {
metrics.RecordError(i.providerName, "signer.SignTransaction")
metrics.RecordErrorDetails(i.providerName, "signer.SignTransaction", err)
return nil, err
}
metrics.RecordRPCLatency(i.providerName, "signer", "SignTransaction", time.Since(start))
......
......@@ -2,6 +2,7 @@ package provider
import (
"context"
"math/big"
"time"
"github.com/ethereum-optimism/optimism/op-ufm/pkg/metrics"
......@@ -21,7 +22,7 @@ import (
// RoundTrip send a new transaction to measure round trip latency
func (p *Provider) RoundTrip(ctx context.Context) {
log.Debug("roundTripLatency",
log.Debug("RoundTrip",
"provider", p.name)
client, err := iclients.Dial(p.name, p.config.URL)
......@@ -33,33 +34,38 @@ func (p *Provider) RoundTrip(ctx context.Context) {
return
}
var nonce uint64
p.txPool.M.Lock()
if p.txPool.Nonce == uint64(0) {
nonce, err = client.PendingNonceAt(ctx, p.walletConfig.Address)
if err != nil {
log.Error("cant get nounce",
"provider", p.name,
"err", err)
p.txPool.M.Unlock()
return
}
p.txPool.Nonce = nonce
} else {
p.txPool.Nonce++
nonce = p.txPool.Nonce
}
p.txPool.M.Unlock()
p.txPool.ExclusiveSend.Lock()
defer p.txPool.ExclusiveSend.Unlock()
txHash := common.Hash{}
attempt := 0
nonce := uint64(0)
// used for timeout
firstAttemptAt := time.Now()
// used for actual round trip time (disregard retry time)
roundTripStartedAt := time.Now()
var roundTripStartedAt time.Time
for {
tx := p.createTx(nonce)
txHash = tx.Hash()
// sleep until we get a clear to send
for {
coolDown := time.Duration(p.config.SendTransactionCoolDown) - time.Since(p.txPool.LastSend)
if coolDown > 0 {
time.Sleep(coolDown)
} else {
break
}
}
tx, err := p.createTx(ctx, client, nonce)
nonce = tx.Nonce()
if err != nil {
log.Error("cant create tx",
"provider", p.name,
"nonce", nonce,
"err", err)
return
}
signedTx, err := p.sign(ctx, tx)
if err != nil {
......@@ -69,7 +75,6 @@ func (p *Provider) RoundTrip(ctx context.Context) {
"err", err)
return
}
txHash = signedTx.Hash()
roundTripStartedAt = time.Now()
......@@ -78,25 +83,29 @@ func (p *Provider) RoundTrip(ctx context.Context) {
if err.Error() == txpool.ErrAlreadyKnown.Error() ||
err.Error() == txpool.ErrReplaceUnderpriced.Error() ||
err.Error() == core.ErrNonceTooLow.Error() {
log.Warn("cant send transaction (retryable)",
"provider", p.name,
"err", err,
"nonce", nonce)
if time.Since(firstAttemptAt) >= time.Duration(p.config.SendTransactionRetryTimeout) {
log.Error("send transaction timed out (known already)",
"provider", p.name,
"hash", txHash.Hex(),
"nonce", nonce,
"elapsed", time.Since(firstAttemptAt),
"attempt", attempt,
"nonce", nonce)
metrics.RecordError(p.name, "ethclient.SendTransaction.nonce")
"attempt", attempt)
metrics.RecordErrorDetails(p.name, "send.timeout", err)
return
}
log.Warn("tx already known, incrementing nonce and trying again",
"provider", p.name,
"nonce", nonce)
time.Sleep(time.Duration(p.config.SendTransactionRetryInterval))
p.txPool.M.Lock()
p.txPool.Nonce++
nonce = p.txPool.Nonce
p.txPool.M.Unlock()
nonce++
attempt++
if attempt%10 == 0 {
log.Debug("retrying send transaction...",
......@@ -108,6 +117,7 @@ func (p *Provider) RoundTrip(ctx context.Context) {
} else {
log.Error("cant send transaction",
"provider", p.name,
"nonce", nonce,
"err", err)
metrics.RecordErrorDetails(p.name, "ethclient.SendTransaction", err)
return
......@@ -131,6 +141,7 @@ func (p *Provider) RoundTrip(ctx context.Context) {
SentAt: sentAt,
SeenBy: make(map[string]time.Time),
}
p.txPool.LastSend = sentAt
p.txPool.M.Unlock()
var receipt *types.Receipt
......@@ -140,13 +151,17 @@ func (p *Provider) RoundTrip(ctx context.Context) {
log.Error("receipt retrieval timed out",
"provider", p.name,
"hash", txHash,
"nonce", nonce,
"elapsed", time.Since(sentAt))
metrics.RecordErrorDetails(p.name, "receipt.timeout", err)
return
}
time.Sleep(time.Duration(p.config.ReceiptRetrievalInterval))
if attempt%10 == 0 {
log.Debug("checking for receipt...",
"provider", p.name,
"hash", txHash,
"nonce", nonce,
"attempt", attempt,
"elapsed", time.Since(sentAt))
}
......@@ -155,6 +170,7 @@ func (p *Provider) RoundTrip(ctx context.Context) {
log.Error("cant get receipt for transaction",
"provider", p.name,
"hash", txHash.Hex(),
"nonce", nonce,
"err", err)
return
}
......@@ -168,6 +184,7 @@ func (p *Provider) RoundTrip(ctx context.Context) {
log.Info("got transaction receipt",
"hash", txHash.Hex(),
"nonce", nonce,
"roundTripLatency", roundTripLatency,
"provider", p.name,
"blockNumber", receipt.BlockNumber,
......@@ -175,20 +192,83 @@ func (p *Provider) RoundTrip(ctx context.Context) {
"gasUsed", receipt.GasUsed)
}
func (p *Provider) createTx(nonce uint64) *types.Transaction {
toAddress := common.HexToAddress(p.walletConfig.Address)
func (p *Provider) createTx(ctx context.Context, client *iclients.InstrumentedEthClient, nonce uint64) (*types.Transaction, error) {
var err error
if nonce == 0 {
nonce, err = client.PendingNonceAt(ctx, p.walletConfig.Address)
if err != nil {
log.Error("cant get nounce",
"provider", p.name,
"nonce", nonce,
"err", err)
return nil, err
}
}
gasTipCap, err := client.SuggestGasTipCap(ctx)
if err != nil {
log.Error("cant get gas tip cap",
"provider", p.name,
"err", err)
return nil, err
}
gasTipCap = new(big.Int).Mul(gasTipCap, big.NewInt(110))
gasTipCap = new(big.Int).Div(gasTipCap, big.NewInt(100))
head, err := client.HeaderByNumber(ctx, nil)
if err != nil {
log.Error("cant get base fee from head",
"provider", p.name,
"err", err)
return nil, err
}
baseFee := head.BaseFee
gasFeeCap := new(big.Int).Add(
gasTipCap,
new(big.Int).Mul(baseFee, big.NewInt(2)))
addr := common.HexToAddress(p.walletConfig.Address)
var data []byte
tx := types.NewTx(&types.DynamicFeeTx{
dynamicTx := &types.DynamicFeeTx{
ChainID: &p.walletConfig.ChainID,
Nonce: nonce,
GasFeeCap: &p.walletConfig.GasFeeCap,
GasTipCap: &p.walletConfig.GasTipCap,
Gas: p.walletConfig.GasLimit,
To: &toAddress,
GasFeeCap: gasFeeCap,
GasTipCap: gasTipCap,
To: &addr,
Value: &p.walletConfig.TxValue,
Data: data,
}
gas, err := client.EstimateGas(ctx, ethereum.CallMsg{
From: addr,
To: &addr,
GasFeeCap: gasFeeCap,
GasTipCap: gasTipCap,
Data: dynamicTx.Data,
Value: dynamicTx.Value,
})
return tx
if err != nil {
log.Error("cant estimate gas",
"provider", p.name,
"err", err)
return nil, err
}
dynamicTx.Gas = gas
tx := types.NewTx(dynamicTx)
log.Info("tx created",
"provider", p.name,
"from", addr,
"to", dynamicTx.To,
"nonce", dynamicTx.Nonce,
"value", dynamicTx.Value,
"gas", dynamicTx.Gas,
"gasTipCap", dynamicTx.GasTipCap,
"gasFeeCap", dynamicTx.GasFeeCap,
)
return tx, nil
}
func (p *Provider) sign(ctx context.Context, tx *types.Transaction) (*types.Transaction, error) {
......
......@@ -15,7 +15,11 @@ type NetworkTransactionPool struct {
M sync.Mutex
Transactions map[string]*TransactionState
Expected int
Nonce uint64
// Last time a transaction was sent
LastSend time.Time
// Prevents concurrent transaction send
ExclusiveSend sync.Mutex
}
type TransactionState struct {
......
......@@ -88,38 +88,38 @@ FaucetTest:test_nonAdmin_drip_fails() (gas: 262520)
FaucetTest:test_receive_succeeds() (gas: 17401)
FaucetTest:test_withdraw_nonAdmin_reverts() (gas: 13145)
FaucetTest:test_withdraw_succeeds() (gas: 78359)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 498906)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 505746)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 502447)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 505644)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 504933)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 497671)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 504511)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 501212)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 502409)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 501698)
FaultDisputeGame_Test:test_addLocalData_static_succeeds() (gas: 640503)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 499197)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 506057)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 502738)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 505955)
FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 505224)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 497962)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 504822)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 501503)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 502720)
FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 501989)
FaultDisputeGame_Test:test_addLocalData_static_succeeds() (gas: 640504)
FaultDisputeGame_Test:test_createdAt_succeeds() (gas: 10342)
FaultDisputeGame_Test:test_extraData_succeeds() (gas: 32377)
FaultDisputeGame_Test:test_gameData_succeeds() (gas: 32829)
FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8250)
FaultDisputeGame_Test:test_initialize_correctData_succeeds() (gas: 57650)
FaultDisputeGame_Test:test_initialize_firstOutput_reverts() (gas: 210554)
FaultDisputeGame_Test:test_initialize_l1HeadTooOld_reverts() (gas: 228337)
FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 415993)
FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 23219)
FaultDisputeGame_Test:test_move_defendRoot_reverts() (gas: 13366)
FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 102920)
FaultDisputeGame_Test:test_gameData_succeeds() (gas: 32804)
FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8309)
FaultDisputeGame_Test:test_initialize_correctData_succeeds() (gas: 57628)
FaultDisputeGame_Test:test_initialize_firstOutput_reverts() (gas: 210629)
FaultDisputeGame_Test:test_initialize_l1HeadTooOld_reverts() (gas: 228390)
FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 415971)
FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 23197)
FaultDisputeGame_Test:test_move_defendRoot_reverts() (gas: 13344)
FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 102898)
FaultDisputeGame_Test:test_move_gameDepthExceeded_reverts() (gas: 407913)
FaultDisputeGame_Test:test_move_gameNotInProgress_reverts() (gas: 11024)
FaultDisputeGame_Test:test_move_nonExistentParent_reverts() (gas: 24732)
FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 107341)
FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 224906)
FaultDisputeGame_Test:test_resolve_notInProgress_reverts() (gas: 9664)
FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 109856)
FaultDisputeGame_Test:test_move_gameNotInProgress_reverts() (gas: 11002)
FaultDisputeGame_Test:test_move_nonExistentParent_reverts() (gas: 24710)
FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 107384)
FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 224949)
FaultDisputeGame_Test:test_resolve_notInProgress_reverts() (gas: 9686)
FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 109879)
FaultDisputeGame_Test:test_resolve_rootUncontestedClockNotExpired_succeeds() (gas: 21421)
FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 27256)
FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 395635)
FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 27279)
FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 395658)
FaultDisputeGame_Test:test_rootClaim_succeeds() (gas: 8276)
FeeVault_Test:test_constructor_succeeds() (gas: 18185)
GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_0() (gas: 354286)
......@@ -298,81 +298,81 @@ LegacyERC20ETH_Test:test_transferFrom_doesNotExist_reverts() (gas: 12957)
LegacyERC20ETH_Test:test_transfer_doesNotExist_reverts() (gas: 10755)
LegacyMessagePasser_Test:test_passMessageToL1_succeeds() (gas: 34524)
LibPosition_Test:test_pos_correctness_succeeds() (gas: 38689)
MIPS_Test:test_add_succeeds() (gas: 122197)
MIPS_Test:test_addiSign_succeeds() (gas: 122188)
MIPS_Test:test_addi_succeeds() (gas: 122385)
MIPS_Test:test_addu_succeeds() (gas: 122239)
MIPS_Test:test_addui_succeeds() (gas: 122447)
MIPS_Test:test_and_succeeds() (gas: 122258)
MIPS_Test:test_andi_succeeds() (gas: 122191)
MIPS_Test:test_beq_succeeds() (gas: 202355)
MIPS_Test:test_bgez_succeeds() (gas: 121484)
MIPS_Test:test_bgtz_succeeds() (gas: 121405)
MIPS_Test:test_blez_succeeds() (gas: 121361)
MIPS_Test:test_bltz_succeeds() (gas: 121504)
MIPS_Test:test_bne_succeeds() (gas: 121570)
MIPS_Test:test_add_succeeds() (gas: 122420)
MIPS_Test:test_addiSign_succeeds() (gas: 122411)
MIPS_Test:test_addi_succeeds() (gas: 122608)
MIPS_Test:test_addu_succeeds() (gas: 122462)
MIPS_Test:test_addui_succeeds() (gas: 122670)
MIPS_Test:test_and_succeeds() (gas: 122481)
MIPS_Test:test_andi_succeeds() (gas: 122414)
MIPS_Test:test_beq_succeeds() (gas: 202801)
MIPS_Test:test_bgez_succeeds() (gas: 121707)
MIPS_Test:test_bgtz_succeeds() (gas: 121628)
MIPS_Test:test_blez_succeeds() (gas: 121584)
MIPS_Test:test_bltz_succeeds() (gas: 121727)
MIPS_Test:test_bne_succeeds() (gas: 121793)
MIPS_Test:test_branch_inDelaySlot_fails() (gas: 85999)
MIPS_Test:test_brk_succeeds() (gas: 121869)
MIPS_Test:test_clo_succeeds() (gas: 121926)
MIPS_Test:test_clone_succeeds() (gas: 121822)
MIPS_Test:test_clz_succeeds() (gas: 122397)
MIPS_Test:test_div_succeeds() (gas: 122376)
MIPS_Test:test_divu_succeeds() (gas: 122361)
MIPS_Test:test_exit_succeeds() (gas: 121746)
MIPS_Test:test_fcntl_succeeds() (gas: 203827)
MIPS_Test:test_brk_succeeds() (gas: 122092)
MIPS_Test:test_clo_succeeds() (gas: 122149)
MIPS_Test:test_clone_succeeds() (gas: 122045)
MIPS_Test:test_clz_succeeds() (gas: 122620)
MIPS_Test:test_div_succeeds() (gas: 122599)
MIPS_Test:test_divu_succeeds() (gas: 122584)
MIPS_Test:test_exit_succeeds() (gas: 122094)
MIPS_Test:test_fcntl_succeeds() (gas: 204273)
MIPS_Test:test_illegal_instruction_fails() (gas: 91462)
MIPS_Test:test_invalid_root_fails() (gas: 435636)
MIPS_Test:test_jal_nonzeroRegion_succeeds() (gas: 120514)
MIPS_Test:test_jal_succeeds() (gas: 120503)
MIPS_Test:test_jalr_succeeds() (gas: 121622)
MIPS_Test:test_jr_succeeds() (gas: 121316)
MIPS_Test:test_jal_nonzeroRegion_succeeds() (gas: 120737)
MIPS_Test:test_jal_succeeds() (gas: 120726)
MIPS_Test:test_jalr_succeeds() (gas: 121845)
MIPS_Test:test_jr_succeeds() (gas: 121539)
MIPS_Test:test_jump_inDelaySlot_fails() (gas: 85367)
MIPS_Test:test_jump_nonzeroRegion_succeeds() (gas: 120258)
MIPS_Test:test_jump_succeeds() (gas: 120188)
MIPS_Test:test_lb_succeeds() (gas: 127429)
MIPS_Test:test_lbu_succeeds() (gas: 127327)
MIPS_Test:test_lh_succeeds() (gas: 127450)
MIPS_Test:test_lhu_succeeds() (gas: 127367)
MIPS_Test:test_ll_succeeds() (gas: 127589)
MIPS_Test:test_lui_succeeds() (gas: 121470)
MIPS_Test:test_lw_succeeds() (gas: 127218)
MIPS_Test:test_lwl_succeeds() (gas: 241600)
MIPS_Test:test_lwr_succeeds() (gas: 241888)
MIPS_Test:test_mfhi_succeeds() (gas: 121831)
MIPS_Test:test_mflo_succeeds() (gas: 121960)
MIPS_Test:test_mmap_succeeds() (gas: 118789)
MIPS_Test:test_movn_succeeds() (gas: 203027)
MIPS_Test:test_movz_succeeds() (gas: 202895)
MIPS_Test:test_mthi_succeeds() (gas: 121875)
MIPS_Test:test_mtlo_succeeds() (gas: 121983)
MIPS_Test:test_mul_succeeds() (gas: 121475)
MIPS_Test:test_mult_succeeds() (gas: 122179)
MIPS_Test:test_multu_succeeds() (gas: 122216)
MIPS_Test:test_nor_succeeds() (gas: 122308)
MIPS_Test:test_or_succeeds() (gas: 122265)
MIPS_Test:test_ori_succeeds() (gas: 122268)
MIPS_Test:test_preimage_read_succeeds() (gas: 234185)
MIPS_Test:test_preimage_write_succeeds() (gas: 126811)
MIPS_Test:test_prestate_exited_succeeds() (gas: 112992)
MIPS_Test:test_sb_succeeds() (gas: 160300)
MIPS_Test:test_sc_succeeds() (gas: 160494)
MIPS_Test:test_sh_succeeds() (gas: 160337)
MIPS_Test:test_sll_succeeds() (gas: 121436)
MIPS_Test:test_sllv_succeeds() (gas: 121665)
MIPS_Test:test_slt_succeeds() (gas: 204222)
MIPS_Test:test_sltu_succeeds() (gas: 122482)
MIPS_Test:test_sra_succeeds() (gas: 121687)
MIPS_Test:test_srav_succeeds() (gas: 121955)
MIPS_Test:test_srl_succeeds() (gas: 121518)
MIPS_Test:test_srlv_succeeds() (gas: 121683)
MIPS_Test:test_step_abi_succeeds() (gas: 58312)
MIPS_Test:test_sub_succeeds() (gas: 122292)
MIPS_Test:test_subu_succeeds() (gas: 122289)
MIPS_Test:test_sw_succeeds() (gas: 160312)
MIPS_Test:test_swl_succeeds() (gas: 160373)
MIPS_Test:test_swr_succeeds() (gas: 160448)
MIPS_Test:test_xor_succeeds() (gas: 122293)
MIPS_Test:test_xori_succeeds() (gas: 122345)
MIPS_Test:test_jump_nonzeroRegion_succeeds() (gas: 120481)
MIPS_Test:test_jump_succeeds() (gas: 120411)
MIPS_Test:test_lb_succeeds() (gas: 127652)
MIPS_Test:test_lbu_succeeds() (gas: 127550)
MIPS_Test:test_lh_succeeds() (gas: 127673)
MIPS_Test:test_lhu_succeeds() (gas: 127590)
MIPS_Test:test_ll_succeeds() (gas: 127812)
MIPS_Test:test_lui_succeeds() (gas: 121693)
MIPS_Test:test_lw_succeeds() (gas: 127441)
MIPS_Test:test_lwl_succeeds() (gas: 242046)
MIPS_Test:test_lwr_succeeds() (gas: 242334)
MIPS_Test:test_mfhi_succeeds() (gas: 122054)
MIPS_Test:test_mflo_succeeds() (gas: 122183)
MIPS_Test:test_mmap_succeeds() (gas: 119012)
MIPS_Test:test_movn_succeeds() (gas: 203473)
MIPS_Test:test_movz_succeeds() (gas: 203341)
MIPS_Test:test_mthi_succeeds() (gas: 122098)
MIPS_Test:test_mtlo_succeeds() (gas: 122206)
MIPS_Test:test_mul_succeeds() (gas: 121698)
MIPS_Test:test_mult_succeeds() (gas: 122402)
MIPS_Test:test_multu_succeeds() (gas: 122439)
MIPS_Test:test_nor_succeeds() (gas: 122531)
MIPS_Test:test_or_succeeds() (gas: 122488)
MIPS_Test:test_ori_succeeds() (gas: 122491)
MIPS_Test:test_preimage_read_succeeds() (gas: 234408)
MIPS_Test:test_preimage_write_succeeds() (gas: 127034)
MIPS_Test:test_prestate_exited_succeeds() (gas: 113280)
MIPS_Test:test_sb_succeeds() (gas: 160523)
MIPS_Test:test_sc_succeeds() (gas: 160717)
MIPS_Test:test_sh_succeeds() (gas: 160560)
MIPS_Test:test_sll_succeeds() (gas: 121659)
MIPS_Test:test_sllv_succeeds() (gas: 121888)
MIPS_Test:test_slt_succeeds() (gas: 204668)
MIPS_Test:test_sltu_succeeds() (gas: 122705)
MIPS_Test:test_sra_succeeds() (gas: 121910)
MIPS_Test:test_srav_succeeds() (gas: 122178)
MIPS_Test:test_srl_succeeds() (gas: 121741)
MIPS_Test:test_srlv_succeeds() (gas: 121906)
MIPS_Test:test_step_abi_succeeds() (gas: 58417)
MIPS_Test:test_sub_succeeds() (gas: 122515)
MIPS_Test:test_subu_succeeds() (gas: 122512)
MIPS_Test:test_sw_succeeds() (gas: 160535)
MIPS_Test:test_swl_succeeds() (gas: 160596)
MIPS_Test:test_swr_succeeds() (gas: 160671)
MIPS_Test:test_xor_succeeds() (gas: 122516)
MIPS_Test:test_xori_succeeds() (gas: 122568)
MerkleTrie_get_Test:test_get_corruptedProof_reverts() (gas: 5733)
MerkleTrie_get_Test:test_get_extraProofElements_reverts() (gas: 58889)
MerkleTrie_get_Test:test_get_invalidDataRemainder_reverts() (gas: 35845)
......
......@@ -26,3 +26,6 @@ deployments/hardhat
deployments/getting-started
deployments/*/.deploy
deployments/1337
# Devnet config which changes with each 'make devnet-up'
deploy-config/devnetL1.json
......@@ -138,6 +138,9 @@ Test contracts should be named one of the following according to their use:
- `TargetContract_Function_Test` for contracts containing happy path tests for a given function.
- `TargetContract_Function_TestFail` for contracts containing sad path tests for a given function.
To minimize clutter, getter functions can be grouped together into a single test contract,
ie. `TargetContract_Getters_Test`.
## Withdrawaing From Fee Vaults
See the file `scripts/FeeVaultWithdrawal.s.sol` to withdraw from the L2 fee vaults. It includes
......
......@@ -43,7 +43,7 @@
"eip1559Elasticity": 6,
"l1GenesisBlockTimestamp": "0x64c811bf",
"l2GenesisRegolithTimeOffset": "0x0",
"faultGameAbsolutePrestate": "0x41c7ae758795765c6664a5d39bf63841c71ff191e9189522bad8ebff5d4eca98",
"faultGameAbsolutePrestate": "0x03c7ae758795765c6664a5d39bf63841c71ff191e9189522bad8ebff5d4eca98",
"faultGameMaxDepth": 30,
"faultGameMaxDuration": 1200,
"systemConfigStartBlock": 0
......
################################################################
# PROFILE: DEFAULT (Local) #
################################################################
[profile.default]
# Compilation settings
src = 'src'
out = 'forge-artifacts'
script = 'scripts'
optimizer = true
optimizer_runs = 999999
remappings = [
'@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts',
'@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts',
'@rari-capital/solmate/=lib/solmate',
"@cwia/=lib/clones-with-immutable-args/src",
'@cwia/=lib/clones-with-immutable-args/src',
'forge-std/=lib/forge-std/src',
'ds-test/=lib/forge-std/lib/ds-test/src'
]
......@@ -17,9 +22,9 @@ extra_output = ['devdoc', 'userdoc', 'metadata', 'storageLayout']
bytecode_hash = 'none'
build_info = true
build_info_path = 'artifacts/build-info'
ffi = true
fuzz_runs = 16
# Test / Script Runner Settings
ffi = true
fs_permissions = [
{ access='read-write', path='./.resource-metering.csv' },
{ access='read-write', path='./deployments/' },
......@@ -29,14 +34,19 @@ fs_permissions = [
{ access='write', path='./semver-lock.json' },
]
[fuzz]
runs = 64
[fmt]
line_length=120
multiline_func_header="all"
multiline_func_header='all'
bracket_spacing=true
wrap_comments=true
ignore = [
'src/vendor/WETH9.sol'
]
ignore = ['src/vendor/WETH9.sol']
################################################################
# PROFILE: CI #
################################################################
[profile.ci]
fuzz_runs = 512
[profile.ci.fuzz]
runs = 512
{
"src/EAS/EAS.sol": "0x00862a9f0088230acc1f5c5d0e4041bcc28cb3b3675d0eb7e1cceee7cf9502f8",
"src/EAS/SchemaRegistry.sol": "0xf1cd4415f85775124c226e1a356d8b9b5126b9e9bdbe5aebb3876d46f8e1217a",
"src/EAS/EAS.sol": "0x1acb25751a1206eb859cc5fcf934da2f84cfb907b8e8951d86fc4e43c53a7303",
"src/EAS/SchemaRegistry.sol": "0x305f3afed2e337cd70aac70fc202e6503b947b0a31e0d4e18c49486eeb635bb5",
"src/L1/L1CrossDomainMessenger.sol": "0x0e663b5d608b07cf278b94b1eeb3202abc01bea6b5905a3869010353df33ad1a",
"src/L1/L1ERC721Bridge.sol": "0xbb10b777d1cd36ef98b53df6675f37a20b14a9a82b174f0d8f8872eedca65f17",
"src/L1/L1StandardBridge.sol": "0xbd7b303cefe46bc14bf1a2b81e5702ff45ce9c5257524e59778e11c75f7f5bdc",
......@@ -16,7 +16,7 @@
"src/L2/L2StandardBridge.sol": "0xe025dcccbf21d48828ecf588941c9ba04c91b87bdd177a653d3f1b265b0b02a8",
"src/L2/L2ToL1MessagePasser.sol": "0xda56ba2e5b2c28fa8ca2df24077d49e96155a00ecc99cd0778d681be6ed166fe",
"src/L2/SequencerFeeVault.sol": "0x37816035c992d38cf7e3d5a1846b02d017dd7bdca46abe6e5c5171b9ee6225ab",
"src/dispute/FaultDisputeGame.sol": "0x72c917e8513d17f274753a391bdbddc1f4daeca1a392f79492df29a1107c3525",
"src/dispute/FaultDisputeGame.sol": "0x7b8462c29d003e96a73491c644001e1a9034bcc45c5be2a7bac3caf80d521635",
"src/legacy/DeployerWhitelist.sol": "0xf2129ec3da75307ba8e21bc943c332bb04704642e6e263149b5c8ee92dbcb7a8",
"src/legacy/L1BlockNumber.sol": "0x30aae1fc85103476af0226b6e98c71c01feebbdc35d93401390b1ad438a37be6",
"src/legacy/LegacyMessagePasser.sol": "0x5c08b0a663cc49d30e4e38540f6aefab19ef287c3ecd31c8d8c3decd5f5bd497",
......
......@@ -8,6 +8,7 @@ bytes32 constant EMPTY_UID = 0;
uint64 constant NO_EXPIRATION_TIME = 0;
error AccessDenied();
error DeadlineExpired();
error InvalidEAS();
error InvalidLength();
error InvalidSignature();
......
......@@ -80,8 +80,8 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
uint256[MAX_GAP - 3] private __gap;
/// @dev Creates a new EAS instance.
/// @custom:semver 1.1.0
constructor() Semver(1, 1, 0) EIP1271Verifier("EAS", "1.0.1") { }
/// @custom:semver 1.2.0
constructor() Semver(1, 2, 0) EIP1271Verifier("EAS", "1.2.0") { }
/// @inheritdoc IEAS
function getSchemaRegistry() external pure returns (ISchemaRegistry) {
......@@ -90,9 +90,10 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
/// @inheritdoc IEAS
function attest(AttestationRequest calldata request) external payable returns (bytes32) {
AttestationRequestData[] memory requests = new AttestationRequestData[](1);
requests[0] = request.data;
return _attest(request.schema, requests, msg.sender, msg.value, true).uids[0];
AttestationRequestData[] memory data = new AttestationRequestData[](1);
data[0] = request.data;
return _attest(request.schema, data, msg.sender, msg.value, true).uids[0];
}
/// @inheritdoc IEAS
......@@ -116,7 +117,8 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
{
// Since a multi-attest call is going to make multiple attestations for multiple schemas, we'd need to collect
// all the returned UIDs into a single list.
bytes32[][] memory totalUids = new bytes32[][](multiRequests.length);
uint256 length = multiRequests.length;
bytes32[][] memory totalUids = new bytes32[][](length);
uint256 totalUidsCount = 0;
// We are keeping track of the total available ETH amount that can be sent to resolvers and will keep deducting
......@@ -125,17 +127,23 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
// possible to send too much ETH anyway.
uint256 availableValue = msg.value;
for (uint256 i = 0; i < multiRequests.length; i = uncheckedInc(i)) {
for (uint256 i = 0; i < length; i = uncheckedInc(i)) {
// The last batch is handled slightly differently: if the total available ETH wasn't spent in full and there
// is a remainder - it will be refunded back to the attester (something that we can only verify during the
// last and final batch).
bool last;
unchecked {
last = i == multiRequests.length - 1;
last = i == length - 1;
}
// Process the current batch of attestations.
MultiAttestationRequest calldata multiRequest = multiRequests[i];
// Ensure that data isn't empty.
if (multiRequest.data.length == 0) {
revert InvalidLength();
}
AttestationsResult memory res =
_attest(multiRequest.schema, multiRequest.data, msg.sender, availableValue, last);
......@@ -161,7 +169,8 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
{
// Since a multi-attest call is going to make multiple attestations for multiple schemas, we'd need to collect
// all the returned UIDs into a single list.
bytes32[][] memory totalUids = new bytes32[][](multiDelegatedRequests.length);
uint256 length = multiDelegatedRequests.length;
bytes32[][] memory totalUids = new bytes32[][](length);
uint256 totalUidsCount = 0;
// We are keeping track of the total available ETH amount that can be sent to resolvers and will keep deducting
......@@ -170,31 +179,33 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
// possible to send too much ETH anyway.
uint256 availableValue = msg.value;
for (uint256 i = 0; i < multiDelegatedRequests.length; i = uncheckedInc(i)) {
for (uint256 i = 0; i < length; i = uncheckedInc(i)) {
// The last batch is handled slightly differently: if the total available ETH wasn't spent in full and there
// is a remainder - it will be refunded back to the attester (something that we can only verify during the
// last and final batch).
bool last;
unchecked {
last = i == multiDelegatedRequests.length - 1;
last = i == length - 1;
}
MultiDelegatedAttestationRequest calldata multiDelegatedRequest = multiDelegatedRequests[i];
AttestationRequestData[] calldata data = multiDelegatedRequest.data;
// Ensure that no inputs are missing.
if (data.length == 0 || data.length != multiDelegatedRequest.signatures.length) {
uint256 dataLength = data.length;
if (dataLength == 0 || dataLength != multiDelegatedRequest.signatures.length) {
revert InvalidLength();
}
// Verify signatures. Please note that the signatures are assumed to be signed with increasing nonces.
for (uint256 j = 0; j < data.length; j = uncheckedInc(j)) {
for (uint256 j = 0; j < dataLength; j = uncheckedInc(j)) {
_verifyAttest(
DelegatedAttestationRequest({
schema: multiDelegatedRequest.schema,
data: data[j],
signature: multiDelegatedRequest.signatures[j],
attester: multiDelegatedRequest.attester
attester: multiDelegatedRequest.attester,
deadline: multiDelegatedRequest.deadline
})
);
}
......@@ -219,10 +230,10 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
/// @inheritdoc IEAS
function revoke(RevocationRequest calldata request) external payable {
RevocationRequestData[] memory requests = new RevocationRequestData[](1);
requests[0] = request.data;
RevocationRequestData[] memory data = new RevocationRequestData[](1);
data[0] = request.data;
_revoke(request.schema, requests, msg.sender, msg.value, true);
_revoke(request.schema, data, msg.sender, msg.value, true);
}
/// @inheritdoc IEAS
......@@ -243,13 +254,14 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
// possible to send too much ETH anyway.
uint256 availableValue = msg.value;
for (uint256 i = 0; i < multiRequests.length; i = uncheckedInc(i)) {
uint256 length = multiRequests.length;
for (uint256 i = 0; i < length; i = uncheckedInc(i)) {
// The last batch is handled slightly differently: if the total available ETH wasn't spent in full and there
// is a remainder - it will be refunded back to the attester (something that we can only verify during the
// last and final batch).
bool last;
unchecked {
last = i == multiRequests.length - 1;
last = i == length - 1;
}
MultiRevocationRequest calldata multiRequest = multiRequests[i];
......@@ -270,31 +282,34 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
// possible to send too much ETH anyway.
uint256 availableValue = msg.value;
for (uint256 i = 0; i < multiDelegatedRequests.length; i = uncheckedInc(i)) {
uint256 length = multiDelegatedRequests.length;
for (uint256 i = 0; i < length; i = uncheckedInc(i)) {
// The last batch is handled slightly differently: if the total available ETH wasn't spent in full and there
// is a remainder - it will be refunded back to the attester (something that we can only verify during the
// last and final batch).
bool last;
unchecked {
last = i == multiDelegatedRequests.length - 1;
last = i == length - 1;
}
MultiDelegatedRevocationRequest memory multiDelegatedRequest = multiDelegatedRequests[i];
RevocationRequestData[] memory data = multiDelegatedRequest.data;
// Ensure that no inputs are missing.
if (data.length == 0 || data.length != multiDelegatedRequest.signatures.length) {
uint256 dataLength = data.length;
if (dataLength == 0 || dataLength != multiDelegatedRequest.signatures.length) {
revert InvalidLength();
}
// Verify signatures. Please note that the signatures are assumed to be signed with increasing nonces.
for (uint256 j = 0; j < data.length; j = uncheckedInc(j)) {
for (uint256 j = 0; j < dataLength; j = uncheckedInc(j)) {
_verifyRevoke(
DelegatedRevocationRequest({
schema: multiDelegatedRequest.schema,
data: data[j],
signature: multiDelegatedRequest.signatures[j],
revoker: multiDelegatedRequest.revoker
revoker: multiDelegatedRequest.revoker,
deadline: multiDelegatedRequest.deadline
})
);
}
......@@ -350,7 +365,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
/// @inheritdoc IEAS
function isAttestationValid(bytes32 uid) public view returns (bool) {
return _db[uid].uid != 0;
return _db[uid].uid != EMPTY_UID;
}
/// @inheritdoc IEAS
......@@ -364,14 +379,14 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
}
/// @dev Attests to a specific schema.
/// @param schema // the unique identifier of the schema to attest to.
/// @param schemaUID The unique identifier of the schema to attest to.
/// @param data The arguments of the attestation requests.
/// @param attester The attesting account.
/// @param availableValue The total available ETH amount that can be sent to the resolver.
/// @param last Whether this is the last attestations/revocations set.
/// @return The UID of the new attestations and the total sent ETH amount.
function _attest(
bytes32 schema,
bytes32 schemaUID,
AttestationRequestData[] memory data,
address attester,
uint256 availableValue,
......@@ -386,7 +401,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
res.uids = new bytes32[](length);
// Ensure that we aren't attempting to attest to a non-existing schema.
SchemaRecord memory schemaRecord = _schemaRegistry.getSchema(schema);
SchemaRecord memory schemaRecord = _schemaRegistry.getSchema(schemaUID);
if (schemaRecord.uid == EMPTY_UID) {
revert InvalidSchema();
}
......@@ -409,7 +424,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
Attestation memory attestation = Attestation({
uid: EMPTY_UID,
schema: schema,
schema: schemaUID,
refUID: request.refUID,
time: _time(),
expirationTime: request.expirationTime,
......@@ -437,7 +452,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
_db[uid] = attestation;
if (request.refUID != 0) {
if (request.refUID != EMPTY_UID) {
// Ensure that we aren't trying to attest to a non-existing referenced UID.
if (!isAttestationValid(request.refUID)) {
revert NotFound();
......@@ -449,7 +464,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
res.uids[i] = uid;
emit Attested(request.recipient, attester, uid, schema);
emit Attested(request.recipient, attester, uid, schemaUID);
}
res.usedValue = _resolveAttestations(schemaRecord, attestations, values, false, availableValue, last);
......@@ -458,14 +473,14 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
}
/// @dev Revokes an existing attestation to a specific schema.
/// @param schema The unique identifier of the schema to attest to.
/// @param schemaUID The unique identifier of the schema to attest to.
/// @param data The arguments of the revocation requests.
/// @param revoker The revoking account.
/// @param availableValue The total available ETH amount that can be sent to the resolver.
/// @param last Whether this is the last attestations/revocations set.
/// @return Returns the total sent ETH amount.
function _revoke(
bytes32 schema,
bytes32 schemaUID,
RevocationRequestData[] memory data,
address revoker,
uint256 availableValue,
......@@ -475,7 +490,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
returns (uint256)
{
// Ensure that a non-existing schema ID wasn't passed by accident.
SchemaRecord memory schemaRecord = _schemaRegistry.getSchema(schema);
SchemaRecord memory schemaRecord = _schemaRegistry.getSchema(schemaUID);
if (schemaRecord.uid == EMPTY_UID) {
revert InvalidSchema();
}
......@@ -495,7 +510,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
}
// Ensure that a wrong schema ID wasn't passed by accident.
if (attestation.schema != schema) {
if (attestation.schema != schemaUID) {
revert InvalidSchema();
}
......@@ -520,7 +535,7 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
attestations[i] = attestation;
values[i] = request.value;
emit Revoked(attestation.recipient, revoker, request.uid, attestation.schema);
emit Revoked(attestations[i].recipient, revoker, request.uid, schemaUID);
}
return _resolveAttestations(schemaRecord, attestations, values, true, availableValue, last);
......@@ -552,22 +567,28 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
revert NotPayable();
}
if (last) {
_refund(availableValue);
}
return 0;
}
// Ensure that we don't accept payments which can't be forwarded to the resolver.
if (value != 0 && !resolver.isPayable()) {
revert NotPayable();
}
if (value != 0) {
if (!resolver.isPayable()) {
revert NotPayable();
}
// Ensure that the attester/revoker doesn't try to spend more than available.
if (value > availableValue) {
revert InsufficientValue();
}
// Ensure that the attester/revoker doesn't try to spend more than available.
if (value > availableValue) {
revert InsufficientValue();
}
// Ensure to deduct the sent value explicitly.
unchecked {
availableValue -= value;
// Ensure to deduct the sent value explicitly.
unchecked {
availableValue -= value;
}
}
if (isRevocation) {
......@@ -618,16 +639,25 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
}
}
if (last) {
_refund(availableValue);
}
return 0;
}
uint256 totalUsedValue = 0;
bool isResolverPayable = resolver.isPayable();
for (uint256 i = 0; i < length; i = uncheckedInc(i)) {
uint256 value = values[i];
// Ensure that we don't accept payments which can't be forwarded to the resolver.
if (value != 0 && !resolver.isPayable()) {
if (value == 0) {
continue;
}
if (!isResolverPayable) {
revert NotPayable();
}
......@@ -702,11 +732,12 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
emit Timestamped(data, time);
}
/// @dev Timestamps the specified bytes32 data.
/// @param data The data to timestamp.
/// @param time The timestamp.
/// @dev Revokes the specified bytes32 data.
/// @param revoker The revoking account.
/// @param data The data to revoke.
/// @param time The timestamp the data was revoked with.
function _revokeOffchain(address revoker, bytes32 data, uint64 time) private {
mapping(bytes32 => uint64) storage revocations = _revocationsOffchain[revoker];
mapping(bytes32 data => uint64 timestamp) storage revocations = _revocationsOffchain[revoker];
if (revocations[data] != 0) {
revert AlreadyRevokedOffchain();
......@@ -717,13 +748,6 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
emit RevokedOffchain(revoker, data, time);
}
/// @dev Returns the current's block timestamp.
/// This method is overridden during tests and
/// used to simulate the current block time.
function _time() internal view virtual returns (uint64) {
return uint64(block.timestamp);
}
/// @dev Merges lists of UIDs.
/// @param uidLists The provided lists of UIDs.
/// @param uidsCount Total UIDs count.
......@@ -732,9 +756,11 @@ contract EAS is IEAS, Semver, EIP1271Verifier {
bytes32[] memory uids = new bytes32[](uidsCount);
uint256 currentIndex = 0;
for (uint256 i = 0; i < uidLists.length; i = uncheckedInc(i)) {
uint256 uidListLength = uidLists.length;
for (uint256 i = 0; i < uidListLength; i = uncheckedInc(i)) {
bytes32[] memory currentUids = uidLists[i];
for (uint256 j = 0; j < currentUids.length; j = uncheckedInc(j)) {
uint256 currentUidsLength = currentUids.length;
for (uint256 j = 0; j < currentUidsLength; j = uncheckedInc(j)) {
uids[currentIndex] = currentUids[j];
unchecked {
......
......@@ -27,6 +27,7 @@ struct DelegatedAttestationRequest {
AttestationRequestData data; // The arguments of the attestation request.
Signature signature; // The ECDSA signature data.
address attester; // The attesting account.
uint64 deadline; // The deadline of the signature/request.
}
/// @dev A struct representing the full arguments of the multi attestation request.
......@@ -42,6 +43,7 @@ struct MultiDelegatedAttestationRequest {
Signature[] signatures; // The ECDSA signatures data. Please note that the signatures are assumed to be signed with
// increasing nonces.
address attester; // The attesting account.
uint64 deadline; // The deadline of the signature/request.
}
/// @dev A struct representing the arguments of the revocation request.
......@@ -63,6 +65,7 @@ struct DelegatedRevocationRequest {
RevocationRequestData data; // The arguments of the revocation request.
Signature signature; // The ECDSA signature data.
address revoker; // The revoking account.
uint64 deadline; // The deadline of the signature/request.
}
/// @dev A struct representing the full arguments of the multi revocation request.
......@@ -78,6 +81,7 @@ struct MultiDelegatedRevocationRequest {
Signature[] signatures; // The ECDSA signatures data. Please note that the signatures are assumed to be signed with
// increasing nonces.
address revoker; // The revoking account.
uint64 deadline; // The deadline of the signature/request.
}
/// @title IEAS
......@@ -87,15 +91,15 @@ interface IEAS {
/// @param recipient The recipient of the attestation.
/// @param attester The attesting account.
/// @param uid The UID the revoked attestation.
/// @param schema The UID of the schema.
event Attested(address indexed recipient, address indexed attester, bytes32 uid, bytes32 indexed schema);
/// @param schemaUID The UID of the schema.
event Attested(address indexed recipient, address indexed attester, bytes32 uid, bytes32 indexed schemaUID);
/// @dev Emitted when an attestation has been revoked.
/// @param recipient The recipient of the attestation.
/// @param attester The attesting account.
/// @param schema The UID of the schema.
/// @param schemaUID The UID of the schema.
/// @param uid The UID the revoked attestation.
event Revoked(address indexed recipient, address indexed attester, bytes32 uid, bytes32 indexed schema);
event Revoked(address indexed recipient, address indexed attester, bytes32 uid, bytes32 indexed schemaUID);
/// @dev Emitted when a data has been timestamped.
/// @param data The data.
......@@ -151,7 +155,8 @@ interface IEAS {
/// r: '0x148c...b25b',
/// s: '0x5a72...be22'
/// },
/// attester: '0xc5E8740aD971409492b1A63Db8d83025e0Fc427e'
/// attester: '0xc5E8740aD971409492b1A63Db8d83025e0Fc427e',
/// deadline: 1673891048
/// })
///
/// @param delegatedRequest The arguments of the delegated attestation request.
......@@ -236,7 +241,8 @@ interface IEAS {
/// r: '0x487s...67bb',
/// s: '0x12ad...2366'
/// }],
/// attester: '0x1D86495b2A7B524D747d2839b3C645Bed32e8CF4'
/// attester: '0x1D86495b2A7B524D747d2839b3C645Bed32e8CF4',
/// deadline: 1673891048
/// }])
///
/// @param multiDelegatedRequests The arguments of the delegated multi attestation requests. The requests should be
......@@ -277,7 +283,8 @@ interface IEAS {
/// r: '0xb593...7142',
/// s: '0x0f5b...2cce'
/// },
/// revoker: '0x244934dd3e31bE2c81f84ECf0b3E6329F5381992'
/// revoker: '0x244934dd3e31bE2c81f84ECf0b3E6329F5381992',
/// deadline: 1673891048
/// })
///
/// @param delegatedRequest The arguments of the delegated revocation request.
......@@ -334,7 +341,8 @@ interface IEAS {
/// r: '0x487s...67bb',
/// s: '0x12ad...2366'
/// }],
/// revoker: '0x244934dd3e31bE2c81f84ECf0b3E6329F5381992'
/// revoker: '0x244934dd3e31bE2c81f84ECf0b3E6329F5381992',
/// deadline: 1673891048
/// }])
///
/// @param multiDelegatedRequests The arguments of the delegated multi revocation attestation requests. The requests
......
......@@ -17,7 +17,8 @@ interface ISchemaRegistry {
/// @dev Emitted when a new schema has been registered
/// @param uid The schema UID.
/// @param registerer The address of the account used to register the schema.
event Registered(bytes32 indexed uid, address registerer);
/// @param schema The schema data.
event Registered(bytes32 indexed uid, address indexed registerer, SchemaRecord schema);
/// @dev Submits and reserves a new schema
/// @param schema The schema data schema.
......
......@@ -20,8 +20,8 @@ contract SchemaRegistry is ISchemaRegistry, Semver {
uint256[MAX_GAP - 1] private __gap;
/// @dev Creates a new SchemaRegistry instance.
/// @custom:semver 1.0.3
constructor() Semver(1, 0, 3) { }
/// @custom:semver 1.2.0
constructor() Semver(1, 2, 0) { }
/// @inheritdoc ISchemaRegistry
function register(string calldata schema, ISchemaResolver resolver, bool revocable) external returns (bytes32) {
......@@ -36,7 +36,7 @@ contract SchemaRegistry is ISchemaRegistry, Semver {
schemaRecord.uid = uid;
_registry[uid] = schemaRecord;
emit Registered(uid, msg.sender);
emit Registered(uid, msg.sender, schemaRecord);
return uid;
}
......
......@@ -12,21 +12,31 @@ import {
RevocationRequestData
} from "../IEAS.sol";
import { Signature, InvalidSignature, MAX_GAP, stringToBytes32, bytes32ToString } from "../Common.sol";
import {
DeadlineExpired,
NO_EXPIRATION_TIME,
Signature,
InvalidSignature,
MAX_GAP,
stringToBytes32,
bytes32ToString
} from "../Common.sol";
/// @title EIP1271Verifier
/// @notice EIP1271Verifier typed signatures verifier for EAS delegated attestations.
abstract contract EIP1271Verifier is EIP712 {
using Address for address;
error InvalidNonce();
// The hash of the data type used to relay calls to the attest function. It's the value of
// keccak256("Attest(bytes32 schema,address recipient,uint64 expirationTime,bool revocable,bytes32 refUID,bytes
// data,uint256 nonce)").
bytes32 private constant ATTEST_TYPEHASH = 0xdbfdf8dc2b135c26253e00d5b6cbe6f20457e003fd526d97cea183883570de61;
// data,uint256 value,uint256 nonce,uint64 deadline)").
bytes32 private constant ATTEST_TYPEHASH = 0xf83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f;
// The hash of the data type used to relay calls to the revoke function. It's the value of
// keccak256("Revoke(bytes32 schema,bytes32 uid,uint256 nonce)").
bytes32 private constant REVOKE_TYPEHASH = 0xa98d02348410c9c76735e0d0bb1396f4015ac2bb9615f9c2611d19d7a8a99650;
// keccak256("Revoke(bytes32 schema,bytes32 uid,uint256 value,uint256 nonce,uint64 deadline)").
bytes32 private constant REVOKE_TYPEHASH = 0x2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c;
// The user readable name of the signing domain.
bytes32 private immutable _name;
......@@ -37,6 +47,11 @@ abstract contract EIP1271Verifier is EIP712 {
// Upgrade forward-compatibility storage gap
uint256[MAX_GAP - 1] private __gap;
/// @dev Emitted when users invalidate nonces by increasing their nonces to (higher) new values.
/// @param oldNonce The previous nonce.
/// @param newNonce The new value.
event NonceIncreased(uint256 oldNonce, uint256 newNonce);
/// @dev Creates a new EIP1271Verifier instance.
/// @param version The current major version of the signing domain
constructor(string memory name, string memory version) EIP712(name, version) {
......@@ -74,17 +89,29 @@ abstract contract EIP1271Verifier is EIP712 {
return bytes32ToString(_name);
}
/// @notice Provides users an option to invalidate nonces by increasing their nonces to (higher) new values.
/// @param newNonce The (higher) new value.
function increaseNonce(uint256 newNonce) external {
uint256 oldNonce = _nonces[msg.sender];
if (newNonce <= oldNonce) {
revert InvalidNonce();
}
_nonces[msg.sender] = newNonce;
emit NonceIncreased({ oldNonce: oldNonce, newNonce: newNonce });
}
/// @notice Verifies delegated attestation request.
/// @param request The arguments of the delegated attestation request.
function _verifyAttest(DelegatedAttestationRequest memory request) internal {
if (request.deadline != NO_EXPIRATION_TIME && request.deadline < _time()) {
revert DeadlineExpired();
}
AttestationRequestData memory data = request.data;
Signature memory signature = request.signature;
uint256 nonce;
unchecked {
nonce = _nonces[request.attester]++;
}
bytes32 hash = _hashTypedDataV4(
keccak256(
abi.encode(
......@@ -95,7 +122,9 @@ abstract contract EIP1271Verifier is EIP712 {
data.revocable,
data.refUID,
keccak256(data.data),
nonce
data.value,
_nonces[request.attester]++,
request.deadline
)
)
);
......@@ -111,15 +140,20 @@ abstract contract EIP1271Verifier is EIP712 {
/// @notice Verifies delegated revocation request.
/// @param request The arguments of the delegated revocation request.
function _verifyRevoke(DelegatedRevocationRequest memory request) internal {
if (request.deadline != NO_EXPIRATION_TIME && request.deadline < _time()) {
revert DeadlineExpired();
}
RevocationRequestData memory data = request.data;
Signature memory signature = request.signature;
uint256 nonce;
unchecked {
nonce = _nonces[request.revoker]++;
}
bytes32 hash = _hashTypedDataV4(keccak256(abi.encode(REVOKE_TYPEHASH, request.schema, data.uid, nonce)));
bytes32 hash = _hashTypedDataV4(
keccak256(
abi.encode(
REVOKE_TYPEHASH, request.schema, data.uid, data.value, _nonces[request.revoker]++, request.deadline
)
)
);
if (
!SignatureChecker.isValidSignatureNow(
request.revoker, hash, abi.encodePacked(signature.r, signature.s, signature.v)
......@@ -128,4 +162,10 @@ abstract contract EIP1271Verifier is EIP712 {
revert InvalidSignature();
}
}
/// @dev Returns the current's block timestamp. This method is overridden during tests and used to simulate the
/// current block time.
function _time() internal view virtual returns (uint64) {
return uint64(block.timestamp);
}
}
......@@ -6,7 +6,7 @@ import { Attestation } from "../Common.sol";
/// @title ISchemaResolver
/// @notice The interface of an optional schema resolver.
interface ISchemaResolver {
/// @notice Checks if the resolve can be sent ETH.
/// @notice Checks if the resolver can be sent ETH.
/// @return Whether the resolver supports ETH transfers.
function isPayable() external pure returns (bool);
......
......@@ -4,14 +4,13 @@ pragma solidity 0.8.19;
import { Semver } from "../../universal/Semver.sol";
import { IEAS, Attestation } from "../IEAS.sol";
import { InvalidEAS, uncheckedInc } from "../Common.sol";
import { AccessDenied, InvalidEAS, InvalidLength, uncheckedInc } from "../Common.sol";
import { ISchemaResolver } from "./ISchemaResolver.sol";
/// @title SchemaResolver
/// @notice The base schema resolver contract.
abstract contract SchemaResolver is ISchemaResolver, Semver {
error AccessDenied();
error InsufficientValue();
error NotPayable();
......@@ -20,7 +19,7 @@ abstract contract SchemaResolver is ISchemaResolver, Semver {
/// @dev Creates a new resolver.
/// @param eas The address of the global EAS contract.
constructor(IEAS eas) Semver(1, 0, 1) {
constructor(IEAS eas) Semver(1, 2, 0) {
if (address(eas) == address(0)) {
revert InvalidEAS();
}
......@@ -63,6 +62,9 @@ abstract contract SchemaResolver is ISchemaResolver, Semver {
returns (bool)
{
uint256 length = attestations.length;
if (length != values.length) {
revert InvalidLength();
}
// We are keeping track of the remaining ETH amount that can be sent to resolvers and will keep deducting
// from it to verify that there isn't any attempt to send too much ETH to resolvers. Please note that unless
......@@ -77,7 +79,7 @@ abstract contract SchemaResolver is ISchemaResolver, Semver {
revert InsufficientValue();
}
// Forward the attestation to the underlying resolver and revert in case it isn't approved.
// Forward the attestation to the underlying resolver and return false in case it isn't approved.
if (!onAttest(attestations[i], value)) {
return false;
}
......@@ -107,6 +109,9 @@ abstract contract SchemaResolver is ISchemaResolver, Semver {
returns (bool)
{
uint256 length = attestations.length;
if (length != values.length) {
revert InvalidLength();
}
// We are keeping track of the remaining ETH amount that can be sent to resolvers and will keep deducting
// from it to verify that there isn't any attempt to send too much ETH to resolvers. Please note that unless
......@@ -121,7 +126,7 @@ abstract contract SchemaResolver is ISchemaResolver, Semver {
revert InsufficientValue();
}
// Forward the revocation to the underlying resolver and revert in case it isn't approved.
// Forward the revocation to the underlying resolver and return false in case it isn't approved.
if (!onRevoke(attestations[i], value)) {
return false;
}
......
......@@ -103,7 +103,9 @@ contract MIPS {
from, to := copyMem(from, to, 4) // lo
from, to := copyMem(from, to, 4) // hi
from, to := copyMem(from, to, 4) // heap
let exitCode := mload(from)
from, to := copyMem(from, to, 1) // exitCode
let exited := mload(from)
from, to := copyMem(from, to, 1) // exited
from, to := copyMem(from, to, 8) // step
from := add(from, 32) // offset to registers
......@@ -117,8 +119,24 @@ contract MIPS {
// Log the resulting MIPS state, for debugging
log0(start, sub(to, start))
// Compute the hash of the resulting MIPS state
// Determine the VM status
let status := 0
switch exited
case 1 {
switch exitCode
// VMStatusValid
case 0 { status := 0 }
// VMStatusInvalid
case 1 { status := 1 }
// VMStatusPanic
default { status := 2 }
}
// VMStatusUnfinished
default { status := 3 }
// Compute the hash of the resulting MIPS state and set the status byte
out_ := keccak256(start, sub(to, start))
out_ := or(and(not(shl(248, 0xFF)), out_), shl(248, status))
}
}
......
......@@ -85,7 +85,7 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver {
/// @param _blockOracle The block oracle, used for loading block hashes further back
/// than the `BLOCKHASH` opcode allows as well as their estimated
/// timestamps.
/// @custom:semver 0.0.7
/// @custom:semver 0.0.9
constructor(
GameType _gameType,
Claim _absolutePrestate,
......@@ -95,7 +95,7 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver {
L2OutputOracle _l2oo,
BlockOracle _blockOracle
)
Semver(0, 0, 8)
Semver(0, 0, 9)
{
GAME_TYPE = _gameType;
ABSOLUTE_PRESTATE = _absolutePrestate;
......@@ -149,7 +149,11 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver {
// INVARIANT: The prestate is always invalid if the passed `_stateData` is not the
// preimage of the prestate claim hash.
if (keccak256(_stateData) != Claim.unwrap(preStateClaim)) revert InvalidPrestate();
// We ignore the highest order byte of the digest because it is used to
// indicate the VM Status and is added after the digest is computed.
if (keccak256(_stateData) << 8 != Claim.unwrap(preStateClaim) << 8) {
revert InvalidPrestate();
}
// INVARIANT: If a step is an attack, the poststate is valid if the step produces
// the same poststate hash as the parent claim's value.
......@@ -434,9 +438,18 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver {
function initialize() external {
// SAFETY: Any revert in this function will bubble up to the DisputeGameFactory and
// prevent the game from being created.
//
// Implicit assumptions:
// - The `gameStatus` state variable defaults to 0, which is `GameStatus.IN_PROGRESS`
// The VMStatus must indicate (1) 'invalid', to argue that disputed thing is invalid.
// Games that agree with the existing outcome are not allowed.
// NOTE(clabby): This assumption will change in Alpha Chad.
uint8 vmStatus = uint8(Claim.unwrap(rootClaim())[0]);
if (!(vmStatus == VMStatus.unwrap(VMStatuses.INVALID) || vmStatus == VMStatus.unwrap(VMStatuses.PANIC))) {
revert UnexpectedRootClaim(rootClaim());
}
// Set the game's starting timestamp
createdAt = Timestamp.wrap(uint64(block.timestamp));
......
......@@ -15,6 +15,11 @@ error NoImplementation(GameType gameType);
/// @param uuid The UUID of the dispute game that already exists.
error GameAlreadyExists(Hash uuid);
/// @notice Thrown when the root claim has an unexpected VM status.
/// Some games can only start with a root-claim with a specific status.
/// @param rootClaim is the claim that was unexpected.
error UnexpectedRootClaim(Claim rootClaim);
////////////////////////////////////////////////////////////////
// `FaultDisputeGame` Errors //
////////////////////////////////////////////////////////////////
......
......@@ -62,6 +62,9 @@ type Position is uint128;
/// @notice A `GameType` represents the type of game being played.
type GameType is uint8;
/// @notice A `VMStatus` represents the status of a VM execution.
type VMStatus is uint8;
/// @notice The current status of the dispute game.
enum GameStatus
// The game is currently in progress, and has not been resolved.
......@@ -85,3 +88,18 @@ library GameTypes {
/// @dev The game will use a `IDisputeGame` implementation that utilizes attestation proofs.
GameType internal constant ATTESTATION = GameType.wrap(2);
}
/// @title VMStatuses
library VMStatuses {
/// @dev The VM has executed successfully and the outcome is valid.
VMStatus internal constant VALID = VMStatus.wrap(0);
/// @dev The VM has executed successfully and the outcome is invalid.
VMStatus internal constant INVALID = VMStatus.wrap(1);
/// @dev The VM has paniced.
VMStatus internal constant PANIC = VMStatus.wrap(2);
/// @dev The VM execution is still in progress.
VMStatus internal constant UNFINISHED = VMStatus.wrap(3);
}
......@@ -41,6 +41,8 @@ contract DisputeGameFactory_Create_Test is DisputeGameFactory_Init {
function testFuzz_create_succeeds(uint8 gameType, Claim rootClaim, bytes calldata extraData) public {
// Ensure that the `gameType` is within the bounds of the `GameType` enum's possible values.
GameType gt = GameType.wrap(uint8(bound(gameType, 0, 2)));
// Ensure the rootClaim has a VMStatus that disagrees with the validity.
rootClaim = changeClaimStatus(rootClaim, VMStatuses.INVALID);
// Set all three implementations to the same `FakeClone` contract.
for (uint8 i; i < 3; i++) {
......@@ -68,6 +70,8 @@ contract DisputeGameFactory_Create_Test is DisputeGameFactory_Init {
function testFuzz_create_noImpl_reverts(uint8 gameType, Claim rootClaim, bytes calldata extraData) public {
// Ensure that the `gameType` is within the bounds of the `GameType` enum's possible values.
GameType gt = GameType.wrap(uint8(bound(gameType, 0, 2)));
// Ensure the rootClaim has a VMStatus that disagrees with the validity.
rootClaim = changeClaimStatus(rootClaim, VMStatuses.INVALID);
vm.expectRevert(abi.encodeWithSelector(NoImplementation.selector, gt));
factory.create(gt, rootClaim, extraData);
......@@ -77,6 +81,8 @@ contract DisputeGameFactory_Create_Test is DisputeGameFactory_Init {
function testFuzz_create_sameUUID_reverts(uint8 gameType, Claim rootClaim, bytes calldata extraData) public {
// Ensure that the `gameType` is within the bounds of the `GameType` enum's possible values.
GameType gt = GameType.wrap(uint8(bound(gameType, 0, 2)));
// Ensure the rootClaim has a VMStatus that disagrees with the validity.
rootClaim = changeClaimStatus(rootClaim, VMStatuses.INVALID);
// Set all three implementations to the same `FakeClone` contract.
for (uint8 i; i < 3; i++) {
......@@ -99,6 +105,12 @@ contract DisputeGameFactory_Create_Test is DisputeGameFactory_Init {
);
factory.create(gt, rootClaim, extraData);
}
function changeClaimStatus(Claim _claim, VMStatus _status) public pure returns (Claim out_) {
assembly {
out_ := or(and(not(shl(248, 0xFF)), _claim), shl(248, _status))
}
}
}
contract DisputeGameFactory_SetImplementation_Test is DisputeGameFactory_Init {
......
......@@ -77,9 +77,9 @@ contract FaultDisputeGame_Init is DisputeGameFactory_Init {
contract FaultDisputeGame_Test is FaultDisputeGame_Init {
/// @dev The root claim of the game.
Claim internal constant ROOT_CLAIM = Claim.wrap(bytes32(uint256(10)));
Claim internal constant ROOT_CLAIM = Claim.wrap(bytes32((uint256(1) << 248) | uint256(10)));
/// @dev The absolute prestate of the trace.
Claim internal constant ABSOLUTE_PRESTATE = Claim.wrap(bytes32(uint256(0)));
Claim internal constant ABSOLUTE_PRESTATE = Claim.wrap(bytes32((uint256(3) << 248) | uint256(0)));
function setUp() public override {
super.init(ROOT_CLAIM, ABSOLUTE_PRESTATE);
......@@ -143,6 +143,17 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init {
factory.create(GAME_TYPE, ROOT_CLAIM, abi.encode(1800, block.number - 1));
}
/// @dev Tests that the `create` function reverts when the rootClaim does not disagree with the outcome.
function testFuzz_initialize_badRootStatus_reverts(Claim rootClaim, bytes calldata extraData) public {
// Ensure that the `gameType` is within the bounds of the `GameType` enum's possible values.
// Ensure the root claim does not have the correct VM status
uint8 vmStatus = uint8(Claim.unwrap(rootClaim)[0]);
if (vmStatus == 1 || vmStatus == 2) rootClaim = changeClaimStatus(rootClaim, VMStatuses.VALID);
vm.expectRevert(abi.encodeWithSelector(UnexpectedRootClaim.selector, rootClaim));
factory.create(GameTypes.FAULT, rootClaim, extraData);
}
/// @dev Tests that the game is initialized with the correct data.
function test_initialize_correctData_succeeds() public {
// Starting
......@@ -449,6 +460,12 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init {
bytes32 h = keccak256(abi.encode(_ident | (1 << 248), address(gameProxy)));
return bytes32((uint256(h) & ~uint256(0xFF << 248)) | (1 << 248));
}
function changeClaimStatus(Claim _claim, VMStatus _status) public pure returns (Claim out_) {
assembly {
out_ := or(and(not(shl(248, 0xFF)), _claim), shl(248, _status))
}
}
}
/// @notice A generic game player actor with a configurable trace.
......@@ -593,9 +610,11 @@ contract GamePlayer {
/// @notice Returns the player's claim that commits to a given trace index.
function claimAt(uint256 _traceIndex) public view returns (Claim claim_) {
return Claim.wrap(
keccak256(abi.encode(_traceIndex >= trace.length ? trace.length - 1 : _traceIndex, traceAt(_traceIndex)))
);
bytes32 hash =
keccak256(abi.encode(_traceIndex >= trace.length ? trace.length - 1 : _traceIndex, traceAt(_traceIndex)));
assembly {
claim_ := or(and(hash, not(shl(248, 0xFF))), shl(248, 1))
}
}
/// @notice Returns the player's claim that commits to a given trace index.
......@@ -608,14 +627,15 @@ contract OneVsOne_Arena is FaultDisputeGame_Init {
/// @dev The absolute prestate of the trace.
bytes ABSOLUTE_PRESTATE = abi.encode(15);
/// @dev The absolute prestate claim.
Claim internal constant ABSOLUTE_PRESTATE_CLAIM = Claim.wrap(keccak256(abi.encode(15)));
Claim internal constant ABSOLUTE_PRESTATE_CLAIM =
Claim.wrap(bytes32((uint256(3) << 248) | (~uint256(0xFF << 248) & uint256(keccak256(abi.encode(15))))));
/// @dev The defender.
GamePlayer internal defender;
/// @dev The challenger.
GamePlayer internal challenger;
function init(GamePlayer _defender, GamePlayer _challenger, uint256 _finalTraceIndex) public {
Claim rootClaim = Claim.wrap(keccak256(abi.encode(_finalTraceIndex, _defender.traceAt(_finalTraceIndex))));
Claim rootClaim = _defender.claimAt(_finalTraceIndex);
super.init(rootClaim, ABSOLUTE_PRESTATE_CLAIM);
defender = _defender;
challenger = _challenger;
......@@ -874,7 +894,6 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRootFuzz is OneVsOne_Arena
contract FaultDisputeGame_ResolvesCorrectly_CorrectRootFuzz is OneVsOne_Arena {
function testFuzz_resolvesCorrectly_succeeds(uint256 _dishonestTraceLength) public {
_dishonestTraceLength = bound(_dishonestTraceLength, 1, 16);
for (uint256 i = 0; i < _dishonestTraceLength; i++) {
uint256 snapshot = vm.snapshot();
......@@ -968,7 +987,7 @@ contract AlphabetVM is IBigStepper {
function step(bytes calldata _stateData, bytes calldata) external view returns (bytes32 postState_) {
uint256 traceIndex;
uint256 claim;
if (keccak256(_stateData) == Claim.unwrap(ABSOLUTE_PRESTATE)) {
if ((keccak256(_stateData) << 8) == (Claim.unwrap(ABSOLUTE_PRESTATE) << 8)) {
// If the state data is empty, then the absolute prestate is the claim.
traceIndex = 0;
(claim) = abi.decode(_stateData, (uint256));
......@@ -979,5 +998,8 @@ contract AlphabetVM is IBigStepper {
}
// STF: n -> n + 1
postState_ = keccak256(abi.encode(traceIndex, claim + 1));
assembly {
postState_ := or(and(postState_, not(shl(248, 0xFF))), shl(248, 1))
}
}
}
......@@ -4,6 +4,7 @@ pragma solidity 0.8.15;
import { CommonTest } from "./CommonTest.t.sol";
import { MIPS } from "src/cannon/MIPS.sol";
import { PreimageOracle } from "src/cannon/PreimageOracle.sol";
import "src/libraries/DisputeTypes.sol";
contract MIPS_Test is CommonTest {
MIPS internal mips;
......@@ -1553,10 +1554,29 @@ contract MIPS_Test is CommonTest {
);
}
/// @dev MIPS VM status codes:
/// 0. Exited with success (Valid)
/// 1. Exited with success (Invalid)
/// 2. Exited with failure (Panic)
/// 3. Unfinished
function vmStatus(MIPS.State memory state) internal pure returns (VMStatus out_) {
if (!state.exited) {
return VMStatuses.UNFINISHED;
} else if (state.exitCode == 0) {
return VMStatuses.VALID;
} else if (state.exitCode == 1) {
return VMStatuses.INVALID;
} else {
return VMStatuses.PANIC;
}
}
function outputState(MIPS.State memory state) internal pure returns (bytes32 out_) {
bytes memory enc = encodeState(state);
VMStatus status = vmStatus(state);
assembly {
out_ := keccak256(add(enc, 0x20), 226)
out_ := or(and(not(shl(248, 0xFF)), out_), shl(248, status))
}
}
......
......@@ -23,7 +23,7 @@ importers:
version: 0.4.8
'@nrwl/nx-cloud':
specifier: latest
version: 16.3.0
version: 16.4.0
'@types/chai':
specifier: ^4.2.18
version: 4.2.21
......@@ -103,14 +103,14 @@ importers:
specifier: 0.4.0
version: 0.4.0
mkdirp:
specifier: ^1.0.4
version: 1.0.4
specifier: ^3.0.1
version: 3.0.1
mocha:
specifier: ^10.2.0
version: 10.2.0
nx:
specifier: 16.7.3
version: 16.7.3
specifier: 16.8.1
version: 16.8.1
nyc:
specifier: ^15.1.0
version: 15.1.0
......@@ -184,7 +184,7 @@ importers:
version: 2.9.6(chai@4.3.7)
ts-node:
specifier: ^10.9.1
version: 10.9.1(@types/node@20.5.3)(typescript@5.1.6)
version: 10.9.1(@types/node@20.5.3)(typescript@5.2.2)
tsx:
specifier: ^3.12.7
version: 3.12.7
......@@ -575,6 +575,12 @@ importers:
specifier: ^3.22.0
version: 3.22.0
ufm-test-services/metamask:
devDependencies:
typescript:
specifier: ^5.1.6
version: 5.1.6
packages:
/@aashutoshrathi/word-wrap@1.2.6:
......@@ -1690,6 +1696,32 @@ packages:
- typescript
dev: true
/@ethereum-waffle/compiler@4.0.3(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(solc@0.8.15)(typechain@8.3.1)(typescript@5.2.2):
resolution: {integrity: sha512-5x5U52tSvEVJS6dpCeXXKvRKyf8GICDwiTwUvGD3/WD+DpvgvaoHOL82XqpTSUHgV3bBq6ma5/8gKUJUIAnJCw==}
engines: {node: '>=10.0'}
peerDependencies:
ethers: '*'
solc: '*'
typechain: ^8.0.0
dependencies:
'@resolver-engine/imports': 0.3.3
'@resolver-engine/imports-fs': 0.3.3
'@typechain/ethers-v5': 10.2.1(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@8.3.1)(typescript@5.2.2)
'@types/mkdirp': 0.5.2
'@types/node-fetch': 2.6.4
ethers: 5.7.2
mkdirp: 0.5.6
node-fetch: 2.6.12
solc: 0.8.15
typechain: 8.3.1(typescript@5.2.2)
transitivePeerDependencies:
- '@ethersproject/abi'
- '@ethersproject/providers'
- encoding
- supports-color
- typescript
dev: true
/@ethereum-waffle/ens@4.0.3(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@5.7.2):
resolution: {integrity: sha512-PVLcdnTbaTfCrfSOrvtlA9Fih73EeDvFS28JQnT5M5P4JMplqmchhcZB1yg/fCtx4cvgHlZXa0+rOCAk2Jk0Jw==}
engines: {node: '>=10.0'}
......@@ -2334,7 +2366,7 @@ packages:
dependencies:
'@lerna/child-process': 7.1.5
'@npmcli/run-script': 6.0.2
'@nx/devkit': 16.7.1(nx@16.7.3)
'@nx/devkit': 16.7.1(nx@16.8.1)
'@octokit/plugin-enterprise-rest': 6.0.1
'@octokit/rest': 19.0.11
byte-size: 8.1.1
......@@ -2370,7 +2402,7 @@ packages:
npm-packlist: 5.1.1
npm-registry-fetch: 14.0.5
npmlog: 6.0.2
nx: 16.7.3
nx: 16.8.1
p-map: 4.0.0
p-map-series: 2.1.0
p-queue: 6.6.2
......@@ -2534,6 +2566,10 @@ packages:
resolution: {integrity: sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==}
engines: {node: '>= 16'}
/@noble/hashes@1.3.2:
resolution: {integrity: sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ==}
engines: {node: '>= 16'}
/@nodelib/fs.scandir@2.1.5:
resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==}
engines: {node: '>= 8'}
......@@ -2599,7 +2635,7 @@ packages:
dependencies:
'@nomiclabs/hardhat-ethers': 2.0.6(ethers@5.7.2)(hardhat@2.9.6)
'@types/sinon-chai': 3.2.5
ethereum-waffle: 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typescript@5.1.6)
ethereum-waffle: 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typescript@5.2.2)
ethers: 5.7.2
hardhat: 2.9.6(chai@4.3.7)
dev: true
......@@ -2661,27 +2697,27 @@ packages:
- supports-color
dev: true
/@nrwl/devkit@16.7.1(nx@16.7.3):
/@nrwl/devkit@16.7.1(nx@16.8.1):
resolution: {integrity: sha512-ysAgNju6o7QjG/ZHW0wIRJ8yWxjhErjqQ8GZ2Smqsb1myrr6UbYsuxaXjoOHI56fMmGyNPK04zzyNXXWQw/UAA==}
dependencies:
'@nx/devkit': 16.7.1(nx@16.7.3)
'@nx/devkit': 16.7.1(nx@16.8.1)
transitivePeerDependencies:
- nx
dev: true
/@nrwl/nx-cloud@16.3.0:
resolution: {integrity: sha512-nJrGsVufhY74KcP7kM7BqFOGAoO5OEF6+wfiM295DgmEG9c1yW+x5QiQaC42K9SWYn/eKQa1X7466ZA5lynXoQ==}
/@nrwl/nx-cloud@16.4.0:
resolution: {integrity: sha512-QitrYK6z9ceagetBlgLMZnC0T85k2JTk+oK0MxZ5p/woclqeYN7SiGNZgMzDq8TjJwt8Fm/MDnsSo3xtufmLBg==}
dependencies:
nx-cloud: 16.3.0
nx-cloud: 16.4.0
transitivePeerDependencies:
- debug
dev: true
/@nrwl/tao@16.7.3:
resolution: {integrity: sha512-kaH0i7ZuncSW8hGXg6DVlUBG319lUG/ene6aJUeV1spOxEsEqlckCm9HfJPfcVntvh9m1LauW+yk64cw/biVwg==}
/@nrwl/tao@16.8.1:
resolution: {integrity: sha512-hgGFLyEgONSofxnJsXN9NlUx4J8/YSLUkfZKdR8Qa97+JGZT8FEuk7NLFJOWdYYqROoCzXLHK0d+twFFNPS5BQ==}
hasBin: true
dependencies:
nx: 16.7.3
nx: 16.8.1
tslib: 2.6.0
transitivePeerDependencies:
- '@swc-node/register'
......@@ -2689,23 +2725,23 @@ packages:
- debug
dev: true
/@nx/devkit@16.7.1(nx@16.7.3):
/@nx/devkit@16.7.1(nx@16.8.1):
resolution: {integrity: sha512-PASQGd1YhcAA/hpupCsSakP71Qh1pYle4dtF+wh3KDe2kdeM6BgccClapiGcXAI46JKLUGAbNYJ8pg7GEPY5Nw==}
peerDependencies:
nx: '>= 15 <= 17'
dependencies:
'@nrwl/devkit': 16.7.1(nx@16.7.3)
'@nrwl/devkit': 16.7.1(nx@16.8.1)
ejs: 3.1.9
enquirer: 2.3.6
ignore: 5.2.4
nx: 16.7.3
nx: 16.8.1
semver: 7.5.3
tmp: 0.2.1
tslib: 2.6.0
dev: true
/@nx/nx-darwin-arm64@16.7.3:
resolution: {integrity: sha512-s1woGSGbNEzDSzNoSIIpaYkVwJmM0D89/1QmccVZIv7jvGGcqx4ONQPsBylWpDco3IeTDhNsOMzMhF3fvqhtgA==}
/@nx/nx-darwin-arm64@16.8.1:
resolution: {integrity: sha512-xOflqyIVcyLPzdJOZcucI+5ClwnTgK8zIvpjbxHokrO9McJJglhfUyP0bbTHpEpWqzA+GaPA/6/Qdu0ATzqQBQ==}
engines: {node: '>= 10'}
cpu: [arm64]
os: [darwin]
......@@ -2713,8 +2749,8 @@ packages:
dev: true
optional: true
/@nx/nx-darwin-x64@16.7.3:
resolution: {integrity: sha512-J9lE+T7Hm3hD+s33xidxa6Jkq2CCKZwwTrLO+Ff1/A2d4T13d16O/Rf3Y/nuveUjCVEYwwYkk4G5v2FPJ4i3SQ==}
/@nx/nx-darwin-x64@16.8.1:
resolution: {integrity: sha512-JJGrlOvEpDMWnM6YKaA1WOnzHgiw5vRKEowX9ba+jxhmCvtdjbLSxi228kv92JtQPPQ91zvtsNM+BFY0EbPOlA==}
engines: {node: '>= 10'}
cpu: [x64]
os: [darwin]
......@@ -2722,8 +2758,8 @@ packages:
dev: true
optional: true
/@nx/nx-freebsd-x64@16.7.3:
resolution: {integrity: sha512-/1WrplEyxTkoARsCUcI2FjMVy2AFuaH2oS1vFuGtBchWoKbgFZd3Aek8+oYt0wiQ7cfBxs2y92UqvTOhLygxOw==}
/@nx/nx-freebsd-x64@16.8.1:
resolution: {integrity: sha512-aZdJQ7cIQfXOmfk4vRXvVYxuV68xz8YyhNZ0IvBfJ16uZQ+YNl4BpklRLEIdaloSbwz9M1NNewmL+AgklEBxlA==}
engines: {node: '>= 10'}
cpu: [x64]
os: [freebsd]
......@@ -2731,8 +2767,8 @@ packages:
dev: true
optional: true
/@nx/nx-linux-arm-gnueabihf@16.7.3:
resolution: {integrity: sha512-Z3CLZcxBnpra8nlizK97eyohI9x+JPh4wp+87x9WvIiLGd+k3hO42nth/q0xXJs2G5emQN8cSLPscGzbZodVpA==}
/@nx/nx-linux-arm-gnueabihf@16.8.1:
resolution: {integrity: sha512-JzjrTf7FFgikoVUbRs0hKvwHRR6SyqT4yIdk/YyiCt2mWY9w4m5DWtHM/9kJzhckkH9MY66m+X/zG6+NKsEMvg==}
engines: {node: '>= 10'}
cpu: [arm]
os: [linux]
......@@ -2740,8 +2776,8 @@ packages:
dev: true
optional: true
/@nx/nx-linux-arm64-gnu@16.7.3:
resolution: {integrity: sha512-a4E4psBgU0b7ZT99630mylxcrlLObgy4bA6JrT+4XIFAcaHkfCmWLupPyXgBCmSqQN01jsuXSYm/t7EWjKL98Q==}
/@nx/nx-linux-arm64-gnu@16.8.1:
resolution: {integrity: sha512-CF0s981myBWusW7iW2+fKPa7ceYYe+NO5EdKe9l27fpHDkcA71KZU3q7U823QpO/7tYvVdBevJp3CCn2/GBURQ==}
engines: {node: '>= 10'}
cpu: [arm64]
os: [linux]
......@@ -2749,8 +2785,8 @@ packages:
dev: true
optional: true
/@nx/nx-linux-arm64-musl@16.7.3:
resolution: {integrity: sha512-vl+WONX6uOS8uGwtcAlb4yiAh2ws/gZSLaIURJaDnf509FrYTb/RsBca5BskOQUYkKSI//6oQu653TRDKYxyWw==}
/@nx/nx-linux-arm64-musl@16.8.1:
resolution: {integrity: sha512-X4TobxRt1dALvoeKC3/t1CqZCMUqtEhGG+KQLT/51sG54HdxmTAWRFlvj8PvLH0QSBk4e+uRZAo45qpt3iSnBg==}
engines: {node: '>= 10'}
cpu: [arm64]
os: [linux]
......@@ -2758,8 +2794,8 @@ packages:
dev: true
optional: true
/@nx/nx-linux-x64-gnu@16.7.3:
resolution: {integrity: sha512-udZ+6IOYv0Ra0MRpbAW8TSFdcUxtfuIryRsGVF2767HeWqHzOhLynmJyJPatJ7gXMVFaL7+zfcAoV6fm7My1FQ==}
/@nx/nx-linux-x64-gnu@16.8.1:
resolution: {integrity: sha512-lHvv2FD14Lpxh7muMLStH2tC1opQOaepO4nXwb1LaaoIpMym7kBgCK8AQuI98/oNQiMDXMNDKWQZCjxnJGDIPw==}
engines: {node: '>= 10'}
cpu: [x64]
os: [linux]
......@@ -2767,8 +2803,8 @@ packages:
dev: true
optional: true
/@nx/nx-linux-x64-musl@16.7.3:
resolution: {integrity: sha512-LQW1ttQWNekHoJTrzXMumaMxfYRcjsuGQP8Ki2pWuw43TFTQyI6Cfgk8/wjKv8ATc772cF9Tadyz4+JEIQlcNw==}
/@nx/nx-linux-x64-musl@16.8.1:
resolution: {integrity: sha512-c4gQvNgIjggD1A5sYhftQEC1PtAhV3sEnv60X00v9wmjl57Wj4Ty0TgyzpYglLysVRiko/B58S8NYS0jKvMmeA==}
engines: {node: '>= 10'}
cpu: [x64]
os: [linux]
......@@ -2776,8 +2812,8 @@ packages:
dev: true
optional: true
/@nx/nx-win32-arm64-msvc@16.7.3:
resolution: {integrity: sha512-wCrpGqh5fPrlkhHZXVSPBDs9E3L5vIJHtdPrc1QP1uCQiV41mpauey31p6rjvQUWYCC0BGTWJGF+hAY7wYUHdg==}
/@nx/nx-win32-arm64-msvc@16.8.1:
resolution: {integrity: sha512-GKHPy/MyGFoV9cdKgcWLZZK2vDdxt5bQ53ss0k+BDKRP+YwLKm7tJl23eeM7JdB4GLCBntEQPC+dBqxOA8Ze/w==}
engines: {node: '>= 10'}
cpu: [arm64]
os: [win32]
......@@ -2785,8 +2821,8 @@ packages:
dev: true
optional: true
/@nx/nx-win32-x64-msvc@16.7.3:
resolution: {integrity: sha512-Ja2+VhMFWiVsZt3mkdsU1MCotQlAxG94zFiJYbXufsERJItWuN4i0mZjeZITiRBosEmkn4SeAUkg+xuiH+q4GA==}
/@nx/nx-win32-x64-msvc@16.8.1:
resolution: {integrity: sha512-yHZ5FAcx54rVc31R0yIpniepkHMPwaxG23l8E/ZYbL1iPwE/Wc1HeUzUvxUuSXtguRp7ihcRhaUEPkcSl2EAVw==}
engines: {node: '>= 10'}
cpu: [x64]
os: [win32]
......@@ -3071,7 +3107,7 @@ packages:
/@scure/bip39@1.2.1:
resolution: {integrity: sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==}
dependencies:
'@noble/hashes': 1.3.1
'@noble/hashes': 1.3.2
'@scure/base': 1.1.1
/@sentry-internal/tracing@7.64.0:
......@@ -3702,6 +3738,24 @@ packages:
typescript: 5.1.6
dev: true
/@typechain/ethers-v5@10.2.1(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typechain@8.3.1)(typescript@5.2.2):
resolution: {integrity: sha512-n3tQmCZjRE6IU4h6lqUGiQ1j866n5MTCBJreNEHHVWXa2u9GJTaeYyU1/k+1qLutkyw+sS6VAN+AbeiTqsxd/A==}
peerDependencies:
'@ethersproject/abi': ^5.0.0
'@ethersproject/providers': ^5.0.0
ethers: ^5.1.3
typechain: ^8.1.1
typescript: '>=4.3.0'
dependencies:
'@ethersproject/abi': 5.7.0
'@ethersproject/providers': 5.7.2
ethers: 5.7.2
lodash: 4.17.21
ts-essentials: 7.0.3(typescript@5.2.2)
typechain: 8.3.1(typescript@5.2.2)
typescript: 5.2.2
dev: true
/@types/abstract-leveldown@5.0.2:
resolution: {integrity: sha512-+jA1XXF3jsz+Z7FcuiNqgK53hTa/luglT2TyTpKPqoYbxVY+mCPF22Rm+q3KPBrMHJwNXFrTViHszBOfU4vftQ==}
dev: true
......@@ -3713,20 +3767,20 @@ packages:
/@types/bn.js@4.11.6:
resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/bn.js@5.1.0:
resolution: {integrity: sha512-QSSVYj7pYFN49kW77o2s9xTCwZ8F2xLbjLLSEVh8D2F4JUhZtPAGOFLTD+ffqksBx/u4cE/KImFjyhqCjn/LIA==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/body-parser@1.19.1:
resolution: {integrity: sha512-a6bTJ21vFOGIkwM0kzh9Yr89ziVxq4vYH2fQ6N8AeipEzai/cFK6aGMArIkUeIdRIgpwQa+2bXiLuUJCpSf2Cg==}
dependencies:
'@types/connect': 3.4.35
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/chai-as-promised@7.1.5:
......@@ -3752,7 +3806,7 @@ packages:
/@types/connect@3.4.35:
resolution: {integrity: sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
/@types/dateformat@5.0.0:
resolution: {integrity: sha512-SZg4JdHIWHQGEokbYGZSDvo5wA4TLYPXaqhigs/wH+REDOejcJzgH+qyY+HtEUtWOZxEUkbhbdYPqQDiEgrXeA==}
......@@ -3766,7 +3820,7 @@ packages:
/@types/express-serve-static-core@4.17.35:
resolution: {integrity: sha512-wALWQwrgiB2AWTT91CB62b6Yt0sNHpznUXeZEcnPU3DRdlDIz74x8Qg1UUYKSVFi+va5vKOLYRBI1bRKiLLKIg==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
'@types/qs': 6.9.7
'@types/range-parser': 1.2.4
'@types/send': 0.17.1
......@@ -3812,7 +3866,7 @@ packages:
dependencies:
'@types/abstract-leveldown': 5.0.2
'@types/level-errors': 3.0.0
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/lru-cache@5.1.1:
......@@ -3843,7 +3897,7 @@ packages:
/@types/mkdirp@0.5.2:
resolution: {integrity: sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/mocha@10.0.1:
......@@ -3862,7 +3916,7 @@ packages:
/@types/node-fetch@2.6.4:
resolution: {integrity: sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
form-data: 3.0.1
dev: true
......@@ -3875,10 +3929,10 @@ packages:
/@types/node@20.5.0:
resolution: {integrity: sha512-Mgq7eCtoTjT89FqNoTzzXg2XvCi5VMhRV6+I2aYanc6kQCBImeNaAYRs/DyoVqk1YEUJK5gN9VO7HRIdz4Wo3Q==}
dev: true
/@types/node@20.5.3:
resolution: {integrity: sha512-ITI7rbWczR8a/S6qjAW7DMqxqFMjjTo61qZVWJ1ubPvbIQsL5D/TvwjYEalM8Kthpe3hTzOGrF2TGbAu2uyqeA==}
dev: true
/@types/normalize-package-data@2.4.1:
resolution: {integrity: sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw==}
......@@ -3890,7 +3944,7 @@ packages:
/@types/pbkdf2@3.1.0:
resolution: {integrity: sha512-Cf63Rv7jCQ0LaL8tNXmEyqTHuIJxRdlS5vMh1mj5voN4+QFhVZnlZruezqpWYDiJ8UTzhP0VmeLXCmBk66YrMQ==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/pino-multi-stream@5.1.3:
......@@ -3908,13 +3962,13 @@ packages:
/@types/pino-std-serializers@2.4.1:
resolution: {integrity: sha512-17XcksO47M24IVTVKPeAByWUd3Oez7EbIjXpSbzMPhXVzgjGtrOa49gKBwxH9hb8dKv58OelsWQ+A1G1l9S3wQ==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/pino@6.3.11:
resolution: {integrity: sha512-S7+fLONqSpHeW9d7TApUqO6VN47KYgOXhCNKwGBVLHObq8HhaAYlVqUNdfnvoXjCMiwE5xcPm/5R2ZUh8bgaXQ==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
'@types/pino-pretty': 4.7.1
'@types/pino-std-serializers': 2.4.1
sonic-boom: 2.8.0
......@@ -3964,7 +4018,7 @@ packages:
/@types/secp256k1@4.0.3:
resolution: {integrity: sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/seedrandom@3.0.1:
......@@ -3983,14 +4037,14 @@ packages:
resolution: {integrity: sha512-Cwo8LE/0rnvX7kIIa3QHCkcuF21c05Ayb0ZfxPiv0W8VRiZiNW/WuRupHKpqqGVGf7SUA44QSOUKaEd9lIrd/Q==}
dependencies:
'@types/mime': 1.3.2
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/serve-static@1.13.10:
resolution: {integrity: sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ==}
dependencies:
'@types/mime': 1.3.2
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@types/sinon-chai@3.2.5:
......@@ -4027,18 +4081,18 @@ packages:
/@types/ws@7.4.7:
resolution: {integrity: sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
/@types/ws@8.5.3:
resolution: {integrity: sha512-6YOoWjruKj1uLf3INHH7D3qTXwFfEsg1kf3c0uDdSBJwfa/llkwIjrAGV7j7mVgGNbzTQ3HiHKKDXl6bJPD97w==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: false
/@types/ws@8.5.5:
resolution: {integrity: sha512-lwhs8hktwxSjf9UaZ9tG5M03PGogvFaH8gUgLNbN9HKIg0dvv6q+gkSuJ8HN4/VbyxkuLzCjlN7GquQ0gUJfIg==}
dependencies:
'@types/node': 20.5.0
'@types/node': 20.5.3
dev: true
/@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.60.1)(eslint@8.47.0)(typescript@5.1.6):
......@@ -8273,6 +8327,31 @@ packages:
- typescript
dev: true
/ethereum-waffle@4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typescript@5.2.2):
resolution: {integrity: sha512-iw9z1otq7qNkGDNcMoeNeLIATF9yKl1M8AIeu42ElfNBplq0e+5PeasQmm8ybY/elkZ1XyRO0JBQxQdVRb8bqQ==}
engines: {node: '>=10.0'}
hasBin: true
peerDependencies:
ethers: '*'
dependencies:
'@ethereum-waffle/chai': 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@5.7.2)
'@ethereum-waffle/compiler': 4.0.3(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(solc@0.8.15)(typechain@8.3.1)(typescript@5.2.2)
'@ethereum-waffle/mock-contract': 4.0.4(ethers@5.7.2)
'@ethereum-waffle/provider': 4.0.5(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(ethers@5.7.2)
ethers: 5.7.2
solc: 0.8.15
typechain: 8.3.1(typescript@5.2.2)
transitivePeerDependencies:
- '@ensdomains/ens'
- '@ensdomains/resolver'
- '@ethersproject/abi'
- '@ethersproject/providers'
- debug
- encoding
- supports-color
- typescript
dev: true
/ethereumjs-abi@0.6.8:
resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==}
dependencies:
......@@ -10638,7 +10717,7 @@ packages:
'@lerna/child-process': 7.1.5
'@lerna/create': 7.1.5
'@npmcli/run-script': 6.0.2
'@nx/devkit': 16.7.1(nx@16.7.3)
'@nx/devkit': 16.7.1(nx@16.8.1)
'@octokit/plugin-enterprise-rest': 6.0.1
'@octokit/rest': 19.0.11
byte-size: 8.1.1
......@@ -10681,7 +10760,7 @@ packages:
npm-packlist: 5.1.1
npm-registry-fetch: 14.0.5
npmlog: 6.0.2
nx: 16.7.3
nx: 16.8.1
p-map: 4.0.0
p-map-series: 2.1.0
p-pipe: 3.1.0
......@@ -10701,7 +10780,7 @@ packages:
strong-log-transformer: 2.1.0
tar: 6.1.11
temp-dir: 1.0.0
typescript: 5.1.6
typescript: 5.2.2
upath: 2.0.1
uuid: 9.0.0
validate-npm-package-license: 3.0.4
......@@ -11808,6 +11887,12 @@ packages:
hasBin: true
dev: true
/mkdirp@3.0.1:
resolution: {integrity: sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg==}
engines: {node: '>=10'}
hasBin: true
dev: true
/mlly@1.4.0:
resolution: {integrity: sha512-ua8PAThnTwpprIaU47EPeZ/bPUVp2QYBbWMphUQpVdBI3Lgqzm5KZQ45Agm3YJedHXaIHl6pBGabaLSUPPSptg==}
dependencies:
......@@ -12293,11 +12378,11 @@ packages:
resolution: {integrity: sha512-ub5E4+FBPKwAZx0UwIQOjYWGHTEq5sPqHQNRN8Z9e4A7u3Tj1weLJsL59yH9vmvqEtBHaOmT6cYQKIZOxp35FQ==}
dev: true
/nx-cloud@16.3.0:
resolution: {integrity: sha512-hmNgpeLO4v4WDSWa8YhwX+q+9ohIyY8iqxlWyIKixWzQH2XfRgYFjOLH4IDLGOlKa3hg7MB6+4+75cK9CfSmKw==}
/nx-cloud@16.4.0:
resolution: {integrity: sha512-jbq4hWvDwRlJVpxgMgbmNSkue+6XZSn53R6Vo6qmCAWODJ9KY1BZdZ/9VRL8IX/BRKebVFiXp3SapFB1qPhH8A==}
hasBin: true
dependencies:
'@nrwl/nx-cloud': 16.3.0
'@nrwl/nx-cloud': 16.4.0
axios: 1.1.3
chalk: 4.1.2
dotenv: 10.0.0
......@@ -12311,8 +12396,8 @@ packages:
- debug
dev: true
/nx@16.7.3:
resolution: {integrity: sha512-aam+1ZesbCfV9xv5FktsAqHVBObcazrf1MG56SdBTYNuILBVgAztPj8NyIZ87ZHw8IE/JxWDDUtZo7lwaSOFzA==}
/nx@16.8.1:
resolution: {integrity: sha512-K5KrwNdPz0eEe6SY5wrnhZcigjfIJkttPrIJRXNBQTE50NGcOfz1TjMXPdTWBxBCCua5PAealO3OrE8jpv+QnQ==}
hasBin: true
requiresBuild: true
peerDependencies:
......@@ -12324,7 +12409,7 @@ packages:
'@swc/core':
optional: true
dependencies:
'@nrwl/tao': 16.7.3
'@nrwl/tao': 16.8.1
'@parcel/watcher': 2.0.4
'@yarnpkg/lockfile': 1.1.0
'@yarnpkg/parsers': 3.0.0-rc.46
......@@ -12335,6 +12420,7 @@ packages:
cli-spinners: 2.6.1
cliui: 7.0.4
dotenv: 16.3.1
dotenv-expand: 10.0.0
enquirer: 2.3.6
fast-glob: 3.2.7
figures: 3.2.0
......@@ -12360,16 +12446,16 @@ packages:
yargs: 17.7.2
yargs-parser: 21.1.1
optionalDependencies:
'@nx/nx-darwin-arm64': 16.7.3
'@nx/nx-darwin-x64': 16.7.3
'@nx/nx-freebsd-x64': 16.7.3
'@nx/nx-linux-arm-gnueabihf': 16.7.3
'@nx/nx-linux-arm64-gnu': 16.7.3
'@nx/nx-linux-arm64-musl': 16.7.3
'@nx/nx-linux-x64-gnu': 16.7.3
'@nx/nx-linux-x64-musl': 16.7.3
'@nx/nx-win32-arm64-msvc': 16.7.3
'@nx/nx-win32-x64-msvc': 16.7.3
'@nx/nx-darwin-arm64': 16.8.1
'@nx/nx-darwin-x64': 16.8.1
'@nx/nx-freebsd-x64': 16.8.1
'@nx/nx-linux-arm-gnueabihf': 16.8.1
'@nx/nx-linux-arm64-gnu': 16.8.1
'@nx/nx-linux-arm64-musl': 16.8.1
'@nx/nx-linux-x64-gnu': 16.8.1
'@nx/nx-linux-x64-musl': 16.8.1
'@nx/nx-win32-arm64-msvc': 16.8.1
'@nx/nx-win32-x64-msvc': 16.8.1
transitivePeerDependencies:
- debug
dev: true
......@@ -15083,6 +15169,14 @@ packages:
typescript: 5.1.6
dev: true
/ts-essentials@7.0.3(typescript@5.2.2):
resolution: {integrity: sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ==}
peerDependencies:
typescript: '>=3.7.0'
dependencies:
typescript: 5.2.2
dev: true
/ts-interface-checker@0.1.13:
resolution: {integrity: sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==}
dev: true
......@@ -15131,7 +15225,7 @@ packages:
yn: 3.1.1
dev: true
/ts-node@10.9.1(@types/node@20.5.3)(typescript@5.1.6):
/ts-node@10.9.1(@types/node@20.5.3)(typescript@5.2.2):
resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==}
hasBin: true
peerDependencies:
......@@ -15157,7 +15251,7 @@ packages:
create-require: 1.1.1
diff: 4.0.2
make-error: 1.3.6
typescript: 5.1.6
typescript: 5.2.2
v8-compile-cache-lib: 3.0.1
yn: 3.1.1
dev: true
......@@ -15288,7 +15382,7 @@ packages:
joycon: 3.1.1
postcss-load-config: 4.0.1
resolve-from: 5.0.0
rollup: 3.26.3
rollup: 3.28.0
source-map: 0.8.0-beta.0
sucrase: 3.34.0
tree-kill: 1.2.2
......@@ -15443,6 +15537,27 @@ packages:
- supports-color
dev: true
/typechain@8.3.1(typescript@5.2.2):
resolution: {integrity: sha512-fA7clol2IP/56yq6vkMTR+4URF1nGjV82Wx6Rf09EsqD4tkzMAvEaqYxVFCavJm/1xaRga/oD55K+4FtuXwQOQ==}
hasBin: true
peerDependencies:
typescript: '>=4.3.0'
dependencies:
'@types/prettier': 2.3.2
debug: 4.3.4(supports-color@8.1.1)
fs-extra: 7.0.1
glob: 7.1.7
js-sha3: 0.8.0
lodash: 4.17.21
mkdirp: 1.0.4
prettier: 2.8.8
ts-command-line-args: 2.5.1
ts-essentials: 7.0.3(typescript@5.2.2)
typescript: 5.2.2
transitivePeerDependencies:
- supports-color
dev: true
/typed-array-buffer@1.0.0:
resolution: {integrity: sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==}
engines: {node: '>= 0.4'}
......@@ -15511,6 +15626,12 @@ packages:
engines: {node: '>=14.17'}
hasBin: true
/typescript@5.2.2:
resolution: {integrity: sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==}
engines: {node: '>=14.17'}
hasBin: true
dev: true
/typical@4.0.0:
resolution: {integrity: sha512-VAH4IvQ7BDFYglMd7BPRDfLgxZZX4O4TFcRDA6EN5X7erNJJq+McIEp8np9aVtxrCJ6qx4GTYVfOWNjcqwZgRw==}
engines: {node: '>=8'}
......
......@@ -6,6 +6,7 @@
- [Overview](#overview)
- [State](#state)
- [State Hash](#state-hash)
- [Memory](#memory)
- [Heap](#heap)
- [Delay Slots](#delay-slots)
......@@ -53,6 +54,34 @@ It consists of the following fields:
The state is represented by packing the above fields, in order, into a 226-byte buffer.
### State Hash
The state hash is computed by hashing the 226-byte state buffer with the Keccak256 hash function
and then setting the high-order byte to the respective VM status.
The VM status can be derived from the state's `exited` and `exitCode` fields.
```rs
enum VmStatus {
Valid = 0,
Invalid = 1,
Panic = 2,
Unfinished = 3,
}
fn vm_status(exit_code: u8, exited: bool) -> u8 {
if exited {
match exit_code {
0 => VmStatus::Valid,
1 => VmStatus::Invalid,
_ => VmStatus::Panic,
}
} else {
VmStatus::Unfinished
}
}
```
## Memory
Memory is represented as a binary merkle tree.
......
......@@ -30,6 +30,13 @@ single dispute game will not result in the bug becoming consensus.
For added context, we define a few types that are used in the following snippets.
```solidity
/// @notice A custom type for a generic hash.
type Hash is bytes32;
/// @notice A dedicated timestamp type.
type Timestamp is uint64;
/// @notice The type of proof system being used.
enum GameType {
/// @dev The game will use a `IDisputeGame` implementation that utilizes fault proofs.
......@@ -90,38 +97,74 @@ interface IDisputeGameFactory {
/// @param rootClaim The root claim of the dispute game
event DisputeGameCreated(address indexed disputeProxy, GameType indexed gameType, Claim indexed rootClaim);
/// @notice `games` queries an internal a mapping that maps the hash of `gameType ++ rootClaim ++ extraData`
/// to the deployed `DisputeGame` clone.
/// @notice Emitted when a new game implementation added to the factory
/// @param impl The implementation contract for the given `GameType`.
/// @param gameType The type of the DisputeGame.
event ImplementationSet(address indexed impl, GameType indexed gameType);
/// @notice The total number of dispute games created by this factory.
/// @return gameCount_ The total number of dispute games created by this factory.
function gameCount() external view returns (uint256 gameCount_);
/// @notice `games` queries an internal mapping that maps the hash of
/// `gameType ++ rootClaim ++ extraData` to the deployed `DisputeGame` clone.
/// @dev `++` equates to concatenation.
/// @param gameType The type of the DisputeGame - used to decide the proxy implementation
/// @param rootClaim The root claim of the DisputeGame.
/// @param extraData Any extra data that should be provided to the created dispute game.
/// @return _proxy The clone of the `DisputeGame` created with the given parameters. Returns `address(0)` if nonexistent.
function games(GameType gameType, Claim rootClaim, bytes calldata extraData) external view returns (IDisputeGame _proxy);
/// @notice `gameImpls` is a mapping that maps `GameType`s to their respective `IDisputeGame` implementations.
/// @param gameType The type of the dispute game.
/// @return _impl The address of the implementation of the game type. Will be cloned on creation of a new dispute game
/// with the given `gameType`.
function gameImpls(GameType gameType) public view returns (IDisputeGame _impl);
/// @notice The owner of the contract.
/// @dev Owner Permissions:
/// - Update the implementation contracts for a given game type.
/// @return _owner The owner of the contract.
function owner() public view returns (address _owner);
/// @param _gameType The type of the DisputeGame - used to decide the proxy implementation
/// @param _rootClaim The root claim of the DisputeGame.
/// @param _extraData Any extra data that should be provided to the created dispute game.
/// @return proxy_ The clone of the `DisputeGame` created with the given parameters.
/// Returns `address(0)` if nonexistent.
/// @return timestamp_ The timestamp of the creation of the dispute game.
function games(GameType _gameType, Claim _rootClaim, bytes calldata _extraData)
external
view
returns (IDisputeGame proxy_, Timestamp timestamp_);
/// @notice `gameAtIndex` returns the dispute game contract address and its creation timestamp
/// at the given index. Each created dispute game increments the underlying index.
/// @param _index The index of the dispute game.
/// @return gameType_ The type of the DisputeGame - used to decide the proxy implementation.
/// @return timestamp_ The timestamp of the creation of the dispute game.
/// @return proxy_ The clone of the `DisputeGame` created with the given parameters.
/// Returns `address(0)` if nonexistent.
function gameAtIndex(uint256 _index)
external
view
returns (GameType gameType_, Timestamp timestamp_, IDisputeGame proxy_);
/// @notice `gameImpls` is a mapping that maps `GameType`s to their respective
/// `IDisputeGame` implementations.
/// @param _gameType The type of the dispute game.
/// @return impl_ The address of the implementation of the game type.
/// Will be cloned on creation of a new dispute game with the given `gameType`.
function gameImpls(GameType _gameType) external view returns (IDisputeGame impl_);
/// @notice Creates a new DisputeGame proxy contract.
/// @param gameType The type of the DisputeGame - used to decide the proxy implementation
/// @param rootClaim The root claim of the DisputeGame.
/// @param extraData Any extra data that should be provided to the created dispute game.
function create(GameType gameType, Claim rootClaim, bytes calldata extraData) external returns (IDisputeGame proxy);
/// @notice Sets the implementation contract for a specific `GameType`
/// @param _gameType The type of the DisputeGame - used to decide the proxy implementation.
/// @param _rootClaim The root claim of the DisputeGame.
/// @param _extraData Any extra data that should be provided to the created dispute game.
/// @return proxy_ The address of the created DisputeGame proxy.
function create(GameType _gameType, Claim _rootClaim, bytes calldata _extraData)
external
returns (IDisputeGame proxy_);
/// @notice Sets the implementation contract for a specific `GameType`.
/// @dev May only be called by the `owner`.
/// @param gameType The type of the DisputeGame
/// @param impl The implementation contract for the given `GameType`
function setImplementation(GameType gameType, IDisputeGame impl) external;
/// @param _gameType The type of the DisputeGame.
/// @param _impl The implementation contract for the given `GameType`.
function setImplementation(GameType _gameType, IDisputeGame _impl) external;
/// @notice Returns a unique identifier for the given dispute game parameters.
/// @dev Hashes the concatenation of `gameType . rootClaim . extraData`
/// without expanding memory.
/// @param _gameType The type of the DisputeGame.
/// @param _rootClaim The root claim of the DisputeGame.
/// @param _extraData Any extra data that should be provided to the created dispute game.
/// @return uuid_ The unique identifier for the given dispute game parameters.
function getGameUUID(GameType _gameType, Claim _rootClaim, bytes memory _extraData)
external
pure
returns (Hash uuid_);
}
```
......@@ -146,82 +189,51 @@ interface IDisputeGame {
/// @custom:invariant The `initialize` function may only be called once.
function initialize() external;
/// @notice Returns the semantic version of the DisputeGame contract
function version() external pure returns (string memory _version);
/// @notice Emitted when the game is resolved.
/// @param status The status of the game after resolution.
event Resolved(GameStatus indexed status);
/// @notice Returns the timestamp that the DisputeGame contract was created at.
function createdAt() external pure returns (Timestamp _createdAt);
function createdAt() external pure returns (Timestamp createdAt_);
/// @notice Returns the current status of the game.
function status() external view returns (GameStatus _status);
function status() external view returns (GameStatus status_);
/// @notice Getter for the game type.
/// @dev `clones-with-immutable-args` argument #1
/// @dev The reference impl should be entirely different depending on the type (fault, validity)
/// i.e. The game type should indicate the security model.
/// @return _gameType The type of proof system being used.
function gameType() external view returns (GameType _gameType);
/// @return gameType_ The type of proof system being used.
function gameType() external view returns (GameType gameType_);
/// @notice Getter for the root claim.
/// @return _rootClaim The root claim of the DisputeGame.
/// @return rootClaim_ The root claim of the DisputeGame.
/// @dev `clones-with-immutable-args` argument #2
function rootClaim() external view returns (Claim _rootClaim);
function rootClaim() external view returns (Claim rootClaim_);
/// @notice Getter for the extra data.
/// @dev `clones-with-immutable-args` argument #3
/// @return _extraData Any extra data supplied to the dispute game contract by the creator.
function extraData() external view returns (bytes memory _extraData);
/// @return extraData_ Any extra data supplied to the dispute game contract by the creator.
function extraData() external view returns (bytes memory extraData_);
/// @notice Returns the address of the `BondManager` used
function bondManager() public view returns (IBondManager _bondManager);
/// @notice Returns the address of the `BondManager` used
function bondManager() public view returns (IBondManager bondManager_);
/// @notice If all necessary information has been gathered, this function should mark the game
/// status as either `CHALLENGER_WINS` or `DEFENDER_WINS` and return the status of
/// the resolved game. It is at this stage that the bonds should be awarded to the
/// necessary parties.
/// @dev May only be called if the `status` is `IN_PROGRESS`.
function resolve() public returns (GameStatus _status);
}
////////////////////////////////////////////////////////////////
// OUTPUT ATTESTATION DISPUTE GAME //
////////////////////////////////////////////////////////////////
/// @title IDisputeGame_OutputAttestation
/// @notice The interface for an attestation-based DisputeGame meant to contest output
/// proposals in Optimism's `L2OutputOracle` contract.
interface IDisputeGame_OutputAttestation is IDisputeGame {
/// @notice A mapping of addresses from the `signerSet` to booleans signifying whether
/// or not they have authorized the `rootClaim` to be invalidated.
function challenges(address challenger) external view returns (bool _challenged);
/// @notice The signer set consists of authorized public keys that may challenge the `rootClaim`.
/// This set of signers is snapshotted from the `SystemConfig` upon creation of the game.
/// @return An array of authorized signers from the `SystemConfig` contract.
function frozenSignerSet() external view returns (address[] memory _signers);
/// @notice The signer set consists of authorized public keys that may challenge the `rootClaim`.
/// @return _isAuthorized Whether or not the `addr` is part of the frozen signer set.
function signerSet(address addr) external view override returns (bool _isAuthorized);
/// @notice The amount of signatures required to successfully challenge the `rootClaim`
/// output proposal. Once this threshold is met by members of the `signerSet`
/// calling `challenge`, the game will be resolved to `CHALLENGER_WINS`.
/// @custom:invariant The `signatureThreshold` may never be greater than the length of the `signerSet`.
function frozenSignatureThreshold() external view returns (uint256 _signatureThreshold);
/// @notice Returns the L2 Block Number that the `rootClaim` commits to. Exists within the `extraData`.
function l2BlockNumber() public view returns (uint256 _l2BlockNumber);
/// @notice Challenge the `rootClaim`.
/// @dev - If the `ecrecover`ed address that created the signature is not a part of the
/// signer set returned by `signerSet`, this function should revert.
/// - If the signature provided is the signature that breaches the signature threshold,
/// the function should call the `resolve` function to resolve the game as `CHALLENGER_WINS`.
/// - When the game resolves, the bond attached to the root claim should be distributed among
/// the signers who participated in challenging the invalid claim.
/// @param signature An EIP-712 signature committing to the `rootClaim` and `l2BlockNumber` (within the `extraData`)
/// from a key that exists within the `signerSet`.
function challenge(bytes calldata signature) external;
/// @return status_ The status of the game after resolution.
function resolve() public returns (GameStatus status_);
/// @notice A compliant implementation of this interface should return the components of the
/// game UUID's preimage provided in the cwia payload. The preimage of the UUID is
/// constructed as `keccak256(gameType . rootClaim . extraData)` where `.` denotes
/// concatenation.
/// @return gameType_ The type of proof system being used.
/// @return rootClaim_ The root claim of the DisputeGame.
/// @return extraData_ Any extra data supplied to the dispute game contract by the creator.
function gameData() external view returns (GameType gameType_, Claim rootClaim_, bytes memory extraData_);
}
```
# Fault Dispute Game
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
**Table of Contents**
- [Overview](#overview)
- [Definitions](#definitions)
- [Virtual Machine (VM)](#virtual-machine-vm)
- [Execution Trace](#execution-trace)
- [Claims](#claims)
- [DAG](#dag)
- [Game Tree](#game-tree)
- [Position](#position)
- [GAME_DURATION](#game_duration)
- [Game Mechanics](#game-mechanics)
- [Actors](#actors)
- [Moves](#moves)
- [Attack](#attack)
- [Defend](#defend)
- [Step](#step)
- [Step Types](#step-types)
- [Team Dynamics](#team-dynamics)
- [Game Clock](#game-clock)
- [Resolution](#resolution)
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
## Overview
The Fault Dispute Game (FDG) is a specific type of
[dispute game](./dispute-game-interface.md) that verifies the validity of a
root claim by iteratively bisecting an execution trace down to a single instruction step.
It relies on a Virtual Machine (VM) to falsify invalid claims made
at a single instruction step.
Actors, i.e. Players, interact with the game by making claims that dispute other claims in the FDG.
Each claim made narrows the execution trace until the source of dispute is a single state transition.
Once a time limit is reached, the dispute game is _resolved_, based on
claims made that are disputed and which aren't, to determine the winners of the game.
## Definitions
### Virtual Machine (VM)
This is a state transition function (STF) that takes a _pre-state_ and computes the post-state.
The VM may reference external data during the STF and as such, it also accepts a _proof_ of this data.
Typically, the pre-state contains a commitment to the _proof_ to verify the integrity of the data referenced.
Mathemtically, we define the STF as $VM(S_i,P_i)$ where
- $S_i$ is the pre-state
- $P_i$ is an optional proof needed for the transition from $S_i$ to $S_{i+1}$.
### Execution Trace
An execution trace $T$ is a sequence $(S_0,S_1,S_2,...,S_n)$ where each $S_i$ is a VM state and
for each $i$, $0 \le i \lt n$, $S_{n+1} = VM(S_i, P_i)$.
Every execution trace has a unique starting state, $S_0$, that's preset to a FDG implementation.
We refer to this state as the **ABSOLUTE\_PRESTATE**.
### Claims
Claims assert an execution trace. This is represented as `ClaimHash`, a `bytes32` commitment to
the last VM state in the trace. A FDG is initialized with a root claim, which commits to the entire
execution trace. As we'll see later, there can be multiple claims, committing to different states in the FDG.
### DAG
A Directed Acyclic Graph $G = (V,E)$ representing the relationship between claims, where:
- $V$ is the set of nodes, each representing a claim. Formally, $V = \{C_1,C_2,...,C_n\}$,
where $C_i$ is a claim.
- $E$ is the set of _directed_ edges. An edge $(C_i,C_j)$ exists if $C_j$ is a direct dispute
against $C_i$ through either an "Attack" or "Defend" [move](#moves).
### Game Tree
The Game Tree is a binary tree of positions. Every claim in the DAG references a position in the Game Tree.
The Game Tree has a maximum depth, `MAX_GAME_DEPTH`, that's preset to an FDG implementation.
Thus, the Game Tree contains $2^{d-1}$ positions, where $d$ is the `MAX_GAME_DEPTH`
(unless $d=0$, in which case there's only 1 position).
### Position
A position represents the location of a claim in the Game Tree. This is represented by a
"generalized index" (or **gindex**) where the high-order bit is the level in the tree and the remaining
bits is a unique bit pattern, allowing a unique identifier for each node in the tree.
The **gindex** of a position $n$ can be calculated as $2^{d(n)} + idx(n)$, where:
- $d(n)$ is a function returning the depth of the position in the Game Tree
- $idx(n)$ is a function returning the index of the position at its depth (starting from the left).
Positions at the deepest level of the game tree correspond to indices in the execution trace.
Positions higher up the game tree also cover the deepest, right-most positions relative to the current position.
We refer to this coverage as the **trace index** of a Position.
> This means claims commit to an execution trace that terminates at the same index as their Position's trace index.
Note that there can be multiple positions covering the same _trace index_.
### GAME_DURATION
This is an immutable, preset to a FDG implementation, representing the duration of the game.
## Game Mechanics
### Actors
The game involves two types of participants (or Players): **Challengers** and **Defenders**.
These players are grouped into separate teams, each employing distinct strategies to interact with the game.
Team members share a common goal regarding the game's outcome. Players interact with the game primarily through _moves_.
### Moves
A Move is a challenge against a claim's execution trace and must include an alternate claim asserting a different trace.
Moves can either be attacks or defenses and serve to update to DAG by adding nodes and edges targeting the disputed
claim.
Initially, claims added to the DAG are _uncontesteed_ (i.e. not **countered**). Once a move targets a claim, that claim
is considered countered.
The status of a claim &mdash; whether it's countered or not &mdash; helps determine its validity and, ultimately, the
game's winner.
#### Attack
A logical move made when a claim is disagreed with.
A claim at the relative attack position to a node, `n`, in the Game Tree commits to half
of the trace of the `n`’s claim.
The attack position relative to a node can be calculated by multiplying its gindex by 2.
To illustrate this, here's a Game Tree highlighting an attack on a Claim positioned at 6.
![Attacking node 6](assets/attack.png)
Attacking the node at 6 moves creates a new claim positioned at 12.
#### Defend
The logical move against a claim when you agree with both it and its parent.
A defense at the relative position to a node, `n``, in the Game Tree commits to the first half of n + 1’s trace range.
![Defend at 4](assets/defend.png)
Note that because of this, some nodes may never exist within the Game Tree.
However, they're not necessary as these nodes have complimentary, valid positions
with the same trace index within the tree. For example, a Position with gindex 5 has the same
trace index as another Position with gindex 2. We can verify that all trace indices have valid moves within the game:
![Game Tree Showing All Valid Move Positions](assets/valid-moves.png)
There may be multiple claims at the same position, so long as their `ClaimHash` are unique.
Each move adds new claims to the Game Tree at strictly increasing depth.
Once a claim is at `MAX_GAME_DEPTH`, the only way to dispute such claims is to **step**.
### Step
At `MAX_GAME_DEPTH`, the position of claims correspond to indices of an execution trace.
It's at this point that the FDG is able to query the VM to determine the validity of claims,
by checking the states they're committing to.
This is done by applying the VM's STF to the state a claim commits to.
If the STF post-state does not match the claimed state, the challenge succeeds.
```solidity
/// @notice Perform an instruction step via an on-chain fault proof processor.
/// @dev This function should point to a fault proof processor in order to execute
/// a step in the fault proof program on-chain. The interface of the fault proof
/// processor contract should adhere to the `IBigStepper` interface.
/// @param _claimIndex The index of the challenged claim within `claimData`.
/// @param _isAttack Whether or not the step is an attack or a defense.
/// @param _stateData The stateData of the step is the preimage of the claim at the given
/// prestate, which is at `_stateIndex` if the move is an attack and `_claimIndex` if
/// the move is a defense. If the step is an attack on the first instruction, it is
/// the absolute prestate of the fault proof VM.
/// @param _proof Proof to access memory nodes in the VM's merkle state tree.
function step(uint256 _claimIndex, bool isAttack, bytes calldata _stateData, bytes calldata _proof) external;
```
### Step Types
Similar to moves, there are two ways to step on a claim; attack or defend.
These determine the pre-state input to the VM STF and the expected output.
- **Attack Step** - Challenges a claim by providing a pre-state, proving an invalid state transition.
It uses the previous state in the execution trace as input and expects the disputed claim's state as output.
There must exist a claim in the DAG that commits to the input.
- **Defense Step** - Challenges a claim by proving it was an invalid attack,
thereby defending the disputed ancestor's claim. It uses the disputed claim's state as input and expects
the next state in the execution trace as output. There must exist a claim in the DAG that commits to the
expected output.
The FDG step handles the inputs to the VM and asserts the expected output.
A step that successfully proves an invalid post-state (when attacking) or pre-state (when defending) is a
successful counter against the disputed claim.
Players interface with `step` by providing an indicator of attack and state data (including any proofs)
that corresponds to the expected pre/post state (depending on whether it's an attack or defend).
The FDG will assert that an existing claim commits to the state data provided by players.
### Team Dynamics
Challengers seek to dispute the root claim, while Defenders aim to support it.
Both types of actors will move accordingly to support their team. For Challengers, this means
attacking the root claim and disputing claims positioned at even depths in the Game Tree.
Defenders do the opposite by disputing claims positioned at odd depths.
Players on either team are motivated to support the actions of their teammates.
This involves countering disputes against claims made by their team (assuming these claims are honest).
Uncontested claims are likely to result in a loss, as explained later under [Resolution](#resolution).
### Game Clock
Every claim in the game has a Clock. A claim's inherits the clock of its grandparent claim in the
DAG (and so on). Akin to a chess clock, it keeps track of the total time each team takes to make
moves, preventing delays.
Making a move resumes the clock for the disputed claim and puases it for the newly added one.
A move against a particular claim is no longer possible once the parent of the disputed claim's Clock
has exceeded half of the `GAME_DURATION`. By which point, the claim's clock has _expired_.
### Resolution
Resolving the FDG determines which team won.
This is done by examining the left-most, uncontested (or undisputed) claim.
If the depth of this claim is odd then Challengers win, otherwise Defenders win.
Resolution is only possible once the Clock of the left-most, uncontested claim has expired.
Given these rules, players are motivated to move quickly to challenge dishonest claims.
Each move bisects the execution trace and eventually, `MAX_GAME_DEPTH` is reached where disputes
can be settled conclusively. Dishonest players are disincentivized to participate, via backwards induction,
as an invalid claim won't remain uncontested. Further incentives can be added to the game by requiring
claims to be bonded, while rewarding game winners using the bonds of dishonest claims.
CI=false
GRAFANA_ADMIN_PWD=
# Used to set the display to be used by playwright when running Metamask test service.
# The following are to be used if running on MacOS
# MM_DISPLAY=host.docker.internal:0
# MM_DISPLAY_VOLUME=/tmp/.X11-unix:/tmp/.X11-unix
MM_DISPLAY=
MM_DISPLAY_VOLUME=
# Needs to point to docker, otherwise you'll get the error: exec: "docker": executable file not found in $PATH
PATH=/
# Runs every minute
* * * * * /usr/local/bin/docker-compose -f /path/to/docker-compose.yml --profile 1minute up -d
# Runs every 5 minutes
*/5 * * * * /usr/local/bin/docker-compose -f /path/to/docker-compose.yml --profile 5minutes up -d
apiVersion: 1
datasources:
- name: Prometheus
type: prometheus
access: proxy
url: http://prometheus:9090
isDefault: true
version: "3"
services:
pushgateway:
image: prom/pushgateway
ports:
- "9091:9091"
restart: unless-stopped
read_only: true
security_opt:
- "no-new-privileges:true"
prometheus:
image: prom/prometheus:latest
container_name: prometheus
ports:
- "9090:9090"
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml
depends_on:
- pushgateway
command:
- '--config.file=/etc/prometheus/prometheus.yml'
read_only: true
security_opt:
- "no-new-privileges:true"
grafana:
image: grafana/grafana:latest
container_name: grafana
ports:
- "3000:3000"
depends_on:
- prometheus
environment:
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_ADMIN_PWD}
volumes:
- ./datasources.yml:/etc/grafana/provisioning/datasources/datasources.yaml
security_opt:
- "no-new-privileges:true"
metamask:
build: ./metamask
container_name: test-service-metamask
profiles: ["30minute"]
depends_on:
- prometheus
environment:
DISPLAY: ${MM_DISPLAY:-:0}
CI: ${CI:-true}
volumes:
- ${MM_DISPLAY_VOLUME}
restart: no
# Example Test Service Config
# my_test_service:
# build: ./my_test_service_dir
# container_name: my_test_service
# profiles: ["1minute"]
# depends_on:
# - prometheus
# restart: no
METAMASK_SECRET_WORDS_OR_PRIVATEKEY=""
METAMASK_NETWORK="goerli"
METAMASK_PASSWORD="Test@1234"
METAMASK_DAPP_URL="http://localhost:9011"
OP_GOERLI_RPC_URL=""
node_modules/
/test-results/
/playwright-report/
/playwright/.cache/
.env
FROM mcr.microsoft.com/playwright:v1.37.1-jammy
WORKDIR /app
ENV PATH /app/node_modules/.bin:$PATH
COPY package.json /app/
RUN npm install
COPY tests /app/tests/
COPY .env /app/
COPY playwright.config.ts /app/
COPY start.sh /app/
COPY tsconfig.json /app/
CMD /bin/sh /app/start.sh
MIT License
Copyright (c) 2023 Optimism
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
{
"name": "@eth-optimism/ufm-test-service-metamask",
"version": "0.1.0",
"description": "A User facing monitoring Test Service for MetaMask",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/ethereum-optimism/optimism.git",
"directory": "ufm-test-services/metamask"
},
"homepage": "https://optimism.io",
"type": "module",
"scripts": {
"clean": "rm -rf node_modules packages/*/node_modules && echo 'Finished cleaning'",
"lint": "prettier --check .",
"lint:fix": "prettier --write .",
"start:metamask-dapp": "npx static-server node_modules/@metamask/test-dapp/dist --port 9011",
"test": "npx playwright test"
},
"devDependencies": {
"@metamask/test-dapp": "^7.1.0",
"@playwright/test": "1.37.1",
"@synthetixio/synpress": "3.7.2-beta.5",
"dotenv": "^16.3.1",
"static-server": "^2.2.1",
"typescript": "^5.1.6",
"viem": "^1.10.8"
}
}
import { defineConfig, devices } from '@playwright/test';
/**
* Read environment variables from file.
* https://github.com/motdotla/dotenv
*/
import 'dotenv/config'
/**
* See https://playwright.dev/docs/test-configuration.
*/
export default defineConfig({
testDir: './tests',
/* Run tests in files in parallel */
fullyParallel: true,
/* Fail the build on CI if you accidentally left test.only in the source code. */
forbidOnly: !!process.env.CI,
/* Retry on CI only */
retries: process.env.CI ? 2 : 0,
/* Opt out of parallel tests on CI. */
workers: process.env.CI ? 1 : undefined,
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
reporter: 'html',
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
use: {
/* Base URL to use in actions like `await page.goto('/')`. */
// baseURL: 'http://127.0.0.1:3000',
/* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
trace: 'on-first-retry',
},
/* Configure projects for major browsers */
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'] },
},
],
/* Run your local dev server before starting the tests */
webServer: {
command: 'npm run start:metamask-dapp',
url: process.env.METAMASK_DAPP_URL,
reuseExistingServer: false,
},
});
This source diff could not be displayed because it is too large. You can view the blob instead.
#!/bin/bash
npm test
\ No newline at end of file
import 'dotenv/config'
import metamask from '@synthetixio/synpress/commands/metamask.js'
import { expect, test, type Page } from '@playwright/test'
import { mnemonicToAccount, privateKeyToAccount } from 'viem/accounts'
import { testWithSynpress } from './testWithSynpressUtil'
const expectedSender =
process.env.METAMASK_SECRET_WORDS_OR_PRIVATEKEY?.startsWith('0x')
? privateKeyToAccount(
process.env.METAMASK_SECRET_WORDS_OR_PRIVATEKEY as `0x${string}`
).address.toLowerCase()
: mnemonicToAccount(
process.env.METAMASK_SECRET_WORDS_OR_PRIVATEKEY as string
).address.toLowerCase()
const expectedRecipient = '0x8fcfbe8953433fd1f2e8375ee99057833e4e1e9e'
let sharedPage: Page
test.describe.configure({ mode: 'serial' })
test.afterAll(async () => {
await sharedPage.close()
})
testWithSynpress('Setup wallet and dApp', async ({ page }) => {
sharedPage = page
await sharedPage.goto('http://localhost:9011')
})
testWithSynpress('Add OP Goerli network', async () => {
const expectedChainId = '0x1a4'
await metamask.addNetwork({
name: 'op-goerli',
rpcUrls: {
default: {
http: [process.env.OP_GOERLI_RPC_URL],
},
},
id: '420',
nativeCurrency: {
symbol: 'OPG',
},
blockExplorers: {
default: {
url: 'https://goerli-explorer.optimism.io',
},
},
})
await expect(sharedPage.locator('#chainId')).toHaveText(expectedChainId)
})
test(`Connect wallet with ${expectedSender}`, async () => {
await sharedPage.click('#connectButton')
await metamask.acceptAccess()
await expect(sharedPage.locator('#accounts')).toHaveText(expectedSender)
})
test('Send an EIP-1559 transaciton and verfiy success', async () => {
const expectedTransferAmount = '0x1'
const expectedTxType = '0x2'
await sharedPage.locator('#toInput').fill(expectedRecipient)
await sharedPage.locator('#amountInput').fill(expectedTransferAmount)
await sharedPage.locator('#typeInput').selectOption(expectedTxType)
await sharedPage.click('#submitForm')
const txHashPromise = new Promise((resolve) => {
// Metamask test dApp only console.logs the transaction hash,
// so we must setup a listener before we confirm the tx to capture it
sharedPage.on('console', async (msg) => {
resolve(msg.text()) // Resolve the Promise when txHash is set
})
})
await metamask.confirmTransaction()
const txHash = await txHashPromise
// Waiting for Infura (Metamask given provider) to index our transaction
await sharedPage.waitForTimeout(10_000)
// Metamask test dApp allows us access to the Metamask RPC provider via loading this URL.
// The RPC reponse will be populated onto the page that's loaded.
// More info here: https://github.com/MetaMask/test-dapp/tree/main#usage
await sharedPage.goto(
`${process.env.METAMASK_DAPP_URL}/request.html?method=eth_getTransactionReceipt&params=["${txHash}"]`
)
// Waiting for RPC response to be populated on the page
await sharedPage.waitForTimeout(2_000)
const transaction = JSON.parse(
(await sharedPage.locator('body > main').innerText()).replace(
'Response: ',
''
)
)
expect(transaction.status).toBe('0x1')
})
import 'dotenv/config'
import {
type BrowserContext,
chromium,
expect,
test as base,
} from '@playwright/test'
import metamask from '@synthetixio/synpress/commands/metamask.js'
import helpers from '@synthetixio/synpress/helpers.js'
const { initialSetup } = metamask
const { prepareMetamask } = helpers
export const testWithSynpress = base.extend<{
context: BrowserContext
}>({
context: async ({}, use) => {
// required for synpress
global.expect = expect
// download metamask
const metamaskPath = await prepareMetamask(
process.env.METAMASK_VERSION || '10.25.0',
)
// prepare browser args
const browserArgs = [
`--disable-extensions-except=${metamaskPath}`,
`--load-extension=${metamaskPath}`,
'--remote-debugging-port=9222',
]
if (process.env.CI) {
browserArgs.push('--disable-gpu')
}
if (process.env.HEADLESS_MODE) {
browserArgs.push('--headless=new')
}
// launch browser
const context = await chromium.launchPersistentContext('', {
headless: false,
args: browserArgs,
})
// wait for metamask
await context.pages()[0].waitForTimeout(3000)
// setup metamask
await initialSetup(chromium, {
secretWordsOrPrivateKey: process.env.METAMASK_SECRET_WORDS_OR_PRIVATEKEY,
network: process.env.METAMASK_NETWORK,
password: process.env.METAMASK_PASSWORD,
enableAdvancedSettings: true,
})
await use(context)
},
})
export { expect }
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"outDir": "./dist",
"baseUrl": "./src",
"noEmit": true,
"target": "ESNext",
"lib": ["esnext"],
"module": "esnext",
"moduleResolution": "Node",
"isolatedModules": true,
"allowUnreachableCode": false,
"skipLibCheck": false,
"allowUnusedLabels": false,
"alwaysStrict": true,
"exactOptionalPropertyTypes": true,
"noFallthroughCasesInSwitch": true,
"noImplicitAny": true,
"noImplicitReturns": true,
"noImplicitOverride": true,
"noImplicitThis": true,
"forceConsistentCasingInFileNames": true,
"verbatimModuleSyntax": true,
"noPropertyAccessFromIndexSignature": true,
"noUncheckedIndexedAccess": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"strict": true
},
"include": ["./src"]
}
global:
scrape_interval: 5s
scrape_configs:
- job_name: 'pushgateway'
static_configs:
- targets: ['pushgateway:9091']
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment