ETH Price: $3,160.38 (-3.63%)

Token

CipherBlock (CBK)
 

Overview

Max Total Supply

1,000,000,000 CBK

Holders

389

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 8 Decimals)

Balance
16,500 CBK

Value
$0.00
0xBD8CE60e41c0f9756A71c5617094c7b54BBE2a20
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
CustomToken

Compiler Version
v0.4.19+commit.c4cbbb05

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
/**
 *Submitted for verification at Etherscan.io on 2018-02-23
*/

pragma solidity ^0.4.19;

contract BaseToken {
    string public name;
    string public symbol;
    uint8 public decimals;
    uint256 public totalSupply;

    mapping (address => uint256) public balanceOf;
    mapping (address => mapping (address => uint256)) public allowance;

    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);

    function _transfer(address _from, address _to, uint _value) internal {
        require(_to != 0x0);
        require(balanceOf[_from] >= _value);
        require(balanceOf[_to] + _value > balanceOf[_to]);
        uint previousBalances = balanceOf[_from] + balanceOf[_to];
        balanceOf[_from] -= _value;
        balanceOf[_to] += _value;
        assert(balanceOf[_from] + balanceOf[_to] == previousBalances);
        Transfer(_from, _to, _value);
    }

    function transfer(address _to, uint256 _value) public returns (bool success) {
        _transfer(msg.sender, _to, _value);
        return true;
    }

    function transferFrom(address _from, address _to, uint256 _value) public returns (bool success) {
        require(_value <= allowance[_from][msg.sender]);
        allowance[_from][msg.sender] -= _value;
        _transfer(_from, _to, _value);
        return true;
    }

    function approve(address _spender, uint256 _value) public returns (bool success) {
        allowance[msg.sender][_spender] = _value;
        Approval(msg.sender, _spender, _value);
        return true;
    }
}

contract BurnToken is BaseToken {
    event Burn(address indexed from, uint256 value);

    function burn(uint256 _value) public returns (bool success) {
        require(balanceOf[msg.sender] >= _value);
        balanceOf[msg.sender] -= _value;
        totalSupply -= _value;
        Burn(msg.sender, _value);
        return true;
    }

    function burnFrom(address _from, uint256 _value) public returns (bool success) {
        require(balanceOf[_from] >= _value);
        require(_value <= allowance[_from][msg.sender]);
        balanceOf[_from] -= _value;
        allowance[_from][msg.sender] -= _value;
        totalSupply -= _value;
        Burn(_from, _value);
        return true;
    }
}

contract ICOToken is BaseToken {
    // 1 ether = icoRatio token
    uint256 public icoRatio;
    uint256 public icoEndtime;
    address public icoSender;
    address public icoHolder;

    event ICO(address indexed from, uint256 indexed value, uint256 tokenValue);
    event Withdraw(address indexed from, address indexed holder, uint256 value);

    modifier onlyBefore() {
        if (now > icoEndtime) {
            revert();
        }
        _;
    }

    function() public payable onlyBefore {
        uint256 tokenValue = (msg.value * icoRatio * 10 ** uint256(decimals)) / (1 ether / 1 wei);
        if (tokenValue == 0 || balanceOf[icoSender] < tokenValue) {
            revert();
        }
        _transfer(icoSender, msg.sender, tokenValue);
        ICO(msg.sender, msg.value, tokenValue);
    }

    function withdraw() {
        uint256 balance = this.balance;
        icoHolder.transfer(balance);
        Withdraw(msg.sender, icoHolder, balance);
    }
}

contract CustomToken is BaseToken, BurnToken, ICOToken {
    function CustomToken() public {
        totalSupply = 100000000000000000;
        balanceOf[0x1e9a8a2ca5a67f3078825918bdd6edf3fba37fe8] = totalSupply;
        name = 'CipherBlock';
        symbol = 'CBK';
        decimals = 8;
        icoRatio = 15000;
        icoEndtime = 1519833600;
        icoSender = 0x1e9a8a2ca5a67f3078825918bdd6edf3fba37fe8;
        icoHolder = 0x1e9a8a2ca5a67f3078825918bdd6edf3fba37fe8;
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_value","type":"uint256"}],"name":"burn","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_value","type":"uint256"}],"name":"burnFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"icoHolder","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"icoRatio","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"icoEndtime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"},{"name":"","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"icoSender","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"value","type":"uint256"},{"indexed":false,"name":"tokenValue","type":"uint256"}],"name":"ICO","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"holder","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Withdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Burn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"spender","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Approval","type":"event"}]

