Token migration announcement. Eterbase Coin token contract has migrated to a new address.
ERC-20
Exchange
Overview
Max Total Supply
1,000,000,000 XBASE
Holders
6,145 (0.00%)
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract (WITH 18 Decimals)
Balance
1,288 XBASEValue
$0.00Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
XBase
Compiler Version
v0.5.7+commit.6da8b019
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2019-04-19 */ pragma solidity ^0.5.7; interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); function transfer(address to, uint256 value) external returns (bool); function approve(address spender, uint256 value) external returns (bool); function transferFrom(address from, address to, uint256 value) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } interface IERC223 { function name() external view returns (string memory); function symbol() external view returns (string memory); function decimals() external view returns (uint8); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint); function transfer(address to, uint value) external returns (bool); function transfer(address to, uint value, bytes calldata data) external returns (bool); event Transfer(address indexed from, address indexed to, uint value, bytes indexed data); } contract ContractReceiver { function tokenFallback(address _from, uint _value, bytes memory _data) public { } } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on 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-solidity/pull/522 if (a == 0) { return 0; } uint256 c = a * b; require(c / a == b); return c; } /** * @dev Integer division of two unsigned integers truncating the quotient, * reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { // Solidity only automatically asserts when dividing by 0 require(b > 0); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; } /** * @dev Subtracts two unsigned integers, reverts on overflow * (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { require(b <= a); uint256 c = a - b; return c; } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a); return c; } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { require(b != 0); return a % b; } } contract StandardToken is IERC20, IERC223 { uint256 public totalSupply; using SafeMath for uint; mapping (address => uint256) internal balances; mapping (address => mapping (address => uint256)) internal allowed; function balanceOf(address _owner) public view returns (uint256 balance) { return balances[_owner]; } function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { require(_to != address(0)); require(_value <= balances[_from]); require(_value <= allowed[_from][msg.sender]); balances[_from] = balances[_from].sub(_value); balances[_to] = balances[_to].add(_value); allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value); emit Transfer(_from, _to, _value); return true; } function approve(address _spender, uint256 _value) public returns (bool) { //require(_value == 0 || allowed[msg.sender][_spender] == 0); allowed[msg.sender][_spender] = _value; emit Approval(msg.sender, _spender, _value); return true; } function allowance(address _owner, address _spender) public view returns (uint256) { return allowed[_owner][_spender]; } function increaseApproval(address _spender, uint _addedValue) public returns (bool) { allowed[msg.sender][_spender] = allowed[msg.sender][_spender].add(_addedValue); emit Approval(msg.sender, _spender, allowed[msg.sender][_spender]); return true; } function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { uint oldValue = allowed[msg.sender][_spender]; if (_subtractedValue > oldValue) { allowed[msg.sender][_spender] = 0; } else { allowed[msg.sender][_spender] = oldValue.sub(_subtractedValue); } emit Approval(msg.sender, _spender, allowed[msg.sender][_spender]); return true; } // Function that is called when a user or another contract wants to transfer funds. function transfer(address _to, uint _value, bytes memory _data) public returns (bool success) { if (isContract(_to)) { return transferToContract(_to, _value, _data); } else { return transferToAddress(_to, _value, _data); } } // Standard function transfer similar to ERC20 transfer with no _data. // Added due to backwards compatibility reasons. function transfer(address _to, uint _value) public returns (bool success) { bytes memory empty; if (isContract(_to)) { return transferToContract(_to, _value, empty); } else { return transferToAddress(_to, _value, empty); } } // Assemble the given address bytecode. If bytecode exists then the _addr is a contract. function isContract(address _addr) private view returns (bool is_contract) { uint length; require(_addr != address(0)); assembly { //retrieve the size of the code on target address, this needs assembly length := extcodesize(_addr) } return (length > 0); } // Function that is called when transaction target is an address. function transferToAddress(address _to, uint _value, bytes memory _data) private returns (bool success) { require(balances[msg.sender] >= _value); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); emit Transfer(msg.sender, _to, _value, _data); return true; } // Function that is called when transaction target is a contract. function transferToContract(address _to, uint _value, bytes memory _data) private returns (bool success) { require(balances[msg.sender] >= _value); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); ContractReceiver receiver = ContractReceiver(_to); receiver.tokenFallback(msg.sender, _value, _data); emit Transfer(msg.sender, _to, _value); emit Transfer(msg.sender, _to, _value, _data); return true; } } contract XBase is StandardToken { string public constant name = "Eterbase Coin"; string public constant symbol = "XBASE"; uint8 public constant decimals = 18; uint256 public constant initialSupply = 1000000000 * 10 ** uint256(decimals); constructor () public { totalSupply = initialSupply; balances[msg.sender] = initialSupply; } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"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":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"initialSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_owner","type":"address"}],"name":"balanceOf","outputs":[{"name":"balance","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_addedValue","type":"uint256"}],"name":"increaseApproval","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"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"},{"indexed":true,"name":"data","type":"bytes"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"spender","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Approval","type":"event"}]
Contract Creation Code
608060405234801561001057600080fd5b506b033b2e3c9fd0803ce8000000600081815533815260016020526040902055610c388061003f6000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063661884631161008c578063a9059cbb11610066578063a9059cbb14610261578063be45fd621461028d578063d73dd62314610348578063dd62ed3e14610374576100cf565b8063661884631461020757806370a082311461023357806395d89b4114610259576100cf565b806306fdde03146100d4578063095ea7b31461015157806318160ddd1461019157806323b872dd146101ab578063313ce567146101e1578063378dc3dc146101ff575b600080fd5b6100dc6103a2565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101165781810151838201526020016100fe565b50505050905090810190601f1680156101435780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61017d6004803603604081101561016757600080fd5b506001600160a01b0381351690602001356103db565b604080519115158252519081900360200190f35b610199610442565b60408051918252519081900360200190f35b61017d600480360360608110156101c157600080fd5b506001600160a01b03813581169160208101359091169060400135610448565b6101e96105c0565b6040805160ff9092168252519081900360200190f35b6101996105c5565b61017d6004803603604081101561021d57600080fd5b506001600160a01b0381351690602001356105d5565b6101996004803603602081101561024957600080fd5b50356001600160a01b03166106c5565b6100dc6106e0565b61017d6004803603604081101561027757600080fd5b506001600160a01b038135169060200135610704565b61017d600480360360608110156102a357600080fd5b6001600160a01b03823516916020810135918101906060810160408201356401000000008111156102d357600080fd5b8201836020820111156102e557600080fd5b8035906020019184600183028401116401000000008311171561030757600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610734945050505050565b61017d6004803603604081101561035e57600080fd5b506001600160a01b038135169060200135610761565b6101996004803603604081101561038a57600080fd5b506001600160a01b03813581169160200135166107fa565b6040518060400160405280600d81526020017f457465726261736520436f696e0000000000000000000000000000000000000081525081565b3360008181526002602090815260408083206001600160a01b038716808552908352818420869055815186815291519394909390927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925928290030190a35060015b92915050565b60005481565b60006001600160a01b03831661045d57600080fd5b6001600160a01b03841660009081526001602052604090205482111561048257600080fd5b6001600160a01b03841660009081526002602090815260408083203384529091529020548211156104b257600080fd5b6001600160a01b0384166000908152600160205260409020546104db908363ffffffff61082516565b6001600160a01b038086166000908152600160205260408082209390935590851681522054610510908363ffffffff61083a16565b6001600160a01b038085166000908152600160209081526040808320949094559187168152600282528281203382529091522054610554908363ffffffff61082516565b6001600160a01b03808616600081815260026020908152604080832033845282529182902094909455805186815290519287169391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929181900390910190a35060015b9392505050565b601281565b6b033b2e3c9fd0803ce800000081565b3360009081526002602090815260408083206001600160a01b03861684529091528120548083111561062a573360009081526002602090815260408083206001600160a01b038816845290915281205561065f565b61063a818463ffffffff61082516565b3360009081526002602090815260408083206001600160a01b03891684529091529020555b3360008181526002602090815260408083206001600160a01b0389168085529083529281902054815190815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b6001600160a01b031660009081526001602052604090205490565b604051806040016040528060058152602001600160d81b6458424153450281525081565b600060606107118461084c565b156107295761072184848361086a565b91505061043c565b610721848483610aa8565b600061073f8461084c565b156107565761074f84848461086a565b90506105b9565b61074f848484610aa8565b3360009081526002602090815260408083206001600160a01b0386168452909152812054610795908363ffffffff61083a16565b3360008181526002602090815260408083206001600160a01b0389168085529083529281902085905580519485525191937f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929081900390910190a350600192915050565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b60008282111561083457600080fd5b50900390565b6000828201838110156105b957600080fd5b6000806001600160a01b03831661086257600080fd5b50503b151590565b3360009081526001602052604081205483111561088657600080fd5b336000908152600160205260409020546108a6908463ffffffff61082516565b33600090815260016020526040808220929092556001600160a01b038616815220546108d8908463ffffffff61083a16565b6001600160a01b0385166000818152600160209081526040808320949094559251600160e11b63607705c50281523360048201818152602483018990526060604484019081528851606485015288518b9763c0ee0b8a9694958c958c959493608490920192860191908190849084905b83811015610960578181015183820152602001610948565b50505050905090810190601f16801561098d5780820380516001836020036101000a031916815260200191505b50945050505050600060405180830381600087803b1580156109ae57600080fd5b505af11580156109c2573d6000803e3d6000fd5b50506040805187815290516001600160a01b03891693503392507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a3826040518082805190602001908083835b60208310610a365780518252601f199092019160209182019101610a17565b51815160209384036101000a6000190180199092169116179052604080519290940182900382208a835293519395506001600160a01b038b16945033937fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c169350918290030190a4506001949350505050565b33600090815260016020526040812054831115610ac457600080fd5b33600090815260016020526040902054610ae4908463ffffffff61082516565b33600090815260016020526040808220929092556001600160a01b03861681522054610b16908463ffffffff61083a16565b6001600160a01b0385166000818152600160209081526040918290209390935580518681529051919233927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a3816040518082805190602001908083835b60208310610b9b5780518252601f199092019160209182019101610b7c565b51815160209384036101000a60001901801990921691161790526040805192909401829003822089835293519395506001600160a01b038a16945033937fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c169350918290030190a4506001939250505056fea165627a7a72305820320b8a30809f7ebdafe2a41f33539b584fe3a5ba9a1cc2e0080509eb006eec250029
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063661884631161008c578063a9059cbb11610066578063a9059cbb14610261578063be45fd621461028d578063d73dd62314610348578063dd62ed3e14610374576100cf565b8063661884631461020757806370a082311461023357806395d89b4114610259576100cf565b806306fdde03146100d4578063095ea7b31461015157806318160ddd1461019157806323b872dd146101ab578063313ce567146101e1578063378dc3dc146101ff575b600080fd5b6100dc6103a2565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101165781810151838201526020016100fe565b50505050905090810190601f1680156101435780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61017d6004803603604081101561016757600080fd5b506001600160a01b0381351690602001356103db565b604080519115158252519081900360200190f35b610199610442565b60408051918252519081900360200190f35b61017d600480360360608110156101c157600080fd5b506001600160a01b03813581169160208101359091169060400135610448565b6101e96105c0565b6040805160ff9092168252519081900360200190f35b6101996105c5565b61017d6004803603604081101561021d57600080fd5b506001600160a01b0381351690602001356105d5565b6101996004803603602081101561024957600080fd5b50356001600160a01b03166106c5565b6100dc6106e0565b61017d6004803603604081101561027757600080fd5b506001600160a01b038135169060200135610704565b61017d600480360360608110156102a357600080fd5b6001600160a01b03823516916020810135918101906060810160408201356401000000008111156102d357600080fd5b8201836020820111156102e557600080fd5b8035906020019184600183028401116401000000008311171561030757600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610734945050505050565b61017d6004803603604081101561035e57600080fd5b506001600160a01b038135169060200135610761565b6101996004803603604081101561038a57600080fd5b506001600160a01b03813581169160200135166107fa565b6040518060400160405280600d81526020017f457465726261736520436f696e0000000000000000000000000000000000000081525081565b3360008181526002602090815260408083206001600160a01b038716808552908352818420869055815186815291519394909390927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925928290030190a35060015b92915050565b60005481565b60006001600160a01b03831661045d57600080fd5b6001600160a01b03841660009081526001602052604090205482111561048257600080fd5b6001600160a01b03841660009081526002602090815260408083203384529091529020548211156104b257600080fd5b6001600160a01b0384166000908152600160205260409020546104db908363ffffffff61082516565b6001600160a01b038086166000908152600160205260408082209390935590851681522054610510908363ffffffff61083a16565b6001600160a01b038085166000908152600160209081526040808320949094559187168152600282528281203382529091522054610554908363ffffffff61082516565b6001600160a01b03808616600081815260026020908152604080832033845282529182902094909455805186815290519287169391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929181900390910190a35060015b9392505050565b601281565b6b033b2e3c9fd0803ce800000081565b3360009081526002602090815260408083206001600160a01b03861684529091528120548083111561062a573360009081526002602090815260408083206001600160a01b038816845290915281205561065f565b61063a818463ffffffff61082516565b3360009081526002602090815260408083206001600160a01b03891684529091529020555b3360008181526002602090815260408083206001600160a01b0389168085529083529281902054815190815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b6001600160a01b031660009081526001602052604090205490565b604051806040016040528060058152602001600160d81b6458424153450281525081565b600060606107118461084c565b156107295761072184848361086a565b91505061043c565b610721848483610aa8565b600061073f8461084c565b156107565761074f84848461086a565b90506105b9565b61074f848484610aa8565b3360009081526002602090815260408083206001600160a01b0386168452909152812054610795908363ffffffff61083a16565b3360008181526002602090815260408083206001600160a01b0389168085529083529281902085905580519485525191937f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929081900390910190a350600192915050565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b60008282111561083457600080fd5b50900390565b6000828201838110156105b957600080fd5b6000806001600160a01b03831661086257600080fd5b50503b151590565b3360009081526001602052604081205483111561088657600080fd5b336000908152600160205260409020546108a6908463ffffffff61082516565b33600090815260016020526040808220929092556001600160a01b038616815220546108d8908463ffffffff61083a16565b6001600160a01b0385166000818152600160209081526040808320949094559251600160e11b63607705c50281523360048201818152602483018990526060604484019081528851606485015288518b9763c0ee0b8a9694958c958c959493608490920192860191908190849084905b83811015610960578181015183820152602001610948565b50505050905090810190601f16801561098d5780820380516001836020036101000a031916815260200191505b50945050505050600060405180830381600087803b1580156109ae57600080fd5b505af11580156109c2573d6000803e3d6000fd5b50506040805187815290516001600160a01b03891693503392507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a3826040518082805190602001908083835b60208310610a365780518252601f199092019160209182019101610a17565b51815160209384036101000a6000190180199092169116179052604080519290940182900382208a835293519395506001600160a01b038b16945033937fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c169350918290030190a4506001949350505050565b33600090815260016020526040812054831115610ac457600080fd5b33600090815260016020526040902054610ae4908463ffffffff61082516565b33600090815260016020526040808220929092556001600160a01b03861681522054610b16908463ffffffff61083a16565b6001600160a01b0385166000818152600160209081526040918290209390935580518681529051919233927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a3816040518082805190602001908083835b60208310610b9b5780518252601f199092019160209182019101610b7c565b51815160209384036101000a60001901801990921691161790526040805192909401829003822089835293519395506001600160a01b038a16945033937fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c169350918290030190a4506001939250505056fea165627a7a72305820320b8a30809f7ebdafe2a41f33539b584fe3a5ba9a1cc2e0080509eb006eec250029
Swarm Source
bzzr://320b8a30809f7ebdafe2a41f33539b584fe3a5ba9a1cc2e0080509eb006eec25
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.