ETH Price: $3,319.77 (-3.47%)
Gas: 9.21 Gwei

Contract

0xBf07a0Df119Ca234634588fbDb5625594E2a5BCA
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Deploy And Call212593922024-11-24 18:27:592 days ago1732472879IN
Ambire Wallet: Identity Factory
0 ETH0.002727529.00577535
Deploy And Call212397082024-11-22 0:32:114 days ago1732235531IN
Ambire Wallet: Identity Factory
0 ETH0.0023522410.7645322
Deploy And Call212396522024-11-22 0:20:594 days ago1732234859IN
Ambire Wallet: Identity Factory
0 ETH0.0026340213.18128568
Deploy And Call212392102024-11-21 22:51:474 days ago1732229507IN
Ambire Wallet: Identity Factory
0 ETH0.0035203912.76610198
Deploy And Call212350802024-11-21 9:02:115 days ago1732179731IN
Ambire Wallet: Identity Factory
0 ETH0.0021200110.61275638
Deploy And Call212325702024-11-21 0:36:595 days ago1732149419IN
Ambire Wallet: Identity Factory
0 ETH0.00162258.51577429
Deploy And Call211781222024-11-13 10:17:4713 days ago1731493067IN
Ambire Wallet: Identity Factory
0 ETH0.0034665321.26707932
Deploy And Call211698082024-11-12 6:27:2314 days ago1731392843IN
Ambire Wallet: Identity Factory
0 ETH0.0047193623.31450985
Deploy And Call211518512024-11-09 18:20:4717 days ago1731176447IN
Ambire Wallet: Identity Factory
0 ETH0.001376477.62476101
Deploy And Call211282472024-11-06 11:15:2320 days ago1730891723IN
Ambire Wallet: Identity Factory
0 ETH0.0022354613.92918605
Deploy And Call211240452024-11-05 21:10:5920 days ago1730841059IN
Ambire Wallet: Identity Factory
0 ETH0.000970165.8616078
Deploy And Call211006842024-11-02 14:54:3524 days ago1730559275IN
Ambire Wallet: Identity Factory
0 ETH0.001263035.57443532
Deploy And Call210661712024-10-28 19:18:4729 days ago1730143127IN
Ambire Wallet: Identity Factory
0 ETH0.0022611411.21659625
Deploy And Call210534302024-10-27 0:38:5930 days ago1729989539IN
Ambire Wallet: Identity Factory
0 ETH0.000741284.35556716
Deploy And Call210472752024-10-26 4:01:2331 days ago1729915283IN
Ambire Wallet: Identity Factory
0 ETH0.000600863.65708041
Deploy And Call210415662024-10-25 8:54:4732 days ago1729846487IN
Ambire Wallet: Identity Factory
0 ETH0.001286987.70310599
Deploy And Call210261972024-10-23 5:28:5934 days ago1729661339IN
Ambire Wallet: Identity Factory
0 ETH0.000916144.62552759
Deploy And Call210239622024-10-22 21:59:5934 days ago1729634399IN
Ambire Wallet: Identity Factory
0 ETH0.001059015.65732555
Deploy And Call209599082024-10-13 23:23:3543 days ago1728861815IN
Ambire Wallet: Identity Factory
0 ETH0.003241458.65619614
Deploy And Call209531472024-10-13 0:38:2344 days ago1728779903IN
Ambire Wallet: Identity Factory
0 ETH0.0025727513.73962424
Deploy And Call209318752024-10-10 1:18:4747 days ago1728523127IN
Ambire Wallet: Identity Factory
0 ETH0.001779779.46625913
Deploy And Call209199842024-10-08 9:32:4749 days ago1728379967IN
Ambire Wallet: Identity Factory
0 ETH0.0027767113.71712546
Deploy And Call209103202024-10-07 1:13:2350 days ago1728263603IN
Ambire Wallet: Identity Factory
0 ETH0.0022796112.12561186
Deploy And Call208981252024-10-05 8:25:4752 days ago1728116747IN
Ambire Wallet: Identity Factory
0 ETH0.001626414.14370995
Deploy And Call208844992024-10-03 10:49:5954 days ago1727952599IN
Ambire Wallet: Identity Factory
0 ETH0.000907654.76471229
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To
212593922024-11-24 18:27:592 days ago1732472879
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
212397082024-11-22 0:32:114 days ago1732235531
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
212396522024-11-22 0:20:594 days ago1732234859
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
212392102024-11-21 22:51:474 days ago1732229507
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
212350802024-11-21 9:02:115 days ago1732179731
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
212325702024-11-21 0:36:595 days ago1732149419
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211781222024-11-13 10:17:4713 days ago1731493067
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211698082024-11-12 6:27:2314 days ago1731392843
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211518512024-11-09 18:20:4717 days ago1731176447
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211282472024-11-06 11:15:2320 days ago1730891723
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211240452024-11-05 21:10:5920 days ago1730841059
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
211006842024-11-02 14:54:3524 days ago1730559275
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210661712024-10-28 19:18:4729 days ago1730143127
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210534302024-10-27 0:38:5930 days ago1729989539
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210472752024-10-26 4:01:2331 days ago1729915283
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210415662024-10-25 8:54:4732 days ago1729846487
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210356252024-10-24 13:01:4733 days ago1729774907
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210261972024-10-23 5:28:5934 days ago1729661339
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
210239622024-10-22 21:59:5934 days ago1729634399
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
209599082024-10-13 23:23:3543 days ago1728861815
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
209531472024-10-13 0:38:2344 days ago1728779903
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
209318752024-10-10 1:18:4747 days ago1728523127
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
209199842024-10-08 9:32:4749 days ago1728379967
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
209103202024-10-07 1:13:2350 days ago1728263603
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
208981252024-10-05 8:25:4752 days ago1728116747
Ambire Wallet: Identity Factory
 Contract Creation0 ETH
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
IdentityFactory

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license
/**
 *Submitted for verification at Etherscan.io on 2021-11-14
*/

// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.7;

// @TODO: Formatting
library LibBytes {
  // @TODO: see if we can just set .length = 
  function trimToSize(bytes memory b, uint newLen)
    internal
    pure
  {
    require(b.length > newLen, "BytesLib: only shrinking");
    assembly {
      mstore(b, newLen)
    }
  }


  /***********************************|
  |        Read Bytes Functions       |
  |__________________________________*/

  /**
   * @dev Reads a bytes32 value from a position in a byte array.
   * @param b Byte array containing a bytes32 value.
   * @param index Index in byte array of bytes32 value.
   * @return result bytes32 value from byte array.
   */
  function readBytes32(
    bytes memory b,
    uint256 index
  )
    internal
    pure
    returns (bytes32 result)
  {
    // Arrays are prefixed by a 256 bit length parameter
    index += 32;

    require(b.length >= index, "BytesLib: length");

    // Read the bytes32 from array memory
    assembly {
      result := mload(add(b, index))
    }
    return result;
  }
}



interface IERC1271Wallet {
	function isValidSignature(bytes32 hash, bytes calldata signature) external view returns (bytes4 magicValue);
}

library SignatureValidator {
	using LibBytes for bytes;

	enum SignatureMode {
		EIP712,
		EthSign,
		SmartWallet,
		Spoof
	}

	// bytes4(keccak256("isValidSignature(bytes32,bytes)"))
	bytes4 constant internal ERC1271_MAGICVALUE_BYTES32 = 0x1626ba7e;

	function recoverAddr(bytes32 hash, bytes memory sig) internal view returns (address) {
		return recoverAddrImpl(hash, sig, false);
	}

	function recoverAddrImpl(bytes32 hash, bytes memory sig, bool allowSpoofing) internal view returns (address) {
		require(sig.length >= 1, "SV_SIGLEN");
		uint8 modeRaw;
		unchecked { modeRaw = uint8(sig[sig.length - 1]); }
		SignatureMode mode = SignatureMode(modeRaw);

		// {r}{s}{v}{mode}
		if (mode == SignatureMode.EIP712 || mode == SignatureMode.EthSign) {
			require(sig.length == 66, "SV_LEN");
			bytes32 r = sig.readBytes32(0);
			bytes32 s = sig.readBytes32(32);
			uint8 v = uint8(sig[64]);
			// Hesitant about this check: seems like this is something that has no business being checked on-chain
			require(v == 27 || v == 28, "SV_INVALID_V");
			if (mode == SignatureMode.EthSign) hash = keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash));
			address signer = ecrecover(hash, v, r, s);
			require(signer != address(0), "SV_ZERO_SIG");
			return signer;
		// {sig}{verifier}{mode}
		} else if (mode == SignatureMode.SmartWallet) {
			// 32 bytes for the addr, 1 byte for the type = 33
			require(sig.length > 33, "SV_LEN_WALLET");
			uint newLen;
			unchecked {
				newLen = sig.length - 33;
			}
			IERC1271Wallet wallet = IERC1271Wallet(address(uint160(uint256(sig.readBytes32(newLen)))));
			sig.trimToSize(newLen);
			require(ERC1271_MAGICVALUE_BYTES32 == wallet.isValidSignature(hash, sig), "SV_WALLET_INVALID");
			return address(wallet);
		// {address}{mode}; the spoof mode is used when simulating calls
		} else if (mode == SignatureMode.Spoof && allowSpoofing) {
			require(tx.origin == address(1), "SV_SPOOF_ORIGIN");
			require(sig.length == 33, "SV_SPOOF_LEN");
			sig.trimToSize(32);
			return abi.decode(sig, (address));
		} else revert("SV_SIGMODE");
	}
}


