diff --git a/Makefile b/Makefile index cbb2dafe..7070b13b 100644 --- a/Makefile +++ b/Makefile @@ -2,19 +2,46 @@ include version.mk DOCKER_COMPOSE := docker-compose -f docker-compose.yml DOCKER_COMPOSE_STATE_DB := xgon-state-db +DOCKER_COMPOSE_EVENT_DB := xgon-event-db DOCKER_COMPOSE_POOL_DB := xgon-pool-db DOCKER_COMPOSE_RPC_DB := xgon-rpc-db DOCKER_COMPOSE_BRIDGE_DB := xgon-bridge-db +DOCKER_COMPOSE_DAC_DB := xgon-data-availability-db +DOCKER_COMPOSE_REDIS := xgon-bridge-redis DOCKER_COMPOSE_ZKEVM_NODE := xgon-node + +DOCKER_COMPOSE_SEQ := xgon-sequencer +DOCKER_COMPOSE_SEQ_SENDER := xgon-sequence-sender +DOCKER_COMPOSE_L2_GASP := xgon-l2gaspricer +DOCKER_COMPOSE_AGG := xgon-aggregator +DOCKER_COMPOSE_RPC := xgon-json-rpc +DOCKER_COMPOSE_SYNC := xgon-sync +DOCKER_COMPOSE_ETH_TX_MANAGER := xgon-eth-tx-manager + DOCKER_COMPOSE_L1_NETWORK := xgon-mock-l1-network DOCKER_COMPOSE_ZKPROVER := xgon-prover DOCKER_COMPOSE_BRIDGE := xgon-bridge-service +DOCKER_COMPOSE_DA_NODE := xgon-data-availability +DOCKER_COMPOSE_COIN_KAFKA_NODE := xgon-bridge-coin-kafka +DOCKER_COMPOSE_ZOOKEEPER := kafka-zookeeper RUN_STATE_DB := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_STATE_DB) +RUN_EVENT_DB := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_EVENT_DB) RUN_POOL_DB := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_POOL_DB) RUN_BRIDGE_DB := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_BRIDGE_DB) -RUN_DBS := ${RUN_BRIDGE_DB} && ${RUN_STATE_DB} && ${RUN_POOL_DB} -RUN_NODE := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_ZKEVM_NODE) +RUN_DAC_DB := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_DAC_DB) +RUN_REDIS := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_REDIS) +RUN_DBS := ${RUN_BRIDGE_DB} && ${RUN_STATE_DB} && ${RUN_EVENT_DB} && ${RUN_POOL_DB} && ${RUN_DAC_DB} +RUN_DA := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_DA_NODE) +RUN_COIN_KAFKA := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_COIN_KAFKA_NODE) +RUN_ZOOKEEPER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_ZOOKEEPER) +RUN_SEQUENCER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_SEQ) +RUN_SEQUENCE_SENDER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_SEQ_SENDER) +RUN_L2_GAS_PRICER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_L2_GASP) +RUN_AGGREGATOR := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_AGG) +RUN_JSON_RPC := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_RPC) +RUN_SYNC := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_SYNC) +RUN_ETH_TX_MANAGER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_ETH_TX_MANAGER) RUN_L1_NETWORK := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_L1_NETWORK) RUN_ZKPROVER := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_ZKPROVER) RUN_BRIDGE := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_BRIDGE) @@ -22,7 +49,13 @@ RUN_BRIDGE := $(DOCKER_COMPOSE) up -d $(DOCKER_COMPOSE_BRIDGE) STOP_NODE_DB := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_NODE_DB) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_NODE_DB) STOP_BRIDGE_DB := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_BRIDGE_DB) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_BRIDGE_DB) STOP_DBS := ${STOP_NODE_DB} && ${STOP_BRIDGE_DB} -STOP_NODE := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_ZKEVM_NODE) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_ZKEVM_NODE) +STOP_SEQUENCER := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_SEQ) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_SEQ) +STOP_SEQUENCE_SENDER := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_SEQ_SENDER) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_SEQ_SENDER) +STOP_L2_GAS_PRICER := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_L2_GASP) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_L2_GASP) +STOP_AGGREGATOR := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_AGG) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_AGG) +STOP_JSON_RPC := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_RPC) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_RPC) +STOP_SYNC := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_SYNC) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_SYNC) +STOP_ETH_TX_MANAGER := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_ETH_TX_MANAGER) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_ETH_TX_MANAGER) STOP_NETWORK := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_L1_NETWORK) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_L1_NETWORK) STOP_ZKPROVER := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_ZKPROVER) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_ZKPROVER) STOP_BRIDGE := $(DOCKER_COMPOSE) stop $(DOCKER_COMPOSE_BRIDGE) && $(DOCKER_COMPOSE) rm -f $(DOCKER_COMPOSE_BRIDGE) @@ -94,11 +127,24 @@ stop-dbs: ## Stops the node database .PHONY: run-node run-node: ## Runs the node - $(RUN_NODE) + $(RUN_ETH_TX_MANAGER) + $(RUN_SYNC) + sleep 2 + $(RUN_SEQUENCER) + $(RUN_SEQUENCE_SENDER) + $(RUN_L2_GAS_PRICER) + $(RUN_AGGREGATOR) + $(RUN_JSON_RPC) .PHONY: stop-node stop-node: ## Stops the node - $(STOP_NODE) + $(STOP_SEQUENCER) + $(STOP_SEQUENCE_SENDER) + $(STOP_JSON_RPC) + $(STOP_L2_GAS_PRICER) + $(STOP_AGGREGATOR) + $(STOP_SYNC) + $(STOP_ETH_TX_MANAGER) .PHONY: run-network run-network: ## Runs the l1 network @@ -134,11 +180,24 @@ restart: stop run ## Executes `make stop` and `make run` commands .PHONY: run run: stop ## runs all services $(RUN_DBS) + $(RUN_REDIS) + $(RUN_ZOOKEEPER) + sleep 3 + $(RUN_COIN_KAFKA) $(RUN_L1_NETWORK) sleep 5 $(RUN_ZKPROVER) sleep 3 - $(RUN_NODE) + $(RUN_DA) + sleep 3 + $(RUN_SYNC) + sleep 2 + $(RUN_ETH_TX_MANAGER) + $(RUN_SEQUENCER) + $(RUN_SEQUENCE_SENDER) + $(RUN_L2_GAS_PRICER) + $(RUN_AGGREGATOR) + $(RUN_JSON_RPC) sleep 7 $(RUN_BRIDGE) @@ -172,12 +231,12 @@ bench-full: ## benchmark full test .PHONY: test-full test-full: build-docker stop run ## Runs all tests checking race conditions sleep 3 - trap '$(STOP)' EXIT; MallocNanoZone=0 go test -race -p 1 -timeout 2400s ./test/e2e/... -count 1 -tags='e2e' + trap 'docker logs $(DOCKER_COMPOSE_BRIDGE); $(STOP)' EXIT; MallocNanoZone=0 go test -race -p 1 -timeout 2400s ./test/e2e/... -count 1 -tags='e2e' .PHONY: test-edge test-edge: build-docker stop run ## Runs all tests checking race conditions sleep 3 - trap '$(STOP)' EXIT; MallocNanoZone=0 go test -race -p 1 -timeout 2400s ./test/e2e/... -count 1 -tags='edge' + trap 'docker logs $(DOCKER_COMPOSE_BRIDGE); $(STOP)' EXIT; MallocNanoZone=0 go test -race -p 1 -timeout 2400s ./test/e2e/... -count 1 -tags='edge' .PHONY: validate validate: lint build test-full ## Validates the whole integrity of the code base diff --git a/cmd/run.go b/cmd/run.go index a17be51a..ed0eafaa 100644 --- a/cmd/run.go +++ b/cmd/run.go @@ -4,16 +4,15 @@ import ( "os" "os/signal" - "github.com/0xPolygonHermez/zkevm-bridge-service/coinmiddleware" - "github.com/0xPolygonHermez/zkevm-bridge-service/localcache" - "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" - "github.com/0xPolygonHermez/zkevm-bridge-service/sentinel" - "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl" "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman" + "github.com/0xPolygonHermez/zkevm-bridge-service/coinmiddleware" "github.com/0xPolygonHermez/zkevm-bridge-service/config" "github.com/0xPolygonHermez/zkevm-bridge-service/db" "github.com/0xPolygonHermez/zkevm-bridge-service/etherman" + "github.com/0xPolygonHermez/zkevm-bridge-service/localcache" + "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" + "github.com/0xPolygonHermez/zkevm-bridge-service/sentinel" "github.com/0xPolygonHermez/zkevm-bridge-service/server" "github.com/0xPolygonHermez/zkevm-bridge-service/synchronizer" "github.com/0xPolygonHermez/zkevm-bridge-service/utils/gerror" @@ -171,42 +170,6 @@ func startServer(ctx *cli.Context) error { return nil } -func startKafkaConsumer(ctx *cli.Context) error { - c, err := initCommon(ctx) - if err != nil { - return err - } - - redisStorage, err := redisstorage.NewRedisStorage(c.BridgeServer.Redis) - if err != nil { - log.Error(err) - return err - } - - // Start the coin middleware kafka consumer - log.Debugf("start initializing kafka consumer...") - coinKafkaConsumer, err := coinmiddleware.NewKafkaConsumer(c.CoinKafkaConsumer, redisStorage) - if err != nil { - log.Error(err) - return err - } - log.Debugf("finish initializing kafka consumer") - go coinKafkaConsumer.Start(ctx.Context) - defer func() { - err := coinKafkaConsumer.Close() - if err != nil { - log.Errorf("close kafka consumer error: %v", err) - } - }() - - // Wait for an in interrupt. - ch := make(chan os.Signal, 1) - signal.Notify(ch, os.Interrupt) - <-ch - - return nil -} - func initCommon(ctx *cli.Context) (*config.Config, error) { configFilePath := ctx.String(flagCfg) network := ctx.String(flagNetwork) diff --git a/coinmiddleware/handler.go b/coinmiddleware/handler.go index 77296897..e8bc29ad 100644 --- a/coinmiddleware/handler.go +++ b/coinmiddleware/handler.go @@ -3,12 +3,13 @@ package coinmiddleware import ( "context" "encoding/json" + "time" + "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" "github.com/0xPolygonHermez/zkevm-node/log" "github.com/IBM/sarama" "github.com/pkg/errors" - "time" ) const ( diff --git a/coinmiddleware/kafkaconsumer.go b/coinmiddleware/kafkaconsumer.go index 1bd66aad..f758b951 100644 --- a/coinmiddleware/kafkaconsumer.go +++ b/coinmiddleware/kafkaconsumer.go @@ -4,16 +4,17 @@ import ( "context" "crypto/tls" "crypto/x509" + "os" + "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" "github.com/0xPolygonHermez/zkevm-node/log" "github.com/IBM/sarama" "github.com/pkg/errors" - "os" ) // KafkaConsumer provides the interface to consume from coin middleware kafka type KafkaConsumer interface { - Start(ctx context.Context) error + Start(ctx context.Context) Close() error } @@ -45,7 +46,7 @@ func NewKafkaConsumer(cfg Config, redisStorage redisstorage.RedisStorage) (Kafka } config.Net.TLS.Enable = true - config.Net.TLS.Config = &tls.Config{RootCAs: caCertPool, InsecureSkipVerify: true} + config.Net.TLS.Config = &tls.Config{RootCAs: caCertPool, InsecureSkipVerify: true} // #nosec } client, err := sarama.NewConsumerGroup(cfg.Brokers, cfg.ConsumerGroupID, config) @@ -60,7 +61,7 @@ func NewKafkaConsumer(cfg Config, redisStorage redisstorage.RedisStorage) (Kafka }, nil } -func (c *kafkaConsumerImpl) Start(ctx context.Context) error { +func (c *kafkaConsumerImpl) Start(ctx context.Context) { log.Debug("starting kafka consumer") ctx, cancel := context.WithCancel(ctx) defer cancel() @@ -70,14 +71,18 @@ func (c *kafkaConsumerImpl) Start(ctx context.Context) error { err := c.client.Consume(ctx, c.topics, c.handler) if err != nil { log.Errorf("kafka consumer error: %v", err) - if errors.Is(err, sarama.ErrClosedConsumerGroup) { - err = nil - } - return errors.Wrap(err, "kafka consumer error") + //if errors.Is(err, sarama.ErrClosedConsumerGroup) { + // err = nil + //} + //err = errors.Wrap(err, "kafka consumer error") + //panic(err) + return } if err = ctx.Err(); err != nil { log.Errorf("kafka consumer ctx error: %v", err) - return errors.Wrap(err, "kafka consumer ctx error") + //err = errors.Wrap(err, "kafka consumer ctx error") + //panic(err) + return } } } diff --git a/config/config.debug.toml b/config/config.debug.toml index 34428be1..3c79ef21 100644 --- a/config/config.debug.toml +++ b/config/config.debug.toml @@ -68,9 +68,9 @@ RootCAPath = "/app/root-ca-cert" [NetworkConfig] GenBlockNumber = 1 -PolygonBridgeAddress = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" -PolygonZkEVMGlobalExitRootAddress = "0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6" -L2PolygonBridgeAddresses = ["0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0"] +PolygonBridgeAddress = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" +PolygonZkEVMGlobalExitRootAddress = "0xEd236da21Ff62bC7B62608AdB818da49E8549fa7" +L2PolygonBridgeAddresses = ["0x10B65c586f795aF3eCCEe594fE4E38E1F059F780"] [NacosConfig] NacosUrls = "" diff --git a/config/config.go b/config/config.go index 64244b6f..b7654a1b 100644 --- a/config/config.go +++ b/config/config.go @@ -4,15 +4,15 @@ import ( "bytes" "encoding/json" "errors" - "github.com/0xPolygonHermez/zkevm-bridge-service/coinmiddleware" - "github.com/0xPolygonHermez/zkevm-bridge-service/nacos" "path/filepath" "strings" "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl" "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman" + "github.com/0xPolygonHermez/zkevm-bridge-service/coinmiddleware" "github.com/0xPolygonHermez/zkevm-bridge-service/db" "github.com/0xPolygonHermez/zkevm-bridge-service/etherman" + "github.com/0xPolygonHermez/zkevm-bridge-service/nacos" "github.com/0xPolygonHermez/zkevm-bridge-service/server" "github.com/0xPolygonHermez/zkevm-bridge-service/synchronizer" "github.com/0xPolygonHermez/zkevm-node/log" diff --git a/config/config.local.toml b/config/config.local.toml index ce4b585d..4b374f30 100644 --- a/config/config.local.toml +++ b/config/config.local.toml @@ -22,7 +22,7 @@ FreeGas = true [Etherman] L1URL = "http://xgon-mock-l1-network:8545" -L2URLs = ["http://xgon-node:8123"] +L2URLs = ["http://xgon-json-rpc:8123"] L1ChainId = 5 L2ChainIds = [1001] @@ -69,9 +69,9 @@ RootCAPath = "/app/root-ca-cert" [NetworkConfig] GenBlockNumber = 1 -PolygonBridgeAddress = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" -PolygonZkEVMGlobalExitRootAddress = "0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6" -L2PolygonBridgeAddresses = ["0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0"] +PolygonBridgeAddress = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" +PolygonZkEVMGlobalExitRootAddress = "0xEd236da21Ff62bC7B62608AdB818da49E8549fa7" +L2PolygonBridgeAddresses = ["0x10B65c586f795aF3eCCEe594fE4E38E1F059F780"] [NacosConfig] NacosUrls = "" diff --git a/config/network.go b/config/network.go index b12b165a..60e1b400 100644 --- a/config/network.go +++ b/config/network.go @@ -41,9 +41,9 @@ var ( }, "local": { GenBlockNumber: 1, - PolygonBridgeAddress: common.HexToAddress("0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0"), - PolygonZkEVMGlobalExitRootAddress: common.HexToAddress("0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6"), - L2PolygonBridgeAddresses: []common.Address{common.HexToAddress("0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0")}, + PolygonBridgeAddress: common.HexToAddress("0x10B65c586f795aF3eCCEe594fE4E38E1F059F780"), + PolygonZkEVMGlobalExitRootAddress: common.HexToAddress("0xEd236da21Ff62bC7B62608AdB818da49E8549fa7"), + L2PolygonBridgeAddresses: []common.Address{common.HexToAddress("0x10B65c586f795aF3eCCEe594fE4E38E1F059F780")}, }, } ) diff --git a/db/pgstorage/migrations/0006.sql b/db/pgstorage/migrations/0006.sql index 3a1aa3da..3a4a4c31 100644 --- a/db/pgstorage/migrations/0006.sql +++ b/db/pgstorage/migrations/0006.sql @@ -1,5 +1,5 @@ -- +migrate Down -DROP SCHEMA IF EXISTS common; +DROP SCHEMA IF EXISTS common CASCADE; -- +migrate Up CREATE SCHEMA IF NOT EXISTS common; diff --git a/db/pgstorage/pgstorage.go b/db/pgstorage/pgstorage.go index a1205a77..2ac9d92d 100644 --- a/db/pgstorage/pgstorage.go +++ b/db/pgstorage/pgstorage.go @@ -4,10 +4,10 @@ import ( "context" "errors" "fmt" - "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" "math/big" "time" + "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" ctmtypes "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman/types" "github.com/0xPolygonHermez/zkevm-bridge-service/etherman" "github.com/0xPolygonHermez/zkevm-bridge-service/utils/gerror" diff --git a/docker-compose.yml b/docker-compose.yml index 63e00ff2..5c700e69 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,5 +1,123 @@ -version: '3.5' +version: "3.5" +networks: + default: + name: xgon + services: + xgon-sequencer: + container_name: xgon-sequencer + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + ports: + - 9092:9091 # needed if metrics enabled + - 6060:6060 + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + - ZKEVM_NODE_POOL_DB_HOST=xgon-pool-db + volumes: + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components sequencer" + + xgon-sequence-sender: + container_name: xgon-sequence-sender + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + - ZKEVM_NODE_POOL_DB_HOST=xgon-pool-db + - ZKEVM_NODE_SEQUENCER_SENDER_ADDRESS=0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266 + volumes: + - ./test/test.keystore.sequencer:/pk/sequencer.keystore + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components sequence-sender" + + xgon-json-rpc: + container_name: xgon-json-rpc + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + ports: + - 8123:8123 + - 8133:8133 # needed if WebSockets enabled + - 9091:9091 # needed if metrics enabled + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + - ZKEVM_NODE_POOL_DB_HOST=xgon-pool-db + volumes: + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components rpc" + + xgon-aggregator: + container_name: xgon-aggregator + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + ports: + - 50081:50081 + - 9093:9091 # needed if metrics enabled + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + - ZKEVM_NODE_AGGREGATOR_SENDER_ADDRESS=0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266 + volumes: + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components aggregator" + + xgon-sync: + container_name: xgon-sync + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + ports: + - 9095:9091 # needed if metrics enabled + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + volumes: + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components synchronizer" + + xgon-eth-tx-manager: + container_name: xgon-eth-tx-manager + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + ports: + - 9094:9091 # needed if metrics enabled + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + volumes: + - ./test/test.keystore.sequencer:/pk/sequencer.keystore + - ./test/test.keystore.aggregator:/pk/aggregator.keystore + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components eth-tx-manager" + + xgon-l2gaspricer: + container_name: xgon-l2gaspricer + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + environment: + - ZKEVM_NODE_POOL_DB_HOST=xgon-pool-db + volumes: + - ./test/test.keystore.sequencer:/pk/keystore + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node run --network custom --custom-network-file /app/genesis.json --cfg /app/config.toml --components l2gaspricer" + xgon-state-db: container_name: xgon-state-db image: postgres @@ -12,12 +130,15 @@ services: ports: - 5432:5432 volumes: - - ./test/config/prover/initproverdb.sql:/docker-entrypoint-initdb.d/init.sql + - ./test/config/prover/init_prover_db.sql:/docker-entrypoint-initdb.d/init.sql environment: - POSTGRES_USER=state_user - POSTGRES_PASSWORD=state_password - POSTGRES_DB=state_db - command: ["postgres", "-N", "500"] + command: + - "postgres" + - "-N" + - "500" xgon-pool-db: container_name: xgon-pool-db @@ -34,7 +155,116 @@ services: - POSTGRES_USER=pool_user - POSTGRES_PASSWORD=pool_password - POSTGRES_DB=pool_db - command: ["postgres", "-N", "500"] + command: + - "postgres" + - "-N" + - "500" + + xgon-event-db: + container_name: xgon-event-db + image: postgres + deploy: + resources: + limits: + memory: 2G + reservations: + memory: 1G + ports: + - 5436:5432 + volumes: + - ./test/config/node/init_event_db.sql:/docker-entrypoint-initdb.d/init.sql + environment: + - POSTGRES_USER=event_user + - POSTGRES_PASSWORD=event_password + - POSTGRES_DB=event_db + command: + - "postgres" + - "-N" + - "500" + + xgon-mock-l1-network: + container_name: xgon-mock-l1-network + image: okexchain/xgon-geth:e2e_v0.1.0_20231030 + ports: + - 8545:8545 + - 8546:8546 + command: + - "--http" + - "--http.api" + - "admin,eth,debug,miner,net,txpool,personal,web3" + - "--http.addr" + - "0.0.0.0" + - "--http.corsdomain" + - "*" + - "--http.vhosts" + - "*" + - "--ws" + - "--ws.origins" + - "*" + - "--ws.addr" + - "0.0.0.0" + - "--dev" + - "--dev.period" + - "1" + - "--datadir" + - "/geth_data" + - "--syncmode" + - "full" + - "--rpc.allow-unprotected-txs" + + xgon-prover: + container_name: xgon-prover + image: hermeznetwork/zkevm-prover:v2.2.0 + ports: + # - 50051:50051 # Prover + - 50052:50052 # Mock prover + - 50061:50061 # MT + - 50071:50071 # Executor + volumes: + - ./test/config/prover/test.prover.config.json:/usr/src/app/config.json + command: > + zkProver -c /usr/src/app/config.json + + xgon-approve: + container_name: xgon-approve + image: okexchain/xgon-node:e2e_v0.1.0_20231030 + environment: + - ZKEVM_NODE_STATEDB_HOST=xgon-state-db + volumes: + - ./test/test.keystore.sequencer:/pk/keystore + - ./test/config/node/test.node.config.toml:/app/config.toml + - ./test/config/node/test.genesis.config.json:/app/genesis.json + command: + - "/bin/sh" + - "-c" + - "/app/xgon-node approve --network custom --custom-network-file /app/genesis.json --key-store-path /pk/keystore --pw testonly --am 115792089237316195423570985008687907853269984665640564039457584007913129639935 -y --cfg /app/config.toml" + + xgon-data-availability: + container_name: xgon-data-availability + image: okexchain/xgon-data-availability:e2e_v0.1.0_20231030 + ports: + - 8444:8444 + volumes: + - ./test/config/node/test.da.toml:/app/config.toml + - ./test/test.keystore.da:/pk/test-member.keystore + command: + - "/bin/sh" + - "-c" + - "/app/xgon-data-availability run --cfg /app/config.toml" + + xgon-data-availability-db: + container_name: xgon-data-availability-db + image: postgres + ports: + - 5438:5432 + environment: + - POSTGRES_USER=committee_user + - POSTGRES_PASSWORD=committee_password + - POSTGRES_DB=committee_db + command: + - "postgres" + - "-N" + - "500" xgon-bridge-db: container_name: xgon-bridge-db @@ -94,47 +324,6 @@ services: KAFKA_ZOOKEEPER_CONNECT: kafka-zookeeper:2181 KAFKA_CREATE_TOPICS: "explorer_chainAddressPrice_push:1:1" - zkevm-node: - container_name: zkevm-node - image: hermeznetwork/zkevm-node:v0.0.7 - ports: - - 8123:8123 - - 61090:61090 - environment: - - ZKEVM_NODE_STATEDB_HOST=zkevm-state-db - - ZKEVM_NODE_POOL_HOST=zkevm-pool-db - - ZKEVM_NODE_RPC_DB_HOST=zkevm-rpc-db - - ZKEVM_NODE_ETHERMAN_PRIVATEKEYPATH=/pk/keystore - volumes: - - ./test/test.keystore.sequencer:/pk/keystore.sequencer - - ./test/test.keystore.aggregator:/pk/keystore.aggregator - - ./test/config/node/config.zkevm.node.toml:/app/config.toml - - ./test/config/node/genesis.local.json:/app/genesis.json - command: - - "/bin/sh" - - "-c" - - "/app/zkevm-node approve --am 115792089237316195423570985008687907853269984665640564039457584007913129639935 -y --cfg /app/config.toml --key-store-path /pk/keystore.sequencer --password testonly && - /app/zkevm-node run --genesis /app/genesis.json --cfg /app/config.toml --components \"synchronizer,rpc,sequencer,aggregator,eth-tx-manager,l2gaspricer\"" - - zkevm-mock-l1-network: - container_name: zkevm-local-l1-network - image: hermeznetwork/geth-zkevm-contracts:v1.1.0-fork.4 - ports: - - 8545:8545 - - zkevm-prover: - container_name: zkevm-prover - image: hermeznetwork/zkevm-prover:c231382 - ports: - - 50051:50051 # Prover - - 50052:50052 # MockProver - - 50061:50061 # MT - - 50071:50071 # Executor - volumes: - - ./test/config/prover/config.prover.json:/usr/src/app/config.json - command: > - zkProver -c /usr/src/app/config.json - xgon-bridge-service: container_name: xgon-bridge-service image: xgon-bridge-service @@ -155,4 +344,4 @@ services: command: - "/bin/sh" - "-c" - - "/app/xgon-bridge run --cfg /app/config.toml" \ No newline at end of file + - "/app/xgon-bridge run --cfg /app/config.toml" diff --git a/docs/running_local.md b/docs/running_local.md index 8693d94b..91d1e4f7 100644 --- a/docs/running_local.md +++ b/docs/running_local.md @@ -71,11 +71,18 @@ make test-edge | Address | Description | |---|---| -| 0x610178dA211FEF7D417bC0e6FeD39F05609AD788 | Proof of Efficiency | -| 0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0 | L1 Bridge | -| 0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0 | L2 Bridge | -| 0x5FbDB2315678afecb367f032d93F642f64180aa3 | Matic token | -| 0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6 | GlobalExitRootManager | +| 0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C | Proof of Efficiency | +| 0x10B65c586f795aF3eCCEe594fE4E38E1F059F780 | L1 Bridge | +| 0x10B65c586f795aF3eCCEe594fE4E38E1F059F780 | L2 Bridge | +| 0xcFE6D77a653b988203BfAc9C6a69eA9D583bdC2b | Matic token | +| 0x82109a709138A2953C720D3d775168717b668ba6 | L1 OKB token | +| 0x82109a709138A2953C720D3d775168717b668ba6 | L2 WETH token | +| 0xEd236da21Ff62bC7B62608AdB818da49E8549fa7 | GlobalExitRootManager | + +## Admin Account +| Address | Private Key | +|---|---| +| 0x2ECF31eCe36ccaC2d3222A303b1409233ECBB225 | 0xde3ca643a52f5543e84ba984c4419ff40dbabd0e483c31c1d09fee8168d68e38 | ## Fund account on L2 with ETH diff --git a/etherman/etherman.go b/etherman/etherman.go index cda4382e..dd8ca198 100644 --- a/etherman/etherman.go +++ b/etherman/etherman.go @@ -194,6 +194,7 @@ func (etherMan *Client) updateGlobalExitRootEvent(ctx context.Context, vLog type gExitRoot.ExitRoots = append(gExitRoot.ExitRoots, common.BytesToHash(globalExitRoot.RollupExitRoot[:])) gExitRoot.GlobalExitRoot = hash(globalExitRoot.MainnetExitRoot, globalExitRoot.RollupExitRoot) gExitRoot.BlockNumber = vLog.BlockNumber + log.Debugf("UpdateGlobalExitRoot event[%+v] blockNumber[%v]", gExitRoot, vLog.BlockNumber) if len(*blocks) == 0 || ((*blocks)[len(*blocks)-1].BlockHash != vLog.BlockHash || (*blocks)[len(*blocks)-1].BlockNumber != vLog.BlockNumber) { t := time.Unix(int64(fullBlock.Time()), 0) @@ -231,6 +232,7 @@ func (etherMan *Client) depositEvent(ctx context.Context, vLog types.Log, blocks deposit.TxHash = vLog.TxHash deposit.Metadata = d.Metadata deposit.LeafType = d.LeafType + log.Debugf("Deposit event[%+v] blockNumber[%v]", deposit, vLog.BlockNumber) if len(*blocks) == 0 || ((*blocks)[len(*blocks)-1].BlockHash != vLog.BlockHash || (*blocks)[len(*blocks)-1].BlockNumber != vLog.BlockNumber) { fullBlock, err := etherMan.EtherClient.BlockByHash(ctx, vLog.BlockHash) @@ -268,6 +270,7 @@ func (etherMan *Client) claimEvent(ctx context.Context, vLog types.Log, blocks * claim.OriginalAddress = c.OriginAddress claim.BlockNumber = vLog.BlockNumber claim.TxHash = vLog.TxHash + log.Debugf("Claim event[%+v] blockNumber[%v]", claim, vLog.BlockNumber) if len(*blocks) == 0 || ((*blocks)[len(*blocks)-1].BlockHash != vLog.BlockHash || (*blocks)[len(*blocks)-1].BlockNumber != vLog.BlockNumber) { fullBlock, err := etherMan.EtherClient.BlockByHash(ctx, vLog.BlockHash) @@ -302,6 +305,7 @@ func (etherMan *Client) tokenWrappedEvent(ctx context.Context, vLog types.Log, b tokenWrapped.OriginalTokenAddress = tw.OriginTokenAddress tokenWrapped.WrappedTokenAddress = tw.WrappedTokenAddress tokenWrapped.BlockNumber = vLog.BlockNumber + log.Debugf("TokenWrapped event[%+v] blockNumber[%v]", tokenWrapped, vLog.BlockNumber) if len(*blocks) == 0 || ((*blocks)[len(*blocks)-1].BlockHash != vLog.BlockHash || (*blocks)[len(*blocks)-1].BlockNumber != vLog.BlockNumber) { fullBlock, err := etherMan.EtherClient.BlockByHash(ctx, vLog.BlockHash) diff --git a/etherman/etherman_test.go b/etherman/etherman_test.go index c93a9019..38884d54 100644 --- a/etherman/etherman_test.go +++ b/etherman/etherman_test.go @@ -32,7 +32,7 @@ func newTestingEnv() (ethman *Client, ethBackend *backends.SimulatedBackend, aut if err != nil { log.Fatal(err) } - ethman, ethBackend, maticAddr, bridge, err = NewSimulatedEtherman(Config{}, auth) + ethman, ethBackend, maticAddr, bridge, _, err = NewSimulatedEtherman(Config{}, auth) if err != nil { log.Fatal(err) } diff --git a/etherman/simulated.go b/etherman/simulated.go index 3f27e839..3ead26f3 100644 --- a/etherman/simulated.go +++ b/etherman/simulated.go @@ -6,11 +6,13 @@ import ( "math/big" mockbridge "github.com/0xPolygonHermez/zkevm-bridge-service/test/mocksmartcontracts/polygonzkevmbridge" + "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/datacommittee" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/matic" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/mockverifier" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/polygonzkevm" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/polygonzkevmbridge" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/polygonzkevmglobalexitroot" + "github.com/0xPolygonHermez/zkevm-node/log" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/common" @@ -20,7 +22,7 @@ import ( // NewSimulatedEtherman creates an etherman that uses a simulated blockchain. It's important to notice that the ChainID of the auth // must be 1337. The address that holds the auth will have an initial balance of 10 ETH -func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client, ethBackend *backends.SimulatedBackend, maticAddr common.Address, mockBridge *mockbridge.Polygonzkevmbridge, err error) { +func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client, ethBackend *backends.SimulatedBackend, maticAddr common.Address, mockBridge *mockbridge.Polygonzkevmbridge, da *datacommittee.Datacommittee, err error) { // 10000000 ETH in wei balance, _ := new(big.Int).SetString("10000000000000000000000000", 10) //nolint:gomnd address := auth.From @@ -32,20 +34,37 @@ func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client blockGasLimit := uint64(999999999999999999) //nolint:gomnd client := backends.NewSimulatedBackend(genesisAlloc, blockGasLimit) + // DAC Setup + dataCommitteeAddr, _, da, err := datacommittee.DeployDatacommittee(auth, client) + if err != nil { + log.Errorf("DeployDatacommittee error, %v", err) + return nil, nil, common.Address{}, nil, nil, err + } + _, err = da.Initialize(auth) + if err != nil { + return nil, nil, common.Address{}, nil, nil, err + } + _, err = da.SetupCommittee(auth, big.NewInt(0), []string{}, []byte{}) + if err != nil { + return nil, nil, common.Address{}, nil, nil, err + } + // Deploy contracts const maticDecimalPlaces = 18 totalSupply, _ := new(big.Int).SetString("10000000000000000000000000000", 10) //nolint:gomnd maticAddr, _, maticContract, err := matic.DeployMatic(auth, client, "Matic Token", "MATIC", maticDecimalPlaces, totalSupply) if err != nil { - return nil, nil, common.Address{}, nil, err + log.Errorf("DeployMatic error", err) + return nil, nil, common.Address{}, nil, nil, err } rollupVerifierAddr, _, _, err := mockverifier.DeployMockverifier(auth, client) if err != nil { - return nil, nil, common.Address{}, nil, err + log.Errorf("DeployMockverifier error", err) + return nil, nil, common.Address{}, nil, nil, err } nonce, err := client.PendingNonceAt(context.TODO(), auth.From) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } const posBridge = 1 calculatedBridgeAddr := crypto.CreateAddress(auth.From, nonce+posBridge) @@ -54,23 +73,25 @@ func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client genesis := common.HexToHash("0xfd3434cd8f67e59d73488a2b8da242dd1f02849ea5dd99f0ca22c836c3d5b4a9") // Random value. Needs to be different to 0x0 exitManagerAddr, _, globalExitRoot, err := polygonzkevmglobalexitroot.DeployPolygonzkevmglobalexitroot(auth, client, calculatedPolygonZkEVMAddress, calculatedBridgeAddr) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } bridgeAddr, _, mockbr, err := mockbridge.DeployPolygonzkevmbridge(auth, client) if err != nil { - return nil, nil, common.Address{}, nil, err + log.Errorf("DeployPolygonzkevmbridge error", err) + return nil, nil, common.Address{}, nil, nil, err } - polygonZkEVMAddress, _, polygonZkEVMContract, err := polygonzkevm.DeployPolygonzkevm(auth, client, exitManagerAddr, maticAddr, rollupVerifierAddr, bridgeAddr, bridgeAddr, 1000, 1) //nolint + polygonZkEVMAddress, _, polygonZkEVMContract, err := polygonzkevm.DeployPolygonzkevm(auth, client, exitManagerAddr, maticAddr, rollupVerifierAddr, bridgeAddr, dataCommitteeAddr, 1000, 1) //nolint if err != nil { - return nil, nil, common.Address{}, nil, err + log.Errorf("DeployPolygonzkevm error", err) + return nil, nil, common.Address{}, nil, nil, err } _, err = mockbr.Initialize(auth, 0, exitManagerAddr, polygonZkEVMAddress) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } br, err := polygonzkevmbridge.NewPolygonzkevmbridge(bridgeAddr, client) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } polygonZkEVMParams := polygonzkevm.PolygonZkEVMInitializePackedParameters{ Admin: auth.From, @@ -81,15 +102,15 @@ func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client } _, err = polygonZkEVMContract.Initialize(auth, polygonZkEVMParams, genesis, "http://localhost", "L2", "v1") //nolint:gomnd if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } if calculatedBridgeAddr != bridgeAddr { - return nil, nil, common.Address{}, nil, fmt.Errorf("bridgeAddr (%s) is different from the expected contract address (%s)", + return nil, nil, common.Address{}, nil, nil, fmt.Errorf("bridgeAddr (%s) is different from the expected contract address (%s)", bridgeAddr.String(), calculatedBridgeAddr.String()) } if calculatedPolygonZkEVMAddress != polygonZkEVMAddress { - return nil, nil, common.Address{}, nil, fmt.Errorf("polygonZkEVMAddress (%s) is different from the expected contract address (%s)", + return nil, nil, common.Address{}, nil, nil, fmt.Errorf("polygonZkEVMAddress (%s) is different from the expected contract address (%s)", polygonZkEVMAddress.String(), calculatedPolygonZkEVMAddress.String()) } @@ -97,17 +118,17 @@ func NewSimulatedEtherman(cfg Config, auth *bind.TransactOpts) (etherman *Client approvedAmount, _ := new(big.Int).SetString("10000000000000000000000", 10) //nolint:gomnd _, err = maticContract.Approve(auth, bridgeAddr, approvedAmount) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } _, err = maticContract.Approve(auth, polygonZkEVMAddress, approvedAmount) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } _, err = polygonZkEVMContract.ActivateForceBatches(auth) if err != nil { - return nil, nil, common.Address{}, nil, err + return nil, nil, common.Address{}, nil, nil, err } client.Commit() - return &Client{EtherClient: client, PolygonBridge: br, PolygonZkEVMGlobalExitRoot: globalExitRoot, SCAddresses: []common.Address{exitManagerAddr, bridgeAddr}}, client, maticAddr, mockbr, nil + return &Client{EtherClient: client, PolygonBridge: br, PolygonZkEVMGlobalExitRoot: globalExitRoot, SCAddresses: []common.Address{exitManagerAddr, bridgeAddr}}, client, maticAddr, mockbr, nil, nil } diff --git a/go.mod b/go.mod index a39763ac..4e1b5b7d 100644 --- a/go.mod +++ b/go.mod @@ -34,8 +34,8 @@ require ( github.com/DataDog/zstd v1.5.2 // indirect github.com/Microsoft/go-winio v0.6.1 // indirect github.com/ProtonMail/go-crypto v0.0.0-20230717121422-5aa5874ade95 // indirect - github.com/StackExchange/wmi v0.0.0-20190523213315-cbe66965904d // indirect - github.com/VictoriaMetrics/fastcache v1.6.0 // indirect + github.com/StackExchange/wmi v1.2.1 // indirect + github.com/VictoriaMetrics/fastcache v1.8.0 // indirect github.com/acomagu/bufpipe v1.0.4 // indirect github.com/aliyun/alibaba-cloud-sdk-go v1.61.18 // indirect github.com/allegro/bigcache v1.2.1 // indirect @@ -111,7 +111,7 @@ require ( github.com/jcmturner/gofork v1.7.6 // indirect github.com/jcmturner/gokrb5/v8 v8.4.4 // indirect github.com/jcmturner/rpc/v2 v2.0.3 // indirect - github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af // indirect + github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/karrick/godirwalk v1.17.0 // indirect github.com/kevinburke/ssh_config v1.2.0 // indirect @@ -159,7 +159,7 @@ require ( github.com/tyler-smith/go-bip39 v1.1.0 // indirect github.com/umbracle/ethgo v0.1.4-0.20230712173909-df37dddf16f0 // indirect github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 // indirect - github.com/valyala/fastjson v1.4.1 // indirect + github.com/valyala/fastjson v1.6.3 // indirect github.com/xanzy/ssh-agent v0.3.3 // indirect github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect go.uber.org/atomic v1.9.0 // indirect @@ -184,4 +184,4 @@ require ( rsc.io/tmplfunc v0.0.3 // indirect ) -replace github.com/0xPolygonHermez/zkevm-node => github.com/okx/Xgon-node v0.2.6-RC3.0.20231017042525-466fd315d92a +replace github.com/0xPolygonHermez/zkevm-node => github.com/okx/Xgon-node v0.2.6-RC3.0.20231031041345-362031125530 diff --git a/go.sum b/go.sum index 6652baa6..947b9508 100644 --- a/go.sum +++ b/go.sum @@ -66,10 +66,11 @@ github.com/ProtonMail/go-crypto v0.0.0-20230717121422-5aa5874ade95/go.mod h1:EjA github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= -github.com/StackExchange/wmi v0.0.0-20190523213315-cbe66965904d h1:G0m3OIz70MZUWq3EgK3CesDbo8upS2Vm9/P3FtgI+Jk= github.com/StackExchange/wmi v0.0.0-20190523213315-cbe66965904d/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg= -github.com/VictoriaMetrics/fastcache v1.6.0 h1:C/3Oi3EiBCqufydp1neRZkqcwmEiuRT9c3fqvvgKm5o= -github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= +github.com/StackExchange/wmi v1.2.1 h1:VIkavFPXSjcnS+O8yTq7NI32k0R5Aj+v39y29VYDOSA= +github.com/StackExchange/wmi v1.2.1/go.mod h1:rcmrprowKIVzvc+NUiLncP2uuArMWLCbu9SBzvHz7e8= +github.com/VictoriaMetrics/fastcache v1.8.0 h1:ybZqS7kRy8YVzYsI09GLzQhs7iqS6cOEH2avtknD1SU= +github.com/VictoriaMetrics/fastcache v1.8.0/go.mod h1:n7Sl+ioh/HlWeYHLSIBIE8TcZFHg/+xgvomWSS5xuEE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= github.com/acomagu/bufpipe v1.0.4 h1:e3H4WUzM3npvo5uv95QuJM3cQspFNtFBzvJ2oNjKIDQ= github.com/acomagu/bufpipe v1.0.4/go.mod h1:mxdxdup/WdsKVreO5GpW4+M/1CE2sMG4jeGJ2sYmHc4= @@ -104,7 +105,7 @@ github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQ github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= -github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= +github.com/benbjohnson/clock v1.3.0 h1:ip6w0uFQkncKQ979AypyG0ER7mqUSBdKLOgAle/AT8A= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -129,6 +130,7 @@ github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA github.com/cespare/cp v1.1.1 h1:nCb6ZLdB7NRaqsm91JtQTAme2SKJzXVsdPIPkyJr1MU= github.com/cespare/cp v1.1.1/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= @@ -337,8 +339,8 @@ github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= -github.com/golang/mock v1.5.0 h1:jlYHihg//f7RRwuPfptm04yp4s7O6Kw8EZiVYIGcH0g= github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= +github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -359,7 +361,6 @@ github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiu github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= @@ -557,8 +558,11 @@ github.com/jcmturner/gokrb5/v8 v8.4.4 h1:x1Sv4HaTpepFkXbt2IkL29DXRf8sOfZXo8eRKh6 github.com/jcmturner/gokrb5/v8 v8.4.4/go.mod h1:1btQEpgT6k+unzCwX1KdWMEwPPkkgBtP+F6aCACiMrs= github.com/jcmturner/rpc/v2 v2.0.3 h1:7FXXj8Ti1IaVFpSAziCZWNzbNuZmnvw/i6CqLNdWfZY= github.com/jcmturner/rpc/v2 v2.0.3/go.mod h1:VUJYCIDm3PVOEHw8sgt091/20OJjskO/YJki3ELg/Hc= -github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af h1:pmfjZENx5imkbgOkpRUYLnmbU7UEFbjtDA2hxJ1ichM= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= +github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= +github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= +github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= +github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.5/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= @@ -704,8 +708,8 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= -github.com/okx/Xgon-node v0.2.6-RC3.0.20231017042525-466fd315d92a h1:cDdU2CIWDWVh9aGGWvR1PRcgZgcKx1/7IZd39crN6v4= -github.com/okx/Xgon-node v0.2.6-RC3.0.20231017042525-466fd315d92a/go.mod h1:F8k8RmhnqwhCGytey+SKI7l8uMCKqW8gtAMRILeqd+8= +github.com/okx/Xgon-node v0.2.6-RC3.0.20231031041345-362031125530 h1:FUMKRWJ6MuJsLBFzO0KZz67y1xlD/EipNz8A34kHtzM= +github.com/okx/Xgon-node v0.2.6-RC3.0.20231031041345-362031125530/go.mod h1:n3w21Wec5I+ISPbcMhThQd/CPuzwpSjt7HEz1VwnoFo= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= @@ -809,7 +813,7 @@ github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4 github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= -github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik= +github.com/rs/cors v1.8.2 h1:KCooALfAYGs415Cwu5ABvv9n9509fSiG5SQJn/AQo4U= github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= github.com/rs/zerolog v1.15.0/go.mod h1:xYTKnLHcpfU2225ny5qZjxnj9NvkumZYjJHlAThCjNc= @@ -930,8 +934,8 @@ github.com/urfave/cli/v2 v2.25.7/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6S github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= -github.com/valyala/fastjson v1.4.1 h1:hrltpHpIpkaxll8QltMU8c3QZ5+qIiCL8yKqPFJI/yE= -github.com/valyala/fastjson v1.4.1/go.mod h1:nV6MsjxL2IMJQUoHDIrjEI7oLyeqK6aBD7EFWPsvP8o= +github.com/valyala/fastjson v1.6.3 h1:tAKFnnwmeMGPbwJ7IwxcTPCNr3uIzoIj3/Fh90ra4xc= +github.com/valyala/fastjson v1.6.3/go.mod h1:CLCAqky6SMuOcxStkYQvblddUtoRxhYMGLrsQns1aXY= github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= @@ -1209,7 +1213,6 @@ golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210316164454-77fc1eacc6aa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1218,6 +1221,7 @@ golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= diff --git a/localcache/maincoinscache.go b/localcache/maincoinscache.go index dabe3652..f2bf5067 100644 --- a/localcache/maincoinscache.go +++ b/localcache/maincoinscache.go @@ -2,12 +2,13 @@ package localcache import ( "context" + "sync" + "time" + "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" "github.com/0xPolygonHermez/zkevm-node/log" "github.com/jackc/pgx/v4" "github.com/pkg/errors" - "sync" - "time" ) const ( diff --git a/nacos/start.go b/nacos/start.go index 252defdc..ca3b16ad 100644 --- a/nacos/start.go +++ b/nacos/start.go @@ -7,11 +7,10 @@ import ( "strings" "time" + "github.com/0xPolygonHermez/zkevm-node/log" "github.com/nacos-group/nacos-sdk-go/clients" "github.com/nacos-group/nacos-sdk-go/common/constant" "github.com/nacos-group/nacos-sdk-go/vo" - - "github.com/0xPolygonHermez/zkevm-node/log" ) // StartNacosClient start nacos client and register rest service in nacos @@ -27,11 +26,13 @@ func StartNacosClient(urls string, namespace string, name string, externalAddr s log.Error(fmt.Sprintf("failed to resolve nacos server url %s: %s", urls, err.Error())) return } + const timeoutMs = 5000 + const listenInterval = 10000 client, err := clients.CreateNamingClient(map[string]interface{}{ "serverConfigs": serverConfigs, "clientConfig": constant.ClientConfig{ - TimeoutMs: 5000, - ListenInterval: 10000, + TimeoutMs: timeoutMs, + ListenInterval: listenInterval, NotLoadCacheAtStart: true, NamespaceId: namespace, LogDir: "/dev/null", @@ -43,11 +44,12 @@ func StartNacosClient(urls string, namespace string, name string, externalAddr s return } + const weight = 10 _, err = client.RegisterInstance(vo.RegisterInstanceParam{ Ip: ip, Port: uint64(port), ServiceName: name, - Weight: 10, + Weight: weight, ClusterName: "DEFAULT", Enable: true, Healthy: true, @@ -68,7 +70,8 @@ func ResolveIPAndPort(addr string) (string, int, error) { laddr := strings.Split(addr, ":") ip := laddr[0] if ip == "127.0.0.1" { - return GetLocalIP(), 26659, nil + const port = 26659 + return GetLocalIP(), port, nil } port, err := strconv.Atoi(laddr[1]) if err != nil { diff --git a/nacos/util.go b/nacos/util.go index 6474232a..bb42b897 100644 --- a/nacos/util.go +++ b/nacos/util.go @@ -17,11 +17,12 @@ func GetOneInstance(urls string, nameSpace string, param vo.SelectOneHealthInsta return nil, fmt.Errorf("failed to resolve nacos server url %s: %s", urls, err.Error()) } + const timeoutMs = 5000 namingClient, err := clients.CreateNamingClient(map[string]interface{}{ "serverConfigs": serverConfigs, "clientConfig": constant.ClientConfig{ NamespaceId: nameSpace, - TimeoutMs: 5000, + TimeoutMs: timeoutMs, NotLoadCacheAtStart: true, LogDir: "/dev/null", }, diff --git a/redisstorage/interfaces.go b/redisstorage/interfaces.go index e4ddf13d..b9d67290 100644 --- a/redisstorage/interfaces.go +++ b/redisstorage/interfaces.go @@ -2,6 +2,7 @@ package redisstorage import ( "context" + "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" ) diff --git a/redisstorage/redisstorage.go b/redisstorage/redisstorage.go index f13d3c77..9c99d752 100644 --- a/redisstorage/redisstorage.go +++ b/redisstorage/redisstorage.go @@ -2,15 +2,16 @@ package redisstorage import ( "context" + "math/rand" + "strconv" + "strings" + "time" + "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" "github.com/0xPolygonHermez/zkevm-node/log" "github.com/pkg/errors" "github.com/redis/go-redis/v9" "google.golang.org/protobuf/encoding/protojson" - "math/rand" - "strconv" - "strings" - "time" ) const ( @@ -67,7 +68,7 @@ func (s *redisStorageImpl) SetCoinPrice(ctx context.Context, prices []*pb.Symbol } valueList = append(valueList, priceKey, priceVal) } - if len(valueList) < 2 { + if len(valueList) < 2 { // nolint:gomnd return nil } err = s.client.HSet(ctx, coinPriceHashKey, valueList...).Err() @@ -131,7 +132,7 @@ func (s *redisStorageImpl) GetCoinPrice(ctx context.Context, symbols []*pb.Symbo if s.mockPrice { for _, price := range priceList { - price.Price = rand.Float64() + price.Price = rand.Float64() // #nosec price.Time = uint64(time.Now().UnixMilli()) } } diff --git a/sentinel/sentinel.go b/sentinel/sentinel.go index cc4ebcc2..866f30f9 100644 --- a/sentinel/sentinel.go +++ b/sentinel/sentinel.go @@ -2,6 +2,7 @@ package sentinel import ( "encoding/json" + "github.com/0xPolygonHermez/zkevm-node/log" "github.com/alibaba/sentinel-golang/core/flow" "github.com/alibaba/sentinel-golang/ext/datasource" diff --git a/server/interfaces.go b/server/interfaces.go index 69332278..9464fb12 100644 --- a/server/interfaces.go +++ b/server/interfaces.go @@ -2,6 +2,7 @@ package server import ( "context" + ctmtypes "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman/types" "github.com/0xPolygonHermez/zkevm-bridge-service/etherman" "github.com/ethereum/go-ethereum/common" diff --git a/server/server.go b/server/server.go index 2bd0d2cf..050c4181 100644 --- a/server/server.go +++ b/server/server.go @@ -3,8 +3,6 @@ package server import ( "context" "fmt" - "github.com/0xPolygonHermez/zkevm-bridge-service/nacos" - "google.golang.org/protobuf/encoding/protojson" "net" "net/http" "os" @@ -12,12 +10,14 @@ import ( "time" "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" + "github.com/0xPolygonHermez/zkevm-bridge-service/nacos" "github.com/0xPolygonHermez/zkevm-node/log" sentinelGrpc "github.com/alibaba/sentinel-golang/pkg/adapters/grpc" "github.com/grpc-ecosystem/grpc-gateway/v2/runtime" "google.golang.org/grpc" "google.golang.org/grpc/credentials/insecure" "google.golang.org/grpc/health/grpc_health_v1" + "google.golang.org/protobuf/encoding/protojson" ) func RegisterNacos(cfg nacos.Config) { diff --git a/server/service.go b/server/service.go index 32d791bc..2065d9a6 100644 --- a/server/service.go +++ b/server/service.go @@ -4,18 +4,18 @@ import ( "context" "encoding/hex" "fmt" - ctmtypes "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman/types" - "github.com/0xPolygonHermez/zkevm-bridge-service/localcache" - "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" - "github.com/pkg/errors" "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl" "github.com/0xPolygonHermez/zkevm-bridge-service/bridgectrl/pb" + ctmtypes "github.com/0xPolygonHermez/zkevm-bridge-service/claimtxman/types" "github.com/0xPolygonHermez/zkevm-bridge-service/etherman" + "github.com/0xPolygonHermez/zkevm-bridge-service/localcache" + "github.com/0xPolygonHermez/zkevm-bridge-service/redisstorage" "github.com/0xPolygonHermez/zkevm-bridge-service/utils/gerror" "github.com/ethereum/go-ethereum/common" lru "github.com/hashicorp/golang-lru/v2" "github.com/jackc/pgx/v4" + "github.com/pkg/errors" ) const ( diff --git a/test/config/node/config.zkevm.node.toml b/test/config/node/config.zkevm.node.toml deleted file mode 100644 index 1a912694..00000000 --- a/test/config/node/config.zkevm.node.toml +++ /dev/null @@ -1,139 +0,0 @@ -IsTrustedSequencer = true - -[Log] -Environment = "development" # "production" or "development" -Level = "debug" -Outputs = ["stdout"] - -[StateDB] -User = "state_user" -Password = "state_password" -Name = "state_db" -Host = "zkevm-state-db" -Port = "5432" -EnableLog = false -MaxConns = 200 - -[Pool] -IntervalToRefreshBlockedAddresses = "5m" -MaxTxBytesSize=30132 -MaxTxDataBytesSize=30000 -DefaultMinGasPriceAllowed = 1000000000 -MinAllowedGasPriceInterval = "5m" -PollMinAllowedGasPriceInterval = "15s" - [Pool.DB] - User = "pool_user" - Password = "pool_password" - Name = "pool_db" - Host = "zkevm-pool-db" - Port = "5432" - EnableLog = false - MaxConns = 200 - -[Etherman] -URL = "http://zkevm-mock-l1-network:8545" -MultiGasProvider = false - [Etherman.Etherscan] - ApiKey = "" - -[RPC] -Host = "0.0.0.0" -Port = 8123 -ReadTimeoutInSec = 60 -WriteTimeoutInSec = 60 -MaxRequestsPerIPAndSecond = 5000 -SequencerNodeURI = "" -DefaultSenderAddress = "0x1111111111111111111111111111111111111111" -EnableL2SuggestedGasPricePolling = true - [RPC.WebSockets] - Enabled = true - Port = 8133 - -[Synchronizer] -SyncInterval = "1s" -SyncChunkSize = 100 -TrustedSequencerURL = "" - -[Sequencer] -WaitPeriodPoolIsEmpty = "1s" -WaitPeriodSendSequence = "3s" -LastBatchVirtualizationTimeMaxWaitPeriod = "5s" -BlocksAmountForTxsToBeDeleted = 100 -FrequencyToCheckTxsForDelete = "12h" -MaxTxsPerBatch = 150 -MaxBatchBytesSize = 129848 -MaxCumulativeGasUsed = 30000000 -MaxKeccakHashes = 468 -MaxPoseidonHashes = 279620 -MaxPoseidonPaddings = 149796 -MaxMemAligns = 262144 -MaxArithmetics = 262144 -MaxBinaries = 262144 -MaxSteps = 8388608 -WeightBatchBytesSize = 1 -WeightCumulativeGasUsed = 1 -WeightKeccakHashes = 1 -WeightPoseidonHashes = 1 -WeightPoseidonPaddings = 1 -WeightMemAligns = 1 -WeightArithmetics = 1 -WeightBinaries = 1 -WeightSteps = 1 -TxLifetimeCheckTimeout = "10m" -MaxTxLifetime = "3h" -MaxTxSizeForL1 = 131072 - [Sequencer.Finalizer] - GERDeadlineTimeoutInSec = "2s" - ForcedBatchDeadlineTimeoutInSec = "60s" - SleepDurationInMs = "100ms" - ResourcePercentageToCloseBatch = 10 - GERFinalityNumberOfBlocks = 0 - ClosingSignalsManagerWaitForCheckingL1Timeout = "1s" - ClosingSignalsManagerWaitForCheckingGER = "1s" - ClosingSignalsManagerWaitForCheckingForcedBatches = "1s" - ForcedBatchesFinalityNumberOfBlocks = 0 - TimestampResolution = "15s" - SenderAddress = "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266" - PrivateKeys = [{Path = "/pk/keystore.sequencer", Password = "testonly"}] - [Sequencer.DBManager] - PoolRetrievalInterval = "500ms" - L2ReorgRetrievalInterval = "5s" - [Sequencer.Worker] - ResourceCostMultiplier = 1000 - -[Aggregator] -Host = "0.0.0.0" -Port = 50081 -ForkId = 4 -RetryTime = "3s" -VerifyProofInterval = "5s" -TxProfitabilityCheckerType = "acceptall" -TxProfitabilityMinReward = "1.1" -ProofStatePollingInterval = "5s" -SenderAddress = "0x70997970c51812dc3a010c7d01b50e0d17dc79c8" -CleanupLockedProofsInterval = "2m" -GeneratingProofCleanupThreshold = "10m" - -[EthTxManager] -ForcedGas = 0 -PrivateKeys = [ - {Path = "/pk/keystore.sequencer", Password = "testonly"}, - {Path = "/pk/keystore.aggregator", Password = "testonly"} -] - -[L2GasPriceSuggester] -Type = "follower" -UpdatePeriod = "10s" -Factor = 0.5 -DefaultGasPriceWei = 1000000000 - -[MTClient] -URI = "zkevm-prover:50061" - -[Executor] -URI = "zkevm-prover:50071" - -[Metrics] -Host = "0.0.0.0" -Port = 9091 -Enabled = false diff --git a/test/config/node/genesis.local.json b/test/config/node/genesis.local.json deleted file mode 100644 index a4bc8e67..00000000 --- a/test/config/node/genesis.local.json +++ /dev/null @@ -1,102 +0,0 @@ -{ - "l1Config" : { - "chainId": 1337, - "polygonZkEVMAddress": "0x610178dA211FEF7D417bC0e6FeD39F05609AD788", - "maticTokenAddress": "0x5FbDB2315678afecb367f032d93F642f64180aa3", - "polygonZkEVMGlobalExitRootAddress": "0x2279B7A0a67DB372996a5FaB50D91eAA73d2eBe6" - }, - "root": "0xd88680f1b151dd67518f9aca85161424c0cac61df2f5424a3ddc04ea25adecc7", - "genesisBlockNumber": 74, - "genesis": [ - { - "contractName": "PolygonZkEVMDeployer", - "balance": "0", - "nonce": "4", - "address": "0x4b2700570f8426A24EA85e0324611E527BdD55B8", - "bytecode": "0x6080604052600436106100705760003560e01c8063715018a61161004e578063715018a6146100e65780638da5cb5b146100fb578063e11ae6cb14610126578063f2fde38b1461013957600080fd5b80632b79805a146100755780634a94d4871461008a5780636d07dbf81461009d575b600080fd5b610088610083366004610927565b610159565b005b6100886100983660046109c7565b6101cb565b3480156100a957600080fd5b506100bd6100b8366004610a1e565b61020d565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100f257600080fd5b50610088610220565b34801561010757600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166100bd565b610088610134366004610a40565b610234565b34801561014557600080fd5b50610088610154366004610a90565b61029b565b610161610357565b600061016e8585856103d8565b905061017a8183610537565b5060405173ffffffffffffffffffffffffffffffffffffffff821681527fba82f25fed02cd2a23d9f5d11c2ef588d22af5437cbf23bfe61d87257c480e4c9060200160405180910390a15050505050565b6101d3610357565b6101de83838361057b565b506040517f25adb19089b6a549831a273acdf7908cff8b7ee5f551f8d1d37996cf01c5df5b90600090a1505050565b600061021983836105a9565b9392505050565b610228610357565b61023260006105b6565b565b61023c610357565b60006102498484846103d8565b60405173ffffffffffffffffffffffffffffffffffffffff821681529091507fba82f25fed02cd2a23d9f5d11c2ef588d22af5437cbf23bfe61d87257c480e4c9060200160405180910390a150505050565b6102a3610357565b73ffffffffffffffffffffffffffffffffffffffff811661034b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b610354816105b6565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610232576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610342565b600083471015610444576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f437265617465323a20696e73756666696369656e742062616c616e63650000006044820152606401610342565b81516000036104af576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f437265617465323a2062797465636f6465206c656e677468206973207a65726f6044820152606401610342565b8282516020840186f5905073ffffffffffffffffffffffffffffffffffffffff8116610219576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f437265617465323a204661696c6564206f6e206465706c6f79000000000000006044820152606401610342565b6060610219838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c6564000081525061062b565b60606105a1848484604051806060016040528060298152602001610b3d6029913961062b565b949350505050565b6000610219838330610744565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6060824710156106bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610342565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516106e69190610acf565b60006040518083038185875af1925050503d8060008114610723576040519150601f19603f3d011682016040523d82523d6000602084013e610728565b606091505b50915091506107398783838761076e565b979650505050505050565b6000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b606083156108045782516000036107fd5773ffffffffffffffffffffffffffffffffffffffff85163b6107fd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610342565b50816105a1565b6105a183838151156108195781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103429190610aeb565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f83011261088d57600080fd5b813567ffffffffffffffff808211156108a8576108a861084d565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019082821181831017156108ee576108ee61084d565b8160405283815286602085880101111561090757600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000806080858703121561093d57600080fd5b8435935060208501359250604085013567ffffffffffffffff8082111561096357600080fd5b61096f8883890161087c565b9350606087013591508082111561098557600080fd5b506109928782880161087c565b91505092959194509250565b803573ffffffffffffffffffffffffffffffffffffffff811681146109c257600080fd5b919050565b6000806000606084860312156109dc57600080fd5b6109e58461099e565b9250602084013567ffffffffffffffff811115610a0157600080fd5b610a0d8682870161087c565b925050604084013590509250925092565b60008060408385031215610a3157600080fd5b50508035926020909101359150565b600080600060608486031215610a5557600080fd5b8335925060208401359150604084013567ffffffffffffffff811115610a7a57600080fd5b610a868682870161087c565b9150509250925092565b600060208284031215610aa257600080fd5b6102198261099e565b60005b83811015610ac6578181015183820152602001610aae565b50506000910152565b60008251610ae1818460208701610aab565b9190910192915050565b6020815260008251806020840152610b0a816040850160208701610aab565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2063616c6c20776974682076616c7565206661696c6564a26469706673582212203e70ce334e8ec9d8d03e87415afd36dce4e82633bd277b08937095a6bd66367764736f6c63430008110033", - "storage": { - "0x0000000000000000000000000000000000000000000000000000000000000000": "0x000000000000000000000000f39fd6e51aad88f6f4ce6ab8827279cfffb92266" - } - }, - { - "contractName": "ProxyAdmin", - "balance": "0", - "nonce": "1", - "address": "0xf065BaE7C019ff5627E09ed48D4EeA317D211956", - "bytecode": "0x60806040526004361061007b5760003560e01c80639623609d1161004e5780639623609d1461012b57806399a88ec41461013e578063f2fde38b1461015e578063f3b7dead1461017e57600080fd5b8063204e1c7a14610080578063715018a6146100c95780637eff275e146100e05780638da5cb5b14610100575b600080fd5b34801561008c57600080fd5b506100a061009b366004610608565b61019e565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100d557600080fd5b506100de610255565b005b3480156100ec57600080fd5b506100de6100fb36600461062c565b610269565b34801561010c57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166100a0565b6100de610139366004610694565b6102f7565b34801561014a57600080fd5b506100de61015936600461062c565b61038c565b34801561016a57600080fd5b506100de610179366004610608565b6103e8565b34801561018a57600080fd5b506100a0610199366004610608565b6104a4565b60008060008373ffffffffffffffffffffffffffffffffffffffff166040516101ea907f5c60da1b00000000000000000000000000000000000000000000000000000000815260040190565b600060405180830381855afa9150503d8060008114610225576040519150601f19603f3d011682016040523d82523d6000602084013e61022a565b606091505b50915091508161023957600080fd5b8080602001905181019061024d9190610788565b949350505050565b61025d6104f0565b6102676000610571565b565b6102716104f0565b6040517f8f28397000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8281166004830152831690638f283970906024015b600060405180830381600087803b1580156102db57600080fd5b505af11580156102ef573d6000803e3d6000fd5b505050505050565b6102ff6104f0565b6040517f4f1ef28600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841690634f1ef28690349061035590869086906004016107a5565b6000604051808303818588803b15801561036e57600080fd5b505af1158015610382573d6000803e3d6000fd5b5050505050505050565b6103946104f0565b6040517f3659cfe600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8281166004830152831690633659cfe6906024016102c1565b6103f06104f0565b73ffffffffffffffffffffffffffffffffffffffff8116610498576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6104a181610571565b50565b60008060008373ffffffffffffffffffffffffffffffffffffffff166040516101ea907ff851a44000000000000000000000000000000000000000000000000000000000815260040190565b60005473ffffffffffffffffffffffffffffffffffffffff163314610267576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161048f565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b73ffffffffffffffffffffffffffffffffffffffff811681146104a157600080fd5b60006020828403121561061a57600080fd5b8135610625816105e6565b9392505050565b6000806040838503121561063f57600080fd5b823561064a816105e6565b9150602083013561065a816105e6565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000606084860312156106a957600080fd5b83356106b4816105e6565b925060208401356106c4816105e6565b9150604084013567ffffffffffffffff808211156106e157600080fd5b818601915086601f8301126106f557600080fd5b81358181111561070757610707610665565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561074d5761074d610665565b8160405282815289602084870101111561076657600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b60006020828403121561079a57600080fd5b8151610625816105e6565b73ffffffffffffffffffffffffffffffffffffffff8316815260006020604081840152835180604085015260005b818110156107ef578581018301518582016060015282016107d3565b5060006060828601015260607fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050939250505056fea2646970667358221220372a0e10eebea1b7fa43ae4c976994e6ed01d85eedc3637b83f01d3f06be442064736f6c63430008110033", - "storage": { - "0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000000165878a594ca255338adfa4d48449f69242eb8f" - } - }, - { - "contractName": "PolygonZkEVMBridge implementation", - "balance": "0", - "nonce": "1", - "address": "0xf23919bb44BCa81aeAb4586BE71Ee3fd4E99B951", - "bytecode": "0x6080604052600436106200019f5760003560e01c8063647c576c11620000e7578063be5831c71162000089578063dbc169761162000060578063dbc169761462000639578063ee25560b1462000651578063fb570834146200068257600080fd5b8063be5831c714620005ae578063cd58657914620005ea578063d02103ca146200060157600080fd5b80639e34070f11620000be5780639e34070f146200050a578063aaa13cc2146200054f578063bab161bf146200057457600080fd5b8063647c576c146200048657806379e2cf9714620004ab57806381b1c17414620004c357600080fd5b80632d2c9d94116200015157806334ac9cf2116200012857806334ac9cf2146200034b5780633ae05047146200037a5780633e197043146200039257600080fd5b80632d2c9d9414620002765780632dfdf0b5146200029b578063318aee3d14620002c257600080fd5b806322e95f2c116200018657806322e95f2c14620001ef578063240ff378146200023a5780632cffd02e146200025157600080fd5b806315064c9614620001a45780632072f6c514620001d5575b600080fd5b348015620001b157600080fd5b50606854620001c09060ff1681565b60405190151581526020015b60405180910390f35b348015620001e257600080fd5b50620001ed620006a7565b005b348015620001fc57600080fd5b50620002146200020e366004620032db565b62000705565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001620001cc565b620001ed6200024b36600462003372565b620007a8565b3480156200025e57600080fd5b50620001ed6200027036600462003409565b620009d0565b3480156200028357600080fd5b50620001ed6200029536600462003409565b62000f74565b348015620002a857600080fd5b50620002b360535481565b604051908152602001620001cc565b348015620002cf57600080fd5b5062000319620002e1366004620034ef565b606b6020526000908152604090205463ffffffff811690640100000000900473ffffffffffffffffffffffffffffffffffffffff1682565b6040805163ffffffff909316835273ffffffffffffffffffffffffffffffffffffffff909116602083015201620001cc565b3480156200035857600080fd5b50606c54620002149073ffffffffffffffffffffffffffffffffffffffff1681565b3480156200038757600080fd5b50620002b362001178565b3480156200039f57600080fd5b50620002b3620003b136600462003526565b6040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b3480156200049357600080fd5b50620001ed620004a5366004620035b0565b6200125e565b348015620004b857600080fd5b50620001ed620014ad565b348015620004d057600080fd5b5062000214620004e236600462003600565b606a6020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b3480156200051757600080fd5b50620001c06200052936600462003600565b600881901c600090815260696020526040902054600160ff9092169190911b9081161490565b3480156200055c57600080fd5b50620002146200056e3660046200361a565b620014e7565b3480156200058157600080fd5b506068546200059890610100900463ffffffff1681565b60405163ffffffff9091168152602001620001cc565b348015620005bb57600080fd5b506068546200059890790100000000000000000000000000000000000000000000000000900463ffffffff1681565b620001ed620005fb366004620036ce565b620016d3565b3480156200060e57600080fd5b50606854620002149065010000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b3480156200064657600080fd5b50620001ed62001c37565b3480156200065e57600080fd5b50620002b36200067036600462003600565b60696020526000908152604090205481565b3480156200068f57600080fd5b50620001c0620006a136600462003770565b62001c93565b606c5473ffffffffffffffffffffffffffffffffffffffff163314620006f9576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200070362001d7c565b565b6040805160e084901b7fffffffff0000000000000000000000000000000000000000000000000000000016602080830191909152606084901b7fffffffffffffffffffffffffffffffffffffffff00000000000000000000000016602483015282516018818403018152603890920183528151918101919091206000908152606a909152205473ffffffffffffffffffffffffffffffffffffffff165b92915050565b60685460ff1615620007e6576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60685463ffffffff8681166101009092041614806200080c5750600263ffffffff861610155b1562000844576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f501781209a1f8899323b96b4ef08b168df93e0a90c673d1e4cce39366cb62f9b6001606860019054906101000a900463ffffffff163388883488886053546040516200089a9998979695949392919062003806565b60405180910390a1620009b8620009b26001606860019054906101000a900463ffffffff16338989348989604051620008d592919062003881565b60405180910390206040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b62001e10565b8215620009c957620009c962001f27565b5050505050565b60685460ff161562000a0e576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62000a258b8b8b8b8b8b8b8b8b8b8b600062001ffc565b73ffffffffffffffffffffffffffffffffffffffff861662000b01576040805160008082526020820190925273ffffffffffffffffffffffffffffffffffffffff861690859060405162000a7a9190620038e6565b60006040518083038185875af1925050503d806000811462000ab9576040519150601f19603f3d011682016040523d82523d6000602084013e62000abe565b606091505b505090508062000afa576040517f6747a28800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5062000efc565b60685463ffffffff61010090910481169088160362000b435762000b3d73ffffffffffffffffffffffffffffffffffffffff87168585620021ed565b62000efc565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b1660208201527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606088901b166024820152600090603801604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000818152606a90935291205490915073ffffffffffffffffffffffffffffffffffffffff168062000e6e576000808062000c1886880188620039fb565b92509250925060008584848460405162000c329062003292565b62000c409392919062003abd565b8190604051809103906000f590508015801562000c61573d6000803e3d6000fd5b506040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c81166004830152602482018c9052919250908216906340c10f1990604401600060405180830381600087803b15801562000cd757600080fd5b505af115801562000cec573d6000803e3d6000fd5b5050505080606a600088815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060405180604001604052808e63ffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815250606b60008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008201518160000160006101000a81548163ffffffff021916908363ffffffff16021790555060208201518160000160046101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055509050507f490e59a1701b938786ac72570a1efeac994a3dbe96e2e883e19e902ace6e6a398d8d838b8b60405162000e5c95949392919062003afa565b60405180910390a15050505062000ef9565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018790528216906340c10f1990604401600060405180830381600087803b15801562000edf57600080fd5b505af115801562000ef4573d6000803e3d6000fd5b505050505b50505b6040805163ffffffff8c811682528916602082015273ffffffffffffffffffffffffffffffffffffffff88811682840152861660608201526080810185905290517f25308c93ceeed162da955b3f7ce3e3f93606579e40fb92029faa9efe275459839181900360a00190a15050505050505050505050565b60685460ff161562000fb2576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62000fc98b8b8b8b8b8b8b8b8b8b8b600162001ffc565b60008473ffffffffffffffffffffffffffffffffffffffff1684888a868660405160240162000ffc949392919062003b42565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f1806b5f200000000000000000000000000000000000000000000000000000000179052516200107f9190620038e6565b60006040518083038185875af1925050503d8060008114620010be576040519150601f19603f3d011682016040523d82523d6000602084013e620010c3565b606091505b5050905080620010ff576040517f37e391c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805163ffffffff8d811682528a16602082015273ffffffffffffffffffffffffffffffffffffffff89811682840152871660608201526080810186905290517f25308c93ceeed162da955b3f7ce3e3f93606579e40fb92029faa9efe275459839181900360a00190a1505050505050505050505050565b605354600090819081805b602081101562001255578083901c600116600103620011e65760338160208110620011b257620011b262003b8a565b0154604080516020810192909252810185905260600160405160208183030381529060405280519060200120935062001213565b60408051602081018690529081018390526060016040516020818303038152906040528051906020012093505b604080516020810184905290810183905260600160405160208183030381529060405280519060200120915080806200124c9062003be8565b91505062001183565b50919392505050565b600054610100900460ff16158080156200127f5750600054600160ff909116105b806200129b5750303b1580156200129b575060005460ff166001145b6200132d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905580156200138c57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b606880547fffffffffffffff000000000000000000000000000000000000000000000000ff1661010063ffffffff8716027fffffffffffffff0000000000000000000000000000000000000000ffffffffff16176501000000000073ffffffffffffffffffffffffffffffffffffffff8681169190910291909117909155606c80547fffffffffffffffffffffffff00000000000000000000000000000000000000001691841691909117905562001443620022c3565b8015620014a757600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b605354606854790100000000000000000000000000000000000000000000000000900463ffffffff16101562000703576200070362001f27565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b1660208201527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606088901b1660248201526000908190603801604051602081830303815290604052805190602001209050600060ff60f81b3083604051806020016200157d9062003292565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f909101166040819052620015c8908d908d908d908d908d9060200162003c23565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905262001606929160200162003c64565b604051602081830303815290604052805190602001206040516020016200168f94939291907fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101209a9950505050505050505050565b60685460ff161562001711576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200171b62002366565b60685463ffffffff888116610100909204161480620017415750600263ffffffff881610155b1562001779576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060608773ffffffffffffffffffffffffffffffffffffffff8816620017df57883414620017d5576040517fb89240f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000925062001ad9565b341562001818576040517f798ee6f100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8089166000908152606b602090815260409182902082518084019093525463ffffffff811683526401000000009004909216918101829052901562001908576040517f9dc29fac000000000000000000000000000000000000000000000000000000008152336004820152602481018b905273ffffffffffffffffffffffffffffffffffffffff8a1690639dc29fac90604401600060405180830381600087803b158015620018db57600080fd5b505af1158015620018f0573d6000803e3d6000fd5b50505050806020015194508060000151935062001ad7565b85156200191d576200191d898b8989620023db565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8b16906370a0823190602401602060405180830381865afa1580156200198b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620019b1919062003c97565b9050620019d773ffffffffffffffffffffffffffffffffffffffff8b1633308e620028f9565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8c16906370a0823190602401602060405180830381865afa15801562001a45573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001a6b919062003c97565b905062001a79828262003cb1565b6068548c9850610100900463ffffffff169650935062001a998762002959565b62001aa48c62002a71565b62001aaf8d62002b7e565b60405160200162001ac39392919062003abd565b604051602081830303815290604052945050505b505b7f501781209a1f8899323b96b4ef08b168df93e0a90c673d1e4cce39366cb62f9b600084868e8e868860535460405162001b1b98979695949392919062003cc7565b60405180910390a162001c0f620009b2600085878f8f8789805190602001206040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b861562001c205762001c2062001f27565b5050505062001c2e60018055565b50505050505050565b606c5473ffffffffffffffffffffffffffffffffffffffff16331462001c89576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200070362002c80565b600084815b602081101562001d6e57600163ffffffff8616821c8116900362001d0a5785816020811062001ccb5762001ccb62003b8a565b60200201358260405160200162001cec929190918252602082015260400190565b60405160208183030381529060405280519060200120915062001d59565b8186826020811062001d205762001d2062003b8a565b602002013560405160200162001d40929190918252602082015260400190565b6040516020818303038152906040528051906020012091505b8062001d658162003be8565b91505062001c98565b50821490505b949350505050565b60685460ff161562001dba576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556040517f2261efe5aef6fedc1fd1550b25facc9181745623049c7901287030b9ad1a549790600090a1565b80600162001e216020600262003e79565b62001e2d919062003cb1565b6053541062001e68576040517fef5ccf6600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060536000815462001e7b9062003be8565b9182905550905060005b602081101562001f17578082901c60011660010362001ebd57826033826020811062001eb55762001eb562003b8a565b015550505050565b6033816020811062001ed35762001ed362003b8a565b01546040805160208101929092528101849052606001604051602081830303815290604052805190602001209250808062001f0e9062003be8565b91505062001e85565b5062001f2262003e87565b505050565b6053546068805463ffffffff909216790100000000000000000000000000000000000000000000000000027fffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffffff909216919091179081905573ffffffffffffffffffffffffffffffffffffffff65010000000000909104166333d6247d62001fad62001178565b6040518263ffffffff1660e01b815260040162001fcc91815260200190565b600060405180830381600087803b15801562001fe757600080fd5b505af1158015620014a7573d6000803e3d6000fd5b6200200d8b63ffffffff1662002d10565b6068546040805160208082018e90528183018d9052825180830384018152606083019384905280519101207f257b363200000000000000000000000000000000000000000000000000000000909252606481019190915260009165010000000000900473ffffffffffffffffffffffffffffffffffffffff169063257b3632906084016020604051808303816000875af1158015620020b0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620020d6919062003c97565b90508060000362002112576040517e2f6fad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60685463ffffffff88811661010090920416146200215c576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606854600090610100900463ffffffff166200217a5750896200217d565b508a5b620021a66200219d848c8c8c8c8c8c8c604051620008d592919062003881565b8f8f8462001c93565b620021dd576040517fe0417cec00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050505050565b60405173ffffffffffffffffffffffffffffffffffffffff831660248201526044810182905262001f229084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915262002d75565b600054610100900460ff166200235c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840162001324565b6200070362002e88565b600260015403620023d4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640162001324565b6002600155565b6000620023ec600482848662003eb6565b620023f79162003ee2565b90507f2afa5331000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000821601620026765760008080808080806200245a896004818d62003eb6565b81019062002469919062003f2b565b96509650965096509650965096503373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff1614620024dd576040517f912ecce700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff861630146200252d576040517f750643af00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8a851462002567576040517f03fffc4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff89811660248301528881166044830152606482018890526084820187905260ff861660a483015260c4820185905260e48083018590528351808403909101815261010490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd505accf000000000000000000000000000000000000000000000000000000001790529151918e1691620026229190620038e6565b6000604051808303816000865af19150503d806000811462002661576040519150601f19603f3d011682016040523d82523d6000602084013e62002666565b606091505b50505050505050505050620009c9565b7fffffffff0000000000000000000000000000000000000000000000000000000081167f8fcbaf0c0000000000000000000000000000000000000000000000000000000014620026f2576040517fe282c0ba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808080808080806200270a8a6004818e62003eb6565b81019062002719919062003f86565b975097509750975097509750975097503373ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff16146200278f576040517f912ecce700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff87163014620027df576040517f750643af00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff8a811660248301528981166044830152606482018990526084820188905286151560a483015260ff861660c483015260e482018590526101048083018590528351808403909101815261012490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f8fcbaf0c000000000000000000000000000000000000000000000000000000001790529151918f1691620028a39190620038e6565b6000604051808303816000865af19150503d8060008114620028e2576040519150601f19603f3d011682016040523d82523d6000602084013e620028e7565b606091505b50505050505050505050505050505050565b60405173ffffffffffffffffffffffffffffffffffffffff80851660248301528316604482015260648101829052620014a79085907f23b872dd000000000000000000000000000000000000000000000000000000009060840162002240565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f06fdde03000000000000000000000000000000000000000000000000000000001790529051606091600091829173ffffffffffffffffffffffffffffffffffffffff861691620029dd9190620038e6565b600060405180830381855afa9150503d806000811462002a1a576040519150601f19603f3d011682016040523d82523d6000602084013e62002a1f565b606091505b50915091508162002a66576040518060400160405280600781526020017f4e4f5f4e414d450000000000000000000000000000000000000000000000000081525062001d74565b62001d748162002f21565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f95d89b41000000000000000000000000000000000000000000000000000000001790529051606091600091829173ffffffffffffffffffffffffffffffffffffffff86169162002af59190620038e6565b600060405180830381855afa9150503d806000811462002b32576040519150601f19603f3d011682016040523d82523d6000602084013e62002b37565b606091505b50915091508162002a66576040518060400160405280600981526020017f4e4f5f53594d424f4c000000000000000000000000000000000000000000000081525062001d74565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f313ce5670000000000000000000000000000000000000000000000000000000017905290516000918291829173ffffffffffffffffffffffffffffffffffffffff86169162002c019190620038e6565b600060405180830381855afa9150503d806000811462002c3e576040519150601f19603f3d011682016040523d82523d6000602084013e62002c43565b606091505b509150915081801562002c57575080516020145b62002c6457601262001d74565b8080602001905181019062001d74919062004012565b60018055565b60685460ff1662002cbd576040517f5386698100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040517f1e5e34eea33501aecf2ebec9fe0e884a40804275ea7fe10b2ba084c8374308b390600090a1565b600881901c60008181526069602052604081208054600160ff861690811b91821892839055929091908183169003620009c9576040517f646cf55800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600062002dd9826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16620031119092919063ffffffff16565b80519091501562001f22578080602001905181019062002dfa919062004032565b62001f22576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f74207375636365656400000000000000000000000000000000000000000000606482015260840162001324565b600054610100900460ff1662002c7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840162001324565b6060604082511062002f435781806020019051810190620007a2919062004052565b8151602003620030d35760005b60208110801562002f9b575082818151811062002f715762002f7162003b8a565b01602001517fff000000000000000000000000000000000000000000000000000000000000001615155b1562002fb6578062002fad8162003be8565b91505062002f50565b8060000362002ffa57505060408051808201909152601281527f4e4f545f56414c49445f454e434f44494e4700000000000000000000000000006020820152919050565b60008167ffffffffffffffff81111562003018576200301862003891565b6040519080825280601f01601f19166020018201604052801562003043576020820181803683370190505b50905060005b82811015620030cb5784818151811062003067576200306762003b8a565b602001015160f81c60f81b82828151811062003087576200308762003b8a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080620030c28162003be8565b91505062003049565b509392505050565b505060408051808201909152601281527f4e4f545f56414c49445f454e434f44494e470000000000000000000000000000602082015290565b919050565b606062001d748484600085856000808673ffffffffffffffffffffffffffffffffffffffff168587604051620031489190620038e6565b60006040518083038185875af1925050503d806000811462003187576040519150601f19603f3d011682016040523d82523d6000602084013e6200318c565b606091505b50915091506200319f87838387620031aa565b979650505050505050565b60608315620032455782516000036200323d5773ffffffffffffffffffffffffffffffffffffffff85163b6200323d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640162001324565b508162001d74565b62001d7483838151156200325c5781518083602001fd5b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401620013249190620040d2565b611b6680620040e883390190565b803563ffffffff811681146200310c57600080fd5b73ffffffffffffffffffffffffffffffffffffffff81168114620032d857600080fd5b50565b60008060408385031215620032ef57600080fd5b620032fa83620032a0565b915060208301356200330c81620032b5565b809150509250929050565b8015158114620032d857600080fd5b60008083601f8401126200333957600080fd5b50813567ffffffffffffffff8111156200335257600080fd5b6020830191508360208285010111156200336b57600080fd5b9250929050565b6000806000806000608086880312156200338b57600080fd5b6200339686620032a0565b94506020860135620033a881620032b5565b93506040860135620033ba8162003317565b9250606086013567ffffffffffffffff811115620033d757600080fd5b620033e58882890162003326565b969995985093965092949392505050565b806104008101831015620007a257600080fd5b60008060008060008060008060008060006105208c8e0312156200342c57600080fd5b620034388d8d620033f6565b9a50620034496104008d01620032a0565b99506104208c013598506104408c013597506200346a6104608d01620032a0565b96506104808c01356200347d81620032b5565b95506200348e6104a08d01620032a0565b94506104c08c0135620034a181620032b5565b93506104e08c013592506105008c013567ffffffffffffffff811115620034c757600080fd5b620034d58e828f0162003326565b915080935050809150509295989b509295989b9093969950565b6000602082840312156200350257600080fd5b81356200350f81620032b5565b9392505050565b60ff81168114620032d857600080fd5b600080600080600080600060e0888a0312156200354257600080fd5b87356200354f8162003516565b96506200355f60208901620032a0565b955060408801356200357181620032b5565b94506200358160608901620032a0565b935060808801356200359381620032b5565b9699959850939692959460a0840135945060c09093013592915050565b600080600060608486031215620035c657600080fd5b620035d184620032a0565b92506020840135620035e381620032b5565b91506040840135620035f581620032b5565b809150509250925092565b6000602082840312156200361357600080fd5b5035919050565b600080600080600080600060a0888a0312156200363657600080fd5b6200364188620032a0565b965060208801356200365381620032b5565b9550604088013567ffffffffffffffff808211156200367157600080fd5b6200367f8b838c0162003326565b909750955060608a01359150808211156200369957600080fd5b50620036a88a828b0162003326565b9094509250506080880135620036be8162003516565b8091505092959891949750929550565b600080600080600080600060c0888a031215620036ea57600080fd5b620036f588620032a0565b965060208801356200370781620032b5565b95506040880135945060608801356200372081620032b5565b93506080880135620037328162003317565b925060a088013567ffffffffffffffff8111156200374f57600080fd5b6200375d8a828b0162003326565b989b979a50959850939692959293505050565b60008060008061046085870312156200378857600080fd5b843593506200379b8660208701620033f6565b9250620037ac6104208601620032a0565b939692955092936104400135925050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b600061010060ff8c16835263ffffffff808c16602085015273ffffffffffffffffffffffffffffffffffffffff808c166040860152818b166060860152808a166080860152508760a08501528160c0850152620038678285018789620037bd565b925080851660e085015250509a9950505050505050505050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60005b83811015620038dd578181015183820152602001620038c3565b50506000910152565b60008251620038fa818460208701620038c0565b9190910192915050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156200394e576200394e62003891565b604052919050565b600067ffffffffffffffff82111562003973576200397362003891565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620039b157600080fd5b8135620039c8620039c28262003956565b62003904565b818152846020838601011115620039de57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060006060848603121562003a1157600080fd5b833567ffffffffffffffff8082111562003a2a57600080fd5b62003a38878388016200399f565b9450602086013591508082111562003a4f57600080fd5b5062003a5e868287016200399f565b9250506040840135620035f58162003516565b6000815180845262003a8b816020860160208601620038c0565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60608152600062003ad2606083018662003a71565b828103602084015262003ae6818662003a71565b91505060ff83166040830152949350505050565b63ffffffff86168152600073ffffffffffffffffffffffffffffffffffffffff8087166020840152808616604084015250608060608301526200319f608083018486620037bd565b73ffffffffffffffffffffffffffffffffffffffff8516815263ffffffff8416602082015260606040820152600062003b80606083018486620037bd565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362003c1c5762003c1c62003bb9565b5060010190565b60608152600062003c39606083018789620037bd565b828103602084015262003c4e818688620037bd565b91505060ff831660408301529695505050505050565b6000835162003c78818460208801620038c0565b83519083019062003c8e818360208801620038c0565b01949350505050565b60006020828403121562003caa57600080fd5b5051919050565b81810381811115620007a257620007a262003bb9565b600061010060ff8b16835263ffffffff808b16602085015273ffffffffffffffffffffffffffffffffffffffff808b166040860152818a1660608601528089166080860152508660a08501528160c085015262003d278285018762003a71565b925080851660e085015250509998505050505050505050565b600181815b8085111562003d9f57817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111562003d835762003d8362003bb9565b8085161562003d9157918102915b93841c939080029062003d45565b509250929050565b60008262003db857506001620007a2565b8162003dc757506000620007a2565b816001811462003de0576002811462003deb5762003e0b565b6001915050620007a2565b60ff84111562003dff5762003dff62003bb9565b50506001821b620007a2565b5060208310610133831016604e8410600b841016171562003e30575081810a620007a2565b62003e3c838362003d40565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111562003e715762003e7162003bb9565b029392505050565b60006200350f838362003da7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b6000808585111562003ec757600080fd5b8386111562003ed557600080fd5b5050820193919092039150565b7fffffffff00000000000000000000000000000000000000000000000000000000813581811691600485101562003f235780818660040360031b1b83161692505b505092915050565b600080600080600080600060e0888a03121562003f4757600080fd5b873562003f5481620032b5565b9650602088013562003f6681620032b5565b955060408801359450606088013593506080880135620035938162003516565b600080600080600080600080610100898b03121562003fa457600080fd5b883562003fb181620032b5565b9750602089013562003fc381620032b5565b96506040890135955060608901359450608089013562003fe38162003317565b935060a089013562003ff58162003516565b979a969950949793969295929450505060c08201359160e0013590565b6000602082840312156200402557600080fd5b81516200350f8162003516565b6000602082840312156200404557600080fd5b81516200350f8162003317565b6000602082840312156200406557600080fd5b815167ffffffffffffffff8111156200407d57600080fd5b8201601f810184136200408f57600080fd5b8051620040a0620039c28262003956565b818152856020838501011115620040b657600080fd5b620040c9826020830160208601620038c0565b95945050505050565b6020815260006200350f602083018462003a7156fe6101006040523480156200001257600080fd5b5060405162001b6638038062001b6683398101604081905262000035916200028d565b82826003620000458382620003a1565b506004620000548282620003a1565b50503360c0525060ff811660e052466080819052620000739062000080565b60a052506200046d915050565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f620000ad6200012e565b805160209182012060408051808201825260018152603160f81b90840152805192830193909352918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018390523060a082015260c001604051602081830303815290604052805190602001209050919050565b6060600380546200013f9062000312565b80601f01602080910402602001604051908101604052809291908181526020018280546200016d9062000312565b8015620001be5780601f106200019257610100808354040283529160200191620001be565b820191906000526020600020905b815481529060010190602001808311620001a057829003601f168201915b5050505050905090565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620001f057600080fd5b81516001600160401b03808211156200020d576200020d620001c8565b604051601f8301601f19908116603f01168101908282118183101715620002385762000238620001c8565b816040528381526020925086838588010111156200025557600080fd5b600091505b838210156200027957858201830151818301840152908201906200025a565b600093810190920192909252949350505050565b600080600060608486031215620002a357600080fd5b83516001600160401b0380821115620002bb57600080fd5b620002c987838801620001de565b94506020860151915080821115620002e057600080fd5b50620002ef86828701620001de565b925050604084015160ff811681146200030757600080fd5b809150509250925092565b600181811c908216806200032757607f821691505b6020821081036200034857634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200039c57600081815260208120601f850160051c81016020861015620003775750805b601f850160051c820191505b81811015620003985782815560010162000383565b5050505b505050565b81516001600160401b03811115620003bd57620003bd620001c8565b620003d581620003ce845462000312565b846200034e565b602080601f8311600181146200040d5760008415620003f45750858301515b600019600386901b1c1916600185901b17855562000398565b600085815260208120601f198616915b828110156200043e578886015182559484019460019091019084016200041d565b50858210156200045d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e0516116aa620004bc6000396000610237015260008181610307015281816105c001526106a70152600061053a015260008181610379015261050401526116aa6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063a457c2d71161008c578063d505accf11610066578063d505accf1461039b578063dd62ed3e146103ae578063ffa1ad74146103f457600080fd5b8063a457c2d71461034e578063a9059cbb14610361578063cd0d00961461037457600080fd5b806395d89b41116100bd57806395d89b41146102e75780639dc29fac146102ef578063a3c573eb1461030257600080fd5b806370a08231146102915780637ecebe00146102c757600080fd5b806330adf81f1161012f5780633644e515116101145780633644e51514610261578063395093511461026957806340c10f191461027c57600080fd5b806330adf81f14610209578063313ce5671461023057600080fd5b806318160ddd1161016057806318160ddd146101bd57806320606b70146101cf57806323b872dd146101f657600080fd5b806306fdde031461017c578063095ea7b31461019a575b600080fd5b610184610430565b60405161019191906113e4565b60405180910390f35b6101ad6101a8366004611479565b6104c2565b6040519015158152602001610191565b6002545b604051908152602001610191565b6101c17f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f81565b6101ad6102043660046114a3565b6104dc565b6101c17f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b60405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610191565b6101c1610500565b6101ad610277366004611479565b61055c565b61028f61028a366004611479565b6105a8565b005b6101c161029f3660046114df565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101c16102d53660046114df565b60056020526000908152604090205481565b610184610680565b61028f6102fd366004611479565b61068f565b6103297f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610191565b6101ad61035c366004611479565b61075e565b6101ad61036f366004611479565b61082f565b6101c17f000000000000000000000000000000000000000000000000000000000000000081565b61028f6103a9366004611501565b61083d565b6101c16103bc366004611574565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101846040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525081565b60606003805461043f906115a7565b80601f016020809104026020016040519081016040528092919081815260200182805461046b906115a7565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b5050505050905090565b6000336104d0818585610b73565b60019150505b92915050565b6000336104ea858285610d27565b6104f5858585610dfe565b506001949350505050565b60007f00000000000000000000000000000000000000000000000000000000000000004614610537576105324661106d565b905090565b507f000000000000000000000000000000000000000000000000000000000000000090565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906104d090829086906105a3908790611629565b610b73565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610672576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d4272696467650000000000000000000000000000000060648201526084015b60405180910390fd5b61067c8282611135565b5050565b60606004805461043f906115a7565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d427269646765000000000000000000000000000000006064820152608401610669565b61067c8282611228565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919083811015610822576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f0000000000000000000000000000000000000000000000000000006064820152608401610669565b6104f58286868403610b73565b6000336104d0818585610dfe565b834211156108cc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f546f6b656e577261707065643a3a7065726d69743a204578706972656420706560448201527f726d6974000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8716600090815260056020526040812080547f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918a918a918a9190866109268361163c565b9091555060408051602081019690965273ffffffffffffffffffffffffffffffffffffffff94851690860152929091166060840152608083015260a082015260c0810186905260e0016040516020818303038152906040528051906020012090506000610991610500565b6040517f19010000000000000000000000000000000000000000000000000000000000006020820152602281019190915260428101839052606201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120600080855291840180845281905260ff89169284019290925260608301879052608083018690529092509060019060a0016020604051602081039080840390855afa158015610a55573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff811615801590610ad057508973ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16145b610b5c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f546f6b656e577261707065643a3a7065726d69743a20496e76616c696420736960448201527f676e6174757265000000000000000000000000000000000000000000000000006064820152608401610669565b610b678a8a8a610b73565b50505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c15576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8216610cb8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f73730000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610df85781811015610deb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610669565b610df88484848403610b73565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610ea1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f64726573730000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8216610f44576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f65737300000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610ffa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e636500000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610df8565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f611098610430565b8051602091820120604080518082018252600181527f310000000000000000000000000000000000000000000000000000000000000090840152805192830193909352918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018390523060a082015260c001604051602081830303815290604052805190602001209050919050565b73ffffffffffffffffffffffffffffffffffffffff82166111b2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610669565b80600260008282546111c49190611629565b909155505073ffffffffffffffffffffffffffffffffffffffff8216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff82166112cb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f73000000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604090205481811015611381576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f63650000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff83166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9101610d1a565b600060208083528351808285015260005b81811015611411578581018301518582016040015282016113f5565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461147457600080fd5b919050565b6000806040838503121561148c57600080fd5b61149583611450565b946020939093013593505050565b6000806000606084860312156114b857600080fd5b6114c184611450565b92506114cf60208501611450565b9150604084013590509250925092565b6000602082840312156114f157600080fd5b6114fa82611450565b9392505050565b600080600080600080600060e0888a03121561151c57600080fd5b61152588611450565b965061153360208901611450565b95506040880135945060608801359350608088013560ff8116811461155757600080fd5b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561158757600080fd5b61159083611450565b915061159e60208401611450565b90509250929050565b600181811c908216806115bb57607f821691505b6020821081036115f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156104d6576104d66115fa565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361166d5761166d6115fa565b506001019056fea26469706673582212208d88fee561cff7120d381c345cfc534cef8229a272dc5809d4bbb685ad67141164736f6c63430008110033a2646970667358221220d9b3ca7b13ec80ac58634ddf0ecebe71e209a71f532614949b9e720413f50c8364736f6c63430008110033" - }, - { - "contractName": "PolygonZkEVMBridge proxy", - "balance": "200000000000000000000000000", - "nonce": "1", - "address": "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0", - "bytecode": "0x60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100a85780638f283970146100e6578063f851a440146101065761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61011b565b005b61006b61011b565b34801561008157600080fd5b5061006b61009036600461088b565b610135565b61006b6100a33660046108a6565b61017f565b3480156100b457600080fd5b506100bd6101f3565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100f257600080fd5b5061006b61010136600461088b565b610231565b34801561011257600080fd5b506100bd61025e565b6101236102d4565b61013361012e6103ab565b6103b5565b565b61013d6103d9565b73ffffffffffffffffffffffffffffffffffffffff1633036101775761017481604051806020016040528060008152506000610419565b50565b61017461011b565b6101876103d9565b73ffffffffffffffffffffffffffffffffffffffff1633036101eb576101e68383838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525060019250610419915050565b505050565b6101e661011b565b60006101fd6103d9565b73ffffffffffffffffffffffffffffffffffffffff163303610226576102216103ab565b905090565b61022e61011b565b90565b6102396103d9565b73ffffffffffffffffffffffffffffffffffffffff1633036101775761017481610444565b60006102686103d9565b73ffffffffffffffffffffffffffffffffffffffff163303610226576102216103d9565b60606102b183836040518060600160405280602781526020016109bb602791396104a5565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b6102dc6103d9565b73ffffffffffffffffffffffffffffffffffffffff163303610133576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f7879207461726760648201527f6574000000000000000000000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b600061022161052a565b3660008037600080366000845af43d6000803e8080156103d4573d6000f35b3d6000fd5b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b5473ffffffffffffffffffffffffffffffffffffffff16919050565b61042283610552565b60008251118061042f5750805b156101e65761043e838361028c565b50505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61046d6103d9565b6040805173ffffffffffffffffffffffffffffffffffffffff928316815291841660208301520160405180910390a16101748161059f565b60606000808573ffffffffffffffffffffffffffffffffffffffff16856040516104cf919061094d565b600060405180830381855af49150503d806000811461050a576040519150601f19603f3d011682016040523d82523d6000602084013e61050f565b606091505b5091509150610520868383876106ab565b9695505050505050565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc6103fd565b61055b81610753565b60405173ffffffffffffffffffffffffffffffffffffffff8216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b73ffffffffffffffffffffffffffffffffffffffff8116610642576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016103a2565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9290921691909117905550565b6060831561074157825160000361073a5773ffffffffffffffffffffffffffffffffffffffff85163b61073a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016103a2565b508161074b565b61074b838361081e565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff81163b6107f7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201527f6f74206120636f6e74726163740000000000000000000000000000000000000060648201526084016103a2565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc610665565b81511561082e5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103a29190610969565b803573ffffffffffffffffffffffffffffffffffffffff8116811461088657600080fd5b919050565b60006020828403121561089d57600080fd5b6102b182610862565b6000806000604084860312156108bb57600080fd5b6108c484610862565b9250602084013567ffffffffffffffff808211156108e157600080fd5b818601915086601f8301126108f557600080fd5b81358181111561090457600080fd5b87602082850101111561091657600080fd5b6020830194508093505050509250925092565b60005b8381101561094457818101518382015260200161092c565b50506000910152565b6000825161095f818460208701610929565b9190910192915050565b6020815260008251806020840152610988816040850160208701610929565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220a1af0d6cb4f1e31496a4c5c1448913bce4bd6ad3a39e47c6f7190c114d6f9bf464736f6c63430008110033", - "storage": { - "0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0x0000000000000000000000000000000000000000000000000000000000000068": "0x00000000000000a40d5f56745a118d0906a34e69aec8c0db1cb8fa0000000100", - "0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103": "0x000000000000000000000000f065bae7c019ff5627e09ed48d4eea317d211956", - "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc": "0x000000000000000000000000f23919bb44bca81aeab4586be71ee3fd4e99b951" - } - }, - { - "contractName": "PolygonZkEVMGlobalExitRootL2 implementation", - "balance": "0", - "nonce": "1", - "address": "0xDc64a140Aa3E981100a9becA4E685f962f0cF6C9", - "bytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806301fd904414610051578063257b36321461006d57806333d6247d1461008d578063a3c573eb146100a2575b600080fd5b61005a60015481565b6040519081526020015b60405180910390f35b61005a61007b366004610162565b60006020819052908152604090205481565b6100a061009b366004610162565b6100ee565b005b6100c97f000000000000000000000000ff0ee8ea08cef5cb4322777f5cc3e8a584b8a4a081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610064565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000ff0ee8ea08cef5cb4322777f5cc3e8a584b8a4a0161461015d576040517fb49365dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600155565b60006020828403121561017457600080fd5b503591905056fea2646970667358221220a187fc278346c1b61c449ea3641002b6eac2bda3351a122a12c35099f933696864736f6c63430008110033" - }, - { - "contractName": "PolygonZkEVMGlobalExitRootL2 proxy", - "balance": "0", - "nonce": "1", - "address": "0xa40d5f56745a118d0906a34e69aec8c0db1cb8fa", - "bytecode": "0x60806040526004361061004e5760003560e01c80633659cfe6146100655780634f1ef286146100855780635c60da1b146100985780638f283970146100c9578063f851a440146100e95761005d565b3661005d5761005b6100fe565b005b61005b6100fe565b34801561007157600080fd5b5061005b6100803660046106ca565b610118565b61005b6100933660046106e5565b61015f565b3480156100a457600080fd5b506100ad6101d0565b6040516001600160a01b03909116815260200160405180910390f35b3480156100d557600080fd5b5061005b6100e43660046106ca565b61020b565b3480156100f557600080fd5b506100ad610235565b610106610292565b610116610111610331565b61033b565b565b61012061035f565b6001600160a01b0316336001600160a01b031614156101575761015481604051806020016040528060008152506000610392565b50565b6101546100fe565b61016761035f565b6001600160a01b0316336001600160a01b031614156101c8576101c38383838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525060019250610392915050565b505050565b6101c36100fe565b60006101da61035f565b6001600160a01b0316336001600160a01b03161415610200576101fb610331565b905090565b6102086100fe565b90565b61021361035f565b6001600160a01b0316336001600160a01b0316141561015757610154816103f1565b600061023f61035f565b6001600160a01b0316336001600160a01b03161415610200576101fb61035f565b606061028583836040518060600160405280602781526020016107e460279139610445565b9392505050565b3b151590565b61029a61035f565b6001600160a01b0316336001600160a01b031614156101165760405162461bcd60e51b815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f78792074617267606482015261195d60f21b608482015260a4015b60405180910390fd5b60006101fb610519565b3660008037600080366000845af43d6000803e80801561035a573d6000f35b3d6000fd5b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b546001600160a01b0316919050565b61039b83610541565b6040516001600160a01b038416907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a26000825111806103dc5750805b156101c3576103eb8383610260565b50505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f61041a61035f565b604080516001600160a01b03928316815291841660208301520160405180910390a1610154816105e9565b6060833b6104a45760405162461bcd60e51b815260206004820152602660248201527f416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f6044820152651b9d1c9858dd60d21b6064820152608401610328565b600080856001600160a01b0316856040516104bf9190610794565b600060405180830381855af49150503d80600081146104fa576040519150601f19603f3d011682016040523d82523d6000602084013e6104ff565b606091505b509150915061050f828286610675565b9695505050505050565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc610383565b803b6105a55760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b6064820152608401610328565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5b80546001600160a01b0319166001600160a01b039290921691909117905550565b6001600160a01b03811661064e5760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b6064820152608401610328565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61036105c8565b60608315610684575081610285565b8251156106945782518084602001fd5b8160405162461bcd60e51b815260040161032891906107b0565b80356001600160a01b03811681146106c557600080fd5b919050565b6000602082840312156106dc57600080fd5b610285826106ae565b6000806000604084860312156106fa57600080fd5b610703846106ae565b9250602084013567ffffffffffffffff8082111561072057600080fd5b818601915086601f83011261073457600080fd5b81358181111561074357600080fd5b87602082850101111561075557600080fd5b6020830194508093505050509250925092565b60005b8381101561078357818101518382015260200161076b565b838111156103eb5750506000910152565b600082516107a6818460208701610768565b9190910192915050565b60208152600082518060208401526107cf816040850160208701610768565b601f01601f1916919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a26469706673582212204675187caf3a43285d9a2c1844a981e977bd52a85ff073e7fc649f73847d70a464736f6c63430008090033", - "storage": { - "0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103": "0x000000000000000000000000f065bae7c019ff5627e09ed48d4eea317d211956", - "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc": "0x000000000000000000000000dc64a140aa3e981100a9beca4e685f962f0cf6c9" - } - }, - { - "contractName": "PolygonZkEVMTimelock", - "balance": "0", - "nonce": "1", - "address": "0x0165878A594ca255338adfa4d48449f69242Eb8F", - "bytecode": "0x6080604052600436106101c65760003560e01c806364d62353116100f7578063b1c5f42711610095578063d547741f11610064578063d547741f14610661578063e38335e514610681578063f23a6e6114610694578063f27a0c92146106d957600080fd5b8063b1c5f427146105af578063bc197c81146105cf578063c4d252f514610614578063d45c44351461063457600080fd5b80638f61f4f5116100d15780638f61f4f5146104e157806391d1485414610515578063a217fddf14610566578063b08e51c01461057b57600080fd5b806364d62353146104815780638065657f146104a15780638f2a0bb0146104c157600080fd5b8063248a9ca31161016457806331d507501161013e57806331d50750146103c857806336568abe146103e85780633a6aae7214610408578063584b153e1461046157600080fd5b8063248a9ca3146103475780632ab0f529146103775780632f2ff15d146103a857600080fd5b80630d3cf6fc116101a05780630d3cf6fc1461026b578063134008d31461029f57806313bc9f20146102b2578063150b7a02146102d257600080fd5b806301d5062a146101d257806301ffc9a7146101f457806307bd02651461022957600080fd5b366101cd57005b600080fd5b3480156101de57600080fd5b506101f26101ed366004611c52565b6106ee565b005b34801561020057600080fd5b5061021461020f366004611cc7565b610783565b60405190151581526020015b60405180910390f35b34801561023557600080fd5b5061025d7fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e6381565b604051908152602001610220565b34801561027757600080fd5b5061025d7f5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca581565b6101f26102ad366004611d09565b6107df565b3480156102be57600080fd5b506102146102cd366004611d75565b6108d7565b3480156102de57600080fd5b506103166102ed366004611e9a565b7f150b7a0200000000000000000000000000000000000000000000000000000000949350505050565b6040517fffffffff000000000000000000000000000000000000000000000000000000009091168152602001610220565b34801561035357600080fd5b5061025d610362366004611d75565b60009081526020819052604090206001015490565b34801561038357600080fd5b50610214610392366004611d75565b6000908152600160208190526040909120541490565b3480156103b457600080fd5b506101f26103c3366004611f02565b6108fd565b3480156103d457600080fd5b506102146103e3366004611d75565b610927565b3480156103f457600080fd5b506101f2610403366004611f02565b610940565b34801561041457600080fd5b5061043c7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610220565b34801561046d57600080fd5b5061021461047c366004611d75565b6109f8565b34801561048d57600080fd5b506101f261049c366004611d75565b610a0e565b3480156104ad57600080fd5b5061025d6104bc366004611d09565b610ade565b3480156104cd57600080fd5b506101f26104dc366004611f73565b610b1d565b3480156104ed57600080fd5b5061025d7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc181565b34801561052157600080fd5b50610214610530366004611f02565b60009182526020828152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b34801561057257600080fd5b5061025d600081565b34801561058757600080fd5b5061025d7ffd643c72710c63c0180259aba6b2d05451e3591a24e58b62239378085726f78381565b3480156105bb57600080fd5b5061025d6105ca366004612025565b610d4f565b3480156105db57600080fd5b506103166105ea36600461214e565b7fbc197c810000000000000000000000000000000000000000000000000000000095945050505050565b34801561062057600080fd5b506101f261062f366004611d75565b610d94565b34801561064057600080fd5b5061025d61064f366004611d75565b60009081526001602052604090205490565b34801561066d57600080fd5b506101f261067c366004611f02565b610e8f565b6101f261068f366004612025565b610eb4565b3480156106a057600080fd5b506103166106af3660046121f8565b7ff23a6e610000000000000000000000000000000000000000000000000000000095945050505050565b3480156106e557600080fd5b5061025d611161565b7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc161071881611244565b6000610728898989898989610ade565b90506107348184611251565b6000817f4cf4410cc57040e44862ef0f45f3dd5a5e02db8eb8add648d4b0e236f1d07dca8b8b8b8b8b8a604051610770969594939291906122a6565b60405180910390a3505050505050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e00000000000000000000000000000000000000000000000000000000014806107d957506107d98261139e565b92915050565b600080527fdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d70696020527f5ba6852781629bcdcd4bdaa6de76d786f1c64b16acdac474e55bebc0ea157951547fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e639060ff1661085c5761085c8133611435565b600061086c888888888888610ade565b905061087881856114ed565b6108848888888861162a565b6000817fc2617efa69bab66782fa219543714338489c4e9e178271560a91b82c3f612b588a8a8a8a6040516108bc94939291906122f1565b60405180910390a36108cd8161172e565b5050505050505050565b6000818152600160205260408120546001811180156108f65750428111155b9392505050565b60008281526020819052604090206001015461091881611244565b61092283836117d7565b505050565b60008181526001602052604081205481905b1192915050565b73ffffffffffffffffffffffffffffffffffffffff811633146109ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c66000000000000000000000000000000000060648201526084015b60405180910390fd5b6109f482826118c7565b5050565b6000818152600160208190526040822054610939565b333014610a9d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f54696d656c6f636b436f6e74726f6c6c65723a2063616c6c6572206d7573742060448201527f62652074696d656c6f636b00000000000000000000000000000000000000000060648201526084016109e1565b60025460408051918252602082018390527f11c24f4ead16507c69ac467fbd5e4eed5fb5c699626d2cc6d66421df253886d5910160405180910390a1600255565b6000868686868686604051602001610afb969594939291906122a6565b6040516020818303038152906040528051906020012090509695505050505050565b7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc1610b4781611244565b888714610bd6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b888514610c65576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b6000610c778b8b8b8b8b8b8b8b610d4f565b9050610c838184611251565b60005b8a811015610d415780827f4cf4410cc57040e44862ef0f45f3dd5a5e02db8eb8add648d4b0e236f1d07dca8e8e85818110610cc357610cc3612331565b9050602002016020810190610cd89190612360565b8d8d86818110610cea57610cea612331565b905060200201358c8c87818110610d0357610d03612331565b9050602002810190610d15919061237b565b8c8b604051610d29969594939291906122a6565b60405180910390a3610d3a8161240f565b9050610c86565b505050505050505050505050565b60008888888888888888604051602001610d709897969594939291906124f7565b60405160208183030381529060405280519060200120905098975050505050505050565b7ffd643c72710c63c0180259aba6b2d05451e3591a24e58b62239378085726f783610dbe81611244565b610dc7826109f8565b610e53576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20636160448201527f6e6e6f742062652063616e63656c6c656400000000000000000000000000000060648201526084016109e1565b6000828152600160205260408082208290555183917fbaa1eb22f2a492ba1a5fea61b8df4d27c6c8b5f3971e63bb58fa14ff72eedb7091a25050565b600082815260208190526040902060010154610eaa81611244565b61092283836118c7565b600080527fdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d70696020527f5ba6852781629bcdcd4bdaa6de76d786f1c64b16acdac474e55bebc0ea157951547fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e639060ff16610f3157610f318133611435565b878614610fc0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b87841461104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b60006110618a8a8a8a8a8a8a8a610d4f565b905061106d81856114ed565b60005b8981101561114b5760008b8b8381811061108c5761108c612331565b90506020020160208101906110a19190612360565b905060008a8a848181106110b7576110b7612331565b9050602002013590503660008a8a868181106110d5576110d5612331565b90506020028101906110e7919061237b565b915091506110f78484848461162a565b84867fc2617efa69bab66782fa219543714338489c4e9e178271560a91b82c3f612b588686868660405161112e94939291906122f1565b60405180910390a350505050806111449061240f565b9050611070565b506111558161172e565b50505050505050505050565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff161580159061123257507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166315064c966040518163ffffffff1660e01b8152600401602060405180830381865afa15801561120e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061123291906125be565b1561123d5750600090565b5060025490565b61124e8133611435565b50565b61125a82610927565b156112e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20616c60448201527f7265616479207363686564756c6564000000000000000000000000000000000060648201526084016109e1565b6112ef611161565b81101561137e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f54696d656c6f636b436f6e74726f6c6c65723a20696e73756666696369656e7460448201527f2064656c6179000000000000000000000000000000000000000000000000000060648201526084016109e1565b61138881426125e0565b6000928352600160205260409092209190915550565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b0000000000000000000000000000000000000000000000000000000014806107d957507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146107d9565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff166109f4576114738161197e565b61147e83602061199d565b60405160200161148f929190612617565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f08c379a00000000000000000000000000000000000000000000000000000000082526109e191600401612698565b6114f6826108d7565b611582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20697360448201527f206e6f742072656164790000000000000000000000000000000000000000000060648201526084016109e1565b80158061159e5750600081815260016020819052604090912054145b6109f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f54696d656c6f636b436f6e74726f6c6c65723a206d697373696e67206465706560448201527f6e64656e6379000000000000000000000000000000000000000000000000000060648201526084016109e1565b60008473ffffffffffffffffffffffffffffffffffffffff168484846040516116549291906126e9565b60006040518083038185875af1925050503d8060008114611691576040519150601f19603f3d011682016040523d82523d6000602084013e611696565b606091505b5050905080611727576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603360248201527f54696d656c6f636b436f6e74726f6c6c65723a20756e6465726c79696e67207460448201527f72616e73616374696f6e2072657665727465640000000000000000000000000060648201526084016109e1565b5050505050565b611737816108d7565b6117c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20697360448201527f206e6f742072656164790000000000000000000000000000000000000000000060648201526084016109e1565b600090815260016020819052604090912055565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff166109f45760008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556118693390565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16156109f45760008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60606107d973ffffffffffffffffffffffffffffffffffffffff831660145b606060006119ac8360026126f9565b6119b79060026125e0565b67ffffffffffffffff8111156119cf576119cf611d8e565b6040519080825280601f01601f1916602001820160405280156119f9576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110611a3057611a30612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110611a9357611a93612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506000611acf8460026126f9565b611ada9060016125e0565b90505b6001811115611b77577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110611b1b57611b1b612331565b1a60f81b828281518110611b3157611b31612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060049490941c93611b7081612710565b9050611add565b5083156108f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e7460448201526064016109e1565b803573ffffffffffffffffffffffffffffffffffffffff81168114611c0457600080fd5b919050565b60008083601f840112611c1b57600080fd5b50813567ffffffffffffffff811115611c3357600080fd5b602083019150836020828501011115611c4b57600080fd5b9250929050565b600080600080600080600060c0888a031215611c6d57600080fd5b611c7688611be0565b965060208801359550604088013567ffffffffffffffff811115611c9957600080fd5b611ca58a828b01611c09565b989b979a50986060810135976080820135975060a09091013595509350505050565b600060208284031215611cd957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146108f657600080fd5b60008060008060008060a08789031215611d2257600080fd5b611d2b87611be0565b955060208701359450604087013567ffffffffffffffff811115611d4e57600080fd5b611d5a89828a01611c09565b979a9699509760608101359660809091013595509350505050565b600060208284031215611d8757600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611e0457611e04611d8e565b604052919050565b600082601f830112611e1d57600080fd5b813567ffffffffffffffff811115611e3757611e37611d8e565b611e6860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611dbd565b818152846020838601011115611e7d57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611eb057600080fd5b611eb985611be0565b9350611ec760208601611be0565b925060408501359150606085013567ffffffffffffffff811115611eea57600080fd5b611ef687828801611e0c565b91505092959194509250565b60008060408385031215611f1557600080fd5b82359150611f2560208401611be0565b90509250929050565b60008083601f840112611f4057600080fd5b50813567ffffffffffffffff811115611f5857600080fd5b6020830191508360208260051b8501011115611c4b57600080fd5b600080600080600080600080600060c08a8c031215611f9157600080fd5b893567ffffffffffffffff80821115611fa957600080fd5b611fb58d838e01611f2e565b909b50995060208c0135915080821115611fce57600080fd5b611fda8d838e01611f2e565b909950975060408c0135915080821115611ff357600080fd5b506120008c828d01611f2e565b9a9d999c50979a969997986060880135976080810135975060a0013595509350505050565b60008060008060008060008060a0898b03121561204157600080fd5b883567ffffffffffffffff8082111561205957600080fd5b6120658c838d01611f2e565b909a50985060208b013591508082111561207e57600080fd5b61208a8c838d01611f2e565b909850965060408b01359150808211156120a357600080fd5b506120b08b828c01611f2e565b999c989b509699959896976060870135966080013595509350505050565b600082601f8301126120df57600080fd5b8135602067ffffffffffffffff8211156120fb576120fb611d8e565b8160051b61210a828201611dbd565b928352848101820192828101908785111561212457600080fd5b83870192505b848310156121435782358252918301919083019061212a565b979650505050505050565b600080600080600060a0868803121561216657600080fd5b61216f86611be0565b945061217d60208701611be0565b9350604086013567ffffffffffffffff8082111561219a57600080fd5b6121a689838a016120ce565b945060608801359150808211156121bc57600080fd5b6121c889838a016120ce565b935060808801359150808211156121de57600080fd5b506121eb88828901611e0c565b9150509295509295909350565b600080600080600060a0868803121561221057600080fd5b61221986611be0565b945061222760208701611be0565b93506040860135925060608601359150608086013567ffffffffffffffff81111561225157600080fd5b6121eb88828901611e0c565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff8716815285602082015260a0604082015260006122dc60a08301868861225d565b60608301949094525060800152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8516815283602082015260606040820152600061232760608301848661225d565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561237257600080fd5b6108f682611be0565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126123b057600080fd5b83018035915067ffffffffffffffff8211156123cb57600080fd5b602001915036819003821315611c4b57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612440576124406123e0565b5060010190565b81835260006020808501808196508560051b810191508460005b878110156124ea57828403895281357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18836030181126124a057600080fd5b8701858101903567ffffffffffffffff8111156124bc57600080fd5b8036038213156124cb57600080fd5b6124d686828461225d565b9a87019a9550505090840190600101612461565b5091979650505050505050565b60a0808252810188905260008960c08301825b8b8110156125455773ffffffffffffffffffffffffffffffffffffffff61253084611be0565b1682526020928301929091019060010161250a565b5083810360208501528881527f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff89111561257e57600080fd5b8860051b9150818a602083013701828103602090810160408501526125a69082018789612447565b60608401959095525050608001529695505050505050565b6000602082840312156125d057600080fd5b815180151581146108f657600080fd5b808201808211156107d9576107d96123e0565b60005b8381101561260e5781810151838201526020016125f6565b50506000910152565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161264f8160178501602088016125f3565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000601791840191820152835161268c8160288401602088016125f3565b01602801949350505050565b60208152600082518060208401526126b78160408501602087016125f3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b8183823760009101908152919050565b80820281158282048414176107d9576107d96123e0565b60008161271f5761271f6123e0565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff019056fea26469706673582212206416c4e08f97752b4bb06159524dac058d3dccd8775e57ef1b01505751ebf7af64736f6c63430008110033", - "storage": { - "0x0000000000000000000000000000000000000000000000000000000000000002": "0x000000000000000000000000000000000000000000000000000000000000000a", - "0xaedcc9e7897c0d335bdc5d92fe3a8b4f23727fe558cd1c19f332b28716a30559": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0xf5e61edb9c9cc6bfbae4463e9a2b1dd6ac3b44ddef38f18016e56ba0363910d9": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0x64494413541ff93b31aa309254e3fed72a7456e9845988b915b4c7a7ceba8814": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", - "0x60b9d94c75b7b3f721925089391e4644cd890cb5e6466f9596dfbd2c54e0b280": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0x3412d5605ac6cd444957cedb533e5dacad6378b4bc819ebe3652188a665066d6": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", - "0x4b63b79f1e338a49559dcd3193ac9eecc50d0f275d24e97cc8c319e5a31a8bd0": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0xdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d706a": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", - "0x800d5dfe4bba53eedee06cd4546a27da8de00f12db83f56062976d4493fda899": "0x0000000000000000000000000000000000000000000000000000000000000001", - "0xc3ad33e20b0c56a223ad5104fff154aa010f8715b9c981fd38fdc60a4d1a52fc": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5" - } - }, - { - "accountName": "keyless Deployer", - "balance": "0", - "nonce": "1", - "address": "0x20E7077d25fe79C5F6c2D3ae4905E96aA7C89c13" - }, - { - "accountName": "deployer", - "balance": "100000000000000000000000", - "nonce": "8", - "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" - } - ] - } \ No newline at end of file diff --git a/test/config/node/init_event_db.sql b/test/config/node/init_event_db.sql new file mode 100644 index 00000000..c45a6ba1 --- /dev/null +++ b/test/config/node/init_event_db.sql @@ -0,0 +1,14 @@ +CREATE TYPE level_t AS ENUM ('emerg', 'alert', 'crit', 'err', 'warning', 'notice', 'info', 'debug'); + +CREATE TABLE public.event ( + id BIGSERIAL PRIMARY KEY, + received_at timestamp WITH TIME ZONE default CURRENT_TIMESTAMP, + ip_address inet, + source varchar(32) not null, + component varchar(32), + level level_t not null, + event_id varchar(32) not null, + description text, + data bytea, + json jsonb +); diff --git a/test/config/node/root-ca-cert b/test/config/node/root-ca-cert new file mode 100644 index 00000000..1ec4f0ca --- /dev/null +++ b/test/config/node/root-ca-cert @@ -0,0 +1,30 @@ +-----BEGIN CERTIFICATE----- +MIIFKjCCAxICCQCdkV+iL/cBTzANBgkqhkiG9w0BAQsFADBWMQswCQYDVQQGEwJD +TjEQMA4GA1UECAwHQmVpamluZzEQMA4GA1UEBwwHQmVpamluZzEQMA4GA1UECgwH +QWxpYmFiYTERMA8GA1UEAwwIQWxpS2Fma2EwIBcNMjIwNTExMTAzOTMxWhgPMjEy +MjA0MTcxMDM5MzFaMFYxCzAJBgNVBAYTAkNOMRAwDgYDVQQIDAdCZWlqaW5nMRAw +DgYDVQQHDAdCZWlqaW5nMRAwDgYDVQQKDAdBbGliYWJhMREwDwYDVQQDDAhBbGlL +YWZrYTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAL315apERcpAkDAB +SY4A2bGrRZO4CXj4nvqbwEZ50f1HlwABjzUMKXES7lWrOwrnqZjSIgm5woqu+Pr4 +sWhKFHN19SSnjeKilQoL8SzMk0p22QJK2sqKRMuHtoBtL6uOT+ykV16IEg0fY2Uu +/oX/sF2LAVCIl1IGc2HVKUr56c0/mM6V6Ur5Sum7ctKk2dm6YS5gwDOXcqAaZhwd +jVzqLEW8hmsMS7n+d2/NIJMqXvTHDRQ74xhR9tN2w92keEBGOQoMG/Qw0RvS1aQi +RKpNpvCE7z543istYuFbFji646u6kRCr7I2i4RwV0qXVM1djcS+PysUsIX4mEjdP +Kq0Fptzsii3aeTFuNswOlo5GieE3psVoymIP2HWd6xmlmFaX3Z8Nd4PxA6h0uRIY +tRbLkHw8WfOAl4dXxWQFkbvNYNLRB5xZUYjm3CA+ZhYfJRtNlPa2247Psnbup6CH +k3DP+aExdLmbtyugZO/lNqi9WMZ0qLFGXZDz8astgJPGKiCjihccpP1cdzGlCzGu +iE6S25JEBuXPl4wg4GXNuCg6tcEKL2qinvbrCimrilWuFajBh7hRH0dgkhezw6xU ++3++ZCebEJOXZ8byn3v/gmyx2PDnKlBPcXCy23nadbiX/zpNvNvCqAewajm9AlWY +fXbCl5TkUnyMPsh0rwWeeRYR2kM3AgMBAAEwDQYJKoZIhvcNAQELBQADggIBADxW +YJoWh9DVtwFGp8TOrlbZ7kwflKFv8Hew4SX00K5GwKgmnn3fjdR0F8rZ2ar/BqdD +zR63sv9LGjMci9NWAqPqN5MyKB97KrFV6nHzcYLRmT+ltolqcfp5MeGCqka7ZTEL +t658xxaSXNEY9HGHYskIu7mWd41KAj0RLRJnEEOrCSZzfpzG4LdD6J0u7wpyJSYL +jGxi2xswt5C0x790LS/JmFq65c/vzfATjbmu6XSO3UvtsADpj0pH3FJFhLzoT67o +NrUeFEHrzsMc7JenYmPIYmEb4xXlfctjCzLaiNG3u8uKwXGBk/oagAwXCsI8I0pR +wtW/QedXxlFtUfATRZnI/eLqvJ5cQ6aXg/GyJtAv+ccFf004K1ER00ECe738WNXm ++6NNkhN5gPhwsfoDhq+a7Zmvj9+x/XDjSRqZ8j+XIMi9ZQjTwUAg9JmnhyR4eJXn +oQAxGc3ii98YoAspKZGRX6LoRfYbNE3TXJsSzGw73+PqS1y74xNNmMx2XX6IV/53 +Is5mA8fli6BIEKkAgE6Pn0t6v5EP6haVF84vJazYRIlYflR2mi8p8dU6kohiC79C +e4seRTTZgyXU+5dgFIXqagub2A79tRtPAr+4Xi84jzY84ceUwqX2fxRwkfaUUJb8 +Hh2q+P+VJeK50B83DZ4ui+WNJbAaAbcLMsn/idX3 +-----END CERTIFICATE----- \ No newline at end of file diff --git a/test/config/node/test.da.toml b/test/config/node/test.da.toml new file mode 100644 index 00000000..0181d856 --- /dev/null +++ b/test/config/node/test.da.toml @@ -0,0 +1,34 @@ +PrivateKey = {Path = "/pk/test-member.keystore", Password = "testonly"} + +[L1] +WsURL = "ws://xgon-mock-l1-network:8546" +RpcURL = "http://xgon-mock-l1-network:8545" +ZkEVMAddress = "0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C" +DataCommitteeAddress = "0x6Ae5b0863dBF3477335c0102DBF432aFf04ceb22" +Timeout = "3m" +RetryPeriod = "5s" + +[Log] +Environment = "development" # "production" or "development" +Level = "debug" +Outputs = ["stderr"] + +[DB] +User = "committee_user" +Password = "committee_password" +Name = "committee_db" +Host = "xgon-data-availability-db" +Port = "5432" +EnableLog = false +MaxConns = 200 + +[RPC] +Host = "0.0.0.0" +Port = 8444 +ReadTimeout = "60s" +WriteTimeout = "60s" +MaxRequestsPerIPAndSecond = 500 +SequencerNodeURI = "" +EnableL2SuggestedGasPricePolling = false + [RPC.WebSockets] + Enabled = false diff --git a/test/config/node/test.genesis.config.json b/test/config/node/test.genesis.config.json new file mode 100644 index 00000000..1c27a3f7 --- /dev/null +++ b/test/config/node/test.genesis.config.json @@ -0,0 +1,123 @@ +{ + "l1Config": { + "chainId": 1337, + "polygonZkEVMAddress": "0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C", + "maticTokenAddress": "0xcFE6D77a653b988203BfAc9C6a69eA9D583bdC2b", + "polygonZkEVMGlobalExitRootAddress": "0xEd236da21Ff62bC7B62608AdB818da49E8549fa7", + "dataCommitteeContract": "0x6Ae5b0863dBF3477335c0102DBF432aFf04ceb22" + }, + "genesisBlockNumber": 231, + "root": "0x6748c8d646d0d45108a0771c1c96412da84303eaee74f6e101ea5dabdbb757ca", + "genesis": [ + { + "contractName": "WETHzkEVM", + "balance": "0", + "nonce": "1", + "address": "0x82109a709138A2953C720D3d775168717b668ba6", + "bytecode": "0x608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063a457c2d71161008c578063d505accf11610066578063d505accf14610379578063dd62ed3e1461038c578063ffa1ad74146103d257600080fd5b8063a457c2d71461032c578063a9059cbb1461033f578063cd0d00961461035257600080fd5b806395d89b41116100bd57806395d89b41146102c55780639dc29fac146102cd578063a3c573eb146102e057600080fd5b806370a082311461026f5780637ecebe00146102a557600080fd5b806330adf81f1161012f5780633644e515116101145780633644e5151461023f578063395093511461024757806340c10f191461025a57600080fd5b806330adf81f14610209578063313ce5671461023057600080fd5b806318160ddd1161016057806318160ddd146101bd57806320606b70146101cf57806323b872dd146101f657600080fd5b806306fdde031461017c578063095ea7b31461019a575b600080fd5b61018461040e565b60405161019191906113c2565b60405180910390f35b6101ad6101a8366004611457565b6104a0565b6040519015158152602001610191565b6002545b604051908152602001610191565b6101c17f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f81565b6101ad610204366004611481565b6104ba565b6101c17f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b60405160128152602001610191565b6101c16104de565b6101ad610255366004611457565b61053a565b61026d610268366004611457565b610586565b005b6101c161027d3660046114bd565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101c16102b33660046114bd565b60056020526000908152604090205481565b61018461065e565b61026d6102db366004611457565b61066d565b6103077f00000000000000000000000010b65c586f795af3eccee594fe4e38e1f059f78081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610191565b6101ad61033a366004611457565b61073c565b6101ad61034d366004611457565b61080d565b6101c17f0000000000000000000000000000000000000000000000000000000000007a6981565b61026d6103873660046114df565b61081b565b6101c161039a366004611552565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101846040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525081565b60606003805461041d90611585565b80601f016020809104026020016040519081016040528092919081815260200182805461044990611585565b80156104965780601f1061046b57610100808354040283529160200191610496565b820191906000526020600020905b81548152906001019060200180831161047957829003601f168201915b5050505050905090565b6000336104ae818585610b51565b60019150505b92915050565b6000336104c8858285610d05565b6104d3858585610ddc565b506001949350505050565b60007f0000000000000000000000000000000000000000000000000000000000007a694614610515576105104661104b565b905090565b507f24ef62eb3c0f520fee02b5f635cc2a78ff79af541e9a7cc5239a62d7f80e9e7a90565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906104ae9082908690610581908790611607565b610b51565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000010b65c586f795af3eccee594fe4e38e1f059f7801614610650576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d4272696467650000000000000000000000000000000060648201526084015b60405180910390fd5b61065a8282611113565b5050565b60606004805461041d90611585565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000010b65c586f795af3eccee594fe4e38e1f059f7801614610732576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d427269646765000000000000000000000000000000006064820152608401610647565b61065a8282611206565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919083811015610800576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f0000000000000000000000000000000000000000000000000000006064820152608401610647565b6104d38286868403610b51565b6000336104ae818585610ddc565b834211156108aa576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f546f6b656e577261707065643a3a7065726d69743a204578706972656420706560448201527f726d6974000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff8716600090815260056020526040812080547f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918a918a918a9190866109048361161a565b9091555060408051602081019690965273ffffffffffffffffffffffffffffffffffffffff94851690860152929091166060840152608083015260a082015260c0810186905260e001604051602081830303815290604052805190602001209050600061096f6104de565b6040517f19010000000000000000000000000000000000000000000000000000000000006020820152602281019190915260428101839052606201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120600080855291840180845281905260ff89169284019290925260608301879052608083018690529092509060019060a0016020604051602081039080840390855afa158015610a33573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff811615801590610aae57508973ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16145b610b3a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f546f6b656e577261707065643a3a7065726d69743a20496e76616c696420736960448201527f676e6174757265000000000000000000000000000000000000000000000000006064820152608401610647565b610b458a8a8a610b51565b50505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316610bf3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff8216610c96576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f73730000000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610dd65781811015610dc9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610647565b610dd68484848403610b51565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610e7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f64726573730000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff8216610f22576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f65737300000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610fd8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e636500000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610dd6565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f61107661040e565b8051602091820120604080518082018252600181527f310000000000000000000000000000000000000000000000000000000000000090840152805192830193909352918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018390523060a082015260c001604051602081830303815290604052805190602001209050919050565b73ffffffffffffffffffffffffffffffffffffffff8216611190576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610647565b80600260008282546111a29190611607565b909155505073ffffffffffffffffffffffffffffffffffffffff8216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff82166112a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f73000000000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff82166000908152602081905260409020548181101561135f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f63650000000000000000000000000000000000000000000000000000000000006064820152608401610647565b73ffffffffffffffffffffffffffffffffffffffff83166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9101610cf8565b600060208083528351808285015260005b818110156113ef578581018301518582016040015282016113d3565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461145257600080fd5b919050565b6000806040838503121561146a57600080fd5b6114738361142e565b946020939093013593505050565b60008060006060848603121561149657600080fd5b61149f8461142e565b92506114ad6020850161142e565b9150604084013590509250925092565b6000602082840312156114cf57600080fd5b6114d88261142e565b9392505050565b600080600080600080600060e0888a0312156114fa57600080fd5b6115038861142e565b96506115116020890161142e565b95506040880135945060608801359350608088013560ff8116811461153557600080fd5b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561156557600080fd5b61156e8361142e565b915061157c6020840161142e565b90509250929050565b600181811c9082168061159957607f821691505b6020821081036115d2577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156104b4576104b46115d8565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361164b5761164b6115d8565b506001019056fea2646970667358221220d16e68f0bedbd2415d7cd129360764fdbe70ca133f4a3e128a22d3fdfa85164264736f6c63430008140033", + "storage": { + "0x0000000000000000000000000000000000000000000000000000000000000003": "0x577261707065642045746865720000000000000000000000000000000000001a", + "0x0000000000000000000000000000000000000000000000000000000000000004": "0x5745544800000000000000000000000000000000000000000000000000000008" + } + }, + { + "contractName": "PolygonZkEVMDeployer", + "balance": "0", + "nonce": "4", + "address": "0xb169BC523B5399B94c7BDe7108fc543004F09aad", + "bytecode": "0x6080604052600436106100705760003560e01c8063715018a61161004e578063715018a6146100e65780638da5cb5b146100fb578063e11ae6cb14610126578063f2fde38b1461013957600080fd5b80632b79805a146100755780634a94d4871461008a5780636d07dbf81461009d575b600080fd5b610088610083366004610927565b610159565b005b6100886100983660046109c7565b6101cb565b3480156100a957600080fd5b506100bd6100b8366004610a1e565b61020d565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100f257600080fd5b50610088610220565b34801561010757600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166100bd565b610088610134366004610a40565b610234565b34801561014557600080fd5b50610088610154366004610a90565b61029b565b610161610357565b600061016e8585856103d8565b905061017a8183610537565b5060405173ffffffffffffffffffffffffffffffffffffffff821681527fba82f25fed02cd2a23d9f5d11c2ef588d22af5437cbf23bfe61d87257c480e4c9060200160405180910390a15050505050565b6101d3610357565b6101de83838361057b565b506040517f25adb19089b6a549831a273acdf7908cff8b7ee5f551f8d1d37996cf01c5df5b90600090a1505050565b600061021983836105a9565b9392505050565b610228610357565b61023260006105b6565b565b61023c610357565b60006102498484846103d8565b60405173ffffffffffffffffffffffffffffffffffffffff821681529091507fba82f25fed02cd2a23d9f5d11c2ef588d22af5437cbf23bfe61d87257c480e4c9060200160405180910390a150505050565b6102a3610357565b73ffffffffffffffffffffffffffffffffffffffff811661034b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b610354816105b6565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610232576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610342565b600083471015610444576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f437265617465323a20696e73756666696369656e742062616c616e63650000006044820152606401610342565b81516000036104af576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f437265617465323a2062797465636f6465206c656e677468206973207a65726f6044820152606401610342565b8282516020840186f5905073ffffffffffffffffffffffffffffffffffffffff8116610219576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f437265617465323a204661696c6564206f6e206465706c6f79000000000000006044820152606401610342565b6060610219838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c6564000081525061062b565b60606105a1848484604051806060016040528060298152602001610b3d6029913961062b565b949350505050565b6000610219838330610744565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6060824710156106bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610342565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516106e69190610acf565b60006040518083038185875af1925050503d8060008114610723576040519150601f19603f3d011682016040523d82523d6000602084013e610728565b606091505b50915091506107398783838761076e565b979650505050505050565b6000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b606083156108045782516000036107fd5773ffffffffffffffffffffffffffffffffffffffff85163b6107fd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610342565b50816105a1565b6105a183838151156108195781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103429190610aeb565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f83011261088d57600080fd5b813567ffffffffffffffff808211156108a8576108a861084d565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019082821181831017156108ee576108ee61084d565b8160405283815286602085880101111561090757600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000806080858703121561093d57600080fd5b8435935060208501359250604085013567ffffffffffffffff8082111561096357600080fd5b61096f8883890161087c565b9350606087013591508082111561098557600080fd5b506109928782880161087c565b91505092959194509250565b803573ffffffffffffffffffffffffffffffffffffffff811681146109c257600080fd5b919050565b6000806000606084860312156109dc57600080fd5b6109e58461099e565b9250602084013567ffffffffffffffff811115610a0157600080fd5b610a0d8682870161087c565b925050604084013590509250925092565b60008060408385031215610a3157600080fd5b50508035926020909101359150565b600080600060608486031215610a5557600080fd5b8335925060208401359150604084013567ffffffffffffffff811115610a7a57600080fd5b610a868682870161087c565b9150509250925092565b600060208284031215610aa257600080fd5b6102198261099e565b60005b83811015610ac6578181015183820152602001610aae565b50506000910152565b60008251610ae1818460208701610aab565b9190910192915050565b6020815260008251806020840152610b0a816040850160208701610aab565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2063616c6c20776974682076616c7565206661696c6564a2646970667358221220964619cee0e0baf94c6f8763f013be157da5d54c89e5cff4a8caf4266e13f13a64736f6c63430008140033", + "storage": { + "0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000002ecf31ece36ccac2d3222a303b1409233ecbb225" + } + }, + { + "contractName": "ProxyAdmin", + "balance": "0", + "nonce": "1", + "address": "0xa6791C91168866769273e6AFFe603e00269b16ae", + "bytecode": "0x60806040526004361061007b5760003560e01c80639623609d1161004e5780639623609d1461012b57806399a88ec41461013e578063f2fde38b1461015e578063f3b7dead1461017e57600080fd5b8063204e1c7a14610080578063715018a6146100c95780637eff275e146100e05780638da5cb5b14610100575b600080fd5b34801561008c57600080fd5b506100a061009b366004610608565b61019e565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100d557600080fd5b506100de610255565b005b3480156100ec57600080fd5b506100de6100fb36600461062c565b610269565b34801561010c57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166100a0565b6100de610139366004610694565b6102f7565b34801561014a57600080fd5b506100de61015936600461062c565b61038c565b34801561016a57600080fd5b506100de610179366004610608565b6103e8565b34801561018a57600080fd5b506100a0610199366004610608565b6104a4565b60008060008373ffffffffffffffffffffffffffffffffffffffff166040516101ea907f5c60da1b00000000000000000000000000000000000000000000000000000000815260040190565b600060405180830381855afa9150503d8060008114610225576040519150601f19603f3d011682016040523d82523d6000602084013e61022a565b606091505b50915091508161023957600080fd5b8080602001905181019061024d9190610788565b949350505050565b61025d6104f0565b6102676000610571565b565b6102716104f0565b6040517f8f28397000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8281166004830152831690638f283970906024015b600060405180830381600087803b1580156102db57600080fd5b505af11580156102ef573d6000803e3d6000fd5b505050505050565b6102ff6104f0565b6040517f4f1ef28600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841690634f1ef28690349061035590869086906004016107a5565b6000604051808303818588803b15801561036e57600080fd5b505af1158015610382573d6000803e3d6000fd5b5050505050505050565b6103946104f0565b6040517f3659cfe600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8281166004830152831690633659cfe6906024016102c1565b6103f06104f0565b73ffffffffffffffffffffffffffffffffffffffff8116610498576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6104a181610571565b50565b60008060008373ffffffffffffffffffffffffffffffffffffffff166040516101ea907ff851a44000000000000000000000000000000000000000000000000000000000815260040190565b60005473ffffffffffffffffffffffffffffffffffffffff163314610267576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161048f565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b73ffffffffffffffffffffffffffffffffffffffff811681146104a157600080fd5b60006020828403121561061a57600080fd5b8135610625816105e6565b9392505050565b6000806040838503121561063f57600080fd5b823561064a816105e6565b9150602083013561065a816105e6565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000606084860312156106a957600080fd5b83356106b4816105e6565b925060208401356106c4816105e6565b9150604084013567ffffffffffffffff808211156106e157600080fd5b818601915086601f8301126106f557600080fd5b81358181111561070757610707610665565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561074d5761074d610665565b8160405282815289602084870101111561076657600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b60006020828403121561079a57600080fd5b8151610625816105e6565b73ffffffffffffffffffffffffffffffffffffffff8316815260006020604081840152835180604085015260005b818110156107ef578581018301518582016060015282016107d3565b5060006060828601015260607fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050939250505056fea2646970667358221220c9867ffac53151bdb1305d8f5e3e883cd83e5270c7ec09cdc24e837b2e65239064736f6c63430008140033", + "storage": { + "0x0000000000000000000000000000000000000000000000000000000000000000": "0x00000000000000000000000026a093198fa2a20c3508679197f5ae1c9323772a" + } + }, + { + "contractName": "PolygonZkEVMBridge implementation", + "balance": "0", + "nonce": "1", + "address": "0x2F1008CB69C24f06D089ECEA5a51791A6FB74b04", + "bytecode": "0x608060405260043610620001f35760003560e01c80634b2f336d116200010b578063be5831c711620000a1578063dd51f5c1116200006c578063dd51f5c11462000793578063ee25560b14620007b8578063f9eaee0d14620007e9578063fb570834146200081d57600080fd5b8063be5831c714620006f0578063cd586579146200072c578063d02103ca1462000743578063dbc16976146200077b57600080fd5b80639e34070f11620000e25780639e34070f146200064b578063aaa13cc21462000690578063b2169f2c14620006b5578063bab161bf14620006cc57600080fd5b80634b2f336d14620005bd57806379e2cf9714620005ec57806381b1c174146200060457600080fd5b80632dfdf0b5116200018d5780633ae0504711620001585780633ae0504714620004355780633c351e10146200044d5780633cbc795b146200047c5780633e19704314620004c957600080fd5b80632dfdf0b51462000331578063318aee3d146200035857806334ac9cf214620003e15780633797306a146200041057600080fd5b806322e95f2c11620001ce57806322e95f2c14620002775780632cc9f16314620002c25780632cffd02e14620002e75780632d2c9d94146200030c57600080fd5b80630ac1be4314620001f857806315064c9614620002415780632072f6c5146200025d575b600080fd5b3480156200020557600080fd5b50606e546200022c9074010000000000000000000000000000000000000000900460ff1681565b60405190151581526020015b60405180910390f35b3480156200024e57600080fd5b506068546200022c9060ff1681565b3480156200026a57600080fd5b506200027562000842565b005b3480156200028457600080fd5b506200029c6200029636600462003c09565b620008a0565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000238565b348015620002cf57600080fd5b5062000275620002e136600462003c45565b62000943565b348015620002f457600080fd5b50620002756200030636600462003d2f565b62000bf6565b3480156200031957600080fd5b50620002756200032b36600462003d2f565b62001281565b3480156200033e57600080fd5b506200034960535481565b60405190815260200162000238565b3480156200036557600080fd5b50620003af6200037736600462003e15565b606b6020526000908152604090205463ffffffff811690640100000000900473ffffffffffffffffffffffffffffffffffffffff1682565b6040805163ffffffff909316835273ffffffffffffffffffffffffffffffffffffffff90911660208301520162000238565b348015620003ee57600080fd5b50606c546200029c9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156200041d57600080fd5b50620002756200042f36600462003e4b565b62001512565b3480156200044257600080fd5b50620003496200169b565b3480156200045a57600080fd5b50606d546200029c9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156200048957600080fd5b50606d54620004b39074010000000000000000000000000000000000000000900463ffffffff1681565b60405163ffffffff909116815260200162000238565b348015620004d657600080fd5b5062000349620004e836600462003e7b565b6040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b348015620005ca57600080fd5b50606e546200029c9073ffffffffffffffffffffffffffffffffffffffff1681565b348015620005f957600080fd5b506200027562001781565b3480156200061157600080fd5b506200029c6200062336600462003f05565b606a6020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b3480156200065857600080fd5b506200022c6200066a36600462003f05565b600881901c600090815260696020526040902054600160ff9092169190911b9081161490565b3480156200069d57600080fd5b506200029c620006af36600462003f1f565b620017bb565b62000275620006c636600462003fd3565b620019a7565b348015620006d957600080fd5b50606854620004b390610100900463ffffffff1681565b348015620006fd57600080fd5b50606854620004b390790100000000000000000000000000000000000000000000000000900463ffffffff1681565b620002756200073d36600462004060565b62001c91565b3480156200075057600080fd5b506068546200029c9065010000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b3480156200078857600080fd5b506200027562002368565b348015620007a057600080fd5b5062000275620007b236600462004102565b620023c4565b348015620007c557600080fd5b5062000349620007d736600462003f05565b60696020526000908152604090205481565b348015620007f657600080fd5b506200022c6200080836600462003e15565b606f6020526000908152604090205460ff1681565b3480156200082a57600080fd5b506200022c6200083c36600462004135565b620025ba565b606c5473ffffffffffffffffffffffffffffffffffffffff16331462000894576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200089e620026a3565b565b6040805160e084901b7fffffffff0000000000000000000000000000000000000000000000000000000016602080830191909152606084901b7fffffffffffffffffffffffffffffffffffffffff00000000000000000000000016602483015282516018818403018152603890920183528151918101919091206000908152606a909152205473ffffffffffffffffffffffffffffffffffffffff165b92915050565b600054610100900460ff1615808015620009645750600054600160ff909116105b80620009805750303b15801562000980575060005460ff166001145b62000a12576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055801562000a7157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b6068805473ffffffffffffffffffffffffffffffffffffffff80891665010000000000027fffffffffffffff0000000000000000000000000000000000000000ffffffffff63ffffffff808d1661010002919091167fffffffffffffff000000000000000000000000000000000000000000000000ff9094169390931717909255606c80548884167fffffffffffffffffffffffff000000000000000000000000000000000000000091821617909155606d805492871674010000000000000000000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009093168885161792909217909155606e80549285169290911691909117905562000b8962002737565b801562000bed57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b60685460ff161562000c34576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62000c4b8b8b8b8b8b8b8b8b8b8b8b6000620027da565b73ffffffffffffffffffffffffffffffffffffffff861662000cfb57606e546040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201869052909116906340c10f1990604401600060405180830381600087803b15801562000cdc57600080fd5b505af115801562000cf1573d6000803e3d6000fd5b5050505062001209565b606d5473ffffffffffffffffffffffffffffffffffffffff878116911614801562000d485750606d5463ffffffff8881167401000000000000000000000000000000000000000090920416145b1562000e0e576040805160008082526020820190925273ffffffffffffffffffffffffffffffffffffffff861690859060405162000d879190620041d7565b60006040518083038185875af1925050503d806000811462000dc6576040519150601f19603f3d011682016040523d82523d6000602084013e62000dcb565b606091505b505090508062000e07576040517f6747a28800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5062001209565b60685463ffffffff61010090910481169088160362000e505762000e4a73ffffffffffffffffffffffffffffffffffffffff87168585620029cb565b62001209565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b1660208201527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606088901b166024820152600090603801604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000818152606a90935291205490915073ffffffffffffffffffffffffffffffffffffffff16806200117b576000808062000f2586880188620042ec565b92509250925060008584848460405162000f3f9062003bc0565b62000f4d93929190620043b9565b8190604051809103906000f590508015801562000f6e573d6000803e3d6000fd5b506040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c81166004830152602482018c9052919250908216906340c10f1990604401600060405180830381600087803b15801562000fe457600080fd5b505af115801562000ff9573d6000803e3d6000fd5b5050505080606a600088815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060405180604001604052808e63ffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815250606b60008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008201518160000160006101000a81548163ffffffff021916908363ffffffff16021790555060208201518160000160046101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055509050507f490e59a1701b938786ac72570a1efeac994a3dbe96e2e883e19e902ace6e6a398d8d838b8b604051620011699594939291906200443f565b60405180910390a15050505062001206565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018790528216906340c10f1990604401600060405180830381600087803b158015620011ec57600080fd5b505af115801562001201573d6000803e3d6000fd5b505050505b50505b6040805163ffffffff8c811682528916602082015273ffffffffffffffffffffffffffffffffffffffff88811682840152861660608201526080810185905290517f25308c93ceeed162da955b3f7ce3e3f93606579e40fb92029faa9efe275459839181900360a00190a15050505050505050505050565b60685460ff1615620012bf576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b620012d68b8b8b8b8b8b8b8b8b8b8b6001620027da565b606e546040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201869052909116906340c10f1990604401600060405180830381600087803b1580156200134b57600080fd5b505af115801562001360573d6000803e3d6000fd5b5050505060008473ffffffffffffffffffffffffffffffffffffffff168789858560405160240162001396949392919062004487565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f1806b5f20000000000000000000000000000000000000000000000000000000017905251620014199190620041d7565b6000604051808303816000865af19150503d806000811462001458576040519150601f19603f3d011682016040523d82523d6000602084013e6200145d565b606091505b505090508062001499576040517f37e391c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805163ffffffff8d811682528a16602082015273ffffffffffffffffffffffffffffffffffffffff89811682840152871660608201526080810186905290517f25308c93ceeed162da955b3f7ce3e3f93606579e40fb92029faa9efe275459839181900360a00190a1505050505050505050505050565b606c5473ffffffffffffffffffffffffffffffffffffffff16331462001564576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606e5474010000000000000000000000000000000000000000900460ff1615158115150362001616576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f416c6c204c3220746f6b656e7320616c7265616479206861766520746865207060448201527f65726d697373696f6e0000000000000000000000000000000000000000000000606482015260840162000a09565b606e805482151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff9091161790556040517f11c1c68b4bf6f68350aa1983fe17ee1d005a7189994475ddbc4b9fc4e4ef02b8906200169090831515815260200190565b60405180910390a150565b605354600090819081805b602081101562001778578083901c600116600103620017095760338160208110620016d557620016d5620044cf565b0154604080516020810192909252810185905260600160405160208183030381529060405280519060200120935062001736565b60408051602081018690529081018390526060016040516020818303038152906040528051906020012093505b604080516020810184905290810183905260600160405160208183030381529060405280519060200120915080806200176f906200452d565b915050620016a6565b50919392505050565b605354606854790100000000000000000000000000000000000000000000000000900463ffffffff1610156200089e576200089e62002aa6565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b1660208201527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606088901b1660248201526000908190603801604051602081830303815290604052805190602001209050600060ff60f81b308360405180602001620018519062003bc0565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f9091011660408190526200189c908d908d908d908d908d9060200162004568565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052620018da9291602001620045a9565b604051602081830303815290604052805190602001206040516020016200196394939291907fff0000000000000000000000000000000000000000000000000000000000000094909416845260609290921b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660018401526015830152603582015260550190565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101209a9950505050505050505050565b60685460ff1615620019e5576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60685463ffffffff87811661010090920416148062001a0b5750600263ffffffff871610155b1562001a43576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b341562001a7c576040517f798ee6f100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606e546040517f9dc29fac0000000000000000000000000000000000000000000000000000000081523360048201526024810186905273ffffffffffffffffffffffffffffffffffffffff90911690639dc29fac90604401600060405180830381600087803b15801562001aef57600080fd5b505af115801562001b04573d6000803e3d6000fd5b50506068546053546040517f501781209a1f8899323b96b4ef08b168df93e0a90c673d1e4cce39366cb62f9b945062001b5a9350600192610100900463ffffffff169133918c918c918c918b918b9190620045dc565b60405180910390a162001c7862001c726001606860019054906101000a900463ffffffff16338a8a8a898960405162001b9592919062004657565b60405180910390206040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b62002b81565b821562001c895762001c8962002aa6565b505050505050565b60685460ff161562001ccf576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b62001cd962002c93565b60685463ffffffff88811661010090920416148062001cff5750600263ffffffff881610155b1562001d37576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060608773ffffffffffffffffffffffffffffffffffffffff881662001dd55788341462001d93576040517fb89240f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606d5473ffffffffffffffffffffffffffffffffffffffff8116945074010000000000000000000000000000000000000000900463ffffffff16925062002213565b341562001e0e576040517f798ee6f100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606e5473ffffffffffffffffffffffffffffffffffffffff9081169089160362001ec8576040517f9dc29fac000000000000000000000000000000000000000000000000000000008152336004820152602481018a905273ffffffffffffffffffffffffffffffffffffffff891690639dc29fac90604401600060405180830381600087803b15801562001ea157600080fd5b505af115801562001eb6573d6000803e3d6000fd5b50505050600092506000935062002213565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152606b602090815260409182902082518084019093525463ffffffff811683526401000000009004909216918101829052901562001fb8576040517f9dc29fac000000000000000000000000000000000000000000000000000000008152336004820152602481018b905273ffffffffffffffffffffffffffffffffffffffff8a1690639dc29fac90604401600060405180830381600087803b15801562001f8b57600080fd5b505af115801562001fa0573d6000803e3d6000fd5b50505050806020015194508060000151935062002211565b606e5474010000000000000000000000000000000000000000900460ff161580156200200a575073ffffffffffffffffffffffffffffffffffffffff89166000908152606f602052604090205460ff16155b1562002042576040517f3759891400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515620020575762002057898b898962002d08565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8b16906370a0823190602401602060405180830381865afa158015620020c5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620020eb919062004667565b90506200211173ffffffffffffffffffffffffffffffffffffffff8b1633308e62003227565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009073ffffffffffffffffffffffffffffffffffffffff8c16906370a0823190602401602060405180830381865afa1580156200217f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620021a5919062004667565b9050620021b3828262004681565b6068548c9850610100900463ffffffff1696509350620021d38762003287565b620021de8c6200339f565b620021e98d620034ac565b604051602001620021fd93929190620043b9565b604051602081830303815290604052945050505b505b7f501781209a1f8899323b96b4ef08b168df93e0a90c673d1e4cce39366cb62f9b600084868e8e86886053546040516200225598979695949392919062004697565b60405180910390a16200234962001c72600085878f8f8789805190602001206040517fff0000000000000000000000000000000000000000000000000000000000000060f889901b1660208201527fffffffff0000000000000000000000000000000000000000000000000000000060e088811b821660218401527fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606089811b821660258601529188901b909216603984015285901b16603d8201526051810183905260718101829052600090609101604051602081830303815290604052805190602001209050979650505050505050565b86156200235a576200235a62002aa6565b5050505062000bed60018055565b606c5473ffffffffffffffffffffffffffffffffffffffff163314620023ba576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200089e620035ae565b606c5473ffffffffffffffffffffffffffffffffffffffff16331462002416576040517fe2e8106b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff821662002495576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f496e76616c696420746f6b656e20616464726573730000000000000000000000604482015260640162000a09565b73ffffffffffffffffffffffffffffffffffffffff82166000908152606f602052604090205460ff161515811515036200252c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f546f6b656e20616c72656164792068617320746865207065726d697373696f6e604482015260640162000a09565b73ffffffffffffffffffffffffffffffffffffffff82166000818152606f602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00168515159081179091558251938452908301527f6036bc45ffdc28cb8eb8a5afad20d8d1b999da9512abc39c0a9f52995a74998d910160405180910390a15050565b600084815b60208110156200269557600163ffffffff8616821c811690036200263157858160208110620025f257620025f2620044cf565b60200201358260405160200162002613929190918252602082015260400190565b60405160208183030381529060405280519060200120915062002680565b81868260208110620026475762002647620044cf565b602002013560405160200162002667929190918252602082015260400190565b6040516020818303038152906040528051906020012091505b806200268c816200452d565b915050620025bf565b50821490505b949350505050565b60685460ff1615620026e1576040517f2f0047fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556040517f2261efe5aef6fedc1fd1550b25facc9181745623049c7901287030b9ad1a549790600090a1565b600054610100900460ff16620027d0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840162000a09565b6200089e6200363e565b620027eb8b63ffffffff16620036d7565b6068546040805160208082018e90528183018d9052825180830384018152606083019384905280519101207f257b363200000000000000000000000000000000000000000000000000000000909252606481019190915260009165010000000000900473ffffffffffffffffffffffffffffffffffffffff169063257b3632906084016020604051808303816000875af11580156200288e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620028b4919062004667565b905080600003620028f0576040517e2f6fad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60685463ffffffff88811661010090920416146200293a576040517f0595ea2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606854600090610100900463ffffffff16620029585750896200295b565b508a5b620029846200297b848c8c8c8c8c8c8c60405162001b9592919062004657565b8f8f84620025ba565b620029bb576040517fe0417cec00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050505050565b60405173ffffffffffffffffffffffffffffffffffffffff831660248201526044810182905262002aa19084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526200373c565b505050565b6053546068805463ffffffff909216790100000000000000000000000000000000000000000000000000027fffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffffff909216919091179081905573ffffffffffffffffffffffffffffffffffffffff65010000000000909104166333d6247d62002b2c6200169b565b6040518263ffffffff1660e01b815260040162002b4b91815260200190565b600060405180830381600087803b15801562002b6657600080fd5b505af115801562002b7b573d6000803e3d6000fd5b50505050565b80600162002b926020600262004849565b62002b9e919062004681565b6053541062002bd9576040517fef5ccf6600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060536000815462002bec906200452d565b9182905550905060005b602081101562002c88578082901c60011660010362002c2e57826033826020811062002c265762002c26620044cf565b015550505050565b6033816020811062002c445762002c44620044cf565b01546040805160208101929092528101849052606001604051602081830303815290604052805190602001209250808062002c7f906200452d565b91505062002bf6565b5062002aa162004857565b60026001540362002d01576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640162000a09565b6002600155565b600062002d19600482848662004886565b62002d2491620048b2565b90507f2afa5331000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000082160162002fa357600080808080808062002d87896004818d62004886565b81019062002d969190620048fb565b96509650965096509650965096503373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff161462002e0a576040517f912ecce700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8616301462002e5a576040517f750643af00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8a851462002e94576040517f03fffc4b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff89811660248301528881166044830152606482018890526084820187905260ff861660a483015260c4820185905260e48083018590528351808403909101815261010490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd505accf000000000000000000000000000000000000000000000000000000001790529151918e169162002f4f9190620041d7565b6000604051808303816000865af19150503d806000811462002f8e576040519150601f19603f3d011682016040523d82523d6000602084013e62002f93565b606091505b5050505050505050505062003220565b7fffffffff0000000000000000000000000000000000000000000000000000000081167f8fcbaf0c00000000000000000000000000000000000000000000000000000000146200301f576040517fe282c0ba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080808080620030378a6004818e62004886565b81019062003046919062004956565b975097509750975097509750975097503373ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff1614620030bc576040517f912ecce700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff871630146200310c576040517f750643af00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff8a811660248301528981166044830152606482018990526084820188905286151560a483015260ff861660c483015260e482018590526101048083018590528351808403909101815261012490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f8fcbaf0c000000000000000000000000000000000000000000000000000000001790529151918f1691620031d09190620041d7565b6000604051808303816000865af19150503d80600081146200320f576040519150601f19603f3d011682016040523d82523d6000602084013e62003214565b606091505b50505050505050505050505b5050505050565b60405173ffffffffffffffffffffffffffffffffffffffff8085166024830152831660448201526064810182905262002b7b9085907f23b872dd000000000000000000000000000000000000000000000000000000009060840162002a1e565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f06fdde03000000000000000000000000000000000000000000000000000000001790529051606091600091829173ffffffffffffffffffffffffffffffffffffffff8616916200330b9190620041d7565b600060405180830381855afa9150503d806000811462003348576040519150601f19603f3d011682016040523d82523d6000602084013e6200334d565b606091505b50915091508162003394576040518060400160405280600781526020017f4e4f5f4e414d45000000000000000000000000000000000000000000000000008152506200269b565b6200269b816200384f565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f95d89b41000000000000000000000000000000000000000000000000000000001790529051606091600091829173ffffffffffffffffffffffffffffffffffffffff861691620034239190620041d7565b600060405180830381855afa9150503d806000811462003460576040519150601f19603f3d011682016040523d82523d6000602084013e62003465565b606091505b50915091508162003394576040518060400160405280600981526020017f4e4f5f53594d424f4c00000000000000000000000000000000000000000000008152506200269b565b60408051600481526024810182526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f313ce5670000000000000000000000000000000000000000000000000000000017905290516000918291829173ffffffffffffffffffffffffffffffffffffffff8616916200352f9190620041d7565b600060405180830381855afa9150503d80600081146200356c576040519150601f19603f3d011682016040523d82523d6000602084013e62003571565b606091505b509150915081801562003585575080516020145b620035925760126200269b565b808060200190518101906200269b9190620049e2565b60018055565b60685460ff16620035eb576040517f5386698100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040517f1e5e34eea33501aecf2ebec9fe0e884a40804275ea7fe10b2ba084c8374308b390600090a1565b600054610100900460ff16620035a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840162000a09565b600881901c60008181526069602052604081208054600160ff861690811b9182189283905592909190818316900362003220576040517f646cf55800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000620037a0826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff1662003a3f9092919063ffffffff16565b80519091501562002aa15780806020019051810190620037c1919062004a02565b62002aa1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f74207375636365656400000000000000000000000000000000000000000000606482015260840162000a09565b606060408251106200387157818060200190518101906200093d919062004a22565b815160200362003a015760005b602081108015620038c957508281815181106200389f576200389f620044cf565b01602001517fff000000000000000000000000000000000000000000000000000000000000001615155b15620038e45780620038db816200452d565b9150506200387e565b806000036200392857505060408051808201909152601281527f4e4f545f56414c49445f454e434f44494e4700000000000000000000000000006020820152919050565b60008167ffffffffffffffff81111562003946576200394662004182565b6040519080825280601f01601f19166020018201604052801562003971576020820181803683370190505b50905060005b82811015620039f957848181518110620039955762003995620044cf565b602001015160f81c60f81b828281518110620039b557620039b5620044cf565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080620039f0816200452d565b91505062003977565b509392505050565b505060408051808201909152601281527f4e4f545f56414c49445f454e434f44494e470000000000000000000000000000602082015290565b919050565b60606200269b8484600085856000808673ffffffffffffffffffffffffffffffffffffffff16858760405162003a769190620041d7565b60006040518083038185875af1925050503d806000811462003ab5576040519150601f19603f3d011682016040523d82523d6000602084013e62003aba565b606091505b509150915062003acd8783838762003ad8565b979650505050505050565b6060831562003b7357825160000362003b6b5773ffffffffffffffffffffffffffffffffffffffff85163b62003b6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640162000a09565b50816200269b565b6200269b838381511562003b8a5781518083602001fd5b806040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000a09919062004aa2565b611b668062004ab883390190565b803563ffffffff8116811462003a3a57600080fd5b73ffffffffffffffffffffffffffffffffffffffff8116811462003c0657600080fd5b50565b6000806040838503121562003c1d57600080fd5b62003c288362003bce565b9150602083013562003c3a8162003be3565b809150509250929050565b60008060008060008060c0878903121562003c5f57600080fd5b62003c6a8762003bce565b9550602087013562003c7c8162003be3565b9450604087013562003c8e8162003be3565b9350606087013562003ca08162003be3565b925062003cb06080880162003bce565b915060a087013562003cc28162003be3565b809150509295509295509295565b8061040081018310156200093d57600080fd5b60008083601f84011262003cf657600080fd5b50813567ffffffffffffffff81111562003d0f57600080fd5b60208301915083602082850101111562003d2857600080fd5b9250929050565b60008060008060008060008060008060006105208c8e03121562003d5257600080fd5b62003d5e8d8d62003cd0565b9a5062003d6f6104008d0162003bce565b99506104208c013598506104408c0135975062003d906104608d0162003bce565b96506104808c013562003da38162003be3565b955062003db46104a08d0162003bce565b94506104c08c013562003dc78162003be3565b93506104e08c013592506105008c013567ffffffffffffffff81111562003ded57600080fd5b62003dfb8e828f0162003ce3565b915080935050809150509295989b509295989b9093969950565b60006020828403121562003e2857600080fd5b813562003e358162003be3565b9392505050565b801515811462003c0657600080fd5b60006020828403121562003e5e57600080fd5b813562003e358162003e3c565b60ff8116811462003c0657600080fd5b600080600080600080600060e0888a03121562003e9757600080fd5b873562003ea48162003e6b565b965062003eb46020890162003bce565b9550604088013562003ec68162003be3565b945062003ed66060890162003bce565b9350608088013562003ee88162003be3565b9699959850939692959460a0840135945060c09093013592915050565b60006020828403121562003f1857600080fd5b5035919050565b600080600080600080600060a0888a03121562003f3b57600080fd5b62003f468862003bce565b9650602088013562003f588162003be3565b9550604088013567ffffffffffffffff8082111562003f7657600080fd5b62003f848b838c0162003ce3565b909750955060608a013591508082111562003f9e57600080fd5b5062003fad8a828b0162003ce3565b909450925050608088013562003fc38162003e6b565b8091505092959891949750929550565b60008060008060008060a0878903121562003fed57600080fd5b62003ff88762003bce565b955060208701356200400a8162003be3565b9450604087013593506060870135620040238162003e3c565b9250608087013567ffffffffffffffff8111156200404057600080fd5b6200404e89828a0162003ce3565b979a9699509497509295939492505050565b600080600080600080600060c0888a0312156200407c57600080fd5b620040878862003bce565b96506020880135620040998162003be3565b9550604088013594506060880135620040b28162003be3565b93506080880135620040c48162003e3c565b925060a088013567ffffffffffffffff811115620040e157600080fd5b620040ef8a828b0162003ce3565b989b979a50959850939692959293505050565b600080604083850312156200411657600080fd5b8235620041238162003be3565b9150602083013562003c3a8162003e3c565b60008060008061046085870312156200414d57600080fd5b8435935062004160866020870162003cd0565b925062004171610420860162003bce565b939692955092936104400135925050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60005b83811015620041ce578181015183820152602001620041b4565b50506000910152565b60008251620041eb818460208701620041b1565b9190910192915050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156200423f576200423f62004182565b604052919050565b600067ffffffffffffffff82111562004264576200426462004182565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620042a257600080fd5b8135620042b9620042b38262004247565b620041f5565b818152846020838601011115620042cf57600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000606084860312156200430257600080fd5b833567ffffffffffffffff808211156200431b57600080fd5b620043298783880162004290565b945060208601359150808211156200434057600080fd5b506200434f8682870162004290565b9250506040840135620043628162003e6b565b809150509250925092565b6000815180845262004387816020860160208601620041b1565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b606081526000620043ce60608301866200436d565b8281036020840152620043e281866200436d565b91505060ff83166040830152949350505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b63ffffffff86168152600073ffffffffffffffffffffffffffffffffffffffff80871660208401528086166040840152506080606083015262003acd608083018486620043f6565b73ffffffffffffffffffffffffffffffffffffffff8516815263ffffffff84166020820152606060408201526000620044c5606083018486620043f6565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203620045615762004561620044fe565b5060010190565b6060815260006200457e606083018789620043f6565b828103602084015262004593818688620043f6565b91505060ff831660408301529695505050505050565b60008351620045bd818460208801620041b1565b835190830190620045d3818360208801620041b1565b01949350505050565b600061010060ff8c16835263ffffffff808c16602085015273ffffffffffffffffffffffffffffffffffffffff808c166040860152818b166060860152808a166080860152508760a08501528160c08501526200463d8285018789620043f6565b925080851660e085015250509a9950505050505050505050565b8183823760009101908152919050565b6000602082840312156200467a57600080fd5b5051919050565b818103818111156200093d576200093d620044fe565b600061010060ff8b16835263ffffffff808b16602085015273ffffffffffffffffffffffffffffffffffffffff808b166040860152818a1660608601528089166080860152508660a08501528160c0850152620046f7828501876200436d565b925080851660e085015250509998505050505050505050565b600181815b808511156200476f57817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04821115620047535762004753620044fe565b808516156200476157918102915b93841c939080029062004715565b509250929050565b60008262004788575060016200093d565b8162004797575060006200093d565b8160018114620047b05760028114620047bb57620047db565b60019150506200093d565b60ff841115620047cf57620047cf620044fe565b50506001821b6200093d565b5060208310610133831016604e8410600b841016171562004800575081810a6200093d565b6200480c838362004710565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04821115620048415762004841620044fe565b029392505050565b600062003e35838362004777565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600080858511156200489757600080fd5b83861115620048a557600080fd5b5050820193919092039150565b7fffffffff000000000000000000000000000000000000000000000000000000008135818116916004851015620048f35780818660040360031b1b83161692505b505092915050565b600080600080600080600060e0888a0312156200491757600080fd5b8735620049248162003be3565b96506020880135620049368162003be3565b95506040880135945060608801359350608088013562003ee88162003e6b565b600080600080600080600080610100898b0312156200497457600080fd5b8835620049818162003be3565b97506020890135620049938162003be3565b965060408901359550606089013594506080890135620049b38162003e3c565b935060a0890135620049c58162003e6b565b979a969950949793969295929450505060c08201359160e0013590565b600060208284031215620049f557600080fd5b815162003e358162003e6b565b60006020828403121562004a1557600080fd5b815162003e358162003e3c565b60006020828403121562004a3557600080fd5b815167ffffffffffffffff81111562004a4d57600080fd5b8201601f8101841362004a5f57600080fd5b805162004a70620042b38262004247565b81815285602083850101111562004a8657600080fd5b62004a99826020830160208601620041b1565b95945050505050565b60208152600062003e3560208301846200436d56fe6101006040523480156200001257600080fd5b5060405162001b6638038062001b6683398101604081905262000035916200028d565b82826003620000458382620003a1565b506004620000548282620003a1565b50503360c0525060ff811660e052466080819052620000739062000080565b60a052506200046d915050565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f620000ad6200012e565b805160209182012060408051808201825260018152603160f81b90840152805192830193909352918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018390523060a082015260c001604051602081830303815290604052805190602001209050919050565b6060600380546200013f9062000312565b80601f01602080910402602001604051908101604052809291908181526020018280546200016d9062000312565b8015620001be5780601f106200019257610100808354040283529160200191620001be565b820191906000526020600020905b815481529060010190602001808311620001a057829003601f168201915b5050505050905090565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620001f057600080fd5b81516001600160401b03808211156200020d576200020d620001c8565b604051601f8301601f19908116603f01168101908282118183101715620002385762000238620001c8565b816040528381526020925086838588010111156200025557600080fd5b600091505b838210156200027957858201830151818301840152908201906200025a565b600093810190920192909252949350505050565b600080600060608486031215620002a357600080fd5b83516001600160401b0380821115620002bb57600080fd5b620002c987838801620001de565b94506020860151915080821115620002e057600080fd5b50620002ef86828701620001de565b925050604084015160ff811681146200030757600080fd5b809150509250925092565b600181811c908216806200032757607f821691505b6020821081036200034857634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200039c57600081815260208120601f850160051c81016020861015620003775750805b601f850160051c820191505b81811015620003985782815560010162000383565b5050505b505050565b81516001600160401b03811115620003bd57620003bd620001c8565b620003d581620003ce845462000312565b846200034e565b602080601f8311600181146200040d5760008415620003f45750858301515b600019600386901b1c1916600185901b17855562000398565b600085815260208120601f198616915b828110156200043e578886015182559484019460019091019084016200041d565b50858210156200045d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e0516116aa620004bc6000396000610237015260008181610307015281816105c001526106a70152600061053a015260008181610379015261050401526116aa6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063a457c2d71161008c578063d505accf11610066578063d505accf1461039b578063dd62ed3e146103ae578063ffa1ad74146103f457600080fd5b8063a457c2d71461034e578063a9059cbb14610361578063cd0d00961461037457600080fd5b806395d89b41116100bd57806395d89b41146102e75780639dc29fac146102ef578063a3c573eb1461030257600080fd5b806370a08231146102915780637ecebe00146102c757600080fd5b806330adf81f1161012f5780633644e515116101145780633644e51514610261578063395093511461026957806340c10f191461027c57600080fd5b806330adf81f14610209578063313ce5671461023057600080fd5b806318160ddd1161016057806318160ddd146101bd57806320606b70146101cf57806323b872dd146101f657600080fd5b806306fdde031461017c578063095ea7b31461019a575b600080fd5b610184610430565b60405161019191906113e4565b60405180910390f35b6101ad6101a8366004611479565b6104c2565b6040519015158152602001610191565b6002545b604051908152602001610191565b6101c17f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f81565b6101ad6102043660046114a3565b6104dc565b6101c17f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b60405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610191565b6101c1610500565b6101ad610277366004611479565b61055c565b61028f61028a366004611479565b6105a8565b005b6101c161029f3660046114df565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101c16102d53660046114df565b60056020526000908152604090205481565b610184610680565b61028f6102fd366004611479565b61068f565b6103297f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610191565b6101ad61035c366004611479565b61075e565b6101ad61036f366004611479565b61082f565b6101c17f000000000000000000000000000000000000000000000000000000000000000081565b61028f6103a9366004611501565b61083d565b6101c16103bc366004611574565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101846040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525081565b60606003805461043f906115a7565b80601f016020809104026020016040519081016040528092919081815260200182805461046b906115a7565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b5050505050905090565b6000336104d0818585610b73565b60019150505b92915050565b6000336104ea858285610d27565b6104f5858585610dfe565b506001949350505050565b60007f00000000000000000000000000000000000000000000000000000000000000004614610537576105324661106d565b905090565b507f000000000000000000000000000000000000000000000000000000000000000090565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906104d090829086906105a3908790611629565b610b73565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610672576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d4272696467650000000000000000000000000000000060648201526084015b60405180910390fd5b61067c8282611135565b5050565b60606004805461043f906115a7565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f546f6b656e577261707065643a3a6f6e6c794272696467653a204e6f7420506f60448201527f6c79676f6e5a6b45564d427269646765000000000000000000000000000000006064820152608401610669565b61067c8282611228565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919083811015610822576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f0000000000000000000000000000000000000000000000000000006064820152608401610669565b6104f58286868403610b73565b6000336104d0818585610dfe565b834211156108cc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f546f6b656e577261707065643a3a7065726d69743a204578706972656420706560448201527f726d6974000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8716600090815260056020526040812080547f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918a918a918a9190866109268361163c565b9091555060408051602081019690965273ffffffffffffffffffffffffffffffffffffffff94851690860152929091166060840152608083015260a082015260c0810186905260e0016040516020818303038152906040528051906020012090506000610991610500565b6040517f19010000000000000000000000000000000000000000000000000000000000006020820152602281019190915260428101839052606201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120600080855291840180845281905260ff89169284019290925260608301879052608083018690529092509060019060a0016020604051602081039080840390855afa158015610a55573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff811615801590610ad057508973ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16145b610b5c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f546f6b656e577261707065643a3a7065726d69743a20496e76616c696420736960448201527f676e6174757265000000000000000000000000000000000000000000000000006064820152608401610669565b610b678a8a8a610b73565b50505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c15576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8216610cb8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f73730000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610df85781811015610deb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610669565b610df88484848403610b73565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610ea1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f64726573730000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff8216610f44576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f65737300000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610ffa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e636500000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610df8565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f611098610430565b8051602091820120604080518082018252600181527f310000000000000000000000000000000000000000000000000000000000000090840152805192830193909352918101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018390523060a082015260c001604051602081830303815290604052805190602001209050919050565b73ffffffffffffffffffffffffffffffffffffffff82166111b2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610669565b80600260008282546111c49190611629565b909155505073ffffffffffffffffffffffffffffffffffffffff8216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff82166112cb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f73000000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604090205481811015611381576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f63650000000000000000000000000000000000000000000000000000000000006064820152608401610669565b73ffffffffffffffffffffffffffffffffffffffff83166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9101610d1a565b600060208083528351808285015260005b81811015611411578581018301518582016040015282016113f5565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461147457600080fd5b919050565b6000806040838503121561148c57600080fd5b61149583611450565b946020939093013593505050565b6000806000606084860312156114b857600080fd5b6114c184611450565b92506114cf60208501611450565b9150604084013590509250925092565b6000602082840312156114f157600080fd5b6114fa82611450565b9392505050565b600080600080600080600060e0888a03121561151c57600080fd5b61152588611450565b965061153360208901611450565b95506040880135945060608801359350608088013560ff8116811461155757600080fd5b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561158757600080fd5b61159083611450565b915061159e60208401611450565b90509250929050565b600181811c908216806115bb57607f821691505b6020821081036115f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156104d6576104d66115fa565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361166d5761166d6115fa565b506001019056fea26469706673582212206fe049be388a1d04319b9913fe6d100c4c8e272fe0f5748eb056bd0622beabcc64736f6c63430008140033a26469706673582212205a6863755e218a86185b7a8974ed88bf11d02370ae341214fc0245f726eb00a064736f6c63430008140033" + }, + { + "contractName": "PolygonZkEVMBridge proxy", + "balance": "115792089237316195423570985008687907853269984665640564039457584007913129639935", + "nonce": "1", + "address": "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780", + "bytecode": "0x60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100a85780638f283970146100e6578063f851a440146101065761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61011b565b005b61006b61011b565b34801561008157600080fd5b5061006b61009036600461086f565b610135565b61006b6100a336600461088a565b61017f565b3480156100b457600080fd5b506100bd6101f3565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100f257600080fd5b5061006b61010136600461086f565b610231565b34801561011257600080fd5b506100bd61025e565b61012361028c565b61013361012e610363565b61036d565b565b61013d610391565b73ffffffffffffffffffffffffffffffffffffffff16330361017757610174816040518060200160405280600081525060006103d1565b50565b61017461011b565b610187610391565b73ffffffffffffffffffffffffffffffffffffffff1633036101eb576101e68383838080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250600192506103d1915050565b505050565b6101e661011b565b60006101fd610391565b73ffffffffffffffffffffffffffffffffffffffff16330361022657610221610363565b905090565b61022e61011b565b90565b610239610391565b73ffffffffffffffffffffffffffffffffffffffff16330361017757610174816103fc565b6000610268610391565b73ffffffffffffffffffffffffffffffffffffffff16330361022657610221610391565b610294610391565b73ffffffffffffffffffffffffffffffffffffffff163303610133576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f7879207461726760648201527f6574000000000000000000000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b600061022161045d565b3660008037600080366000845af43d6000803e80801561038c573d6000f35b3d6000fd5b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b5473ffffffffffffffffffffffffffffffffffffffff16919050565b6103da83610485565b6000825111806103e75750805b156101e6576103f683836104d2565b50505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f610425610391565b6040805173ffffffffffffffffffffffffffffffffffffffff928316815291841660208301520160405180910390a1610174816104fe565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc6103b5565b61048e8161060a565b60405173ffffffffffffffffffffffffffffffffffffffff8216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606104f7838360405180606001604052806027815260200161099f602791396106d5565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81166105a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201527f6464726573730000000000000000000000000000000000000000000000000000606482015260840161035a565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9290921691909117905550565b73ffffffffffffffffffffffffffffffffffffffff81163b6106ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201527f6f74206120636f6e747261637400000000000000000000000000000000000000606482015260840161035a565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc6105c4565b60606000808573ffffffffffffffffffffffffffffffffffffffff16856040516106ff9190610931565b600060405180830381855af49150503d806000811461073a576040519150601f19603f3d011682016040523d82523d6000602084013e61073f565b606091505b50915091506107508683838761075a565b9695505050505050565b606083156107f05782516000036107e95773ffffffffffffffffffffffffffffffffffffffff85163b6107e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161035a565b50816107fa565b6107fa8383610802565b949350505050565b8151156108125781518083602001fd5b806040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161035a919061094d565b803573ffffffffffffffffffffffffffffffffffffffff8116811461086a57600080fd5b919050565b60006020828403121561088157600080fd5b6104f782610846565b60008060006040848603121561089f57600080fd5b6108a884610846565b9250602084013567ffffffffffffffff808211156108c557600080fd5b818601915086601f8301126108d957600080fd5b8135818111156108e857600080fd5b8760208285010111156108fa57600080fd5b6020830194508093505050509250925092565b60005b83811015610928578181015183820152602001610910565b50506000910152565b6000825161094381846020870161090d565b9190910192915050565b602081526000825180602084015261096c81604085016020870161090d565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220701a0c26bdd76686e63fc3c65e4f28a20ba3ecc8a60246733c0627e679c9804e64736f6c63430008140033", + "storage": { + "0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0x0000000000000000000000000000000000000000000000000000000000000068": "0x00000000000000a40d5f56745a118d0906a34e69aec8c0db1cb8fa0000000100", + "0x000000000000000000000000000000000000000000000000000000000000006c": "0x0000000000000000000000002ecf31ece36ccac2d3222a303b1409233ecbb225", + "0x000000000000000000000000000000000000000000000000000000000000006d": "0x00000000000000000000000082109a709138a2953c720d3d775168717b668ba6", + "0x000000000000000000000000000000000000000000000000000000000000006e": "0x00000000000000000000000082109a709138a2953c720d3d775168717b668ba6", + "0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103": "0x000000000000000000000000a6791C91168866769273e6AFFe603e00269b16ae", + "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc": "0x0000000000000000000000002F1008CB69C24f06D089ECEA5a51791A6FB74b04" + } + }, + { + "contractName": "PolygonZkEVMGlobalExitRootL2 implementation", + "balance": "0", + "nonce": "1", + "address": "0x5D6c503E69326Ab691b71E1223908e49988c5AEc", + "bytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806301fd904414610051578063257b36321461006d57806333d6247d1461008d578063a3c573eb146100a2575b600080fd5b61005a60015481565b6040519081526020015b60405180910390f35b61005a61007b366004610162565b60006020819052908152604090205481565b6100a061009b366004610162565b6100ee565b005b6100c97f00000000000000000000000010b65c586f795af3eccee594fe4e38e1f059f78081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610064565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000010b65c586f795af3eccee594fe4e38e1f059f780161461015d576040517fb49365dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600155565b60006020828403121561017457600080fd5b503591905056fea2646970667358221220ea2171e2c85c8bff947affc409ef6fc6a8fe82fb8c174ddeda988651e595d66564736f6c63430008140033" + }, + { + "contractName": "PolygonZkEVMGlobalExitRootL2 proxy", + "balance": "0", + "nonce": "1", + "address": "0xa40d5f56745a118d0906a34e69aec8c0db1cb8fa", + "bytecode": "0x60806040523661001357610011610017565b005b6100115b61001f6101b7565b6001600160a01b0316336001600160a01b0316141561016f5760606001600160e01b031960003516631b2ce7f360e11b8114156100655761005e6101ea565b9150610167565b6001600160e01b0319811663278f794360e11b14156100865761005e610241565b6001600160e01b031981166308f2839760e41b14156100a75761005e610287565b6001600160e01b031981166303e1469160e61b14156100c85761005e6102b8565b6001600160e01b03198116635c60da1b60e01b14156100e95761005e6102f8565b60405162461bcd60e51b815260206004820152604260248201527f5472616e73706172656e745570677261646561626c6550726f78793a2061646d60448201527f696e2063616e6e6f742066616c6c6261636b20746f2070726f78792074617267606482015261195d60f21b608482015260a4015b60405180910390fd5b815160208301f35b61017761030c565b565b606061019e83836040518060600160405280602781526020016108576027913961031c565b9392505050565b90565b6001600160a01b03163b151590565b60007fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b546001600160a01b0316919050565b60606101f4610394565b600061020336600481846106a2565b81019061021091906106e8565b905061022d8160405180602001604052806000815250600061039f565b505060408051602081019091526000815290565b606060008061025336600481846106a2565b8101906102609190610719565b915091506102708282600161039f565b604051806020016040528060008152509250505090565b6060610291610394565b60006102a036600481846106a2565b8101906102ad91906106e8565b905061022d816103cb565b60606102c2610394565b60006102cc6101b7565b604080516001600160a01b03831660208201529192500160405160208183030381529060405291505090565b6060610302610394565b60006102cc610422565b610177610317610422565b610431565b6060600080856001600160a01b0316856040516103399190610807565b600060405180830381855af49150503d8060008114610374576040519150601f19603f3d011682016040523d82523d6000602084013e610379565b606091505b509150915061038a86838387610455565b9695505050505050565b341561017757600080fd5b6103a8836104d3565b6000825111806103b55750805b156103c6576103c48383610179565b505b505050565b7f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f6103f46101b7565b604080516001600160a01b03928316815291841660208301520160405180910390a161041f81610513565b50565b600061042c6105bc565b905090565b3660008037600080366000845af43d6000803e808015610450573d6000f35b3d6000fd5b606083156104c15782516104ba576001600160a01b0385163b6104ba5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161015e565b50816104cb565b6104cb83836105e4565b949350505050565b6104dc8161060e565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b6001600160a01b0381166105785760405162461bcd60e51b815260206004820152602660248201527f455243313936373a206e65772061646d696e20697320746865207a65726f206160448201526564647265737360d01b606482015260840161015e565b807fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035b80546001600160a01b0319166001600160a01b039290921691909117905550565b60007f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc6101db565b8151156105f45781518083602001fd5b8060405162461bcd60e51b815260040161015e9190610823565b6001600160a01b0381163b61067b5760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b606482015260840161015e565b807f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc61059b565b600080858511156106b257600080fd5b838611156106bf57600080fd5b5050820193919092039150565b80356001600160a01b03811681146106e357600080fd5b919050565b6000602082840312156106fa57600080fd5b61019e826106cc565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561072c57600080fd5b610735836106cc565b9150602083013567ffffffffffffffff8082111561075257600080fd5b818501915085601f83011261076657600080fd5b81358181111561077857610778610703565b604051601f8201601f19908116603f011681019083821181831017156107a0576107a0610703565b816040528281528860208487010111156107b957600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60005b838110156107f65781810151838201526020016107de565b838111156103c45750506000910152565b600082516108198184602087016107db565b9190910192915050565b60208152600082518060208401526108428160408501602087016107db565b601f01601f1916919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a264697066735822122012bb4f564f73959a03513dc74fc3c6e40e8386e6f02c16b78d6db00ce0aa16af64736f6c63430008090033", + "storage": { + "0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103": "0x000000000000000000000000a6791c91168866769273e6affe603e00269b16ae", + "0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc": "0x0000000000000000000000005d6c503e69326ab691b71e1223908e49988c5aec" + } + }, + { + "contractName": "PolygonZkEVMTimelock", + "balance": "0", + "nonce": "1", + "address": "0x26a093198fA2a20C3508679197F5aE1c9323772A", + "bytecode": "0x6080604052600436106101c65760003560e01c806364d62353116100f7578063b1c5f42711610095578063d547741f11610064578063d547741f14610661578063e38335e514610681578063f23a6e6114610694578063f27a0c92146106d957600080fd5b8063b1c5f427146105af578063bc197c81146105cf578063c4d252f514610614578063d45c44351461063457600080fd5b80638f61f4f5116100d15780638f61f4f5146104e157806391d1485414610515578063a217fddf14610566578063b08e51c01461057b57600080fd5b806364d62353146104815780638065657f146104a15780638f2a0bb0146104c157600080fd5b8063248a9ca31161016457806331d507501161013e57806331d50750146103c857806336568abe146103e85780633a6aae7214610408578063584b153e1461046157600080fd5b8063248a9ca3146103475780632ab0f529146103775780632f2ff15d146103a857600080fd5b80630d3cf6fc116101a05780630d3cf6fc1461026b578063134008d31461029f57806313bc9f20146102b2578063150b7a02146102d257600080fd5b806301d5062a146101d257806301ffc9a7146101f457806307bd02651461022957600080fd5b366101cd57005b600080fd5b3480156101de57600080fd5b506101f26101ed366004611c52565b6106ee565b005b34801561020057600080fd5b5061021461020f366004611cc7565b610783565b60405190151581526020015b60405180910390f35b34801561023557600080fd5b5061025d7fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e6381565b604051908152602001610220565b34801561027757600080fd5b5061025d7f5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca581565b6101f26102ad366004611d09565b6107df565b3480156102be57600080fd5b506102146102cd366004611d75565b6108d7565b3480156102de57600080fd5b506103166102ed366004611e9a565b7f150b7a0200000000000000000000000000000000000000000000000000000000949350505050565b6040517fffffffff000000000000000000000000000000000000000000000000000000009091168152602001610220565b34801561035357600080fd5b5061025d610362366004611d75565b60009081526020819052604090206001015490565b34801561038357600080fd5b50610214610392366004611d75565b6000908152600160208190526040909120541490565b3480156103b457600080fd5b506101f26103c3366004611f02565b6108fd565b3480156103d457600080fd5b506102146103e3366004611d75565b610927565b3480156103f457600080fd5b506101f2610403366004611f02565b610940565b34801561041457600080fd5b5061043c7f0000000000000000000000002ecf31ece36ccac2d3222a303b1409233ecbb22581565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610220565b34801561046d57600080fd5b5061021461047c366004611d75565b6109f8565b34801561048d57600080fd5b506101f261049c366004611d75565b610a0e565b3480156104ad57600080fd5b5061025d6104bc366004611d09565b610ade565b3480156104cd57600080fd5b506101f26104dc366004611f73565b610b1d565b3480156104ed57600080fd5b5061025d7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc181565b34801561052157600080fd5b50610214610530366004611f02565b60009182526020828152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b34801561057257600080fd5b5061025d600081565b34801561058757600080fd5b5061025d7ffd643c72710c63c0180259aba6b2d05451e3591a24e58b62239378085726f78381565b3480156105bb57600080fd5b5061025d6105ca366004612025565b610d4f565b3480156105db57600080fd5b506103166105ea36600461214e565b7fbc197c810000000000000000000000000000000000000000000000000000000095945050505050565b34801561062057600080fd5b506101f261062f366004611d75565b610d94565b34801561064057600080fd5b5061025d61064f366004611d75565b60009081526001602052604090205490565b34801561066d57600080fd5b506101f261067c366004611f02565b610e8f565b6101f261068f366004612025565b610eb4565b3480156106a057600080fd5b506103166106af3660046121f8565b7ff23a6e610000000000000000000000000000000000000000000000000000000095945050505050565b3480156106e557600080fd5b5061025d611161565b7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc161071881611244565b6000610728898989898989610ade565b90506107348184611251565b6000817f4cf4410cc57040e44862ef0f45f3dd5a5e02db8eb8add648d4b0e236f1d07dca8b8b8b8b8b8a604051610770969594939291906122a6565b60405180910390a3505050505050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f4e2312e00000000000000000000000000000000000000000000000000000000014806107d957506107d98261139e565b92915050565b600080527fdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d70696020527f5ba6852781629bcdcd4bdaa6de76d786f1c64b16acdac474e55bebc0ea157951547fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e639060ff1661085c5761085c8133611435565b600061086c888888888888610ade565b905061087881856114ed565b6108848888888861162a565b6000817fc2617efa69bab66782fa219543714338489c4e9e178271560a91b82c3f612b588a8a8a8a6040516108bc94939291906122f1565b60405180910390a36108cd8161172e565b5050505050505050565b6000818152600160205260408120546001811180156108f65750428111155b9392505050565b60008281526020819052604090206001015461091881611244565b61092283836117d7565b505050565b60008181526001602052604081205481905b1192915050565b73ffffffffffffffffffffffffffffffffffffffff811633146109ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c66000000000000000000000000000000000060648201526084015b60405180910390fd5b6109f482826118c7565b5050565b6000818152600160208190526040822054610939565b333014610a9d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f54696d656c6f636b436f6e74726f6c6c65723a2063616c6c6572206d7573742060448201527f62652074696d656c6f636b00000000000000000000000000000000000000000060648201526084016109e1565b60025460408051918252602082018390527f11c24f4ead16507c69ac467fbd5e4eed5fb5c699626d2cc6d66421df253886d5910160405180910390a1600255565b6000868686868686604051602001610afb969594939291906122a6565b6040516020818303038152906040528051906020012090509695505050505050565b7fb09aa5aeb3702cfd50b6b62bc4532604938f21248a27a1d5ca736082b6819cc1610b4781611244565b888714610bd6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b888514610c65576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b6000610c778b8b8b8b8b8b8b8b610d4f565b9050610c838184611251565b60005b8a811015610d415780827f4cf4410cc57040e44862ef0f45f3dd5a5e02db8eb8add648d4b0e236f1d07dca8e8e85818110610cc357610cc3612331565b9050602002016020810190610cd89190612360565b8d8d86818110610cea57610cea612331565b905060200201358c8c87818110610d0357610d03612331565b9050602002810190610d15919061237b565b8c8b604051610d29969594939291906122a6565b60405180910390a3610d3a8161240f565b9050610c86565b505050505050505050505050565b60008888888888888888604051602001610d709897969594939291906124f7565b60405160208183030381529060405280519060200120905098975050505050505050565b7ffd643c72710c63c0180259aba6b2d05451e3591a24e58b62239378085726f783610dbe81611244565b610dc7826109f8565b610e53576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20636160448201527f6e6e6f742062652063616e63656c6c656400000000000000000000000000000060648201526084016109e1565b6000828152600160205260408082208290555183917fbaa1eb22f2a492ba1a5fea61b8df4d27c6c8b5f3971e63bb58fa14ff72eedb7091a25050565b600082815260208190526040902060010154610eaa81611244565b61092283836118c7565b600080527fdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d70696020527f5ba6852781629bcdcd4bdaa6de76d786f1c64b16acdac474e55bebc0ea157951547fd8aa0f3194971a2a116679f7c2090f6939c8d4e01a2a8d7e41d55e5351469e639060ff16610f3157610f318133611435565b878614610fc0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b87841461104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f54696d656c6f636b436f6e74726f6c6c65723a206c656e677468206d69736d6160448201527f746368000000000000000000000000000000000000000000000000000000000060648201526084016109e1565b60006110618a8a8a8a8a8a8a8a610d4f565b905061106d81856114ed565b60005b8981101561114b5760008b8b8381811061108c5761108c612331565b90506020020160208101906110a19190612360565b905060008a8a848181106110b7576110b7612331565b9050602002013590503660008a8a868181106110d5576110d5612331565b90506020028101906110e7919061237b565b915091506110f78484848461162a565b84867fc2617efa69bab66782fa219543714338489c4e9e178271560a91b82c3f612b588686868660405161112e94939291906122f1565b60405180910390a350505050806111449061240f565b9050611070565b506111558161172e565b50505050505050505050565b60007f0000000000000000000000002ecf31ece36ccac2d3222a303b1409233ecbb22573ffffffffffffffffffffffffffffffffffffffff161580159061123257507f0000000000000000000000002ecf31ece36ccac2d3222a303b1409233ecbb22573ffffffffffffffffffffffffffffffffffffffff166315064c966040518163ffffffff1660e01b8152600401602060405180830381865afa15801561120e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061123291906125be565b1561123d5750600090565b5060025490565b61124e8133611435565b50565b61125a82610927565b156112e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20616c60448201527f7265616479207363686564756c6564000000000000000000000000000000000060648201526084016109e1565b6112ef611161565b81101561137e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f54696d656c6f636b436f6e74726f6c6c65723a20696e73756666696369656e7460448201527f2064656c6179000000000000000000000000000000000000000000000000000060648201526084016109e1565b61138881426125e0565b6000928352600160205260409092209190915550565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b0000000000000000000000000000000000000000000000000000000014806107d957507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146107d9565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff166109f4576114738161197e565b61147e83602061199d565b60405160200161148f929190612617565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f08c379a00000000000000000000000000000000000000000000000000000000082526109e191600401612698565b6114f6826108d7565b611582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20697360448201527f206e6f742072656164790000000000000000000000000000000000000000000060648201526084016109e1565b80158061159e5750600081815260016020819052604090912054145b6109f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f54696d656c6f636b436f6e74726f6c6c65723a206d697373696e67206465706560448201527f6e64656e6379000000000000000000000000000000000000000000000000000060648201526084016109e1565b60008473ffffffffffffffffffffffffffffffffffffffff168484846040516116549291906126e9565b60006040518083038185875af1925050503d8060008114611691576040519150601f19603f3d011682016040523d82523d6000602084013e611696565b606091505b5050905080611727576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603360248201527f54696d656c6f636b436f6e74726f6c6c65723a20756e6465726c79696e67207460448201527f72616e73616374696f6e2072657665727465640000000000000000000000000060648201526084016109e1565b5050505050565b611737816108d7565b6117c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f54696d656c6f636b436f6e74726f6c6c65723a206f7065726174696f6e20697360448201527f206e6f742072656164790000000000000000000000000000000000000000000060648201526084016109e1565b600090815260016020819052604090912055565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff166109f45760008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556118693390565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16156109f45760008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b60606107d973ffffffffffffffffffffffffffffffffffffffff831660145b606060006119ac8360026126f9565b6119b79060026125e0565b67ffffffffffffffff8111156119cf576119cf611d8e565b6040519080825280601f01601f1916602001820160405280156119f9576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110611a3057611a30612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110611a9357611a93612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506000611acf8460026126f9565b611ada9060016125e0565b90505b6001811115611b77577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110611b1b57611b1b612331565b1a60f81b828281518110611b3157611b31612331565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060049490941c93611b7081612710565b9050611add565b5083156108f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e7460448201526064016109e1565b803573ffffffffffffffffffffffffffffffffffffffff81168114611c0457600080fd5b919050565b60008083601f840112611c1b57600080fd5b50813567ffffffffffffffff811115611c3357600080fd5b602083019150836020828501011115611c4b57600080fd5b9250929050565b600080600080600080600060c0888a031215611c6d57600080fd5b611c7688611be0565b965060208801359550604088013567ffffffffffffffff811115611c9957600080fd5b611ca58a828b01611c09565b989b979a50986060810135976080820135975060a09091013595509350505050565b600060208284031215611cd957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146108f657600080fd5b60008060008060008060a08789031215611d2257600080fd5b611d2b87611be0565b955060208701359450604087013567ffffffffffffffff811115611d4e57600080fd5b611d5a89828a01611c09565b979a9699509760608101359660809091013595509350505050565b600060208284031215611d8757600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611e0457611e04611d8e565b604052919050565b600082601f830112611e1d57600080fd5b813567ffffffffffffffff811115611e3757611e37611d8e565b611e6860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611dbd565b818152846020838601011115611e7d57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060808587031215611eb057600080fd5b611eb985611be0565b9350611ec760208601611be0565b925060408501359150606085013567ffffffffffffffff811115611eea57600080fd5b611ef687828801611e0c565b91505092959194509250565b60008060408385031215611f1557600080fd5b82359150611f2560208401611be0565b90509250929050565b60008083601f840112611f4057600080fd5b50813567ffffffffffffffff811115611f5857600080fd5b6020830191508360208260051b8501011115611c4b57600080fd5b600080600080600080600080600060c08a8c031215611f9157600080fd5b893567ffffffffffffffff80821115611fa957600080fd5b611fb58d838e01611f2e565b909b50995060208c0135915080821115611fce57600080fd5b611fda8d838e01611f2e565b909950975060408c0135915080821115611ff357600080fd5b506120008c828d01611f2e565b9a9d999c50979a969997986060880135976080810135975060a0013595509350505050565b60008060008060008060008060a0898b03121561204157600080fd5b883567ffffffffffffffff8082111561205957600080fd5b6120658c838d01611f2e565b909a50985060208b013591508082111561207e57600080fd5b61208a8c838d01611f2e565b909850965060408b01359150808211156120a357600080fd5b506120b08b828c01611f2e565b999c989b509699959896976060870135966080013595509350505050565b600082601f8301126120df57600080fd5b8135602067ffffffffffffffff8211156120fb576120fb611d8e565b8160051b61210a828201611dbd565b928352848101820192828101908785111561212457600080fd5b83870192505b848310156121435782358252918301919083019061212a565b979650505050505050565b600080600080600060a0868803121561216657600080fd5b61216f86611be0565b945061217d60208701611be0565b9350604086013567ffffffffffffffff8082111561219a57600080fd5b6121a689838a016120ce565b945060608801359150808211156121bc57600080fd5b6121c889838a016120ce565b935060808801359150808211156121de57600080fd5b506121eb88828901611e0c565b9150509295509295909350565b600080600080600060a0868803121561221057600080fd5b61221986611be0565b945061222760208701611be0565b93506040860135925060608601359150608086013567ffffffffffffffff81111561225157600080fd5b6121eb88828901611e0c565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff8716815285602082015260a0604082015260006122dc60a08301868861225d565b60608301949094525060800152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8516815283602082015260606040820152600061232760608301848661225d565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561237257600080fd5b6108f682611be0565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126123b057600080fd5b83018035915067ffffffffffffffff8211156123cb57600080fd5b602001915036819003821315611c4b57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612440576124406123e0565b5060010190565b81835260006020808501808196508560051b810191508460005b878110156124ea57828403895281357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18836030181126124a057600080fd5b8701858101903567ffffffffffffffff8111156124bc57600080fd5b8036038213156124cb57600080fd5b6124d686828461225d565b9a87019a9550505090840190600101612461565b5091979650505050505050565b60a0808252810188905260008960c08301825b8b8110156125455773ffffffffffffffffffffffffffffffffffffffff61253084611be0565b1682526020928301929091019060010161250a565b5083810360208501528881527f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff89111561257e57600080fd5b8860051b9150818a602083013701828103602090810160408501526125a69082018789612447565b60608401959095525050608001529695505050505050565b6000602082840312156125d057600080fd5b815180151581146108f657600080fd5b808201808211156107d9576107d96123e0565b60005b8381101561260e5781810151838201526020016125f6565b50506000910152565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161264f8160178501602088016125f3565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000601791840191820152835161268c8160288401602088016125f3565b01602801949350505050565b60208152600082518060208401526126b78160408501602087016125f3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b8183823760009101908152919050565b80820281158282048414176107d9576107d96123e0565b60008161271f5761271f6123e0565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff019056fea26469706673582212209da77d4ff44295a8d775fdab11f0d3b6e791d2a92815b915b3c986c1b952ce7264736f6c63430008140033", + "storage": { + "0x0000000000000000000000000000000000000000000000000000000000000002": "0x0000000000000000000000000000000000000000000000000000000000000e10", + "0xd52c425d569449de3ea8e96b6f4f0056c8b90231a08ce274f929eac5ca5b70c5": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0x05ff7937f06c2996e8480305be52289ca3766048749e7cbb61d45fd5705375bb": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0x64494413541ff93b31aa309254e3fed72a7456e9845988b915b4c7a7ceba8814": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", + "0x0dbd82eed89d73822865d402eb9d73d4609cb01c0aa3d785a17d7a9d0cb5ee06": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0x3412d5605ac6cd444957cedb533e5dacad6378b4bc819ebe3652188a665066d6": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", + "0x9d38bd476745c975feef1b204358c9d3e7719e09369f43fb65a1097848fb43d1": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0xdae2aa361dfd1ca020a396615627d436107c35eff9fe7738a3512819782d706a": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5", + "0x89eab0dbc58be726d54f3116480f80e75a19870aa9750471514a47a86f365aef": "0x0000000000000000000000000000000000000000000000000000000000000001", + "0xc3ad33e20b0c56a223ad5104fff154aa010f8715b9c981fd38fdc60a4d1a52fc": "0x5f58e3a2316349923ce3780f8d587db2d72378aed66a8261c916544fa6846ca5" + } + }, + { + "accountName": "keyless Deployer", + "balance": "0", + "nonce": "1", + "address": "0xc0124DeE8494E155eFf900100D2AF4CC0BC9a76e" + }, + { + "accountName": "deployer", + "balance": "100000000000000000000000", + "nonce": "9", + "address": "0x2ECF31eCe36ccaC2d3222A303b1409233ECBB225" + }, + { + "accountName": "deployer", + "balance": "100000000000000000000000", + "nonce": "8", + "address": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" + } + ] +} diff --git a/test/config/node/test.node.config.toml b/test/config/node/test.node.config.toml new file mode 100644 index 00000000..6e7a58ef --- /dev/null +++ b/test/config/node/test.node.config.toml @@ -0,0 +1,166 @@ +IsTrustedSequencer = true + +[Log] +Environment = "development" # "production" or "development" +Level = "debug" +Outputs = ["stderr"] + +[StateDB] +User = "state_user" +Password = "state_password" +Name = "state_db" +Host = "xgon-state-db" +Port = "5432" +EnableLog = false +MaxConns = 200 + +[Pool] +FreeClaimGasLimit = 1500000 +IntervalToRefreshBlockedAddresses = "5m" +IntervalToRefreshGasPrices = "5s" +MaxTxBytesSize=100132 +MaxTxDataBytesSize=100000 +DefaultMinGasPriceAllowed = 1000000000 +MinAllowedGasPriceInterval = "5m" +PollMinAllowedGasPriceInterval = "15s" + [Pool.DB] + User = "pool_user" + Password = "pool_password" + Name = "pool_db" + Host = "xgon-pool-db" + Port = "5432" + EnableLog = false + MaxConns = 200 + +[Etherman] +URL = "http://xgon-mock-l1-network:8545" +ForkIDChunkSize = 20000 +MultiGasProvider = false + [Etherscan] + ApiKey = "" + +[RPC] +Host = "0.0.0.0" +Port = 8123 +ReadTimeout = "60s" +WriteTimeout = "60s" +MaxRequestsPerIPAndSecond = 5000 +SequencerNodeURI = "" +EnableL2SuggestedGasPricePolling = true + [RPC.WebSockets] + Enabled = true + Port = 8133 + +[Synchronizer] +SyncInterval = "1s" +SyncChunkSize = 100 +TrustedSequencerURL = "http://xgon-json-rpc:8123" # If it is empty or not specified, then the value is read from the smc. + +[Sequencer] +WaitPeriodPoolIsEmpty = "1s" +LastBatchVirtualizationTimeMaxWaitPeriod = "10s" +BlocksAmountForTxsToBeDeleted = 100 +FrequencyToCheckTxsForDelete = "12h" +MaxTxsPerBatch = 300 +MaxBatchBytesSize = 120000 +MaxCumulativeGasUsed = 30000000 +MaxKeccakHashes = 2145 +MaxPoseidonHashes = 252357 +MaxPoseidonPaddings = 135191 +MaxMemAligns = 236585 +MaxArithmetics = 236585 +MaxBinaries = 473170 +MaxSteps = 7570538 +TxLifetimeCheckTimeout = "10m" +MaxTxLifetime = "3h" + [Sequencer.Finalizer] + GERDeadlineTimeout = "2s" + ForcedBatchDeadlineTimeout = "5s" + SleepDuration = "100ms" + ResourcePercentageToCloseBatch = 10 + GERFinalityNumberOfBlocks = 0 + ClosingSignalsManagerWaitForCheckingL1Timeout = "10s" + ClosingSignalsManagerWaitForCheckingGER = "10s" + ClosingSignalsManagerWaitForCheckingForcedBatches = "10s" + ForcedBatchesFinalityNumberOfBlocks = 0 + TimestampResolution = "10s" + StopSequencerOnBatchNum = 0 + [Sequencer.DBManager] + PoolRetrievalInterval = "500ms" + L2ReorgRetrievalInterval = "5s" + [Sequencer.EffectiveGasPrice] + MaxBreakEvenGasPriceDeviationPercentage = 10 + L1GasPriceFactor = 0.25 + ByteGasCost = 16 + MarginFactor = 1 + Enabled = false + +[SequenceSender] +WaitPeriodSendSequence = "15s" +LastBatchVirtualizationTimeMaxWaitPeriod = "10s" +MaxTxSizeForL1 = 131072 +MaxBatchesForL1 = 10 +SenderAddress = "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266" +L2Coinbase = "0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266" +PrivateKey = {Path = "/pk/sequencer.keystore", Password = "testonly"} +UseValidium = true + +[Aggregator] +Host = "0.0.0.0" +Port = 50081 +RetryTime = "5s" +VerifyProofInterval = "10s" +TxProfitabilityCheckerType = "acceptall" +TxProfitabilityMinReward = "1.1" +ProofStatePollingInterval = "5s" +SenderAddress = "0x70997970c51812dc3a010c7d01b50e0d17dc79c8" +CleanupLockedProofsInterval = "2m" +GeneratingProofCleanupThreshold = "10m" + +[EthTxManager] +ForcedGas = 0 +PrivateKeys = [ + {Path = "/pk/sequencer.keystore", Password = "testonly"}, + {Path = "/pk/aggregator.keystore", Password = "testonly"} +] + +[L2GasPriceSuggester] +Type = "default" +UpdatePeriod = "10s" +Factor = 0.5 +DefaultGasPriceWei = 1000000000 +MaxGasPriceWei = 0 + +[MTClient] +URI = "xgon-prover:50061" + +[Executor] +URI = "xgon-prover:50071" +MaxGRPCMessageSize = 100000000 + +[Metrics] +Host = "0.0.0.0" +Port = 9091 +Enabled = true +ProfilingHost = "0.0.0.0" +ProfilingPort = 6060 +ProfilingEnabled = true + +[EventLog] + [EventLog.DB] + User = "event_user" + Password = "event_password" + Name = "event_db" + Host = "xgon-event-db" + Port = "5432" + EnableLog = false + MaxConns = 200 + +[HashDB] +User = "prover_user" +Password = "prover_pass" +Name = "prover_db" +Host = "xgon-state-db" +Port = "5432" +EnableLog = false +MaxConns = 200 diff --git a/test/config/prover/initproverdb.sql b/test/config/prover/init_prover_db.sql similarity index 50% rename from test/config/prover/initproverdb.sql rename to test/config/prover/init_prover_db.sql index ac1834ea..a4f8616c 100644 --- a/test/config/prover/initproverdb.sql +++ b/test/config/prover/init_prover_db.sql @@ -7,7 +7,9 @@ CREATE TABLE state.nodes (hash BYTEA PRIMARY KEY, data BYTEA NOT NULL); CREATE TABLE state.program (hash BYTEA PRIMARY KEY, data BYTEA NOT NULL); CREATE USER prover_user with password 'prover_pass'; -GRANT CONNECT ON DATABASE prover_db TO prover_user; -GRANT ALL PRIVILEGES ON SCHEMA state TO prover_user; -GRANT ALL PRIVILEGES ON TABLE state.nodes TO prover_user; -GRANT ALL PRIVILEGES ON TABLE state.program TO prover_user; +ALTER DATABASE prover_db OWNER TO prover_user; +ALTER SCHEMA state OWNER TO prover_user; +ALTER SCHEMA public OWNER TO prover_user; +ALTER TABLE state.nodes OWNER TO prover_user; +ALTER TABLE state.program OWNER TO prover_user; +ALTER USER prover_user SET SEARCH_PATH=state; diff --git a/test/config/prover/config.prover.json b/test/config/prover/test.prover.config.json similarity index 79% rename from test/config/prover/config.prover.json rename to test/config/prover/test.prover.config.json index 9a129de0..59022727 100644 --- a/test/config/prover/config.prover.json +++ b/test/config/prover/test.prover.config.json @@ -2,22 +2,18 @@ "runExecutorServer": true, "runExecutorClient": false, "runExecutorClientMultithread": false, - - "runStateDBServer": true, - "runStateDBTest": false, - + "runHashDBServer": true, + "runHashDBTest": false, "runAggregatorServer": false, "runAggregatorClient": false, - "runAggregatorClientMock": true, + "runAggregatorClientMock": true, "aggregatorClientMockTimeout": 1, "proverName": "test-prover", - "runFileGenBatchProof": false, "runFileGenAggregatedProof": false, "runFileGenFinalProof": false, "runFileProcessBatch": false, "runFileProcessBatchMultithread": false, - "runKeccakScriptGenerator": false, "runKeccakTest": false, "runStorageSMTest": false, @@ -25,9 +21,8 @@ "runMemAlignSMTest": false, "runSHA256Test": false, "runBlakeTest": false, - "executeInParallel": true, - "useMainExecGenerated": false, + "useMainExecGenerated": true, "saveRequestToFile": false, "saveInputToFile": false, "saveDbReadsToFile": false, @@ -39,48 +34,43 @@ "opcodeTracer": false, "logRemoteDbReads": false, "logExecutorServerResponses": false, - "proverServerPort": 50051, "proverServerMockPort": 50052, "proverServerMockTimeout": 10000000, "proverClientPort": 50051, "proverClientHost": "127.0.0.1", - "executorServerPort": 50071, "executorROMLineTraces": false, "executorClientPort": 50071, "executorClientHost": "127.0.0.1", - - "stateDBServerPort": 50061, - "stateDBURL": "local", - + "hashDBServerPort": 50061, + "hashDBURL": "local", "aggregatorServerPort": 50081, "aggregatorClientPort": 50081, - "aggregatorClientHost": "zkevm-node", - + "aggregatorClientHost": "xgon-aggregator", "mapConstPolsFile": false, "mapConstantsTreeFile": false, - "inputFile": "input_executor_0.json", "inputFile2": "input_executor_1.json", - "keccakScriptFile": "config/scripts/keccak_script.json", "storageRomFile": "config/scripts/storage_sm_rom.json", - "outputPath": "output", - - "databaseURL": "postgresql://prover_user:prover_pass@zkevm-state-db:5432/prover_db", + "databaseURL": "postgresql://prover_user:prover_pass@xgon-state-db:5432/prover_db", "dbNodesTableName": "state.nodes", "dbProgramTableName": "state.program", "dbMultiWrite": true, "dbFlushInParallel": false, "dbMTCacheSize": 1024, - "dbProgramCacheSize": 1024, + "dbProgramCacheSize": 512, "dbNumberOfPoolConnections": 30, + "dbGetTree": true, "cleanerPollingPeriod": 600, "requestsPersistence": 3600, "maxExecutorThreads": 20, "maxProverThreads": 8, - "maxStateDBThreads": 8 -} - + "maxHashDBThreads": 8, + "ECRecoverPrecalc": false, + "ECRecoverPrecalcNThreads": 4, + "stateManager": true, + "useAssociativeCache": false +} \ No newline at end of file diff --git a/test/e2e/bridge_test.go b/test/e2e/bridge_test.go index 4db52d5d..641f7e7f 100644 --- a/test/e2e/bridge_test.go +++ b/test/e2e/bridge_test.go @@ -13,13 +13,14 @@ import ( "github.com/0xPolygonHermez/zkevm-bridge-service/db" "github.com/0xPolygonHermez/zkevm-bridge-service/server" "github.com/0xPolygonHermez/zkevm-bridge-service/test/operations" + "github.com/0xPolygonHermez/zkevm-node/log" "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/require" ) var ( - l1BridgeAddr = common.HexToAddress("0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0") - l2BridgeAddr = common.HexToAddress("0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0") + l1BridgeAddr = common.HexToAddress("0x10B65c586f795aF3eCCEe594fE4E38E1F059F780") + l2BridgeAddr = common.HexToAddress("0x10B65c586f795aF3eCCEe594fE4E38E1F059F780") ) // TestE2E tests the flow of deposit and withdraw funds using the vector @@ -64,7 +65,8 @@ func TestE2E(t *testing.T) { opsman, err := operations.NewManager(ctx, opsCfg) require.NoError(t, err) - t.Run("L1-L2 eth bridge", func(t *testing.T) { + t.Run("L1-L2 okb bridge", func(t *testing.T) { + log.Infof("TestE2E, L1-L2 okb bridge start.") // Check initial globalExitRoot. Must fail because at the beginning, no globalExitRoot event is thrown. globalExitRootSMC, err := opsman.GetCurrentGlobalExitRootFromSmc(ctx) require.NoError(t, err) @@ -72,15 +74,17 @@ func TestE2E(t *testing.T) { // Send L1 deposit var destNetwork uint32 = 1 amount := new(big.Int).SetUint64(10000000000000000000) - tokenAddr := common.Address{} // This means is eth + okbAddr := common.HexToAddress("0x82109a709138A2953C720D3d775168717b668ba6") // This means is okb destAddr := common.HexToAddress("0xc949254d682d8c9ad5682521675b8f43b102aec4") - l1Balance, err := opsman.CheckAccountBalance(ctx, operations.L1, &l1BridgeAddr) + err = opsman.ApproveERC20OKB(ctx, okbAddr, amount) + l1Balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L1, okbAddr, &l1BridgeAddr) require.NoError(t, err) t.Logf("L1 Bridge Balance: %v", l1Balance) - err = opsman.SendL1Deposit(ctx, tokenAddr, amount, destNetwork, &destAddr) require.NoError(t, err) - l1Balance, err = opsman.CheckAccountBalance(ctx, operations.L1, &l1BridgeAddr) + err = opsman.SendL1Deposit(ctx, okbAddr, amount, destNetwork, &destAddr) + require.NoError(t, err) + l1Balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L1, okbAddr, &l1BridgeAddr) require.NoError(t, err) t.Logf("L1 Bridge Balance: %v", l1Balance) @@ -97,6 +101,7 @@ func TestE2E(t *testing.T) { // Check L2 funds balance, err := opsman.CheckAccountBalance(ctx, operations.L2, &destAddr) require.NoError(t, err) + log.Infof("balance:%v", balance.String()) initL2Balance := big.NewInt(0) require.Equal(t, 0, balance.Cmp(initL2Balance)) t.Log("Deposit: ", deposits[0]) @@ -104,7 +109,9 @@ func TestE2E(t *testing.T) { err = opsman.CheckL2Claim(ctx, uint(deposits[0].DestNet), uint(deposits[0].DepositCnt)) require.NoError(t, err) // Check L2 funds to see if the amount has been increased + log.Infof("destAddr:%v", destAddr.String()) balance2, err := opsman.CheckAccountBalance(ctx, operations.L2, &destAddr) + log.Infof("balance:%v, balance2:%v, amount:%v", balance.String(), balance2.String(), amount.String()) require.NoError(t, err) require.NotEqual(t, balance, balance2) require.Equal(t, amount, balance2) @@ -118,7 +125,7 @@ func TestE2E(t *testing.T) { l2Balance, err := opsman.CheckAccountBalance(ctx, operations.L2, &l2BridgeAddr) require.NoError(t, err) t.Logf("L2 Bridge Balance: %v", l2Balance) - err = opsman.SendL2Deposit(ctx, tokenAddr, amount, destNetwork, &destAddr) + err = opsman.SendL2Deposit(ctx, common.Address{}, amount, destNetwork, &destAddr) require.NoError(t, err) l2Balance, err = opsman.CheckAccountBalance(ctx, operations.L2, &l2BridgeAddr) require.NoError(t, err) @@ -147,13 +154,14 @@ func TestE2E(t *testing.T) { require.NoError(t, err) // Check L1 funds to see if the amount has been increased - balance, err = opsman.CheckAccountBalance(ctx, operations.L1, &destAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L1, okbAddr, &destAddr) require.NoError(t, err) require.Equal(t, big.NewInt(1000000000000000000), balance) // Check L2 funds to see that the amount has been reduced balance, err = opsman.CheckAccountBalance(ctx, operations.L2, &destAddr) require.NoError(t, err) require.True(t, big.NewInt(9000000000000000000).Cmp(balance) > 0) + log.Infof("TestE2E, L1-L2 okb bridge end.") }) t.Run("L1-L2 token bridge", func(t *testing.T) { @@ -162,6 +170,7 @@ func TestE2E(t *testing.T) { 2. Bridge from L2 to L1 3. Claim the deposits in both layers */ + log.Infof("TestE2E, L1-L2 token bridge start.") // Check initial globalExitRoot. globalExitRootSMC, err := opsman.GetCurrentGlobalExitRootFromSmc(ctx) require.NoError(t, err) @@ -170,12 +179,12 @@ func TestE2E(t *testing.T) { var destNetwork uint32 = 1 amount1 := new(big.Int).SetUint64(1000000000000000000) totAmount := new(big.Int).SetUint64(3500000000000000000) - tokenAddr, _, err := opsman.DeployERC20(ctx, "A COIN", "ACO", "l1") + tokenAddr, _, err := opsman.DeployERC20(ctx, "A COIN", "ACO", operations.L1) require.NoError(t, err) - err = opsman.MintERC20(ctx, tokenAddr, totAmount, "l1") + err = opsman.MintERC20(ctx, tokenAddr, totAmount, operations.L1) require.NoError(t, err) - origAddr := common.HexToAddress("0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC") - balance, err := opsman.CheckAccountTokenBalance(ctx, "l1", tokenAddr, &origAddr) + origAddr := common.HexToAddress("0x2ecf31ece36ccac2d3222a303b1409233ecbb225") + balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L1, tokenAddr, &origAddr) require.NoError(t, err) t.Log("Init account balance l1: ", balance) destAddr := common.HexToAddress("0xc949254d682d8c9ad5682521675b8f43b102aec4") @@ -193,7 +202,7 @@ func TestE2E(t *testing.T) { time.Sleep(3 * time.Second) // wait for sync token_wrapped event tokenWrapped, err := opsman.GetTokenWrapped(ctx, 0, tokenAddr, false) require.NoError(t, err) - balance2, err := opsman.CheckAccountTokenBalance(ctx, "l2", tokenWrapped.WrappedTokenAddress, &destAddr) + balance2, err := opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) t.Log("Init account balance l2: ", balance2) @@ -222,7 +231,7 @@ func TestE2E(t *testing.T) { err = opsman.SendL1Claim(ctx, deposits[0], smtProof, globaExitRoot) require.NoError(t, err) // Check L1 funds to see if the amount has been increased - balance, err = opsman.CheckAccountTokenBalance(ctx, "l1", tokenAddr, &origAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L1, tokenAddr, &origAddr) require.NoError(t, err) require.Equal(t, big.NewInt(2000000000000000000), balance) @@ -233,13 +242,15 @@ func TestE2E(t *testing.T) { err = opsman.CheckL2Claim(ctx, uint(deposits[0].DestNet), uint(deposits[0].DepositCnt)) require.NoError(t, err) // Check L2 funds to see if the amount has been increased - balance, err = opsman.CheckAccountTokenBalance(ctx, "l2", tokenWrapped.WrappedTokenAddress, &destAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) t.Log("Balance tokenWrapped: ", balance) require.Equal(t, new(big.Int).SetUint64(1500000000000000000), balance) + log.Infof("TestE2E, L1-L2 token bridge end.") }) t.Run("Reversal ERC20", func(t *testing.T) { + log.Infof("TestE2E, Reversal ERC20 start.") // Check initial globalExitRoot. globalExitRootSMC, err := opsman.GetCurrentGlobalExitRootFromSmc(ctx) require.NoError(t, err) @@ -257,8 +268,10 @@ func TestE2E(t *testing.T) { balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenAddr, &origAddr) require.NoError(t, err) t.Log("Token balance: ", balance, ". tokenaddress: ", tokenAddr, ". account: ", origAddr) - destAddr := common.HexToAddress("0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC") + destAddr := common.HexToAddress("0x2ecf31ece36ccac2d3222a303b1409233ecbb225") amount = new(big.Int).SetUint64(1000000000000000000) + err = opsman.SetL2TokensAllowed(ctx, true) + require.NoError(t, err) err = opsman.SendL2Deposit(ctx, tokenAddr, amount, destNetwork, &destAddr) require.NoError(t, err) // Check globalExitRoot @@ -331,9 +344,11 @@ func TestE2E(t *testing.T) { balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L1, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) require.Equal(t, 0, big.NewInt(400000000000000000).Cmp(balance)) + log.Infof("TestE2E, Reversal ERC20 end.") }) t.Run("ERC20", func(t *testing.T) { + log.Infof("TestE2E, ERC20 start.") // Check initial globalExitRoot. globalExitRootSMC, err := opsman.GetCurrentGlobalExitRootFromSmc(ctx) require.NoError(t, err) @@ -345,7 +360,7 @@ func TestE2E(t *testing.T) { require.NoError(t, err) err = opsman.MintERC20(ctx, tokenAddr, amount, operations.L1) require.NoError(t, err) - origAddr := common.HexToAddress("0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC") + origAddr := common.HexToAddress("0x2ecf31ece36ccac2d3222a303b1409233ecbb225") balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L1, tokenAddr, &origAddr) require.NoError(t, err) t.Log("Init account balance l1: ", balance) @@ -414,6 +429,7 @@ func TestE2E(t *testing.T) { balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) require.Equal(t, big.NewInt(2000000000000000000), balance) + log.Infof("TestE2E, ERC20 end.") }) t.Run("Multi deposits", func(t *testing.T) { @@ -422,7 +438,7 @@ func TestE2E(t *testing.T) { 2. Do 2 more deposits 3. Claim the first 3 deposits in L2 */ - + log.Infof("TestE2E, Multi deposits start.") // Check initial globalExitRoot. globalExitRootSMC, err := opsman.GetCurrentGlobalExitRootFromSmc(ctx) require.NoError(t, err) @@ -433,12 +449,12 @@ func TestE2E(t *testing.T) { amount2 := new(big.Int).SetUint64(2000000000000000000) amount3 := new(big.Int).SetUint64(3000000000000000000) totAmount := new(big.Int).SetUint64(9000000000000000000) - tokenAddr, _, err := opsman.DeployERC20(ctx, "A COIN", "ACO", "l1") + tokenAddr, _, err := opsman.DeployERC20(ctx, "A COIN", "ACO", operations.L1) require.NoError(t, err) - err = opsman.MintERC20(ctx, tokenAddr, totAmount, "l1") + err = opsman.MintERC20(ctx, tokenAddr, totAmount, operations.L1) require.NoError(t, err) - origAddr := common.HexToAddress("0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC") - balance, err := opsman.CheckAccountTokenBalance(ctx, "l1", tokenAddr, &origAddr) + origAddr := common.HexToAddress("0x2ecf31ece36ccac2d3222a303b1409233ecbb225") + balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L1, tokenAddr, &origAddr) require.NoError(t, err) t.Log("Init account balance l1: ", balance) destAddr := common.HexToAddress("0xc949254d682d8c9ad5682521675b8f43b102aec4") @@ -477,35 +493,37 @@ func TestE2E(t *testing.T) { require.NoError(t, err) t.Log("TokenWrapped: ", tokenWrapped) // Check L2 funds to see if the amount has been increased - balance, err = opsman.CheckAccountTokenBalance(ctx, "l2", tokenWrapped.WrappedTokenAddress, &destAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) t.Log("Balance tokenWrapped: ", balance) // Check the claim tx err = opsman.CheckL2Claim(ctx, uint(deposits[0].DestNet), uint(deposits[0].DepositCnt)) require.NoError(t, err) - balance, err = opsman.CheckAccountTokenBalance(ctx, "l2", tokenWrapped.WrappedTokenAddress, &destAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) // Check the claim tx err = opsman.CheckL2Claim(ctx, uint(deposits[0].DestNet), uint(deposits[0].DepositCnt)) require.NoError(t, err) // Check L2 funds to see if the amount has been increased - balance, err = opsman.CheckAccountTokenBalance(ctx, "l2", tokenWrapped.WrappedTokenAddress, &destAddr) + balance, err = opsman.CheckAccountTokenBalance(ctx, operations.L2, tokenWrapped.WrappedTokenAddress, &destAddr) require.NoError(t, err) t.Log("Balance tokenWrapped: ", balance) require.Equal(t, new(big.Int).SetUint64(6000000000000000000), balance) + log.Infof("TestE2E, Multi deposits end.") }) t.Run("Bridge Message Test", func(t *testing.T) { // Test L1 Bridge Message // Send L1 bridge message + log.Infof("TestE2E, Bridge Message Test start.") var destNetwork uint32 = 1 amount := new(big.Int).SetUint64(1000000000000000000) destAddr, err := opsman.DeployBridgeMessageReceiver(ctx, operations.L1) require.NoError(t, err) - + log.Infof("first, destAddr:%v,amount:%v,destNetwork:%v", destAddr.String(), amount.String(), destNetwork) err = opsman.SendL1BridgeMessage(ctx, destAddr, destNetwork, amount, []byte("metadata")) require.NoError(t, err) @@ -519,13 +537,38 @@ func TestE2E(t *testing.T) { err = opsman.SendL2Claim(ctx, deposits[0], smtProof, globaExitRoot) require.NoError(t, err) + // Send L1 message to L2' 0xc949254d682d8c9ad5682521675b8f43b102aec4 + destAddr = common.HexToAddress("0xc949254d682d8c9ad5682521675b8f43b102aec4") + log.Infof("second, destAddr:%v,amount:%v,destNetwork:%v", destAddr.String(), amount.String(), destNetwork) + err = opsman.SendL1BridgeMessage(ctx, destAddr, destNetwork, amount, []byte("metadata")) + require.NoError(t, err) + + // Get Bridge Info By DestAddr + deposits, err = opsman.GetBridgeInfoByDestAddr(ctx, &destAddr) + require.NoError(t, err) + // Get the claim data + smtProof, globaExitRoot, err = opsman.GetClaimData(ctx, uint(deposits[0].NetworkId), uint(deposits[0].DepositCnt)) + require.NoError(t, err) + // Check the claim tx + err = opsman.SendL2Claim(ctx, deposits[0], smtProof, globaExitRoot) + require.NoError(t, err) + + l2ETHWrapAddress := common.HexToAddress("0x82109a709138A2953C720D3d775168717b668ba6") + balance, err := opsman.CheckAccountTokenBalance(ctx, operations.L2, l2ETHWrapAddress, &destAddr) + require.NoError(t, err) + log.Infof("destAddr:%v, balance:%v ", destAddr.String(), balance) + require.Equal(t, amount, balance) + + err = opsman.ApproveERC20(ctx, l2ETHWrapAddress, amount, operations.L2) + require.NoError(t, err) + // Test L2 Bridge Message // Send L2 bridge message destNetwork = 0 destAddr, err = opsman.DeployBridgeMessageReceiver(ctx, operations.L2) require.NoError(t, err) - + log.Infof("destAddr:%v, destNetwork:%v, amount:%v", destAddr.String(), destNetwork, amount.String()) err = opsman.SendL2BridgeMessage(ctx, destAddr, destNetwork, amount, []byte("metadata")) require.NoError(t, err) @@ -539,5 +582,6 @@ func TestE2E(t *testing.T) { t.Logf("globalExitRoot: %+v", globaExitRoot) err = opsman.SendL1Claim(ctx, deposits[0], smtProof, globaExitRoot) require.NoError(t, err) + log.Infof("TestE2E, Bridge Message Test end.") }) } diff --git a/test/e2e/edge_test.go b/test/e2e/edge_test.go index 1442308d..541cce5c 100644 --- a/test/e2e/edge_test.go +++ b/test/e2e/edge_test.go @@ -19,11 +19,13 @@ import ( func depositFromL1(ctx context.Context, opsman *operations.Manager, t *testing.T) { amount := new(big.Int).SetUint64(250000000000000000) - tokenAddr := common.Address{} // This means is eth + okbAddr := common.HexToAddress("0x82109a709138A2953C720D3d775168717b668ba6") // This means is okb destAddr := common.HexToAddress("0xc949254d682d8c9ad5682521675b8f43b102aec4") var destNetwork uint32 = 1 // L1 Deposit - err := opsman.SendL1Deposit(ctx, tokenAddr, amount, destNetwork, &destAddr) + err := opsman.ApproveERC20OKB(ctx, okbAddr, amount) + require.NoError(t, err) + err = opsman.SendL1Deposit(ctx, okbAddr, amount, destNetwork, &destAddr) require.NoError(t, err) deposits, err := opsman.GetBridgeInfoByDestAddr(ctx, &destAddr) @@ -37,8 +39,8 @@ func depositFromL2(ctx context.Context, opsman *operations.Manager, t *testing.T // Send L2 Deposit to withdraw the some funds var destNetwork uint32 = 0 amount := new(big.Int).SetUint64(100000000000000000) - tokenAddr := common.Address{} // This means is eth - destAddr := common.HexToAddress("0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC") + tokenAddr := common.Address{} // This means is okb + destAddr := common.HexToAddress("0x2ecf31ece36ccac2d3222a303b1409233ecbb225") err := opsman.SendL2Deposit(ctx, tokenAddr, amount, destNetwork, &destAddr) require.NoError(t, err) diff --git a/test/operations/manager.go b/test/operations/manager.go index 62ed2b3a..c48a2f5c 100644 --- a/test/operations/manager.go +++ b/test/operations/manager.go @@ -25,6 +25,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/pkg/errors" ) // NetworkSID is used to identify the network. @@ -43,11 +44,11 @@ const ( l2NetworkURL = "http://localhost:8123" // MaticTokenAddress token address - MaticTokenAddress = "0x5FbDB2315678afecb367f032d93F642f64180aa3" //nolint:gosec - l1BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" - l2BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" + MaticTokenAddress = "0xcFE6D77a653b988203BfAc9C6a69eA9D583bdC2b" //nolint:gosec + l1BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" + l2BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" - l1AccHexAddress = "0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC" + l1AccHexAddress = "0x2ecf31ece36ccac2d3222a303b1409233ecbb225" sequencerAddress = "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" @@ -60,7 +61,7 @@ const ( var ( dbConfig = pgstorage.NewConfigFromEnv() accHexPrivateKeys = map[NetworkSID]string{ - L1: "0x5de4111afa1a4b94908f83103eb1f1706367c2e68ca870fc3fb9a804cdab365a", //0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC + L1: "0xde3ca643a52f5543e84ba984c4419ff40dbabd0e483c31c1d09fee8168d68e38", //0x2ecf31ece36ccac2d3222a303b1409233ecbb225 L2: "0xdfd01798f92667dbf91df722434e8fbe96af0211d4d1b82bbbbc8f1def7a814f", //0xc949254d682d8c9ad5682521675b8f43b102aec4 } ) @@ -118,7 +119,7 @@ func NewManager(ctx context.Context, cfg *Config) (*Manager, error) { if err != nil { return nil, err } - bService := server.NewBridgeService(cfg.BS, cfg.BT.Height, []uint{0, 1}, pgst) + bService := server.NewBridgeService(cfg.BS, cfg.BT.Height, []uint{0, 1}, []uint{5, 1001}, pgst, nil, nil) opsman.storage = st.(StorageInterface) opsman.bridgetree = bt opsman.bridgeService = bService @@ -166,6 +167,22 @@ func (m *Manager) SendL1Deposit(ctx context.Context, tokenAddr common.Address, a return m.WaitExitRootToBeSynced(ctx, orgExitRoot, false) } +// SetL2TokensAllowed set l2 tokens allowed set +func (m *Manager) SetL2TokensAllowed(ctx context.Context, allowed bool) error { + client := m.clients[L2] + auth, err := client.GetSigner(ctx, accHexPrivateKeys[L1]) + if err != nil { + return err + } + + err = client.SetL2TokensAllowed(ctx, allowed, auth) + if err != nil { + return errors.Wrap(err, "SetL2TokensAllowed") + } + + return nil +} + // SendL2Deposit sends a deposit from l2 to l1. func (m *Manager) SendL2Deposit(ctx context.Context, tokenAddr common.Address, amount *big.Int, destNetwork uint32, destAddr *common.Address, @@ -183,7 +200,7 @@ func (m *Manager) SendL2Deposit(ctx context.Context, tokenAddr common.Address, a err = client.SendBridgeAsset(ctx, tokenAddr, amount, destNetwork, destAddr, []byte{}, auth) if err != nil { - return err + return errors.Wrap(err, "SendBridgeAsset") } // sync for new exit root @@ -226,8 +243,8 @@ func (m *Manager) SendL2BridgeMessage(ctx context.Context, destAddr common.Addre return err } - auth.Value = amount - err = client.SendBridgeMessage(ctx, destNetwork, destAddr, metadata, auth) + //auth.Value = amount + err = client.SendL2BridgeMessage(ctx, destNetwork, amount, destAddr, metadata, auth) if err != nil { return err } @@ -463,7 +480,7 @@ func (m *Manager) CheckAccountBalance(ctx context.Context, network NetworkSID, a client := m.clients[network] auth, err := client.GetSigner(ctx, accHexPrivateKeys[network]) if err != nil { - return big.NewInt(0), nil + return big.NewInt(0), errors.Wrap(err, "GetSigner failed") } if account == nil { @@ -471,8 +488,9 @@ func (m *Manager) CheckAccountBalance(ctx context.Context, network NetworkSID, a } balance, err := client.BalanceAt(ctx, *account, nil) if err != nil { - return big.NewInt(0), nil + return big.NewInt(0), errors.Wrap(err, "eth_getBalance failed") } + log.Debugf("CheckAccountBalance success network[%v] account[%v] balance[%v]", network, account.String(), balance.String()) return balance, nil } @@ -481,7 +499,7 @@ func (m *Manager) CheckAccountTokenBalance(ctx context.Context, network NetworkS client := m.clients[network] auth, err := client.GetSigner(ctx, accHexPrivateKeys[network]) if err != nil { - return big.NewInt(0), nil + return big.NewInt(0), errors.Wrap(err, "GetSigner failed") } if account == nil { @@ -489,12 +507,13 @@ func (m *Manager) CheckAccountTokenBalance(ctx context.Context, network NetworkS } erc20Token, err := erc20.NewMatic(tokenAddr, client) if err != nil { - return big.NewInt(0), nil + return big.NewInt(0), errors.Wrap(err, "NewMatic failed") } balance, err := erc20Token.BalanceOf(&bind.CallOpts{Pending: false}, *account) if err != nil { - return big.NewInt(0), nil + return big.NewInt(0), errors.Wrap(err, "balanceOf failed") } + log.Debugf("CheckAccountTokenBalance success network[%v] tokenAddr[%v] account[%v] balance[%v]", network, tokenAddr.String(), account.String(), balance.String()) return balance, nil } @@ -629,7 +648,7 @@ func (m *Manager) MintERC20(ctx context.Context, erc20Addr common.Address, amoun client := m.clients[network] auth, err := client.GetSigner(ctx, accHexPrivateKeys[network]) if err != nil { - return err + return errors.Wrap(err, "GetSigner") } var bridgeAddress = l1BridgeAddr @@ -639,19 +658,35 @@ func (m *Manager) MintERC20(ctx context.Context, erc20Addr common.Address, amoun err = client.ApproveERC20(ctx, erc20Addr, common.HexToAddress(bridgeAddress), amount, auth) if err != nil { - return err + return errors.Wrap(err, "ApproveERC20") } - return client.MintERC20(ctx, erc20Addr, amount, auth) + return errors.Wrap(client.MintERC20(ctx, erc20Addr, amount, auth), "MintERC20") +} + +// ApproveERC20OKB approves erc20 tokens +func (m *Manager) ApproveERC20OKB(ctx context.Context, okbAddress common.Address, amount *big.Int) error { + client := m.clients[L1] + auth, err := client.GetSigner(ctx, accHexPrivateKeys[L1]) + if err != nil { + return err + } + return client.ApproveERC20(ctx, okbAddress, common.HexToAddress(l1BridgeAddr), amount, auth) } // ApproveERC20 approves erc20 tokens -func (m *Manager) ApproveERC20(ctx context.Context, erc20Addr, bridgeAddr common.Address, amount *big.Int, network NetworkSID) error { +func (m *Manager) ApproveERC20(ctx context.Context, erc20Addr common.Address, amount *big.Int, network NetworkSID) error { client := m.clients[network] auth, err := client.GetSigner(ctx, accHexPrivateKeys[network]) if err != nil { return err } + + bridgeAddr := common.HexToAddress(l1BridgeAddr) + if network == L2 { + bridgeAddr = common.HexToAddress(l2BridgeAddr) + } + return client.ApproveERC20(ctx, erc20Addr, bridgeAddr, amount, auth) } diff --git a/test/operations/mockserver.go b/test/operations/mockserver.go index 71aa3f14..b181bfde 100644 --- a/test/operations/mockserver.go +++ b/test/operations/mockserver.go @@ -43,6 +43,6 @@ func RunMockServer(dbType string, height uint8, networks []uint) (*bridgectrl.Br MaxPageLimit: 100, //nolint:gomnd BridgeVersion: "v1", } - bridgeService := server.NewBridgeService(cfg, btCfg.Height, networks, store) + bridgeService := server.NewBridgeService(cfg, btCfg.Height, networks, []uint{5, 1001}, store, nil, nil) return bt, store, server.RunServer(cfg, bridgeService) } diff --git a/test/scripts/claim/main.go b/test/scripts/claim/main.go index 40d96fd8..3ef1e253 100644 --- a/test/scripts/claim/main.go +++ b/test/scripts/claim/main.go @@ -11,7 +11,7 @@ import ( ) const ( - l2BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" + l2BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" l2AccHexAddress = "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" l2AccHexPrivateKey = "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" diff --git a/test/scripts/deposit/main.go b/test/scripts/deposit/main.go index 4ff7f7d8..07128668 100644 --- a/test/scripts/deposit/main.go +++ b/test/scripts/deposit/main.go @@ -10,7 +10,7 @@ import ( ) const ( - l1BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" + l1BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" l1AccHexAddress = "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" l1AccHexPrivateKey = "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" diff --git a/test/scripts/forcebatchproposal/main.go b/test/scripts/forcebatchproposal/main.go index c4902564..9ed4ab55 100644 --- a/test/scripts/forcebatchproposal/main.go +++ b/test/scripts/forcebatchproposal/main.go @@ -15,8 +15,8 @@ const ( l1AccHexPrivateKey = "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" l1NetworkURL = "http://localhost:8545" - polygonZkEVMAddressHex = "0x610178dA211FEF7D417bC0e6FeD39F05609AD788" - maticTokenAddressHex = "0x5FbDB2315678afecb367f032d93F642f64180aa3" //nolint:gosec + polygonZkEVMAddressHex = "0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C" + maticTokenAddressHex = "0xcFE6D77a653b988203BfAc9C6a69eA9D583bdC2b" //nolint:gosec ) func main() { @@ -44,7 +44,7 @@ func main() { if err != nil { log.Fatal("Error approving matics: ", err) } - tx, err := polygonZkEVM.SequenceBatches(auth, nil, auth.From) + tx, err := polygonZkEVM.SequenceBatches(auth, nil, auth.From, nil) if err != nil { log.Fatal("Error sending the batch: ", err) } diff --git a/test/scripts/initialClaim/Readme.md b/test/scripts/initialClaim/Readme.md index 14406f00..10ab02b6 100644 --- a/test/scripts/initialClaim/Readme.md +++ b/test/scripts/initialClaim/Readme.md @@ -5,8 +5,8 @@ Typically this action is used to include the claim tx to fill the bridge autocla ## Parameters At the beginning of the script there are the next constant variables that need to be reviewed. ``` - l2BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" - zkevmAddr = "0x610178dA211FEF7D417bC0e6FeD39F05609AD788" + l2BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" + zkevmAddr = "0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C" accHexAddress = "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" accHexPrivateKey = "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" diff --git a/test/scripts/initialClaim/main.go b/test/scripts/initialClaim/main.go index 9361799e..cb56ae70 100644 --- a/test/scripts/initialClaim/main.go +++ b/test/scripts/initialClaim/main.go @@ -20,8 +20,8 @@ import ( ) const ( - l2BridgeAddr = "0xff0EE8ea08cEf5cb4322777F5CC3E8A584B8A4A0" - zkevmAddr = "0x610178dA211FEF7D417bC0e6FeD39F05609AD788" + l2BridgeAddr = "0x10B65c586f795aF3eCCEe594fE4E38E1F059F780" + zkevmAddr = "0x0D9088C72Cd4F08e9dDe474D8F5394147f64b22C" accHexAddress = "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266" accHexPrivateKey = "0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80" @@ -29,6 +29,8 @@ const ( l2NetworkURL = "http://localhost:8123" bridgeURL = "http://localhost:8080" + forkID = 4 + l2GasLimit = 1000000 mtHeight = 32 @@ -112,7 +114,7 @@ func main() { } encoded := hex.EncodeToHex(b) log.Info("tx encoded: ", encoded) - byt, err := state.EncodeTransaction(*tx) + byt, err := state.EncodeTransaction(*tx, state.MaxEffectivePercentage, forkID) if err != nil { log.Fatal("error: ", err) } diff --git a/test/test.keystore.da b/test/test.keystore.da new file mode 100644 index 00000000..96b662b7 --- /dev/null +++ b/test/test.keystore.da @@ -0,0 +1 @@ +{"address":"f39fd6e51aad88f6f4ce6ab8827279cfffb92266","crypto":{"cipher":"aes-128-ctr","ciphertext":"d005030a7684f3adad2447cbb27f63039eec2224c451eaa445de0d90502b9f3d","cipherparams":{"iv":"dc07a54bc7e388efa89c34d42f2ebdb4"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":262144,"p":1,"r":8,"salt":"cf2ec55ecae11171de575112cfb16963570533a9c46fb774473ceb11519eb24a"},"mac":"3eb180d405a5da6e462b2adc00091c14856c91d574bf27348714506357d6e177"},"id":"035454db-6b6d-477f-8a79-ce24c10b185f","version":3} \ No newline at end of file diff --git a/utils/client.go b/utils/client.go index e9c2c356..1bc396ae 100644 --- a/utils/client.go +++ b/utils/client.go @@ -16,6 +16,7 @@ import ( zkevmtypes "github.com/0xPolygonHermez/zkevm-node/config/types" "github.com/0xPolygonHermez/zkevm-node/encoding" "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/polygonzkevmbridge" + "github.com/0xPolygonHermez/zkevm-node/etherman/smartcontracts/polygonzkevmbridgel2" "github.com/0xPolygonHermez/zkevm-node/log" "github.com/0xPolygonHermez/zkevm-node/test/contracts/bin/ERC20" ops "github.com/0xPolygonHermez/zkevm-node/test/operations" @@ -42,7 +43,8 @@ const ( type Client struct { // Client ethclient *ethclient.Client - bridge *polygonzkevmbridge.Polygonzkevmbridge + bridge *polygonzkevmbridge.Polygonzkevmbridge + bridgeL2 *polygonzkevmbridgel2.Polygonzkevmbridgel2 } // NewClient creates client. @@ -52,12 +54,16 @@ func NewClient(ctx context.Context, nodeURL string, bridgeSCAddr common.Address) return nil, err } var br *polygonzkevmbridge.Polygonzkevmbridge + var brl2 *polygonzkevmbridgel2.Polygonzkevmbridgel2 if len(bridgeSCAddr) != 0 { - br, err = polygonzkevmbridge.NewPolygonzkevmbridge(bridgeSCAddr, client) + br, _ = polygonzkevmbridge.NewPolygonzkevmbridge(bridgeSCAddr, client) + brl2, err = polygonzkevmbridgel2.NewPolygonzkevmbridgel2(bridgeSCAddr, client) } + log.Infof("nodeURL:%v, bridgeSCAddr:%v, ", nodeURL, bridgeSCAddr.String()) return &Client{ - Client: client, - bridge: br, + Client: client, + bridge: br, + bridgeL2: brl2, }, err } @@ -166,6 +172,7 @@ func (c *Client) SendBridgeAsset(ctx context.Context, tokenAddr common.Address, if destAddr == nil { destAddr = &auth.From } + log.Infof("token address:%v, amount:%v, destnetwork:%v, dest address:%v", tokenAddr.String(), amount.String(), destNetwork, destAddr.String()) tx, err := c.bridge.BridgeAsset(auth, destNetwork, *destAddr, amount, tokenAddr, true, metadata) if err != nil { log.Error("Error: ", err) @@ -190,6 +197,20 @@ func (c *Client) SendBridgeMessage(ctx context.Context, destNetwork uint32, dest return WaitTxToBeMined(ctx, c.Client, tx, txTimeout) } +// SendL2BridgeMessage sends a bridge message transaction. +func (c *Client) SendL2BridgeMessage(ctx context.Context, destNetwork uint32, amountWETH *big.Int, destAddr common.Address, metadata []byte, + auth *bind.TransactOpts, +) error { + tx, err := c.bridgeL2.BridgeMessage(auth, destNetwork, destAddr, amountWETH, true, metadata) + if err != nil { + log.Error("Error: ", err) + return err + } + // wait transfer to be included in a batch + const txTimeout = 60 * time.Second + return WaitTxToBeMined(ctx, c.Client, tx, txTimeout) +} + // BuildSendClaim builds a tx data to be sent to the bridge method SendClaim. func (c *Client) BuildSendClaim(ctx context.Context, deposit *etherman.Deposit, smtProof [mtHeight][keyLen]byte, globalExitRoot *etherman.GlobalExitRoot, nonce, gasPrice int64, gasLimit uint64, auth *bind.TransactOpts) (*types.Transaction, error) { opts := *auth @@ -246,6 +267,24 @@ func (c *Client) SendClaim(ctx context.Context, deposit *pb.Deposit, smtProof [m return WaitTxToBeMined(ctx, c.Client, tx, txTimeout) } +// SetL2TokensAllowed set l2 token allowed. +func (c *Client) SetL2TokensAllowed(ctx context.Context, allowed bool, auth *bind.TransactOpts) error { + result, _ := c.bridgeL2.IsAllL2TokensAllowed(&bind.CallOpts{}) + if result == allowed { + log.Infof("Do nothing, allowed:%v", allowed) + return nil + } + + tx, err := c.bridgeL2.SetAllL2TokensAllowed(auth, allowed) + if err != nil { + log.Error("Error: ", err) + return err + } + // wait transfer to be included in a batch + const txTimeout = 60 * time.Second + return WaitTxToBeMined(ctx, c.Client, tx, txTimeout) +} + // WaitTxToBeMined waits until a tx is mined or forged. func WaitTxToBeMined(ctx context.Context, client *ethclient.Client, tx *types.Transaction, timeout time.Duration) error { return ops.WaitTxToBeMined(ctx, client, tx, timeout)