6060604052341561000f57600080fd5b67016345785d8a00006003819055731e9a8a2ca5a67f3078825918bdd6edf3fba37fe860005260046020527fad110abe74f1c3927e0b0fb255ca82c12939b554631aa70af5a1964b90c7badf5560408051908101604052600b81527f436970686572426c6f636b000000000000000000000000000000000000000000602082015260009080516100a3929160200190610144565b5060408051908101604052600381527f43424b0000000000000000000000000000000000000000000000000000000000602082015260019080516100eb929160200190610144565b506002805460ff19166008908117909155613a98600655635a96d2006007558054600160a060020a0319908116731e9a8a2ca5a67f3078825918bdd6edf3fba37fe89081179092556009805490911690911790556101df565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061018557805160ff19168380011785556101b2565b828001600101855582156101b2579182015b828111156101b2578251825591602001919060010190610197565b506101be9291506101c2565b5090565b6101dc91905b808211156101be57600081556001016101c8565b90565b61096e806101ee6000396000f3006060604052600436106100e55763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde03811461019d578063095ea7b31461022757806318160ddd1461025d57806323b872dd14610282578063313ce567146102aa5780633ccfd60b146102d357806342966c68146102e857806370a08231146102fe57806379cc67901461031d57806395d89b411461033f578063a2ebb20b14610352578063a9059cbb14610381578063b3b8c620146103a3578063d211fe86146103b6578063dd62ed3e146103c9578063de28fc1d146103ee575b60006007544211156100f657600080fd5b600254600654670de0b6b3a76400009160ff16600a0a349091020204905080158061013b5750600854600160a060020a03166000908152600460205260409020548190105b1561014557600080fd5b60085461015c90600160a060020a03163383610401565b3433600160a060020a03167f4a987bc3d04b32db133ad9a3c7c0d8ecc441eb56f45a62b92c38384c095e7ac08360405190815260200160405180910390a350005b34156101a857600080fd5b6101b06104f2565b60405160208082528190810183818151815260200191508051906020019080838360005b838110156101ec5780820151838201526020016101d4565b50505050905090810190601f1680156102195780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561023257600080fd5b610249600160a060020a0360043516602435610590565b604051901515815260200160405180910390f35b341561026857600080fd5b6102706105fc565b60405190815260200160405180910390f35b341561028d57600080fd5b610249600160a060020a0360043581169060243516604435610602565b34156102b557600080fd5b6102bd610679565b60405160ff909116815260200160405180910390f35b34156102de57600080fd5b6102e6610682565b005b34156102f357600080fd5b610249600435610701565b341561030957600080fd5b610270600160a060020a036004351661078c565b341561032857600080fd5b610249600160a060020a036004351660243561079e565b341561034a57600080fd5b6101b061087a565b341561035d57600080fd5b6103656108e5565b604051600160a060020a03909116815260200160405180910390f35b341561038c57600080fd5b610249600160a060020a03600435166024356108f4565b34156103ae57600080fd5b61027061090a565b34156103c157600080fd5b610270610910565b34156103d457600080fd5b610270600160a060020a0360043581169060243516610916565b34156103f957600080fd5b610365610933565b6000600160a060020a038316151561041857600080fd5b600160a060020a0384166000908152600460205260409020548290101561043e57600080fd5b600160a060020a0383166000908152600460205260409020548281011161046457600080fd5b50600160a060020a0382811660009081526004602052604080822080549387168352912080548481038255825485019283905590549201910181146104a557fe5b82600160a060020a031684600160a060020a03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405190815260200160405180910390a350505050565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105885780601f1061055d57610100808354040283529160200191610588565b820191906000526020600020905b81548152906001019060200180831161056b57829003601f168201915b505050505081565b600160a060020a03338116600081815260056020908152604080832094871680845294909152808220859055909291907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b60035481565b600160a060020a0380841660009081526005602090815260408083203390941683529290529081205482111561063757600080fd5b600160a060020a038085166000908152600560209081526040808320339094168352929052208054839003905561066f848484610401565b5060019392505050565b60025460ff1681565b600954600160a060020a0330811631911681156108fc0282604051600060405180830381858888f1935050505015156106ba57600080fd5b600954600160a060020a039081169033167f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb8360405190815260200160405180910390a350565b600160a060020a0333166000908152600460205260408120548290101561072757600080fd5b600160a060020a03331660008181526004602052604090819020805485900390556003805485900390557fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59084905190815260200160405180910390a2506001919050565b60046020526000908152604090205481565b600160a060020a038216600090815260046020526040812054829010156107c457600080fd5b600160a060020a03808416600090815260056020908152604080832033909416835292905220548211156107f757600080fd5b600160a060020a038084166000818152600460209081526040808320805488900390556005825280832033909516835293905282902080548590039055600380548590039055907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59084905190815260200160405180910390a250600192915050565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105885780601f1061055d57610100808354040283529160200191610588565b600954600160a060020a031681565b6000610901338484610401565b50600192915050565b60065481565b60075481565b600560209081526000928352604080842090915290825290205481565b600854600160a060020a0316815600a165627a7a723058203bcd5a6d21804f3d26aca2aa7f1a94935e5b17bd6525afdc9e285f4fa209e7ab0029

