Contract 0xdbf411f0125839bE53aC7cc5c8c3a8f185075df7

 
 
Txn Hash
Method
Block
From
To
Value
0x5cb6ec3581a7c9023c87317abdbad5f3ffda0e526c95a281a97819e2ccd63583Transfer72295192019-02-16 22:55:311280 days 1 hr ago0xbb2594bce9c5c18766245df9c950ab7d323c65f6 IN  0xdbf411f0125839be53ac7cc5c8c3a8f185075df70.37 Ether0.000357715
0x9088e1e76ed9a03a7e572a2bd7bb4dcad6989090290e2717b4483eea5af5e3eeTransfer71799362019-02-05 20:40:431291 days 3 hrs ago0x2cb644a9299f95f427a6a32b9b8f37b0d6720043 IN  0xdbf411f0125839be53ac7cc5c8c3a8f185075df70.2 Ether0.000632715
0x03ac1940cad5522433be0741d5b4224892cbc2a34e498c315ee9f8e9aafa616e0x6080604071413572019-01-28 23:49:251299 days 27 mins ago0x5caa0c4552116d0cf266746c779fd0feaaa0c569 IN  Create: GutTCO0 Ether0.005313612
[ Download CSV Export 
Latest 2 internal transactions
Parent Txn Hash Block From To Value
0x5cb6ec3581a7c9023c87317abdbad5f3ffda0e526c95a281a97819e2ccd6358372295192019-02-16 22:55:311280 days 1 hr ago 0xdbf411f0125839be53ac7cc5c8c3a8f185075df70xceb8e7aeb51caafb1edd59c8d5a4514bd54ddd380.37 Ether
0x9088e1e76ed9a03a7e572a2bd7bb4dcad6989090290e2717b4483eea5af5e3ee71799362019-02-05 20:40:431291 days 3 hrs ago 0xdbf411f0125839be53ac7cc5c8c3a8f185075df70xceb8e7aeb51caafb1edd59c8d5a4514bd54ddd380.2 Ether
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
GutTCO

Compiler Version
v0.4.25+commit.59dbf8f1

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2019-01-29
*/

/**
 *  PERSONO.ID is WEB 3.0 cornerstone.
 *  Human first. UBI out of the box. Inevitable.
 *  This contract is a crowdsale of transitional GUT tokens for ETH.
 *  Join early. Don't miss the rise of the great, and impressive bounties.
 *  Open site() at GUT token address 0xbA01AfF9EF5198B5e691D2ac61E3cC126F25491d
**/

pragma solidity ^0.4.24;

/**
 * @title ERC20 interface
 */
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
  );
}

/**
 * @title SafeMath
 * @dev Math operations with safety checks that revert on error
 */
