Source Code
Overview
ETH Balance
0 ETH
Eth Value
$0.00| Transaction Hash |
Method
|
Block
|
From
|
|
To
|
||||
|---|---|---|---|---|---|---|---|---|---|
Latest 1 internal transaction
Advanced mode:
| Parent Transaction Hash | Method | Block |
From
|
|
To
|
||
|---|---|---|---|---|---|---|---|
| - | 12328081 | 1782 days ago | Contract Creation | 0 ETH |
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0x730A21fD...D89aa5F86 The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
BagSimple
Compiler Version
v0.5.12+commit.7709ece9
Contract Source Code (Solidity)
/**
*Submitted for verification at Etherscan.io on 2021-03-29
*/
pragma solidity ^0.5.12;
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
pragma solidity >=0.5.12;
contract LibNote {
event LogNote(
bytes4 indexed sig,
address indexed usr,
bytes32 indexed arg1,
bytes32 indexed arg2,
bytes data
) anonymous;
modifier note {
_;
assembly {
// log an 'anonymous' event with a constant 6 words of calldata
// and four indexed topics: selector, caller, arg1 and arg2
let mark := msize() // end of memory ensures zero
mstore(0x40, add(mark, 288)) // update free memory pointer
mstore(mark, 0x20) // bytes type data offset
mstore(add(mark, 0x20), 224) // bytes size (padded)
calldatacopy(add(mark, 0x40), 0, 224) // bytes payload
log4(
mark,
288, // calldata
shl(224, shr(224, calldataload(0))), // msg.sig
caller(), // msg.sender
calldataload(4), // arg1
calldataload(36) // arg2
)
}
}
}
contract Auth is LibNote {
mapping(address => uint256) public wards;
address public deployer;
function rely(address usr) external note auth {
wards[usr] = 1;
}
function deny(address usr) external note auth {
wards[usr] = 0;
}
modifier auth {
require(wards[msg.sender] == 1 || deployer == msg.sender, "Auth/not-authorized");
_;
}
}
pragma solidity ^0.5.0;
/**
* @dev Interface of the ERC20 standard as defined in the EIP. Does not include
* the optional functions; to access them see {ERC20Detailed}.
*/
interface IERC20 {
function decimals() external view returns (uint8);
/**
* @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);
function mint(address account, uint256 amount) external;
/**
* @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);
}
pragma solidity ^0.5.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, 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) {
return sub(a, b, "SafeMath: subtraction overflow");
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
* - Subtraction cannot overflow.
*
* _Available since v2.4.0._
*/
function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @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) {
// 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 0;
}
uint256 c = a * b;
require(c / a == b, "SafeMath: multiplication overflow");
return c;
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts 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) {
return div(a, b, "SafeMath: division by zero");
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts with custom message 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.
*
* _Available since v2.4.0._
*/
function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
// Solidity only automatically asserts when dividing by 0
require(b > 0, errorMessage);
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts 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) {
return mod(a, b, "SafeMath: modulo by zero");
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts with custom message 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.
*
* _Available since v2.4.0._
*/
function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b != 0, errorMessage);
return a % b;
}
function min(uint x, uint y) internal pure returns (uint z) {
return x <= y ? x : y;
}
}
interface VatLike {
function slip(
bytes32,
address,
int256
) external;
function move(
address,
address,
uint256
) external;
}
interface CurveGaugeWrapper {
function deposit(uint256 _value, address addr) external;
function withdraw(uint256 _value) external;
function set_approve_deposit(address addr, bool can_deposit) external;
function decimals() external view returns (uint8);
/**
* @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);
function mint(address account, uint256 amount) external;
/**
* @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);
}
interface CurveGauge {
function deposit(uint256 _value) external;
function withdraw(uint256 _value) external;
function lp_token() external view returns (address);
function minter() external view returns (address);
function crv_token() external view returns (address);
function voting_escrow() external view returns (address);
}
interface CurveGaugeReward {
function rewarded_token() external returns (address);
function claim_rewards(address addr) external;
}
interface Minter {
function mint(address gauge_addr) external;
}
interface VotingEscrow {
function create_lock(uint256 _value, uint256 _unlock_time) external;
function increase_amount(uint256 _value) external;
function increase_unlock_time(uint256 _unlock_time) external;
function withdraw() external;
}
contract Bag {
using SafeMath for uint256;
address public owner;
uint256 amnt;
constructor() public {
owner = msg.sender;
}
function claim(CurveGauge curveGauge, CurveGaugeReward curveGaugeReward) internal {
address minter = curveGauge.minter();
Minter(minter).mint(address(curveGauge));
if (address(curveGaugeReward) != address(0)) {
curveGaugeReward.claim_rewards(address(this));
}
}
function transferToken(uint256 wad, address token, address usr, uint256 total) internal {
uint256 tokenToTransfer = IERC20(token).balanceOf(address(this)).mul(wad).div(total);
require(IERC20(token).transfer(usr, tokenToTransfer), "GJFC/bag-failed-tkn-tran");
}
function exit(CurveGauge curveGauge, address gem, address usr, uint256 wad,
CurveGaugeReward curveGaugeReward) external {
require(owner == msg.sender, "GJFC/bag-exit-auth");
uint256 amntBefore = amnt;
amnt = amnt.sub(wad);
claim(curveGauge, curveGaugeReward);
transferToken(wad, curveGauge.crv_token(), usr, amntBefore);
if (address(curveGaugeReward) != address(0)) {
transferToken(wad, curveGaugeReward.rewarded_token(), usr, amntBefore);
}
curveGauge.withdraw(wad);
require(IERC20(gem).transfer(usr, wad), "GJFC/bag-failed-transfer");
}
function join(CurveGauge curveGauge, address gem, uint256 wad, CurveGaugeReward curveGaugeReward) external {
require(owner == msg.sender, "GJFC/bag-join-auth");
amnt = amnt.add(wad);
claim(curveGauge, curveGaugeReward);
IERC20(gem).approve(address(curveGauge), wad);
curveGauge.deposit(wad);
}
function init(CurveGauge curveGauge) external {
require(owner == msg.sender, "GJFC/bag-init-auth");
IERC20 crv = IERC20(curveGauge.crv_token());
crv.approve(curveGauge.voting_escrow(), uint256(-1));
}
function create_lock(CurveGauge curveGauge, uint256 _value, uint256 _unlock_time) external {
require(owner == msg.sender, "GJFC/bag-crt-auth");
VotingEscrow votingEscrow = VotingEscrow(curveGauge.voting_escrow());
votingEscrow.create_lock(_value, _unlock_time);
}
function increase_amount(CurveGauge curveGauge, uint256 _value) external {
require(owner == msg.sender, "GJFC/bag-inc-amnt-auth");
VotingEscrow votingEscrow = VotingEscrow(curveGauge.voting_escrow());
votingEscrow.increase_amount(_value);
}
function increase_unlock_time(CurveGauge curveGauge, uint256 _unlock_time) external {
require(owner == msg.sender, "GJFC/bag-inc-time-auth");
VotingEscrow votingEscrow = VotingEscrow(curveGauge.voting_escrow());
votingEscrow.increase_unlock_time(_unlock_time);
}
function withdraw(CurveGauge curveGauge, address usr) external {
require(owner == msg.sender, "GJFC/bag-with-auth");
VotingEscrow votingEscrow = VotingEscrow(curveGauge.voting_escrow());
votingEscrow.withdraw();
IERC20 crv = IERC20(curveGauge.crv_token());
require(
crv.transfer(usr, crv.balanceOf(address(this))),
"GJFC/failed-transfer"
);
}
}
/**
* @title MakerDAO like adapter for gem join
*
* see MakerDAO docs for details
*/
contract GemJoinForCurve is LibNote {
// --- Auth ---
mapping(address => uint256) public wards;
function rely(address usr) external note auth {
wards[usr] = 1;
}
function deny(address usr) external note auth {
wards[usr] = 0;
}
modifier auth {
require(wards[msg.sender] == 1, "GJFC/not-authorized");
_;
}
VatLike public vat; // CDP Engine
bytes32 public ilk; // Collateral Type
IERC20 public gem;
CurveGauge public curveGauge;
CurveGaugeReward public curveGaugeReward;
uint256 public dec;
uint256 public live; // Active Flag
mapping(address => address) public bags;
constructor(
address vat_,
bytes32 ilk_,
address curveGauge_,
bool withReward
) public {
wards[msg.sender] = 1;
live = 1;
vat = VatLike(vat_);
ilk = ilk_;
curveGauge = CurveGauge(curveGauge_);
if (withReward) {
curveGaugeReward = CurveGaugeReward(curveGauge_);
}
gem = IERC20(curveGauge.lp_token());
require(address(gem) != address(0));
dec = gem.decimals();
require(dec >= 18, "GJFC/decimals-18-or-higher");
}
function makeBag(address user) internal returns (address bag) {
if (bags[user] != address(0)) {
bag = bags[user];
} else {
Bag b = new Bag();
b.init(curveGauge);
bag = address(b);
bags[user] = bag;
}
}
function cage() external note auth {
live = 0;
}
function join(address urn, uint256 wad) external note {
require(live == 1, "GJFC/not-live");
require(int256(wad) >= 0, "GJFC/overflow");
vat.slip(ilk, urn, int256(wad));
address bag = makeBag(msg.sender);
require(
gem.transferFrom(msg.sender, bag, wad),
"GJFC/failed-transfer"
);
Bag(bag).join(curveGauge, address(gem), wad, curveGaugeReward);
}
function exit(address usr, uint256 wad) external note {
require(wad <= 2**255, "GJFC/overflow");
vat.slip(ilk, msg.sender, -int256(wad));
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
Bag(bag).exit(curveGauge, address(gem), usr, wad, curveGaugeReward);
}
function create_lock(uint256 _value, uint256 _unlock_time) external {
require(live == 1, "GJFC/not-live");
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
require(
IERC20(curveGauge.crv_token()).transferFrom(msg.sender, bag, _value),
"GJFC/failed-transfer"
);
Bag(bag).create_lock(curveGauge, _value, _unlock_time);
}
function increase_amount(uint256 _value) external {
require(live == 1, "GJFC/not-live");
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
require(
IERC20(curveGauge.crv_token()).transferFrom(msg.sender, bag, _value),
"GJFC/failed-transfer"
);
Bag(bag).increase_amount(curveGauge, _value);
}
function increase_unlock_time(uint256 _unlock_time) external {
require(live == 1, "GJFC/not-live");
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
Bag(bag).increase_unlock_time(curveGauge, _unlock_time);
}
function withdraw() external {
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
Bag(bag).withdraw(curveGauge, msg.sender);
}
}
contract BagSimple {
using SafeMath for uint256;
address public owner;
uint256 amnt;
constructor() public {
owner = msg.sender;
}
function claim(CurveGauge curveGauge) internal {
address minter = curveGauge.minter();
Minter(minter).mint(address(curveGauge));
}
function transferToken(uint256 wad, address token, address usr, uint256 total) internal {
uint256 tokenToTransfer = IERC20(token).balanceOf(address(this)).mul(wad).div(total);
require(IERC20(token).transfer(usr, tokenToTransfer), "GJFC/bag-failed-tkn-tran");
}
function exit(CurveGauge curveGauge, address gem, address usr, uint256 wad) external {
require(owner == msg.sender, "GJFC/bag-exit-auth");
uint256 amntBefore = amnt;
amnt = amnt.sub(wad);
claim(curveGauge);
transferToken(wad, curveGauge.crv_token(), usr, amntBefore);
curveGauge.withdraw(wad);
require(IERC20(gem).transfer(usr, wad), "GJFC/bag-failed-transfer");
}
function join(CurveGauge curveGauge, address gem, uint256 wad) external {
require(owner == msg.sender, "GJFC/bag-join-auth");
amnt = amnt.add(wad);
claim(curveGauge);
IERC20(gem).approve(address(curveGauge), wad);
curveGauge.deposit(wad);
}
function init(CurveGauge curveGauge) external {
require(owner == msg.sender, "GJFC/bag-init-auth");
IERC20 crv = IERC20(curveGauge.crv_token());
crv.approve(curveGauge.voting_escrow(), uint256(-1));
}
}
/**
* @title MakerDAO like adapter for gem join
*
* see MakerDAO docs for details
* simple optimized version with no boost
*/
contract GemJoinForCurveSimple is LibNote {
using SafeMath for uint256;
// --- Auth ---
mapping(address => uint256) public wards;
function rely(address usr) external note auth {
wards[usr] = 1;
}
function deny(address usr) external note auth {
wards[usr] = 0;
}
modifier auth {
require(wards[msg.sender] == 1, "GJFC/not-authorized");
_;
}
VatLike public vat; // CDP Engine
bytes32 public ilk; // Collateral Type
IERC20 public gem;
CurveGauge public curveGauge;
uint256 public dec;
uint256 public live; // Active Flag
uint256 public totalCollateral;
mapping(address => address) public bags;
constructor(
address vat_,
bytes32 ilk_,
address curveGauge_,
bool
) public {
wards[msg.sender] = 1;
live = 1;
vat = VatLike(vat_);
ilk = ilk_;
curveGauge = CurveGauge(curveGauge_);
gem = IERC20(curveGauge.lp_token());
require(address(gem) != address(0));
dec = gem.decimals();
require(dec >= 18, "GJFC/decimals-18-or-higher");
}
function makeBag(address user) internal returns (address bag) {
if (bags[user] != address(0)) {
bag = bags[user];
} else {
BagSimple b = new BagSimple();
b.init(curveGauge);
bag = address(b);
bags[user] = bag;
}
}
function cage() external note auth {
live = 0;
}
function join(address urn, uint256 wad) external note {
require(live == 1, "GJFC/not-live");
require(int256(wad) >= 0, "GJFC/overflow");
vat.slip(ilk, urn, int256(wad));
totalCollateral = totalCollateral.add(wad);
address bag = makeBag(msg.sender);
require(
gem.transferFrom(msg.sender, bag, wad),
"GJFC/failed-transfer"
);
BagSimple(bag).join(curveGauge, address(gem), wad);
}
function exit(address usr, uint256 wad) external note {
require(wad <= 2**255, "GJFC/overflow");
vat.slip(ilk, msg.sender, -int256(wad));
totalCollateral = totalCollateral.sub(wad);
address bag = bags[msg.sender];
require(bag != address(0), "GJFC/zero-bag");
BagSimple(bag).exit(curveGauge, address(gem), usr, wad);
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"constant":false,"inputs":[{"internalType":"contract CurveGauge","name":"curveGauge","type":"address"},{"internalType":"address","name":"gem","type":"address"},{"internalType":"address","name":"usr","type":"address"},{"internalType":"uint256","name":"wad","type":"uint256"}],"name":"exit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract CurveGauge","name":"curveGauge","type":"address"}],"name":"init","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"contract CurveGauge","name":"curveGauge","type":"address"},{"internalType":"address","name":"gem","type":"address"},{"internalType":"uint256","name":"wad","type":"uint256"}],"name":"join","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"}]Contract Creation Code
0x608060405234801561001057600080fd5b50600080546001600160a01b03191633179055610b3c806100326000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c806319ab453c146100515780637c2dc88a146100795780638da5cb5b146100b55780639f6c3dbd146100d9575b600080fd5b6100776004803603602081101561006757600080fd5b50356001600160a01b031661010f565b005b6100776004803603608081101561008f57600080fd5b506001600160a01b038135811691602081013582169160408201351690606001356102c3565b6100bd6104e8565b604080516001600160a01b039092168252519081900360200190f35b610077600480360360608110156100ef57600080fd5b506001600160a01b038135811691602081013590911690604001356104f7565b6000546001600160a01b03163314610163576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5ad2dcd2e85ac2eae8d60731b604482015290519081900360640190fd5b6000816001600160a01b03166376d8b1176040518163ffffffff1660e01b815260040160206040518083038186803b15801561019e57600080fd5b505afa1580156101b2573d6000803e3d6000fd5b505050506040513d60208110156101c857600080fd5b50516040805163dfe0503160e01b815290519192506001600160a01b038084169263095ea7b3929186169163dfe05031916004808301926020929190829003018186803b15801561021857600080fd5b505afa15801561022c573d6000803e3d6000fd5b505050506040513d602081101561024257600080fd5b5051604080516001600160e01b031960e085901b1681526001600160a01b03909216600483015260001960248301525160448083019260209291908290030181600087803b15801561029357600080fd5b505af11580156102a7573d6000803e3d6000fd5b505050506040513d60208110156102bd57600080fd5b50505050565b6000546001600160a01b03163314610317576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5acaf0d2e85ac2eae8d60731b604482015290519081900360640190fd5b60015461032a818363ffffffff61065b16565b600155610336856106a6565b6103a682866001600160a01b03166376d8b1176040518163ffffffff1660e01b815260040160206040518083038186803b15801561037357600080fd5b505afa158015610387573d6000803e3d6000fd5b505050506040513d602081101561039d57600080fd5b50518584610777565b846001600160a01b0316632e1a7d4d836040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156103ec57600080fd5b505af1158015610400573d6000803e3d6000fd5b50505050836001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561046457600080fd5b505af1158015610478573d6000803e3d6000fd5b505050506040513d602081101561048e57600080fd5b50516104e1576040805162461bcd60e51b815260206004820152601860248201527f474a46432f6261672d6661696c65642d7472616e736665720000000000000000604482015290519081900360640190fd5b5050505050565b6000546001600160a01b031681565b6000546001600160a01b0316331461054b576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5ad4ded2dc5ac2eae8d60731b604482015290519081900360640190fd5b60015461055e908263ffffffff6108fa16565b60015561056a836106a6565b816001600160a01b031663095ea7b384836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156105ca57600080fd5b505af11580156105de573d6000803e3d6000fd5b505050506040513d60208110156105f457600080fd5b50506040805163b6b55f2560e01b81526004810183905290516001600160a01b0385169163b6b55f2591602480830192600092919082900301818387803b15801561063e57600080fd5b505af1158015610652573d6000803e3d6000fd5b50505050505050565b600061069d83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610954565b90505b92915050565b6000816001600160a01b031663075461726040518163ffffffff1660e01b815260040160206040518083038186803b1580156106e157600080fd5b505afa1580156106f5573d6000803e3d6000fd5b505050506040513d602081101561070b57600080fd5b5051604080516335313c2160e11b81526001600160a01b038581166004830152915192935090831691636a6278429160248082019260009290919082900301818387803b15801561075b57600080fd5b505af115801561076f573d6000803e3d6000fd5b505050505050565b600061081b8261080f87876001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156107d757600080fd5b505afa1580156107eb573d6000803e3d6000fd5b505050506040513d602081101561080157600080fd5b50519063ffffffff6109eb16565b9063ffffffff610a4416565b9050836001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561087d57600080fd5b505af1158015610891573d6000803e3d6000fd5b505050506040513d60208110156108a757600080fd5b50516104e1576040805162461bcd60e51b815260206004820152601860248201527f474a46432f6261672d6661696c65642d746b6e2d7472616e0000000000000000604482015290519081900360640190fd5b60008282018381101561069d576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b600081848411156109e35760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156109a8578181015183820152602001610990565b50505050905090810190601f1680156109d55780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6000826109fa575060006106a0565b82820282848281610a0757fe5b041461069d5760405162461bcd60e51b8152600401808060200182810382526021815260200180610ae76021913960400191505060405180910390fd5b600061069d83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525060008183610ad05760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156109a8578181015183820152602001610990565b506000838581610adc57fe5b049594505050505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a265627a7a723158204eb8bb0f3212d2efec419345930702f875dab393305226b8e6fdd0d8e863839264736f6c634300050c0032
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806319ab453c146100515780637c2dc88a146100795780638da5cb5b146100b55780639f6c3dbd146100d9575b600080fd5b6100776004803603602081101561006757600080fd5b50356001600160a01b031661010f565b005b6100776004803603608081101561008f57600080fd5b506001600160a01b038135811691602081013582169160408201351690606001356102c3565b6100bd6104e8565b604080516001600160a01b039092168252519081900360200190f35b610077600480360360608110156100ef57600080fd5b506001600160a01b038135811691602081013590911690604001356104f7565b6000546001600160a01b03163314610163576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5ad2dcd2e85ac2eae8d60731b604482015290519081900360640190fd5b6000816001600160a01b03166376d8b1176040518163ffffffff1660e01b815260040160206040518083038186803b15801561019e57600080fd5b505afa1580156101b2573d6000803e3d6000fd5b505050506040513d60208110156101c857600080fd5b50516040805163dfe0503160e01b815290519192506001600160a01b038084169263095ea7b3929186169163dfe05031916004808301926020929190829003018186803b15801561021857600080fd5b505afa15801561022c573d6000803e3d6000fd5b505050506040513d602081101561024257600080fd5b5051604080516001600160e01b031960e085901b1681526001600160a01b03909216600483015260001960248301525160448083019260209291908290030181600087803b15801561029357600080fd5b505af11580156102a7573d6000803e3d6000fd5b505050506040513d60208110156102bd57600080fd5b50505050565b6000546001600160a01b03163314610317576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5acaf0d2e85ac2eae8d60731b604482015290519081900360640190fd5b60015461032a818363ffffffff61065b16565b600155610336856106a6565b6103a682866001600160a01b03166376d8b1176040518163ffffffff1660e01b815260040160206040518083038186803b15801561037357600080fd5b505afa158015610387573d6000803e3d6000fd5b505050506040513d602081101561039d57600080fd5b50518584610777565b846001600160a01b0316632e1a7d4d836040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156103ec57600080fd5b505af1158015610400573d6000803e3d6000fd5b50505050836001600160a01b031663a9059cbb84846040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561046457600080fd5b505af1158015610478573d6000803e3d6000fd5b505050506040513d602081101561048e57600080fd5b50516104e1576040805162461bcd60e51b815260206004820152601860248201527f474a46432f6261672d6661696c65642d7472616e736665720000000000000000604482015290519081900360640190fd5b5050505050565b6000546001600160a01b031681565b6000546001600160a01b0316331461054b576040805162461bcd60e51b815260206004820152601260248201527108e948c865ec4c2ce5ad4ded2dc5ac2eae8d60731b604482015290519081900360640190fd5b60015461055e908263ffffffff6108fa16565b60015561056a836106a6565b816001600160a01b031663095ea7b384836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156105ca57600080fd5b505af11580156105de573d6000803e3d6000fd5b505050506040513d60208110156105f457600080fd5b50506040805163b6b55f2560e01b81526004810183905290516001600160a01b0385169163b6b55f2591602480830192600092919082900301818387803b15801561063e57600080fd5b505af1158015610652573d6000803e3d6000fd5b50505050505050565b600061069d83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610954565b90505b92915050565b6000816001600160a01b031663075461726040518163ffffffff1660e01b815260040160206040518083038186803b1580156106e157600080fd5b505afa1580156106f5573d6000803e3d6000fd5b505050506040513d602081101561070b57600080fd5b5051604080516335313c2160e11b81526001600160a01b038581166004830152915192935090831691636a6278429160248082019260009290919082900301818387803b15801561075b57600080fd5b505af115801561076f573d6000803e3d6000fd5b505050505050565b600061081b8261080f87876001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156107d757600080fd5b505afa1580156107eb573d6000803e3d6000fd5b505050506040513d602081101561080157600080fd5b50519063ffffffff6109eb16565b9063ffffffff610a4416565b9050836001600160a01b031663a9059cbb84836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561087d57600080fd5b505af1158015610891573d6000803e3d6000fd5b505050506040513d60208110156108a757600080fd5b50516104e1576040805162461bcd60e51b815260206004820152601860248201527f474a46432f6261672d6661696c65642d746b6e2d7472616e0000000000000000604482015290519081900360640190fd5b60008282018381101561069d576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b600081848411156109e35760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156109a8578181015183820152602001610990565b50505050905090810190601f1680156109d55780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6000826109fa575060006106a0565b82820282848281610a0757fe5b041461069d5760405162461bcd60e51b8152600401808060200182810382526021815260200180610ae76021913960400191505060405180910390fd5b600061069d83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525060008183610ad05760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156109a8578181015183820152602001610990565b506000838581610adc57fe5b049594505050505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a265627a7a723158204eb8bb0f3212d2efec419345930702f875dab393305226b8e6fdd0d8e863839264736f6c634300050c0032
Deployed Bytecode Sourcemap
22057:1616:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22057:1616:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23438:232;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;23438:232:0;-1:-1:-1;;;;;23438:232:0;;:::i;:::-;;22686:440;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;-1:-1;;;;;;22686:440:0;;;;;;;;;;;;;;;;;;;;;;:::i;22120:20::-;;;:::i;:::-;;;;-1:-1:-1;;;;;22120:20:0;;;;;;;;;;;;;;23134:296;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;;;23134:296:0;;;;;;;;;;;;;;;;;:::i;23438:232::-;23503:5;;-1:-1:-1;;;;;23503:5:0;23512:10;23503:19;23495:50;;;;;-1:-1:-1;;;23495:50:0;;;;;;;;;;;;-1:-1:-1;;;23495:50:0;;;;;;;;;;;;;;;23556:10;23576;-1:-1:-1;;;;;23576:20:0;;:22;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23576:22:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23576:22:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;23576:22:0;23622:26;;;-1:-1:-1;;;23622:26:0;;;;23576:22;;-1:-1:-1;;;;;;23610:11:0;;;;;;23622:24;;;;-1:-1:-1;;23622:26:0;;;;;23576:22;;23622:26;;;;;;;:24;:26;;;5:2:-1;;;;30:1;27;20:12;5:2;23622:26:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23622:26:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;23622:26:0;23610:52;;;-1:-1:-1;23610:52:0;;;-1:-1:-1;;;;;;23610:52:0;;;-1:-1:-1;;;;;23610:52:0;;;;;;;-1:-1:-1;;23610:52:0;;;;;;;;;;23622:26;;23610:52;;;;;;;-1:-1:-1;23610:52:0;;;;5:2:-1;;;;30:1;27;20:12;5:2;23610:52:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23610:52:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;;;23438:232:0:o;22686:440::-;22790:5;;-1:-1:-1;;;;;22790:5:0;22799:10;22790:19;22782:50;;;;;-1:-1:-1;;;22782:50:0;;;;;;;;;;;;-1:-1:-1;;;22782:50:0;;;;;;;;;;;;;;;22866:4;;22888:13;22866:4;22897:3;22888:13;:8;:13;:::i;:::-;22881:4;:20;22914:17;22920:10;22914:5;:17::i;:::-;22944:59;22958:3;22963:10;-1:-1:-1;;;;;22963:20:0;;:22;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22963:22:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22963:22:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;22963:22:0;22987:3;22992:10;22944:13;:59::i;:::-;23014:24;;;-1:-1:-1;;;23014:24:0;;;;;;;;;;-1:-1:-1;;;;;23014:19:0;;;;;:24;;;;;-1:-1:-1;;23014:24:0;;;;;;;-1:-1:-1;23014:19:0;:24;;;5:2:-1;;;;30:1;27;20:12;5:2;23014:24:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;-1:-1;;23059:30:0;;;-1:-1:-1;;;23059:30:0;;-1:-1:-1;;;;;23059:30:0;;;;;;;;;;;;;;;:20;;;;-1:-1:-1;23059:20:0;;-1:-1:-1;23059:30:0;;;;;;;;;;;;;;;-1:-1:-1;23059:20:0;:30;;;5:2:-1;;;;30:1;27;20:12;5:2;23059:30:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23059:30:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;23059:30:0;23051:67;;;;;-1:-1:-1;;;23051:67:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;22686:440;;;;;:::o;22120:20::-;;;-1:-1:-1;;;;;22120:20:0;;:::o;23134:296::-;23225:5;;-1:-1:-1;;;;;23225:5:0;23234:10;23225:19;23217:50;;;;;-1:-1:-1;;;23217:50:0;;;;;;;;;;;;-1:-1:-1;;;23217:50:0;;;;;;;;;;;;;;;23287:4;;:13;;23296:3;23287:13;:8;:13;:::i;:::-;23280:4;:20;23311:17;23317:10;23311:5;:17::i;:::-;23343:45;;;-1:-1:-1;;;23343:45:0;;-1:-1:-1;;;;;23343:45:0;;;;;;;;;;;;;;;:19;;;;;;:45;;;;;;;;;;;;;;;-1:-1:-1;23343:19:0;:45;;;5:2:-1;;;;30:1;27;20:12;5:2;23343:45:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23343:45:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;;23399:23:0;;;-1:-1:-1;;;23399:23:0;;;;;;;;;;-1:-1:-1;;;;;23399:18:0;;;-1:-1:-1;;23399:23:0;;;;;-1:-1:-1;;23399:23:0;;;;;;;-1:-1:-1;23399:18:0;:23;;;5:2:-1;;;;30:1;27;20:12;5:2;23399:23:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23399:23:0;;;;23134:296;;;:::o;6456:136::-;6514:7;6541:43;6545:1;6548;6541:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;6534:50;;6456:136;;;;;:::o;22234:153::-;22292:14;22309:10;-1:-1:-1;;;;;22309:17:0;;:19;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22309:19:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22309:19:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;22309:19:0;22339:40;;;-1:-1:-1;;;22339:40:0;;-1:-1:-1;;;;;22339:40:0;;;;;;;;;22309:19;;-1:-1:-1;22339:19:0;;;;;;:40;;;;;-1:-1:-1;;22339:40:0;;;;;;;;-1:-1:-1;22339:19:0;:40;;;5:2:-1;;;;30:1;27;20:12;5:2;22339:40:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22339:40:0;;;;22234:153;;:::o;22395:283::-;22520:38;;;-1:-1:-1;;;22520:38:0;;22552:4;22520:38;;;;;;22494:23;;22520:58;;22572:5;;22520:47;;22563:3;;-1:-1:-1;;;;;22520:23:0;;;;;:38;;;;;;;;;;;;;;;:23;:38;;;5:2:-1;;;;30:1;27;20:12;5:2;22520:38:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22520:38:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;22520:38:0;;:47;:42;:47;:::i;:::-;:51;:58;:51;:58;:::i;:::-;22597:44;;;-1:-1:-1;;;22597:44:0;;-1:-1:-1;;;;;22597:44:0;;;;;;;;;;;;;;;22494:84;;-1:-1:-1;22597:22:0;;;;;;:44;;;;;;;;;;;;;;;-1:-1:-1;22597:22:0;:44;;;5:2:-1;;;;30:1;27;20:12;5:2;22597:44:0;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22597:44:0;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;-1:-1;22597:44:0;22589:81;;;;;-1:-1:-1;;;22589:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;6000:181;6058:7;6090:5;;;6114:6;;;;6106:46;;;;;-1:-1:-1;;;6106:46:0;;;;;;;;;;;;;;;;;;;;;;;;;;;6929:192;7015:7;7051:12;7043:6;;;;7035:29;;;;-1:-1:-1;;;7035:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:100:-1;33:3;30:1;27:10;8:100;;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;;12:14;7035:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;7087:5:0;;;6929:192::o;7372:471::-;7430:7;7675:6;7671:47;;-1:-1:-1;7705:1:0;7698:8;;7671:47;7742:5;;;7746:1;7742;:5;:1;7766:5;;;;;:10;7758:56;;;;-1:-1:-1;;;7758:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8311:132;8369:7;8396:39;8400:1;8403;8396:39;;;;;;;;;;;;;;;;;9059:7;9161:12;9154:5;9146:28;;;;-1:-1:-1;;;9146:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;27:10;;8:100;;90:11;;;84:18;71:11;;;64:39;52:2;45:10;8:100;;9146:28:0;;9185:9;9201:1;9197;:5;;;;;;;8973:345;-1:-1:-1;;;;;8973:345:0:o
Swarm Source
bzzr://4eb8bb0f3212d2efec419345930702f875dab393305226b8e6fdd0d8e8638392
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 33 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ 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.