contract Identity {
	mapping (address => bytes32) public privileges;
	// The next allowed nonce
	uint public nonce;

	// Events
	event LogPrivilegeChanged(address indexed addr, bytes32 priv);
	event LogErr(address indexed to, uint value, bytes data, bytes returnData); // only used in tryCatch

	// Transaction structure
	// we handle replay protection separately by requiring (address(this), chainID, nonce) as part of the sig
	struct Transaction {
		address to;
		uint value;
		bytes data;
	}

	constructor(address[] memory addrs) {
		uint len = addrs.length;
		for (uint i=0; i<len; i++) {
			// @TODO should we allow setting to any arb value here?
			privileges[addrs[i]] = bytes32(uint(1));
			emit LogPrivilegeChanged(addrs[i], bytes32(uint(1)));
		}
	}

	// This contract can accept ETH without calldata
	receive() external payable {}

	// This contract can accept ETH with calldata
	// However, to support EIP 721 and EIP 1155, we need to respond to those methods with their own method signature
	fallback() external payable {
		bytes4 method = msg.sig;
		if (
			method == 0x150b7a02 // bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))
				|| method == 0xf23a6e61 // bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))
				|| method == 0xbc197c81 // bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))
		) {
			// Copy back the method
			// solhint-disable-next-line no-inline-assembly
			assembly {
				calldatacopy(0, 0, 0x04)
				return (0, 0x20)
			}
		}
	}

	function setAddrPrivilege(address addr, bytes32 priv)
		external
	{
		require(msg.sender == address(this), 'ONLY_IDENTITY_CAN_CALL');
		// Anti-bricking measure: if the privileges slot is used for special data (not 0x01),
		// don't allow to set it to true
		if (uint(privileges[addr]) > 1) require(priv != bytes32(uint(1)), 'UNSETTING_SPECIAL_DATA');
		privileges[addr] = priv;
		emit LogPrivilegeChanged(addr, priv);
	}

	function tipMiner(uint amount)
		external
	{
		require(msg.sender == address(this), 'ONLY_IDENTITY_CAN_CALL');
		// See https://docs.flashbots.net/flashbots-auction/searchers/advanced/coinbase-payment/#managing-payments-to-coinbaseaddress-when-it-is-a-contract
		// generally this contract is reentrancy proof cause of the nonce
		executeCall(block.coinbase, amount, new bytes(0));
	}

	function tryCatch(address to, uint value, bytes calldata data)
		external
	{
		require(msg.sender == address(this), 'ONLY_IDENTITY_CAN_CALL');
		(bool success, bytes memory returnData) = to.call{value: value, gas: gasleft()}(data);
		if (!success) emit LogErr(to, value, data, returnData);
	}


	// WARNING: if the signature of this is changed, we have to change IdentityFactory
	function execute(Transaction[] calldata txns, bytes calldata signature)
		external
	{
		require(txns.length > 0, 'MUST_PASS_TX');
		uint currentNonce = nonce;
		// NOTE: abi.encode is safer than abi.encodePacked in terms of collision safety
		bytes32 hash = keccak256(abi.encode(address(this), block.chainid, currentNonce, txns));
		// We have to increment before execution cause it protects from reentrancies
		nonce = currentNonce + 1;

		address signer = SignatureValidator.recoverAddrImpl(hash, signature, true);
		require(privileges[signer] != bytes32(0), 'INSUFFICIENT_PRIVILEGE');
		uint len = txns.length;
		for (uint i=0; i<len; i++) {
			Transaction memory txn = txns[i];
			executeCall(txn.to, txn.value, txn.data);
		}
		// The actual anti-bricking mechanism - do not allow a signer to drop their own priviledges
		require(privileges[signer] != bytes32(0), 'PRIVILEGE_NOT_DOWNGRADED');
	}

	// no need for nonce management here cause we're not dealing with sigs
	function executeBySender(Transaction[] calldata txns) external {
		require(txns.length > 0, 'MUST_PASS_TX');
		require(privileges[msg.sender] != bytes32(0), 'INSUFFICIENT_PRIVILEGE');
		uint len = txns.length;
		for (uint i=0; i<len; i++) {
			Transaction memory txn = txns[i];
			executeCall(txn.to, txn.value, txn.data);
		}
		// again, anti-bricking
		require(privileges[msg.sender] != bytes32(0), 'PRIVILEGE_NOT_DOWNGRADED');
	}

	function executeBySelf(Transaction[] calldata txns) external {
		require(msg.sender == address(this), 'ONLY_IDENTITY_CAN_CALL');
		require(txns.length > 0, 'MUST_PASS_TX');
		uint len = txns.length;
		for (uint i=0; i<len; i++) {
			Transaction memory txn = txns[i];
			executeCall(txn.to, txn.value, txn.data);
		}
	}

	// we shouldn't use address.call(), cause: https://github.com/ethereum/solidity/issues/2884
	// copied from https://github.com/uport-project/uport-identity/blob/develop/contracts/Proxy.sol
	// there's also
	// https://github.com/gnosis/MultiSigWallet/commit/e1b25e8632ca28e9e9e09c81bd20bf33fdb405ce
	// https://github.com/austintgriffith/bouncer-proxy/blob/master/BouncerProxy/BouncerProxy.sol
	// https://github.com/gnosis/safe-contracts/blob/7e2eeb3328bb2ae85c36bc11ea6afc14baeb663c/contracts/base/Executor.sol
	function executeCall(address to, uint256 value, bytes memory data)
		internal
	{
		assembly {
			let result := call(gas(), to, value, add(data, 0x20), mload(data), 0, 0)

			switch result case 0 {
				let size := returndatasize()
				let ptr := mload(0x40)
				returndatacopy(ptr, 0, size)
				revert(ptr, size)
			}
			default {}
		}
		// A single call consumes around 477 more gas with the pure solidity version, for whatever reason
		// WARNING: do not use this, it corrupts the returnData string (returns it in a slightly different format)
		//(bool success, bytes memory returnData) = to.call{value: value, gas: gasleft()}(data);
		//if (!success) revert(string(data));
	}

	// EIP 1271 implementation
	// see https://eips.ethereum.org/EIPS/eip-1271
	function isValidSignature(bytes32 hash, bytes calldata signature) external view returns (bytes4) {
		if (privileges[SignatureValidator.recoverAddr(hash, signature)] != bytes32(0)) {
			// bytes4(keccak256("isValidSignature(bytes32,bytes)")
			return 0x1626ba7e;
		} else {
			return 0xffffffff;
		}
	}

	// EIP 1155 implementation
	// we pretty much only need to signal that we support the interface for 165, but for 1155 we also need the fallback function
	function supportsInterface(bytes4 interfaceID) external pure returns (bool) {
		return
			interfaceID == 0x01ffc9a7 ||    // ERC-165 support (i.e. `bytes4(keccak256('supportsInterface(bytes4)'))`).
			interfaceID == 0x4e2312e0;      // ERC-1155 `ERC1155TokenReceiver` support (i.e. `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)")) ^ bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))`).
	}
}

