Feature Tip: Add private address tag to any address under My Name Tag !
ERC-20
Overview
Max Total Supply
2,000,000,000 WKC
Holders
10,408
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract (WITH 18 Decimals)
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
WankCoin
Compiler Version
v0.4.21+commit.dfe3193c
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2018-03-08 */ pragma solidity ^0.4.21; contract TokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; } contract ERC20 { uint256 public totalSupply; function balanceOf(address _owner) public constant returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool ok); function transferFrom(address _from, address _to, uint256 _value) public returns (bool ok); function approve(address _spender, uint256 _value) public returns (bool ok); function allowance(address _owner, address _spender) public constant returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } contract WankCoin is ERC20 { mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint8 public decimals; string public name; string public symbol; bool public running; address public owner; address public ownerTemp; modifier isOwner { require(owner == msg.sender); _; } modifier isRunning { require(running); _; } function WankCoin() public { running = true; owner = msg.sender; decimals = 18; totalSupply = 2 * uint(10)**(decimals + 9); balances[owner] = totalSupply; name = "WANKCOIN"; symbol = "WKC"; emit Transfer(0x0, owner, totalSupply); } function transfer(address _to, uint256 _value) public isRunning returns (bool) { require(balances[msg.sender] >= _value && balances[_to] + _value > balances[_to]); balances[msg.sender] -= _value; balances[_to] += _value; emit Transfer(msg.sender, _to, _value); return true; } function transferFrom(address _from, address _to, uint256 _value) public isRunning returns (bool) { require(balances[_from] >= _value && allowed[_from][msg.sender] >= _value && balances[_to] + _value > balances[_to]); balances[_to] += _value; balances[_from] -= _value; allowed[_from][msg.sender] -= _value; emit Transfer(_from, _to, _value); return true; } function balanceOf(address _owner) public constant returns (uint256) { return balances[_owner]; } function approve(address _spender, uint256 _value) public isRunning returns (bool) { allowed[msg.sender][_spender] = _value; emit Approval(msg.sender, _spender, _value); return true; } function allowance(address _owner, address _spender) public constant returns (uint256) { return allowed[_owner][_spender]; } function approveAndCall(address _spender, uint256 _value, bytes _extraData) public isRunning returns (bool ok) { TokenRecipient spender = TokenRecipient(_spender); if (approve(_spender, _value)) { spender.receiveApproval(msg.sender, _value, this, _extraData); return true; } } function setName(string _name) public isOwner { name = _name; } function setSymbol(string _symbol) public isOwner { symbol = _symbol; } function setRunning(bool _run) public isOwner { running = _run; } function transferOwnership(address _owner) public isOwner { ownerTemp = _owner; } function acceptOwnership() public { require(msg.sender == ownerTemp); owner = ownerTemp; ownerTemp = 0x0; } function collectERC20(address _token, uint _amount) public isRunning isOwner returns (bool success) { return ERC20(_token).transfer(owner, _amount); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":false,"inputs":[{"name":"_token","type":"address"},{"name":"_amount","type":"uint256"}],"name":"collectERC20","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"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":"ownerTemp","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_owner","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":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"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":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_symbol","type":"string"}],"name":"setSymbol","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_name","type":"string"}],"name":"setName","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"},{"name":"_extraData","type":"bytes"}],"name":"approveAndCall","outputs":[{"name":"ok","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"running","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","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":"_run","type":"bool"}],"name":"setRunning","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_owner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","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"}],"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
6060604052341561000f57600080fd5b60068054600160ff19918216811761010060a860020a03191661010033600160a060020a03908116820292909217948590556003805460129516949094179384905560ff938416600901909316600a0a600202600081815593909404168252602052604090819020919091558051908101604052600881527f57414e4b434f494e000000000000000000000000000000000000000000000000602082015260049080516100c0929160200190610164565b5060408051908101604052600381527f574b43000000000000000000000000000000000000000000000000000000000060208201526005908051610108929160200190610164565b50600660019054906101000a9004600160a060020a0316600160a060020a031660007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60005460405190815260200160405180910390a36101ff565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106101a557805160ff19168380011785556101d2565b828001600101855582156101d2579182015b828111156101d25782518255916020019190600101906101b7565b506101de9291506101e2565b5090565b6101fc91905b808211156101de57600081556001016101e8565b90565b610c588061020e6000396000f3006060604052600436106100ed5763ffffffff60e060020a60003504166303c1d1df81146100f257806306fdde0314610128578063095ea7b3146101b257806318160ddd146101d457806323b872dd146101f9578063313ce567146102215780635b5fa6ba1461024a57806370a082311461027957806379ba5097146102985780638da5cb5b146102ad57806395d89b41146102c0578063a9059cbb146102d3578063b84c8246146102f5578063c47f002714610346578063cae9ca5114610397578063d85bd526146103fc578063dd62ed3e1461040f578063dfd200c514610434578063f2fde38b1461044c575b600080fd5b34156100fd57600080fd5b610114600160a060020a036004351660243561046b565b604051901515815260200160405180910390f35b341561013357600080fd5b61013b61051c565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561017757808201518382015260200161015f565b50505050905090810190601f1680156101a45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156101bd57600080fd5b610114600160a060020a03600435166024356105ba565b34156101df57600080fd5b6101e7610637565b60405190815260200160405180910390f35b341561020457600080fd5b610114600160a060020a036004358116906024351660443561063d565b341561022c57600080fd5b61023461075f565b60405160ff909116815260200160405180910390f35b341561025557600080fd5b61025d610768565b604051600160a060020a03909116815260200160405180910390f35b341561028457600080fd5b6101e7600160a060020a0360043516610777565b34156102a357600080fd5b6102ab610792565b005b34156102b857600080fd5b61025d6107f9565b34156102cb57600080fd5b61013b61080d565b34156102de57600080fd5b610114600160a060020a0360043516602435610878565b341561030057600080fd5b6102ab60046024813581810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061094795505050505050565b341561035157600080fd5b6102ab60046024813581810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061097e95505050505050565b34156103a257600080fd5b61011460048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506109b195505050505050565b341561040757600080fd5b610114610adb565b341561041a57600080fd5b6101e7600160a060020a0360043581169060243516610ae4565b341561043f57600080fd5b6102ab6004351515610b0f565b341561045757600080fd5b6102ab600160a060020a0360043516610b42565b60065460009060ff16151561047f57600080fd5b60065433600160a060020a03908116610100909204161461049f57600080fd5b600654600160a060020a038085169163a9059cbb91610100909104168460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b15156104ff57600080fd5b5af1151561050c57600080fd5b5050506040518051949350505050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105b25780601f10610587576101008083540402835291602001916105b2565b820191906000526020600020905b81548152906001019060200180831161059557829003601f168201915b505050505081565b60065460009060ff1615156105ce57600080fd5b600160a060020a03338116600081815260026020908152604080832094881680845294909152908190208590557f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b60005481565b60065460009060ff16151561065157600080fd5b600160a060020a0384166000908152600160205260409020548290108015906106a15750600160a060020a0380851660009081526002602090815260408083203390941683529290522054829010155b80156106c65750600160a060020a038316600090815260016020526040902054828101115b15156106d157600080fd5b600160a060020a03808416600081815260016020908152604080832080548801905588851680845281842080548990039055600283528184203390961684529490915290819020805486900390559091907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a35060019392505050565b60035460ff1681565b600754600160a060020a031681565b600160a060020a031660009081526001602052604090205490565b60075433600160a060020a039081169116146107ad57600080fd5b600780546006805474ffffffffffffffffffffffffffffffffffffffff001916610100600160a060020a0384160217905573ffffffffffffffffffffffffffffffffffffffff19169055565b6006546101009004600160a060020a031681565b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105b25780601f10610587576101008083540402835291602001916105b2565b60065460009060ff16151561088c57600080fd5b600160a060020a0333166000908152600160205260409020548290108015906108ce5750600160a060020a038316600090815260016020526040902054828101115b15156108d957600080fd5b600160a060020a033381166000818152600160205260408082208054879003905592861680825290839020805486019055917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a350600192915050565b60065433600160a060020a03908116610100909204161461096757600080fd5b600581805161097a929160200190610b91565b5050565b60065433600160a060020a03908116610100909204161461099e57600080fd5b600481805161097a929160200190610b91565b600654600090819060ff1615156109c757600080fd5b50836109d381856105ba565b15610ad35780600160a060020a0316638f4ffcb1338630876040518563ffffffff1660e060020a0281526004018085600160a060020a0316600160a060020a0316815260200184815260200183600160a060020a0316600160a060020a0316815260200180602001828103825283818151815260200191508051906020019080838360005b83811015610a70578082015183820152602001610a58565b50505050905090810190601f168015610a9d5780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b1515610abe57600080fd5b5af11515610acb57600080fd5b505050600191505b509392505050565b60065460ff1681565b600160a060020a03918216600090815260026020908152604080832093909416825291909152205490565b60065433600160a060020a039081166101009092041614610b2f57600080fd5b6006805460ff1916911515919091179055565b60065433600160a060020a039081166101009092041614610b6257600080fd5b6007805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10610bd257805160ff1916838001178555610bff565b82800160010185558215610bff579182015b82811115610bff578251825591602001919060010190610be4565b50610c0b929150610c0f565b5090565b610c2991905b80821115610c0b5760008155600101610c15565b905600a165627a7a72305820c79ba96b0ed2ee2e0a35d3e4a46672f3743012eb6af8559ad5eb8709f86cf45f0029
Deployed Bytecode
0x6060604052600436106100ed5763ffffffff60e060020a60003504166303c1d1df81146100f257806306fdde0314610128578063095ea7b3146101b257806318160ddd146101d457806323b872dd146101f9578063313ce567146102215780635b5fa6ba1461024a57806370a082311461027957806379ba5097146102985780638da5cb5b146102ad57806395d89b41146102c0578063a9059cbb146102d3578063b84c8246146102f5578063c47f002714610346578063cae9ca5114610397578063d85bd526146103fc578063dd62ed3e1461040f578063dfd200c514610434578063f2fde38b1461044c575b600080fd5b34156100fd57600080fd5b610114600160a060020a036004351660243561046b565b604051901515815260200160405180910390f35b341561013357600080fd5b61013b61051c565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561017757808201518382015260200161015f565b50505050905090810190601f1680156101a45780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156101bd57600080fd5b610114600160a060020a03600435166024356105ba565b34156101df57600080fd5b6101e7610637565b60405190815260200160405180910390f35b341561020457600080fd5b610114600160a060020a036004358116906024351660443561063d565b341561022c57600080fd5b61023461075f565b60405160ff909116815260200160405180910390f35b341561025557600080fd5b61025d610768565b604051600160a060020a03909116815260200160405180910390f35b341561028457600080fd5b6101e7600160a060020a0360043516610777565b34156102a357600080fd5b6102ab610792565b005b34156102b857600080fd5b61025d6107f9565b34156102cb57600080fd5b61013b61080d565b34156102de57600080fd5b610114600160a060020a0360043516602435610878565b341561030057600080fd5b6102ab60046024813581810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061094795505050505050565b341561035157600080fd5b6102ab60046024813581810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061097e95505050505050565b34156103a257600080fd5b61011460048035600160a060020a03169060248035919060649060443590810190830135806020601f820181900481020160405190810160405281815292919060208401838380828437509496506109b195505050505050565b341561040757600080fd5b610114610adb565b341561041a57600080fd5b6101e7600160a060020a0360043581169060243516610ae4565b341561043f57600080fd5b6102ab6004351515610b0f565b341561045757600080fd5b6102ab600160a060020a0360043516610b42565b60065460009060ff16151561047f57600080fd5b60065433600160a060020a03908116610100909204161461049f57600080fd5b600654600160a060020a038085169163a9059cbb91610100909104168460405160e060020a63ffffffff8516028152600160a060020a0390921660048301526024820152604401602060405180830381600087803b15156104ff57600080fd5b5af1151561050c57600080fd5b5050506040518051949350505050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105b25780601f10610587576101008083540402835291602001916105b2565b820191906000526020600020905b81548152906001019060200180831161059557829003601f168201915b505050505081565b60065460009060ff1615156105ce57600080fd5b600160a060020a03338116600081815260026020908152604080832094881680845294909152908190208590557f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b60005481565b60065460009060ff16151561065157600080fd5b600160a060020a0384166000908152600160205260409020548290108015906106a15750600160a060020a0380851660009081526002602090815260408083203390941683529290522054829010155b80156106c65750600160a060020a038316600090815260016020526040902054828101115b15156106d157600080fd5b600160a060020a03808416600081815260016020908152604080832080548801905588851680845281842080548990039055600283528184203390961684529490915290819020805486900390559091907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a35060019392505050565b60035460ff1681565b600754600160a060020a031681565b600160a060020a031660009081526001602052604090205490565b60075433600160a060020a039081169116146107ad57600080fd5b600780546006805474ffffffffffffffffffffffffffffffffffffffff001916610100600160a060020a0384160217905573ffffffffffffffffffffffffffffffffffffffff19169055565b6006546101009004600160a060020a031681565b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105b25780601f10610587576101008083540402835291602001916105b2565b60065460009060ff16151561088c57600080fd5b600160a060020a0333166000908152600160205260409020548290108015906108ce5750600160a060020a038316600090815260016020526040902054828101115b15156108d957600080fd5b600160a060020a033381166000818152600160205260408082208054879003905592861680825290839020805486019055917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a350600192915050565b60065433600160a060020a03908116610100909204161461096757600080fd5b600581805161097a929160200190610b91565b5050565b60065433600160a060020a03908116610100909204161461099e57600080fd5b600481805161097a929160200190610b91565b600654600090819060ff1615156109c757600080fd5b50836109d381856105ba565b15610ad35780600160a060020a0316638f4ffcb1338630876040518563ffffffff1660e060020a0281526004018085600160a060020a0316600160a060020a0316815260200184815260200183600160a060020a0316600160a060020a0316815260200180602001828103825283818151815260200191508051906020019080838360005b83811015610a70578082015183820152602001610a58565b50505050905090810190601f168015610a9d5780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b1515610abe57600080fd5b5af11515610acb57600080fd5b505050600191505b509392505050565b60065460ff1681565b600160a060020a03918216600090815260026020908152604080832093909416825291909152205490565b60065433600160a060020a039081166101009092041614610b2f57600080fd5b6006805460ff1916911515919091179055565b60065433600160a060020a039081166101009092041614610b6257600080fd5b6007805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10610bd257805160ff1916838001178555610bff565b82800160010185558215610bff579182015b82811115610bff578251825591602001919060010190610be4565b50610c0b929150610c0f565b5090565b610c2991905b80821115610c0b5760008155600101610c15565b905600a165627a7a72305820c79ba96b0ed2ee2e0a35d3e4a46672f3743012eb6af8559ad5eb8709f86cf45f0029
Swarm Source
bzzr://c79ba96b0ed2ee2e0a35d3e4a46672f3743012eb6af8559ad5eb8709f86cf45f
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.