library SafeMath {

  /**
  * @dev Multiplies two numbers, 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.
    if (a == 0) {
      return 0;
    }

    uint256 c = a * b;
    require(c / a == b);

    return c;
  }

  /**
  * @dev Integer division of two numbers truncating the quotient, reverts on division by zero.
  */
  function div(uint256 a, uint256 b) internal pure returns (uint256) {
    require(b > 0); // Solidity only automatically asserts when dividing by 0
    uint256 c = a / b;

    return c;
  }

  /**
  * @dev Subtracts two numbers, 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 numbers, 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 numbers 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;
  }
}

/**
 * @title Standard ERC20 token
 *
 * @notice The full implementation is in the token. Here it is just for correct compilation. 
 */
contract ERC20 is IERC20 {
  /**
   * @dev Internal ERC20 token function that mints an amount of the token and assigns it to
   * an account. This encapsulates the modification of balances such that the
   * proper events are emitted.
   * @param account The account that will receive the created tokens.
   * @param value The amount that will be created.
   */
  function _mint(address account, uint256 value) internal;
}

/**
 * @title Roles
 * @dev Library for managing addresses assigned to a Role.
 */
library Roles {
  struct Role {
    mapping (address => bool) bearer;
  }

  /**
   * @dev give an account access to this role
   */
  function add(Role storage role, address account) internal {
    require(account != address(0));
    require(!has(role, account));

    role.bearer[account] = true;
  }

  /**
   * @dev remove an account's access to this role
   */
  function remove(Role storage role, address account) internal {
    require(account != address(0));
    require(has(role, account));

    role.bearer[account] = false;
  }

  /**
   * @dev check if an account has this role
   * @return bool
   */
  function has(Role storage role, address account)
    internal
    view
    returns (bool)
  {
    require(account != address(0));
    return role.bearer[account];
  }
}

contract MinterRole {
  using Roles for Roles.Role;

  event MinterAdded(address indexed account);
  event MinterRemoved(address indexed account);

  Roles.Role private minters;

  constructor() internal {
    _addMinter(msg.sender);
  }

  modifier onlyMinter() {
    require(isMinter(msg.sender));
    _;
  }

  function isMinter(address account) public view returns (bool) {
    return minters.has(account);
  }

  function addMinter(address account) public onlyMinter {
    _addMinter(account);
  }

  function renounceMinter() public {
    _removeMinter(msg.sender);
  }

  function _addMinter(address account) internal {
    minters.add(account);
    emit MinterAdded(account);
  }

  function _removeMinter(address account) internal {
    minters.remove(account);
    emit MinterRemoved(account);
  }
}

/**
 * @title ERC20Mintable
 * @dev ERC20 minting logic. Shortened. Full contract is in the GutTCO.token() contract.
 */
contract ERC20Mintable is ERC20, MinterRole {
  
  /**
   * @dev Function to mint tokens
   * @param to The address that will receive the minted tokens.
   * @param value The amount of tokens to mint.
   * @return A boolean that indicates if the operation was successful.
   */
  function mint(
    address to,
    uint256 value
  )
    public
    onlyMinter
    returns (bool)
  {
    _mint(to, value);
    return true;
  }
}

/**
 * @title SafeERC20
 * @notice Shortened Wrappers around ERC20 operations that throw on failure.
 */
library SafeERC20 {

  using SafeMath for uint256;

  function safeTransfer(
    IERC20 token,
    address to,
    uint256 value
  )
    internal
  {
    require(token.transfer(to, value));
  }
}

/**
 * @title Helps contracts guard against reentrancy attacks.
 * @author Remco Bloemen <[email protected]π.com>, Eenae <[email protected]>
 * @dev If you mark a function `nonReentrant`, you should also
 * mark it `external`.
 */
contract ReentrancyGuard {

  /// @dev counter to allow mutex lock with only one SSTORE operation
  uint256 private _guardCounter;

  constructor() internal {
    // The counter starts at one to prevent changing it from zero to a non-zero
    // value, which is a more expensive operation.
    _guardCounter = 1;
  }

  /**
   * @notice Prevents a contract from calling itself, directly or indirectly.
   */
  modifier nonReentrant() {
    _guardCounter += 1;
    uint256 localCounter = _guardCounter;
    _;
    require(localCounter == _guardCounter);
  }

}

/**
 * @title Crowdsale
 * @notice Crowdsale is a base contract for managing a token crowdsale,
 * allowing investors to purchase tokens with ether. This contract implements
 * such functionality in its most fundamental form and is extended by other contracts here to provide additional
 * functionality and custom behavior.
 */
contract Crowdsale is ReentrancyGuard {
  using SafeMath for uint256;
  using SafeERC20 for IERC20;

  // The token being sold
  IERC20 private _token;

  // Address where funds are collected
  address private _wallet;

  // How many token units a buyer would get per wei. 
  // Usually is the conversion between wei and the smallest and indivisible token unit.
  // Overridden by IcreasingPriceTCO contract logic.
  uint256 private _rate;

  // Amount of wei raised
  uint256 private _weiRaised;

  /**
   * Event for token purchase logging
   * @param purchaser who paid for the tokens
   * @param beneficiary who got the tokens
   * @param value weis paid for purchase
   * @param amount amount of tokens purchased
   */
  event TokensPurchased(
    address indexed purchaser,
    address indexed beneficiary,
    uint256 value,
    uint256 amount
  );

  /**
   * @param rate Number of token units a buyer gets per wei
   * @dev The rate is the conversion between wei and the smallest and indivisible
   * token unit. So, if you are using a rate of 1 with a ERC20Detailed token
   * with 3 decimals called TOK, 1 wei will give you 1 unit, or 0.001 TOK.
   * @param wallet Address where collected funds will be forwarded to
   * @param token Address of the token being sold
   */
  constructor(uint256 rate, address wallet, IERC20 token) internal {
    require(rate > 0);
    require(wallet != address(0));
    require(token != address(0));

    _rate = rate;
    _wallet = wallet;
    _token = token;
  }

  // -----------------------------------------
  // Crowdsale external interface
  // -----------------------------------------

  /**
   * @dev fallback function ***DO NOT OVERRIDE***
   * Note that other contracts will transfer fund with a base gas stipend
   * of 2300, which is not enough to call buyTokens. Consider calling
   * buyTokens directly when purchasing tokens from a contract.
   */
  function () external payable {
    buyTokens(msg.sender);
  }

  /**
   * @return the token being sold.
   */
  function token() public view returns(IERC20) {
    return _token;
  }

  /**
   * @return the address where funds are collected.
   */
  function wallet() public view returns(address) {
    return _wallet;
  }

  /**
   * @return the number of token units a buyer gets per wei.
   */
  function rate() public view returns(uint256) {
    return _rate;
  }

  /**
   * @return the amount of wei raised.
   */
  function weiRaised() public view returns (uint256) {
    return _weiRaised;
  }

  /**
   * @dev low level token purchase ***DO NOT OVERRIDE***
   * This function has a non-reentrancy guard, so it shouldn't be called by
   * another `nonReentrant` function.
   * @param beneficiary Recipient of the token purchase
   */
  function buyTokens(address beneficiary) public nonReentrant payable {

    uint256 weiAmount = msg.value;
    _preValidatePurchase(beneficiary, weiAmount);

    // calculate token amount to be created
    uint256 tokens = _getTokenAmount(weiAmount);

    // update state
    _weiRaised = _weiRaised.add(weiAmount);

    _processPurchase(beneficiary, tokens);
    emit TokensPurchased(
      msg.sender,
      beneficiary,
      weiAmount,
      tokens
    );

    _updatePurchasingState(beneficiary, weiAmount); //check and manage current exchange rate and hard cap
    _forwardFunds(); //save funds to a Persono.id Foundation address
    _postValidatePurchase(beneficiary, weiAmount); 
  }

  // -----------------------------------------
  // Internal interface (extensible)
  // -----------------------------------------

  /**
   * @dev Validation of an incoming purchase. Use require statements to revert state when conditions are not met. Use `super` in contracts that inherit from Crowdsale to extend their validations.
   * Example from CappedCrowdsale.sol's _preValidatePurchase method:
   *   super._preValidatePurchase(beneficiary, weiAmount);
   *   require(weiRaised().add(weiAmount) <= cap);
   * @param beneficiary Address performing the token purchase
   * @param weiAmount Value in wei involved in the purchase
   */
  function _preValidatePurchase(
    address beneficiary,
    uint256 weiAmount
  )
    internal
    view
  {
    require(beneficiary != address(0));
    require(weiAmount != 0);
  }

  /**
   * @dev Validation of an executed purchase. Observe state and use revert statements to undo rollback when valid conditions are not met.
   * @param beneficiary Address performing the token purchase
   * @param weiAmount Value in wei involved in the purchase
   */
  function _postValidatePurchase(
    address beneficiary,
    uint256 weiAmount
  )
    internal
    view
  {
    // optional override
  }

  /**
   * @dev Source of tokens. Override this method to modify the way in which the crowdsale ultimately gets and sends its tokens.
   * @param beneficiary Address performing the token purchase
   * @param tokenAmount Number of tokens to be emitted
   */
  function _deliverTokens(
    address beneficiary,
    uint256 tokenAmount
  )
    internal
  {
    _token.safeTransfer(beneficiary, tokenAmount);
  }

  /**
   * @dev Executed when a purchase has been validated and is ready to be executed. Doesn't necessarily emit/send tokens.
   * @param beneficiary Address receiving the tokens
   * @param tokenAmount Number of tokens to be purchased
   */
  function _processPurchase(
    address beneficiary,
    uint256 tokenAmount
  )
    internal
  {
    _deliverTokens(beneficiary, tokenAmount);
  }

  /**
   * @dev Override for extensions that require an internal state to check for validity (current user contributions, etc.)
   * @param beneficiary Address receiving the tokens
   * @param weiAmount Value in wei involved in the purchase
   */
  function _updatePurchasingState(
    address beneficiary,
    uint256 weiAmount
  )
    internal
  {
    // optional override
  }

  /**
   * @dev Override to extend the way in which ether is converted to tokens.
   * @param weiAmount Value in wei to be converted into tokens
   * @return Number of tokens that can be purchased with the specified _weiAmount
   */
  function _getTokenAmount(uint256 weiAmount)
    internal view returns (uint256)
  {
    return weiAmount.mul(_rate);
  }

  /**
   * @dev Determines how ETH is stored/forwarded on purchases.
   */
  function _forwardFunds() internal {
    _wallet.transfer(msg.value);
  }
}

/**
 * @title IncreasingPriceTCO
 * @notice Extension of Crowdsale contract that increases the price of tokens according to price ranges. 
 * Early adopters get up to 24 times more benefits.
 */
contract IncreasingPriceTCO is Crowdsale {
    using SafeMath for uint256;

    uint256[2][] private _rates; //_rates[i][0] - upper limit of total weiRaised to apply _rates[i][1] exchange rate at the 
    uint8 private _currentRateIndex; // Index of the current rate: _rates[_currentIndex][1] is the current rate index

    event NewRateIsSet(
    uint8 rateIndex,
    uint256 exRate,
    uint256 weiRaisedRange,
    uint256 weiRaised
  );
  /**
   * @param initRates Is an array of pairs [weiRaised, exchangeRate]. Deteremine the exchange rate depending on the total wei raised before the transaction. 
  */
  constructor(uint256[2][] memory initRates) internal {
    require(initRates.length > 1, 'Rates array should contain more then one value');
    _rates = initRates;
    _currentRateIndex = 0;
  }
 
  function getCurrentRate() public view returns(uint256) {
    return _rates[_currentRateIndex][1];
  }

  modifier ifExRateNeedsUpdate {
    if(weiRaised() >= _rates[_currentRateIndex][0] && _currentRateIndex < _rates.length - 1)
      _;
  }

  /**
   * @notice The new exchange rate is set if total weiRased() exceeds the current exchange rate range 
   */
  function _updateCurrentRate() internal ifExRateNeedsUpdate {
    uint256 _weiRaised = weiRaised();
    _currentRateIndex++; //the modifier ifExRateNeedsUpdate means the exchange rate is changed, so we move to the next range right away
    while(_currentRateIndex < _rates.length - 1 && _rates[_currentRateIndex][0] <= _weiRaised) {
      _currentRateIndex++;
    }
    emit NewRateIsSet(_currentRateIndex, //new exchange rate index
                      _rates[_currentRateIndex][1], //new exchange rate 
                      _rates[_currentRateIndex][0], //new exchange rate _weiRaised limit
                      _weiRaised); //amount of _weiRaised by the moment the new exchange rate is applied
  }

  /**
   * @notice The base rate function is overridden to revert, since this crowdsale doens't use it, and
   * all calls to it are a mistake.
   */
  function rate() public view returns(uint256) {
    revert();
  }
  
  /**
   * @notice Overrides function applying multiple increasing price exchange rates concept
   */
  function _getTokenAmount(uint256 weiAmount)
    internal view returns (uint256)
  {
    return getCurrentRate().mul(weiAmount);
  }

  /**
   * @notice Overrides a "hook" from the base Crowdsale contract. Checks and updates the current exchange rate. 
   */
  function _updatePurchasingState(address beneficiary, uint256 weiAmount) internal
  {
    _updateCurrentRate();
  }
}

contract KeeperRole {
  using Roles for Roles.Role;

  event KeeperAdded(address indexed account);
  event KeeperRemoved(address indexed account);

  Roles.Role private keepers;

  constructor() internal {
    _addKeeper(msg.sender);
  }

  modifier onlyKeeper() {
    require(isKeeper(msg.sender), 'Only Keeper is allowed');
    _;
  }

  function isKeeper(address account) public view returns (bool) {
    return keepers.has(account);
  }

  function addKeeper(address account) public onlyKeeper {
    _addKeeper(account);
  }

  function renounceKeeper() public {
    _removeKeeper(msg.sender);
  }

  function _addKeeper(address account) internal {
    keepers.add(account);
    emit KeeperAdded(account);
  }

  function _removeKeeper(address account) internal {
    keepers.remove(account);
    emit KeeperRemoved(account);
  }
}

contract PauserRole {
  using Roles for Roles.Role;

  event PauserAdded(address indexed account);
  event PauserRemoved(address indexed account);

  Roles.Role private pausers;

  constructor() internal {
    _addPauser(msg.sender);
  }

  modifier onlyPauser() {
    require(isPauser(msg.sender));
    _;
  }

  function isPauser(address account) public view returns (bool) {
    return pausers.has(account);
  }

  function addPauser(address account) public onlyPauser {
    _addPauser(account);
  }

  function renouncePauser() public {
    _removePauser(msg.sender);
  }

  function _addPauser(address account) internal {
    pausers.add(account);
    emit PauserAdded(account);
  }

  function _removePauser(address account) internal {
    pausers.remove(account);
    emit PauserRemoved(account);
  }
}

/**
 * @title Haltable
 * @dev Base contract which allows children to implement an emergency pause mechanism 
 * and close irreversibly
 */
contract Haltable is KeeperRole, PauserRole {
  event Paused(address account);
  event Unpaused(address account);
  event Closed(address account);

  bool private _paused;
  bool private _closed;

  constructor() internal {
    _paused = false;
    _closed = false;
  }

  /**
   * @return true if the contract is paused, false otherwise.
   */
  function paused() public view returns(bool) {
    return _paused;
  }

  /**
   * @return true if the contract is closed, false otherwise.
   */
  function isClosed() public view returns(bool) {
    return _closed;
  }

  /**
   * @return true if the contract is not closed, false otherwise.
   */
  function notClosed() public view returns(bool) {
    return !_closed;
  }

  /**
   * @notice Modifier to make a function callable only when the contract is not paused.
   */
  modifier whenNotPaused() {
    require(!_paused, 'The contract is paused');
    _;
  }

  /**
   * @notice Modifier to make a function callable only when the contract is paused.
   */
  modifier whenPaused() {
    require(_paused, 'The contract is not paused');
    _;
  }

  /**
   * @dev Modifier to make a function callable only when the contract is closed.
   */
  modifier whenClosed(bool orCondition) {
    require(_closed, 'The contract is not closed');
    _;
  }

  /**
   * @dev Modifier to make a function callable only when the contract is closed or an external condition is met.
   */
  modifier whenClosedOr(bool orCondition) {
    require(_closed || orCondition, "It must be closed or what is set in 'orCondition'");
    _;
  }

  /**
   * @dev Modifier to make a function callable only when the contract is not closed.
   */
  modifier whenNotClosed() {
    require(!_closed, "Reverted because it is closed");
    _;
  }

  /**
   * @dev called by the owner to pause, triggers stopped state
   */
  function pause() public onlyPauser whenNotPaused {
    _paused = true;
    emit Paused(msg.sender);
  }

  /**
   * @dev called by the owner to unpause, returns to normal state
   */
  function unpause() public onlyPauser whenPaused {
    _paused = false;
    emit Unpaused(msg.sender);
  }

  /**
   * @dev Called by a Keeper to close a contract. This is irreversible.
   */
  function close() internal whenNotClosed {
    _closed = true;
    emit Closed(msg.sender);
  }
}

/**
 * @title CappedCrowdsale
 * @dev Crowdsale with a limit for total contributions.
 */
contract CappedTCO is Crowdsale {
  using SafeMath for uint256;
  uint256 private _cap;
  
  /**
   * @dev Constructor, takes maximum amount of wei accepted in the crowdsale.
   * @param cap Max amount of wei to be contributed
   */
  constructor(uint256 cap) internal {
      require(cap > 0, 'Hard cap must be > 0');
      _cap = cap;
  }
  
  /**
   * @return the cap of the crowdsale.
   */
  function cap() public view returns(uint256) {
      return _cap;
  }
  
  /**
   * @dev Checks whether the cap has been reached.
   * @return Whether the cap was not reached
   */
  function capNotReached() public view returns (bool) {
      return weiRaised() < _cap;
  }
  
  /**
   * @dev Checks whether the cap has been reached.
   * @return Whether the cap was reached
   */
  function capReached() public view returns (bool) {
      return weiRaised() >= _cap;
  }
}

/**
 * @title PostDeliveryCappedCrowdsale
 * @notice Hardcapped crowdsale with the gained tokens locked from withdrawal until the crowdsale ends.
 */
contract PostDeliveryCappedTCO is CappedTCO, Haltable {
  using SafeMath for uint256;

  mapping(address => uint256) private _balances; //token balances storage until the crowdsale ends

  uint256 private _totalSupply; //total GUT distributed amount

  event TokensWithdrawn(
    address indexed beneficiary,
    uint256 amount
  );

  constructor() internal {}

  /**
   * @notice Withdraw tokens only after the crowdsale ends (closed).
   * @param beneficiary is an address whose tokens will be withdrawn. Allows to use a separate address 
   * @notice Withdrawal is suspended in case the crowdsale is paused.
   */
  function withdrawTokensFrom(address beneficiary) public whenNotPaused whenClosedOr(capReached()) {
    uint256 amount = _balances[beneficiary];
    require(amount > 0, 'The balance should be positive for withdrawal. Please check the balance in the token contract.');
    _balances[beneficiary] = 0;
    _deliverTokens(beneficiary, amount);
    emit TokensWithdrawn(beneficiary, amount);
  }

  /**
   * @notice If calling this function (wothdrawing) from a contract, use withdrawTokensFrom(address beneficiary)
   * Check that crowdsale is finished: GutTCO.isClosed() == true before running this function (withdrawing tokens).
   */
  function withdrawTokens() public {
    withdrawTokensFrom(address(msg.sender));
  }

  /**
   * @notice Total amount of tokens supplied
   */
  function totalSupply() public view returns (uint256) {
    return _totalSupply;
  }

  /**
   * @return the balance of an account.
   */
  function balanceOf(address account) public view returns(uint256) {
    return _balances[account];
  }

  /**
   * @dev Extend parent behavior requiring purchase to respect the funding cap.
   * @param beneficiary Token purchaser
   * @param weiAmount Amount of wei contributed
   */
  function _preValidatePurchase(
      address beneficiary,
      uint256 weiAmount
  )
      internal
      view
  {
      require(capNotReached(),"Hardcap is reached.");
      require(notClosed(), "TCO is finished, sorry.");
      super._preValidatePurchase(beneficiary, weiAmount);
  }

  /**
   * @dev Overrides parent by storing balances instead of issuing tokens right away
   * @param beneficiary Token purchaser
   * @param tokenAmount Amount of tokens purchased
   */
  function _processPurchase(
    address beneficiary,
    uint256 tokenAmount
  )
    internal
  {
    _balances[beneficiary] = _balances[beneficiary].add(tokenAmount);
    _totalSupply = _totalSupply.add(tokenAmount);
  }
}

/**
 * @notice If you transfer funds (ETH) from a contract, the default gas stipend 2300 will not be enough 
 * to complete transaction to your contract address. Please, consider calling buyTokens() directly when
 * purchasing tokens from a contract.
*/
contract GutTCO is 
PostDeliveryCappedTCO, 
IncreasingPriceTCO, 
MinterRole
{
    bool private _finalized;

    event CrowdsaleFinalized();

    constructor(
    uint256 _rate,
    address _wallet,
    uint256 _cap,
    ERC20Mintable _token
  ) public 
  Crowdsale(_rate, _wallet, _token)
  CappedTCO(_cap)
  IncreasingPriceTCO(initRates())
  {
    _finalized = false;
  }

  /**
   * @notice Initializes exchange rates ranges.
   */
  function initRates() internal pure returns(uint256[2][] memory ratesArray) {
     ratesArray = new uint256[2][](4);
     ratesArray[0] = [uint256(100000 ether), 3000]; //first 100000 ether are given 3000 GUT each
     ratesArray[1] = [uint256(300000 ether), 1500]; //next 200000 (up to 300000) ether are exchanged at 1500 GUT/ether 
     ratesArray[2] = [uint256(700000 ether), 500];  //next 400000 ether will go to Persono.id Foundation at 500 GUT/ether
     ratesArray[3] = [uint256(1500000 ether), 125]; //the rest 800000 ether are exchanged at 125 GUT/ether
  }

  function closeTCO() public onlyMinter {
     if(notFinalized()) _finalize();
  }

  /**
   * @return true if the crowdsale is finalized, false otherwise.
   */
  function finalized() public view returns (bool) {
    return _finalized;
  }

  /**
   * @return true if the crowdsale is finalized, false otherwise.
   */
  function notFinalized() public view returns (bool) {
    return !finalized();
  }

  /**
   * @notice Is called after TCO finished to close() TCO and transfer (mint) supplied tokens to the token's contract.
   */
  function _finalize() private {
    require(notFinalized(), 'TCO already finalized');
    if(notClosed()) close();
    _finalization();
    emit CrowdsaleFinalized();
  }

  function _finalization() private {
     if(totalSupply() > 0)
        require(ERC20Mintable(address(token())).mint(address(this), totalSupply()), 'Error when being finalized at minting totalSupply() to the token');
     _finalized = true;
  }

  /**
   * @notice Overrides IncreasingPriceTCO. Auto finalize TCO when the cap is reached.
   */
  function _updatePurchasingState(address beneficiary, uint256 weiAmount) internal 
  {
    super._updatePurchasingState(beneficiary, weiAmount);
    if(capReached()) _finalize();
  }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"rate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"notFinalized","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"cap","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"unpause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"account","type":"address"}],"name":"addKeeper","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"weiRaised","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"account","type":"address"}],"name":"isPauser","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"capReached","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"wallet","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"paused","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"closeTCO","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"account","type":"address"}],"name":"isKeeper","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"renouncePauser","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":"account","type":"address"}],"name":"addPauser","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"pause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"withdrawTokens","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"account","type":"address"}],"name":"addMinter","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceMinter","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"capNotReached","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"renounceKeeper","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"notClosed","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"account","type":"address"}],"name":"isMinter","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"finalized","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isClosed","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"beneficiary","type":"address"}],"name":"withdrawTokensFrom","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"beneficiary","type":"address"}],"name":"buyTokens","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"getCurrentRate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"token","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_rate","type":"uint256"},{"name":"_wallet","type":"address"},{"name":"_cap","type":"uint256"},{"name":"_token","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[],"name":"CrowdsaleFinalized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"MinterAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"MinterRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"rateIndex","type":"uint8"},{"indexed":false,"name":"exRate","type":"uint256"},{"indexed":false,"name":"weiRaisedRange","type":"uint256"},{"indexed":false,"name":"weiRaised","type":"uint256"}],"name":"NewRateIsSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"beneficiary","type":"address"},{"indexed":false,"name":"amount","type":"uint256"}],"name":"TokensWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"account","type":"address"}],"name":"Closed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"PauserAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"PauserRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"KeeperAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"account","type":"address"}],"name":"KeeperRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"purchaser","type":"address"},{"indexed":true,"name":"beneficiary","type":"address"},{"indexed":false,"name":"value","type":"uint256"},{"indexed":false,"name":"amount","type":"uint256"}],"name":"TokensPurchased","type":"event"}]

