Note: This is the official https://www.hellogold.org/ token sale contract address
More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 3,887 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Withdraw | 12693566 | 1308 days ago | IN | 0 ETH | 0.0002787 | ||||
Unblock | 4338897 | 2665 days ago | IN | 0 ETH | 0.00060843 | ||||
Approve | 4338889 | 2665 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338885 | 2665 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338789 | 2665 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338784 | 2665 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338727 | 2665 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338655 | 2666 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4338267 | 2666 days ago | IN | 0 ETH | 0.00098709 | ||||
Approve | 4338059 | 2666 days ago | IN | 0 ETH | 0.00106611 | ||||
Approve | 4337822 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4337721 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4337701 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4337700 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4337699 | 2666 days ago | IN | 0 ETH | 0.00088446 | ||||
Approve | 4337686 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4337685 | 2666 days ago | IN | 0 ETH | 0.00088446 | ||||
Approve | 4337681 | 2666 days ago | IN | 0 ETH | 0.00088574 | ||||
Approve | 4335130 | 2667 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4335107 | 2667 days ago | IN | 0 ETH | 0.00093002 | ||||
Block | 4335001 | 2667 days ago | IN | 0 ETH | 0.00060162 | ||||
Approve | 4334714 | 2667 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4334706 | 2667 days ago | IN | 0 ETH | 0.00093002 | ||||
Approve | 4333071 | 2667 days ago | IN | 0 ETH | 0.00092868 | ||||
Approve | 4332622 | 2668 days ago | IN | 0 ETH | 0.00132861 |
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
4289943 | 2682 days ago | 10 ETH | ||||
4289943 | 2682 days ago | 5 ETH | ||||
4289925 | 2682 days ago | 1.3 ETH | ||||
4289758 | 2682 days ago | 5.3 ETH | ||||
4289736 | 2682 days ago | 3 ETH | ||||
4289614 | 2682 days ago | 3 ETH | ||||
4289542 | 2682 days ago | 1.5 ETH | ||||
4289429 | 2682 days ago | 1 ETH | ||||
4288102 | 2682 days ago | 4 ETH | ||||
4287509 | 2682 days ago | 1 ETH | ||||
4286880 | 2683 days ago | 3.35986196 ETH | ||||
4286643 | 2683 days ago | 3 ETH | ||||
4286596 | 2683 days ago | 2.63 ETH | ||||
4286410 | 2683 days ago | 1.5 ETH | ||||
4286389 | 2683 days ago | 2 ETH | ||||
4286234 | 2683 days ago | 1.5 ETH | ||||
4286001 | 2683 days ago | 10 ETH | ||||
4286001 | 2683 days ago | 0.5 ETH | ||||
4285985 | 2683 days ago | 1 ETH | ||||
4285805 | 2683 days ago | 0.1 ETH | ||||
4285804 | 2683 days ago | 0.1 ETH | ||||
4285276 | 2683 days ago | 7 ETH | ||||
4283944 | 2683 days ago | 0.5 ETH | ||||
4281258 | 2684 days ago | 0.8 ETH | ||||
4281211 | 2684 days ago | 0.015559 ETH |
Loading...
Loading
Contract Name:
HelloGoldSale
Compiler Version
v0.4.16+commit.d7661dd9
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2017-08-26 */ pragma solidity ^0.4.11; contract DoNotDeployThisGetTheRightOneCosParityPutsThisOnTop { uint256 nothing; function DoNotDeployThisGetTheRightOneCosParityPutsThisOnTop() { nothing = 27; } } //*************** Ownable contract Ownable { address public owner; function Ownable() { owner = msg.sender; } modifier onlyOwner() { require(msg.sender == owner); _; } function transferOwnership(address newOwner) onlyOwner { if (newOwner != address(0)) { owner = newOwner; } } } //***********Pausible contract Pausable is Ownable { event Pause(); event Unpause(); bool public paused = false; /** * @dev modifier to allow actions only when the contract IS paused */ modifier whenNotPaused() { require (!paused); _; } /** * @dev modifier to allow actions only when the contract IS NOT paused */ modifier whenPaused { require (paused) ; _; } /** * @dev called by the owner to pause, triggers stopped state */ function pause() onlyOwner whenNotPaused returns (bool) { paused = true; Pause(); return true; } /** * @dev called by the owner to unpause, returns to normal state */ function unpause() onlyOwner whenPaused returns (bool) { paused = false; Unpause(); return true; } } //*************ERC20 contract ERC20 { uint public totalSupply; function balanceOf(address who) constant returns (uint); function allowance(address owner, address spender) constant returns (uint); function transfer(address to, uint value) returns (bool ok); function transferFrom(address from, address to, uint value) returns (bool ok); function approve(address spender, uint value) returns (bool ok); event Transfer(address indexed from, address indexed to, uint value); event Approval(address indexed owner, address indexed spender, uint value); } //*************** SafeMath contract SafeMath { function safeMul(uint a, uint b) internal returns (uint) { uint c = a * b; assert(a == 0 || c / a == b); return c; } function safeDiv(uint a, uint b) internal returns (uint) { assert(b > 0); uint c = a / b; assert(a == b * c + a % b); return c; } function safeSub(uint a, uint b) internal returns (uint) { assert(b <= a); return a - b; } function safeAdd(uint a, uint b) internal returns (uint) { uint c = a + b; assert(c>=a && c>=b); return c; } function max64(uint64 a, uint64 b) internal constant returns (uint64) { return a >= b ? a : b; } function min64(uint64 a, uint64 b) internal constant returns (uint64) { return a < b ? a : b; } function max256(uint256 a, uint256 b) internal constant returns (uint256) { return a >= b ? a : b; } function min256(uint256 a, uint256 b) internal constant returns (uint256) { return a < b ? a : b; } } //**************** StandardToken contract StandardToken is ERC20, SafeMath { /** * @dev Fix for the ERC20 short address attack. */ modifier onlyPayloadSize(uint size) { require(msg.data.length >= size + 4); _; } mapping(address => uint) balances; mapping (address => mapping (address => uint)) allowed; function transfer(address _to, uint _value) onlyPayloadSize(2 * 32) returns (bool success){ balances[msg.sender] = safeSub(balances[msg.sender], _value); balances[_to] = safeAdd(balances[_to], _value); Transfer(msg.sender, _to, _value); return true; } function transferFrom(address _from, address _to, uint _value) onlyPayloadSize(3 * 32) returns (bool success) { var _allowance = allowed[_from][msg.sender]; // Check is not needed because safeSub(_allowance, _value) will already throw if this condition is not met // if (_value > _allowance) throw; balances[_to] = safeAdd(balances[_to], _value); balances[_from] = safeSub(balances[_from], _value); allowed[_from][msg.sender] = safeSub(_allowance, _value); Transfer(_from, _to, _value); return true; } function balanceOf(address _owner) constant returns (uint balance) { return balances[_owner]; } function approve(address _spender, uint _value) returns (bool success) { require((_value == 0) || (allowed[msg.sender][_spender] == 0)); allowed[msg.sender][_spender] = _value; Approval(msg.sender, _spender, _value); return true; } function allowance(address _owner, address _spender) constant returns (uint remaining) { return allowed[_owner][_spender]; } } contract GBT { function parentChange(address,uint); function parentFees(address); function setHGT(address _hgt); } //************ HELLOGOLDTOKEN contract HelloGoldToken is ERC20, SafeMath, Pausable, StandardToken { string public name; string public symbol; uint8 public decimals; GBT goldtoken; function setGBT(address gbt_) onlyOwner { goldtoken = GBT(gbt_); } function GBTAddress() constant returns (address) { return address(goldtoken); } function HelloGoldToken(address _reserve) { name = "HelloGold Token"; symbol = "HGT"; decimals = 8; totalSupply = 1 * 10 ** 9 * 10 ** uint256(decimals); balances[_reserve] = totalSupply; } function parentChange(address _to) internal { require(address(goldtoken) != 0x0); goldtoken.parentChange(_to,balances[_to]); } function parentFees(address _to) internal { require(address(goldtoken) != 0x0); goldtoken.parentFees(_to); } function transferFrom(address _from, address _to, uint256 _value) returns (bool success){ parentFees(_from); parentFees(_to); success = super.transferFrom(_from,_to,_value); parentChange(_from); parentChange(_to); return; } function transfer(address _to, uint _value) whenNotPaused returns (bool success) { parentFees(msg.sender); parentFees(_to); success = super.transfer(_to,_value); parentChange(msg.sender); parentChange(_to); return; } function approve(address _spender, uint _value) whenNotPaused returns (bool success) { return super.approve(_spender,_value); } } //********* GOLDFEES ************************ contract GoldFees is SafeMath,Ownable { // e.g. if rate = 0.0054 //uint rateN = 9999452055; uint rateN = 9999452054794520548; uint rateD = 19; uint public maxDays; uint public maxRate; function GoldFees() { calcMax(); } function calcMax() { maxDays = 1; maxRate = rateN; uint pow = 2; do { uint newN = rateN ** pow; if (newN / maxRate != maxRate) { maxDays = pow / 2; break; } maxRate = newN; pow *= 2; } while (pow < 2000); } function updateRate(uint256 _n, uint256 _d) onlyOwner{ rateN = _n; rateD = _d; calcMax(); } function rateForDays(uint256 numDays) constant returns (uint256 rate) { if (numDays <= maxDays) { uint r = rateN ** numDays; uint d = rateD * numDays; if (d > 18) { uint div = 10 ** (d-18); rate = r / div; } else { div = 10 ** (18 - d); rate = r * div; } } else { uint256 md1 = numDays / 2; uint256 md2 = numDays - md1; uint256 r2; uint256 r1 = rateForDays(md1); if (md1 == md2) { r2 = r1; } else { r2 = rateForDays(md2); } //uint256 r1 = rateForDays(maxDays); //uint256 r2 = rateForDays(numDays-maxDays); rate = safeMul( r1 , r2) / 10 ** 18; } return; } uint256 constant public UTC2MYT = 1483200000; function wotDay(uint256 time) returns (uint256) { return (time - UTC2MYT) / (1 days); } // minimum fee is 1 unless same day function calcFees(uint256 start, uint256 end, uint256 startAmount) constant returns (uint256 amount, uint256 fee) { if (startAmount == 0) return; uint256 numberOfDays = wotDay(end) - wotDay(start); if (numberOfDays == 0) { amount = startAmount; return; } amount = (rateForDays(numberOfDays) * startAmount) / (1 ether); if ((fee == 0) && (amount != 0)) amount--; fee = safeSub(startAmount,amount); } } //******************** GoldBackedToken contract GoldBackedToken is Ownable, SafeMath, ERC20, Pausable { event Transfer(address indexed from, address indexed to, uint value); event Approval(address indexed owner, address indexed spender, uint value); event DeductFees(address indexed owner,uint256 amount); event TokenMinted(address destination, uint256 amount); event TokenBurned(address source, uint256 amount); string public name = "HelloGold Gold Backed Token"; string public symbol = "GBT"; uint256 constant public decimals = 18; // same as ETH uint256 constant public hgtDecimals = 8; uint256 constant public allocationPool = 1 * 10**9 * 10**hgtDecimals; // total HGT holdings uint256 constant public maxAllocation = 38 * 10**5 * 10**decimals; // max GBT that can ever ever be given out uint256 public totAllocation; // amount of GBT so far address public feeCalculator; address public HGT; // HGT contract address function setFeeCalculator(address newFC) onlyOwner { feeCalculator = newFC; } function calcFees(uint256 from, uint256 to, uint256 amount) returns (uint256 val, uint256 fee) { return GoldFees(feeCalculator).calcFees(from,to,amount); } function GoldBackedToken(address feeCalc) { feeCalculator = feeCalc; } struct allocation { uint256 amount; uint256 date; } allocation[] public allocationsOverTime; allocation[] public currentAllocations; function currentAllocationLength() constant returns (uint256) { return currentAllocations.length; } function aotLength() constant returns (uint256) { return allocationsOverTime.length; } struct Balance { uint256 amount; // amount through update or transfer uint256 lastUpdated; // DATE last updated uint256 nextAllocationIndex; // which allocationsOverTime record contains next update uint256 allocationShare; // the share of allocationPool that this holder gets (means they hold HGT) } /*Creates an array with all balances*/ mapping (address => Balance) public balances; mapping (address => mapping (address => uint)) allowed; function update(address where) internal { uint256 pos; uint256 fees; uint256 val; (val,fees,pos) = updatedBalance(where); balances[where].nextAllocationIndex = pos; balances[where].amount = val; balances[where].lastUpdated = now; } function updatedBalance(address where) constant public returns (uint val, uint fees, uint pos) { uint256 c_val; uint256 c_fees; uint256 c_amount; (val, fees) = calcFees(balances[where].lastUpdated,now,balances[where].amount); pos = balances[where].nextAllocationIndex; if ((pos < currentAllocations.length) && (balances[where].allocationShare != 0)) { c_amount = currentAllocations[balances[where].nextAllocationIndex].amount * balances[where].allocationShare / allocationPool; (c_val,c_fees) = calcFees(currentAllocations[balances[where].nextAllocationIndex].date,now,c_amount); } val += c_val; fees += c_fees; pos = currentAllocations.length; } function balanceOf(address where) constant returns (uint256 val) { uint256 fees; uint256 pos; (val,fees,pos) = updatedBalance(where); return ; } event Allocation(uint256 amount, uint256 date); event FeeOnAllocation(uint256 fees, uint256 date); event PartComplete(); event StillToGo(uint numLeft); uint256 public partPos; uint256 public partFees; uint256 partL; allocation[] public partAllocations; function partAllocationLength() constant returns (uint) { return partAllocations.length; } function addAllocationPartOne(uint newAllocation,uint numSteps) onlyOwner{ uint256 thisAllocation = newAllocation; require(totAllocation < maxAllocation); // cannot allocate more than this; if (currentAllocations.length > partAllocations.length) { partAllocations = currentAllocations; } if (totAllocation + thisAllocation > maxAllocation) { thisAllocation = maxAllocation - totAllocation; log0("max alloc reached"); } totAllocation += thisAllocation; Allocation(thisAllocation,now); allocation memory newDiv; newDiv.amount = thisAllocation; newDiv.date = now; // store into history allocationsOverTime.push(newDiv); // add this record to the end of currentAllocations partL = partAllocations.push(newDiv); // update all other records with calcs from last record if (partAllocations.length < 2) { // no fees to consider PartComplete(); currentAllocations = partAllocations; FeeOnAllocation(0,now); return; } // // The only fees that need to be collected are the fees on location zero. // Since they are the last calculated = they come out with the break // for (partPos = partAllocations.length - 2; partPos >= 0; partPos-- ){ (partAllocations[partPos].amount,partFees) = calcFees(partAllocations[partPos].date,now,partAllocations[partPos].amount); partAllocations[partPos].amount += partAllocations[partL - 1].amount; partAllocations[partPos].date = now; if ((partPos == 0) || (partPos == partAllocations.length-numSteps)){ break; } } if (partPos != 0) { StillToGo(partPos); return; // not done yet } PartComplete(); FeeOnAllocation(partFees,now); currentAllocations = partAllocations; } function addAllocationPartTwo(uint numSteps) onlyOwner { require(numSteps > 0); require(partPos > 0); for (uint i = 0; i < numSteps; i++ ){ partPos--; (partAllocations[partPos].amount,partFees) = calcFees(partAllocations[partPos].date,now,partAllocations[partPos].amount); partAllocations[partPos].amount += partAllocations[partL - 1].amount; partAllocations[partPos].date = now; if (partPos == 0) { break; } } if (partPos != 0) { StillToGo(partPos); return; // not done yet } PartComplete(); FeeOnAllocation(partFees,now); currentAllocations = partAllocations; } function setHGT(address _hgt) onlyOwner { HGT = _hgt; } function parentFees(address where) whenNotPaused { require(msg.sender == HGT); update(where); } function parentChange(address where, uint newValue) whenNotPaused { // called when HGT balance changes require(msg.sender == HGT); balances[where].allocationShare = newValue; } /* send GBT */ function transfer(address _to, uint256 _value) whenNotPaused returns (bool ok) { update(msg.sender); // Do this to ensure sender has enough funds. update(_to); balances[msg.sender].amount = safeSub(balances[msg.sender].amount, _value); balances[_to].amount = safeAdd(balances[_to].amount, _value); Transfer(msg.sender, _to, _value); //Notify anyone listening that this transfer took place return true; } function transferFrom(address _from, address _to, uint _value) whenNotPaused returns (bool success) { var _allowance = allowed[_from][msg.sender]; update(_from); // Do this to ensure sender has enough funds. update(_to); balances[_to].amount = safeAdd(balances[_to].amount, _value); balances[_from].amount = safeSub(balances[_from].amount, _value); allowed[_from][msg.sender] = safeSub(_allowance, _value); Transfer(_from, _to, _value); return true; } function approve(address _spender, uint _value) whenNotPaused returns (bool success) { require((_value == 0) || (allowed[msg.sender][_spender] == 0)); allowed[msg.sender][_spender] = _value; Approval(msg.sender, _spender, _value); return true; } function allowance(address _owner, address _spender) constant returns (uint remaining) { return allowed[_owner][_spender]; } // Minting Functions address public authorisedMinter; function setMinter(address minter) onlyOwner { authorisedMinter = minter; } function mintTokens(address destination, uint256 amount) { require(msg.sender == authorisedMinter); update(destination); balances[destination].amount = safeAdd(balances[destination].amount, amount); balances[destination].lastUpdated = now; balances[destination].nextAllocationIndex = currentAllocations.length; TokenMinted(destination,amount); } function burnTokens(address source, uint256 amount) { require(msg.sender == authorisedMinter); update(source); balances[source].amount = safeSub(balances[source].amount,amount); balances[source].lastUpdated = now; balances[source].nextAllocationIndex = currentAllocations.length; TokenBurned(source,amount); } } //**************** HelloGoldSale contract HelloGoldSale is Pausable, SafeMath { uint256 public decimals = 8; uint256 public startDate = 1503892800; // Monday, August 28, 2017 12:00:00 PM GMT+08:00 uint256 public endDate = 1504497600; // Monday, September 4, 2017 12:00:00 PM GMT+08:00 uint256 tranchePeriod = 1 weeks; // address of HGT Token. HGT must Approve this contract to disburse 180M tokens HelloGoldToken token; uint256 constant MaxCoinsR1 = 80 * 10**6 * 10**8; // 180M HGT uint256 public coinsRemaining = 80 * 10**6 * 10**8; uint256 coinsPerTier = 16 * 10**6 * 10**8; // 40M HGT uint256 public coinsLeftInTier = 16 * 10**6 * 10**8; uint256 public minimumCap = 0; // presale achieved uint256 numTiers = 5; uint16 public tierNo; uint256 public preallocCoins; // used for testing against cap (inc placement) uint256 public purchasedCoins; // used for testing against tier pricing uint256 public ethRaised; uint256 public personalMax = 10 ether; // max ether per person during public sale uint256 public contributors; address public cs; address public multiSig; address public HGT_Reserve; struct csAction { bool passedKYC; bool blocked; } /* This creates an array with all balances */ mapping (address => csAction) public permissions; mapping (address => uint256) public deposits; modifier MustBeEnabled(address x) { require (!permissions[x].blocked) ; require (permissions[x].passedKYC) ; _; } function HelloGoldSale(address _cs, address _hgt, address _multiSig, address _reserve) { cs = _cs; token = HelloGoldToken(_hgt); multiSig = _multiSig; HGT_Reserve = _reserve; } // We only expect to use this to set/reset the start of the contract under exceptional circumstances function setStart(uint256 when_) onlyOwner { startDate = when_; endDate = when_ + tranchePeriod; } modifier MustBeCs() { require (msg.sender == cs) ; _; } // 1 ether = N HGT tokens uint256[5] public hgtRates = [1248900000000,1196900000000,1144800000000,1092800000000,1040700000000]; /* Approve the account for operation */ function approve(address user) MustBeCs { permissions[user].passedKYC = true; } function block(address user) MustBeCs { permissions[user].blocked = true; } function unblock(address user) MustBeCs { permissions[user].blocked = false; } function newCs(address newCs) onlyOwner { cs = newCs; } function setPeriod(uint256 period_) onlyOwner { require (!funding()) ; tranchePeriod = period_; endDate = startDate + tranchePeriod; if (endDate < now + tranchePeriod) { endDate = now + tranchePeriod; } } function when() constant returns (uint256) { return now; } function funding() constant returns (bool) { if (paused) return false; // frozen if (now < startDate) return false; // too early if (now > endDate) return false; // too late if (coinsRemaining == 0) return false; // no more coins if (tierNo >= numTiers ) return false; // passed end of top tier. Tiers start at zero return true; } function success() constant returns (bool succeeded) { if (coinsRemaining == 0) return true; bool complete = (now > endDate) ; bool didOK = (coinsRemaining <= (MaxCoinsR1 - minimumCap)); // not even 40M Gone?? Aargh. succeeded = (complete && didOK) ; // (out of steam but enough sold) return ; } function failed() constant returns (bool didNotSucceed) { bool complete = (now > endDate ); bool didBad = (coinsRemaining > (MaxCoinsR1 - minimumCap)); didNotSucceed = (complete && didBad); return; } function () payable MustBeEnabled(msg.sender) whenNotPaused { createTokens(msg.sender,msg.value); } function linkCoin(address coin) onlyOwner { token = HelloGoldToken(coin); } function coinAddress() constant returns (address) { return address(token); } // hgtRates in whole tokens per ETH // max individual contribution in whole ETH function setHgtRates(uint256 p0,uint256 p1,uint256 p2,uint256 p3,uint256 p4, uint256 _max ) onlyOwner { require (now < startDate) ; hgtRates[0] = p0 * 10**8; hgtRates[1] = p1 * 10**8; hgtRates[2] = p2 * 10**8; hgtRates[3] = p3 * 10**8; hgtRates[4] = p4 * 10**8; personalMax = _max * 1 ether; // max ETH per person } event Purchase(address indexed buyer, uint256 level,uint256 value, uint256 tokens); event Reduction(string msg, address indexed buyer, uint256 wanted, uint256 allocated); event MaxFunds(address sender, uint256 taken, uint256 returned); function createTokens(address recipient, uint256 value) private { uint256 totalTokens; uint256 hgtRate; require (funding()) ; require (value >= 1 finney) ; require (deposits[recipient] < personalMax); uint256 maxRefund = 0; if ((deposits[recipient] + value) > personalMax) { maxRefund = deposits[recipient] + value - personalMax; value -= maxRefund; MaxFunds(recipient,value,maxRefund); } uint256 val = value; ethRaised = safeAdd(ethRaised,value); if (deposits[recipient] == 0) contributors++; do { hgtRate = hgtRates[tierNo]; // hgtRate must include the 10^8 uint tokens = safeMul(val, hgtRate); // (val in eth * 10^18) * #tokens per eth tokens = safeDiv(tokens, 1 ether); // val is in ether, msg.value is in wei if (tokens <= coinsLeftInTier) { uint256 actualTokens = tokens; uint refund = 0; if (tokens > coinsRemaining) { //can't sell desired # tokens Reduction("in tier",recipient,tokens,coinsRemaining); actualTokens = coinsRemaining; refund = safeSub(tokens, coinsRemaining ); // refund amount in tokens refund = safeDiv(refund*1 ether,hgtRate ); // refund amount in ETH // need a refund mechanism here too coinsRemaining = 0; val = safeSub( val,refund); } else { coinsRemaining = safeSub(coinsRemaining, actualTokens); } purchasedCoins = safeAdd(purchasedCoins, actualTokens); totalTokens = safeAdd(totalTokens,actualTokens); require (token.transferFrom(HGT_Reserve, recipient,totalTokens)) ; Purchase(recipient,tierNo,val,actualTokens); // event deposits[recipient] = safeAdd(deposits[recipient],val); // in case of refund - could pull off etherscan refund += maxRefund; if (refund > 0) { ethRaised = safeSub(ethRaised,refund); recipient.transfer(refund); } if (coinsRemaining <= (MaxCoinsR1 - minimumCap)){ // has passed success criteria if (!multiSig.send(this.balance)) { // send funds to HGF log0("cannot forward funds to owner"); } } coinsLeftInTier = safeSub(coinsLeftInTier,actualTokens); if ((coinsLeftInTier == 0) && (coinsRemaining != 0)) { // exact sell out of non final tier coinsLeftInTier = coinsPerTier; tierNo++; endDate = now + tranchePeriod; } return; } // check that coinsLeftInTier >= coinsRemaining uint256 coins2buy = min256(coinsLeftInTier , coinsRemaining); endDate = safeAdd( now, tranchePeriod); // Have bumped levels - need to modify end date here purchasedCoins = safeAdd(purchasedCoins, coins2buy); // give all coins remaining in this tier totalTokens = safeAdd(totalTokens,coins2buy); coinsRemaining = safeSub(coinsRemaining,coins2buy); uint weiCoinsLeftInThisTier = safeMul(coins2buy,1 ether); uint costOfTheseCoins = safeDiv(weiCoinsLeftInThisTier, hgtRate); // how much did that cost? Purchase(recipient, tierNo,costOfTheseCoins,coins2buy); // event deposits[recipient] = safeAdd(deposits[recipient],costOfTheseCoins); val = safeSub(val,costOfTheseCoins); tierNo = tierNo + 1; coinsLeftInTier = coinsPerTier; } while ((val > 0) && funding()); // escaped because we passed the end of the universe..... // so give them their tokens require (token.transferFrom(HGT_Reserve, recipient,totalTokens)) ; if ((val > 0) || (maxRefund > 0)){ Reduction("finished crowdsale, returning ",recipient,value,totalTokens); // return the remainder ! recipient.transfer(val+maxRefund); // if you can't return the balance, abort whole process } if (!multiSig.send(this.balance)) { ethRaised = safeSub(ethRaised,this.balance); log0("cannot send at tier jump"); } } function allocatedTokens(address grantee, uint256 numTokens) onlyOwner { require (now < startDate) ; if (numTokens < coinsRemaining) { coinsRemaining = safeSub(coinsRemaining, numTokens); } else { numTokens = coinsRemaining; coinsRemaining = 0; } preallocCoins = safeAdd(preallocCoins,numTokens); require (token.transferFrom(HGT_Reserve,grantee,numTokens)); } function withdraw() { // it failed. Come and get your ether. if (failed()) { if (deposits[msg.sender] > 0) { uint256 val = deposits[msg.sender]; deposits[msg.sender] = 0; msg.sender.transfer(val); } } } function complete() onlyOwner { // this should not have to be called. Extreme measures. if (success()) { uint256 val = this.balance; if (val > 0) { if (!multiSig.send(val)) { log0("cannot withdraw"); } else { log0("funds withdrawn"); } } else { log0("nothing to withdraw"); } } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"permissions","outputs":[{"name":"passedKYC","type":"bool"},{"name":"blocked","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"user","type":"address"}],"name":"block","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"purchasedCoins","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"success","outputs":[{"name":"succeeded","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"startDate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"personalMax","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"period_","type":"uint256"}],"name":"setPeriod","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"multiSig","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"unpause","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"complete","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"cs","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":true,"inputs":[],"name":"preallocCoins","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"p0","type":"uint256"},{"name":"p1","type":"uint256"},{"name":"p2","type":"uint256"},{"name":"p3","type":"uint256"},{"name":"p4","type":"uint256"},{"name":"_max","type":"uint256"}],"name":"setHgtRates","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"user","type":"address"}],"name":"unblock","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"contributors","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"tierNo","outputs":[{"name":"","type":"uint16"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"grantee","type":"address"},{"name":"numTokens","type":"uint256"}],"name":"allocatedTokens","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"pause","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newCs","type":"address"}],"name":"newCs","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"coinsLeftInTier","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"coin","type":"address"}],"name":"linkCoin","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"failed","outputs":[{"name":"didNotSucceed","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"endDate","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"hgtRates","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"funding","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"HGT_Reserve","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"user","type":"address"}],"name":"approve","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"coinsRemaining","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"when","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"minimumCap","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"when_","type":"uint256"}],"name":"setStart","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"deposits","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"coinAddress","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"ethRaised","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_cs","type":"address"},{"name":"_hgt","type":"address"},{"name":"_multiSig","type":"address"},{"name":"_reserve","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"buyer","type":"address"},{"indexed":false,"name":"level","type":"uint256"},{"indexed":false,"name":"value","type":"uint256"},{"indexed":false,"name":"tokens","type":"uint256"}],"name":"Purchase","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"msg","type":"string"},{"indexed":true,"name":"buyer","type":"address"},{"indexed":false,"name":"wanted","type":"uint256"},{"indexed":false,"name":"allocated","type":"uint256"}],"name":"Reduction","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"sender","type":"address"},{"indexed":false,"name":"taken","type":"uint256"},{"indexed":false,"name":"returned","type":"uint256"}],"name":"MaxFunds","type":"event"},{"anonymous":false,"inputs":[],"name":"Pause","type":"event"},{"anonymous":false,"inputs":[],"name":"Unpause","type":"event"}]
Contract Creation Code
606060409081526000805460a060020a60ff0219168155600860018190556359a395406002556359accfc060035562093a80600455661c6bf5263400006006556605af3107a40000600781905590556009556005600a55678ac7230489e80000600f5560a090519081016040908152650122c83da9008252650116accca100602083015265010a8b65b8009082015264fe6ff4b000606082015264f24e8dc7006080820152620000b490601690600562000160565b503415620000c157600080fd5b60405160808062001b27833981016040528080519190602001805191906020018051919060200180519150505b5b60008054600160a060020a03191633600160a060020a03161790555b60118054600160a060020a03808716600160a060020a031992831617909255600580548684169083161790556012805485841690831617905560138054928416929091169190911790555b50505050620001d2565b82600581019282156200019b579160200282015b828111156200019b578251829065ffffffffffff1690559160200191906001019062000174565b5b50620001aa929150620001ae565b5090565b620001cf91905b80821115620001aa5760008155600101620001b5565b5090565b90565b61194580620001e26000396000f300606060405236156101c75763ffffffff60e060020a60003504166301e88208811461024257806306907e171461027d5780630b59a5c41461029e5780630b93381b146102c35780630b97bc86146102ea5780630be484911461030f5780630f3a9f6514610334578063313ce5671461034c57806336e0004a146103715780633ccfd60b146103a05780633f4ba83a146103b5578063522e1177146103dc578063540a5e4e146103f15780635c975abb146104205780635f33afdb1461044757806366c2ae951461046c57806367b220a5146104935780636e7e3b2b146104b4578063781c4dad146104d9578063796c0c78146105035780638456cb59146105275780638502293b1461054e5780638da5cb5b1461056f578063a6d151241461059e578063aecd27fa146105c3578063ba414fa6146105e4578063c24a0f8b1461060b578063cb0ef7d014610630578063cb4c86b714610658578063d4788cc31461067f578063daea85c5146106ae578063dde82c2d146106cf578063e2b0caef146106f4578063f2fde38b14610719578063f381f2a51461073a578063f6a03ebf1461075f578063fc7e286d14610777578063fdc61dd1146107a8578063fddf0fc0146107d7575b5b33600160a060020a038116600090815260146020526040902054610100900460ff16156101f457600080fd5b600160a060020a03811660009081526014602052604090205460ff16151561021b57600080fd5b60005460a060020a900460ff161561023257600080fd5b61023c33346107fc565b5b5b5b50005b341561024d57600080fd5b610261600160a060020a0360043516611010565b6040519115158252151560208201526040908101905180910390f35b341561028857600080fd5b61029c600160a060020a036004351661102e565b005b34156102a957600080fd5b6102b1611073565b60405190815260200160405180910390f35b34156102ce57600080fd5b6102d6611079565b604051901515815260200160405180910390f35b34156102f557600080fd5b6102b16110be565b60405190815260200160405180910390f35b341561031a57600080fd5b6102b16110c4565b60405190815260200160405180910390f35b341561033f57600080fd5b61029c6004356110ca565b005b341561035757600080fd5b6102b161111e565b60405190815260200160405180910390f35b341561037c57600080fd5b610384611124565b604051600160a060020a03909116815260200160405180910390f35b34156103ab57600080fd5b61029c611133565b005b34156103c057600080fd5b6102d66111b0565b604051901515815260200160405180910390f35b34156103e757600080fd5b61029c611237565b005b34156103fc57600080fd5b610384611348565b604051600160a060020a03909116815260200160405180910390f35b341561042b57600080fd5b6102d6611357565b604051901515815260200160405180910390f35b341561045257600080fd5b6102b1611367565b60405190815260200160405180910390f35b341561047757600080fd5b61029c60043560243560443560643560843560a43561136d565b005b341561049e57600080fd5b61029c600160a060020a0360043516611408565b005b34156104bf57600080fd5b6102b1611449565b60405190815260200160405180910390f35b34156104e457600080fd5b6104ec61144f565b60405161ffff909116815260200160405180910390f35b341561050e57600080fd5b61029c600160a060020a0360043516602435611459565b005b341561053257600080fd5b6102d6611559565b604051901515815260200160405180910390f35b341561055957600080fd5b61029c600160a060020a03600435166115e5565b005b341561057a57600080fd5b61038461162d565b604051600160a060020a03909116815260200160405180910390f35b34156105a957600080fd5b6102b161163c565b60405190815260200160405180910390f35b34156105ce57600080fd5b61029c600160a060020a0360043516611642565b005b34156105ef57600080fd5b6102d661168a565b604051901515815260200160405180910390f35b341561061657600080fd5b6102b16116b6565b60405190815260200160405180910390f35b341561063b57600080fd5b6102b16004356116bc565b60405190815260200160405180910390f35b341561066357600080fd5b6102d66116d4565b604051901515815260200160405180910390f35b341561068a57600080fd5b610384611742565b604051600160a060020a03909116815260200160405180910390f35b34156106b957600080fd5b61029c600160a060020a0360043516611751565b005b34156106da57600080fd5b6102b1611794565b60405190815260200160405180910390f35b34156106ff57600080fd5b6102b161179a565b60405190815260200160405180910390f35b341561072457600080fd5b61029c600160a060020a036004351661179f565b005b341561074557600080fd5b6102b16117f7565b60405190815260200160405180910390f35b341561076a57600080fd5b61029c6004356117fd565b005b341561078257600080fd5b6102b1600160a060020a036004351661182a565b60405190815260200160405180910390f35b34156107b357600080fd5b61038461183c565b604051600160a060020a03909116815260200160405180910390f35b34156107e257600080fd5b6102b161184c565b60405190815260200160405180910390f35b6000806000806000806000806000806108136116d4565b151561081e57600080fd5b66038d7ea4c680008b101561083257600080fd5b600f54600160a060020a038d166000908152601560205260409020541061085857600080fd5b600f54600160a060020a038d166000908152601560205260408120549099508c01111561090c57600f548b601560008f600160a060020a0316600160a060020a031681526020019081526020016000205401039750878b039a507fa7cbe06f3899584e1098af358ac211bec7e617eaf4ff825299554904d76fef2a8c8c8a6040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a15b8a965061091b600e548c611852565b600e55600160a060020a038c166000908152601560205260409020541515610947576010805460010190555b5b600b5460169061ffff166005811061095c57fe5b0160005b5054985061096e878a61187a565b955061098286670de0b6b3a76400006118a9565b6008549096508611610cd65785945060009350600654861115610a5c578b600160a060020a03167f1cb2dbf66c8795a5a1001c63a30fc3d4c207b969d6836f6f600cbd64aac9cf2887600654604051602081019290925260408083019190915260608083526007908301527f696e207469657200000000000000000000000000000000000000000000000000608083015260a0909101905180910390a26006549450610a2e86866118e8565b9350610a4484670de0b6b3a7640000028a6118a9565b60006006559350610a5587856118e8565b9650610a6c565b610a68600654866118e8565b6006555b610a78600d5486611852565b600d55610a858a86611852565b600554601354919b50600160a060020a03908116916323b872dd91168e8d60006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610afb57600080fd5b6102c65a03f11515610b0c57600080fd5b505050604051805190501515610b2157600080fd5b600b54600160a060020a038d16907f5bc97d73357ac0d035d4b9268a69240988a5776b8a4fcced3dbc223960123f409061ffff168988604051808461ffff168152602001838152602001828152602001935050505060405180910390a2600160a060020a038c16600090815260156020526040902054610ba19088611852565b600160a060020a038d1660009081526015602052604081209190915593880193841115610c0857610bd4600e54856118e8565b600e55600160a060020a038c1684156108fc0285604051600060405180830381858888f193505050501515610c0857600080fd5b5b600954661c6bf52634000003600654111515610c8557601254600160a060020a039081169030163180156108fc0290604051600060405180830381858888f193505050501515610c85576040517f63616e6e6f7420666f72776172642066756e647320746f206f776e65720000008152601d0160405180910390a05b5b610c92600854866118e8565b6008819055158015610ca5575060065415155b15610cd157600754600855600b805461ffff8082166001011661ffff1990911617905560045442016003555b611001565b610ce46008546006546118ff565b9250610cf242600454611852565b600355600d54610d029084611852565b600d55610d0f8a84611852565b9950610d1d600654846118e8565b600655610d3283670de0b6b3a764000061187a565b9150610d3e828a6118a9565b600b54909150600160a060020a038d16907f5bc97d73357ac0d035d4b9268a69240988a5776b8a4fcced3dbc223960123f409061ffff168386604051808461ffff168152602001838152602001828152602001935050505060405180910390a2600160a060020a038c16600090815260156020526040902054610dc19082611852565b600160a060020a038d16600090815260156020526040902055610de487826118e8565b600b805461ffff8082166001011661ffff199091161790556007546008559650600087118015610e175750610e176116d4565b5b15610e2257610947565b600554601354600160a060020a03918216916323b872dd91168e8d60006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610e9557600080fd5b6102c65a03f11515610ea657600080fd5b505050604051805190501515610ebb57600080fd5b6000871180610eca5750600088115b15610f81578b600160a060020a03167f1cb2dbf66c8795a5a1001c63a30fc3d4c207b969d6836f6f600cbd64aac9cf288c8c60405160208101929092526040808301919091526060808352601e908301527f66696e69736865642063726f776473616c652c2072657475726e696e67200000608083015260a0909101905180910390a2600160a060020a038c1687890180156108fc0290604051600060405180830381858888f193505050501515610f8157600080fd5b5b601254600160a060020a039081169030163180156108fc0290604051600060405180830381858888f19350505050151561100157610fcc600e5430600160a060020a0316316118e8565b600e556040517f63616e6e6f742073656e642061742074696572206a756d700000000000000000815260180160405180910390a05b5b505050505050505050505050565b60146020526000908152604090205460ff8082169161010090041682565b60115433600160a060020a0390811691161461104957600080fd5b600160a060020a0381166000908152601460205260409020805461ff0019166101001790555b5b50565b600d5481565b60008060006006546000141561109257600192506110b9565b60035442119150600954661c6bf52634000003600654111590508180156110b65750805b92505b505090565b60025481565b600f5481565b60005433600160a060020a039081169116146110e557600080fd5b6110ed6116d4565b156110f757600080fd5b60048190556002548101600381905542820190101561106f5760045442016003555b5b5b50565b60015481565b601254600160a060020a031681565b600061113d61168a565b1561106f57600160a060020a033316600090815260156020526040812054111561106f5750600160a060020a033316600081815260156020526040808220805492905590919082156108fc0290839051600060405180830381858888f19350505050151561106f57600080fd5b5b5b5b50565b6000805433600160a060020a039081169116146111cc57600080fd5b60005460a060020a900460ff1615156111e457600080fd5b6000805474ff0000000000000000000000000000000000000000191690557f7805862f689e2f13df9f062ff482ad3ad112aca9e0847911ed832e158c525b3360405160405180910390a15060015b5b5b90565b6000805433600160a060020a0390811691161461125357600080fd5b61125b611079565b1561106f5750600160a060020a03301631600081111561131057601254600160a060020a031681156108fc0282604051600060405180830381858888f1935050505015156112d9576040517f63616e6e6f7420776974686472617700000000000000000000000000000000008152600f0160405180910390a061130b565b6040517f66756e64732077697468647261776e00000000000000000000000000000000008152600f0160405180910390a05b61106f565b6040517f6e6f7468696e6720746f20776974686472617700000000000000000000000000815260130160405180910390a05b5b5b5b50565b601154600160a060020a031681565b60005460a060020a900460ff1681565b600c5481565b60005433600160a060020a0390811691161461138857600080fd5b600254421061139657600080fd5b6305f5e1008602601660005b0160005b50556305f5e1008502601660015b0160005b50556305f5e1008402601660025b0160005b50556305f5e1008302601660035b0160005b50556305f5e1008202601660045b0160005b5055670de0b6b3a76400008102600f555b5b505050505050565b60115433600160a060020a0390811691161461142357600080fd5b600160a060020a0381166000908152601460205260409020805461ff00191690555b5b50565b60105481565b600b5461ffff1681565b60005433600160a060020a0390811691161461147457600080fd5b600254421061148257600080fd5b6006548110156114a057611498600654826118e8565b6006556114ab565b506006805460009091555b6114b7600c5482611852565b600c55600554601354600160a060020a03918216916323b872dd9116848460006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b151561152d57600080fd5b6102c65a03f1151561153e57600080fd5b50505060405180519050151561155357600080fd5b5b5b5050565b6000805433600160a060020a0390811691161461157557600080fd5b60005460a060020a900460ff161561158c57600080fd5b6000805474ff0000000000000000000000000000000000000000191660a060020a1790557f6985a02210a168e66602d3235cb6db0e70f92b3ba4d376a33c0f3d9434bff62560405160405180910390a15060015b5b5b90565b60005433600160a060020a0390811691161461160057600080fd5b6011805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b50565b600054600160a060020a031681565b60085481565b60005433600160a060020a0390811691161461165d57600080fd5b6005805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b50565b600354600954600654600092421191661c6bf5263400000390118180156110b65750805b92505b505090565b60035481565b601681600581106116c957fe5b0160005b5054905081565b6000805460a060020a900460ff16156116ef57506000611232565b60025442101561170157506000611232565b60035442111561171357506000611232565b600654151561172457506000611232565b600a54600b5461ffff161061173b57506000611232565b5060015b90565b601354600160a060020a031681565b60115433600160a060020a0390811691161461176c57600080fd5b600160a060020a0381166000908152601460205260409020805460ff191660011790555b5b50565b60065481565b425b90565b60005433600160a060020a039081169116146117ba57600080fd5b600160a060020a0381161561106f576000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b5b50565b60095481565b60005433600160a060020a0390811691161461181857600080fd5b600281905560045481016003555b5b50565b60156020526000908152604090205481565b600554600160a060020a03165b90565b600e5481565b60008282018381108015906118675750828110155b151561186f57fe5b8091505b5092915050565b6000828202831580611867575082848281151561189357fe5b04145b151561186f57fe5b8091505b5092915050565b6000808083116118b557fe5b82848115156118c057fe5b04905082848115156118ce57fe5b06818402018414151561186f57fe5b8091505b5092915050565b6000828211156118f457fe5b508082035b92915050565b600081831061190e5781611910565b825b90505b929150505600a165627a7a72305820a9b8851ef63a7ce6e549d887703658081f12701db3ace521a6d8a4f63203bc0b00290000000000000000000000004461ed03de52fbf2ea28b71016137dcc4db50c50000000000000000000000000ba2184520a1cc49a6159c57e61e1844e085615b6000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af
Deployed Bytecode
0x606060405236156101c75763ffffffff60e060020a60003504166301e88208811461024257806306907e171461027d5780630b59a5c41461029e5780630b93381b146102c35780630b97bc86146102ea5780630be484911461030f5780630f3a9f6514610334578063313ce5671461034c57806336e0004a146103715780633ccfd60b146103a05780633f4ba83a146103b5578063522e1177146103dc578063540a5e4e146103f15780635c975abb146104205780635f33afdb1461044757806366c2ae951461046c57806367b220a5146104935780636e7e3b2b146104b4578063781c4dad146104d9578063796c0c78146105035780638456cb59146105275780638502293b1461054e5780638da5cb5b1461056f578063a6d151241461059e578063aecd27fa146105c3578063ba414fa6146105e4578063c24a0f8b1461060b578063cb0ef7d014610630578063cb4c86b714610658578063d4788cc31461067f578063daea85c5146106ae578063dde82c2d146106cf578063e2b0caef146106f4578063f2fde38b14610719578063f381f2a51461073a578063f6a03ebf1461075f578063fc7e286d14610777578063fdc61dd1146107a8578063fddf0fc0146107d7575b5b33600160a060020a038116600090815260146020526040902054610100900460ff16156101f457600080fd5b600160a060020a03811660009081526014602052604090205460ff16151561021b57600080fd5b60005460a060020a900460ff161561023257600080fd5b61023c33346107fc565b5b5b5b50005b341561024d57600080fd5b610261600160a060020a0360043516611010565b6040519115158252151560208201526040908101905180910390f35b341561028857600080fd5b61029c600160a060020a036004351661102e565b005b34156102a957600080fd5b6102b1611073565b60405190815260200160405180910390f35b34156102ce57600080fd5b6102d6611079565b604051901515815260200160405180910390f35b34156102f557600080fd5b6102b16110be565b60405190815260200160405180910390f35b341561031a57600080fd5b6102b16110c4565b60405190815260200160405180910390f35b341561033f57600080fd5b61029c6004356110ca565b005b341561035757600080fd5b6102b161111e565b60405190815260200160405180910390f35b341561037c57600080fd5b610384611124565b604051600160a060020a03909116815260200160405180910390f35b34156103ab57600080fd5b61029c611133565b005b34156103c057600080fd5b6102d66111b0565b604051901515815260200160405180910390f35b34156103e757600080fd5b61029c611237565b005b34156103fc57600080fd5b610384611348565b604051600160a060020a03909116815260200160405180910390f35b341561042b57600080fd5b6102d6611357565b604051901515815260200160405180910390f35b341561045257600080fd5b6102b1611367565b60405190815260200160405180910390f35b341561047757600080fd5b61029c60043560243560443560643560843560a43561136d565b005b341561049e57600080fd5b61029c600160a060020a0360043516611408565b005b34156104bf57600080fd5b6102b1611449565b60405190815260200160405180910390f35b34156104e457600080fd5b6104ec61144f565b60405161ffff909116815260200160405180910390f35b341561050e57600080fd5b61029c600160a060020a0360043516602435611459565b005b341561053257600080fd5b6102d6611559565b604051901515815260200160405180910390f35b341561055957600080fd5b61029c600160a060020a03600435166115e5565b005b341561057a57600080fd5b61038461162d565b604051600160a060020a03909116815260200160405180910390f35b34156105a957600080fd5b6102b161163c565b60405190815260200160405180910390f35b34156105ce57600080fd5b61029c600160a060020a0360043516611642565b005b34156105ef57600080fd5b6102d661168a565b604051901515815260200160405180910390f35b341561061657600080fd5b6102b16116b6565b60405190815260200160405180910390f35b341561063b57600080fd5b6102b16004356116bc565b60405190815260200160405180910390f35b341561066357600080fd5b6102d66116d4565b604051901515815260200160405180910390f35b341561068a57600080fd5b610384611742565b604051600160a060020a03909116815260200160405180910390f35b34156106b957600080fd5b61029c600160a060020a0360043516611751565b005b34156106da57600080fd5b6102b1611794565b60405190815260200160405180910390f35b34156106ff57600080fd5b6102b161179a565b60405190815260200160405180910390f35b341561072457600080fd5b61029c600160a060020a036004351661179f565b005b341561074557600080fd5b6102b16117f7565b60405190815260200160405180910390f35b341561076a57600080fd5b61029c6004356117fd565b005b341561078257600080fd5b6102b1600160a060020a036004351661182a565b60405190815260200160405180910390f35b34156107b357600080fd5b61038461183c565b604051600160a060020a03909116815260200160405180910390f35b34156107e257600080fd5b6102b161184c565b60405190815260200160405180910390f35b6000806000806000806000806000806108136116d4565b151561081e57600080fd5b66038d7ea4c680008b101561083257600080fd5b600f54600160a060020a038d166000908152601560205260409020541061085857600080fd5b600f54600160a060020a038d166000908152601560205260408120549099508c01111561090c57600f548b601560008f600160a060020a0316600160a060020a031681526020019081526020016000205401039750878b039a507fa7cbe06f3899584e1098af358ac211bec7e617eaf4ff825299554904d76fef2a8c8c8a6040518084600160a060020a0316600160a060020a03168152602001838152602001828152602001935050505060405180910390a15b8a965061091b600e548c611852565b600e55600160a060020a038c166000908152601560205260409020541515610947576010805460010190555b5b600b5460169061ffff166005811061095c57fe5b0160005b5054985061096e878a61187a565b955061098286670de0b6b3a76400006118a9565b6008549096508611610cd65785945060009350600654861115610a5c578b600160a060020a03167f1cb2dbf66c8795a5a1001c63a30fc3d4c207b969d6836f6f600cbd64aac9cf2887600654604051602081019290925260408083019190915260608083526007908301527f696e207469657200000000000000000000000000000000000000000000000000608083015260a0909101905180910390a26006549450610a2e86866118e8565b9350610a4484670de0b6b3a7640000028a6118a9565b60006006559350610a5587856118e8565b9650610a6c565b610a68600654866118e8565b6006555b610a78600d5486611852565b600d55610a858a86611852565b600554601354919b50600160a060020a03908116916323b872dd91168e8d60006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610afb57600080fd5b6102c65a03f11515610b0c57600080fd5b505050604051805190501515610b2157600080fd5b600b54600160a060020a038d16907f5bc97d73357ac0d035d4b9268a69240988a5776b8a4fcced3dbc223960123f409061ffff168988604051808461ffff168152602001838152602001828152602001935050505060405180910390a2600160a060020a038c16600090815260156020526040902054610ba19088611852565b600160a060020a038d1660009081526015602052604081209190915593880193841115610c0857610bd4600e54856118e8565b600e55600160a060020a038c1684156108fc0285604051600060405180830381858888f193505050501515610c0857600080fd5b5b600954661c6bf52634000003600654111515610c8557601254600160a060020a039081169030163180156108fc0290604051600060405180830381858888f193505050501515610c85576040517f63616e6e6f7420666f72776172642066756e647320746f206f776e65720000008152601d0160405180910390a05b5b610c92600854866118e8565b6008819055158015610ca5575060065415155b15610cd157600754600855600b805461ffff8082166001011661ffff1990911617905560045442016003555b611001565b610ce46008546006546118ff565b9250610cf242600454611852565b600355600d54610d029084611852565b600d55610d0f8a84611852565b9950610d1d600654846118e8565b600655610d3283670de0b6b3a764000061187a565b9150610d3e828a6118a9565b600b54909150600160a060020a038d16907f5bc97d73357ac0d035d4b9268a69240988a5776b8a4fcced3dbc223960123f409061ffff168386604051808461ffff168152602001838152602001828152602001935050505060405180910390a2600160a060020a038c16600090815260156020526040902054610dc19082611852565b600160a060020a038d16600090815260156020526040902055610de487826118e8565b600b805461ffff8082166001011661ffff199091161790556007546008559650600087118015610e175750610e176116d4565b5b15610e2257610947565b600554601354600160a060020a03918216916323b872dd91168e8d60006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b1515610e9557600080fd5b6102c65a03f11515610ea657600080fd5b505050604051805190501515610ebb57600080fd5b6000871180610eca5750600088115b15610f81578b600160a060020a03167f1cb2dbf66c8795a5a1001c63a30fc3d4c207b969d6836f6f600cbd64aac9cf288c8c60405160208101929092526040808301919091526060808352601e908301527f66696e69736865642063726f776473616c652c2072657475726e696e67200000608083015260a0909101905180910390a2600160a060020a038c1687890180156108fc0290604051600060405180830381858888f193505050501515610f8157600080fd5b5b601254600160a060020a039081169030163180156108fc0290604051600060405180830381858888f19350505050151561100157610fcc600e5430600160a060020a0316316118e8565b600e556040517f63616e6e6f742073656e642061742074696572206a756d700000000000000000815260180160405180910390a05b5b505050505050505050505050565b60146020526000908152604090205460ff8082169161010090041682565b60115433600160a060020a0390811691161461104957600080fd5b600160a060020a0381166000908152601460205260409020805461ff0019166101001790555b5b50565b600d5481565b60008060006006546000141561109257600192506110b9565b60035442119150600954661c6bf52634000003600654111590508180156110b65750805b92505b505090565b60025481565b600f5481565b60005433600160a060020a039081169116146110e557600080fd5b6110ed6116d4565b156110f757600080fd5b60048190556002548101600381905542820190101561106f5760045442016003555b5b5b50565b60015481565b601254600160a060020a031681565b600061113d61168a565b1561106f57600160a060020a033316600090815260156020526040812054111561106f5750600160a060020a033316600081815260156020526040808220805492905590919082156108fc0290839051600060405180830381858888f19350505050151561106f57600080fd5b5b5b5b50565b6000805433600160a060020a039081169116146111cc57600080fd5b60005460a060020a900460ff1615156111e457600080fd5b6000805474ff0000000000000000000000000000000000000000191690557f7805862f689e2f13df9f062ff482ad3ad112aca9e0847911ed832e158c525b3360405160405180910390a15060015b5b5b90565b6000805433600160a060020a0390811691161461125357600080fd5b61125b611079565b1561106f5750600160a060020a03301631600081111561131057601254600160a060020a031681156108fc0282604051600060405180830381858888f1935050505015156112d9576040517f63616e6e6f7420776974686472617700000000000000000000000000000000008152600f0160405180910390a061130b565b6040517f66756e64732077697468647261776e00000000000000000000000000000000008152600f0160405180910390a05b61106f565b6040517f6e6f7468696e6720746f20776974686472617700000000000000000000000000815260130160405180910390a05b5b5b5b50565b601154600160a060020a031681565b60005460a060020a900460ff1681565b600c5481565b60005433600160a060020a0390811691161461138857600080fd5b600254421061139657600080fd5b6305f5e1008602601660005b0160005b50556305f5e1008502601660015b0160005b50556305f5e1008402601660025b0160005b50556305f5e1008302601660035b0160005b50556305f5e1008202601660045b0160005b5055670de0b6b3a76400008102600f555b5b505050505050565b60115433600160a060020a0390811691161461142357600080fd5b600160a060020a0381166000908152601460205260409020805461ff00191690555b5b50565b60105481565b600b5461ffff1681565b60005433600160a060020a0390811691161461147457600080fd5b600254421061148257600080fd5b6006548110156114a057611498600654826118e8565b6006556114ab565b506006805460009091555b6114b7600c5482611852565b600c55600554601354600160a060020a03918216916323b872dd9116848460006040516020015260405160e060020a63ffffffff8616028152600160a060020a0393841660048201529190921660248201526044810191909152606401602060405180830381600087803b151561152d57600080fd5b6102c65a03f1151561153e57600080fd5b50505060405180519050151561155357600080fd5b5b5b5050565b6000805433600160a060020a0390811691161461157557600080fd5b60005460a060020a900460ff161561158c57600080fd5b6000805474ff0000000000000000000000000000000000000000191660a060020a1790557f6985a02210a168e66602d3235cb6db0e70f92b3ba4d376a33c0f3d9434bff62560405160405180910390a15060015b5b5b90565b60005433600160a060020a0390811691161461160057600080fd5b6011805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b50565b600054600160a060020a031681565b60085481565b60005433600160a060020a0390811691161461165d57600080fd5b6005805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b50565b600354600954600654600092421191661c6bf5263400000390118180156110b65750805b92505b505090565b60035481565b601681600581106116c957fe5b0160005b5054905081565b6000805460a060020a900460ff16156116ef57506000611232565b60025442101561170157506000611232565b60035442111561171357506000611232565b600654151561172457506000611232565b600a54600b5461ffff161061173b57506000611232565b5060015b90565b601354600160a060020a031681565b60115433600160a060020a0390811691161461176c57600080fd5b600160a060020a0381166000908152601460205260409020805460ff191660011790555b5b50565b60065481565b425b90565b60005433600160a060020a039081169116146117ba57600080fd5b600160a060020a0381161561106f576000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b5b50565b60095481565b60005433600160a060020a0390811691161461181857600080fd5b600281905560045481016003555b5b50565b60156020526000908152604090205481565b600554600160a060020a03165b90565b600e5481565b60008282018381108015906118675750828110155b151561186f57fe5b8091505b5092915050565b6000828202831580611867575082848281151561189357fe5b04145b151561186f57fe5b8091505b5092915050565b6000808083116118b557fe5b82848115156118c057fe5b04905082848115156118ce57fe5b06818402018414151561186f57fe5b8091505b5092915050565b6000828211156118f457fe5b508082035b92915050565b600081831061190e5781611910565b825b90505b929150505600a165627a7a72305820a9b8851ef63a7ce6e549d887703658081f12701db3ace521a6d8a4f63203bc0b0029
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000004461ed03de52fbf2ea28b71016137dcc4db50c50000000000000000000000000ba2184520a1cc49a6159c57e61e1844e085615b6000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af
-----Decoded View---------------
Arg [0] : _cs (address): 0x4461ed03DE52Fbf2ea28B71016137DCc4Db50C50
Arg [1] : _hgt (address): 0xba2184520A1cC49a6159c57e61E1844E085615B6
Arg [2] : _multiSig (address): 0xC03281aF336e2C25B41FF893A0e6cE1a932B23AF
Arg [3] : _reserve (address): 0xC03281aF336e2C25B41FF893A0e6cE1a932B23AF
-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000004461ed03de52fbf2ea28b71016137dcc4db50c50
Arg [1] : 000000000000000000000000ba2184520a1cc49a6159c57e61e1844e085615b6
Arg [2] : 000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af
Arg [3] : 000000000000000000000000c03281af336e2c25b41ff893a0e6ce1a932b23af
Swarm Source
bzzr://a9b8851ef63a7ce6e549d887703658081f12701db3ace521a6d8a4f63203bc0b
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
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.