interface IERC20 {
    function totalSupply() external view returns (uint256);
    function balanceOf(address account) external view returns (uint256);
    function transfer(address recipient, uint256 amount) external returns (bool);
    function allowance(address owner, address spender) external view returns (uint256);
    function approve(address spender, uint256 amount) external returns (bool);
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);
}


contract IdentityFactory {
	event LogDeployed(address addr, uint256 salt);

	address public immutable allowedToDrain;
	constructor(address allowed) {
		allowedToDrain = allowed;
	}

	function deploy(bytes calldata code, uint256 salt) external {
		deploySafe(code, salt);
	}

	// When the relayer needs to act upon an /identity/:addr/submit call, it'll either call execute on the Identity directly
	// if it's already deployed, or call `deployAndExecute` if the account is still counterfactual
	// we can't have deployAndExecuteBySender, because the sender will be the factory
	function deployAndExecute(
		bytes calldata code, uint256 salt,
		Identity.Transaction[] calldata txns, bytes calldata signature
	) external {
		address payable addr = payable(deploySafe(code, salt));
		Identity(addr).execute(txns, signature);
	}
	// but for the quick accounts we need this
	function deployAndCall(bytes calldata code, uint256 salt, address callee, bytes calldata data) external {
		deploySafe(code, salt);
		require(data.length > 4, 'DATA_LEN');
		bytes4 method;
		// solium-disable-next-line security/no-inline-assembly
		assembly {
			// can also do shl(224, shr(224, calldataload(0)))
			method := and(calldataload(data.offset), 0xffffffff00000000000000000000000000000000000000000000000000000000)
		}
		require(
			method == 0x6171d1c9 // execute((address,uint256,bytes)[],bytes)
			|| method == 0x534255ff // send(address,(uint256,address,address),(bool,bytes,bytes),(address,uint256,bytes)[])
			|| method == 0x4b776c6d // sendTransfer(address,(uint256,address,address),(bytes,bytes),(address,address,uint256,uint256))
			|| method == 0x63486689 // sendTxns(address,(uint256,address,address),(bytes,bytes),(string,address,uint256,bytes)[])
		, 'INVALID_METHOD');

		assembly {
			let dataPtr := mload(0x40)
			calldatacopy(dataPtr, data.offset, data.length)
			let result := call(gas(), callee, 0, dataPtr, data.length, 0, 0)

			switch result case 0 {
				let size := returndatasize()
				let ptr := mload(0x40)
				returndatacopy(ptr, 0, size)
				revert(ptr, size)
			}
			default {}
		}
	}


	// Withdraw the earnings from various fees (deploy fees and execute fees earned cause of `deployAndExecute`)
	// although we do not use this since we no longer receive fees on the factory, it's good to have this for safety
	// In practice, we (almost) never receive fees on the factory, but there's one exception: QuickAccManager EIP 712 methods (sendTransfer) + deployAndCall
	function withdraw(IERC20 token, address to, uint256 tokenAmount) external {
		require(msg.sender == allowedToDrain, 'ONLY_AUTHORIZED');
		token.transfer(to, tokenAmount);
	}

	// This is done to mitigate possible frontruns where, for example, deploying the same code/salt via deploy()
	// would make a pending deployAndExecute fail
	// The way we mitigate that is by checking if the contract is already deployed and if so, we continue execution
	function deploySafe(bytes memory code, uint256 salt) internal returns (address) {
		address expectedAddr = address(uint160(uint256(
			keccak256(abi.encodePacked(bytes1(0xff), address(this), salt, keccak256(code)))
		)));
		uint size;
		assembly { size := extcodesize(expectedAddr) }
		// If there is code at that address, we can assume it's the one we were about to deploy,
		// because of how CREATE2 and keccak256 works
		if (size == 0) {
			address addr;
			assembly { addr := create2(0, add(code, 0x20), mload(code), salt) }
			require(addr != address(0), 'FAILED_DEPLOYING');
			require(addr == expectedAddr, 'FAILED_MATCH');
			emit LogDeployed(addr, salt);
		}
		return expectedAddr;
	}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"allowed","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"addr","type":"address"},{"indexed":false,"internalType":"uint256","name":"salt","type":"uint256"}],"name":"LogDeployed","type":"event"},{"inputs":[],"name":"allowedToDrain","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"code","type":"bytes"},{"internalType":"uint256","name":"salt","type":"uint256"}],"name":"deploy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"code","type":"bytes"},{"internalType":"uint256","name":"salt","type":"uint256"},{"internalType":"address","name":"callee","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"deployAndCall","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"code","type":"bytes"},{"internalType":"uint256","name":"salt","type":"uint256"},{"components":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct Identity.Transaction[]","name":"txns","type":"tuple[]"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"deployAndExecute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenAmount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60a060405234801561001057600080fd5b506040516109ea3803806109ea83398101604081905261002f91610044565b60601b6001600160601b031916608052610074565b60006020828403121561005657600080fd5b81516001600160a01b038116811461006d57600080fd5b9392505050565b60805160601c610952610098600039600081816061015261035001526109526000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c80631ce6236f1461005c5780631e86da2a1461009f57806349c81579146100b45780639c4ae2d0146100c7578063d9caed12146100da575b600080fd5b6100837f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200160405180910390f35b6100b26100ad3660046106d2565b6100ed565b005b6100b26100c2366004610644565b6101a1565b6100b26100d53660046105f8565b6102fe565b6100b26100e83660046107a7565b610345565b600061013088888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a9250610431915050565b604051636171d1c960e01b81529091506001600160a01b03821690636171d1c990610165908890889088908890600401610811565b600060405180830381600087803b15801561017f57600080fd5b505af1158015610193573d6000803e3d6000fd5b505050505050505050505050565b6101e286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250889250610431915050565b50600481116102235760405162461bcd60e51b81526020600482015260086024820152672220aa20afa622a760c11b60448201526064015b60405180910390fd5b81356001600160e01b031916636171d1c960e01b811480610254575063534255ff60e01b6001600160e01b03198216145b8061026f5750634b776c6d60e01b6001600160e01b03198216145b8061028a5750636348668960e01b6001600160e01b03198216145b6102c75760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d351551213d160921b604482015260640161021a565b6040518284823760008084836000895af190508080156102e6576102f3565b3d604051816000823e8181fd5b505050505050505050565b61033f83838080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859250610431915050565b50505050565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146103af5760405162461bcd60e51b815260206004820152600f60248201526e13d3931657d055551213d492569151608a1b604482015260640161021a565b60405163a9059cbb60e01b81526001600160a01b0383811660048301526024820183905284169063a9059cbb90604401602060405180830381600087803b1580156103f957600080fd5b505af115801561040d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061033f91906105cf565b8151602080840191909120604080516001600160f81b0319818501523060601b6bffffffffffffffffffffffff19166021820152603581018590526055808201939093528151808203909301835260750190528051910120600090803b8061057e576000848651602088016000f590506001600160a01b0381166104ea5760405162461bcd60e51b815260206004820152601060248201526f4641494c45445f4445504c4f59494e4760801b604482015260640161021a565b826001600160a01b0316816001600160a01b03161461053a5760405162461bcd60e51b815260206004820152600c60248201526b08c8292988a88be9a82a886960a31b604482015260640161021a565b604080516001600160a01b0383168152602081018790527fecef66cbb4d4c8dd18157def75d46290ddc298395ea46f7ff64321c1a912cbad910160405180910390a1505b509392505050565b60008083601f84011261059857600080fd5b50813567ffffffffffffffff8111156105b057600080fd5b6020830191508360208285010111156105c857600080fd5b9250929050565b6000602082840312156105e157600080fd5b815180151581146105f157600080fd5b9392505050565b60008060006040848603121561060d57600080fd5b833567ffffffffffffffff81111561062457600080fd5b61063086828701610586565b909790965060209590950135949350505050565b6000806000806000806080878903121561065d57600080fd5b863567ffffffffffffffff8082111561067557600080fd5b6106818a838b01610586565b9098509650602089013595506040890135915061069d82610904565b909350606088013590808211156106b357600080fd5b506106c089828a01610586565b979a9699509497509295939492505050565b60008060008060008060006080888a0312156106ed57600080fd5b873567ffffffffffffffff8082111561070557600080fd5b6107118b838c01610586565b909950975060208a0135965060408a013591508082111561073157600080fd5b818a0191508a601f83011261074557600080fd5b81358181111561075457600080fd5b8b60208260051b850101111561076957600080fd5b6020830196508095505060608a013591508082111561078757600080fd5b506107948a828b01610586565b989b979a50959850939692959293505050565b6000806000606084860312156107bc57600080fd5b83356107c781610904565b925060208401356107d781610904565b929592945050506040919091013590565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60408082528181018590526000906060808401600588901b8501820189855b8a8110156108e157878303605f190184528135368d9003605e1901811261085657600080fd5b8c01803561086381610904565b6001600160a01b03168452602081810135818601528782013536839003601e1901811261088f57600080fd5b8201803567ffffffffffffffff8111156108a857600080fd5b8036038413156108b757600080fd5b888a8801526108cb898801828585016107e8565b9783019796505050929092019150600101610830565b505085810360208701526108f681888a6107e8565b9a9950505050505050505050565b6001600160a01b038116811461091957600080fd5b5056fea2646970667358221220f2f7b8ae56f395f993ace824b61aafd112d10ad47a0003cd7de4bb4668d7da3d64736f6c6343000807003300000000000000000000000023c2c34f38ce66ccc10e71e9bb2a06532d52c5e9

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100575760003560e01c80631ce6236f1461005c5780631e86da2a1461009f57806349c81579146100b45780639c4ae2d0146100c7578063d9caed12146100da575b600080fd5b6100837f00000000000000000000000023c2c34f38ce66ccc10e71e9bb2a06532d52c5e981565b6040516001600160a01b03909116815260200160405180910390f35b6100b26100ad3660046106d2565b6100ed565b005b6100b26100c2366004610644565b6101a1565b6100b26100d53660046105f8565b6102fe565b6100b26100e83660046107a7565b610345565b600061013088888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a9250610431915050565b604051636171d1c960e01b81529091506001600160a01b03821690636171d1c990610165908890889088908890600401610811565b600060405180830381600087803b15801561017f57600080fd5b505af1158015610193573d6000803e3d6000fd5b505050505050505050505050565b6101e286868080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250889250610431915050565b50600481116102235760405162461bcd60e51b81526020600482015260086024820152672220aa20afa622a760c11b60448201526064015b60405180910390fd5b81356001600160e01b031916636171d1c960e01b811480610254575063534255ff60e01b6001600160e01b03198216145b8061026f5750634b776c6d60e01b6001600160e01b03198216145b8061028a5750636348668960e01b6001600160e01b03198216145b6102c75760405162461bcd60e51b815260206004820152600e60248201526d1253959053125117d351551213d160921b604482015260640161021a565b6040518284823760008084836000895af190508080156102e6576102f3565b3d604051816000823e8181fd5b505050505050505050565b61033f83838080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859250610431915050565b50505050565b336001600160a01b037f00000000000000000000000023c2c34f38ce66ccc10e71e9bb2a06532d52c5e916146103af5760405162461bcd60e51b815260206004820152600f60248201526e13d3931657d055551213d492569151608a1b604482015260640161021a565b60405163a9059cbb60e01b81526001600160a01b0383811660048301526024820183905284169063a9059cbb90604401602060405180830381600087803b1580156103f957600080fd5b505af115801561040d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061033f91906105cf565b8151602080840191909120604080516001600160f81b0319818501523060601b6bffffffffffffffffffffffff19166021820152603581018590526055808201939093528151808203909301835260750190528051910120600090803b8061057e576000848651602088016000f590506001600160a01b0381166104ea5760405162461bcd60e51b815260206004820152601060248201526f4641494c45445f4445504c4f59494e4760801b604482015260640161021a565b826001600160a01b0316816001600160a01b03161461053a5760405162461bcd60e51b815260206004820152600c60248201526b08c8292988a88be9a82a886960a31b604482015260640161021a565b604080516001600160a01b0383168152602081018790527fecef66cbb4d4c8dd18157def75d46290ddc298395ea46f7ff64321c1a912cbad910160405180910390a1505b509392505050565b60008083601f84011261059857600080fd5b50813567ffffffffffffffff8111156105b057600080fd5b6020830191508360208285010111156105c857600080fd5b9250929050565b6000602082840312156105e157600080fd5b815180151581146105f157600080fd5b9392505050565b60008060006040848603121561060d57600080fd5b833567ffffffffffffffff81111561062457600080fd5b61063086828701610586565b909790965060209590950135949350505050565b6000806000806000806080878903121561065d57600080fd5b863567ffffffffffffffff8082111561067557600080fd5b6106818a838b01610586565b9098509650602089013595506040890135915061069d82610904565b909350606088013590808211156106b357600080fd5b506106c089828a01610586565b979a9699509497509295939492505050565b60008060008060008060006080888a0312156106ed57600080fd5b873567ffffffffffffffff8082111561070557600080fd5b6107118b838c01610586565b909950975060208a0135965060408a013591508082111561073157600080fd5b818a0191508a601f83011261074557600080fd5b81358181111561075457600080fd5b8b60208260051b850101111561076957600080fd5b6020830196508095505060608a013591508082111561078757600080fd5b506107948a828b01610586565b989b979a50959850939692959293505050565b6000806000606084860312156107bc57600080fd5b83356107c781610904565b925060208401356107d781610904565b929592945050506040919091013590565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b60408082528181018590526000906060808401600588901b8501820189855b8a8110156108e157878303605f190184528135368d9003605e1901811261085657600080fd5b8c01803561086381610904565b6001600160a01b03168452602081810135818601528782013536839003601e1901811261088f57600080fd5b8201803567ffffffffffffffff8111156108a857600080fd5b8036038413156108b757600080fd5b888a8801526108cb898801828585016107e8565b9783019796505050929092019150600101610830565b505085810360208701526108f681888a6107e8565b9a9950505050505050505050565b6001600160a01b038116811461091957600080fd5b5056fea2646970667358221220f2f7b8ae56f395f993ace824b61aafd112d10ad47a0003cd7de4bb4668d7da3d64736f6c63430008070033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000023c2c34f38ce66ccc10e71e9bb2a06532d52c5e9