Deployed Bytecode

0x6060604052600436106100e55763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde03811461019d578063095ea7b31461022757806318160ddd1461025d57806323b872dd14610282578063313ce567146102aa5780633ccfd60b146102d357806342966c68146102e857806370a08231146102fe57806379cc67901461031d57806395d89b411461033f578063a2ebb20b14610352578063a9059cbb14610381578063b3b8c620146103a3578063d211fe86146103b6578063dd62ed3e146103c9578063de28fc1d146103ee575b60006007544211156100f657600080fd5b600254600654670de0b6b3a76400009160ff16600a0a349091020204905080158061013b5750600854600160a060020a03166000908152600460205260409020548190105b1561014557600080fd5b60085461015c90600160a060020a03163383610401565b3433600160a060020a03167f4a987bc3d04b32db133ad9a3c7c0d8ecc441eb56f45a62b92c38384c095e7ac08360405190815260200160405180910390a350005b34156101a857600080fd5b6101b06104f2565b60405160208082528190810183818151815260200191508051906020019080838360005b838110156101ec5780820151838201526020016101d4565b50505050905090810190601f1680156102195780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561023257600080fd5b610249600160a060020a0360043516602435610590565b604051901515815260200160405180910390f35b341561026857600080fd5b6102706105fc565b60405190815260200160405180910390f35b341561028d57600080fd5b610249600160a060020a0360043581169060243516604435610602565b34156102b557600080fd5b6102bd610679565b60405160ff909116815260200160405180910390f35b34156102de57600080fd5b6102e6610682565b005b34156102f357600080fd5b610249600435610701565b341561030957600080fd5b610270600160a060020a036004351661078c565b341561032857600080fd5b610249600160a060020a036004351660243561079e565b341561034a57600080fd5b6101b061087a565b341561035d57600080fd5b6103656108e5565b604051600160a060020a03909116815260200160405180910390f35b341561038c57600080fd5b610249600160a060020a03600435166024356108f4565b34156103ae57600080fd5b61027061090a565b34156103c157600080fd5b610270610910565b34156103d457600080fd5b610270600160a060020a0360043581169060243516610916565b34156103f957600080fd5b610365610933565b6000600160a060020a038316151561041857600080fd5b600160a060020a0384166000908152600460205260409020548290101561043e57600080fd5b600160a060020a0383166000908152600460205260409020548281011161046457600080fd5b50600160a060020a0382811660009081526004602052604080822080549387168352912080548481038255825485019283905590549201910181146104a557fe5b82600160a060020a031684600160a060020a03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405190815260200160405180910390a350505050565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105885780601f1061055d57610100808354040283529160200191610588565b820191906000526020600020905b81548152906001019060200180831161056b57829003601f168201915b505050505081565b600160a060020a03338116600081815260056020908152604080832094871680845294909152808220859055909291907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b60035481565b600160a060020a0380841660009081526005602090815260408083203390941683529290529081205482111561063757600080fd5b600160a060020a038085166000908152600560209081526040808320339094168352929052208054839003905561066f848484610401565b5060019392505050565b60025460ff1681565b600954600160a060020a0330811631911681156108fc0282604051600060405180830381858888f1935050505015156106ba57600080fd5b600954600160a060020a039081169033167f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb8360405190815260200160405180910390a350565b600160a060020a0333166000908152600460205260408120548290101561072757600080fd5b600160a060020a03331660008181526004602052604090819020805485900390556003805485900390557fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59084905190815260200160405180910390a2506001919050565b60046020526000908152604090205481565b600160a060020a038216600090815260046020526040812054829010156107c457600080fd5b600160a060020a03808416600090815260056020908152604080832033909416835292905220548211156107f757600080fd5b600160a060020a038084166000818152600460209081526040808320805488900390556005825280832033909516835293905282902080548590039055600380548590039055907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59084905190815260200160405180910390a250600192915050565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105885780601f1061055d57610100808354040283529160200191610588565b600954600160a060020a031681565b6000610901338484610401565b50600192915050565b60065481565b60075481565b600560209081526000928352604080842090915290825290205481565b600854600160a060020a0316815600a165627a7a723058203bcd5a6d21804f3d26aca2aa7f1a94935e5b17bd6525afdc9e285f4fa209e7ab0029

Swarm Source

bzzr://3bcd5a6d21804f3d26aca2aa7f1a94935e5b17bd6525afdc9e285f4fa209e7ab
Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.