@arbitrum/nitro-contracts 3.1.0 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/contracts/@openzeppelin/contracts/access/Ownable.sol/Ownable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/interfaces/draft-IERC1822.sol/IERC1822Proxiable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/ERC1967/ERC1967Proxy.sol/ERC1967Proxy.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/ERC1967/ERC1967Upgrade.sol/ERC1967Upgrade.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/Proxy.sol/Proxy.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/beacon/IBeacon.sol/IBeacon.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/beacon/UpgradeableBeacon.sol/UpgradeableBeacon.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/transparent/ProxyAdmin.sol/ProxyAdmin.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/transparent/TransparentUpgradeableProxy.sol/TransparentUpgradeableProxy.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol/UUPSUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/security/ReentrancyGuard.sol/ReentrancyGuard.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/token/ERC20/ERC20.sol/ERC20.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/token/ERC20/IERC20.sol/IERC20.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol/IERC20Metadata.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/token/ERC20/extensions/draft-IERC20Permit.sol/IERC20Permit.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol/SafeERC20.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/Address.sol/Address.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/Context.sol/Context.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/Create2.sol/Create2.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/StorageSlot.sol/StorageSlot.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/Strings.sol/Strings.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts/utils/cryptography/ECDSA.sol/ECDSA.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/access/AccessControlEnumerableUpgradeable.sol/AccessControlEnumerableUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol/AccessControlUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/access/IAccessControlEnumerableUpgradeable.sol/IAccessControlEnumerableUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/access/IAccessControlUpgradeable.sol/IAccessControlUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol/OwnableUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol/Initializable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol/PausableUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol/ERC20Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/token/ERC20/IERC20Upgradeable.sol/IERC20Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/token/ERC20/extensions/ERC20BurnableUpgradeable.sol/ERC20BurnableUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/token/ERC20/extensions/IERC20MetadataUpgradeable.sol/IERC20MetadataUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol/AddressUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol/ContextUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/Create2Upgradeable.sol/Create2Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/StorageSlotUpgradeable.sol/StorageSlotUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/StringsUpgradeable.sol/StringsUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/cryptography/ECDSAUpgradeable.sol/ECDSAUpgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/cryptography/draft-EIP712Upgradeable.sol/EIP712Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol/ERC165Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/introspection/IERC165Upgradeable.sol/IERC165Upgradeable.dbg.json +1 -1
- package/build/contracts/@openzeppelin/contracts-upgradeable/utils/structs/EnumerableSetUpgradeable.sol/EnumerableSetUpgradeable.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/AbsBoldStakingPool.sol/AbsBoldStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/AssertionStakingPool.sol/AssertionStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/AssertionStakingPoolCreator.sol/AssertionStakingPoolCreator.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/EdgeStakingPool.sol/EdgeStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/EdgeStakingPoolCreator.sol/EdgeStakingPoolCreator.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/StakingPoolCreatorUtils.sol/StakingPoolCreatorUtils.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/interfaces/IAbsBoldStakingPool.sol/IAbsBoldStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/interfaces/IAssertionStakingPool.sol/IAssertionStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/interfaces/IAssertionStakingPoolCreator.sol/IAssertionStakingPoolCreator.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/interfaces/IEdgeStakingPool.sol/IEdgeStakingPool.dbg.json +1 -1
- package/build/contracts/src/assertionStakingPool/interfaces/IEdgeStakingPoolCreator.sol/IEdgeStakingPoolCreator.dbg.json +1 -1
- package/build/contracts/src/bridge/AbsBridge.sol/AbsBridge.dbg.json +1 -1
- package/build/contracts/src/bridge/AbsInbox.sol/AbsInbox.dbg.json +1 -1
- package/build/contracts/src/bridge/AbsOutbox.sol/AbsOutbox.dbg.json +1 -1
- package/build/contracts/src/bridge/Bridge.sol/Bridge.dbg.json +1 -1
- package/build/contracts/src/bridge/DelayBuffer.sol/DelayBuffer.dbg.json +1 -1
- package/build/contracts/src/bridge/ERC20Bridge.sol/ERC20Bridge.dbg.json +1 -1
- package/build/contracts/src/bridge/ERC20Inbox.sol/ERC20Inbox.dbg.json +1 -1
- package/build/contracts/src/bridge/ERC20Outbox.sol/ERC20Outbox.dbg.json +1 -1
- package/build/contracts/src/bridge/GasRefunder.sol/GasRefunder.dbg.json +1 -1
- package/build/contracts/src/bridge/IBridge.sol/IBridge.dbg.json +1 -1
- package/build/contracts/src/bridge/IDelayedMessageProvider.sol/IDelayedMessageProvider.dbg.json +1 -1
- package/build/contracts/src/bridge/IERC20Bridge.sol/IERC20Bridge.dbg.json +1 -1
- package/build/contracts/src/bridge/IERC20Inbox.sol/IERC20Inbox.dbg.json +1 -1
- package/build/contracts/src/bridge/IEthBridge.sol/IEthBridge.dbg.json +1 -1
- package/build/contracts/src/bridge/IInbox.sol/IInbox.dbg.json +1 -1
- package/build/contracts/src/bridge/IInboxBase.sol/IInboxBase.dbg.json +1 -1
- package/build/contracts/src/bridge/IOutbox.sol/IOutbox.dbg.json +1 -1
- package/build/contracts/src/bridge/IOwnable.sol/IOwnable.dbg.json +1 -1
- package/build/contracts/src/bridge/ISequencerInbox.sol/IFeeTokenPricer.dbg.json +1 -1
- package/build/contracts/src/bridge/ISequencerInbox.sol/ISequencerInbox.dbg.json +1 -1
- package/build/contracts/src/bridge/Inbox.sol/Inbox.dbg.json +1 -1
- package/build/contracts/src/bridge/Messages.sol/Messages.dbg.json +1 -1
- package/build/contracts/src/bridge/Outbox.sol/Outbox.dbg.json +1 -1
- package/build/contracts/src/bridge/SequencerInbox.sol/SequencerInbox.dbg.json +1 -1
- package/build/contracts/src/bridge/extra/ERC20MigrationOutbox.sol/ERC20MigrationOutbox.dbg.json +4 -0
- package/build/contracts/src/bridge/extra/ERC20MigrationOutbox.sol/ERC20MigrationOutbox.json +113 -0
- package/build/contracts/src/bridge/extra/IERC20MigrationOutbox.sol/IERC20MigrationOutbox.dbg.json +4 -0
- package/build/contracts/src/bridge/extra/IERC20MigrationOutbox.sol/IERC20MigrationOutbox.json +97 -0
- package/build/contracts/src/chain/CacheManager.sol/CacheManager.dbg.json +1 -1
- package/build/contracts/src/chain/CacheManager.sol/CacheManager.json +2 -2
- package/build/contracts/src/challengeV2/IAssertionChain.sol/IAssertionChain.dbg.json +1 -1
- package/build/contracts/src/challengeV2/IEdgeChallengeManager.sol/IEdgeChallengeManager.dbg.json +1 -1
- package/build/contracts/src/challengeV2/libraries/ArrayUtilsLib.sol/ArrayUtilsLib.dbg.json +1 -1
- package/build/contracts/src/challengeV2/libraries/ChallengeEdgeLib.sol/ChallengeEdgeLib.dbg.json +1 -1
- package/build/contracts/src/challengeV2/libraries/EdgeChallengeManagerLib.sol/EdgeChallengeManagerLib.dbg.json +1 -1
- package/build/contracts/src/challengeV2/libraries/MerkleTreeAccumulatorLib.sol/MerkleTreeAccumulatorLib.dbg.json +1 -1
- package/build/contracts/src/challengeV2/libraries/UintUtilsLib.sol/UintUtilsLib.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/Balance.sol/BalanceLib.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/Burner.sol/Burner.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/ELCRound.sol/LatestELCRoundsLib.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/ExpressLaneAuction.sol/ExpressLaneAuction.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/ExpressLaneAuction.sol/ExpressLaneAuction.json +2 -2
- package/build/contracts/src/express-lane-auction/IExpressLaneAuction.sol/IExpressLaneAuction.dbg.json +1 -1
- package/build/contracts/src/express-lane-auction/RoundTimingInfo.sol/RoundTimingInfoLib.dbg.json +1 -1
- package/build/contracts/src/libraries/AddressAliasHelper.sol/AddressAliasHelper.dbg.json +1 -1
- package/build/contracts/src/libraries/AdminFallbackProxy.sol/AdminFallbackProxy.dbg.json +1 -1
- package/build/contracts/src/libraries/AdminFallbackProxy.sol/DoubleLogicERC1967Upgrade.dbg.json +1 -1
- package/build/contracts/src/libraries/ArbitrumChecker.sol/ArbitrumChecker.dbg.json +1 -1
- package/build/contracts/src/libraries/CallerChecker.sol/CallerChecker.dbg.json +1 -1
- package/build/contracts/src/libraries/CryptographyPrimitives.sol/CryptographyPrimitives.dbg.json +1 -1
- package/build/contracts/src/libraries/DecimalsConverterHelper.sol/DecimalsConverterHelper.dbg.json +1 -1
- package/build/contracts/src/libraries/DelegateCallAware.sol/DelegateCallAware.dbg.json +1 -1
- package/build/contracts/src/libraries/DoubleLogicUUPSUpgradeable.sol/DoubleLogicUUPSUpgradeable.dbg.json +1 -1
- package/build/contracts/src/libraries/GasRefundEnabled.sol/GasRefundEnabled.dbg.json +1 -1
- package/build/contracts/src/libraries/IGasRefunder.sol/IGasRefunder.dbg.json +1 -1
- package/build/contracts/src/libraries/IReader4844.sol/IReader4844.dbg.json +1 -1
- package/build/contracts/src/libraries/MerkleLib.sol/MerkleLib.dbg.json +1 -1
- package/build/contracts/src/libraries/UUPSNotUpgradeable.sol/UUPSNotUpgradeable.dbg.json +1 -1
- package/build/contracts/src/mocks/BridgeStub.sol/BridgeStub.dbg.json +1 -1
- package/build/contracts/src/mocks/BridgeUnproxied.sol/BridgeUnproxied.dbg.json +1 -1
- package/build/contracts/src/mocks/InboxStub.sol/InboxStub.dbg.json +1 -1
- package/build/contracts/src/mocks/MerkleTreeAccess.sol/MerkleTreeAccess.dbg.json +1 -1
- package/build/contracts/src/mocks/MockRollupEventInbox.sol/MockRollupEventInbox.dbg.json +1 -1
- package/build/contracts/src/mocks/SequencerInboxBlobMock.sol/SequencerInboxBlobMock.dbg.json +1 -1
- package/build/contracts/src/mocks/SequencerInboxStub.sol/SequencerInboxStub.dbg.json +1 -1
- package/build/contracts/src/mocks/SimpleOneStepProofEntry.sol/SimpleOneStepProofEntry.dbg.json +1 -1
- package/build/contracts/src/mocks/TestWETH9.sol/IWETH9.dbg.json +1 -1
- package/build/contracts/src/mocks/TestWETH9.sol/TestWETH9.dbg.json +1 -1
- package/build/contracts/src/mocks/UpgradeExecutorMock.sol/UpgradeExecutorMock.dbg.json +1 -1
- package/build/contracts/src/node-interface/NodeInterface.sol/NodeInterface.dbg.json +1 -1
- package/build/contracts/src/node-interface/NodeInterfaceDebug.sol/NodeInterfaceDebug.dbg.json +1 -1
- package/build/contracts/src/osp/HashProofHelper.sol/HashProofHelper.dbg.json +1 -1
- package/build/contracts/src/osp/IOneStepProofEntry.sol/IOneStepProofEntry.dbg.json +1 -1
- package/build/contracts/src/osp/IOneStepProofEntry.sol/OneStepProofEntryLib.dbg.json +1 -1
- package/build/contracts/src/osp/IOneStepProver.sol/IOneStepProver.dbg.json +1 -1
- package/build/contracts/src/osp/OneStepProofEntry.sol/OneStepProofEntry.dbg.json +1 -1
- package/build/contracts/src/osp/OneStepProver0.sol/OneStepProver0.dbg.json +1 -1
- package/build/contracts/src/osp/OneStepProverHostIo.sol/OneStepProverHostIo.dbg.json +1 -1
- package/build/contracts/src/osp/OneStepProverMath.sol/OneStepProverMath.dbg.json +1 -1
- package/build/contracts/src/osp/OneStepProverMemory.sol/OneStepProverMemory.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbAddressTable.sol/ArbAddressTable.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbAggregator.sol/ArbAggregator.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbBLS.sol/ArbBLS.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbDebug.sol/ArbDebug.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbFunctionTable.sol/ArbFunctionTable.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbGasInfo.sol/ArbGasInfo.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbInfo.sol/ArbInfo.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbNativeTokenManager.sol/ArbNativeTokenManager.dbg.json +4 -0
- package/build/contracts/src/precompiles/ArbNativeTokenManager.sol/ArbNativeTokenManager.json +75 -0
- package/build/contracts/src/precompiles/ArbOwner.sol/ArbOwner.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbOwner.sol/ArbOwner.json +71 -0
- package/build/contracts/src/precompiles/ArbOwnerPublic.sol/ArbOwnerPublic.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbOwnerPublic.sol/ArbOwnerPublic.json +32 -0
- package/build/contracts/src/precompiles/ArbRetryableTx.sol/ArbRetryableTx.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbStatistics.sol/ArbStatistics.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbSys.sol/ArbSys.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbWasm.sol/ArbWasm.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbWasmCache.sol/ArbWasmCache.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbosActs.sol/ArbosActs.dbg.json +1 -1
- package/build/contracts/src/precompiles/ArbosTest.sol/ArbosTest.dbg.json +1 -1
- package/build/contracts/src/rollup/AbsRollupEventInbox.sol/AbsRollupEventInbox.dbg.json +1 -1
- package/build/contracts/src/rollup/Assertion.sol/AssertionNodeLib.dbg.json +1 -1
- package/build/contracts/src/rollup/AssertionState.sol/AssertionStateLib.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/BOLDUpgradeAction.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/ConstantArrayStorage.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/IOldRollup.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/IOldRollupAdmin.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/ISeqInboxPostUpgradeInit.dbg.json +1 -1
- package/build/contracts/src/rollup/BOLDUpgradeAction.sol/StateHashPreImageLookup.dbg.json +1 -1
- package/build/contracts/src/rollup/BridgeCreator.sol/BridgeCreator.dbg.json +1 -1
- package/build/contracts/src/rollup/DeployHelper.sol/DeployHelper.dbg.json +1 -1
- package/build/contracts/src/rollup/ERC20RollupEventInbox.sol/ERC20RollupEventInbox.dbg.json +1 -1
- package/build/contracts/src/rollup/FactoryDeployerHelper.sol/FactoryDeployerHelper.dbg.json +1 -1
- package/build/contracts/src/rollup/FactoryDeployerHelper.sol/IDeployHelper.dbg.json +1 -1
- package/build/contracts/src/rollup/FactoryDeployerHelper.sol/IERC20.dbg.json +1 -1
- package/build/contracts/src/rollup/FactoryDeployerHelper.sol/IERC20Bridge.dbg.json +1 -1
- package/build/contracts/src/rollup/FactoryDeployerHelper.sol/IInboxBase.dbg.json +1 -1
- package/build/contracts/src/rollup/IRollupAdmin.sol/IRollupAdmin.dbg.json +1 -1
- package/build/contracts/src/rollup/IRollupCore.sol/IRollupCore.dbg.json +1 -1
- package/build/contracts/src/rollup/IRollupEventInbox.sol/IRollupEventInbox.dbg.json +1 -1
- package/build/contracts/src/rollup/IRollupLogic.sol/IRollupUser.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupAdminLogic.sol/RollupAdminLogic.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupCore.sol/RollupCore.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupCreator.sol/RollupCreator.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupEventInbox.sol/RollupEventInbox.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupLib.sol/RollupLib.dbg.json +1 -1
- package/build/contracts/src/rollup/RollupProxy.sol/RollupProxy.dbg.json +1 -1
- package/build/contracts/src/rollup/ValidatorWallet.sol/ValidatorWallet.dbg.json +1 -1
- package/build/contracts/src/rollup/ValidatorWalletCreator.sol/ValidatorWalletCreator.dbg.json +1 -1
- package/build/contracts/src/state/Deserialize.sol/Deserialize.dbg.json +1 -1
- package/build/contracts/src/state/GlobalState.sol/GlobalStateLib.dbg.json +1 -1
- package/build/contracts/src/state/Instructions.sol/Instructions.dbg.json +1 -1
- package/build/contracts/src/state/Machine.sol/MachineLib.dbg.json +1 -1
- package/build/contracts/src/state/MerkleProof.sol/MerkleProofLib.dbg.json +1 -1
- package/build/contracts/src/state/Module.sol/ModuleLib.dbg.json +1 -1
- package/build/contracts/src/state/ModuleMemory.sol/ModuleMemoryLib.dbg.json +1 -1
- package/build/contracts/src/state/ModuleMemoryCompact.sol/ModuleMemoryCompactLib.dbg.json +1 -1
- package/build/contracts/src/state/MultiStack.sol/MultiStackLib.dbg.json +1 -1
- package/build/contracts/src/state/PcArray.sol/PcArrayLib.dbg.json +1 -1
- package/build/contracts/src/state/StackFrame.sol/StackFrameLib.dbg.json +1 -1
- package/build/contracts/src/state/Value.sol/ValueLib.dbg.json +1 -1
- package/build/contracts/src/state/ValueArray.sol/ValueArrayLib.dbg.json +1 -1
- package/build/contracts/src/state/ValueStack.sol/ValueStackLib.dbg.json +1 -1
- package/build/contracts/src/stylus/StylusDeployer.sol/StylusDeployer.dbg.json +1 -1
- package/build/contracts/src/stylus/StylusDeployer.sol/StylusDeployer.json +7 -2
- package/build/contracts/src/test-helpers/BridgeTester.sol/BridgeTester.dbg.json +1 -1
- package/build/contracts/src/test-helpers/CryptographyPrimitivesTester.sol/CryptographyPrimitivesTester.dbg.json +1 -1
- package/build/contracts/src/test-helpers/EthVault.sol/EthVault.dbg.json +1 -1
- package/build/contracts/src/test-helpers/MessageTester.sol/MessageTester.dbg.json +1 -1
- package/build/contracts/src/test-helpers/NoReceiveForwarder.sol/ConstructorError.dbg.json +1 -1
- package/build/contracts/src/test-helpers/NoReceiveForwarder.sol/ConstructorFine.dbg.json +1 -1
- package/build/contracts/src/test-helpers/NoReceiveForwarder.sol/NoReceiveForwarder.dbg.json +1 -1
- package/build/contracts/src/test-helpers/NoReceiveForwarder.sol/ReceivingForwarder.dbg.json +1 -1
- package/build/contracts/src/test-helpers/OutboxWithoutOptTester.sol/OutboxWithoutOptTester.dbg.json +1 -1
- package/build/contracts/src/test-helpers/RollupMock.sol/RollupMock.dbg.json +1 -1
- package/build/contracts/src/test-helpers/TestToken.sol/TestToken.dbg.json +1 -1
- package/build/contracts/src/test-helpers/ValueArrayTester.sol/ValueArrayTester.dbg.json +1 -1
- package/package.json +1 -1
- package/src/bridge/extra/ERC20MigrationOutbox.sol +44 -0
- package/src/bridge/extra/IERC20MigrationOutbox.sol +38 -0
- package/src/express-lane-auction/IExpressLaneAuction.sol +4 -0
- package/src/precompiles/ArbNativeTokenManager.sol +39 -0
- package/src/precompiles/ArbOwner.sol +28 -0
- package/src/precompiles/ArbOwnerPublic.sol +10 -0
- package/src/stylus/StylusDeployer.sol +4 -3
- package/build/contracts/src/mocks/ArbOS11To32UpgradeTest.sol/ArbOS11To32UpgradeTest.dbg.json +0 -4
- package/build/contracts/src/mocks/ArbOS11To32UpgradeTest.sol/ArbOS11To32UpgradeTest.json +0 -24
- package/build/contracts/src/mocks/Benchmarks.sol/Benchmarks.dbg.json +0 -4
- package/build/contracts/src/mocks/Benchmarks.sol/Benchmarks.json +0 -46
- package/build/contracts/src/mocks/BigMap.sol/BigMap.dbg.json +0 -4
- package/build/contracts/src/mocks/BigMap.sol/BigMap.json +0 -48
- package/build/contracts/src/mocks/CreateTest.sol/CreateTest.dbg.json +0 -4
- package/build/contracts/src/mocks/CreateTest.sol/CreateTest.json +0 -15
- package/build/contracts/src/mocks/HostioTest.sol/HostioTest.dbg.json +0 -4
- package/build/contracts/src/mocks/HostioTest.sol/HostioTest.json +0 -513
- package/build/contracts/src/mocks/MultiCallTest.sol/MultiCallTest.dbg.json +0 -4
- package/build/contracts/src/mocks/MultiCallTest.sol/MultiCallTest.json +0 -71
- package/build/contracts/src/mocks/PendingBlkTimeAndNrAdvanceCheck.sol/PendingBlkTimeAndNrAdvanceCheck.dbg.json +0 -4
- package/build/contracts/src/mocks/PendingBlkTimeAndNrAdvanceCheck.sol/PendingBlkTimeAndNrAdvanceCheck.json +0 -36
- package/build/contracts/src/mocks/Program.sol/ProgramTest.dbg.json +0 -4
- package/build/contracts/src/mocks/Program.sol/ProgramTest.json +0 -142
- package/build/contracts/src/mocks/ProxyAdminForBinding.sol/ProxyAdminForBinding.dbg.json +0 -4
- package/build/contracts/src/mocks/ProxyAdminForBinding.sol/ProxyAdminForBinding.json +0 -160
- package/build/contracts/src/mocks/SdkStorage.sol/SdkStorage.dbg.json +0 -4
- package/build/contracts/src/mocks/SdkStorage.sol/SdkStorage.json +0 -25
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructInConstructorWithDestination.dbg.json +0 -4
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructInConstructorWithDestination.json +0 -22
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructInConstructorWithoutDestination.dbg.json +0 -4
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructInConstructorWithoutDestination.json +0 -16
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructOutsideConstructor.dbg.json +0 -4
- package/build/contracts/src/mocks/SelfDestruct.sol/SelfDestructOutsideConstructor.json +0 -36
- package/build/contracts/src/mocks/Simple.sol/Simple.dbg.json +0 -4
- package/build/contracts/src/mocks/Simple.sol/Simple.json +0 -303
- package/build/contracts/src/mocks/SimpleCacheManager.sol/SimpleCacheManager.dbg.json +0 -4
- package/build/contracts/src/mocks/SimpleCacheManager.sol/SimpleCacheManager.json +0 -37
- package/build/contracts/src/mocks/SimpleProxy.sol/SimpleProxy.dbg.json +0 -4
- package/build/contracts/src/mocks/SimpleProxy.sol/SimpleProxy.json +0 -30
- package/src/mocks/ArbOS11To32UpgradeTest.sol +0 -18
- package/src/mocks/Benchmarks.sol +0 -52
- package/src/mocks/BigMap.sol +0 -23
- package/src/mocks/CreateTest.sol +0 -44
- package/src/mocks/HostioTest.sol +0 -200
- package/src/mocks/MultiCallTest.sol +0 -119
- package/src/mocks/PendingBlkTimeAndNrAdvanceCheck.sol +0 -31
- package/src/mocks/Program.sol +0 -128
- package/src/mocks/ProxyAdminForBinding.sol +0 -9
- package/src/mocks/SdkStorage.sol +0 -176
- package/src/mocks/SelfDestruct.sol +0 -33
- package/src/mocks/Simple.sol +0 -168
- package/src/mocks/SimpleCacheManager.sol +0 -29
- package/src/mocks/SimpleProxy.sol +0 -21
package/src/mocks/HostioTest.sol
DELETED
@@ -1,200 +0,0 @@
|
|
1
|
-
// Copyright 2024, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/nitro/blob/master/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.24;
|
6
|
-
|
7
|
-
/*
|
8
|
-
* HostioTest is a test contract used to compare EVM with Stylus.
|
9
|
-
*/
|
10
|
-
contract HostioTest {
|
11
|
-
function exitEarly() external pure {
|
12
|
-
assembly {
|
13
|
-
stop()
|
14
|
-
}
|
15
|
-
}
|
16
|
-
|
17
|
-
function transientLoadBytes32(
|
18
|
-
bytes32 key
|
19
|
-
) external view returns (bytes32) {
|
20
|
-
bytes32 data;
|
21
|
-
assembly {
|
22
|
-
data := tload(key)
|
23
|
-
}
|
24
|
-
return data;
|
25
|
-
}
|
26
|
-
|
27
|
-
function transientStoreBytes32(bytes32 key, bytes32 value) external {
|
28
|
-
assembly {
|
29
|
-
// solc-ignore-next-line transient-storage
|
30
|
-
tstore(key, value)
|
31
|
-
}
|
32
|
-
}
|
33
|
-
|
34
|
-
function returnDataSize() external pure returns (uint256) {
|
35
|
-
uint256 size;
|
36
|
-
assembly {
|
37
|
-
size := returndatasize()
|
38
|
-
}
|
39
|
-
return size;
|
40
|
-
}
|
41
|
-
|
42
|
-
function emitLog(
|
43
|
-
bytes calldata _data,
|
44
|
-
int8 n,
|
45
|
-
bytes32 t1,
|
46
|
-
bytes32 t2,
|
47
|
-
bytes32 t3,
|
48
|
-
bytes32 t4
|
49
|
-
) external {
|
50
|
-
bytes memory data = _data;
|
51
|
-
if (n == 0) {
|
52
|
-
assembly {
|
53
|
-
log0(add(data, 32), mload(data))
|
54
|
-
}
|
55
|
-
} else if (n == 1) {
|
56
|
-
assembly {
|
57
|
-
log1(add(data, 32), mload(data), t1)
|
58
|
-
}
|
59
|
-
} else if (n == 2) {
|
60
|
-
assembly {
|
61
|
-
log2(add(data, 32), mload(data), t1, t2)
|
62
|
-
}
|
63
|
-
} else if (n == 3) {
|
64
|
-
assembly {
|
65
|
-
log3(add(data, 32), mload(data), t1, t2, t3)
|
66
|
-
}
|
67
|
-
} else if (n == 4) {
|
68
|
-
assembly {
|
69
|
-
log4(add(data, 32), mload(data), t1, t2, t3, t4)
|
70
|
-
}
|
71
|
-
} else {
|
72
|
-
revert("invalid n for emit log");
|
73
|
-
}
|
74
|
-
}
|
75
|
-
|
76
|
-
function accountBalance(
|
77
|
-
address account
|
78
|
-
) external view returns (uint256) {
|
79
|
-
return account.balance;
|
80
|
-
}
|
81
|
-
|
82
|
-
function accountCode(
|
83
|
-
address account
|
84
|
-
) external view returns (bytes memory) {
|
85
|
-
uint256 size = 10000;
|
86
|
-
bytes memory code = new bytes(size);
|
87
|
-
assembly {
|
88
|
-
extcodecopy(account, add(code, 32), 0, size)
|
89
|
-
size := extcodesize(account)
|
90
|
-
mstore(code, size)
|
91
|
-
}
|
92
|
-
return code;
|
93
|
-
}
|
94
|
-
|
95
|
-
function accountCodeSize(
|
96
|
-
address account
|
97
|
-
) external view returns (uint256) {
|
98
|
-
uint256 size;
|
99
|
-
assembly {
|
100
|
-
size := extcodesize(account)
|
101
|
-
}
|
102
|
-
return size;
|
103
|
-
}
|
104
|
-
|
105
|
-
function accountCodehash(
|
106
|
-
address account
|
107
|
-
) external view returns (bytes32) {
|
108
|
-
bytes32 hash;
|
109
|
-
assembly {
|
110
|
-
hash := extcodehash(account)
|
111
|
-
}
|
112
|
-
return hash;
|
113
|
-
}
|
114
|
-
|
115
|
-
function evmGasLeft() external view returns (uint256) {
|
116
|
-
return gasleft();
|
117
|
-
}
|
118
|
-
|
119
|
-
function evmInkLeft() external view returns (uint256) {
|
120
|
-
return gasleft();
|
121
|
-
}
|
122
|
-
|
123
|
-
function blockBasefee() external view returns (uint256) {
|
124
|
-
return block.basefee;
|
125
|
-
}
|
126
|
-
|
127
|
-
function chainid() external view returns (uint256) {
|
128
|
-
return block.chainid;
|
129
|
-
}
|
130
|
-
|
131
|
-
function blockCoinbase() external view returns (address) {
|
132
|
-
return block.coinbase;
|
133
|
-
}
|
134
|
-
|
135
|
-
function blockGasLimit() external view returns (uint256) {
|
136
|
-
return block.gaslimit;
|
137
|
-
}
|
138
|
-
|
139
|
-
function blockNumber() external view returns (uint256) {
|
140
|
-
return block.number;
|
141
|
-
}
|
142
|
-
|
143
|
-
function blockTimestamp() external view returns (uint256) {
|
144
|
-
return block.timestamp;
|
145
|
-
}
|
146
|
-
|
147
|
-
function contractAddress() external view returns (address) {
|
148
|
-
return address(this);
|
149
|
-
}
|
150
|
-
|
151
|
-
function mathDiv(uint256 a, uint256 b) external pure returns (uint256) {
|
152
|
-
return a / b;
|
153
|
-
}
|
154
|
-
|
155
|
-
function mathMod(uint256 a, uint256 b) external pure returns (uint256) {
|
156
|
-
return a % b;
|
157
|
-
}
|
158
|
-
|
159
|
-
function mathPow(uint256 a, uint256 b) external pure returns (uint256) {
|
160
|
-
uint256 result;
|
161
|
-
assembly {
|
162
|
-
result := exp(a, b)
|
163
|
-
}
|
164
|
-
return result;
|
165
|
-
}
|
166
|
-
|
167
|
-
function mathAddMod(uint256 a, uint256 b, uint256 c) external pure returns (uint256) {
|
168
|
-
return addmod(a, b, c);
|
169
|
-
}
|
170
|
-
|
171
|
-
function mathMulMod(uint256 a, uint256 b, uint256 c) external pure returns (uint256) {
|
172
|
-
return mulmod(a, b, c);
|
173
|
-
}
|
174
|
-
|
175
|
-
function msgSender() external view returns (address) {
|
176
|
-
return msg.sender;
|
177
|
-
}
|
178
|
-
|
179
|
-
function msgValue() external payable returns (uint256) {
|
180
|
-
return msg.value;
|
181
|
-
}
|
182
|
-
|
183
|
-
function keccak(
|
184
|
-
bytes calldata preimage
|
185
|
-
) external pure returns (bytes32) {
|
186
|
-
return keccak256(preimage);
|
187
|
-
}
|
188
|
-
|
189
|
-
function txGasPrice() external view returns (uint256) {
|
190
|
-
return tx.gasprice;
|
191
|
-
}
|
192
|
-
|
193
|
-
function txInkPrice() external view returns (uint256) {
|
194
|
-
return tx.gasprice;
|
195
|
-
}
|
196
|
-
|
197
|
-
function txOrigin() external view returns (address) {
|
198
|
-
return tx.origin;
|
199
|
-
}
|
200
|
-
}
|
@@ -1,119 +0,0 @@
|
|
1
|
-
// Copyright 2024, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/nitro/blob/master/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
/*
|
8
|
-
* this contract is the solidity equivalent of stylus multicall test contract
|
9
|
-
* it should only be used for stylus tests, and it ignores good solidity good practices
|
10
|
-
*/
|
11
|
-
|
12
|
-
contract MultiCallTest {
|
13
|
-
event Called(address addr, uint8 count, bool success, bytes returnData);
|
14
|
-
event Storage(bytes32 slot, bytes32 data, bool write);
|
15
|
-
|
16
|
-
function getBE(bytes calldata data, uint8 numBytes) internal pure returns (uint256) {
|
17
|
-
uint256 res = 0;
|
18
|
-
for (uint8 i = 0; i < numBytes; i++) {
|
19
|
-
res = res << 8;
|
20
|
-
res = res | uint8(data[i]);
|
21
|
-
}
|
22
|
-
return res;
|
23
|
-
}
|
24
|
-
|
25
|
-
// solhint-disable no-complex-fallback
|
26
|
-
// solhint-disable reason-string
|
27
|
-
// solhint-disable avoid-low-level-calls
|
28
|
-
// solhint-disable-next-line prettier/prettier
|
29
|
-
fallback(
|
30
|
-
bytes calldata input
|
31
|
-
) external payable returns (bytes memory) {
|
32
|
-
require(input.length > 0);
|
33
|
-
uint8 count = uint8(input[0]);
|
34
|
-
input = input[1:];
|
35
|
-
|
36
|
-
// combined output of all calls
|
37
|
-
bytes memory output;
|
38
|
-
|
39
|
-
for (uint8 i = 0; i < count; i++) {
|
40
|
-
uint32 length = uint32(getBE(input, 4));
|
41
|
-
input = input[4:];
|
42
|
-
|
43
|
-
bytes calldata curr = input[:length];
|
44
|
-
input = input[length:];
|
45
|
-
|
46
|
-
uint8 kind = uint8(curr[0]);
|
47
|
-
curr = curr[1:];
|
48
|
-
|
49
|
-
if (kind & 0xf0 == 0x0) {
|
50
|
-
// call
|
51
|
-
uint256 value;
|
52
|
-
if (kind & 0x3 == 0) {
|
53
|
-
value = getBE(curr, 32);
|
54
|
-
curr = curr[32:];
|
55
|
-
}
|
56
|
-
|
57
|
-
address addr = address(bytes20(curr[:20]));
|
58
|
-
bytes calldata data = curr[20:];
|
59
|
-
bytes memory out;
|
60
|
-
bool success;
|
61
|
-
|
62
|
-
if (kind & 0x3 == 0) {
|
63
|
-
(success, out) = addr.call{value: value}(data);
|
64
|
-
} else if (kind & 0x3 == 1) {
|
65
|
-
(success, out) = addr.delegatecall(data);
|
66
|
-
} else if (kind & 0x3 == 2) {
|
67
|
-
(success, out) = addr.staticcall(data);
|
68
|
-
} else {
|
69
|
-
revert("unknown call kind");
|
70
|
-
}
|
71
|
-
if (!success) {
|
72
|
-
if (kind & 0x4 == 0) {
|
73
|
-
uint256 len = out.length;
|
74
|
-
if (len > 0) {
|
75
|
-
assembly {
|
76
|
-
revert(add(out, 32), len)
|
77
|
-
}
|
78
|
-
} else {
|
79
|
-
revert();
|
80
|
-
}
|
81
|
-
}
|
82
|
-
out = "";
|
83
|
-
}
|
84
|
-
if (kind & 0x8 != 0) {
|
85
|
-
emit Called(addr, count, success, out);
|
86
|
-
}
|
87
|
-
output = bytes.concat(output, out);
|
88
|
-
} else if (kind & 0xf0 == 0x10) {
|
89
|
-
// storage
|
90
|
-
bytes32 slot = bytes32(curr[:32]);
|
91
|
-
curr = curr[32:];
|
92
|
-
bytes32 data;
|
93
|
-
bool write;
|
94
|
-
if (kind & 0x3 == 0) {
|
95
|
-
data = bytes32(curr[:32]);
|
96
|
-
write = true;
|
97
|
-
assembly {
|
98
|
-
sstore(slot, data)
|
99
|
-
}
|
100
|
-
} else if (kind & 0x3 == 1) {
|
101
|
-
write = false;
|
102
|
-
assembly {
|
103
|
-
data := sload(slot)
|
104
|
-
}
|
105
|
-
output = bytes.concat(output, data);
|
106
|
-
} else {
|
107
|
-
revert("unknown storage kind");
|
108
|
-
}
|
109
|
-
if (kind & 0x8 != 0) {
|
110
|
-
emit Storage(slot, data, write);
|
111
|
-
}
|
112
|
-
} else {
|
113
|
-
revert("unknown command");
|
114
|
-
}
|
115
|
-
}
|
116
|
-
|
117
|
-
return output;
|
118
|
-
}
|
119
|
-
}
|
@@ -1,31 +0,0 @@
|
|
1
|
-
// Copyright 2021-2022, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/OffchainLabs/nitro-contracts/blob/main/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
import "../precompiles/ArbSys.sol";
|
8
|
-
|
9
|
-
contract PendingBlkTimeAndNrAdvanceCheck {
|
10
|
-
uint256 immutable deployedAt;
|
11
|
-
uint256 immutable deployedAtBlock;
|
12
|
-
ArbSys constant ARB_SYS = ArbSys(address(100));
|
13
|
-
|
14
|
-
constructor() {
|
15
|
-
deployedAt = block.timestamp;
|
16
|
-
deployedAtBlock = ARB_SYS.arbBlockNumber();
|
17
|
-
}
|
18
|
-
|
19
|
-
function isAdvancing() external {
|
20
|
-
require(block.timestamp > deployedAt, "Time didn't advance");
|
21
|
-
require(ARB_SYS.arbBlockNumber() > deployedAtBlock, "Block didn't advance");
|
22
|
-
}
|
23
|
-
|
24
|
-
function checkArbBlockHashReturnsLatest(
|
25
|
-
bytes32 expected
|
26
|
-
) external {
|
27
|
-
bytes32 gotBlockHash = ARB_SYS.arbBlockHash(ARB_SYS.arbBlockNumber() - 1);
|
28
|
-
require(gotBlockHash != bytes32(0), "ZERO_BLOCK_HASH");
|
29
|
-
require(gotBlockHash == expected, "WRONG_BLOCK_HASH");
|
30
|
-
}
|
31
|
-
}
|
package/src/mocks/Program.sol
DELETED
@@ -1,128 +0,0 @@
|
|
1
|
-
// Copyright 2022-2023, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/nitro/blob/master/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
import "../precompiles/ArbSys.sol";
|
8
|
-
import "@openzeppelin/contracts/utils/Strings.sol";
|
9
|
-
|
10
|
-
contract ProgramTest {
|
11
|
-
event Hash(bytes32 result);
|
12
|
-
|
13
|
-
function callKeccak(address program, bytes calldata data) external {
|
14
|
-
// in keccak.rs
|
15
|
-
// the input is the # of hashings followed by a preimage
|
16
|
-
// the output is the iterated hash of the preimage
|
17
|
-
(bool success, bytes memory result) = address(program).call(data);
|
18
|
-
require(success, "call failed");
|
19
|
-
bytes32 hash = bytes32(result);
|
20
|
-
emit Hash(hash);
|
21
|
-
require(hash == keccak256(data[1:]));
|
22
|
-
}
|
23
|
-
|
24
|
-
function staticcallProgram(
|
25
|
-
address program,
|
26
|
-
bytes calldata data
|
27
|
-
) external view returns (bytes memory) {
|
28
|
-
(bool success, bytes memory result) = address(program).staticcall(data);
|
29
|
-
require(success, "call failed");
|
30
|
-
return result;
|
31
|
-
}
|
32
|
-
|
33
|
-
function assert256(
|
34
|
-
bytes memory data,
|
35
|
-
string memory text,
|
36
|
-
uint256 expected
|
37
|
-
) internal pure returns (bytes memory) {
|
38
|
-
uint256 value = abi.decode(data, (uint256));
|
39
|
-
require(value == expected, text);
|
40
|
-
|
41
|
-
bytes memory rest = new bytes(data.length - 32);
|
42
|
-
for (uint256 i = 32; i < data.length; i++) {
|
43
|
-
rest[i - 32] = data[i];
|
44
|
-
}
|
45
|
-
return rest;
|
46
|
-
}
|
47
|
-
|
48
|
-
function staticcallEvmData(
|
49
|
-
address program,
|
50
|
-
address fundedAccount,
|
51
|
-
uint64 gas,
|
52
|
-
bytes calldata data
|
53
|
-
) external view returns (bytes memory) {
|
54
|
-
(bool success, bytes memory result) = address(program).staticcall{gas: gas}(data);
|
55
|
-
require(success, "call failed");
|
56
|
-
|
57
|
-
address arbPrecompile = address(0x69);
|
58
|
-
address ethPrecompile = address(0x01);
|
59
|
-
|
60
|
-
result = assert256(result, "block number ", block.number - 1);
|
61
|
-
result = assert256(result, "chain id ", block.chainid);
|
62
|
-
result = assert256(result, "base fee ", block.basefee);
|
63
|
-
result = assert256(result, "gas price ", tx.gasprice);
|
64
|
-
result = assert256(result, "gas limit ", block.gaslimit);
|
65
|
-
result = assert256(result, "value ", 0);
|
66
|
-
result = assert256(result, "timestamp ", block.timestamp);
|
67
|
-
result = assert256(result, "balance ", fundedAccount.balance);
|
68
|
-
result = assert256(result, "rust address ", uint256(uint160(program)));
|
69
|
-
result = assert256(result, "sender ", uint256(uint160(address(this))));
|
70
|
-
result = assert256(result, "origin ", uint256(uint160(tx.origin)));
|
71
|
-
result = assert256(result, "coinbase ", uint256(uint160(address(block.coinbase))));
|
72
|
-
result = assert256(result, "rust codehash", uint256(program.codehash));
|
73
|
-
result = assert256(result, "arb codehash ", uint256(arbPrecompile.codehash));
|
74
|
-
result = assert256(result, "eth codehash ", uint256(ethPrecompile.codehash));
|
75
|
-
|
76
|
-
bytes memory code = new bytes(program.code.length);
|
77
|
-
for (uint256 i = 0; i < program.code.length; i++) {
|
78
|
-
code[i] = result[i];
|
79
|
-
}
|
80
|
-
require(keccak256(code) == keccak256(program.code), "code");
|
81
|
-
bytes memory rest = new bytes(result.length - program.code.length);
|
82
|
-
for (uint256 i = program.code.length; i < result.length; i++) {
|
83
|
-
rest[i - program.code.length] = result[i];
|
84
|
-
}
|
85
|
-
|
86
|
-
result = rest;
|
87
|
-
return result;
|
88
|
-
}
|
89
|
-
|
90
|
-
function checkRevertData(
|
91
|
-
address program,
|
92
|
-
bytes calldata data,
|
93
|
-
bytes calldata expected
|
94
|
-
) external payable returns (bytes memory) {
|
95
|
-
(bool success, bytes memory result) = address(program).call{value: msg.value}(data);
|
96
|
-
require(!success, "unexpected success");
|
97
|
-
require(result.length == expected.length, "wrong revert data length");
|
98
|
-
for (uint256 i = 0; i < result.length; i++) {
|
99
|
-
require(result[i] == expected[i], "revert data mismatch");
|
100
|
-
}
|
101
|
-
return result;
|
102
|
-
}
|
103
|
-
|
104
|
-
function mathTest(
|
105
|
-
address program
|
106
|
-
) external {
|
107
|
-
uint256 value = 0xeddecf107b5740cef7f5a01e3ea7e287665c4e75a8eb6afae2fda2e3d4367786;
|
108
|
-
value = mulmod(
|
109
|
-
value,
|
110
|
-
0xc6178c2de1078cd36c3bd302cde755340d7f17fcb3fcc0b9c333ba03b217029f,
|
111
|
-
0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
112
|
-
);
|
113
|
-
value = addmod(
|
114
|
-
value,
|
115
|
-
0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f,
|
116
|
-
0xc6178c2de1078cd36c3bd302cde755340d7f17fcb3fcc0b9c333ba03b217029f
|
117
|
-
);
|
118
|
-
unchecked {
|
119
|
-
value /= 0xeddecf107b5740ce;
|
120
|
-
value = value ** 0xfffffffefffffc2f;
|
121
|
-
value = value % 0xc6178c2de1078cd3;
|
122
|
-
}
|
123
|
-
|
124
|
-
(bool success, bytes memory result) = address(program).call("");
|
125
|
-
require(success, "call failed");
|
126
|
-
require(keccak256(result) == keccak256(abi.encodePacked(value)));
|
127
|
-
}
|
128
|
-
}
|
@@ -1,9 +0,0 @@
|
|
1
|
-
// Copyright 2021-2022, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/OffchainLabs/nitro-contracts/blob/main/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
import "@openzeppelin/contracts/proxy/transparent/ProxyAdmin.sol";
|
8
|
-
|
9
|
-
contract ProxyAdminForBinding is ProxyAdmin {}
|
package/src/mocks/SdkStorage.sol
DELETED
@@ -1,176 +0,0 @@
|
|
1
|
-
// Copyright 2022-2023, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/nitro/blob/master/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
contract SdkStorage {
|
8
|
-
bool flag;
|
9
|
-
address owner;
|
10
|
-
address other;
|
11
|
-
Struct sub;
|
12
|
-
Struct[] structs;
|
13
|
-
uint64[] vector;
|
14
|
-
uint40[][] nested;
|
15
|
-
bytes bytesFull;
|
16
|
-
bytes bytesLong;
|
17
|
-
string chars;
|
18
|
-
Maps maps;
|
19
|
-
Arrays arrays;
|
20
|
-
|
21
|
-
struct Struct {
|
22
|
-
uint16 num;
|
23
|
-
int32 other;
|
24
|
-
bytes32 word;
|
25
|
-
}
|
26
|
-
|
27
|
-
struct Maps {
|
28
|
-
mapping(uint256 => address) basic;
|
29
|
-
mapping(address => bool[]) vects;
|
30
|
-
mapping(int32 => address)[] array;
|
31
|
-
mapping(bytes1 => mapping(bool => uint256)) nested;
|
32
|
-
mapping(string => Struct) structs;
|
33
|
-
}
|
34
|
-
|
35
|
-
struct Arrays {
|
36
|
-
string[4] strings;
|
37
|
-
uint8 spacer;
|
38
|
-
uint24[5] packed;
|
39
|
-
uint8 trail;
|
40
|
-
address[2] spill;
|
41
|
-
uint8[2][4] matrix;
|
42
|
-
int96[4][] vector;
|
43
|
-
int96[][4] vectors;
|
44
|
-
Struct[3] structs;
|
45
|
-
}
|
46
|
-
|
47
|
-
function populate() external {
|
48
|
-
flag = true;
|
49
|
-
owner = address(0x70);
|
50
|
-
other = address(0x30);
|
51
|
-
|
52
|
-
sub.num = 32;
|
53
|
-
sub.other = type(int32).max;
|
54
|
-
sub.word = bytes32(uint256(64));
|
55
|
-
|
56
|
-
for (uint64 i = 0; i < 32; i++) {
|
57
|
-
vector.push(i);
|
58
|
-
}
|
59
|
-
vector[7] = 77;
|
60
|
-
|
61
|
-
for (uint256 w = 0; w < 10; w++) {
|
62
|
-
nested.push(new uint40[](w));
|
63
|
-
for (uint256 i = 0; i < w; i++) {
|
64
|
-
nested[w][i] = uint40(i);
|
65
|
-
}
|
66
|
-
}
|
67
|
-
for (uint256 w = 0; w < 10; w++) {
|
68
|
-
for (uint256 i = 0; i < w; i++) {
|
69
|
-
nested[w][i] *= 2;
|
70
|
-
}
|
71
|
-
}
|
72
|
-
|
73
|
-
for (uint8 i = 0; i < 31; i++) {
|
74
|
-
bytesFull = abi.encodePacked(bytesFull, i);
|
75
|
-
}
|
76
|
-
for (uint8 i = 0; i < 80; i++) {
|
77
|
-
bytesLong = abi.encodePacked(bytesLong, i);
|
78
|
-
}
|
79
|
-
chars = "arbitrum stylus";
|
80
|
-
|
81
|
-
for (uint256 i = 0; i < 16; i++) {
|
82
|
-
maps.basic[i] = address(uint160(i));
|
83
|
-
}
|
84
|
-
|
85
|
-
for (uint160 a = 0; a < 4; a++) {
|
86
|
-
maps.vects[address(a)] = new bool[](0);
|
87
|
-
for (uint256 i = 0; i <= a; i++) {
|
88
|
-
maps.vects[address(a)].push(true);
|
89
|
-
}
|
90
|
-
}
|
91
|
-
|
92
|
-
for (int32 i = 0; i < 4; i++) {
|
93
|
-
maps.array.push();
|
94
|
-
maps.array[uint256(uint32(i))][i] = address(uint160(uint32(i)));
|
95
|
-
}
|
96
|
-
|
97
|
-
for (uint8 i = 0; i < 4; i++) {
|
98
|
-
maps.nested[bytes1(i)][i % 2 == 0] = i + 1;
|
99
|
-
}
|
100
|
-
|
101
|
-
maps.structs["stylus"] = sub;
|
102
|
-
|
103
|
-
for (uint256 i = 0; i < 4; i++) {
|
104
|
-
structs.push(sub);
|
105
|
-
}
|
106
|
-
|
107
|
-
arrays.strings[2] = "L2 is for you!";
|
108
|
-
|
109
|
-
for (uint256 i = 0; i < 5; i++) {
|
110
|
-
arrays.packed[i] = uint24(i);
|
111
|
-
}
|
112
|
-
|
113
|
-
for (uint256 i = 0; i < 2; i++) {
|
114
|
-
arrays.spill[i] = address(uint160(i));
|
115
|
-
}
|
116
|
-
|
117
|
-
for (uint256 i = 0; i < 4; i++) {
|
118
|
-
arrays.matrix[i][0] = uint8(i);
|
119
|
-
arrays.matrix[i][1] = arrays.matrix[i][0] + 1;
|
120
|
-
}
|
121
|
-
|
122
|
-
for (uint256 w = 0; w < 3; w++) {
|
123
|
-
int96[4] memory array;
|
124
|
-
for (int256 i = 0; i < 4; i++) {
|
125
|
-
array[uint256(i)] = int96(i);
|
126
|
-
}
|
127
|
-
arrays.vector.push(array);
|
128
|
-
}
|
129
|
-
|
130
|
-
for (uint256 w = 0; w < 4; w++) {
|
131
|
-
for (int96 i = 0; i < 4; i++) {
|
132
|
-
arrays.vectors[w].push(i);
|
133
|
-
}
|
134
|
-
}
|
135
|
-
|
136
|
-
for (uint256 i = 0; i < 3; i++) {
|
137
|
-
arrays.structs[i] = sub;
|
138
|
-
}
|
139
|
-
}
|
140
|
-
|
141
|
-
function remove() external {
|
142
|
-
while (bytesFull.length != 0) {
|
143
|
-
bytesFull.pop();
|
144
|
-
}
|
145
|
-
|
146
|
-
while (bytesLong.length > 16) {
|
147
|
-
bytesLong.pop();
|
148
|
-
}
|
149
|
-
|
150
|
-
chars = "wasm is cute <3";
|
151
|
-
|
152
|
-
while (vector.length != 0) {
|
153
|
-
vector.pop();
|
154
|
-
}
|
155
|
-
|
156
|
-
while (nested.length > 1) {
|
157
|
-
nested.pop();
|
158
|
-
}
|
159
|
-
|
160
|
-
for (uint256 i = 0; i < 8; i++) {
|
161
|
-
delete maps.basic[i];
|
162
|
-
}
|
163
|
-
maps.basic[8] = address(32);
|
164
|
-
|
165
|
-
for (uint160 i = 0; i < 4; i++) {
|
166
|
-
delete maps.vects[address(i)];
|
167
|
-
}
|
168
|
-
|
169
|
-
structs.pop();
|
170
|
-
|
171
|
-
delete arrays.matrix;
|
172
|
-
delete arrays.vector;
|
173
|
-
delete arrays.vectors;
|
174
|
-
delete arrays.structs;
|
175
|
-
}
|
176
|
-
}
|
@@ -1,33 +0,0 @@
|
|
1
|
-
// Copyright 2024, Offchain Labs, Inc.
|
2
|
-
// For license information, see https://github.com/OffchainLabs/nitro-contracts/blob/main/LICENSE
|
3
|
-
// SPDX-License-Identifier: BUSL-1.1
|
4
|
-
|
5
|
-
pragma solidity ^0.8.0;
|
6
|
-
|
7
|
-
contract SelfDestructInConstructorWithoutDestination {
|
8
|
-
constructor() public payable {
|
9
|
-
selfdestruct(payable(address(this)));
|
10
|
-
}
|
11
|
-
}
|
12
|
-
|
13
|
-
contract SelfDestructInConstructorWithDestination {
|
14
|
-
constructor(
|
15
|
-
address payable destination
|
16
|
-
) public payable {
|
17
|
-
selfdestruct(destination);
|
18
|
-
}
|
19
|
-
}
|
20
|
-
|
21
|
-
contract SelfDestructOutsideConstructor {
|
22
|
-
constructor() public payable {}
|
23
|
-
|
24
|
-
function selfDestructWithDestination(
|
25
|
-
address payable destination
|
26
|
-
) public {
|
27
|
-
selfdestruct(destination);
|
28
|
-
}
|
29
|
-
|
30
|
-
function selfDestructWithoutDestination() public {
|
31
|
-
selfdestruct(payable(address(this)));
|
32
|
-
}
|
33
|
-
}
|