-----Decoded View---------------
Arg [0] : allowed (address): 0x23C2c34f38ce66ccC10E71e9bB2A06532D52C5E9

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000023c2c34f38ce66ccc10e71e9bb2a06532d52c5e9


Deployed Bytecode Sourcemap

10928:3700:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11008:39;;;;;;;;-1:-1:-1;;;;;4705:32:1;;;4687:51;;4675:2;4660:18;11008:39:0;;;;;;;11520:252;;;;;;:::i;:::-;;:::i;:::-;;11820:1253;;;;;;:::i;:::-;;:::i;11119:92::-;;;;;;:::i;:::-;;:::i;13461:176::-;;;;;;:::i;:::-;;:::i;11520:252::-;11669:20;11700:22;11711:4;;11700:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;11717:4:0;;-1:-1:-1;11700:10:0;;-1:-1:-1;;11700:22:0:i;:::-;11728:39;;-1:-1:-1;;;11728:39:0;;11669:54;;-1:-1:-1;;;;;;11728:22:0;;;;;:39;;11751:4;;;;11757:9;;;;11728:39;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11664:108;11520:252;;;;;;;:::o;11820:1253::-;11929:22;11940:4;;11929:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;11946:4:0;;-1:-1:-1;11929:10:0;;-1:-1:-1;;11929:22:0:i;:::-;-1:-1:-1;11978:1:0;11964:15;;11956:36;;;;-1:-1:-1;;;11956:36:0;;8554:2:1;11956:36:0;;;8536:21:1;8593:1;8573:18;;;8566:29;-1:-1:-1;;;8611:18:1;;;8604:38;8659:18;;11956:36:0;;;;;;;;;12158:25;;-1:-1:-1;;;;;;12154:98:0;-1:-1:-1;;;12274:20:0;;;:92;;-1:-1:-1;;;;;;;;;;12346:20:0;;;12274:92;:208;;;-1:-1:-1;;;;;;;;;;12462:20:0;;;12274:208;:335;;;-1:-1:-1;;;;;;;;;;12589:20:0;;;12274:335;12261:465;;;;-1:-1:-1;;;12261:465:0;;7525:2:1;12261:465:0;;;7507:21:1;7564:2;7544:18;;;7537:30;-1:-1:-1;;;7583:18:1;;;7576:44;7637:18;;12261:465:0;7323:338:1;12261:465:0;12769:4;12763:11;12814;12801;12792:7;12779:47;12893:1;12890;12877:11;12868:7;12865:1;12857:6;12850:5;12845:50;12831:64;-1:-1:-1;12831:64:0;12916:133;;;;12902:162;;12916:133;12942:16;12981:4;12975:11;13015:4;13012:1;13007:3;12992:28;13038:4;13033:3;13026:17;12902:162;;;12742:327;11820:1253;;;;;;:::o;11119:92::-;11184:22;11195:4;;11184:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;11201:4:0;;-1:-1:-1;11184:10:0;;-1:-1:-1;;11184:22:0:i;:::-;;11119:92;;;:::o;13461:176::-;13548:10;-1:-1:-1;;;;;13562:14:0;13548:28;;13540:56;;;;-1:-1:-1;;;13540:56:0;;7181:2:1;13540:56:0;;;7163:21:1;7220:2;7200:18;;;7193:30;-1:-1:-1;;;7239:18:1;;;7232:45;7294:18;;13540:56:0;6979:339:1;13540:56:0;13601:31;;-1:-1:-1;;;13601:31:0;;-1:-1:-1;;;;;4941:32:1;;;13601:31:0;;;4923:51:1;4990:18;;;4983:34;;;13601:14:0;;;;;4896:18:1;;13601:31:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;13915:710::-;14114:15;;;;;;;;;;14062:68;;;-1:-1:-1;;;;;;14062:68:0;;;4306:39:1;14101:4:0;4382:2:1;4378:15;-1:-1:-1;;4374:53:1;4361:11;;;4354:74;4444:12;;;4437:28;;;4481:12;;;;4474:28;;;;14062:68:0;;;;;;;;;;4518:12:1;;14062:68:0;;14052:79;;;;;-1:-1:-1;;14176:25:0;;;14348:249;;14369:12;14447:4;14440;14434:11;14427:4;14421;14417:15;14414:1;14406:46;14398:54;-1:-1:-1;;;;;;14467:18:0;;14459:47;;;;-1:-1:-1;;;14459:47:0;;8209:2:1;14459:47:0;;;8191:21:1;8248:2;8228:18;;;8221:30;-1:-1:-1;;;8267:18:1;;;8260:46;8323:18;;14459:47:0;8007:340:1;14459:47:0;14528:12;-1:-1:-1;;;;;14520:20:0;:4;-1:-1:-1;;;;;14520:20:0;;14512:45;;;;-1:-1:-1;;;14512:45:0;;7868:2:1;14512:45:0;;;7850:21:1;7907:2;7887:18;;;7880:30;-1:-1:-1;;;7926:18:1;;;7919:42;7978:18;;14512:45:0;7666:336:1;14512:45:0;14568:23;;;-1:-1:-1;;;;;4941:32:1;;4923:51;;5005:2;4990:18;;4983:34;;;14568:23:0;;4896:18:1;14568:23:0;;;;;;;14363:234;14348:249;-1:-1:-1;14608:12:0;13915:710;-1:-1:-1;;;13915:710:0:o;14:347:1:-;65:8;75:6;129:3;122:4;114:6;110:17;106:27;96:55;;147:1;144;137:12;96:55;-1:-1:-1;170:20:1;;213:18;202:30;;199:50;;;245:1;242;235:12;199:50;282:4;274:6;270:17;258:29;;334:3;327:4;318:6;310;306:19;302:30;299:39;296:59;;;351:1;348;341:12;296:59;14:347;;;;;:::o;366:277::-;433:6;486:2;474:9;465:7;461:23;457:32;454:52;;;502:1;499;492:12;454:52;534:9;528:16;587:5;580:13;573:21;566:5;563:32;553:60;;609:1;606;599:12;553:60;632:5;366:277;-1:-1:-1;;;366:277:1:o;648:477::-;727:6;735;743;796:2;784:9;775:7;771:23;767:32;764:52;;;812:1;809;802:12;764:52;852:9;839:23;885:18;877:6;874:30;871:50;;;917:1;914;907:12;871:50;956:58;1006:7;997:6;986:9;982:22;956:58;:::i;:::-;1033:8;;930:84;;-1:-1:-1;1115:2:1;1100:18;;;;1087:32;;648:477;-1:-1:-1;;;;648:477:1:o;1130:921::-;1238:6;1246;1254;1262;1270;1278;1331:3;1319:9;1310:7;1306:23;1302:33;1299:53;;;1348:1;1345;1338:12;1299:53;1388:9;1375:23;1417:18;1458:2;1450:6;1447:14;1444:34;;;1474:1;1471;1464:12;1444:34;1513:58;1563:7;1554:6;1543:9;1539:22;1513:58;:::i;:::-;1590:8;;-1:-1:-1;1487:84:1;-1:-1:-1;1672:2:1;1657:18;;1644:32;;-1:-1:-1;1726:2:1;1711:18;;1698:32;;-1:-1:-1;1739:31:1;1698:32;1739:31;:::i;:::-;1789:5;;-1:-1:-1;1847:2:1;1832:18;;1819:32;;1863:16;;;1860:36;;;1892:1;1889;1882:12;1860:36;;1931:60;1983:7;1972:8;1961:9;1957:24;1931:60;:::i;:::-;1130:921;;;;-1:-1:-1;1130:921:1;;-1:-1:-1;1130:921:1;;2010:8;;1130:921;-1:-1:-1;;;1130:921:1:o;2056:1288::-;2221:6;2229;2237;2245;2253;2261;2269;2322:3;2310:9;2301:7;2297:23;2293:33;2290:53;;;2339:1;2336;2329:12;2290:53;2379:9;2366:23;2408:18;2449:2;2441:6;2438:14;2435:34;;;2465:1;2462;2455:12;2435:34;2504:58;2554:7;2545:6;2534:9;2530:22;2504:58;:::i;:::-;2581:8;;-1:-1:-1;2478:84:1;-1:-1:-1;2663:2:1;2648:18;;2635:32;;-1:-1:-1;2720:2:1;2705:18;;2692:32;;-1:-1:-1;2736:16:1;;;2733:36;;;2765:1;2762;2755:12;2733:36;2803:8;2792:9;2788:24;2778:34;;2850:7;2843:4;2839:2;2835:13;2831:27;2821:55;;2872:1;2869;2862:12;2821:55;2912:2;2899:16;2938:2;2930:6;2927:14;2924:34;;;2954:1;2951;2944:12;2924:34;3007:7;3002:2;2992:6;2989:1;2985:14;2981:2;2977:23;2973:32;2970:45;2967:65;;;3028:1;3025;3018:12;2967:65;3059:2;3055;3051:11;3041:21;;3081:6;3071:16;;;3140:2;3129:9;3125:18;3112:32;3096:48;;3169:2;3159:8;3156:16;3153:36;;;3185:1;3182;3175:12;3153:36;;3224:60;3276:7;3265:8;3254:9;3250:24;3224:60;:::i;:::-;2056:1288;;;;-1:-1:-1;2056:1288:1;;-1:-1:-1;2056:1288:1;;;;3198:86;;-1:-1:-1;;;2056:1288:1:o;3349:470::-;3440:6;3448;3456;3509:2;3497:9;3488:7;3484:23;3480:32;3477:52;;;3525:1;3522;3515:12;3477:52;3564:9;3551:23;3583:31;3608:5;3583:31;:::i;:::-;3633:5;-1:-1:-1;3690:2:1;3675:18;;3662:32;3703:33;3662:32;3703:33;:::i;:::-;3349:470;;3755:7;;-1:-1:-1;;;3809:2:1;3794:18;;;;3781:32;;3349:470::o;3824:266::-;3912:6;3907:3;3900:19;3964:6;3957:5;3950:4;3945:3;3941:14;3928:43;-1:-1:-1;4016:1:1;3991:16;;;4009:4;3987:27;;;3980:38;;;;4072:2;4051:15;;;-1:-1:-1;;4047:29:1;4038:39;;;4034:50;;3824:266::o;5028:1946::-;5323:2;5375:21;;;5348:18;;;5431:22;;;5294:4;;5472:2;5490:18;;;5554:1;5550:14;;;5535:30;;5531:39;;5593:6;5294:4;5627:1214;5641:6;5638:1;5635:13;5627:1214;;;5706:22;;;-1:-1:-1;;5702:36:1;5690:49;;5778:20;;5853:14;5849:27;;;-1:-1:-1;;5845:41:1;5821:66;;5811:94;;5901:1;5898;5891:12;5811:94;5931:31;;5990:19;;6022:33;5990:19;6022:33;:::i;:::-;-1:-1:-1;;;;;6083:33:1;6068:49;;6140:4;6194:14;;;6181:28;6164:15;;;6157:53;6264:14;;;6251:28;6336:14;6332:26;;;-1:-1:-1;;6328:40:1;6302:67;;6292:95;;6383:1;6380;6373:12;6292:95;6415:32;;6474:21;;6522:18;6511:30;;6508:50;;;6554:1;6551;6544:12;6508:50;6605:6;6589:14;6585:27;6578:5;6574:39;6571:59;;;6626:1;6623;6616:12;6571:59;6667:2;6662;6654:6;6650:15;6643:27;6693:68;6757:2;6749:6;6745:15;6737:6;6732:2;6723:7;6719:16;6693:68;:::i;:::-;6819:12;;;;6683:78;-1:-1:-1;;;6784:15:1;;;;;-1:-1:-1;5663:1:1;5656:9;5627:1214;;;5631:3;;6891:9;6883:6;6879:22;6872:4;6861:9;6857:20;6850:52;6919:49;6961:6;6953;6945;6919:49;:::i;:::-;6911:57;5028:1946;-1:-1:-1;;;;;;;;;;5028:1946:1:o;8688:131::-;-1:-1:-1;;;;;8763:31:1;;8753:42;;8743:70;;8809:1;8806;8799:12;8743:70;8688:131;:::o

Swarm Source

ipfs://f2f7b8ae56f395f993ace824b61aafd112d10ad47a0003cd7de4bb4668d7da3d

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
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.