60806040523480156200001157600080fd5b50604051608080620027cd833981018060405281019080805190602001909291908051906020019092919080519060200190929190805190602001909291905050506200006c6200038e640100000000026401000000009004565b8285858460016000819055506000831115156200008857600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614151515620000c557600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156200010257600080fd5b8260038190555081600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505060008111151562000207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260148152602001807f4861726420636170206d757374206265203e203000000000000000000000000081525060200191505060405180910390fd5b80600581905550506200022933620004cd640100000000026401000000009004565b620002433362000537640100000000026401000000009004565b6000600860006101000a81548160ff0219169083151502179055506000600860016101000a81548160ff0219169083151502179055506001815111151562000319576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001807f52617465732061727261792073686f756c6420636f6e7461696e206d6f72652081526020017f7468656e206f6e652076616c756500000000000000000000000000000000000081525060400191505060405180910390fd5b80600b90805190602001906200033192919062000763565b506000600c60006101000a81548160ff021916908360ff160217905550506200036933620005a1640100000000026401000000009004565b6000600e60006101000a81548160ff0219169083151502179055505050505062000896565b60606004604051908082528060200260200182016040528015620003cf57816020015b620003bb620007c8565b815260200190600190039081620003b15790505b509050604080519081016040528069152d02c7e14af68000008152602001610bb88152508160008151811015156200040357fe5b906020019060200201819052506040805190810160405280693f870857a3e0e380000081526020016105dc8152508160018151811015156200044157fe5b90602001906020020181905250604080519081016040528069943b1377290cbd80000081526020016101f48152508160028151811015156200047f57fe5b9060200190602002018190525060408051908101604052806a013da329b63364718000008152602001607d815250816003815181101515620004bd57fe5b9060200190602002018190525090565b620004f18160066200060b64010000000002620017bc179091906401000000009004565b8073ffffffffffffffffffffffffffffffffffffffff167f1584773458d98c71b34a270ee1100b3a42889bf91e3b7a858563b684c24d838e60405160405180910390a250565b6200055b8160076200060b64010000000002620017bc179091906401000000009004565b8073ffffffffffffffffffffffffffffffffffffffff167f6719d08c1888103bea251a4ed56406bd0c3e69723c8a1686e017e7bbe159b6f860405160405180910390a250565b620005c581600d6200060b64010000000002620017bc179091906401000000009004565b8073ffffffffffffffffffffffffffffffffffffffff167f6ae172837ea30b801fbfcdd4108aa1d5bf8ff775444fd70256b44e6bf3dfc3f660405160405180910390a250565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156200064857600080fd5b620006638282620006ce640100000000026401000000009004565b1515156200067057600080fd5b60018260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141515156200070c57600080fd5b8260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b828054828255906000526020600020906002028101928215620007b5579160200282015b82811115620007b457825182906002620007a3929190620007ea565b509160200191906002019062000787565b5b509050620007c491906200082f565b5090565b6040805190810160405280600290602082028038833980820191505090505090565b82600281019282156200081c579160200282015b828111156200081b578251825591602001919060010190620007fe565b5b5090506200082b919062000860565b5090565b6200085d91905b808211156200085957600081816200084f919062000888565b5060020162000836565b5090565b90565b6200088591905b808211156200088157600081600090555060010162000867565b5090565b90565b506000815560010160009055565b611f2780620008a66000396000f300608060405260043610610180576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806318160ddd1461018b5780632c4e722e146101b657806332c669c4146101e1578063355274ea146102105780633f4ba83a1461023b5780634032b72b146102525780634042b66f1461029557806346fbf68e146102c05780634f9359451461031b578063521eb2731461034a5780635c975abb146103a15780635e5b1aec146103d05780636ba42aaa146103e75780636ef8d66d1461044257806370a082311461045957806382dc1ec4146104b05780638456cb59146104f35780638d8f2adb1461050a578063983b2d56146105215780639865027514610564578063a11a89661461057b578063a82ba2d5146105aa578063a9fb55c0146105c1578063aa271e1a146105f0578063b3f05b971461064b578063c2b6b58c1461067a578063e8a66f54146106a9578063ec8ac4d8146106ec578063f7fb07b014610722578063fc0c546a1461074d575b610189336107a4565b005b34801561019757600080fd5b506101a061089a565b6040518082815260200191505060405180910390f35b3480156101c257600080fd5b506101cb6108a4565b6040518082815260200191505060405180910390f35b3480156101ed57600080fd5b506101f66108ab565b604051808215151515815260200191505060405180910390f35b34801561021c57600080fd5b506102256108bb565b6040518082815260200191505060405180910390f35b34801561024757600080fd5b506102506108c5565b005b34801561025e57600080fd5b50610293600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506109dd565b005b3480156102a157600080fd5b506102aa610a66565b6040518082815260200191505060405180910390f35b3480156102cc57600080fd5b50610301600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610a70565b604051808215151515815260200191505060405180910390f35b34801561032757600080fd5b50610330610a8d565b604051808215151515815260200191505060405180910390f35b34801561035657600080fd5b5061035f610aa1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156103ad57600080fd5b506103b6610acb565b604051808215151515815260200191505060405180910390f35b3480156103dc57600080fd5b506103e5610ae2565b005b3480156103f357600080fd5b50610428600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b0e565b604051808215151515815260200191505060405180910390f35b34801561044e57600080fd5b50610457610b2b565b005b34801561046557600080fd5b5061049a600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b36565b6040518082815260200191505060405180910390f35b3480156104bc57600080fd5b506104f1600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b7f565b005b3480156104ff57600080fd5b50610508610b9f565b005b34801561051657600080fd5b5061051f610cb8565b005b34801561052d57600080fd5b50610562600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610cc3565b005b34801561057057600080fd5b50610579610ce3565b005b34801561058757600080fd5b50610590610cee565b604051808215151515815260200191505060405180910390f35b3480156105b657600080fd5b506105bf610d01565b005b3480156105cd57600080fd5b506105d6610d0c565b604051808215151515815260200191505060405180910390f35b3480156105fc57600080fd5b50610631600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610d24565b604051808215151515815260200191505060405180910390f35b34801561065757600080fd5b50610660610d41565b604051808215151515815260200191505060405180910390f35b34801561068657600080fd5b5061068f610d58565b604051808215151515815260200191505060405180910390f35b3480156106b557600080fd5b506106ea600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610d6f565b005b610720600480360381019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506107a4565b005b34801561072e57600080fd5b50610737611058565b6040518082815260200191505060405180910390f35b34801561075957600080fd5b5061076261109e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60008060006001600080828254019250508190555060005490503492506107cb84846110c8565b6107d4836111ce565b91506107eb836004546111f190919063ffffffff16565b6004819055506107fb8483611212565b8373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f6faf93231a456e552dbc9961f58d9713ee4f2e69d15f1975b050ef0911053a7b8585604051808381526020018281526020019250505060405180910390a361087284846112c6565b61087a6112ea565b6108848484611355565b6000548114151561089457600080fd5b50505050565b6000600a54905090565b6000806000fd5b60006108b5610d41565b15905090565b6000600554905090565b6108ce33610a70565b15156108d957600080fd5b600860009054906101000a900460ff16151561095d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f54686520636f6e7472616374206973206e6f742070617573656400000000000081525060200191505060405180910390fd5b6000600860006101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa33604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a1565b6109e633610b0e565b1515610a5a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204b656570657220697320616c6c6f7765640000000000000000000081525060200191505060405180910390fd5b610a6381611359565b50565b6000600454905090565b6000610a868260076113b390919063ffffffff16565b9050919050565b6000600554610a9a610a66565b1015905090565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600860009054906101000a900460ff16905090565b610aeb33610d24565b1515610af657600080fd5b610afe6108ab565b15610b0c57610b0b611447565b5b565b6000610b248260066113b390919063ffffffff16565b9050919050565b610b343361150f565b565b6000600960008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610b8833610a70565b1515610b9357600080fd5b610b9c81611569565b50565b610ba833610a70565b1515610bb357600080fd5b600860009054906101000a900460ff16151515610c38576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f54686520636f6e7472616374206973207061757365640000000000000000000081525060200191505060405180910390fd5b6001600860006101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25833604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a1565b610cc133610d6f565b565b610ccc33610d24565b1515610cd757600080fd5b610ce0816115c3565b50565b610cec3361161d565b565b6000600554610cfb610a66565b10905090565b610d0a33611677565b565b6000600860019054906101000a900460ff1615905090565b6000610d3a82600d6113b390919063ffffffff16565b9050919050565b6000600e60009054906101000a900460ff16905090565b6000600860019054906101000a900460ff16905090565b6000600860009054906101000a900460ff16151515610df6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f54686520636f6e7472616374206973207061757365640000000000000000000081525060200191505060405180910390fd5b610dfe610a8d565b600860019054906101000a900460ff1680610e165750805b1515610eb0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001807f4974206d75737420626520636c6f736564206f7220776861742069732073657481526020017f20696e20276f72436f6e646974696f6e2700000000000000000000000000000081525060400191505060405180910390fd5b600960008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549150600082111515610fb6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252605e8152602001807f5468652062616c616e63652073686f756c6420626520706f736974697665206681526020017f6f72207769746864726177616c2e20506c6561736520636865636b207468652081526020017f62616c616e636520696e2074686520746f6b656e20636f6e74726163742e000081525060600191505060405180910390fd5b6000600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555061100583836116d1565b8273ffffffffffffffffffffffffffffffffffffffff167f6352c5382c4a4578e712449ca65e83cdb392d045dfcf1cad9615189db2da244b836040518082815260200191505060405180910390a2505050565b6000600b600c60009054906101000a900460ff1660ff1681548110151561107b57fe5b9060005260206000209060020201600160028110151561109757fe5b0154905090565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6110d0610cee565b1515611144576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4861726463617020697320726561636865642e0000000000000000000000000081525060200191505060405180910390fd5b61114c610d0c565b15156111c0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260178152602001807f54434f2069732066696e69736865642c20736f7272792e00000000000000000081525060200191505060405180910390fd5b6111ca8282611722565b5050565b60006111ea826111dc611058565b61177290919063ffffffff16565b9050919050565b600080828401905083811015151561120857600080fd5b8091505092915050565b61126481600960008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020546111f190919063ffffffff16565b600960008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506112bc81600a546111f190919063ffffffff16565b600a819055505050565b6112d082826117b0565b6112d8610a8d565b156112e6576112e5611447565b5b5050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc349081150290604051600060405180830381858888f19350505050158015611352573d6000803e3d6000fd5b50565b5050565b61136d8160066117bc90919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167f1584773458d98c71b34a270ee1100b3a42889bf91e3b7a858563b684c24d838e60405160405180910390a250565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141515156113f057600080fd5b8260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b61144f6108ab565b15156114c3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260158152602001807f54434f20616c72656164792066696e616c697a6564000000000000000000000081525060200191505060405180910390fd5b6114cb610d0c565b156114d9576114d861186c565b5b6114e1611971565b7f9270cc390c096600a1c17c44345a1ba689fafd99d97487b10cfccf86cf73183660405160405180910390a1565b611523816007611b2590919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167fcd265ebaf09df2871cc7bd4133404a235ba12eff2041bb89d9c714a2621c7c7e60405160405180910390a250565b61157d8160076117bc90919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167f6719d08c1888103bea251a4ed56406bd0c3e69723c8a1686e017e7bbe159b6f860405160405180910390a250565b6115d781600d6117bc90919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167f6ae172837ea30b801fbfcdd4108aa1d5bf8ff775444fd70256b44e6bf3dfc3f660405160405180910390a250565b61163181600d611b2590919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167fe94479a9f7e1952cc78f2d6baab678adc1b772d936c6583def489e524cb6669260405160405180910390a250565b61168b816006611b2590919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167fa7a775c2c8141f7985c111748ec31c11e5e44b83528e105c8d1d4e8e6b81cf8060405160405180910390a250565b61171e8282600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611bd49092919063ffffffff16565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561175e57600080fd5b6000811415151561176e57600080fd5b5050565b600080600084141561178757600091506117a9565b828402905082848281151561179857fe5b041415156117a557600080fd5b8091505b5092915050565b6117b8611cc2565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156117f857600080fd5b61180282826113b3565b15151561180e57600080fd5b60018260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b600860019054906101000a900460ff161515156118f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f5265766572746564206265636175736520697420697320636c6f73656400000081525060200191505060405180910390fd5b6001600860016101000a81548160ff0219169083151502179055507f13607bf9d2dd20e1f3a7daf47ab12856f8aad65e6ae7e2c75ace3d0c424a40e833604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a1565b600061197b61089a565b1115611b085761198961109e565b73ffffffffffffffffffffffffffffffffffffffff166340c10f19306119ad61089a565b6040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015611a3257600080fd5b505af1158015611a46573d6000803e3d6000fd5b505050506040513d6020811015611a5c57600080fd5b81019080805190602001909291905050501515611b07576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260408152602001807f4572726f72207768656e206265696e672066696e616c697a6564206174206d6981526020017f6e74696e6720746f74616c537570706c79282920746f2074686520746f6b656e81525060400191505060405180910390fd5b5b6001600e60006101000a81548160ff021916908315150217905550565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614151515611b6157600080fd5b611b6b82826113b3565b1515611b7657600080fd5b60008260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b8273ffffffffffffffffffffffffffffffffffffffff1663a9059cbb83836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015611c7757600080fd5b505af1158015611c8b573d6000803e3d6000fd5b505050506040513d6020811015611ca157600080fd5b81019080805190602001909291905050501515611cbd57600080fd5b505050565b6000600b600c60009054906101000a900460ff1660ff16815481101515611ce557fe5b90600052602060002090600202016000600281101515611d0157fe5b0154611d0b610a66565b10158015611d3257506001600b8054905003600c60009054906101000a900460ff1660ff16105b15611ef857611d3f610a66565b9050600c600081819054906101000a900460ff168092919060010191906101000a81548160ff021916908360ff160217905550505b6001600b8054905003600c60009054906101000a900460ff1660ff16108015611ddb575080600b600c60009054906101000a900460ff1660ff16815481101515611dba57fe5b90600052602060002090600202016000600281101515611dd657fe5b015411155b15611e1757600c600081819054906101000a900460ff168092919060010191906101000a81548160ff021916908360ff16021790555050611d74565b7fe6c7293394d059a65fe1793802d17864412e1c7cfe83e3f2311a9e0c16686fcc600c60009054906101000a900460ff16600b600c60009054906101000a900460ff1660ff16815481101515611e6957fe5b90600052602060002090600202016001600281101515611e8557fe5b0154600b600c60009054906101000a900460ff1660ff16815481101515611ea857fe5b90600052602060002090600202016000600281101515611ec457fe5b015484604051808560ff1660ff16815260200184815260200183815260200182815260200194505050505060405180910390a15b505600a165627a7a723058202e07cd89900f10a7c8c7f47aadf9816d673c0b6d7864246545c1b872e78322f200290000000000000000000000000000000000000000000000000000000000000001000000000000000000000000ceb8e7aeb51caafb1edd59c8d5a4514bd54ddd38000000000000000000000000000000000000000000013da329b6336471800000000000000000000000000000ba01aff9ef5198b5e691d2ac61e3cc126f25491d

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000ceb8e7aeb51caafb1edd59c8d5a4514bd54ddd38000000000000000000000000000000000000000000013da329b6336471800000000000000000000000000000ba01aff9ef5198b5e691d2ac61e3cc126f25491d

-----Decoded View---------------
Arg [0] : _rate (uint256): 1
Arg [1] : _wallet (address): 0xceb8e7aeb51caafb1edd59c8d5a4514bd54ddd38
Arg [2] : _cap (uint256): 1500000000000000000000000
Arg [3] : _token (address): 0xba01aff9ef5198b5e691d2ac61e3cc126f25491d

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [1] : 000000000000000000000000ceb8e7aeb51caafb1edd59c8d5a4514bd54ddd38
Arg [2] : 000000000000000000000000000000000000000000013da329b6336471800000
Arg [3] : 000000000000000000000000ba01aff9ef5198b5e691d2ac61e3cc126f25491d


Swarm Source

bzzr://2e07cd89900f10a7c8c7f47aadf9816d673c0b6d7864246545c1b872e78322f2
Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.