Contract Overview
Latest 25 from a total of 8206862 transactions
Contract Name:
GFT
Compiler Version
v0.5.5+commit.47a71e8f
pragma solidity ^0.5.0; import "./math/SafeMath.sol"; import "./token/IERC20.sol"; import "./token/IERC223.sol"; import "./token/ISmartToken.sol"; import "./token/DSToken.sol"; import "./token/IApproveAndCallFallBack.sol"; import "./token/ITokenController.sol"; import "./token/IERC223Receiving.sol"; contract GFT is DSToken("GFT", "Game Fantasy Token"), IERC223, ISmartToken { using SafeMath for uint256; address private _newOwner; bool public _transfersEnabled = true; // true if transfer/transferFrom are enabled, false if not uint256 private _cap; address private _controller; // allows execution only when transfers aren't disabled modifier transfersAllowed() { assert(_transfersEnabled); _; } constructor() public { _controller = msg.sender; uint256 perCoin = 1e18; _cap = perCoin.mul(3000 * 10000); } ////////// // IOwned Methods ////////// /** @dev allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner @param newOwner_ new contract owner */ function transferOwnership(address newOwner_) public auth { require(newOwner_ != _owner, "GFT-already-an-owner"); _newOwner = newOwner_; } /** @dev used by a new owner to accept an ownership transfer */ function acceptOwnership() public { require(msg.sender == _newOwner, "GFT-not-new-owner"); _owner = _newOwner; _newOwner = address(0); } ////////// // SmartToken Methods ////////// /** @dev disables/enables transfers can only be called by the contract owner @param disable_ true to disable transfers, false to enable them */ function disableTransfers(bool disable_) public auth { _transfersEnabled = !disable_; } function issue(address to_, uint256 amount_) public auth stoppable { mint(to_, amount_); } ////////// // Cap Methods ////////// function cap() public view returns (uint256) { return _cap; } ////////// // Controller Methods ////////// /// @notice Changes the _controller of the contract /// @param newController_ The new _controller of the contract function changeController(address newController_) public auth { _controller = newController_; } /// @notice Send `amount_` tokens to `to_` from `from_` on the condition it /// is approved by `from_` /// @param from_ The address holding the tokens being transferred /// @param to_ The address of the recipient /// @param amount_ The amount of tokens to be transferred /// @return True if the transfer was successful function transferFrom( address from_, address to_, uint256 amount_ ) public transfersAllowed returns (bool success) { // Alerts the token _controller of the transfer if (isContract(_controller)) { if (!ITokenController(_controller).onTransfer(from_, to_, amount_)) revert(); } success = super.transferFrom(from_, to_, amount_); } /* * ERC 223 * Added support for the ERC 223 "tokenFallback" method in a "transfer" function with a payload. */ function transferFrom( address from_, address to_, uint256 amount_, bytes memory data_ ) public transfersAllowed returns (bool success) { // Alerts the token _controller of the transfer if (isContract(_controller)) { if (!ITokenController(_controller).onTransfer(from_, to_, amount_)) revert(); } require( super.transferFrom(from_, to_, amount_), "GFT-insufficient-balance" ); if (isContract(to_)) { IERC223Receiving receiver = IERC223Receiving(to_); receiver.tokenFallback(from_, amount_, data_); } emit ERC223Transfer(from_, to_, amount_, data_); return true; } /* * ERC 223 * Added support for the ERC 223 "tokenFallback" method in a "transfer" function with a payload. * https://github.com/ethereum/EIPs/issues/223 * function transfer(address to_, uint256 value_, bytes memory data_) public returns (bool success); */ /// @notice Send `value_` tokens to `to_` from `msg.sender` and trigger /// tokenFallback if sender is a contract. /// @dev Function that is called when a user or another contract wants to transfer funds. /// @param to_ Address of token receiver. /// @param amount_ Number of tokens to transfer. /// @param data_ Data to be sent to tokenFallback /// @return Returns success of function call. function transfer( address to_, uint256 amount_, bytes memory data_ ) public returns (bool success) { return transferFrom(msg.sender, to_, amount_, data_); } /// @notice `msg.sender` approves `spender_` to spend `amount_` tokens on /// its behalf. This is a modified version of the ERC20 approve function /// to be a little bit safer /// @param spender_ The address of the account able to transfer the tokens /// @param amount_ The amount of tokens to be approved for transfer /// @return True if the approval was successful function approve(address spender_, uint256 amount_) public returns (bool success) { // Alerts the token _controller of the approve function call if (isContract(_controller)) { if ( !ITokenController(_controller).onApprove( msg.sender, spender_, amount_ ) ) revert(); } return super.approve(spender_, amount_); } function mint(address guy_, uint256 wad_) public auth stoppable { require(totalSupply().add(wad_) <= _cap, "GFT-insufficient-cap"); super.mint(guy_, wad_); emit Transfer(address(0), guy_, wad_); } function burn(address guy_, uint256 wad_) public auth stoppable { super.burn(guy_, wad_); emit Transfer(guy_, address(0), wad_); } /// @notice `msg.sender` approves `spender_` to send `amount_` tokens on /// its behalf, and then a function is triggered in the contract that is /// being approved, `spender_`. This allows users to use their tokens to /// interact with contracts in one function call instead of two /// @param spender_ The address of the contract able to transfer the tokens /// @param amount_ The amount of tokens to be approved for transfer /// @return True if the function call was successful function approveAndCall( address spender_, uint256 amount_, bytes memory extraData_ ) public returns (bool success) { if (!approve(spender_, amount_)) revert(); IApproveAndCallFallBack(spender_).receiveApproval( msg.sender, amount_, address(this), extraData_ ); return true; } /// @dev Internal function to determine if an address is a contract /// @param addr_ The address being queried /// @return True if `addr_` is a contract function isContract(address addr_) internal view returns (bool) { uint256 size; if (addr_ == address(0)) return false; assembly { size := extcodesize(addr_) } return size > 0; } /// @notice The fallback function: If the contract's _controller has not been /// set to 0, then the `proxyPayment` method is called which relays the /// ether and creates tokens as described in the token _controller contract function() external payable { if (isContract(_controller)) { if ( !ITokenController(_controller).proxyPayment.value(msg.value)( msg.sender, msg.sig, msg.data ) ) revert(); } else { revert(); } } ////////// // Safety Methods ////////// /// @notice This method can be used by the owner to extract mistakenly /// sent tokens to this contract. /// @param token_ The address of the token contract that you want to recover /// set to 0 in case you want to extract ether. function claimTokens(address token_) public auth { if (token_ == address(0)) { address(msg.sender).transfer(address(this).balance); return; } IERC20 token = IERC20(token_); uint256 balance = token.balanceOf(address(this)); token.transfer(address(msg.sender), balance); emit ClaimedTokens(token_, address(msg.sender), balance); } function withdrawTokens( IERC20 token_, address to_, uint256 amount_ ) public auth { assert(token_.transfer(to_, amount_)); } //////////////// // Events //////////////// event ClaimedTokens( address indexed token_, address indexed controller_, uint256 amount_ ); }
pragma solidity <0.6.0 >=0.4.21; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. */ /*@CTK SafeMath_mul @tag spec @post __reverted == __has_assertion_failure @post __has_assertion_failure == __has_overflow @post __reverted == false -> c == a * b @post msg == msg__post */ /* CertiK Smart Labelling, for more details visit: https://certik.org */ function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { if (a == 0) { return 0; } c = a * b; assert(c / a == b); return c; } /** * @dev Integer division of two numbers, truncating the quotient. */ /*@CTK SafeMath_div @tag spec @pre b != 0 @post __reverted == __has_assertion_failure @post __has_overflow == true -> __has_assertion_failure == true @post __reverted == false -> __return == a / b @post msg == msg__post */ /* CertiK Smart Labelling, for more details visit: https://certik.org */ function div(uint256 a, uint256 b) internal pure returns (uint256) { // assert(b > 0); // Solidity automatically throws when dividing by 0 // uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return a / b; } /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ /*@CTK SafeMath_sub @tag spec @post __reverted == __has_assertion_failure @post __has_overflow == true -> __has_assertion_failure == true @post __reverted == false -> __return == a - b @post msg == msg__post */ /* CertiK Smart Labelling, for more details visit: https://certik.org */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { assert(b <= a); return a - b; } /** * @dev Adds two numbers, throws on overflow. */ /*@CTK SafeMath_add @tag spec @post __reverted == __has_assertion_failure @post __has_assertion_failure == __has_overflow @post __reverted == false -> c == a + b @post msg == msg__post */ /* CertiK Smart Labelling, for more details visit: https://certik.org */ function add(uint256 a, uint256 b) internal pure returns (uint256 c) { c = a + b; assert(c >= a); return c; } }
pragma solidity <0.6.0 >=0.4.21; /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract IERC20Basic { function totalSupply() public view returns (uint256); function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); }
pragma solidity <0.6.0 >=0.4.21; interface IERC223 { function transfer( address to, uint256 amount, bytes calldata data ) external returns (bool ok); function transferFrom( address from, address to, uint256 amount, bytes calldata data ) external returns (bool ok); event ERC223Transfer( address indexed from, address indexed to, uint256 amount, bytes data ); }
pragma solidity <0.6.0 >=0.4.21; interface ISmartToken { function transferOwnership(address newOwner_) external; function acceptOwnership() external; function disableTransfers(bool disable_) external; function issue(address to_, uint256 amount_) external; }
pragma solidity ^0.5.0; /// @dev The token _controller contract must implement these functions contract ITokenController { /// @notice Called when `owner_` sends ether to the MiniMe Token contract /// @param owner_ The address that sent the ether to create tokens /// @return True if the ether is accepted, false if it throws function proxyPayment( address owner_, bytes4 sig, bytes memory data ) public payable returns (bool); /// @notice Notifies the _controller about a token transfer allowing the /// _controller to react if desired /// @param from_ The origin of the transfer /// @param to_ The destination of the transfer /// @param amount_ The amount of the transfer /// @return False if the _controller does not authorize the transfer function onTransfer( address from_, address to_, uint256 amount_ ) public returns (bool); /// @notice Notifies the _controller about an approval allowing the /// _controller to react if desired /// @param owner_ The address that calls `approve()` /// @param spender_ The spender in the `approve()` call /// @param amount_ The amount in the `approve()` call /// @return False if the _controller does not authorize the approval function onApprove( address owner_, address spender_, uint256 amount_ ) public returns (bool); }
pragma solidity ^0.5.0; import "./DSAuthority.sol"; contract DSAuthEvents { event LogSetAuthority(address indexed authority); event LogSetOwner(address indexed owner); } contract DSAuth is DSAuthEvents { DSAuthority public _authority; address public _owner; constructor() public { _owner = msg.sender; emit LogSetOwner(msg.sender); } function setOwner(address owner_) public auth { _owner = owner_; emit LogSetOwner(_owner); } function setAuthority(DSAuthority authority_) public auth { _authority = authority_; emit LogSetAuthority(address(_authority)); } modifier auth { require(isAuthorized(msg.sender, msg.sig), "ds-auth-unauthorized"); _; } function isAuthorized(address src, bytes4 sig) internal view returns (bool) { if (src == address(this)) { return true; } else if (src == _owner) { return true; } else if (_authority == DSAuthority(address(0))) { return false; } else { return _authority.canCall(src, address(this), sig); } } }
pragma solidity ^0.5.0; interface DSAuthority { function canCall( address src, address dst, bytes4 sig ) external view returns (bool); }
pragma solidity ^0.5.0; import "../math/SafeMath.sol"; import "../ownership/DSAuth.sol"; contract DSToken is DSAuth { using SafeMath for uint256; bool public _stopped; uint256 internal _totalSupply; mapping(address => uint256) internal _balances; mapping(address => mapping(address => uint256)) internal _allowances; string private _name; string private _symbol; constructor(string memory symbol_, string memory name_) public { _symbol = symbol_; _name = name_; } event Approval(address indexed src, address indexed guy, uint256 wad); event Transfer(address indexed src, address indexed dst, uint256 wad); event Mint(address indexed guy, uint256 wad); event Burn(address indexed guy, uint256 wad); event Stop(); event Start(); /** * @dev Returns the name of the token. */ function name() public view returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view returns (string memory) { return _symbol; } function decimals() public pure returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view returns (uint256) { require( account != address(0), "ERC721: balance query for the zero address" ); return _balances[account]; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view returns (uint256) { return _allowances[owner][spender]; } modifier stoppable { require(!_stopped, "ds-stop-is-stopped"); _; } function approve(address guy) external returns (bool) { return approve(guy, uint256(-1)); } function approve(address guy, uint256 wad) public stoppable returns (bool) { require(guy != address(0), "ERC20: approve to the zero address"); _allowances[msg.sender][guy] = wad; emit Approval(msg.sender, guy, wad); return true; } function transfer(address dst, uint256 wad) external returns (bool) { return transferFrom(msg.sender, dst, wad); } function transferFrom( address src, address dst, uint256 wad ) public stoppable returns (bool) { if (src != msg.sender && _allowances[src][msg.sender] != uint256(-1)) { require( _allowances[src][msg.sender] >= wad, "ds-token-insufficient-approval" ); _allowances[src][msg.sender] = _allowances[src][msg.sender].sub( wad ); } require(_balances[src] >= wad, "ds-token-insufficient-balance"); _balances[src] = _balances[src].sub(wad); _balances[dst] = _balances[dst].add(wad); emit Transfer(src, dst, wad); return true; } function push(address dst, uint256 wad) external { transferFrom(msg.sender, dst, wad); } function pull(address src, uint256 wad) external { transferFrom(src, msg.sender, wad); } function move( address src, address dst, uint256 wad ) external { transferFrom(src, dst, wad); } function mint(uint256 wad) external { mint(msg.sender, wad); } function burn(uint256 wad) external { burn(msg.sender, wad); } function mint(address guy, uint256 wad) public auth stoppable { _balances[guy] = _balances[guy].add(wad); _totalSupply = _totalSupply.add(wad); emit Mint(guy, wad); } function burn(address guy, uint256 wad) public auth stoppable { if (guy != msg.sender && _allowances[guy][msg.sender] != uint256(-1)) { require( _allowances[guy][msg.sender] >= wad, "ds-token-insufficient-approval" ); _allowances[guy][msg.sender] = _allowances[guy][msg.sender].sub( wad ); } require(_balances[guy] >= wad, "ds-token-insufficient-balance"); _balances[guy] = _balances[guy].sub(wad); _totalSupply = _totalSupply.sub(wad); emit Burn(guy, wad); } function destroy(address from_, uint256 amount_) public auth stoppable { // do not require allowance require(_balances[from_] >= amount_, "ds-token-insufficient-balance"); _balances[from_] = _balances[from_].sub(amount_); _totalSupply = _totalSupply.sub(amount_); emit Burn(from_, amount_); emit Transfer(from_, address(0), amount_); } function dsStop() public auth { _stopped = true; emit Stop(); } function start() public auth { _stopped = false; emit Start(); } }
pragma solidity ^0.5.0; contract IApproveAndCallFallBack { function receiveApproval( address from, uint256 amount_, address token_, bytes memory data_ ) public; }
pragma solidity <0.6.0 >=0.4.21; import "./IERC20Basic.sol"; /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract IERC20 is IERC20Basic { function name() external view returns (string memory); function symbol() external view returns (string memory); function allowance(address owner, address spender) public view returns (uint256); function transferFrom( address from, address to, uint256 value ) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval( address indexed owner, address indexed spender, uint256 value ); }
pragma solidity ^0.5.0; /// @title IERC223Receiving - Standard interface implementation for compatibility with ERC223 tokens. interface IERC223Receiving { /// @dev Function that is called when a user or another contract wants to transfer funds. /// @param from_ Transaction initiator, analogue of msg.sender /// @param value_ Number of tokens to transfer. /// @param data_ Data containig a function signature and/or parameters function tokenFallback( address from_, uint256 value_, bytes calldata data_ ) external; }
[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"spender_","type":"address"},{"name":"amount_","type":"uint256"}],"name":"approve","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"owner_","type":"address"}],"name":"setOwner","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_stopped","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"disable_","type":"bool"}],"name":"disableTransfers","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"from_","type":"address"},{"name":"to_","type":"address"},{"name":"amount_","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"cap","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newController_","type":"address"}],"name":"changeController","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"guy_","type":"address"},{"name":"wad_","type":"uint256"}],"name":"mint","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"wad","type":"uint256"}],"name":"burn","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"token_","type":"address"},{"name":"to_","type":"address"},{"name":"amount_","type":"uint256"}],"name":"withdrawTokens","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"account","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"acceptOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"authority_","type":"address"}],"name":"setAuthority","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"dsStop","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_transfersEnabled","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"to_","type":"address"},{"name":"amount_","type":"uint256"}],"name":"issue","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"guy_","type":"address"},{"name":"wad_","type":"uint256"}],"name":"burn","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"wad","type":"uint256"}],"name":"mint","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"from_","type":"address"},{"name":"amount_","type":"uint256"}],"name":"destroy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"dst","type":"address"},{"name":"wad","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"from_","type":"address"},{"name":"to_","type":"address"},{"name":"amount_","type":"uint256"},{"name":"data_","type":"bytes"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"dst","type":"address"},{"name":"wad","type":"uint256"}],"name":"push","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"src","type":"address"},{"name":"dst","type":"address"},{"name":"wad","type":"uint256"}],"name":"move","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"to_","type":"address"},{"name":"amount_","type":"uint256"},{"name":"data_","type":"bytes"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"start","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"_authority","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"spender_","type":"address"},{"name":"amount_","type":"uint256"},{"name":"extraData_","type":"bytes"}],"name":"approveAndCall","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"guy","type":"address"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"owner","type":"address"},{"name":"spender","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"token_","type":"address"}],"name":"claimTokens","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"src","type":"address"},{"name":"wad","type":"uint256"}],"name":"pull","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newOwner_","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"token_","type":"address"},{"indexed":true,"name":"controller_","type":"address"},{"indexed":false,"name":"amount_","type":"uint256"}],"name":"ClaimedTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"amount","type":"uint256"},{"indexed":false,"name":"data","type":"bytes"}],"name":"ERC223Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"src","type":"address"},{"indexed":true,"name":"guy","type":"address"},{"indexed":false,"name":"wad","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"src","type":"address"},{"indexed":true,"name":"dst","type":"address"},{"indexed":false,"name":"wad","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"guy","type":"address"},{"indexed":false,"name":"wad","type":"uint256"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"guy","type":"address"},{"indexed":false,"name":"wad","type":"uint256"}],"name":"Burn","type":"event"},{"anonymous":false,"inputs":[],"name":"Stop","type":"event"},{"anonymous":false,"inputs":[],"name":"Start","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"authority","type":"address"}],"name":"LogSetAuthority","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"}],"name":"LogSetOwner","type":"event"}]
Contract Creation Code
60806040526004361061021a5760003560e01c8063867904b411610123578063bb35783b116100ab578063daea85c51161006f578063daea85c514610ae4578063dd62ed3e14610b17578063df8de3e714610b52578063f2d5d56b14610b85578063f2fde38b14610bbe5761021a565b8063bb35783b146108e7578063be45fd621461092a578063be9a6555146109f2578063c2205ee114610a07578063cae9ca5114610a1c5761021a565b8063a24835d1116100f2578063a24835d114610738578063a9059cbb14610771578063ab67aa58146107aa578063b2bdfa7b1461087d578063b753a98c146108ae5761021a565b8063867904b41461068757806395d89b41146106c05780639dc29fac146106d5578063a0712d681461070e5761021a565b80633cebb823116101a657806370a082311161017557806370a08231146105e257806379ba5097146106155780637a9e5e4b1461062a57806383d5978a1461065d57806385438bc0146106725761021a565b80633cebb8231461050957806340c10f191461053c57806342966c68146105755780635e35359e1461059f5761021a565b80631608f18f116101ed5780631608f18f1461043357806318160ddd1461045f57806323b872dd14610486578063313ce567146104c9578063355274ea146104f45761021a565b806306fdde0314610314578063095ea7b31461039e57806313af4035146103eb578063141762971461041e575b60095461022f906001600160a01b0316610bf1565b1561030d57600954604051600160e11b632535112f0281523360048201818152600080356001600160e01b0319166024850181905260606044860190815236606487018190526001600160a01b0390971696634a6a225e96349695939493919290608401848480828437600081840152601f19601f820116905080830192505050955050505050506020604051808303818588803b1580156102d057600080fd5b505af11580156102e4573d6000803e3d6000fd5b50505050506040513d60208110156102fb57600080fd5b5051151561030857600080fd5b610312565b600080fd5b005b34801561032057600080fd5b50610329610c1a565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561036357818101518382015260200161034b565b50505050905090810190601f1680156103905780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103aa57600080fd5b506103d7600480360360408110156103c157600080fd5b506001600160a01b038135169060200135610cb0565b604080519115158252519081900360200190f35b3480156103f757600080fd5b506103126004803603602081101561040e57600080fd5b50356001600160a01b0316610d76565b34801561042a57600080fd5b506103d7610e20565b34801561043f57600080fd5b506103126004803603602081101561045657600080fd5b50351515610e30565b34801561046b57600080fd5b50610474610ea8565b60408051918252519081900360200190f35b34801561049257600080fd5b506103d7600480360360608110156104a957600080fd5b506001600160a01b03813581169160208101359091169060400135610eae565b3480156104d557600080fd5b506104de610f8b565b6040805160ff9092168252519081900360200190f35b34801561050057600080fd5b50610474610f90565b34801561051557600080fd5b506103126004803603602081101561052c57600080fd5b50356001600160a01b0316610f96565b34801561054857600080fd5b506103126004803603604081101561055f57600080fd5b506001600160a01b038135169060200135611012565b34801561058157600080fd5b506103126004803603602081101561059857600080fd5b503561116a565b3480156105ab57600080fd5b50610312600480360360608110156105c257600080fd5b506001600160a01b03813581169160208101359091169060400135611177565b3480156105ee57600080fd5b506104746004803603602081101561060557600080fd5b50356001600160a01b031661126a565b34801561062157600080fd5b506103126112d2565b34801561063657600080fd5b506103126004803603602081101561064d57600080fd5b50356001600160a01b031661135b565b34801561066957600080fd5b50610312611401565b34801561067e57600080fd5b506103d761149c565b34801561069357600080fd5b50610312600480360360408110156106aa57600080fd5b506001600160a01b0381351690602001356114ac565b3480156106cc57600080fd5b50610329611564565b3480156106e157600080fd5b50610312600480360360408110156106f857600080fd5b506001600160a01b0381351690602001356115c5565b34801561071a57600080fd5b506103126004803603602081101561073157600080fd5b50356116ac565b34801561074457600080fd5b506103126004803603604081101561075b57600080fd5b506001600160a01b0381351690602001356116b6565b34801561077d57600080fd5b506103d76004803603604081101561079457600080fd5b506001600160a01b03813516906020013561189a565b3480156107b657600080fd5b506103d7600480360360808110156107cd57600080fd5b6001600160a01b0382358116926020810135909116916040820135919081019060808101606082013564010000000081111561080857600080fd5b82018360208201111561081a57600080fd5b8035906020019184600183028401116401000000008311171561083c57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506118a7945050505050565b34801561088957600080fd5b50610892611b7c565b604080516001600160a01b039092168252519081900360200190f35b3480156108ba57600080fd5b50610312600480360360408110156108d157600080fd5b506001600160a01b038135169060200135611b8b565b3480156108f357600080fd5b506103126004803603606081101561090a57600080fd5b506001600160a01b03813581169160208101359091169060400135611b96565b34801561093657600080fd5b506103d76004803603606081101561094d57600080fd5b6001600160a01b038235169160208101359181019060608101604082013564010000000081111561097d57600080fd5b82018360208201111561098f57600080fd5b803590602001918460018302840111640100000000831117156109b157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550611ba7945050505050565b3480156109fe57600080fd5b50610312611bb5565b348015610a1357600080fd5b50610892611c4a565b348015610a2857600080fd5b506103d760048036036060811015610a3f57600080fd5b6001600160a01b0382351691602081013591810190606081016040820135640100000000811115610a6f57600080fd5b820183602082011115610a8157600080fd5b80359060200191846001830284011164010000000083111715610aa357600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550611c59945050505050565b348015610af057600080fd5b506103d760048036036020811015610b0757600080fd5b50356001600160a01b0316611d5e565b348015610b2357600080fd5b5061047460048036036040811015610b3a57600080fd5b506001600160a01b0381358116916020013516611d6c565b348015610b5e57600080fd5b5061031260048036036020811015610b7557600080fd5b50356001600160a01b0316611d97565b348015610b9157600080fd5b5061031260048036036040811015610ba857600080fd5b506001600160a01b038135169060200135611f75565b348015610bca57600080fd5b5061031260048036036020811015610be157600080fd5b50356001600160a01b0316611f80565b6000806001600160a01b0383161515610c0e576000915050610c15565b5050803b15155b919050565b60058054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610ca65780601f10610c7b57610100808354040283529160200191610ca6565b820191906000526020600020905b815481529060010190602001808311610c8957829003601f168201915b5050505050905090565b600954600090610cc8906001600160a01b0316610bf1565b15610d635760095460408051600160e01b63da682aeb0281523360048201526001600160a01b038681166024830152604482018690529151919092169163da682aeb9160648083019260209291908290030181600087803b158015610d2c57600080fd5b505af1158015610d40573d6000803e3d6000fd5b505050506040513d6020811015610d5657600080fd5b50511515610d6357600080fd5b610d6d8383612062565b90505b92915050565b610d8c336000356001600160e01b031916612166565b1515610dd05760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0383811691909117918290556040519116907fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b600154600160a01b900460ff1681565b610e46336000356001600160e01b031916612166565b1515610e8a5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b60078054600160a01b60ff0219169115600160a01b02919091179055565b60025490565b600754600090600160a01b900460ff161515610ec657fe5b600954610edb906001600160a01b0316610bf1565b15610f785760095460408051600160e01b634a3931490281526001600160a01b03878116600483015286811660248301526044820186905291519190921691634a3931499160648083019260209291908290030181600087803b158015610f4157600080fd5b505af1158015610f55573d6000803e3d6000fd5b505050506040513d6020811015610f6b57600080fd5b50511515610f7857600080fd5b610f83848484612252565b949350505050565b601290565b60085490565b610fac336000356001600160e01b031916612166565b1515610ff05760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600980546001600160a01b0319166001600160a01b0392909216919091179055565b611028336000356001600160e01b031916612166565b151561106c5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff16156110bc5760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6008546110d7826110cb610ea8565b9063ffffffff6124d916565b111561112d5760408051600160e51b62461bcd02815260206004820152601460248201527f4746542d696e73756666696369656e742d636170000000000000000000000000604482015290519081900360640190fd5b61113782826124e6565b6040805182815290516001600160a01b0384169160009160008051602061297f8339815191529181900360200190a35050565b61117433826115c5565b50565b61118d336000356001600160e01b031916612166565b15156111d15760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b826001600160a01b031663a9059cbb83836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561123157600080fd5b505af1158015611245573d6000803e3d6000fd5b505050506040513d602081101561125b57600080fd5b5051151561126557fe5b505050565b60006001600160a01b03821615156112b657604051600160e51b62461bcd02815260040180806020018281038252602a815260200180612955602a913960400191505060405180910390fd5b506001600160a01b031660009081526003602052604090205490565b6007546001600160a01b031633146113345760408051600160e51b62461bcd02815260206004820152601160248201527f4746542d6e6f742d6e65772d6f776e6572000000000000000000000000000000604482015290519081900360640190fd5b60078054600180546001600160a01b03199081166001600160a01b03841617909155169055565b611371336000356001600160e01b031916612166565b15156113b55760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600080546001600160a01b0319166001600160a01b03838116919091178083556040519116917f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada491a250565b611417336000356001600160e01b031916612166565b151561145b5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b60018054600160a01b60ff021916600160a01b1790556040517fbedf0f4abfe86d4ffad593d9607fe70e83ea706033d44d24b3b6283cf3fc4f6b90600090a1565b600754600160a01b900460ff1681565b6114c2336000356001600160e01b031916612166565b15156115065760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff16156115565760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6115608282611012565b5050565b60068054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610ca65780601f10610c7b57610100808354040283529160200191610ca6565b6115db336000356001600160e01b031916612166565b151561161f5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff161561166f5760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b611679828261262b565b6040805182815290516000916001600160a01b0385169160008051602061297f8339815191529181900360200190a35050565b6111743382611012565b6116cc336000356001600160e01b031916612166565b15156117105760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff16156117605760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6001600160a01b0382166000908152600360205260409020548111156117d05760408051600160e51b62461bcd02815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e6365000000604482015290519081900360640190fd5b6001600160a01b0382166000908152600360205260409020546117f9908263ffffffff6128f716565b6001600160a01b038316600090815260036020526040902055600254611825908263ffffffff6128f716565b6002556040805182815290516001600160a01b038416917fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5919081900360200190a26040805182815290516000916001600160a01b0385169160008051602061297f8339815191529181900360200190a35050565b6000610d6d338484610eae565b600754600090600160a01b900460ff1615156118bf57fe5b6009546118d4906001600160a01b0316610bf1565b156119715760095460408051600160e01b634a3931490281526001600160a01b03888116600483015287811660248301526044820187905291519190921691634a3931499160648083019260209291908290030181600087803b15801561193a57600080fd5b505af115801561194e573d6000803e3d6000fd5b505050506040513d602081101561196457600080fd5b5051151561197157600080fd5b61197c858585612252565b15156119d25760408051600160e51b62461bcd02815260206004820152601860248201527f4746542d696e73756666696369656e742d62616c616e63650000000000000000604482015290519081900360640190fd5b6119db84610bf1565b15611abc57604051600160e11b63607705c50281526001600160a01b03868116600483019081526024830186905260606044840190815285516064850152855188949385169363c0ee0b8a938b938a938a9360840190602085019080838360005b83811015611a54578181015183820152602001611a3c565b50505050905090810190601f168015611a815780820380516001836020036101000a031916815260200191505b50945050505050600060405180830381600087803b158015611aa257600080fd5b505af1158015611ab6573d6000803e3d6000fd5b50505050505b836001600160a01b0316856001600160a01b03167f9bfafdc2ae8835972d7b64ef3f8f307165ac22ceffde4a742c52da5487f45fd185856040518083815260200180602001828103825283818151815260200191508051906020019080838360005b83811015611b36578181015183820152602001611b1e565b50505050905090810190601f168015611b635780820380516001836020036101000a031916815260200191505b50935050505060405180910390a3506001949350505050565b6001546001600160a01b031681565b611265338383610eae565b611ba1838383610eae565b50505050565b6000610f83338585856118a7565b611bcb336000356001600160e01b031916612166565b1515611c0f5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b60018054600160a01b60ff02191690556040517f1b55ba3aa851a46be3b365aee5b5c140edd620d578922f3e8466d2cbd96f954b90600090a1565b6000546001600160a01b031681565b6000611c658484610cb0565b1515611c7057600080fd5b604051600160e01b638f4ffcb102815233600482018181526024830186905230604484018190526080606485019081528651608486015286516001600160a01b038a1695638f4ffcb195948a94938a939192909160a490910190602085019080838360005b83811015611ced578181015183820152602001611cd5565b50505050905090810190601f168015611d1a5780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015611d3c57600080fd5b505af1158015611d50573d6000803e3d6000fd5b506001979650505050505050565b6000610d7082600019610cb0565b6001600160a01b03918216600090815260046020908152604080832093909416825291909152205490565b611dad336000356001600160e01b031916612166565b1515611df15760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b6001600160a01b0381161515611e34576040513390303180156108fc02916000818181858888f19350505050158015611e2e573d6000803e3d6000fd5b50611174565b60408051600160e01b6370a08231028152306004820152905182916000916001600160a01b038416916370a08231916024808301926020929190829003018186803b158015611e8257600080fd5b505afa158015611e96573d6000803e3d6000fd5b505050506040513d6020811015611eac57600080fd5b505160408051600160e01b63a9059cbb0281523360048201526024810183905290519192506001600160a01b0384169163a9059cbb916044808201926020929091908290030181600087803b158015611f0457600080fd5b505af1158015611f18573d6000803e3d6000fd5b505050506040513d6020811015611f2e57600080fd5b505060408051828152905133916001600160a01b038616917ff931edb47c50b4b4104c187b5814a9aef5f709e17e2ecf9617e860cacade929c9181900360200190a3505050565b611265823383610eae565b611f96336000356001600160e01b031916612166565b1515611fda5760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b6001546001600160a01b03828116911614156120405760408051600160e51b62461bcd02815260206004820152601460248201527f4746542d616c72656164792d616e2d6f776e6572000000000000000000000000604482015290519081900360640190fd5b600780546001600160a01b0319166001600160a01b0392909216919091179055565b600154600090600160a01b900460ff16156120b55760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6001600160a01b03831615156120ff57604051600160e51b62461bcd0281526004018080602001828103825260228152602001806129336022913960400191505060405180910390fd5b3360008181526004602090815260408083206001600160a01b03881680855290835292819020869055805186815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a350600192915050565b60006001600160a01b03831630141561218157506001610d70565b6001546001600160a01b038481169116141561219f57506001610d70565b6000546001600160a01b031615156121b957506000610d70565b60005460408051600160e01b63b70096130281526001600160a01b0386811660048301523060248301526001600160e01b0319861660448301529151919092169163b7009613916064808301926020929190829003018186803b15801561221f57600080fd5b505afa158015612233573d6000803e3d6000fd5b505050506040513d602081101561224957600080fd5b50519050610d70565b600154600090600160a01b900460ff16156122a55760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6001600160a01b03841633148015906122e357506001600160a01b038416600090815260046020908152604080832033845290915290205460001914155b156123bc576001600160a01b03841660009081526004602090815260408083203384529091529020548211156123635760408051600160e51b62461bcd02815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c0000604482015290519081900360640190fd5b6001600160a01b0384166000908152600460209081526040808320338452909152902054612397908363ffffffff6128f716565b6001600160a01b03851660009081526004602090815260408083203384529091529020555b6001600160a01b03841660009081526003602052604090205482111561242c5760408051600160e51b62461bcd02815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e6365000000604482015290519081900360640190fd5b6001600160a01b038416600090815260036020526040902054612455908363ffffffff6128f716565b6001600160a01b03808616600090815260036020526040808220939093559085168152205461248a908363ffffffff6124d916565b6001600160a01b03808516600081815260036020908152604091829020949094558051868152905191939288169260008051602061297f83398151915292918290030190a35060019392505050565b81810182811015610d7057fe5b6124fc336000356001600160e01b031916612166565b15156125405760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff16156125905760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6001600160a01b0382166000908152600360205260409020546125b9908263ffffffff6124d916565b6001600160a01b0383166000908152600360205260409020556002546125e5908263ffffffff6124d916565b6002556040805182815290516001600160a01b038416917f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885919081900360200190a25050565b612641336000356001600160e01b031916612166565b15156126855760408051600160e51b62461bcd02815260206004820152601460248201526000805160206129bf833981519152604482015290519081900360640190fd5b600154600160a01b900460ff16156126d55760408051600160e51b62461bcd028152602060048201526012602482015260008051602061299f833981519152604482015290519081900360640190fd5b6001600160a01b038216331480159061271357506001600160a01b038216600090815260046020908152604080832033845290915290205460001914155b156127ec576001600160a01b03821660009081526004602090815260408083203384529091529020548111156127935760408051600160e51b62461bcd02815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c0000604482015290519081900360640190fd5b6001600160a01b03821660009081526004602090815260408083203384529091529020546127c7908263ffffffff6128f716565b6001600160a01b03831660009081526004602090815260408083203384529091529020555b6001600160a01b03821660009081526003602052604090205481111561285c5760408051600160e51b62461bcd02815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e6365000000604482015290519081900360640190fd5b6001600160a01b038216600090815260036020526040902054612885908263ffffffff6128f716565b6001600160a01b0383166000908152600360205260409020556002546128b1908263ffffffff6128f716565b6002556040805182815290516001600160a01b038416917fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5919081900360200190a25050565b60008282111561290357fe5b50900390565b600082151561291a57506000610d70565b5081810281838281151561292a57fe5b0414610d7057fefe45524332303a20617070726f766520746f20746865207a65726f20616464726573734552433732313a2062616c616e636520717565727920666f7220746865207a65726f2061646472657373ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef64732d73746f702d69732d73746f70706564000000000000000000000000000064732d617574682d756e617574686f72697a6564000000000000000000000000a165627a7a72305820edd851e892ed81d09d6f2a813b8fedf308a082c19b45192d150dda37e398309a0029
Age | Block | Fee Address | BC Fee Address | Voting Power | Jailed | Incoming |
---|
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for
interesting conversations.