Address Contract Partially Verified
Address
0x245ef47D4d0505ECF3Ac463F4d81f41ADE8f1fd1
Balance
0 ETH
Nonce
1
Code Size
4276 bytes
Creator
0xdEBbb848...d48B at tx 0x3fa47e55...b34684
Last Active
Indexed Transactions
24 (10,625,985 → 10,658,025)
Gas Used (indexed)
380,582
Contract Bytecode
4276 bytes
0x6080604052600436106100d0576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806301502460146100d557806306fdde03146100ec578063095ea7b31461017c57806313af4035146101e157806318160ddd1461022457806323b872dd1461024f578063313ce567146102d457806331c420d414610305578063426a84931461031c5780636d1b229d1461038b57806370a08231146103d057806395d89b4114610427578063a9059cbb146104b7578063dd62ed3e1461051c575b600080fd5b3480156100e157600080fd5b506100ea610593565b005b3480156100f857600080fd5b5061010161064f565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610141578082015181840152602081019050610126565b50505050905090810190601f16801561016e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561018857600080fd5b506101c7600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061068c565b604051808215151515815260200191505060405180910390f35b3480156101ed57600080fd5b50610222600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061077e565b005b34801561023057600080fd5b5061023961081e565b6040518082815260200191505060405180910390f35b34801561025b57600080fd5b506102ba600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610828565b604051808215151515815260200191505060405180910390f35b3480156102e057600080fd5b506102e961085a565b604051808260ff1660ff16815260200191505060405180910390f35b34801561031157600080fd5b5061031a610863565b005b34801561032857600080fd5b50610371600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919050505061091e565b604051808215151515815260200191505060405180910390f35b34801561039757600080fd5b506103b66004803603810190808035906020019092919050505061094e565b604051808215151515815260200191505060405180910390f35b3480156103dc57600080fd5b50610411600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610a1e565b6040518082815260200191505060405180910390f35b34801561043357600080fd5b5061043c610a66565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561047c578082015181840152602081019050610461565b50505050905090810190601f1680156104a95780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156104c357600080fd5b50610502600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610aa3565b604051808215151515815260200191505060405180910390f35b34801561052857600080fd5b5061057d600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610ad3565b6040518082815260200191505060405180910390f35b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156105ef57600080fd5b600360149054906101000a900460ff16151561064d576001600360146101000a81548160ff0219169083151502179055507f615acbaede366d76a8b8cb2a9ada6a71495f0786513d71aa97aaf0c3910b78de60405160405180910390a15b565b60606040805190810160405280600781526020017f4e75676765747300000000000000000000000000000000000000000000000000815250905090565b600081600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156107da57600080fd5b80600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6000600254905090565b6000600360149054906101000a900460ff1661084e57610849848484610b5a565b610851565b60005b90509392505050565b60006012905090565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415156108bf57600080fd5b600360149054906101000a900460ff161561091c576000600360146101000a81548160ff0219169083151502179055507f2f05ba71d0df11bf5fa562a6569d70c4f80da84284badbe015ce1456063d0ded60405160405180910390a15b565b60008261092b3386610ad3565b14156109425761093b848361068c565b9050610947565b600090505b9392505050565b6000806000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050808311156109a35760009150610a18565b6000831115610a13576109b68184610e56565b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a0460025484610e56565b60028190555060019150610a18565b600191505b50919050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60606040805190810160405280600381526020017f4e55470000000000000000000000000000000000000000000000000000000000815250905090565b6000600360149054906101000a900460ff16610ac857610ac38383610e6f565b610acb565b60005b905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b6000806000600160008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054915083821015610bef5760009250610e4d565b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905083811015610c415760009250610e4d565b610c4b8285610e56565b600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600084118015610d0757508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614155b15610de357610d168185610e56565b6000808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610da06000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548561104d565b6000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef866040518082815260200191505060405180910390a3600192505b50509392505050565b6000818310151515610e6457fe5b818303905092915050565b6000806000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905082811015610ec45760009150611046565b600083118015610f0057508373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614155b15610fdc57610f0f8184610e56565b6000803373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610f996000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020548461104d565b6000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505b8373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef856040518082815260200191505060405180910390a3600191505b5092915050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03831115151561107d57fe5b8183019050929150505600a165627a7a72305820b9b146e44e9fab6736760270e7b99cbfcad28de45816007886250982c4416ca40029
Verified Source Code Partial Match
Compiler: v0.4.24+commit.e67f0147
EVM: byzantium
Optimization: No
NuggetsToken.sol 452 lines
/*
* Nuggets Token Smart Contract.
*/
pragma solidity ^0.4.16;
/*
* Abstract Token Smart Contract.
*/
pragma solidity ^0.4.16;
/*
* ERC-20 Standard Token Smart Contract Interface.
*/
pragma solidity ^0.4.16;
/**
* ERC-20 standard token interface, as defined
* <a href="http://github.com/ethereum/EIPs/issues/20">here</a>.
*/
contract Token {
/**
* Get total number of tokens in circulation.
*
* @return total number of tokens in circulation
*/
function totalSupply () constant returns (uint256 supply);
/**
* Get number of tokens currently belonging to given owner.
*
* @param _owner address to get number of tokens currently belonging to the
* owner of
* @return number of tokens currently belonging to the owner of given address
*/
function balanceOf (address _owner) constant returns (uint256 balance);
/**
* Transfer given number of tokens from message sender to given recipient.
*
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer to the owner of given address
* @return true if tokens were transferred successfully, false otherwise
*/
function transfer (address _to, uint256 _value) returns (bool success);
/**
* Transfer given number of tokens from given owner to given recipient.
*
* @param _from address to transfer tokens from the owner of
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer from given owner to given
* recipient
* @return true if tokens were transferred successfully, false otherwise
*/
function transferFrom (address _from, address _to, uint256 _value)
returns (bool success);
/**
* Allow given spender to transfer given number of tokens from message sender.
*
* @param _spender address to allow the owner of to transfer tokens from
* message sender
* @param _value number of tokens to allow to transfer
* @return true if token transfer was successfully approved, false otherwise
*/
function approve (address _spender, uint256 _value) returns (bool success);
/**
* Tell how many tokens given spender is currently allowed to transfer from
* given owner.
*
* @param _owner address to get number of tokens allowed to be transferred
* from the owner of
* @param _spender address to get number of tokens allowed to be transferred
* by the owner of
* @return number of tokens given spender is currently allowed to transfer
* from given owner
*/
function allowance (address _owner, address _spender) constant
returns (uint256 remaining);
/**
* Logged when tokens were transferred from one owner to another.
*
* @param _from address of the owner, tokens were transferred from
* @param _to address of the owner, tokens were transferred to
* @param _value number of tokens transferred
*/
event Transfer (address indexed _from, address indexed _to, uint256 _value);
/**
* Logged when owner approved his tokens to be transferred by some spender.
*
* @param _owner owner who approved his tokens to be transferred
* @param _spender spender who were allowed to transfer the tokens belonging
* to the owner
* @param _value number of tokens belonging to the owner, approved to be
* transferred by the spender
*/
event Approval (
address indexed _owner, address indexed _spender, uint256 _value);
}
/*
* Safe Math Smart Contract.
*/
pragma solidity ^0.4.16;
/**
* Provides methods to safely add, subtract and multiply uint256 numbers.
*/
contract SafeMath {
uint256 constant private MAX_UINT256 =
0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF;
/**
* Add two uint256 values, throw in case of overflow.
*
* @param x first value to add
* @param y second value to add
* @return x + y
*/
function safeAdd (uint256 x, uint256 y)
constant internal
returns (uint256 z) {
assert (x <= MAX_UINT256 - y);
return x + y;
}
/**
* Subtract one uint256 value from another, throw in case of underflow.
*
* @param x value to subtract from
* @param y value to subtract
* @return x - y
*/
function safeSub (uint256 x, uint256 y)
constant internal
returns (uint256 z) {
assert (x >= y);
return x - y;
}
/**
* Multiply two uint256 values, throw in case of overflow.
*
* @param x first value to multiply
* @param y second value to multiply
* @return x * y
*/
function safeMul (uint256 x, uint256 y)
constant internal
returns (uint256 z) {
if (y == 0) return 0; // Prevent division by zero at the next line
assert (x <= MAX_UINT256 / y);
return x * y;
}
}
/**
* Abstract Token Smart Contract that could be used as a base contract for
* ERC-20 token contracts.
*/
contract AbstractToken is Token, SafeMath {
/**
* Create new Abstract Token contract.
*/
function AbstractToken () {
// Do nothing
}
/**
* Get number of tokens currently belonging to given owner.
*
* @param _owner address to get number of tokens currently belonging to the
* owner of
* @return number of tokens currently belonging to the owner of given address
*/
function balanceOf (address _owner) constant returns (uint256 balance) {
return accounts [_owner];
}
/**
* Transfer given number of tokens from message sender to given recipient.
*
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer to the owner of given address
* @return true if tokens were transferred successfully, false otherwise
*/
function transfer (address _to, uint256 _value) returns (bool success) {
uint256 fromBalance = accounts [msg.sender];
if (fromBalance < _value) return false;
if (_value > 0 && msg.sender != _to) {
accounts [msg.sender] = safeSub (fromBalance, _value);
accounts [_to] = safeAdd (accounts [_to], _value);
}
Transfer (msg.sender, _to, _value);
return true;
}
/**
* Transfer given number of tokens from given owner to given recipient.
*
* @param _from address to transfer tokens from the owner of
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer from given owner to given
* recipient
* @return true if tokens were transferred successfully, false otherwise
*/
function transferFrom (address _from, address _to, uint256 _value)
returns (bool success) {
uint256 spenderAllowance = allowances [_from][msg.sender];
if (spenderAllowance < _value) return false;
uint256 fromBalance = accounts [_from];
if (fromBalance < _value) return false;
allowances [_from][msg.sender] =
safeSub (spenderAllowance, _value);
if (_value > 0 && _from != _to) {
accounts [_from] = safeSub (fromBalance, _value);
accounts [_to] = safeAdd (accounts [_to], _value);
}
Transfer (_from, _to, _value);
return true;
}
/**
* Allow given spender to transfer given number of tokens from message sender.
*
* @param _spender address to allow the owner of to transfer tokens from
* message sender
* @param _value number of tokens to allow to transfer
* @return true if token transfer was successfully approved, false otherwise
*/
function approve (address _spender, uint256 _value) returns (bool success) {
allowances [msg.sender][_spender] = _value;
Approval (msg.sender, _spender, _value);
return true;
}
/**
* Tell how many tokens given spender is currently allowed to transfer from
* given owner.
*
* @param _owner address to get number of tokens allowed to be transferred
* from the owner of
* @param _spender address to get number of tokens allowed to be transferred
* by the owner of
* @return number of tokens given spender is currently allowed to transfer
* from given owner
*/
function allowance (address _owner, address _spender) constant
returns (uint256 remaining) {
return allowances [_owner][_spender];
}
/**
* Mapping from addresses of token holders to the numbers of tokens belonging
* to these token holders.
*/
mapping (address => uint256) accounts;
/**
* Mapping from addresses of token holders to the mapping of addresses of
* spenders to the allowances set by these token holders to these spenders.
*/
mapping (address => mapping (address => uint256)) private allowances;
}
/**
* Nuggets Token Smart Contract: EIP-20 compatible token smart contract with
* fixed supply, token burning and transfer freezing.
*/
contract NuggetsToken is AbstractToken {
/**
* Initial supply of Nuggets Tokens.
*/
uint constant INITIAL_SUPPLY = 10000000000e18;
/**
* Create new Nuggets Token contract.
*/
function NuggetsToken () {
owner = msg.sender;
accounts [owner] = INITIAL_SUPPLY;
tokensCount = INITIAL_SUPPLY;
}
/**
* Get name of this token.
*
* @return name of this token
*/
function name () constant returns (string result) {
return "Nuggets";
}
/**
* Get symbol of this token.
*
* @return symbol of this token
*/
function symbol () constant returns (string result) {
return "NUG";
}
/**
* Get number of decimals for this token.
*
* @return number of decimals for this token
*/
function decimals () constant returns (uint8 result) {
return 18;
}
/**
* Get total number of tokens in circulation.
*
* @return total number of tokens in circulation
*/
function totalSupply () constant returns (uint256 supply) {
return tokensCount;
}
/**
* Transfer given number of tokens from message sender to given recipient.
*
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer to the owner of given address
* @return true if tokens were transferred successfully, false otherwise
*/
function transfer (address _to, uint256 _value) returns (bool success) {
return frozen ? false : AbstractToken.transfer (_to, _value);
}
/**
* Transfer given number of tokens from given owner to given recipient.
*
* @param _from address to transfer tokens from the owner of
* @param _to address to transfer tokens to the owner of
* @param _value number of tokens to transfer from given owner to given
* recipient
* @return true if tokens were transferred successfully, false otherwise
*/
function transferFrom (address _from, address _to, uint256 _value)
returns (bool success) {
return frozen ? false : AbstractToken.transferFrom (_from, _to, _value);
}
/**
* Change how many tokens given spender is allowed to transfer from message
* spender. In order to prevent double spending of allowance, this method
* receives assumed current allowance value as an argument. If actual
* allowance differs from an assumed one, this method just returns false.
*
* @param _spender address to allow the owner of to transfer tokens from
* message sender
* @param _currentValue assumed number of tokens currently allowed to be
* transferred
* @param _newValue number of tokens to allow to transfer
* @return true if token transfer was successfully approved, false otherwise
*/
function approve (address _spender, uint256 _currentValue, uint256 _newValue)
returns (bool success) {
if (allowance (msg.sender, _spender) == _currentValue)
return approve (_spender, _newValue);
else return false;
}
/**
* Burn given number of tokens belonging to message sender.
*
* @param _value number of tokens to burn
* @return true on success, false on error
*/
function burnTokens (uint256 _value) returns (bool success) {
uint256 ownerBalance = accounts [msg.sender];
if (_value > ownerBalance) return false;
else if (_value > 0) {
accounts [msg.sender] = safeSub (ownerBalance, _value);
tokensCount = safeSub (tokensCount, _value);
return true;
} else return true;
}
/**
* Set new owner for the smart contract.
* May only be called by smart contract owner.
*
* @param _newOwner address of new owner of the smart contract
*/
function setOwner (address _newOwner) {
require (msg.sender == owner);
owner = _newOwner;
}
/**
* Freeze token transfers.
* May only be called by smart contract owner.
*/
function freezeTransfers () {
require (msg.sender == owner);
if (!frozen) {
frozen = true;
Freeze ();
}
}
/**
* Unfreeze token transfers.
* May only be called by smart contract owner.
*/
function unfreezeTransfers () {
require (msg.sender == owner);
if (frozen) {
frozen = false;
Unfreeze ();
}
}
/**
* Logged when token transfers were frozen.
*/
event Freeze ();
/**
* Logged when token transfers were unfrozen.
*/
event Unfreeze ();
/**
* Number of tokens in circulation.
*/
uint256 tokensCount;
/**
* Owner of the smart contract.
*/
address owner;
/**
* Whether token transfers are currently frozen.
*/
bool frozen;
}
Read Contract
allowance 0xdd62ed3e → uint256
balanceOf 0x70a08231 → uint256
decimals 0x313ce567 → uint8
name 0x06fdde03 → string
symbol 0x95d89b41 → string
totalSupply 0x18160ddd → uint256
Write Contract 8 functions
These functions modify contract state and require a wallet transaction to execute.
approve 0x095ea7b3
address _spender
uint256 _value
returns: bool
approve 0x426a8493
address _spender
uint256 _currentValue
uint256 _newValue
returns: bool
burnTokens 0x6d1b229d
uint256 _value
returns: bool
freezeTransfers 0x01502460
No parameters
setOwner 0x13af4035
address _newOwner
transfer 0xa9059cbb
address _to
uint256 _value
returns: bool
transferFrom 0x23b872dd
address _from
address _to
uint256 _value
returns: bool
unfreezeTransfers 0x31c420d4
No parameters
Top Interactions
| Address | Txns | Sent | Received |
|---|---|---|---|
| 0x272c1fEa...Df56 | 2 | 2 | |
| 0xB0E4E7E5...c991 | 2 | 2 | |
| 0x954b4D1A...b902 | 1 | 1 | |
| 0x8b5f7A0A...b8b9 | 1 | 1 | |
| 0x49FB6aF7...Cc50 | 1 | 1 | |
| 0xb0042C01...8dBd | 1 | 1 | |
| 0x7269CaD9...C304 | 1 | 1 | |
| 0x50f9fa0E...b162 | 1 | 1 |
Recent Transactions
|
| Hash | Block | Age | From/To | Value | |
|---|---|---|---|---|---|
| 0x6ee605af...32d6b6 | 10,658,025 | IN | 0x272c1fEa...Df56 | 0 ETH | |
| 0x0ed383ef...8d1243 | 10,657,933 | IN | 0x8b5f7A0A...b8b9 | 0 ETH | |
| 0x0157b89f...0b98e3 | 10,655,681 | IN | 0x272c1fEa...Df56 | 0 ETH | |
| 0x6c52e61a...311044 | 10,651,198 | IN | 0x7269CaD9...C304 | 0 ETH | |
| 0x42a98110...f5e6e3 | 10,646,558 | IN | 0xb0042C01...8dBd | 0 ETH | |
| 0x26da25a0...ac37b0 | 10,633,921 | IN | 0xB0E4E7E5...c991 | 0 ETH | |
| 0xd93e3f49...16b8bc | 10,633,921 | IN | 0xB0E4E7E5...c991 | 0 ETH | |
| 0xf8bea0f7...4bab21 | 10,630,873 | IN | 0x49FB6aF7...Cc50 | 0 ETH | |
| 0x58094e1b...148dde | 10,628,469 | IN | 0x954b4D1A...b902 | 0 ETH | |
| 0xcbacbb4e...7be56c | 10,625,985 | IN | 0x50f9fa0E...b162 | 0 ETH |