Contract Source Code
Find Similiar Contracts
pragma solidity 0.4.10;
/// @title Abstract token contract - Functions to be implemented by token contracts.
contract Token {
function transfer(address to, uint256 value) returns (bool success);
function transferFrom(address from, address to, uint256 value) returns (bool success);
function approve(address spender, uint256 value) returns (bool success);
// This is not an abstract function, because solc won't recognize generated getter functions for public variables as functions.
function totalSupply() constant returns (uint256 supply) {}
function balanceOf(address owner) constant returns (uint256 balance);
function allowance(address owner, address spender) constant returns (uint256 remaining);
event Transfer(address indexed from, address indexed to, uint256 value);
event Approval(address indexed owner, address indexed spender, uint256 value);
}
/// @title Standard token contract - Standard token interface implementation.
contract StandardToken is Token {
/*
* Data structures
*/
mapping (address => uint256) balances;
mapping (address => mapping (address => uint256)) allowed;
uint256 public totalSupply;
/*
* Public functions
*/
/// @dev Transfers sender's tokens to a given address. Returns success.
/// @param _to Address of token receiver.
/// @param _value Number of tokens to transfer.
/// @return Returns success of function call.
function transfer(address _to, uint256 _value)
public
returns (bool)
{
if (balances[msg.sender] < _value) {
// Balance too low
throw;
}
balances[msg.sender] -= _value;
balances[_to] += _value;
Transfer(msg.sender, _to, _value);
return true;
}
/// @dev Allows allowed third party to transfer tokens from one address to another. Returns success.
/// @param _from Address from where tokens are withdrawn.
/// @param _to Address to where tokens are sent.
/// @param _value Number of tokens to transfer.
/// @return Returns success of function call.
function transferFrom(address _from, address _to, uint256 _value)
public
returns (bool)
{
if (balances[_from] < _value || allowed[_from][msg.sender] < _value) {
// Balance or allowance too low
throw;
}
balances[_to] += _value;
balances[_from] -= _value;
allowed[_from][msg.sender] -= _value;
Transfer(_from, _to, _value);
return true;
}
/// @dev Sets approved amount of tokens for spender. Returns success.
/// @param _spender Address of allowed account.
/// @param _value Number of approved tokens.
/// @return Returns success of function call.
function approve(address _spender, uint256 _value)
public
returns (bool)
{
allowed[msg.sender][_spender] = _value;
Approval(msg.sender, _spender, _value);
return true;
}
/*
* Read functions
*/
/// @dev Returns number of allowed tokens for given address.
/// @param _owner Address of token owner.
/// @param _spender Address of token spender.
/// @return Returns remaining allowance for spender.
function allowance(address _owner, address _spender)
constant
public
returns (uint256)
{
return allowed[_owner][_spender];
}
/// @dev Returns number of tokens owned by given address.
/// @param _owner Address of token owner.
/// @return Returns balance of owner.
function balanceOf(address _owner)
constant
public
returns (uint256)
{
return balances[_owner];
}
}
/// @title Gnosis token contract
/// @author Stefan George - <[email protected]>
contract GnosisToken is StandardToken {
/*
* Token meta data
*/
string constant public name = "Gnosis Token";
string constant public symbol = "GNO";
uint8 constant public decimals = 18;
/*
* Public functions
*/
/// @dev Contract constructor function sets dutch auction contract address and assigns all tokens to dutch auction.
/// @param dutchAuction Address of dutch auction contract.
/// @param owners Array of addresses receiving preassigned tokens.
/// @param tokens Array of preassigned token amounts.
function GnosisToken(address dutchAuction, address[] owners, uint[] tokens)
public
{
if (dutchAuction == 0)
// Address should not be null.
throw;
totalSupply = 10000000 * 10**18;
balances[dutchAuction] = 9000000 * 10**18;
Transfer(0, dutchAuction, balances[dutchAuction]);
uint assignedTokens = balances[dutchAuction];
for (uint i=0; i<owners.length; i++) {
if (owners[i] == 0)
// Address should not be null.
throw;
balances[owners[i]] += tokens[i];
Transfer(0, owners[i], tokens[i]);
assignedTokens += tokens[i];
}
if (assignedTokens != totalSupply)
throw;
}
}
Contract ABI
[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"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,"type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"type":"function"},{"constant":true,"inputs":[{"name":"_owner","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"type":"function"},{"constant":true,"inputs":[{"name":"_owner","type":"address"},{"name":"_spender","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"type":"function"},{"inputs":[{"name":"dutchAuction","type":"address"},{"name":"owners","type":"address[]"},{"name":"tokens","type":"uint256[]"}],"payable":false,"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
Switch To Opcodes View 6060604052341561000c57fe5b604051610d51380380610d51833981016040528080519060200190919080518201919060200180518201919050505b6000600060008573ffffffffffffffffffffffffffffffffffffffff1614156100645760006000fd5b6a084595161401484a0000006002819055506a0771d2fa45345aa9000000600060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508473ffffffffffffffffffffffffffffffffffffffff1660007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546040518082815260200191505060405180910390a3600060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549150600090505b835181101561030357600084828151811015156101b457fe5b9060200190602002015173ffffffffffffffffffffffffffffffffffffffff1614156101e05760006000fd5b82818151811015156101ee57fe5b9060200190602002015160006000868481518110151561020a57fe5b9060200190602002015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282540192505081905550838181518110151561026957fe5b9060200190602002015173ffffffffffffffffffffffffffffffffffffffff1660007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef85848151811015156102ba57fe5b906020019060200201516040518082815260200191505060405180910390a382818151811015156102e757fe5b90602001906020020151820191505b808060010191505061019b565b600254821415156103145760006000fd5b5b50505050505b610a278061032a6000396000f30060606040523615610097576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde0314610099578063095ea7b31461013257806318160ddd1461018957806323b872dd146101af578063313ce5671461022557806370a082311461025157806395d89b411461029b578063a9059cbb14610334578063dd62ed3e1461038b575bfe5b34156100a157fe5b6100a96103f4565b60405180806020018281038252838181518152602001915080519060200190808383600083146100f8575b8051825260208311156100f8576020820191506020810190506020830392506100d4565b505050905090810190601f1680156101245780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561013a57fe5b61016f600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803590602001909190505061042e565b604051808215151515815260200191505060405180910390f35b341561019157fe5b610199610521565b6040518082815260200191505060405180910390f35b34156101b757fe5b61020b600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803573ffffffffffffffffffffffffffffffffffffffff16906020019091908035906020019091905050610527565b604051808215151515815260200191505060405180910390f35b341561022d57fe5b610235610791565b604051808260ff1660ff16815260200191505060405180910390f35b341561025957fe5b610285600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610796565b6040518082815260200191505060405180910390f35b34156102a357fe5b6102ab6107e0565b60405180806020018281038252838181518152602001915080519060200190808383600083146102fa575b8051825260208311156102fa576020820191506020810190506020830392506102d6565b505050905090810190601f1680156103265780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561033c57fe5b610371600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803590602001909190505061081a565b604051808215151515815260200191505060405180910390f35b341561039357fe5b6103de600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610973565b6040518082815260200191505060405180910390f35b604060405190810160405280600c81526020017f476e6f73697320546f6b656e000000000000000000000000000000000000000081525081565b600081600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a3600190505b92915050565b60025481565b600081600060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410806105f1575081600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054105b156105fc5760006000fd5b81600060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254019250508190555081600060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254039250508190555081600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825403925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190505b9392505050565b601281565b6000600060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490505b919050565b604060405190810160405280600381526020017f474e4f000000000000000000000000000000000000000000000000000000000081525081565b600081600060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205410156108695760006000fd5b81600060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254039250508190555081600060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190505b92915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490505b929150505600a165627a7a723058202e733d216c861d7ecce84e19c22f2140eeb24d6e7844461caf13eb41c5578ba000290000000000000000000000001d0dcc8d8bcafa8e8502beaeef6cbd49d3affcdc000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000001d805bc00b8fa3c96ae6c8fa97b2fd24b19a98010000000000000000000000005210c4dcd7eb899a1274fd6471adec9896ae05aa0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a00000000000000000000000006750adbb477d0310f395da2ad93abe4b9bfd1c8700000000000000000000000031cba7ad3483f9bff236df556e1c3695736a9615000000000000000000000000fc36387afdba73d4532af724ee04d94992e8a2e80000000000000000000000009ee585a6c270fd8b046a5b2019fdac86544bca61000000000000000000000000d8dd5d51efea7108c2d2e663f4520fe4715056c0000000000000000000000000c0754d0a5cb5b25d452be07165180ef331a3241a0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a0000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000054b40b1f852bda000000000000000000000000000000000000000000000000000a968163f0a57b400000000000000000000000000000000000000000000000000a968163f0a57b40000000000000000000000000000000000000000000000000032d26d12e980b60000000000000000000000000000000000000000000000000021e19e0c9bab2400000000000000000000000000000000000000000000000001fc3842bd1f071c00000000000000000000000000000000000000000000000001fc3842bd1f071c0000000000000000000000000000000000000000000000000098774738bc82220000000000000000000000000000000000000000000000000065a4da25d3016c0000000000000000000000000000000000000000000000000152d02c7e14af6800000
Constructor Arguments (ABI-encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000001d0dcc8d8bcafa8e8502beaeef6cbd49d3affcdc000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000001d805bc00b8fa3c96ae6c8fa97b2fd24b19a98010000000000000000000000005210c4dcd7eb899a1274fd6471adec9896ae05aa0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a00000000000000000000000006750adbb477d0310f395da2ad93abe4b9bfd1c8700000000000000000000000031cba7ad3483f9bff236df556e1c3695736a9615000000000000000000000000fc36387afdba73d4532af724ee04d94992e8a2e80000000000000000000000009ee585a6c270fd8b046a5b2019fdac86544bca61000000000000000000000000d8dd5d51efea7108c2d2e663f4520fe4715056c0000000000000000000000000c0754d0a5cb5b25d452be07165180ef331a3241a0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a0000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000054b40b1f852bda000000000000000000000000000000000000000000000000000a968163f0a57b400000000000000000000000000000000000000000000000000a968163f0a57b40000000000000000000000000000000000000000000000000032d26d12e980b60000000000000000000000000000000000000000000000000021e19e0c9bab2400000000000000000000000000000000000000000000000001fc3842bd1f071c00000000000000000000000000000000000000000000000001fc3842bd1f071c0000000000000000000000000000000000000000000000000098774738bc82220000000000000000000000000000000000000000000000000065a4da25d3016c0000000000000000000000000000000000000000000000000152d02c7e14af6800000
-----Decoded View---------------
Found 25 constructor arguments :
Arg [0] : 0000000000000000000000001d0dcc8d8bcafa8e8502beaeef6cbd49d3affcdc
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [2] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [3] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [4] : 0000000000000000000000001d805bc00b8fa3c96ae6c8fa97b2fd24b19a9801
Arg [5] : 0000000000000000000000005210c4dcd7eb899a1274fd6471adec9896ae05aa
Arg [6] : 0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a0
Arg [7] : 0000000000000000000000006750adbb477d0310f395da2ad93abe4b9bfd1c87
Arg [8] : 00000000000000000000000031cba7ad3483f9bff236df556e1c3695736a9615
Arg [9] : 000000000000000000000000fc36387afdba73d4532af724ee04d94992e8a2e8
Arg [10] : 0000000000000000000000009ee585a6c270fd8b046a5b2019fdac86544bca61
Arg [11] : 000000000000000000000000d8dd5d51efea7108c2d2e663f4520fe4715056c0
Arg [12] : 000000000000000000000000c0754d0a5cb5b25d452be07165180ef331a3241a
Arg [13] : 0000000000000000000000009f7dfab2222a473284205cddf08a677726d786a0
Arg [14] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [15] : 0000000000000000000000000000000000000000000054b40b1f852bda000000
Arg [16] : 000000000000000000000000000000000000000000000a968163f0a57b400000
Arg [17] : 000000000000000000000000000000000000000000000a968163f0a57b400000
Arg [18] : 00000000000000000000000000000000000000000000032d26d12e980b600000
Arg [19] : 00000000000000000000000000000000000000000000021e19e0c9bab2400000
Arg [20] : 000000000000000000000000000000000000000000001fc3842bd1f071c00000
Arg [21] : 000000000000000000000000000000000000000000001fc3842bd1f071c00000
Arg [22] : 00000000000000000000000000000000000000000000098774738bc822200000
Arg [23] : 00000000000000000000000000000000000000000000065a4da25d3016c00000
Arg [24] : 00000000000000000000000000000000000000000000152d02c7e14af6800000
Swarm Source:
bzzr://2e733d216c861d7ecce84e19c22f2140eeb24d6e7844461caf13eb41c5578ba0