Feature Tip: Add private address tag to any address under My Name Tag !
More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 28 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Transfer | 16797043 | 709 days ago | IN | 0.4 ETH | 0.00065202 | ||||
Transfer | 16720109 | 720 days ago | IN | 0.6 ETH | 0.00045736 | ||||
Transfer | 16582692 | 740 days ago | IN | 1 ETH | 0.00050398 | ||||
Transfer | 16426718 | 761 days ago | IN | 0.6 ETH | 0.0004577 | ||||
Transfer Ownersh... | 16339925 | 773 days ago | IN | 0 ETH | 0.00044796 | ||||
Transfer | 16336687 | 774 days ago | IN | 0.3 ETH | 0.00048933 | ||||
Transfer | 16255846 | 785 days ago | IN | 0.4 ETH | 0.00036602 | ||||
Transfer | 16069885 | 811 days ago | IN | 0.5 ETH | 0.00051745 | ||||
Transfer | 15968076 | 825 days ago | IN | 0.65 ETH | 0.00031607 | ||||
Transfer | 15927387 | 831 days ago | IN | 1 ETH | 0.00323618 | ||||
Transfer | 15846374 | 842 days ago | IN | 0.8 ETH | 0.00018931 | ||||
Transfer | 15681088 | 865 days ago | IN | 1 ETH | 0.00012329 | ||||
Transfer | 15537914 | 886 days ago | IN | 1 ETH | 0.00067603 | ||||
Set Reimburse Co... | 13717636 | 1174 days ago | IN | 0 ETH | 0.00381896 | ||||
Set Reimburse Co... | 13680923 | 1180 days ago | IN | 0 ETH | 0.00232583 | ||||
Set Reimburse Co... | 13657172 | 1183 days ago | IN | 0 ETH | 0.00261297 | ||||
Transfer | 13184553 | 1257 days ago | IN | 2 ETH | 0.00187372 | ||||
Transfer | 13164597 | 1261 days ago | IN | 2 ETH | 0.00214236 | ||||
Transfer | 13146863 | 1263 days ago | IN | 0.3 ETH | 0.0024099 | ||||
Transfer | 13018482 | 1283 days ago | IN | 2 ETH | 0.00127156 | ||||
Transfer | 13018100 | 1283 days ago | IN | 0.3 ETH | 0.00132646 | ||||
Transfer | 12989738 | 1288 days ago | IN | 0.5 ETH | 0.00088431 | ||||
Transfer | 12474150 | 1368 days ago | IN | 3.97904139 ETH | 0.00193706 | ||||
Transfer | 12459818 | 1370 days ago | IN | 0.5 ETH | 0.00218972 | ||||
Transfer | 12425826 | 1375 days ago | IN | 0.6 ETH | 0.00345302 |
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
21204471 | 92 days ago | 0.00539891 ETH | ||||
20678856 | 165 days ago | 0.00267344 ETH | ||||
20678782 | 165 days ago | 0.00387976 ETH | ||||
20665493 | 167 days ago | 0.00523988 ETH | ||||
20665472 | 167 days ago | 0.00461553 ETH | ||||
20665452 | 167 days ago | 0.00437413 ETH | ||||
20665439 | 167 days ago | 0.00493574 ETH | ||||
20665415 | 167 days ago | 0.00564684 ETH | ||||
20665402 | 167 days ago | 0.00426353 ETH | ||||
20665378 | 167 days ago | 0.00407329 ETH | ||||
20665333 | 167 days ago | 0.0051379 ETH | ||||
20665322 | 167 days ago | 0.00496258 ETH | ||||
20665309 | 167 days ago | 0.00391103 ETH | ||||
20665277 | 167 days ago | 0.00285068 ETH | ||||
20664226 | 167 days ago | 0.00819017 ETH | ||||
20664191 | 167 days ago | 0.00736289 ETH | ||||
20663160 | 167 days ago | 0.00221648 ETH | ||||
20663147 | 167 days ago | 0.0021887 ETH | ||||
20635141 | 171 days ago | 0.00270867 ETH | ||||
20635127 | 171 days ago | 0.0028346 ETH | ||||
20635094 | 171 days ago | 0.00285032 ETH | ||||
20635080 | 171 days ago | 0.00298544 ETH | ||||
20635042 | 171 days ago | 0.00345232 ETH | ||||
20634990 | 171 days ago | 0.00273567 ETH | ||||
20634976 | 171 days ago | 0.00314499 ETH |
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
AztecFeeDistributor
Compiler Version
v0.6.10+commit.00c0fcaf
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-2.0-only // Copyright 2020 Spilsbury Holdings Ltd pragma solidity >=0.6.10 <0.8.0; import {IERC20} from '@openzeppelin/contracts/token/ERC20/IERC20.sol'; import {Ownable} from '@openzeppelin/contracts/access/Ownable.sol'; import {SafeMath} from '@openzeppelin/contracts/math/SafeMath.sol'; import {IUniswapV2Router02} from '@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol'; import {IUniswapV2Pair} from '@uniswap/v2-core/contracts/interfaces/IUniswapV2Pair.sol'; import {IWETH} from '@uniswap/v2-periphery/contracts/interfaces/IWETH.sol'; import {UniswapV2Library} from '@uniswap/v2-periphery/contracts/libraries/UniswapV2Library.sol'; import {IFeeDistributor} from './interfaces/IFeeDistributor.sol'; import {IRollupProcessor} from './interfaces/IRollupProcessor.sol'; contract AztecFeeDistributor is IFeeDistributor, Ownable { using SafeMath for uint256; uint256 constant ethAssetId = 0; uint256 public override reimburseConstant = 16 * 14465; uint256 public override convertConstant = 157768 * 20; // gas for calling convert() / 5% address public immutable override rollupProcessor; address public immutable override router; address public immutable override factory; address public immutable override WETH; constructor(address _rollupProcessor, address _router) public { rollupProcessor = _rollupProcessor; router = _router; factory = IUniswapV2Router02(_router).factory(); WETH = IUniswapV2Router02(_router).WETH(); } receive() external payable {} function setReimburseConstant(uint256 _reimburseConstant) external override onlyOwner { reimburseConstant = _reimburseConstant; } function setConvertConstant(uint256 _convertConstant) external override onlyOwner { convertConstant = _convertConstant; } function txFeeBalance(uint256 assetId) public override view returns (uint256) { if (assetId == ethAssetId) { return address(this).balance; } else { address assetAddress = IRollupProcessor(rollupProcessor).getSupportedAsset(assetId); return IERC20(assetAddress).balanceOf(address(this)); } } function deposit(uint256 assetId, uint256 amount) external override payable returns (uint256 depositedAmount) { if (assetId == ethAssetId) { require(amount == msg.value, 'Fee Distributor: WRONG_AMOUNT'); } else { require(msg.value == 0, 'Fee Distributor: WRONG_PAYMENT_TYPE'); address assetAddress = IRollupProcessor(rollupProcessor).getSupportedAsset(assetId); IERC20(assetAddress).transferFrom(msg.sender, address(this), amount); uint256 balance = IERC20(assetAddress).balanceOf(address(this)); uint256 outputValue = getAmountOut(assetAddress, balance); if (outputValue >= convertConstant.mul(tx.gasprice)) { swapTokensForETH(assetAddress, balance, outputValue); emit Convert(assetId, balance, outputValue); } } depositedAmount = amount; } function reimburseGas( uint256 gasUsed, uint256 feeLimit, address payable feeReceiver ) external override returns (uint256 reimbursement) { require(msg.sender == rollupProcessor, 'Fee Distributor: INVALID_CALLER'); reimbursement = gasUsed.add(reimburseConstant).mul(tx.gasprice); require(reimbursement <= feeLimit, 'Fee Distributor: FEE_LIMIT_EXCEEDED'); (bool success, ) = feeReceiver.call{value: reimbursement}(''); require(success, 'Fee Distributor: REIMBURSE_GAS_FAILED'); emit FeeReimbursed(feeReceiver, reimbursement); } function convert(uint256 assetId, uint256 minOutputValue) public override onlyOwner returns (uint256 outputValue) { require(assetId != ethAssetId, 'Fee Distributor: NOT_A_TOKEN_ASSET'); address assetAddress = IRollupProcessor(rollupProcessor).getSupportedAsset(assetId); uint256 inputValue = IERC20(assetAddress).balanceOf(address(this)); require(inputValue > 0, 'Fee Distributor: EMPTY_BALANCE'); outputValue = getAmountOut(assetAddress, inputValue); require(outputValue >= minOutputValue, 'Fee Distributor: INSUFFICIENT_OUTPUT_AMOUNT'); swapTokensForETH(assetAddress, inputValue, outputValue); emit Convert(assetId, inputValue, outputValue); } function getAmountOut(address assetAddress, uint256 inputValue) internal view returns (uint256 outputValue) { (uint256 reserveIn, uint256 reserveOut) = UniswapV2Library.getReserves(factory, assetAddress, WETH); outputValue = UniswapV2Library.getAmountOut(inputValue, reserveIn, reserveOut); } function swapTokensForETH( address assetAddress, uint256 inputValue, uint256 outputValue ) internal { address pair = UniswapV2Library.pairFor(factory, assetAddress, WETH); (bool success, ) = assetAddress.call(abi.encodeWithSelector(0xa9059cbb, pair, inputValue)); require(success, 'Fee Distributor: TRANSFER_FAILED'); (uint256 amountOut0, uint256 amountOut1) = assetAddress < WETH ? (uint256(0), outputValue) : (outputValue, uint256(0)); IUniswapV2Pair(pair).swap(amountOut0, amountOut1, address(this), new bytes(0)); IWETH(WETH).withdraw(outputValue); } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { address msgSender = _msgSender(); _owner = msgSender; emit OwnershipTransferred(address(0), msgSender); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { emit OwnershipTransferred(_owner, address(0)); _owner = address(0); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); emit OwnershipTransferred(_owner, newOwner); _owner = newOwner; } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b > a) return (false, 0); return (true, a - b); } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b == 0) return (false, 0); return (true, a / b); } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { if (b == 0) return (false, 0); return (true, a % b); } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { require(b <= a, "SafeMath: subtraction overflow"); return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { if (a == 0) return 0; uint256 c = a * b; require(c / a == b, "SafeMath: multiplication overflow"); return c; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { require(b > 0, "SafeMath: division by zero"); return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { require(b > 0, "SafeMath: modulo by zero"); return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b <= a, errorMessage); return a - b; } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryDiv}. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b > 0, errorMessage); return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b > 0, errorMessage); return a % b; } }
pragma solidity >=0.6.2; import './IUniswapV2Router01.sol'; interface IUniswapV2Router02 is IUniswapV2Router01 { function removeLiquidityETHSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountETH); function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountETH); function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactETHForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; }
pragma solidity >=0.5.0; interface IUniswapV2Pair { event Approval(address indexed owner, address indexed spender, uint value); event Transfer(address indexed from, address indexed to, uint value); function name() external pure returns (string memory); function symbol() external pure returns (string memory); function decimals() external pure returns (uint8); function totalSupply() external view returns (uint); function balanceOf(address owner) external view returns (uint); function allowance(address owner, address spender) external view returns (uint); function approve(address spender, uint value) external returns (bool); function transfer(address to, uint value) external returns (bool); function transferFrom(address from, address to, uint value) external returns (bool); function DOMAIN_SEPARATOR() external view returns (bytes32); function PERMIT_TYPEHASH() external pure returns (bytes32); function nonces(address owner) external view returns (uint); function permit(address owner, address spender, uint value, uint deadline, uint8 v, bytes32 r, bytes32 s) external; event Mint(address indexed sender, uint amount0, uint amount1); event Burn(address indexed sender, uint amount0, uint amount1, address indexed to); event Swap( address indexed sender, uint amount0In, uint amount1In, uint amount0Out, uint amount1Out, address indexed to ); event Sync(uint112 reserve0, uint112 reserve1); function MINIMUM_LIQUIDITY() external pure returns (uint); function factory() external view returns (address); function token0() external view returns (address); function token1() external view returns (address); function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast); function price0CumulativeLast() external view returns (uint); function price1CumulativeLast() external view returns (uint); function kLast() external view returns (uint); function mint(address to) external returns (uint liquidity); function burn(address to) external returns (uint amount0, uint amount1); function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external; function skim(address to) external; function sync() external; function initialize(address, address) external; }
pragma solidity >=0.5.0; interface IWETH { function deposit() external payable; function transfer(address to, uint value) external returns (bool); function withdraw(uint) external; }
pragma solidity >=0.5.0; import '@uniswap/v2-core/contracts/interfaces/IUniswapV2Pair.sol'; import "./SafeMath.sol"; library UniswapV2Library { using SafeMath for uint; // returns sorted token addresses, used to handle return values from pairs sorted in this order function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) { require(tokenA != tokenB, 'UniswapV2Library: IDENTICAL_ADDRESSES'); (token0, token1) = tokenA < tokenB ? (tokenA, tokenB) : (tokenB, tokenA); require(token0 != address(0), 'UniswapV2Library: ZERO_ADDRESS'); } // calculates the CREATE2 address for a pair without making any external calls function pairFor(address factory, address tokenA, address tokenB) internal pure returns (address pair) { (address token0, address token1) = sortTokens(tokenA, tokenB); pair = address(uint(keccak256(abi.encodePacked( hex'ff', factory, keccak256(abi.encodePacked(token0, token1)), hex'96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f' // init code hash )))); } // fetches and sorts the reserves for a pair function getReserves(address factory, address tokenA, address tokenB) internal view returns (uint reserveA, uint reserveB) { (address token0,) = sortTokens(tokenA, tokenB); (uint reserve0, uint reserve1,) = IUniswapV2Pair(pairFor(factory, tokenA, tokenB)).getReserves(); (reserveA, reserveB) = tokenA == token0 ? (reserve0, reserve1) : (reserve1, reserve0); } // given some amount of an asset and pair reserves, returns an equivalent amount of the other asset function quote(uint amountA, uint reserveA, uint reserveB) internal pure returns (uint amountB) { require(amountA > 0, 'UniswapV2Library: INSUFFICIENT_AMOUNT'); require(reserveA > 0 && reserveB > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY'); amountB = amountA.mul(reserveB) / reserveA; } // given an input amount of an asset and pair reserves, returns the maximum output amount of the other asset function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) internal pure returns (uint amountOut) { require(amountIn > 0, 'UniswapV2Library: INSUFFICIENT_INPUT_AMOUNT'); require(reserveIn > 0 && reserveOut > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY'); uint amountInWithFee = amountIn.mul(997); uint numerator = amountInWithFee.mul(reserveOut); uint denominator = reserveIn.mul(1000).add(amountInWithFee); amountOut = numerator / denominator; } // given an output amount of an asset and pair reserves, returns a required input amount of the other asset function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) internal pure returns (uint amountIn) { require(amountOut > 0, 'UniswapV2Library: INSUFFICIENT_OUTPUT_AMOUNT'); require(reserveIn > 0 && reserveOut > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY'); uint numerator = reserveIn.mul(amountOut).mul(1000); uint denominator = reserveOut.sub(amountOut).mul(997); amountIn = (numerator / denominator).add(1); } // performs chained getAmountOut calculations on any number of pairs function getAmountsOut(address factory, uint amountIn, address[] memory path) internal view returns (uint[] memory amounts) { require(path.length >= 2, 'UniswapV2Library: INVALID_PATH'); amounts = new uint[](path.length); amounts[0] = amountIn; for (uint i; i < path.length - 1; i++) { (uint reserveIn, uint reserveOut) = getReserves(factory, path[i], path[i + 1]); amounts[i + 1] = getAmountOut(amounts[i], reserveIn, reserveOut); } } // performs chained getAmountIn calculations on any number of pairs function getAmountsIn(address factory, uint amountOut, address[] memory path) internal view returns (uint[] memory amounts) { require(path.length >= 2, 'UniswapV2Library: INVALID_PATH'); amounts = new uint[](path.length); amounts[amounts.length - 1] = amountOut; for (uint i = path.length - 1; i > 0; i--) { (uint reserveIn, uint reserveOut) = getReserves(factory, path[i - 1], path[i]); amounts[i - 1] = getAmountIn(amounts[i], reserveIn, reserveOut); } } }
// SPDX-License-Identifier: GPL-2.0-only // Copyright 2020 Spilsbury Holdings Ltd pragma solidity >=0.6.10 <0.8.0; interface IFeeDistributor { event FeeReimbursed(address receiver, uint256 amount); event Convert(uint256 assetId, uint256 inputValue, uint256 outputValue); function reimburseConstant() external pure returns (uint256); function convertConstant() external pure returns (uint256); function rollupProcessor() external pure returns (address); function router() external pure returns (address); function factory() external pure returns (address); function WETH() external pure returns (address); function setReimburseConstant(uint256 _reimburseConstant) external; function setConvertConstant(uint256 _convertConstant) external; function txFeeBalance(uint256 assetId) external view returns (uint256); function deposit(uint256 assetId, uint256 amount) external payable returns (uint256 depositedAmount); function reimburseGas( uint256 gasUsed, uint256 feeLimit, address payable feeReceiver ) external returns (uint256 reimbursement); function convert(uint256 assetId, uint256 minOutputValue) external returns (uint256 outputValue); }
// SPDX-License-Identifier: GPL-2.0-only // Copyright 2020 Spilsbury Holdings Ltd pragma solidity >=0.6.10 <0.8.0; interface IRollupProcessor { function feeDistributor() external view returns (address); function escapeHatch( bytes calldata proofData, bytes calldata signatures, bytes calldata viewingKeys ) external; function processRollup( bytes calldata proofData, bytes calldata signatures, bytes calldata viewingKeys, bytes calldata providerSignature, address provider, address payable feeReceiver, uint256 feeLimit ) external; function depositPendingFunds( uint256 assetId, uint256 amount, address owner ) external payable; function depositPendingFundsPermit( uint256 assetId, uint256 amount, address owner, address spender, uint256 permitApprovalAmount, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; function setRollupProvider(address provderAddress, bool valid) external; function approveProof(bytes32 _proofHash) external; function setFeeDistributor(address feeDistributorAddress) external; function setVerifier(address verifierAddress) external; function setSupportedAsset(address linkedToken, bool supportsPermit) external; function setAssetPermitSupport(uint256 assetId, bool supportsPermit) external; function getSupportedAsset(uint256 assetId) external view returns (address); function getSupportedAssets() external view returns (address[] memory); function getTotalDeposited() external view returns (uint256[] memory); function getTotalWithdrawn() external view returns (uint256[] memory); function getTotalPendingDeposit() external view returns (uint256[] memory); function getTotalFees() external view returns (uint256[] memory); function getAssetPermitSupport(uint256 assetId) external view returns (bool); function getEscapeHatchStatus() external view returns (bool, uint256); function getUserPendingDeposit(uint256 assetId, address userAddress) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.8.0; /* * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with GSN meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address payable) { return msg.sender; } function _msgData() internal view virtual returns (bytes memory) { this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691 return msg.data; } }
pragma solidity >=0.6.2; interface IUniswapV2Router01 { function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidity( address tokenA, address tokenB, uint amountADesired, uint amountBDesired, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB, uint liquidity); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); function removeLiquidity( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB); function removeLiquidityETH( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountToken, uint amountETH); function removeLiquidityWithPermit( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountA, uint amountB); function removeLiquidityETHWithPermit( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountToken, uint amountETH); function swapExactTokensForTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapTokensForExactTokens( uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapExactETHForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function swapTokensForExactETH(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapExactTokensForETH(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapETHForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); }
pragma solidity >=0.6.6; // a library for performing overflow-safe math, courtesy of DappHub (https://github.com/dapphub/ds-math) library SafeMath { function add(uint x, uint y) internal pure returns (uint z) { require((z = x + y) >= x, 'ds-math-add-overflow'); } function sub(uint x, uint y) internal pure returns (uint z) { require((z = x - y) <= x, 'ds-math-sub-underflow'); } function mul(uint x, uint y) internal pure returns (uint z) { require(y == 0 || (z = x * y) / y == x, 'ds-math-mul-overflow'); } }
{ "evmVersion": "istanbul", "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_rollupProcessor","type":"address"},{"internalType":"address","name":"_router","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"assetId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"inputValue","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"outputValue","type":"uint256"}],"name":"Convert","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"FeeReimbursed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"WETH","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"assetId","type":"uint256"},{"internalType":"uint256","name":"minOutputValue","type":"uint256"}],"name":"convert","outputs":[{"internalType":"uint256","name":"outputValue","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"convertConstant","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"assetId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[{"internalType":"uint256","name":"depositedAmount","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"reimburseConstant","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"feeLimit","type":"uint256"},{"internalType":"address payable","name":"feeReceiver","type":"address"}],"name":"reimburseGas","outputs":[{"internalType":"uint256","name":"reimbursement","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rollupProcessor","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"router","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_convertConstant","type":"uint256"}],"name":"setConvertConstant","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_reimburseConstant","type":"uint256"}],"name":"setReimburseConstant","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"assetId","type":"uint256"}],"name":"txFeeBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
61010060405262038810600155623025a06002553480156200002057600080fd5b5060405162001af538038062001af5833981810160405260408110156200004657600080fd5b5080516020909101516000620000646001600160e01b03620001cf16565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3506001600160601b0319606083811b821660805282901b1660a0526040805163c45a015560e01b815290516001600160a01b0383169163c45a0155916004808301926020929190829003018186803b1580156200010957600080fd5b505afa1580156200011e573d6000803e3d6000fd5b505050506040513d60208110156200013557600080fd5b505160601b6001600160601b03191660c052604080516315ab88c960e31b815290516001600160a01b0383169163ad5c4648916004808301926020929190829003018186803b1580156200018857600080fd5b505afa1580156200019d573d6000803e3d6000fd5b505050506040513d6020811015620001b457600080fd5b505160601b6001600160601b03191660e05250620001d39050565b3390565b60805160601c60a05160601c60c05160601c60e05160601c6118ae6200024760003980610a495280610f515280610fb65280611119528061124e525080610a6d5280610f2f5280610f94525080610e43525080610315528061034a5280610510528061084f5280610b3652506118ae6000f3fe6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c746d1d011610059578063c746d1d014610293578063e2bbb158146102a8578063f2fde38b146102cb578063f887ea40146102fe576100f3565b80638da5cb5b1461022457806396e4ee3d14610239578063ad5c464814610269578063c45a01551461027e576100f3565b80636b426d66116100c65780636b426d661461018f578063715018a6146101b95780637827524b146101d057806386a88da2146101fa576100f3565b80632a113d6e146100f857806349a695081461012957806356aa719914610150576100f3565b366100f357005b600080fd5b34801561010457600080fd5b5061010d610313565b604080516001600160a01b039092168252519081900360200190f35b34801561013557600080fd5b5061013e610337565b60408051918252519081900360200190f35b34801561015c57600080fd5b5061013e6004803603606081101561017357600080fd5b50803590602081013590604001356001600160a01b031661033d565b34801561019b57600080fd5b5061013e600480360360208110156101b257600080fd5b50356104fe565b3480156101c557600080fd5b506101ce610622565b005b3480156101dc57600080fd5b506101ce600480360360208110156101f357600080fd5b50356106ce565b34801561020657600080fd5b506101ce6004803603602081101561021d57600080fd5b5035610735565b34801561023057600080fd5b5061010d61079c565b34801561024557600080fd5b5061013e6004803603604081101561025c57600080fd5b50803590602001356107ab565b34801561027557600080fd5b5061010d610a47565b34801561028a57600080fd5b5061010d610a6b565b34801561029f57600080fd5b5061013e610a8f565b61013e600480360360408110156102be57600080fd5b5080359060200135610a95565b3480156102d757600080fd5b506101ce600480360360208110156102ee57600080fd5b50356001600160a01b0316610d3f565b34801561030a57600080fd5b5061010d610e41565b7f000000000000000000000000000000000000000000000000000000000000000081565b60015481565b6000336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146103bc576040805162461bcd60e51b815260206004820152601f60248201527f466565204469737472696275746f723a20494e56414c49445f43414c4c455200604482015290519081900360640190fd5b6103e13a6103d560015487610e6590919063ffffffff16565b9063ffffffff610ec816565b9050828111156104225760405162461bcd60e51b815260040180806020018281038252602381526020018061182b6023913960400191505060405180910390fd5b6040516000906001600160a01b0384169083908381818185875af1925050503d806000811461046d576040519150601f19603f3d011682016040523d82523d6000602084013e610472565b606091505b50509050806104b25760405162461bcd60e51b81526004018080602001828103825260258152602001806117c56025913960400191505060405180910390fd5b604080516001600160a01b03851681526020810184905281517fcf4cc329b7982381c7a729b04a403439bbef0749b4a8dbd2a3850218b420bd87929181900390910190a1509392505050565b60008161050c57504761061d565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166360a8b18a846040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561057257600080fd5b505afa158015610586573d6000803e3d6000fd5b505050506040513d602081101561059c57600080fd5b5051604080516370a0823160e01b815230600482015290519192506001600160a01b038316916370a0823191602480820192602092909190829003018186803b1580156105e857600080fd5b505afa1580156105fc573d6000803e3d6000fd5b505050506040513d602081101561061257600080fd5b5051915061061d9050565b919050565b61062a610f21565b6001600160a01b031661063b61079c565b6001600160a01b031614610684576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6106d6610f21565b6001600160a01b03166106e761079c565b6001600160a01b031614610730576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600155565b61073d610f21565b6001600160a01b031661074e61079c565b6001600160a01b031614610797576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600255565b6000546001600160a01b031690565b60006107b5610f21565b6001600160a01b03166107c661079c565b6001600160a01b03161461080f576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b8261084b5760405162461bcd60e51b81526004018080602001828103825260228152602001806116e26022913960400191505060405180910390fd5b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166360a8b18a856040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156108b157600080fd5b505afa1580156108c5573d6000803e3d6000fd5b505050506040513d60208110156108db57600080fd5b5051604080516370a0823160e01b815230600482015290519192506000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561092957600080fd5b505afa15801561093d573d6000803e3d6000fd5b505050506040513d602081101561095357600080fd5b50519050806109a9576040805162461bcd60e51b815260206004820152601e60248201527f466565204469737472696275746f723a20454d5054595f42414c414e43450000604482015290519081900360640190fd5b6109b38282610f25565b9250838310156109f45760405162461bcd60e51b815260040180806020018281038252602b815260200180611772602b913960400191505060405180910390fd5b6109ff828285610f8d565b604080518681526020810183905280820185905290517f4ce95f38741cee3ff8dbe0e93f4d495736f717646b07bdc0c17fc43549c34e4f9181900360600190a1505092915050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b60025481565b600082610af557348214610af0576040805162461bcd60e51b815260206004820152601d60248201527f466565204469737472696275746f723a2057524f4e475f414d4f554e54000000604482015290519081900360640190fd5b610d39565b3415610b325760405162461bcd60e51b815260040180806020018281038252602381526020018061172a6023913960400191505060405180910390fd5b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166360a8b18a856040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610b9857600080fd5b505afa158015610bac573d6000803e3d6000fd5b505050506040513d6020811015610bc257600080fd5b5051604080516323b872dd60e01b81523360048201523060248201526044810186905290519192506001600160a01b038316916323b872dd916064808201926020929091908290030181600087803b158015610c1d57600080fd5b505af1158015610c31573d6000803e3d6000fd5b505050506040513d6020811015610c4757600080fd5b5050604080516370a0823160e01b815230600482015290516000916001600160a01b038416916370a0823191602480820192602092909190829003018186803b158015610c9357600080fd5b505afa158015610ca7573d6000803e3d6000fd5b505050506040513d6020811015610cbd57600080fd5b505190506000610ccd8383610f25565b600254909150610ce3903a63ffffffff610ec816565b8110610d3557610cf4838383610f8d565b604080518781526020810184905280820183905290517f4ce95f38741cee3ff8dbe0e93f4d495736f717646b07bdc0c17fc43549c34e4f9181900360600190a15b5050505b50919050565b610d47610f21565b6001600160a01b0316610d5861079c565b6001600160a01b031614610da1576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b6001600160a01b038116610de65760405162461bcd60e51b81526004018080602001828103825260268152602001806117046026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b7f000000000000000000000000000000000000000000000000000000000000000081565b600082820183811015610ebf576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b600082610ed757506000610ec2565b82820282848281610ee457fe5b0414610ebf5760405162461bcd60e51b81526004018080602001828103825260218152602001806117ea6021913960400191505060405180910390fd5b3390565b6000806000610f757f0000000000000000000000000000000000000000000000000000000000000000867f00000000000000000000000000000000000000000000000000000000000000006112d3565b91509150610f848483836113a1565b95945050505050565b6000610fda7f0000000000000000000000000000000000000000000000000000000000000000857f0000000000000000000000000000000000000000000000000000000000000000611491565b604080516001600160a01b038084166024830152604480830188905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182519495506000949189169390918291908083835b602083106110575780518252601f199092019160209182019101611038565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146110b9576040519150601f19603f3d011682016040523d82523d6000602084013e6110be565b606091505b5050905080611114576040805162461bcd60e51b815260206004820181905260248201527f466565204469737472696275746f723a205452414e534645525f4641494c4544604482015290519081900360640190fd5b6000807f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316876001600160a01b0316106111585784600061115c565b6000855b604080516000808252602082019283905263022c0d9f60e01b835260248201858152604483018590523060648401819052608060848501908152845160a486018190529799509597506001600160a01b038b169663022c0d9f968a968a969395939493919260c48601928190849084905b838110156111e55781810151838201526020016111cd565b50505050905090810190601f1680156112125780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b15801561123457600080fd5b505af1158015611248573d6000803e3d6000fd5b505050507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316632e1a7d4d866040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156112b257600080fd5b505af11580156112c6573d6000803e3d6000fd5b5050505050505050505050565b60008060006112e28585611551565b5090506000806112f3888888611491565b6001600160a01b0316630902f1ac6040518163ffffffff1660e01b815260040160606040518083038186803b15801561132b57600080fd5b505afa15801561133f573d6000803e3d6000fd5b505050506040513d606081101561135557600080fd5b5080516020909101516dffffffffffffffffffffffffffff91821693501690506001600160a01b038781169084161461138f578082611392565b81815b90999098509650505050505050565b60008084116113e15760405162461bcd60e51b815260040180806020018281038252602b81526020018061184e602b913960400191505060405180910390fd5b6000831180156113f15750600082115b61142c5760405162461bcd60e51b815260040180806020018281038252602881526020018061179d6028913960400191505060405180910390fd5b6000611440856103e563ffffffff61162f16565b90506000611454828563ffffffff61162f16565b9050600061147a8361146e886103e863ffffffff61162f16565b9063ffffffff61169216565b905080828161148557fe5b04979650505050505050565b60008060006114a08585611551565b604080516bffffffffffffffffffffffff19606094851b811660208084019190915293851b81166034830152825160288184030181526048830184528051908501206001600160f81b031960688401529a90941b9093166069840152607d8301989098527f96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f609d808401919091528851808403909101815260bd909201909752805196019590952095945050505050565b600080826001600160a01b0316846001600160a01b031614156115a55760405162461bcd60e51b815260040180806020018281038252602581526020018061174d6025913960400191505060405180910390fd5b826001600160a01b0316846001600160a01b0316106115c55782846115c8565b83835b90925090506001600160a01b038216611628576040805162461bcd60e51b815260206004820152601e60248201527f556e697377617056324c6962726172793a205a45524f5f414444524553530000604482015290519081900360640190fd5b9250929050565b600081158061164a5750508082028282828161164757fe5b04145b610ec2576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6d756c2d6f766572666c6f7760601b604482015290519081900360640190fd5b80820182811015610ec2576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fdfe466565204469737472696275746f723a204e4f545f415f544f4b454e5f41535345544f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373466565204469737472696275746f723a2057524f4e475f5041594d454e545f54595045556e697377617056324c6962726172793a204944454e544943414c5f414444524553534553466565204469737472696275746f723a20494e53554646494349454e545f4f55545055545f414d4f554e54556e697377617056324c6962726172793a20494e53554646494349454e545f4c4951554944495459466565204469737472696275746f723a205245494d42555253455f4741535f4641494c4544536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572466565204469737472696275746f723a204645455f4c494d49545f4558434545444544556e697377617056324c6962726172793a20494e53554646494349454e545f494e5055545f414d4f554e54a2646970667358221220f968829c6f6760eb3d7db7c6cf0da404baab6c6868cdfc9a2307b64c5f3f5d9564736f6c634300060a0033000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d
Deployed Bytecode
0x6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c746d1d011610059578063c746d1d014610293578063e2bbb158146102a8578063f2fde38b146102cb578063f887ea40146102fe576100f3565b80638da5cb5b1461022457806396e4ee3d14610239578063ad5c464814610269578063c45a01551461027e576100f3565b80636b426d66116100c65780636b426d661461018f578063715018a6146101b95780637827524b146101d057806386a88da2146101fa576100f3565b80632a113d6e146100f857806349a695081461012957806356aa719914610150576100f3565b366100f357005b600080fd5b34801561010457600080fd5b5061010d610313565b604080516001600160a01b039092168252519081900360200190f35b34801561013557600080fd5b5061013e610337565b60408051918252519081900360200190f35b34801561015c57600080fd5b5061013e6004803603606081101561017357600080fd5b50803590602081013590604001356001600160a01b031661033d565b34801561019b57600080fd5b5061013e600480360360208110156101b257600080fd5b50356104fe565b3480156101c557600080fd5b506101ce610622565b005b3480156101dc57600080fd5b506101ce600480360360208110156101f357600080fd5b50356106ce565b34801561020657600080fd5b506101ce6004803603602081101561021d57600080fd5b5035610735565b34801561023057600080fd5b5061010d61079c565b34801561024557600080fd5b5061013e6004803603604081101561025c57600080fd5b50803590602001356107ab565b34801561027557600080fd5b5061010d610a47565b34801561028a57600080fd5b5061010d610a6b565b34801561029f57600080fd5b5061013e610a8f565b61013e600480360360408110156102be57600080fd5b5080359060200135610a95565b3480156102d757600080fd5b506101ce600480360360208110156102ee57600080fd5b50356001600160a01b0316610d3f565b34801561030a57600080fd5b5061010d610e41565b7f000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba81565b60015481565b6000336001600160a01b037f000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba16146103bc576040805162461bcd60e51b815260206004820152601f60248201527f466565204469737472696275746f723a20494e56414c49445f43414c4c455200604482015290519081900360640190fd5b6103e13a6103d560015487610e6590919063ffffffff16565b9063ffffffff610ec816565b9050828111156104225760405162461bcd60e51b815260040180806020018281038252602381526020018061182b6023913960400191505060405180910390fd5b6040516000906001600160a01b0384169083908381818185875af1925050503d806000811461046d576040519150601f19603f3d011682016040523d82523d6000602084013e610472565b606091505b50509050806104b25760405162461bcd60e51b81526004018080602001828103825260258152602001806117c56025913960400191505060405180910390fd5b604080516001600160a01b03851681526020810184905281517fcf4cc329b7982381c7a729b04a403439bbef0749b4a8dbd2a3850218b420bd87929181900390910190a1509392505050565b60008161050c57504761061d565b60007f000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba6001600160a01b03166360a8b18a846040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561057257600080fd5b505afa158015610586573d6000803e3d6000fd5b505050506040513d602081101561059c57600080fd5b5051604080516370a0823160e01b815230600482015290519192506001600160a01b038316916370a0823191602480820192602092909190829003018186803b1580156105e857600080fd5b505afa1580156105fc573d6000803e3d6000fd5b505050506040513d602081101561061257600080fd5b5051915061061d9050565b919050565b61062a610f21565b6001600160a01b031661063b61079c565b6001600160a01b031614610684576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6106d6610f21565b6001600160a01b03166106e761079c565b6001600160a01b031614610730576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600155565b61073d610f21565b6001600160a01b031661074e61079c565b6001600160a01b031614610797576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b600255565b6000546001600160a01b031690565b60006107b5610f21565b6001600160a01b03166107c661079c565b6001600160a01b03161461080f576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b8261084b5760405162461bcd60e51b81526004018080602001828103825260228152602001806116e26022913960400191505060405180910390fd5b60007f000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba6001600160a01b03166360a8b18a856040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156108b157600080fd5b505afa1580156108c5573d6000803e3d6000fd5b505050506040513d60208110156108db57600080fd5b5051604080516370a0823160e01b815230600482015290519192506000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561092957600080fd5b505afa15801561093d573d6000803e3d6000fd5b505050506040513d602081101561095357600080fd5b50519050806109a9576040805162461bcd60e51b815260206004820152601e60248201527f466565204469737472696275746f723a20454d5054595f42414c414e43450000604482015290519081900360640190fd5b6109b38282610f25565b9250838310156109f45760405162461bcd60e51b815260040180806020018281038252602b815260200180611772602b913960400191505060405180910390fd5b6109ff828285610f8d565b604080518681526020810183905280820185905290517f4ce95f38741cee3ff8dbe0e93f4d495736f717646b07bdc0c17fc43549c34e4f9181900360600190a1505092915050565b7f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc281565b7f0000000000000000000000005c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f81565b60025481565b600082610af557348214610af0576040805162461bcd60e51b815260206004820152601d60248201527f466565204469737472696275746f723a2057524f4e475f414d4f554e54000000604482015290519081900360640190fd5b610d39565b3415610b325760405162461bcd60e51b815260040180806020018281038252602381526020018061172a6023913960400191505060405180910390fd5b60007f000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba6001600160a01b03166360a8b18a856040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610b9857600080fd5b505afa158015610bac573d6000803e3d6000fd5b505050506040513d6020811015610bc257600080fd5b5051604080516323b872dd60e01b81523360048201523060248201526044810186905290519192506001600160a01b038316916323b872dd916064808201926020929091908290030181600087803b158015610c1d57600080fd5b505af1158015610c31573d6000803e3d6000fd5b505050506040513d6020811015610c4757600080fd5b5050604080516370a0823160e01b815230600482015290516000916001600160a01b038416916370a0823191602480820192602092909190829003018186803b158015610c9357600080fd5b505afa158015610ca7573d6000803e3d6000fd5b505050506040513d6020811015610cbd57600080fd5b505190506000610ccd8383610f25565b600254909150610ce3903a63ffffffff610ec816565b8110610d3557610cf4838383610f8d565b604080518781526020810184905280820183905290517f4ce95f38741cee3ff8dbe0e93f4d495736f717646b07bdc0c17fc43549c34e4f9181900360600190a15b5050505b50919050565b610d47610f21565b6001600160a01b0316610d5861079c565b6001600160a01b031614610da1576040805162461bcd60e51b8152602060048201819052602482015260008051602061180b833981519152604482015290519081900360640190fd5b6001600160a01b038116610de65760405162461bcd60e51b81526004018080602001828103825260268152602001806117046026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d81565b600082820183811015610ebf576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b600082610ed757506000610ec2565b82820282848281610ee457fe5b0414610ebf5760405162461bcd60e51b81526004018080602001828103825260218152602001806117ea6021913960400191505060405180910390fd5b3390565b6000806000610f757f0000000000000000000000005c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f867f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26112d3565b91509150610f848483836113a1565b95945050505050565b6000610fda7f0000000000000000000000005c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f857f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2611491565b604080516001600160a01b038084166024830152604480830188905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182519495506000949189169390918291908083835b602083106110575780518252601f199092019160209182019101611038565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146110b9576040519150601f19603f3d011682016040523d82523d6000602084013e6110be565b606091505b5050905080611114576040805162461bcd60e51b815260206004820181905260248201527f466565204469737472696275746f723a205452414e534645525f4641494c4544604482015290519081900360640190fd5b6000807f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b0316876001600160a01b0316106111585784600061115c565b6000855b604080516000808252602082019283905263022c0d9f60e01b835260248201858152604483018590523060648401819052608060848501908152845160a486018190529799509597506001600160a01b038b169663022c0d9f968a968a969395939493919260c48601928190849084905b838110156111e55781810151838201526020016111cd565b50505050905090810190601f1680156112125780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b15801561123457600080fd5b505af1158015611248573d6000803e3d6000fd5b505050507f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b0316632e1a7d4d866040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156112b257600080fd5b505af11580156112c6573d6000803e3d6000fd5b5050505050505050505050565b60008060006112e28585611551565b5090506000806112f3888888611491565b6001600160a01b0316630902f1ac6040518163ffffffff1660e01b815260040160606040518083038186803b15801561132b57600080fd5b505afa15801561133f573d6000803e3d6000fd5b505050506040513d606081101561135557600080fd5b5080516020909101516dffffffffffffffffffffffffffff91821693501690506001600160a01b038781169084161461138f578082611392565b81815b90999098509650505050505050565b60008084116113e15760405162461bcd60e51b815260040180806020018281038252602b81526020018061184e602b913960400191505060405180910390fd5b6000831180156113f15750600082115b61142c5760405162461bcd60e51b815260040180806020018281038252602881526020018061179d6028913960400191505060405180910390fd5b6000611440856103e563ffffffff61162f16565b90506000611454828563ffffffff61162f16565b9050600061147a8361146e886103e863ffffffff61162f16565b9063ffffffff61169216565b905080828161148557fe5b04979650505050505050565b60008060006114a08585611551565b604080516bffffffffffffffffffffffff19606094851b811660208084019190915293851b81166034830152825160288184030181526048830184528051908501206001600160f81b031960688401529a90941b9093166069840152607d8301989098527f96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f609d808401919091528851808403909101815260bd909201909752805196019590952095945050505050565b600080826001600160a01b0316846001600160a01b031614156115a55760405162461bcd60e51b815260040180806020018281038252602581526020018061174d6025913960400191505060405180910390fd5b826001600160a01b0316846001600160a01b0316106115c55782846115c8565b83835b90925090506001600160a01b038216611628576040805162461bcd60e51b815260206004820152601e60248201527f556e697377617056324c6962726172793a205a45524f5f414444524553530000604482015290519081900360640190fd5b9250929050565b600081158061164a5750508082028282828161164757fe5b04145b610ec2576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6d756c2d6f766572666c6f7760601b604482015290519081900360640190fd5b80820182811015610ec2576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fdfe466565204469737472696275746f723a204e4f545f415f544f4b454e5f41535345544f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373466565204469737472696275746f723a2057524f4e475f5041594d454e545f54595045556e697377617056324c6962726172793a204944454e544943414c5f414444524553534553466565204469737472696275746f723a20494e53554646494349454e545f4f55545055545f414d4f554e54556e697377617056324c6962726172793a20494e53554646494349454e545f4c4951554944495459466565204469737472696275746f723a205245494d42555253455f4741535f4641494c4544536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572466565204469737472696275746f723a204645455f4c494d49545f4558434545444544556e697377617056324c6962726172793a20494e53554646494349454e545f494e5055545f414d4f554e54a2646970667358221220f968829c6f6760eb3d7db7c6cf0da404baab6c6868cdfc9a2307b64c5f3f5d9564736f6c634300060a0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d
-----Decoded View---------------
Arg [0] : _rollupProcessor (address): 0x737901bea3eeb88459df9ef1BE8fF3Ae1B42A2ba
Arg [1] : _router (address): 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000737901bea3eeb88459df9ef1be8ff3ae1b42a2ba
Arg [1] : 0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.