Overview
S Balance
0 S
S Value
-More Info
Private Name Tags
ContractCreator
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
CircleTokenAdapter
Compiler Version
v0.8.27+commit.40a35a09
Optimization Enabled:
Yes with 200 runs
Other Settings:
cancun EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.27; import "./interfaces/ICircleToken.sol"; import "./interfaces/IMintedBurnableERC20.sol"; /// Adapter in between a Circle stablecoin (USDC/EURC) and the Bridge contract. /// Implements methods required in tokens by the Bridge, translates their calls /// to calling methods of the target stablecoin. /// The contract should be deployable as implementation of deprecated FiatToken, /// therefore it must be careful in using any storage. contract CircleTokenAdapter is IMintedBurnableERC20 { // All variables should be immutable to be compiled into the contract bytecode. ICircleFiatToken public immutable token; address public immutable bridge; constructor(ICircleFiatToken _token, address _bridge) { require(address(_token) != address(0), "Token not set"); require(_bridge != address(0), "Bridge not set"); token = _token; bridge = _bridge; } /// @notice Mint fiat tokens to an address. /// @param account The address that will receive the minted tokens. /// @param amount The amount of tokens to mint. /// @return True if the operation was successful. function mint(address account, uint256 amount) external returns (bool) { require(msg.sender == bridge, "Sender is not bridge"); return token.mint(account, amount); } /// @notice Burn tokens from `account` account. /// @param account The address whose tokens will be burned. /// @param value the amount of tokens to be burned. function burnFrom(address account, uint256 value) external { require(msg.sender == bridge, "Sender is not bridge"); require(token.transferFrom(account, address(this), value), "TransferFrom failed"); token.burn(value); } /// Unsupported - only for compliance with IMintedBurnableERC20 interface. function burn(uint256) external pure { revert("Burn unsupported"); } }
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.27; /// Circle's FiatToken interface. interface ICircleFiatToken { function mint(address _to, uint256 _amount) external returns (bool); function burn(uint256 _amount) external; function transferFrom(address from, address to, uint256 value) external returns (bool); }
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.27; /// Minted ERC-20 tokens represents an Ethereum ERC-20 tokens on L2. interface IMintedBurnableERC20 { function mint(address account, uint256 amount) external returns (bool); function burn(uint256 value) external; function burnFrom(address account, uint256 value) external; }
{ "evmVersion": "cancun", "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"contract ICircleFiatToken","name":"_token","type":"address"},{"internalType":"address","name":"_bridge","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"bridge","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"burnFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract ICircleFiatToken","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60c060405234801561000f575f5ffd5b5060405161061f38038061061f83398101604081905261002e916100ee565b6001600160a01b0382166100795760405162461bcd60e51b815260206004820152600d60248201526c151bdad95b881b9bdd081cd95d609a1b60448201526064015b60405180910390fd5b6001600160a01b0381166100c05760405162461bcd60e51b815260206004820152600e60248201526d109c9a5919d9481b9bdd081cd95d60921b6044820152606401610070565b6001600160a01b039182166080521660a052610126565b6001600160a01b03811681146100eb575f5ffd5b50565b5f5f604083850312156100ff575f5ffd5b825161010a816100d7565b602084015190925061011b816100d7565b809150509250929050565b60805160a0516104b76101685f395f818160ae0152818161011b015261026101525f818160ed015281816101aa015281816102f101526103b301526104b75ff3fe608060405234801561000f575f5ffd5b5060043610610055575f3560e01c806340c10f191461005957806342966c681461008157806379cc679014610096578063e78cea92146100a9578063fc0c546a146100e8575b5f5ffd5b61006c610067366004610416565b61010f565b60405190151581526020015b60405180910390f35b61009461008f36600461044b565b61021b565b005b6100946100a4366004610416565b610256565b6100d07f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b039091168152602001610078565b6100d07f000000000000000000000000000000000000000000000000000000000000000081565b5f336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146101845760405162461bcd60e51b815260206004820152601460248201527353656e646572206973206e6f742062726964676560601b60448201526064015b60405180910390fd5b6040516340c10f1960e01b81526001600160a01b038481166004830152602482018490527f000000000000000000000000000000000000000000000000000000000000000016906340c10f19906044016020604051808303815f875af11580156101f0573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906102149190610462565b9392505050565b60405162461bcd60e51b815260206004820152601060248201526f109d5c9b881d5b9cdd5c1c1bdc9d195960821b604482015260640161017b565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146102c55760405162461bcd60e51b815260206004820152601460248201527353656e646572206973206e6f742062726964676560601b604482015260640161017b565b6040516323b872dd60e01b81526001600160a01b038381166004830152306024830152604482018390527f000000000000000000000000000000000000000000000000000000000000000016906323b872dd906064016020604051808303815f875af1158015610337573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061035b9190610462565b61039d5760405162461bcd60e51b8152602060048201526013602482015272151c985b9cd9995c919c9bdb4819985a5b1959606a1b604482015260640161017b565b604051630852cd8d60e31b8152600481018290527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906342966c68906024015f604051808303815f87803b1580156103fc575f5ffd5b505af115801561040e573d5f5f3e3d5ffd5b505050505050565b5f5f60408385031215610427575f5ffd5b82356001600160a01b038116811461043d575f5ffd5b946020939093013593505050565b5f6020828403121561045b575f5ffd5b5035919050565b5f60208284031215610472575f5ffd5b81518015158114610214575f5ffdfea26469706673582212205b5265f4b5e1cc5a2f5ef50a58b190e05dce19856cb2dfcf207037b4bbb8f65364736f6c634300081b0033000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e57000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e23336387
Deployed Bytecode
0x608060405234801561000f575f5ffd5b5060043610610055575f3560e01c806340c10f191461005957806342966c681461008157806379cc679014610096578063e78cea92146100a9578063fc0c546a146100e8575b5f5ffd5b61006c610067366004610416565b61010f565b60405190151581526020015b60405180910390f35b61009461008f36600461044b565b61021b565b005b6100946100a4366004610416565b610256565b6100d07f000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e2333638781565b6040516001600160a01b039091168152602001610078565b6100d07f000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e5781565b5f336001600160a01b037f000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e2333638716146101845760405162461bcd60e51b815260206004820152601460248201527353656e646572206973206e6f742062726964676560601b60448201526064015b60405180910390fd5b6040516340c10f1960e01b81526001600160a01b038481166004830152602482018490527f000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e5716906340c10f19906044016020604051808303815f875af11580156101f0573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906102149190610462565b9392505050565b60405162461bcd60e51b815260206004820152601060248201526f109d5c9b881d5b9cdd5c1c1bdc9d195960821b604482015260640161017b565b336001600160a01b037f000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e2333638716146102c55760405162461bcd60e51b815260206004820152601460248201527353656e646572206973206e6f742062726964676560601b604482015260640161017b565b6040516323b872dd60e01b81526001600160a01b038381166004830152306024830152604482018390527f000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e5716906323b872dd906064016020604051808303815f875af1158015610337573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061035b9190610462565b61039d5760405162461bcd60e51b8152602060048201526013602482015272151c985b9cd9995c919c9bdb4819985a5b1959606a1b604482015260640161017b565b604051630852cd8d60e31b8152600481018290527f000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e576001600160a01b0316906342966c68906024015f604051808303815f87803b1580156103fc575f5ffd5b505af115801561040e573d5f5f3e3d5ffd5b505050505050565b5f5f60408385031215610427575f5ffd5b82356001600160a01b038116811461043d575f5ffd5b946020939093013593505050565b5f6020828403121561045b575f5ffd5b5035919050565b5f60208284031215610472575f5ffd5b81518015158114610214575f5ffdfea26469706673582212205b5265f4b5e1cc5a2f5ef50a58b190e05dce19856cb2dfcf207037b4bbb8f65364736f6c634300081b0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e57000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e23336387
-----Decoded View---------------
Arg [0] : _token (address): 0xe715cbA7B5cCb33790ceBFF1436809d36cb17E57
Arg [1] : _bridge (address): 0xb903716B3DD10b0115E93eb29D8Eb99e23336387
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000e715cba7b5ccb33790cebff1436809d36cb17e57
Arg [1] : 000000000000000000000000b903716b3dd10b0115e93eb29d8eb99e23336387
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
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.