comment
stringlengths
1
211
input
stringlengths
155
20k
label
stringlengths
4
1k
original_idx
int64
203
514k
predicate
stringlengths
1
1k
"Your sell cooldown has not expired."
/** _______ _______ _______ _______ __ __ _______ __ __ __ _ __ __ | || || || _ || |_| || || | | || | | || |_| | | _____||_ _|| ___|| |_| || || _ || | | || |_| || | | |_____ | | | |___ | || || |_| || |_| || || | |_____ | | | | ___|| || || ___|| || _ | | | _____| | | | | |___ | _ || ||_|| || | | || | | || _ | |_______| |___| |_______||__| |__||_| |_||___| |_______||_| |__||__| |__| * * TOKENOMICS: * 1,000,000,000,000 token supply * FIRST TWO MINUTES: 3,000,000,000 max buy / 45-second buy cooldown (these limitations are lifted automatically two minutes post-launch) * 15-second cooldown to sell after a buy * 10% tax on buys and sells * Max wallet of 9% of total supply for first 12 hours * Higher fee on sells within first 1 hour post-launch * No team tokens, no presale * Functions for removing fees * SPDX-License-Identifier: UNLICENSED */ pragma solidity ^0.8.4; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mod(uint256 a, uint256 b) internal pure returns (uint256) { } function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor () { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); } contract STEAMPUNX is Context, IERC20, Ownable { using SafeMath for uint256; mapping (address => uint256) private _rOwned; mapping (address => uint256) private _tOwned; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) private _isExcludedFromFee; mapping (address => User) private cooldown; uint256 private constant MAX = ~uint256(0); uint256 private constant _tTotal = 1e12 * 10**9; uint256 private _rTotal = (MAX - (MAX % _tTotal)); uint256 private _tFeeTotal; string private constant _name = unicode"STEAMPUNX"; string private constant _symbol = unicode"STEAMPUNX"; uint8 private constant _decimals = 9; uint256 private _taxFee = 6; uint256 private _teamFee = 4; uint256 private _feeRate = 2; uint256 private _previousTaxFee = _taxFee; uint256 private _previousteamFee = _teamFee; uint256 private _launchFeeEnd; uint256 private _maxBuyAmount; uint256 private _maxHeldTokens; address payable private _feeAddress1; address payable private _feeAddress2; IUniswapV2Router02 private uniswapV2Router; address private uniswapV2Pair; bool private _tradingOpen; bool private _cooldownEnabled = true; bool private inSwap = false; bool private _useFees = true; bool private _useDevFee = true; uint256 private _buyLimitEnd; uint256 private _maxHeldTokensEnd; struct User { uint256 buy; uint256 sell; bool exists; } event MaxBuyAmountUpdated(uint _maxBuyAmount); event CooldownEnabledUpdated(bool _cooldown); event UseFeesBooleanUpdated(bool _usefees); event UseDevFeeBooleanUpdated(bool _usedevfee); event TaxFeeUpdated(uint _taxfee); event TeamFeeUpdated(uint _taxfee); event FeeAddress1Updated(address _feewallet1); event FeeAddress2Updated(address _feewallet2); modifier lockTheSwap { } constructor (address payable feeAddress1, address payable feeAddress2) { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public pure override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function transferFrom(address sender, address recipient, uint256 amount) public override returns (bool) { } function tokenFromReflection(uint256 rAmount) private view returns(uint256) { } function removeAllFee() private { } function restoreAllFee() private { } function _approve(address owner, address spender, uint256 amount) private { } function _transfer(address from, address to, uint256 amount) private { require(from != address(0), "ERC20: transfer from the zero address"); require(to != address(0), "ERC20: transfer to the zero address"); require(amount > 0, "Transfer amount must be greater than zero"); // set to false for no fee on buys bool takeFee = true; if(from != owner() && to != owner()) { if(_cooldownEnabled) { if(!cooldown[msg.sender].exists) { cooldown[msg.sender] = User(0,0,true); } } // buy if(from == uniswapV2Pair && to != address(uniswapV2Router) && !_isExcludedFromFee[to]) { _taxFee = 6; _teamFee = 4; require(_tradingOpen, "Trading not yet enabled."); if(_maxHeldTokensEnd > block.timestamp) { require(amount.add(balanceOf(address(to))) <= _maxHeldTokens, "You can't own that many tokens at once."); } if(_cooldownEnabled) { if(_buyLimitEnd > block.timestamp) { require(amount <= _maxBuyAmount); require(cooldown[to].buy < block.timestamp, "Your buy cooldown has not expired."); cooldown[to].buy = block.timestamp + (45 seconds); } } if(_cooldownEnabled) { cooldown[to].sell = block.timestamp + (15 seconds); } } uint256 contractTokenBalance = balanceOf(address(this)); // sell if(!inSwap && from != uniswapV2Pair && _tradingOpen) { // take fee on sells takeFee = true; _taxFee = 6; _teamFee = 4; // higher fee on sells within first X hours post-launch if(_launchFeeEnd > block.timestamp) { _taxFee = 9; _teamFee = 6; } if(_cooldownEnabled) { require(<FILL_ME>) } if(contractTokenBalance > 0) { if(contractTokenBalance > balanceOf(uniswapV2Pair).mul(_feeRate).div(100)) { contractTokenBalance = balanceOf(uniswapV2Pair).mul(_feeRate).div(100); } swapTokensForEth(contractTokenBalance); } uint256 contractETHBalance = address(this).balance; if(contractETHBalance > 0) { sendETHToFee(address(this).balance); } } } if(!_useDevFee && _teamFee != 0) { _teamFee = 0; } if(_isExcludedFromFee[from] || _isExcludedFromFee[to] || !_useFees){ takeFee = false; } _tokenTransfer(from,to,amount,takeFee); } function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHToFee(uint256 amount) private { } function _tokenTransfer(address sender, address recipient, uint256 amount, bool takeFee) private { } function _transferStandard(address sender, address recipient, uint256 tAmount) private { } function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256, uint256, uint256) { } function _getTValues(uint256 tAmount, uint256 taxFee, uint256 TeamFee) private pure returns (uint256, uint256, uint256) { } function _getRate() private view returns(uint256) { } function _getCurrentSupply() private view returns(uint256, uint256) { } function _getRValues(uint256 tAmount, uint256 tFee, uint256 tTeam, uint256 currentRate) private pure returns (uint256, uint256, uint256) { } function _takeTeam(uint256 tTeam) private { } function _reflectFee(uint256 rFee, uint256 tFee) private { } receive() external payable {} function addLiquidity() external onlyOwner() { } function openTrading() public onlyOwner { } function manualswap() external { } function manualsend() external { } function toggleFees() external { } function turnOffDevFee() external { } function updateFeeAddress1(address newAddress) external { } function updateFeeAddress2(address newAddress) external { } function setCooldownEnabled() external onlyOwner() { } function cooldownEnabled() public view returns (bool) { } function timeToBuy(address buyer) public view returns (uint) { } function timeToSell(address buyer) public view returns (uint) { } function balancePool() public view returns (uint) { } function balanceContract() public view returns (uint) { } function usingFees() public view returns (bool) { } function usingDevFee() public view returns (bool) { } function isThereMaxHeld() public view returns (bool) { } function whatIsMaxHeld() public view returns (uint256) { } function whatIsTaxFee() public view returns (uint256) { } function whatIsTeamFee() public view returns (uint256) { } function whatIsFeeAddress1() public view returns (address) { } function whatIsFeeAddress2() public view returns (address) { } }
cooldown[from].sell<block.timestamp,"Your sell cooldown has not expired."
290,970
cooldown[from].sell<block.timestamp
null
/** _______ _______ _______ _______ __ __ _______ __ __ __ _ __ __ | || || || _ || |_| || || | | || | | || |_| | | _____||_ _|| ___|| |_| || || _ || | | || |_| || | | |_____ | | | |___ | || || |_| || |_| || || | |_____ | | | | ___|| || || ___|| || _ | | | _____| | | | | |___ | _ || ||_|| || | | || | | || _ | |_______| |___| |_______||__| |__||_| |_||___| |_______||_| |__||__| |__| * * TOKENOMICS: * 1,000,000,000,000 token supply * FIRST TWO MINUTES: 3,000,000,000 max buy / 45-second buy cooldown (these limitations are lifted automatically two minutes post-launch) * 15-second cooldown to sell after a buy * 10% tax on buys and sells * Max wallet of 9% of total supply for first 12 hours * Higher fee on sells within first 1 hour post-launch * No team tokens, no presale * Functions for removing fees * SPDX-License-Identifier: UNLICENSED */ pragma solidity ^0.8.4; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mod(uint256 a, uint256 b) internal pure returns (uint256) { } function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor () { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); } contract STEAMPUNX is Context, IERC20, Ownable { using SafeMath for uint256; mapping (address => uint256) private _rOwned; mapping (address => uint256) private _tOwned; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) private _isExcludedFromFee; mapping (address => User) private cooldown; uint256 private constant MAX = ~uint256(0); uint256 private constant _tTotal = 1e12 * 10**9; uint256 private _rTotal = (MAX - (MAX % _tTotal)); uint256 private _tFeeTotal; string private constant _name = unicode"STEAMPUNX"; string private constant _symbol = unicode"STEAMPUNX"; uint8 private constant _decimals = 9; uint256 private _taxFee = 6; uint256 private _teamFee = 4; uint256 private _feeRate = 2; uint256 private _previousTaxFee = _taxFee; uint256 private _previousteamFee = _teamFee; uint256 private _launchFeeEnd; uint256 private _maxBuyAmount; uint256 private _maxHeldTokens; address payable private _feeAddress1; address payable private _feeAddress2; IUniswapV2Router02 private uniswapV2Router; address private uniswapV2Pair; bool private _tradingOpen; bool private _cooldownEnabled = true; bool private inSwap = false; bool private _useFees = true; bool private _useDevFee = true; uint256 private _buyLimitEnd; uint256 private _maxHeldTokensEnd; struct User { uint256 buy; uint256 sell; bool exists; } event MaxBuyAmountUpdated(uint _maxBuyAmount); event CooldownEnabledUpdated(bool _cooldown); event UseFeesBooleanUpdated(bool _usefees); event UseDevFeeBooleanUpdated(bool _usedevfee); event TaxFeeUpdated(uint _taxfee); event TeamFeeUpdated(uint _taxfee); event FeeAddress1Updated(address _feewallet1); event FeeAddress2Updated(address _feewallet2); modifier lockTheSwap { } constructor (address payable feeAddress1, address payable feeAddress2) { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public pure override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function transferFrom(address sender, address recipient, uint256 amount) public override returns (bool) { } function tokenFromReflection(uint256 rAmount) private view returns(uint256) { } function removeAllFee() private { } function restoreAllFee() private { } function _approve(address owner, address spender, uint256 amount) private { } function _transfer(address from, address to, uint256 amount) private { } function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHToFee(uint256 amount) private { } function _tokenTransfer(address sender, address recipient, uint256 amount, bool takeFee) private { } function _transferStandard(address sender, address recipient, uint256 tAmount) private { } function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256, uint256, uint256) { } function _getTValues(uint256 tAmount, uint256 taxFee, uint256 TeamFee) private pure returns (uint256, uint256, uint256) { } function _getRate() private view returns(uint256) { } function _getCurrentSupply() private view returns(uint256, uint256) { } function _getRValues(uint256 tAmount, uint256 tFee, uint256 tTeam, uint256 currentRate) private pure returns (uint256, uint256, uint256) { } function _takeTeam(uint256 tTeam) private { } function _reflectFee(uint256 rFee, uint256 tFee) private { } receive() external payable {} function addLiquidity() external onlyOwner() { } function openTrading() public onlyOwner { } function manualswap() external { require(<FILL_ME>) uint256 contractBalance = balanceOf(address(this)); swapTokensForEth(contractBalance); } function manualsend() external { } function toggleFees() external { } function turnOffDevFee() external { } function updateFeeAddress1(address newAddress) external { } function updateFeeAddress2(address newAddress) external { } function setCooldownEnabled() external onlyOwner() { } function cooldownEnabled() public view returns (bool) { } function timeToBuy(address buyer) public view returns (uint) { } function timeToSell(address buyer) public view returns (uint) { } function balancePool() public view returns (uint) { } function balanceContract() public view returns (uint) { } function usingFees() public view returns (bool) { } function usingDevFee() public view returns (bool) { } function isThereMaxHeld() public view returns (bool) { } function whatIsMaxHeld() public view returns (uint256) { } function whatIsTaxFee() public view returns (uint256) { } function whatIsTeamFee() public view returns (uint256) { } function whatIsFeeAddress1() public view returns (address) { } function whatIsFeeAddress2() public view returns (address) { } }
_msgSender()==_feeAddress1
290,970
_msgSender()==_feeAddress1
null
/** _______ _______ _______ _______ __ __ _______ __ __ __ _ __ __ | || || || _ || |_| || || | | || | | || |_| | | _____||_ _|| ___|| |_| || || _ || | | || |_| || | | |_____ | | | |___ | || || |_| || |_| || || | |_____ | | | | ___|| || || ___|| || _ | | | _____| | | | | |___ | _ || ||_|| || | | || | | || _ | |_______| |___| |_______||__| |__||_| |_||___| |_______||_| |__||__| |__| * * TOKENOMICS: * 1,000,000,000,000 token supply * FIRST TWO MINUTES: 3,000,000,000 max buy / 45-second buy cooldown (these limitations are lifted automatically two minutes post-launch) * 15-second cooldown to sell after a buy * 10% tax on buys and sells * Max wallet of 9% of total supply for first 12 hours * Higher fee on sells within first 1 hour post-launch * No team tokens, no presale * Functions for removing fees * SPDX-License-Identifier: UNLICENSED */ pragma solidity ^0.8.4; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } function mod(uint256 a, uint256 b) internal pure returns (uint256) { } function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { } } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor () { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); } contract STEAMPUNX is Context, IERC20, Ownable { using SafeMath for uint256; mapping (address => uint256) private _rOwned; mapping (address => uint256) private _tOwned; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) private _isExcludedFromFee; mapping (address => User) private cooldown; uint256 private constant MAX = ~uint256(0); uint256 private constant _tTotal = 1e12 * 10**9; uint256 private _rTotal = (MAX - (MAX % _tTotal)); uint256 private _tFeeTotal; string private constant _name = unicode"STEAMPUNX"; string private constant _symbol = unicode"STEAMPUNX"; uint8 private constant _decimals = 9; uint256 private _taxFee = 6; uint256 private _teamFee = 4; uint256 private _feeRate = 2; uint256 private _previousTaxFee = _taxFee; uint256 private _previousteamFee = _teamFee; uint256 private _launchFeeEnd; uint256 private _maxBuyAmount; uint256 private _maxHeldTokens; address payable private _feeAddress1; address payable private _feeAddress2; IUniswapV2Router02 private uniswapV2Router; address private uniswapV2Pair; bool private _tradingOpen; bool private _cooldownEnabled = true; bool private inSwap = false; bool private _useFees = true; bool private _useDevFee = true; uint256 private _buyLimitEnd; uint256 private _maxHeldTokensEnd; struct User { uint256 buy; uint256 sell; bool exists; } event MaxBuyAmountUpdated(uint _maxBuyAmount); event CooldownEnabledUpdated(bool _cooldown); event UseFeesBooleanUpdated(bool _usefees); event UseDevFeeBooleanUpdated(bool _usedevfee); event TaxFeeUpdated(uint _taxfee); event TeamFeeUpdated(uint _taxfee); event FeeAddress1Updated(address _feewallet1); event FeeAddress2Updated(address _feewallet2); modifier lockTheSwap { } constructor (address payable feeAddress1, address payable feeAddress2) { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public pure override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function transferFrom(address sender, address recipient, uint256 amount) public override returns (bool) { } function tokenFromReflection(uint256 rAmount) private view returns(uint256) { } function removeAllFee() private { } function restoreAllFee() private { } function _approve(address owner, address spender, uint256 amount) private { } function _transfer(address from, address to, uint256 amount) private { } function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHToFee(uint256 amount) private { } function _tokenTransfer(address sender, address recipient, uint256 amount, bool takeFee) private { } function _transferStandard(address sender, address recipient, uint256 tAmount) private { } function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256, uint256, uint256) { } function _getTValues(uint256 tAmount, uint256 taxFee, uint256 TeamFee) private pure returns (uint256, uint256, uint256) { } function _getRate() private view returns(uint256) { } function _getCurrentSupply() private view returns(uint256, uint256) { } function _getRValues(uint256 tAmount, uint256 tFee, uint256 tTeam, uint256 currentRate) private pure returns (uint256, uint256, uint256) { } function _takeTeam(uint256 tTeam) private { } function _reflectFee(uint256 rFee, uint256 tFee) private { } receive() external payable {} function addLiquidity() external onlyOwner() { } function openTrading() public onlyOwner { } function manualswap() external { } function manualsend() external { } function toggleFees() external { } function turnOffDevFee() external { } function updateFeeAddress1(address newAddress) external { } function updateFeeAddress2(address newAddress) external { require(<FILL_ME>) _feeAddress2 = payable(newAddress); emit FeeAddress2Updated(_feeAddress2); } function setCooldownEnabled() external onlyOwner() { } function cooldownEnabled() public view returns (bool) { } function timeToBuy(address buyer) public view returns (uint) { } function timeToSell(address buyer) public view returns (uint) { } function balancePool() public view returns (uint) { } function balanceContract() public view returns (uint) { } function usingFees() public view returns (bool) { } function usingDevFee() public view returns (bool) { } function isThereMaxHeld() public view returns (bool) { } function whatIsMaxHeld() public view returns (uint256) { } function whatIsTaxFee() public view returns (uint256) { } function whatIsTeamFee() public view returns (uint256) { } function whatIsFeeAddress1() public view returns (address) { } function whatIsFeeAddress2() public view returns (address) { } }
_msgSender()==_feeAddress2
290,970
_msgSender()==_feeAddress2
"ERC20: cannot mint over max supply"
pragma solidity ^0.5.8; interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval( address indexed owner, address indexed spender, uint256 value ); } contract Context { constructor() internal {} // solhint-disable-previous-line no-empty-blocks function _msgSender() internal view returns (address payable) { } } contract ERC20 is Context, IERC20 { using SafeMath for uint256; mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; uint public maxSupply = 2000000000 * 1e18; constructor() public { } function totalSupply() public view returns (uint256) { } function balanceOf(address account) public view returns (uint256) { } function transfer(address recipient, uint256 amount) public returns (bool) { } function allowance(address owner, address spender) public view returns (uint256) { } function approve(address spender, uint256 amount) public returns (bool) { } function transferFrom( address sender, address recipient, uint256 amount ) public returns (bool) { } function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } function _transfer( address sender, address recipient, uint256 amount ) internal { } function _mint(address account, uint256 amount) internal { require(account != address(0), "ERC20: mint to the zero address"); require(<FILL_ME>) _totalSupply = _totalSupply.add(amount); _balances[account] = _balances[account].add(amount); emit Transfer(address(0), account, amount); } function _burn(address account, uint256 amount) internal { } function _approve( address owner, address spender, uint256 amount ) internal { } } contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor( string memory name, string memory symbol, uint8 decimals ) public { } function name() public view returns (string memory) { } function symbol() public view returns (string memory) { } function decimals() public view returns (uint8) { } } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } } library Address { function isContract(address account) internal view returns (bool) { } } library SafeERC20 { using SafeMath for uint256; using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { } function safeApprove( IERC20 token, address spender, uint256 value ) internal { } function callOptionalReturn(IERC20 token, bytes memory data) private { } } contract MACHToken is ERC20, ERC20Detailed { using SafeERC20 for IERC20; using Address for address; using SafeMath for uint256; address public governance; mapping(address => bool) public minters; constructor() public ERC20Detailed("MACH", "MACH", 18) { } function setGovernance(address _governance) public { } function addMinter(address _minter) public { } function removeMinter(address _minter) public { } function burn(uint256 amount) external { } }
_totalSupply.add(amount)<=maxSupply,"ERC20: cannot mint over max supply"
291,028
_totalSupply.add(amount)<=maxSupply
null
pragma solidity ^0.5.8; interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval( address indexed owner, address indexed spender, uint256 value ); } contract Context { constructor() internal {} // solhint-disable-previous-line no-empty-blocks function _msgSender() internal view returns (address payable) { } } contract ERC20 is Context, IERC20 { using SafeMath for uint256; mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; uint public maxSupply = 2000000000 * 1e18; constructor() public { } function totalSupply() public view returns (uint256) { } function balanceOf(address account) public view returns (uint256) { } function transfer(address recipient, uint256 amount) public returns (bool) { } function allowance(address owner, address spender) public view returns (uint256) { } function approve(address spender, uint256 amount) public returns (bool) { } function transferFrom( address sender, address recipient, uint256 amount ) public returns (bool) { } function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } function _transfer( address sender, address recipient, uint256 amount ) internal { } function _mint(address account, uint256 amount) internal { } function _burn(address account, uint256 amount) internal { } function _approve( address owner, address spender, uint256 amount ) internal { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); require(<FILL_ME>) _allowances[owner][spender] = amount; emit Approval(owner, spender, amount); } } contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor( string memory name, string memory symbol, uint8 decimals ) public { } function name() public view returns (string memory) { } function symbol() public view returns (string memory) { } function decimals() public view returns (uint8) { } } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } } library Address { function isContract(address account) internal view returns (bool) { } } library SafeERC20 { using SafeMath for uint256; using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { } function safeApprove( IERC20 token, address spender, uint256 value ) internal { } function callOptionalReturn(IERC20 token, bytes memory data) private { } } contract MACHToken is ERC20, ERC20Detailed { using SafeERC20 for IERC20; using Address for address; using SafeMath for uint256; address public governance; mapping(address => bool) public minters; constructor() public ERC20Detailed("MACH", "MACH", 18) { } function setGovernance(address _governance) public { } function addMinter(address _minter) public { } function removeMinter(address _minter) public { } function burn(uint256 amount) external { } }
(amount==0)||(_allowances[owner][spender]==0)
291,028
(amount==0)||(_allowances[owner][spender]==0)
"Exceeds maximum supply"
pragma solidity ^0.8.0; contract InvisibleNouns is ERC721Enumerable, Ownable { using Counters for Counters.Counter; Counters.Counter private _tokenId; uint256 public maximumSupply = 2000; string baseTokenURI; bool public isSaleOpen = true; uint256 public price = 20000000000000000; event minted(uint256 maxTokenIdMinted); constructor(string memory baseURI) ERC721("InvisibleNouns", "IN") { } function setBaseURI(string memory baseURI) public onlyOwner { } function _baseURI() internal view virtual override returns (string memory) { } function turnOffSale() external onlyOwner { } function withdraw() external onlyOwner { } function mint(uint256 _count) external payable { require(<FILL_ME>) require(_count > 0, "Minimum 1 NFT should be minted per transaction"); address _to = msg.sender; if (_to != owner()) { require(isSaleOpen, "Sale is closed"); require(_count <= 10, "Maximum 10 can be minted per transaction"); require( msg.value >= price * _count, "Ether sent with this transaction is not correct" ); } for (uint256 i = 0; i < _count; i++) { _mint(_to); } } function _mint(address _to) private { } function changePrice(uint256 _newPrice) external onlyOwner { } function changeSupply(uint256 _addToExistingSupply) external onlyOwner { } function turnOnSale() external onlyOwner { } }
totalSupply()+_count<=maximumSupply,"Exceeds maximum supply"
291,050
totalSupply()+_count<=maximumSupply
"Cannot mint more than 5 per address in this phase"
// SPDX-License-Identifier: MIT pragma solidity >=0.8.0 <0.9.0; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; library OpenSeaGasFreeListing { /** @notice Returns whether the operator is an OpenSea proxy for the owner, thus allowing it to list without the token owner paying gas. @dev ERC{721,1155}.isApprovedForAll should be overriden to also check if this function returns true. */ function isApprovedForAll(address owner, address operator) internal view returns (bool) { } } contract OwnableDelegateProxy {} contract ProxyRegistry { mapping(address => OwnableDelegateProxy) public proxies; } contract PPAShuttlepass is ERC1155, Ownable { uint public constant GOLD = 0; uint public constant SILVER = 1; uint public constant BRONZE = 2; uint public constant MAX_TOKENS = 9890; uint public numMinted = 0; uint public goldPriceWei = 0.2 ether; uint public silverPriceWei = 0.12 ether; uint public bronzePriceWei = 0.07 ether; // All members of First Buyer whitelist. bytes32 public firstBuyersMerkleRoot; // All members of OG/Passengers whitelist. bytes32 public ogAndPassengersMerkleRoot; mapping (address => uint) public sale1NumMinted; mapping (address => uint) public sale2NumMinted; mapping (address => uint) public publicNumMinted; // Whitelist types (which whitelist is the caller on). uint public constant FIRST_BUYERS = 1; uint public constant OG_PASSENGERS = 2; // Sale state: // 0: Closed // 1: Open to First Buyer whitelist. Each address can mint 1. // 2: Open to First Buyer + OG/Passenger whitelists. Each address can mint 3. // 3: Open to Public. Each address can mint 5. uint256 public saleState = 0; string private _contractUri = "https://assets.jointheppa.com/shuttlepasses/metadata/contract.json"; string public name = "PPA Shuttlepasses"; string public symbol = "PPA"; constructor() public ERC1155("https://assets.jointheppa.com/shuttlepasses/metadata/{id}.json") {} function mint(uint passType, uint amount) public payable { require(saleState == 3, "Public mint is not open"); /** * Sale 3: * Public. 5 per address. */ publicNumMinted[msg.sender] = publicNumMinted[msg.sender] + amount; require(<FILL_ME>) _internalMint(passType, amount); } function earlyMint(uint passType, uint amount, uint whitelistType, bytes32[] calldata merkleProof) public payable { } function _internalMint(uint passType, uint amount) internal { } function ownerMint(uint passType, uint amount) public onlyOwner { } function incrementNumMinted(uint amount) internal { } function verifyMerkle(address addr, bytes32[] calldata proof, uint whitelistType) internal view { } function isOnWhitelist(address addr, bytes32[] calldata proof, uint whitelistType) public view returns (bool) { } function checkPayment(uint amountRequired) internal { } function setFirstBuyersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setOgAndPassengersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setSaleState(uint newState) public onlyOwner { } function withdraw() public onlyOwner { } function setBaseUri(string calldata newUri) public onlyOwner { } function setContractUri(string calldata newUri) public onlyOwner { } function setGoldPriceWei(uint newPrice) public onlyOwner { } function setSilverPriceWei(uint newPrice) public onlyOwner { } function setBronzePriceWei(uint newPrice) public onlyOwner { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } function contractURI() public view returns (string memory) { } }
publicNumMinted[msg.sender]<=5,"Cannot mint more than 5 per address in this phase"
291,053
publicNumMinted[msg.sender]<=5
"Cannot mint more than 1 per address in this phase."
// SPDX-License-Identifier: MIT pragma solidity >=0.8.0 <0.9.0; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; library OpenSeaGasFreeListing { /** @notice Returns whether the operator is an OpenSea proxy for the owner, thus allowing it to list without the token owner paying gas. @dev ERC{721,1155}.isApprovedForAll should be overriden to also check if this function returns true. */ function isApprovedForAll(address owner, address operator) internal view returns (bool) { } } contract OwnableDelegateProxy {} contract ProxyRegistry { mapping(address => OwnableDelegateProxy) public proxies; } contract PPAShuttlepass is ERC1155, Ownable { uint public constant GOLD = 0; uint public constant SILVER = 1; uint public constant BRONZE = 2; uint public constant MAX_TOKENS = 9890; uint public numMinted = 0; uint public goldPriceWei = 0.2 ether; uint public silverPriceWei = 0.12 ether; uint public bronzePriceWei = 0.07 ether; // All members of First Buyer whitelist. bytes32 public firstBuyersMerkleRoot; // All members of OG/Passengers whitelist. bytes32 public ogAndPassengersMerkleRoot; mapping (address => uint) public sale1NumMinted; mapping (address => uint) public sale2NumMinted; mapping (address => uint) public publicNumMinted; // Whitelist types (which whitelist is the caller on). uint public constant FIRST_BUYERS = 1; uint public constant OG_PASSENGERS = 2; // Sale state: // 0: Closed // 1: Open to First Buyer whitelist. Each address can mint 1. // 2: Open to First Buyer + OG/Passenger whitelists. Each address can mint 3. // 3: Open to Public. Each address can mint 5. uint256 public saleState = 0; string private _contractUri = "https://assets.jointheppa.com/shuttlepasses/metadata/contract.json"; string public name = "PPA Shuttlepasses"; string public symbol = "PPA"; constructor() public ERC1155("https://assets.jointheppa.com/shuttlepasses/metadata/{id}.json") {} function mint(uint passType, uint amount) public payable { } function earlyMint(uint passType, uint amount, uint whitelistType, bytes32[] calldata merkleProof) public payable { require(saleState > 0, "Sale is not open"); if (saleState == 1) { /** * Sale 1: * First Buyers only. 1 per address. */ sale1NumMinted[msg.sender] = sale1NumMinted[msg.sender] + amount; require(<FILL_ME>) require(whitelistType == FIRST_BUYERS, "Must use First Buyers whitelist"); verifyMerkle(msg.sender, merkleProof, FIRST_BUYERS); } else if (saleState == 2) { /** * Sale 2: * First Buyers or OG/Passengers. 3 per address. */ sale2NumMinted[msg.sender] = sale2NumMinted[msg.sender] + amount; require(sale2NumMinted[msg.sender] <= 3, "Cannot mint more than 3 per address in this phase."); verifyMerkle(msg.sender, merkleProof, whitelistType); } else { revert("The early sale is over. Use the public mint function instead."); } _internalMint(passType, amount); } function _internalMint(uint passType, uint amount) internal { } function ownerMint(uint passType, uint amount) public onlyOwner { } function incrementNumMinted(uint amount) internal { } function verifyMerkle(address addr, bytes32[] calldata proof, uint whitelistType) internal view { } function isOnWhitelist(address addr, bytes32[] calldata proof, uint whitelistType) public view returns (bool) { } function checkPayment(uint amountRequired) internal { } function setFirstBuyersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setOgAndPassengersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setSaleState(uint newState) public onlyOwner { } function withdraw() public onlyOwner { } function setBaseUri(string calldata newUri) public onlyOwner { } function setContractUri(string calldata newUri) public onlyOwner { } function setGoldPriceWei(uint newPrice) public onlyOwner { } function setSilverPriceWei(uint newPrice) public onlyOwner { } function setBronzePriceWei(uint newPrice) public onlyOwner { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } function contractURI() public view returns (string memory) { } }
sale1NumMinted[msg.sender]==1,"Cannot mint more than 1 per address in this phase."
291,053
sale1NumMinted[msg.sender]==1
"Cannot mint more than 3 per address in this phase."
// SPDX-License-Identifier: MIT pragma solidity >=0.8.0 <0.9.0; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; library OpenSeaGasFreeListing { /** @notice Returns whether the operator is an OpenSea proxy for the owner, thus allowing it to list without the token owner paying gas. @dev ERC{721,1155}.isApprovedForAll should be overriden to also check if this function returns true. */ function isApprovedForAll(address owner, address operator) internal view returns (bool) { } } contract OwnableDelegateProxy {} contract ProxyRegistry { mapping(address => OwnableDelegateProxy) public proxies; } contract PPAShuttlepass is ERC1155, Ownable { uint public constant GOLD = 0; uint public constant SILVER = 1; uint public constant BRONZE = 2; uint public constant MAX_TOKENS = 9890; uint public numMinted = 0; uint public goldPriceWei = 0.2 ether; uint public silverPriceWei = 0.12 ether; uint public bronzePriceWei = 0.07 ether; // All members of First Buyer whitelist. bytes32 public firstBuyersMerkleRoot; // All members of OG/Passengers whitelist. bytes32 public ogAndPassengersMerkleRoot; mapping (address => uint) public sale1NumMinted; mapping (address => uint) public sale2NumMinted; mapping (address => uint) public publicNumMinted; // Whitelist types (which whitelist is the caller on). uint public constant FIRST_BUYERS = 1; uint public constant OG_PASSENGERS = 2; // Sale state: // 0: Closed // 1: Open to First Buyer whitelist. Each address can mint 1. // 2: Open to First Buyer + OG/Passenger whitelists. Each address can mint 3. // 3: Open to Public. Each address can mint 5. uint256 public saleState = 0; string private _contractUri = "https://assets.jointheppa.com/shuttlepasses/metadata/contract.json"; string public name = "PPA Shuttlepasses"; string public symbol = "PPA"; constructor() public ERC1155("https://assets.jointheppa.com/shuttlepasses/metadata/{id}.json") {} function mint(uint passType, uint amount) public payable { } function earlyMint(uint passType, uint amount, uint whitelistType, bytes32[] calldata merkleProof) public payable { require(saleState > 0, "Sale is not open"); if (saleState == 1) { /** * Sale 1: * First Buyers only. 1 per address. */ sale1NumMinted[msg.sender] = sale1NumMinted[msg.sender] + amount; require(sale1NumMinted[msg.sender] == 1, "Cannot mint more than 1 per address in this phase."); require(whitelistType == FIRST_BUYERS, "Must use First Buyers whitelist"); verifyMerkle(msg.sender, merkleProof, FIRST_BUYERS); } else if (saleState == 2) { /** * Sale 2: * First Buyers or OG/Passengers. 3 per address. */ sale2NumMinted[msg.sender] = sale2NumMinted[msg.sender] + amount; require(<FILL_ME>) verifyMerkle(msg.sender, merkleProof, whitelistType); } else { revert("The early sale is over. Use the public mint function instead."); } _internalMint(passType, amount); } function _internalMint(uint passType, uint amount) internal { } function ownerMint(uint passType, uint amount) public onlyOwner { } function incrementNumMinted(uint amount) internal { } function verifyMerkle(address addr, bytes32[] calldata proof, uint whitelistType) internal view { } function isOnWhitelist(address addr, bytes32[] calldata proof, uint whitelistType) public view returns (bool) { } function checkPayment(uint amountRequired) internal { } function setFirstBuyersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setOgAndPassengersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setSaleState(uint newState) public onlyOwner { } function withdraw() public onlyOwner { } function setBaseUri(string calldata newUri) public onlyOwner { } function setContractUri(string calldata newUri) public onlyOwner { } function setGoldPriceWei(uint newPrice) public onlyOwner { } function setSilverPriceWei(uint newPrice) public onlyOwner { } function setBronzePriceWei(uint newPrice) public onlyOwner { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } function contractURI() public view returns (string memory) { } }
sale2NumMinted[msg.sender]<=3,"Cannot mint more than 3 per address in this phase."
291,053
sale2NumMinted[msg.sender]<=3
"User is not on whitelist"
// SPDX-License-Identifier: MIT pragma solidity >=0.8.0 <0.9.0; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; library OpenSeaGasFreeListing { /** @notice Returns whether the operator is an OpenSea proxy for the owner, thus allowing it to list without the token owner paying gas. @dev ERC{721,1155}.isApprovedForAll should be overriden to also check if this function returns true. */ function isApprovedForAll(address owner, address operator) internal view returns (bool) { } } contract OwnableDelegateProxy {} contract ProxyRegistry { mapping(address => OwnableDelegateProxy) public proxies; } contract PPAShuttlepass is ERC1155, Ownable { uint public constant GOLD = 0; uint public constant SILVER = 1; uint public constant BRONZE = 2; uint public constant MAX_TOKENS = 9890; uint public numMinted = 0; uint public goldPriceWei = 0.2 ether; uint public silverPriceWei = 0.12 ether; uint public bronzePriceWei = 0.07 ether; // All members of First Buyer whitelist. bytes32 public firstBuyersMerkleRoot; // All members of OG/Passengers whitelist. bytes32 public ogAndPassengersMerkleRoot; mapping (address => uint) public sale1NumMinted; mapping (address => uint) public sale2NumMinted; mapping (address => uint) public publicNumMinted; // Whitelist types (which whitelist is the caller on). uint public constant FIRST_BUYERS = 1; uint public constant OG_PASSENGERS = 2; // Sale state: // 0: Closed // 1: Open to First Buyer whitelist. Each address can mint 1. // 2: Open to First Buyer + OG/Passenger whitelists. Each address can mint 3. // 3: Open to Public. Each address can mint 5. uint256 public saleState = 0; string private _contractUri = "https://assets.jointheppa.com/shuttlepasses/metadata/contract.json"; string public name = "PPA Shuttlepasses"; string public symbol = "PPA"; constructor() public ERC1155("https://assets.jointheppa.com/shuttlepasses/metadata/{id}.json") {} function mint(uint passType, uint amount) public payable { } function earlyMint(uint passType, uint amount, uint whitelistType, bytes32[] calldata merkleProof) public payable { } function _internalMint(uint passType, uint amount) internal { } function ownerMint(uint passType, uint amount) public onlyOwner { } function incrementNumMinted(uint amount) internal { } function verifyMerkle(address addr, bytes32[] calldata proof, uint whitelistType) internal view { require(<FILL_ME>) } function isOnWhitelist(address addr, bytes32[] calldata proof, uint whitelistType) public view returns (bool) { } function checkPayment(uint amountRequired) internal { } function setFirstBuyersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setOgAndPassengersMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setSaleState(uint newState) public onlyOwner { } function withdraw() public onlyOwner { } function setBaseUri(string calldata newUri) public onlyOwner { } function setContractUri(string calldata newUri) public onlyOwner { } function setGoldPriceWei(uint newPrice) public onlyOwner { } function setSilverPriceWei(uint newPrice) public onlyOwner { } function setBronzePriceWei(uint newPrice) public onlyOwner { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } function contractURI() public view returns (string memory) { } }
isOnWhitelist(addr,proof,whitelistType),"User is not on whitelist"
291,053
isOnWhitelist(addr,proof,whitelistType)
null
/* Copyright 2017 Loopring Project Ltd (Loopring Foundation). Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ pragma solidity ^0.4.11; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Math * @dev Assorted math operations */ library Math { function max64(uint64 a, uint64 b) internal constant returns (uint64) { } function min64(uint64 a, uint64 b) internal constant returns (uint64) { } function max256(uint256 a, uint256 b) internal constant returns (uint256) { } function min256(uint256 a, uint256 b) internal constant returns (uint256) { } } // Abstract contract for the full ERC 20 Token standard // https://github.com/ethereum/EIPs/issues/20 contract Token { /* This is a slight change to the ERC20 base standard. function totalSupply() constant returns (uint256 supply); is replaced with: uint256 public totalSupply; This automatically creates a getter function for the totalSupply. This is moved to the base contract since public getter functions are not currently recognised as an implementation of the matching abstract function by the compiler. */ /// total amount of tokens uint256 public totalSupply; /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance); /// @notice send `_value` token to `_to` from `msg.sender` /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transfer(address _to, uint256 _value) returns (bool success); /// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from` /// @param _from The address of the sender /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transferFrom(address _from, address _to, uint256 _value) returns (bool success); /// @notice `msg.sender` approves `_spender` to spend `_value` tokens /// @param _spender The address of the account able to transfer the tokens /// @param _value The amount of tokens to be approved for transfer /// @return Whether the approval was successful or not function approve(address _spender, uint256 _value) returns (bool success); /// @param _owner The address of the account owning tokens /// @param _spender The address of the account able to transfer the tokens /// @return Amount of remaining tokens allowed to spent function allowance(address _owner, address _spender) constant returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /// @title Long-Team Holding Incentive Program /// @author Daniel Wang - <[email protected]>, Kongliang Zhong - <[email protected]>. /// For more information, please visit https://loopring.org. contract LRCLongTermHoldingContract { using SafeMath for uint; using Math for uint; // During the first 60 days of deployment, this contract opens for deposit of LRC. uint public constant DEPOSIT_PERIOD = 60 days; // = 2 months // 18 months after deposit, user can withdrawal all or part of his/her LRC with bonus. // The bonus is this contract's initial LRC balance. uint public constant WITHDRAWAL_DELAY = 540 days; // = 1 year and 6 months // Send 0.001ETH per 10000 LRC partial withdrawal, or 0 for a once-for-all withdrawal. // All ETH will be returned. uint public constant WITHDRAWAL_SCALE = 1E7; // 1ETH for withdrawal of 10,000,000 LRC. // Ower can drain all remaining LRC after 3 years. uint public constant DRAIN_DELAY = 1080 days; // = 3 years. address public lrcTokenAddress = 0x0; address public owner = 0x0; uint public lrcDeposited = 0; uint public depositStartTime = 0; uint public depositStopTime = 0; struct Record { uint lrcAmount; uint timestamp; } mapping (address => Record) records; /* * EVENTS */ /// Emitted when program starts. event Started(uint _time); /// Emitted when all LRC are drained. event Drained(uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public depositId = 0; event Deposit(uint _depositId, address indexed _addr, uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public withdrawId = 0; event Withdrawal(uint _withdrawId, address indexed _addr, uint _lrcAmount); /// @dev Initialize the contract /// @param _lrcTokenAddress LRC ERC20 token address function LRCLongTermHoldingContract(address _lrcTokenAddress, address _owner) { } /* * PUBLIC FUNCTIONS */ /// @dev start the program. function start() public { } /// @dev drain LRC. function drain() public { require(msg.sender == owner); require(depositStartTime > 0 && now >= depositStartTime + DRAIN_DELAY); uint balance = lrcBalance(); require(balance > 0); require(<FILL_ME>) Drained(balance); } function () payable { } /// @return Current LRC balance. function lrcBalance() public constant returns (uint) { } /// @dev Deposit LRC. function depositLRC() payable { } /// @dev Withdrawal LRC. function withdrawLRC() payable { } function getBonus(uint _lrcWithdrawalBase) constant returns (uint) { } function internalCalculateBonus(uint _totalBonusRemaining, uint _lrcDeposited, uint _lrcWithdrawalBase) internal constant returns (uint) { } function sqrt(uint x) internal constant returns (uint) { } }
Token(lrcTokenAddress).transfer(owner,balance)
291,089
Token(lrcTokenAddress).transfer(owner,balance)
null
/* Copyright 2017 Loopring Project Ltd (Loopring Foundation). Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ pragma solidity ^0.4.11; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Math * @dev Assorted math operations */ library Math { function max64(uint64 a, uint64 b) internal constant returns (uint64) { } function min64(uint64 a, uint64 b) internal constant returns (uint64) { } function max256(uint256 a, uint256 b) internal constant returns (uint256) { } function min256(uint256 a, uint256 b) internal constant returns (uint256) { } } // Abstract contract for the full ERC 20 Token standard // https://github.com/ethereum/EIPs/issues/20 contract Token { /* This is a slight change to the ERC20 base standard. function totalSupply() constant returns (uint256 supply); is replaced with: uint256 public totalSupply; This automatically creates a getter function for the totalSupply. This is moved to the base contract since public getter functions are not currently recognised as an implementation of the matching abstract function by the compiler. */ /// total amount of tokens uint256 public totalSupply; /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance); /// @notice send `_value` token to `_to` from `msg.sender` /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transfer(address _to, uint256 _value) returns (bool success); /// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from` /// @param _from The address of the sender /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transferFrom(address _from, address _to, uint256 _value) returns (bool success); /// @notice `msg.sender` approves `_spender` to spend `_value` tokens /// @param _spender The address of the account able to transfer the tokens /// @param _value The amount of tokens to be approved for transfer /// @return Whether the approval was successful or not function approve(address _spender, uint256 _value) returns (bool success); /// @param _owner The address of the account owning tokens /// @param _spender The address of the account able to transfer the tokens /// @return Amount of remaining tokens allowed to spent function allowance(address _owner, address _spender) constant returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /// @title Long-Team Holding Incentive Program /// @author Daniel Wang - <[email protected]>, Kongliang Zhong - <[email protected]>. /// For more information, please visit https://loopring.org. contract LRCLongTermHoldingContract { using SafeMath for uint; using Math for uint; // During the first 60 days of deployment, this contract opens for deposit of LRC. uint public constant DEPOSIT_PERIOD = 60 days; // = 2 months // 18 months after deposit, user can withdrawal all or part of his/her LRC with bonus. // The bonus is this contract's initial LRC balance. uint public constant WITHDRAWAL_DELAY = 540 days; // = 1 year and 6 months // Send 0.001ETH per 10000 LRC partial withdrawal, or 0 for a once-for-all withdrawal. // All ETH will be returned. uint public constant WITHDRAWAL_SCALE = 1E7; // 1ETH for withdrawal of 10,000,000 LRC. // Ower can drain all remaining LRC after 3 years. uint public constant DRAIN_DELAY = 1080 days; // = 3 years. address public lrcTokenAddress = 0x0; address public owner = 0x0; uint public lrcDeposited = 0; uint public depositStartTime = 0; uint public depositStopTime = 0; struct Record { uint lrcAmount; uint timestamp; } mapping (address => Record) records; /* * EVENTS */ /// Emitted when program starts. event Started(uint _time); /// Emitted when all LRC are drained. event Drained(uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public depositId = 0; event Deposit(uint _depositId, address indexed _addr, uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public withdrawId = 0; event Withdrawal(uint _withdrawId, address indexed _addr, uint _lrcAmount); /// @dev Initialize the contract /// @param _lrcTokenAddress LRC ERC20 token address function LRCLongTermHoldingContract(address _lrcTokenAddress, address _owner) { } /* * PUBLIC FUNCTIONS */ /// @dev start the program. function start() public { } /// @dev drain LRC. function drain() public { } function () payable { } /// @return Current LRC balance. function lrcBalance() public constant returns (uint) { } /// @dev Deposit LRC. function depositLRC() payable { require(depositStartTime > 0); require(msg.value == 0); require(now >= depositStartTime && now <= depositStopTime); var lrcToken = Token(lrcTokenAddress); uint lrcAmount = lrcToken .balanceOf(msg.sender) .min256(lrcToken.allowance(msg.sender, address(this))); require(lrcAmount > 0); var record = records[msg.sender]; record.lrcAmount += lrcAmount; record.timestamp = now; records[msg.sender] = record; lrcDeposited += lrcAmount; Deposit(depositId++, msg.sender, lrcAmount); require(<FILL_ME>) } /// @dev Withdrawal LRC. function withdrawLRC() payable { } function getBonus(uint _lrcWithdrawalBase) constant returns (uint) { } function internalCalculateBonus(uint _totalBonusRemaining, uint _lrcDeposited, uint _lrcWithdrawalBase) internal constant returns (uint) { } function sqrt(uint x) internal constant returns (uint) { } }
lrcToken.transferFrom(msg.sender,address(this),lrcAmount)
291,089
lrcToken.transferFrom(msg.sender,address(this),lrcAmount)
null
/* Copyright 2017 Loopring Project Ltd (Loopring Foundation). Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ pragma solidity ^0.4.11; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Math * @dev Assorted math operations */ library Math { function max64(uint64 a, uint64 b) internal constant returns (uint64) { } function min64(uint64 a, uint64 b) internal constant returns (uint64) { } function max256(uint256 a, uint256 b) internal constant returns (uint256) { } function min256(uint256 a, uint256 b) internal constant returns (uint256) { } } // Abstract contract for the full ERC 20 Token standard // https://github.com/ethereum/EIPs/issues/20 contract Token { /* This is a slight change to the ERC20 base standard. function totalSupply() constant returns (uint256 supply); is replaced with: uint256 public totalSupply; This automatically creates a getter function for the totalSupply. This is moved to the base contract since public getter functions are not currently recognised as an implementation of the matching abstract function by the compiler. */ /// total amount of tokens uint256 public totalSupply; /// @param _owner The address from which the balance will be retrieved /// @return The balance function balanceOf(address _owner) constant returns (uint256 balance); /// @notice send `_value` token to `_to` from `msg.sender` /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transfer(address _to, uint256 _value) returns (bool success); /// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from` /// @param _from The address of the sender /// @param _to The address of the recipient /// @param _value The amount of token to be transferred /// @return Whether the transfer was successful or not function transferFrom(address _from, address _to, uint256 _value) returns (bool success); /// @notice `msg.sender` approves `_spender` to spend `_value` tokens /// @param _spender The address of the account able to transfer the tokens /// @param _value The amount of tokens to be approved for transfer /// @return Whether the approval was successful or not function approve(address _spender, uint256 _value) returns (bool success); /// @param _owner The address of the account owning tokens /// @param _spender The address of the account able to transfer the tokens /// @return Amount of remaining tokens allowed to spent function allowance(address _owner, address _spender) constant returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /// @title Long-Team Holding Incentive Program /// @author Daniel Wang - <[email protected]>, Kongliang Zhong - <[email protected]>. /// For more information, please visit https://loopring.org. contract LRCLongTermHoldingContract { using SafeMath for uint; using Math for uint; // During the first 60 days of deployment, this contract opens for deposit of LRC. uint public constant DEPOSIT_PERIOD = 60 days; // = 2 months // 18 months after deposit, user can withdrawal all or part of his/her LRC with bonus. // The bonus is this contract's initial LRC balance. uint public constant WITHDRAWAL_DELAY = 540 days; // = 1 year and 6 months // Send 0.001ETH per 10000 LRC partial withdrawal, or 0 for a once-for-all withdrawal. // All ETH will be returned. uint public constant WITHDRAWAL_SCALE = 1E7; // 1ETH for withdrawal of 10,000,000 LRC. // Ower can drain all remaining LRC after 3 years. uint public constant DRAIN_DELAY = 1080 days; // = 3 years. address public lrcTokenAddress = 0x0; address public owner = 0x0; uint public lrcDeposited = 0; uint public depositStartTime = 0; uint public depositStopTime = 0; struct Record { uint lrcAmount; uint timestamp; } mapping (address => Record) records; /* * EVENTS */ /// Emitted when program starts. event Started(uint _time); /// Emitted when all LRC are drained. event Drained(uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public depositId = 0; event Deposit(uint _depositId, address indexed _addr, uint _lrcAmount); /// Emitted for each sucuessful deposit. uint public withdrawId = 0; event Withdrawal(uint _withdrawId, address indexed _addr, uint _lrcAmount); /// @dev Initialize the contract /// @param _lrcTokenAddress LRC ERC20 token address function LRCLongTermHoldingContract(address _lrcTokenAddress, address _owner) { } /* * PUBLIC FUNCTIONS */ /// @dev start the program. function start() public { } /// @dev drain LRC. function drain() public { } function () payable { } /// @return Current LRC balance. function lrcBalance() public constant returns (uint) { } /// @dev Deposit LRC. function depositLRC() payable { } /// @dev Withdrawal LRC. function withdrawLRC() payable { require(depositStartTime > 0); require(lrcDeposited > 0); var record = records[msg.sender]; require(now >= record.timestamp + WITHDRAWAL_DELAY); require(record.lrcAmount > 0); uint lrcWithdrawalBase = record.lrcAmount; if (msg.value > 0) { lrcWithdrawalBase = lrcWithdrawalBase .min256(msg.value.mul(WITHDRAWAL_SCALE)); } uint lrcBonus = getBonus(lrcWithdrawalBase); uint balance = lrcBalance(); uint lrcAmount = balance.min256(lrcWithdrawalBase + lrcBonus); lrcDeposited -= lrcWithdrawalBase; record.lrcAmount -= lrcWithdrawalBase; if (record.lrcAmount == 0) { delete records[msg.sender]; } else { records[msg.sender] = record; } Withdrawal(withdrawId++, msg.sender, lrcAmount); require(<FILL_ME>) if (msg.value > 0) { msg.sender.transfer(msg.value); } } function getBonus(uint _lrcWithdrawalBase) constant returns (uint) { } function internalCalculateBonus(uint _totalBonusRemaining, uint _lrcDeposited, uint _lrcWithdrawalBase) internal constant returns (uint) { } function sqrt(uint x) internal constant returns (uint) { } }
Token(lrcTokenAddress).transfer(msg.sender,lrcAmount)
291,089
Token(lrcTokenAddress).transfer(msg.sender,lrcAmount)
'Strategy.newBPool: already initialised'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { require(msg.sender == address(controller), 'Strategy.newBPool: !controller'); require(<FILL_ME>) bPool = IBPool(IBFactory(bFactory).newBPool()); } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
address(bPool)==address(0),'Strategy.newBPool: already initialised'
291,097
address(bPool)==address(0)
'Strategy.init: not newBPool'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { require(msg.sender == address(controller), 'Strategy.init: !controller'); require(<FILL_ME>) require(totalSupply() == 0, 'Strategy.init: already initialised'); (,address _vaultToken) = vaultInfo(); uint256 amountIn=pullToken(_vaultToken); swapToWeth(_vaultToken,amountIn); for (uint256 i = 0; i < tokens.length; i++) { swapToToken(tokens[i],amounts[i]); //Approve the balancer pool IERC20(tokens[i]).safeApprove(address(bPool), uint256(-1)); // Bind tokens bPool.bind(tokens[i], amounts[i], weights[i]); } clearToken(msg.sender,_vaultToken); _mint(address(this), INIT_NUM_VALUE); } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
address(bPool)!=address(0),'Strategy.init: not newBPool'
291,097
address(bPool)!=address(0)
'Strategy.bind: the token is bound'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { require(msg.sender == address(controller), 'Strategy.bind: !controller'); require(address(bPool) != address(0), 'Strategy.bind: not initialised'); require(<FILL_ME>) (address _vault,address _vaultToken) = vaultInfo(); uint256 amountIn= pullToken(_vaultToken); swapToWeth(_vaultToken,amountIn); swapToToken(_token,_amount); IERC20 token=IERC20(_token); //Approve the balancer pool if(token.allowance(address(this),address(bPool))>0){ token.safeApprove(address(bPool), uint256(0)); } token.safeApprove(address(bPool), uint256(-1)); // Bind tokens bPool.bind(_token, _amount, _weight); syncTokens(); clearToken(_vault,_vaultToken); } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
!bPool.isBound(_token),'Strategy.bind: the token is bound'
291,097
!bPool.isBound(_token)
'Strategy.bind: the token is bound'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { require(msg.sender == address(controller), 'Strategy.rebind: !controller'); require(address(bPool) != address(0), 'Strategy.rebind: not initialised'); require(<FILL_ME>) (address _vault,address _vaultToken) = vaultInfo(); uint256 amountIn= pullToken(_vaultToken); swapToWeth(_vaultToken,amountIn); swapToToken(_token,_amount); IERC20 token = IERC20(_token); bPool.gulp(_token); uint256 oldBalance = token.balanceOf(address(bPool)); if (_amount > oldBalance) { swapToToken(_token,_amount.sub(oldBalance)); if(token.allowance(address(this),address(bPool))>0){ token.safeApprove(address(bPool), uint256(0)); } token.safeApprove(address(bPool), uint256(-1)); } bPool.rebind(_token, _amount, _weight); syncTokens(); amountIn = token.balanceOf(address(this)); swapToWeth(_token, amountIn); clearToken(_vault,_vaultToken); } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
bPool.isBound(_token),'Strategy.bind: the token is bound'
291,097
bPool.isBound(_token)
'Strategy.deposit: Insufficient balance'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { require(msg.sender == address(controller), 'Strategy.deposit: !controller'); (address _vault,address _vaultToken) = vaultInfo(); require(_amount > 0, 'Strategy.deposit: token balance is zero'); IERC20 tokenContract = IERC20(_vaultToken); require(<FILL_ME>) tokenContract.safeTransferFrom(msg.sender, address(this), _amount); uint256 hasWethTotal = swapToWeth(_vaultToken,_amount); (uint256 oneShareWethAmount,uint256[] memory oneShareAmounts) = calcOneShareAmount(0); uint256 preShareCount = hasWethTotal.div(oneShareWethAmount); require(preShareCount > 0, 'Strategy.deposit: Must be greater than 0 amount by pre share Count '); for (uint256 i = 0; i < tokens.length; i++) { uint256 amountOut = oneShareAmounts[i].mul(preShareCount); swapToToken(tokens[i], amountOut); uint256 tbal = IERC20(tokens[i]).balanceOf(address(bPool)); bPool.rebind(tokens[i], tbal.add(amountOut), weights[i]); } _mint(address(this), preShareCount.mul(1e18)); clearToken(_vault,_vaultToken); } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
tokenContract.balanceOf(msg.sender)>=_amount,'Strategy.deposit: Insufficient balance'
291,097
tokenContract.balanceOf(msg.sender)>=_amount
'Strategy.withdraw: Must be greater than the number of initializations'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { require(msg.sender == address(controller), 'Strategy.withdraw: !controller'); require(_amount > 0, 'Strategy.withdraw: Must be greater than 0 amount'); require(_amount <= available(), 'Strategy.withdraw: Must be less than assets'); (address _vault,address _vaultToken) = vaultInfo(); uint256 needWeth = _amount; if (WETH != _vaultToken) { needWeth = UniswapV2ExpandLibrary.getAmountIn(WETH, _vaultToken, _amount); } (uint256 oneShareWethAmount,uint256[] memory oneShareAmounts) = calcOneShareAmount(1); uint256 preShareCount = needWeth.div(oneShareWethAmount); uint256 burnAmount=preShareCount.mul(1e18); require(<FILL_ME>) for (uint256 i = 0; i < tokens.length; i++) { uint256 amountIn = oneShareAmounts[i].mul(preShareCount); uint256 tbal = IERC20(tokens[i]).balanceOf(address(bPool)); bPool.rebind(tokens[i], tbal.sub(amountIn), weights[i]); swapToWeth(tokens[i], amountIn); } _burn(address(this), burnAmount); clearToken(_vault,_vaultToken); } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
totalSupply().sub(burnAmount)>=INIT_NUM_VALUE,'Strategy.withdraw: Must be greater than the number of initializations'
291,097
totalSupply().sub(burnAmount)>=INIT_NUM_VALUE
'Strategy.withdrawAll: Must be greater than the number of initializations'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { require(msg.sender == address(controller), 'Strategy.withdrawAll: !controller'); require(<FILL_ME>) for (uint256 i = 0; i < tokens.length; i++) { uint256 amountOut = amounts[i]; IERC20 token=IERC20(tokens[i]); require(token.balanceOf(address(bPool))>=amountOut,'Strategy.withdrawAll: token balance < amountOut'); bPool.rebind(tokens[i],amountOut,bPool.getDenormalizedWeight(tokens[i])); uint256 amountIn = token.balanceOf(address(this)); swapToWeth(tokens[i], amountIn); } _burn(address(this), totalSupply().sub(INIT_NUM_VALUE)); (address _vault,address _vaultToken) = vaultInfo(); clearToken(_vault,_vaultToken); } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
totalSupply()>INIT_NUM_VALUE,'Strategy.withdrawAll: Must be greater than the number of initializations'
291,097
totalSupply()>INIT_NUM_VALUE
'Strategy.withdrawAll: token balance < amountOut'
pragma solidity ^0.6.12; contract BalLiquidityStrategy is ERC20, GovIdentity { using SafeERC20 for IERC20; using Address for address; using ExpandMath for uint256; uint256 constant public INIT_NUM=1; uint256 constant public INIT_NUM_VALUE=INIT_NUM*(1e18); uint256[] public weights; uint256[] public amounts; address[] public tokens; IController public controller; IBPool public bPool; address constant public WETH = address(0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2); address constant public bFactory = address(0x9424B1412450D0f8Fc2255FAf6046b98213B76Bd); constructor( address _controller, address[] memory _tokens, uint256[] memory _weights, uint256[] memory _amounts) public ERC20('Share Token', 'ST'){ } function getTokens()public view returns(address[] memory){ } function getWeights()public view returns(uint256[] memory){ } function pullToken(address _token)internal returns(uint256 amount){ } function clearToken(address to,address _token) internal { } function swapToWeth(address _token, uint256 amountIn) internal returns(uint256 amountOut){ } function swapToToken(address _token, uint256 amountOut) internal returns(uint256 amountIn){ } function syncTokens()internal{ } function vaultInfo() internal view returns (address, address){ } function calcOneShareAmount(uint256 direction) internal view returns (uint256 oneShareWethAmount, uint256[] memory oneShareAmounts){ } function newBPool()external { } function init() external { } function approveTokens() public { } function bind(address _token, uint256 _amount, uint256 _weight) external { } function rebind(address _token, uint256 _amount, uint256 _weight) external { } function unbind(address _token) external { } function deposit(uint256 _amount) external { } function withdraw(uint256 _amount) external { } function withdraw(address _token) external returns (uint256 balance){ } function withdrawAll() external { require(msg.sender == address(controller), 'Strategy.withdrawAll: !controller'); require(totalSupply() > INIT_NUM_VALUE, 'Strategy.withdrawAll: Must be greater than the number of initializations'); for (uint256 i = 0; i < tokens.length; i++) { uint256 amountOut = amounts[i]; IERC20 token=IERC20(tokens[i]); require(<FILL_ME>) bPool.rebind(tokens[i],amountOut,bPool.getDenormalizedWeight(tokens[i])); uint256 amountIn = token.balanceOf(address(this)); swapToWeth(tokens[i], amountIn); } _burn(address(this), totalSupply().sub(INIT_NUM_VALUE)); (address _vault,address _vaultToken) = vaultInfo(); clearToken(_vault,_vaultToken); } function assets() public view returns (uint256){ } function available() public view returns (uint256){ } }
token.balanceOf(address(bPool))>=amountOut,'Strategy.withdrawAll: token balance < amountOut'
291,097
token.balanceOf(address(bPool))>=amountOut
null
pragma solidity ^0.4.23; contract BaseERC20Token { mapping (address => uint256) public balanceOf; string public name; string public symbol; uint8 public decimals; uint256 public totalSupply; event Transfer(address indexed from, address indexed to, uint256 value); constructor ( uint256 _totalSupply, uint8 _decimals, string _name, string _symbol ) public { } function transfer(address to, uint256 value) public returns (bool success) { } event Approval(address indexed owner, address indexed spender, uint256 value); mapping(address => mapping(address => uint256)) public allowance; function approve(address spender, uint256 value) public returns (bool success) { } function transferFrom(address from, address to, uint256 value) public returns (bool success) { } } contract MintableToken is BaseERC20Token { address public owner = msg.sender; constructor( uint256 _totalSupply, uint8 _decimals, string _name, string _symbol ) BaseERC20Token(_totalSupply, _decimals, _name, _symbol) public { } function mint(address recipient, uint256 amount) public { require(msg.sender == owner); require(<FILL_ME>) // Overflow check totalSupply += amount; balanceOf[recipient] += amount; emit Transfer(address(0), recipient, amount); } function burn(uint256 amount) public { } function burnFrom(address from, uint256 amount) public { } }
totalSupply+amount>=totalSupply
291,117
totalSupply+amount>=totalSupply
"Purchase would exceed max supply of zales"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { require(saleIsActive, "Sale must be active to mint zale"); require(numberOfTokens > 0 && numberOfTokens <= maxzalePurchase, "Can only mint 258 tokens at a time"); require(<FILL_ME>) require(msg.value >= zalePrice.mul(numberOfTokens), "Ether value sent is not correct"); for (uint i = 0; i < numberOfTokens; i++) { uint mintIndex = totalSupply(); if (totalSupply() < MAX_zaleS) { _safeMint(msg.sender, mintIndex); } } } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
totalSupply().add(numberOfTokens)<=MAX_zaleS,"Purchase would exceed max supply of zales"
291,120
totalSupply().add(numberOfTokens)<=MAX_zaleS
"New name is same as the current one"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { require(ownerOf(_tokenId) == msg.sender, "Hey, your wallet doesn't own this zale!"); require(<FILL_ME>) zaleNames[_tokenId] = _name; emit zaleNameChange(msg.sender, _tokenId, _name); } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
sha256(bytes(_name))!=sha256(bytes(zaleNames[_tokenId])),"New name is same as the current one"
291,120
sha256(bytes(_name))!=sha256(bytes(zaleNames[_tokenId]))
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(address(this).balance >= reward2, "Not enough to payout"); return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(address(this).balance >= reward3, "Not enough to payout"); return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(address(this).balance >= reward4, "Not enough to payout"); return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(address(this).balance >= reward5, "Not enough to payout"); return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(address(this).balance >= reward6, "Not enough to payout"); return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward1,"Not enough to payout"
291,120
address(this).balance>=reward1
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(address(this).balance >= reward1, "Not enough to payout"); return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(address(this).balance >= reward3, "Not enough to payout"); return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(address(this).balance >= reward4, "Not enough to payout"); return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(address(this).balance >= reward5, "Not enough to payout"); return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(address(this).balance >= reward6, "Not enough to payout"); return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward2,"Not enough to payout"
291,120
address(this).balance>=reward2
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(address(this).balance >= reward1, "Not enough to payout"); return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(address(this).balance >= reward2, "Not enough to payout"); return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(address(this).balance >= reward4, "Not enough to payout"); return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(address(this).balance >= reward5, "Not enough to payout"); return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(address(this).balance >= reward6, "Not enough to payout"); return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward3,"Not enough to payout"
291,120
address(this).balance>=reward3
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(address(this).balance >= reward1, "Not enough to payout"); return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(address(this).balance >= reward2, "Not enough to payout"); return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(address(this).balance >= reward3, "Not enough to payout"); return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(address(this).balance >= reward5, "Not enough to payout"); return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(address(this).balance >= reward6, "Not enough to payout"); return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward4,"Not enough to payout"
291,120
address(this).balance>=reward4
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(address(this).balance >= reward1, "Not enough to payout"); return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(address(this).balance >= reward2, "Not enough to payout"); return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(address(this).balance >= reward3, "Not enough to payout"); return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(address(this).balance >= reward4, "Not enough to payout"); return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(address(this).balance >= reward6, "Not enough to payout"); return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward5,"Not enough to payout"
291,120
address(this).balance>=reward5
"Not enough to payout"
pragma solidity >=0.6.0 <0.8.0; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { } } /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor () internal { } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { } } pragma solidity 0.7.6; pragma experimental ABIEncoderV2; contract Zalesi is ERC721, ERC721Burnable, Ownable { using SafeMath for uint256; string public zale_PROVENANCE = ""; // IPFS URL WILL BE ADDED WHEN zaleS ARE ALL SOLD OUT string public LICENSE_TEXT = ""; // IT IS WHAT IT SAYS bool licenseLocked = false; // TEAM CAN'T EDIT THE LICENSE AFTER THIS GETS TRUE uint256 public zalePrice = 60000000000000000; // 0.01 ETH uint public constant maxzalePurchase = 9999; uint256 public MAX_zaleS = 9999; bool public saleIsActive = false; mapping(uint => string) public zaleNames; // Reserve 200 for team - Giveaways/Prizes etc uint public zaleReserve = 200; mapping(uint => uint) public readyTime; uint8[] score = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; uint public reward1 = 1000000000000000000; uint public reward2 = 400000000000000000; uint public reward3 = 300000000000000000; uint public reward4 = 130000000000000000; uint public reward5 = 100000000000000000; uint public reward6 = 80000000000000000; bool public _isActive = false; event zaleNameChange(address _by, uint _tokenId, string _name); event licenseisLocked(string _licenseText); constructor() ERC721("Zales I", "ZaleI") {} function reservezales(address _to, uint256 _reserveAmount) public onlyOwner { } function setProvenanceHash(string memory provenanceHash) public onlyOwner { } function setBaseURI(string memory baseURI) public onlyOwner { } function flipSaleState() public onlyOwner { } function tokensOfOwner(address _owner) external view returns(uint256[] memory) { } // Returns the license for tokens function tokenLicense(uint _id) public view returns(string memory) { } // Locks the license to prevent further changes function lockLicense() public onlyOwner { } // Change the license function changeLicense(string memory _license) public onlyOwner { } function mintzales(uint numberOfTokens) public payable { } function changezaleName(uint _tokenId, string memory _name) public { } function viewzaleName(uint _tokenId) public view returns(string memory) { } // GET ALL zale OF A WALLET AS AN ARRAY OF STRINGS. WOULD BE BETTER MAYBE IF IT RETURNED A STRUCT WITH ID-NAME MATCH function zaleNamesOfOwner(address _owner) external view returns(string[] memory) { } function getReward(uint[] memory tokenIds) external { } function getCombo(address _owner, uint8[] memory combo) private { require(address(this).balance > 0, "Empty balance"); if (combo[0] == 1 && combo[1] == 1 && combo[2] == 1 && combo[3] == 1 && combo[4] == 1 && combo[5] == 1 && combo[6] == 1 && combo[7] == 1 && combo[8] == 1 && combo[9] == 1) { require(address(this).balance >= reward1, "Not enough to payout"); return _withdraw(_owner, reward1); } if (combo[0] == 1 && combo[1] == 1 && combo[3] == 1 && combo[5] == 1 && combo[7] == 1 && combo[9] == 1) { require(address(this).balance >= reward2, "Not enough to payout"); return _withdraw(_owner, reward2); } if (combo[0] == 1 && combo[2] == 1 && combo[4] == 1 && combo[6] == 1 && combo[8] == 1) { require(address(this).balance >= reward3, "Not enough to payout"); return _withdraw(_owner, reward3); } if (combo[0] == 1 && combo[2] == 1 && combo[5] == 1 && combo[8] == 1) { require(address(this).balance >= reward4, "Not enough to payout"); return _withdraw(_owner, reward4); } if (combo[1] == 1 && combo[4] == 1 && combo[7] == 1) { require(address(this).balance >= reward5, "Not enough to payout"); return _withdraw(_owner, reward5); } if (combo[0] == 1 && combo[3] == 1 && combo[6] == 1) { require(<FILL_ME>) return _withdraw(_owner, reward6); } } function getScore(uint tokenId) internal pure returns (uint s) { } function setMaxZales(uint maxzale) external onlyOwner { } function isRewardActive(bool active) external onlyOwner { } function setReward1(uint amount) external onlyOwner { } function setReward2(uint amount) external onlyOwner { } function setReward3(uint amount) external onlyOwner { } function setReward4(uint amount) external onlyOwner { } function setReward5(uint amount) external onlyOwner { } function setReward6(uint amount) external onlyOwner { } function setMintPrice(uint price) external onlyOwner { } function resetWithdrawDate() external onlyOwner { } function _setNextWithdrawDate(uint tokenId) internal { } function resetTokenWithdrawDate(uint tokenId, uint timestamp) external onlyOwner { } function canWithdraw(uint tokenId) public view returns (bool) { } function withdraw(uint amount) external onlyOwner { } function _withdraw(address _address, uint256 _amount) private { } //Transfers ether to other contract function fund() public payable { } }
address(this).balance>=reward6,"Not enough to payout"
291,120
address(this).balance>=reward6
null
pragma solidity ^0.4.21; // SafeMath is a part of Zeppelin Solidity library // licensed under MIT License // https://github.com/OpenZeppelin/zeppelin-solidity/blob/master/LICENSE /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function add(uint256 a, uint256 b) internal pure returns (uint256) { } } // https://github.com/OpenZeppelin/zeppelin-solidity /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function totalSupply() public view returns (uint256); function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 totalSupply_; /** * @dev Protection from short address attack */ modifier onlyPayloadSize(uint size) { } /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256 balance) { } /** * @dev Hook for custom actions to be executed after transfer has completed * @param _from Transferred from * @param _to Transferred to * @param _value Value transferred */ function _postTransferHook(address _from, address _to, uint256 _value) internal; } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } contract Owned { address owner; modifier onlyOwner { } /// @dev Contract constructor function Owned() public { } } contract AcceptsTokens { ETToken public tokenContract; function AcceptsTokens(address _tokenContract) public { } modifier onlyTokenContract { } function acceptTokens(address _from, uint256 _value, uint256 param1, uint256 param2, uint256 param3) external; } contract ETToken is Owned, StandardToken { using SafeMath for uint; string public name = "ETH.TOWN Token"; string public symbol = "ETIT"; uint8 public decimals = 18; address public beneficiary; address public oracle; address public heroContract; modifier onlyOracle { } mapping (uint32 => address) public floorContracts; mapping (address => bool) public canAcceptTokens; mapping (address => bool) public isMinter; modifier onlyMinters { } event Dividend(uint256 value); event Withdrawal(address indexed to, uint256 value); event Burn(address indexed from, uint256 value); function ETToken() public { } function setOracle(address _oracle) external onlyOwner { } function setBeneficiary(address _beneficiary) external onlyOwner { } function setHeroContract(address _heroContract) external onlyOwner { } function _mintTokens(address _user, uint256 _amount) private { } function authorizeFloor(uint32 _index, address _floorContract) external onlyOwner { } function _acceptDividends(uint256 _value) internal { } function acceptDividends(uint256 _value, uint32 _floorIndex) external { require(<FILL_ME>) _acceptDividends(_value); } function rewardTokensFloor(address _user, uint256 _tokens, uint32 _floorIndex) external { } function rewardTokens(address _user, uint256 _tokens) external onlyMinters { } function() payable public { } function payoutDividends(address _user, uint256 _value) external onlyOracle { } function accountAuth(uint256 /*_challenge*/) external { } function burn(uint256 _amount) external { } function setCanAcceptTokens(address _address, bool _value) external onlyOwner { } function setIsMinter(address _address, bool _value) external onlyOwner { } function _invokeTokenRecipient(address _from, address _to, uint256 _value, uint256 _param1, uint256 _param2, uint256 _param3) internal { } /** * @dev transfer token for a specified address and forward the parameters to token recipient if any * @param _to The address to transfer to. * @param _value The amount to be transferred. * @param _param1 Parameter 1 for the token recipient * @param _param2 Parameter 2 for the token recipient * @param _param3 Parameter 3 for the token recipient */ function transferWithParams(address _to, uint256 _value, uint256 _param1, uint256 _param2, uint256 _param3) onlyPayloadSize(5 * 32) external returns (bool) { } /** * @dev Hook for custom actions to be executed after transfer has completed * @param _from Transferred from * @param _to Transferred to * @param _value Value transferred */ function _postTransferHook(address _from, address _to, uint256 _value) internal { } } contract PresaleContract is Owned { ETToken public tokenContract; /// @dev Contract constructor function PresaleContract(address _tokenContract) public { } } contract ETCharPresale_v2 is PresaleContract { using SafeMath for uint; bool public enabled = true; uint32 public maxCharId = 10000; uint32 public currentCharId = 2000; uint256 public currentPrice = 0.02 ether; mapping (uint32 => address) public owners; mapping (address => uint32[]) public characters; bool public awardTokens = true; event Purchase(address from, uint32 charId, uint256 amount); function ETCharPresale_v2(address _presaleToken) PresaleContract(_presaleToken) public { } function _isContract(address _user) internal view returns (bool) { } function _provideChars(address _address, uint32 _number) internal { } function priceIncrease() public view returns (uint256) { } function() public payable { } function setEnabled(bool _enabled) public onlyOwner { } function setMaxCharId(uint32 _maxCharId) public onlyOwner { } function setCurrentPrice(uint256 _currentPrice) public onlyOwner { } function setAwardTokens(bool _awardTokens) public onlyOwner { } function withdraw() public onlyOwner { } function charactersOf(address _user) public view returns (uint32[]) { } function charactersCountOf(address _user) public view returns (uint256) { } function getCharacter(address _user, uint256 _index) public view returns (uint32) { } }
floorContracts[_floorIndex]==msg.sender
291,122
floorContracts[_floorIndex]==msg.sender
null
pragma solidity ^0.4.21; // SafeMath is a part of Zeppelin Solidity library // licensed under MIT License // https://github.com/OpenZeppelin/zeppelin-solidity/blob/master/LICENSE /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function add(uint256 a, uint256 b) internal pure returns (uint256) { } } // https://github.com/OpenZeppelin/zeppelin-solidity /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function totalSupply() public view returns (uint256); function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 totalSupply_; /** * @dev Protection from short address attack */ modifier onlyPayloadSize(uint size) { } /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256 balance) { } /** * @dev Hook for custom actions to be executed after transfer has completed * @param _from Transferred from * @param _to Transferred to * @param _value Value transferred */ function _postTransferHook(address _from, address _to, uint256 _value) internal; } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } contract Owned { address owner; modifier onlyOwner { } /// @dev Contract constructor function Owned() public { } } contract AcceptsTokens { ETToken public tokenContract; function AcceptsTokens(address _tokenContract) public { } modifier onlyTokenContract { } function acceptTokens(address _from, uint256 _value, uint256 param1, uint256 param2, uint256 param3) external; } contract ETToken is Owned, StandardToken { using SafeMath for uint; string public name = "ETH.TOWN Token"; string public symbol = "ETIT"; uint8 public decimals = 18; address public beneficiary; address public oracle; address public heroContract; modifier onlyOracle { } mapping (uint32 => address) public floorContracts; mapping (address => bool) public canAcceptTokens; mapping (address => bool) public isMinter; modifier onlyMinters { } event Dividend(uint256 value); event Withdrawal(address indexed to, uint256 value); event Burn(address indexed from, uint256 value); function ETToken() public { } function setOracle(address _oracle) external onlyOwner { } function setBeneficiary(address _beneficiary) external onlyOwner { } function setHeroContract(address _heroContract) external onlyOwner { } function _mintTokens(address _user, uint256 _amount) private { } function authorizeFloor(uint32 _index, address _floorContract) external onlyOwner { } function _acceptDividends(uint256 _value) internal { } function acceptDividends(uint256 _value, uint32 _floorIndex) external { } function rewardTokensFloor(address _user, uint256 _tokens, uint32 _floorIndex) external { } function rewardTokens(address _user, uint256 _tokens) external onlyMinters { } function() payable public { } function payoutDividends(address _user, uint256 _value) external onlyOracle { } function accountAuth(uint256 /*_challenge*/) external { } function burn(uint256 _amount) external { } function setCanAcceptTokens(address _address, bool _value) external onlyOwner { } function setIsMinter(address _address, bool _value) external onlyOwner { } function _invokeTokenRecipient(address _from, address _to, uint256 _value, uint256 _param1, uint256 _param2, uint256 _param3) internal { } /** * @dev transfer token for a specified address and forward the parameters to token recipient if any * @param _to The address to transfer to. * @param _value The amount to be transferred. * @param _param1 Parameter 1 for the token recipient * @param _param2 Parameter 2 for the token recipient * @param _param3 Parameter 3 for the token recipient */ function transferWithParams(address _to, uint256 _value, uint256 _param1, uint256 _param2, uint256 _param3) onlyPayloadSize(5 * 32) external returns (bool) { } /** * @dev Hook for custom actions to be executed after transfer has completed * @param _from Transferred from * @param _to Transferred to * @param _value Value transferred */ function _postTransferHook(address _from, address _to, uint256 _value) internal { } } contract PresaleContract is Owned { ETToken public tokenContract; /// @dev Contract constructor function PresaleContract(address _tokenContract) public { } } contract ETCharPresale_v2 is PresaleContract { using SafeMath for uint; bool public enabled = true; uint32 public maxCharId = 10000; uint32 public currentCharId = 2000; uint256 public currentPrice = 0.02 ether; mapping (uint32 => address) public owners; mapping (address => uint32[]) public characters; bool public awardTokens = true; event Purchase(address from, uint32 charId, uint256 amount); function ETCharPresale_v2(address _presaleToken) PresaleContract(_presaleToken) public { } function _isContract(address _user) internal view returns (bool) { } function _provideChars(address _address, uint32 _number) internal { } function priceIncrease() public view returns (uint256) { } function() public payable { require(enabled); require(!_isContract(msg.sender)); require(msg.value >= currentPrice); uint32 chars = uint32(msg.value.div(currentPrice)); require(chars <= 100); if (chars > 50) { chars = 50; } require(<FILL_ME>) uint256 purchaseValue = currentPrice.mul(chars); uint256 change = msg.value.sub(purchaseValue); _provideChars(msg.sender, chars); if (awardTokens) { tokenContract.rewardTokens(msg.sender, purchaseValue * 200); } if (currentCharId > maxCharId) { enabled = false; } if (change > 0) { msg.sender.transfer(change); } } function setEnabled(bool _enabled) public onlyOwner { } function setMaxCharId(uint32 _maxCharId) public onlyOwner { } function setCurrentPrice(uint256 _currentPrice) public onlyOwner { } function setAwardTokens(bool _awardTokens) public onlyOwner { } function withdraw() public onlyOwner { } function charactersOf(address _user) public view returns (uint32[]) { } function charactersCountOf(address _user) public view returns (uint256) { } function getCharacter(address _user, uint256 _index) public view returns (uint32) { } }
currentCharId+chars-1<=maxCharId
291,122
currentCharId+chars-1<=maxCharId
"Mining is over"
//SPDX-License-Identifier: MIT /// @title JPEG Mining /// @author Xatarrer /// @notice Unaudited pragma solidity ^0.8.4; import "./ERC721Enumerable.sol"; import "./SSTORE2.sol"; import "./Ownable.sol"; import "./IERC20.sol"; import "./Strings.sol"; import "./SafeMath.sol"; /** @dev Return data URL: https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs https://en.wikipedia.org/wiki/Data_URI_scheme @dev Base64 encoding/decoding available at https://github.com/Brechtpd/base64/blob/main/base64.sol @dev Large efficient immutable storage: https://github.com/0xsequence/sstore2/blob/master/contracts/SSTORE2.sol */ contract JPEGminer is ERC721Enumerable, Ownable { using SafeMath for uint256; event Mined(address minerAddress, string indexed phase); uint256 public constant NSCANS = 100; string private constant _NAME = "Mined JPEG"; string private constant _SYMBOL = "MJ"; string private constant _DESCRIPTION = "JPEG Mining is a collaborative effort to store %2a%2athe largest on-chain image%2a%2a %281.5MB in Base64 format %26 1.1MB in binary%29. " "The image is split into 100 pieces which are uploaded by every wallet that calls the function mine%28%29. " "Thanks to the %2a%2aprogressive JPEG%2a%2a technology the image is viewable since its first piece is mined, " "and its quality gradually improves until the last piece is mined. %5Cr %5Cr" "As the image's quality improves over each successive mining, it goes through 3 different clear phases%3A %5Cr" "1. image is %2a%2black & white%2a%2 only, %5Cr2. %2a%2color%2a%2 is added, and %5Cr3. %2a%2resolution%2a%2 improves until the final version. %5Cr" "The B&W phase is the shortest and only lasts 11 uploads, " "the color phase last 22 uploads, and the resolution phase is the longest with 67 uploads. %5Cr %5Cr" "Every JPEG miner gets an NFT of the image with the quality at the time of minting. %5Cr %5Cr" "Art by Logan Turner. Idea and code by Xatarrer."; // Replace the hashes before deployment address private immutable _mintingGasFeesPointer; address private immutable _imageHashesPointer; address private immutable _imageHeaderPointer; address[] private _imageScansPointers; string private constant _imageFooterB64 = "/9k="; constructor( string memory imageHeaderB64, bytes32[] memory imageHashes, uint256[] memory mintingGasFees ) ERC721(_NAME, _SYMBOL) { } /// @return JSON with properties function tokenURI(uint256 tokenId) public view override returns (string memory) { } function mergeScans( uint256 tokenId, string memory preImage, string memory posImage, string memory lastText ) private view returns (string memory) { } function getPhase(uint256 tokenId) public pure returns (string memory) { } function getMintingGasFee(uint256 tokenId) public view returns (uint256) { } function getHash(uint256 tokenId) public view returns (bytes32) { } /// @param imageScanB64 Piece of image data in base64 function mine(string calldata imageScanB64) external payable { // Checks require(msg.sender == tx.origin, "Only EA's can mine"); require(balanceOf(msg.sender) == 0, "Cannot mine more than once"); require(<FILL_ME>) // Check gas minting fee uint256 mintingFee = tx.gasprice.mul(getMintingGasFee(totalSupply())); require(msg.value >= mintingFee, "ETH fee insufficient"); // Check hash matches require(keccak256(bytes(imageScanB64)) == getHash(totalSupply()), "Wrong data"); // SSTORE2 scan _imageScansPointers[totalSupply()] = SSTORE2.write(bytes(imageScanB64)); // Return change payable(msg.sender).transfer(msg.value - mintingFee); // Mint scan uint256 tokenId = totalSupply(); _mint(msg.sender, tokenId); emit Mined(msg.sender, getPhase(tokenId)); } function withdrawEth() external onlyOwner { } function withdrawToken(address addrERC20) external onlyOwner { } }
totalSupply()<NSCANS,"Mining is over"
291,228
totalSupply()<NSCANS
"Wrong data"
//SPDX-License-Identifier: MIT /// @title JPEG Mining /// @author Xatarrer /// @notice Unaudited pragma solidity ^0.8.4; import "./ERC721Enumerable.sol"; import "./SSTORE2.sol"; import "./Ownable.sol"; import "./IERC20.sol"; import "./Strings.sol"; import "./SafeMath.sol"; /** @dev Return data URL: https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs https://en.wikipedia.org/wiki/Data_URI_scheme @dev Base64 encoding/decoding available at https://github.com/Brechtpd/base64/blob/main/base64.sol @dev Large efficient immutable storage: https://github.com/0xsequence/sstore2/blob/master/contracts/SSTORE2.sol */ contract JPEGminer is ERC721Enumerable, Ownable { using SafeMath for uint256; event Mined(address minerAddress, string indexed phase); uint256 public constant NSCANS = 100; string private constant _NAME = "Mined JPEG"; string private constant _SYMBOL = "MJ"; string private constant _DESCRIPTION = "JPEG Mining is a collaborative effort to store %2a%2athe largest on-chain image%2a%2a %281.5MB in Base64 format %26 1.1MB in binary%29. " "The image is split into 100 pieces which are uploaded by every wallet that calls the function mine%28%29. " "Thanks to the %2a%2aprogressive JPEG%2a%2a technology the image is viewable since its first piece is mined, " "and its quality gradually improves until the last piece is mined. %5Cr %5Cr" "As the image's quality improves over each successive mining, it goes through 3 different clear phases%3A %5Cr" "1. image is %2a%2black & white%2a%2 only, %5Cr2. %2a%2color%2a%2 is added, and %5Cr3. %2a%2resolution%2a%2 improves until the final version. %5Cr" "The B&W phase is the shortest and only lasts 11 uploads, " "the color phase last 22 uploads, and the resolution phase is the longest with 67 uploads. %5Cr %5Cr" "Every JPEG miner gets an NFT of the image with the quality at the time of minting. %5Cr %5Cr" "Art by Logan Turner. Idea and code by Xatarrer."; // Replace the hashes before deployment address private immutable _mintingGasFeesPointer; address private immutable _imageHashesPointer; address private immutable _imageHeaderPointer; address[] private _imageScansPointers; string private constant _imageFooterB64 = "/9k="; constructor( string memory imageHeaderB64, bytes32[] memory imageHashes, uint256[] memory mintingGasFees ) ERC721(_NAME, _SYMBOL) { } /// @return JSON with properties function tokenURI(uint256 tokenId) public view override returns (string memory) { } function mergeScans( uint256 tokenId, string memory preImage, string memory posImage, string memory lastText ) private view returns (string memory) { } function getPhase(uint256 tokenId) public pure returns (string memory) { } function getMintingGasFee(uint256 tokenId) public view returns (uint256) { } function getHash(uint256 tokenId) public view returns (bytes32) { } /// @param imageScanB64 Piece of image data in base64 function mine(string calldata imageScanB64) external payable { // Checks require(msg.sender == tx.origin, "Only EA's can mine"); require(balanceOf(msg.sender) == 0, "Cannot mine more than once"); require(totalSupply() < NSCANS, "Mining is over"); // Check gas minting fee uint256 mintingFee = tx.gasprice.mul(getMintingGasFee(totalSupply())); require(msg.value >= mintingFee, "ETH fee insufficient"); // Check hash matches require(<FILL_ME>) // SSTORE2 scan _imageScansPointers[totalSupply()] = SSTORE2.write(bytes(imageScanB64)); // Return change payable(msg.sender).transfer(msg.value - mintingFee); // Mint scan uint256 tokenId = totalSupply(); _mint(msg.sender, tokenId); emit Mined(msg.sender, getPhase(tokenId)); } function withdrawEth() external onlyOwner { } function withdrawToken(address addrERC20) external onlyOwner { } }
keccak256(bytes(imageScanB64))==getHash(totalSupply()),"Wrong data"
291,228
keccak256(bytes(imageScanB64))==getHash(totalSupply())
'GUMPAirdrop: Transfer failed.'
// SPDX-License-Identifier: MIT pragma solidity ^0.8.1; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; // Allows anyone to claim a token if they exist in a merkle root. interface IAirdropTokenDistributor { // Returns the address of the token distributed by this contract. function token() external view returns (address); // Returns the merkle root of the merkle tree containing account balances available to claim. function merkleRoot() external view returns (bytes32); // Returns true if the index has been marked claimed. function isClaimed(uint256 index) external view returns (bool); // Claim the given amount of the token to the given address. Reverts if the inputs are invalid. function claim(uint256 index, address account, uint256 amount, bytes32[] calldata merkleProof) external; // This event is triggered whenever a call to #claim succeeds. event Claimed(uint256 index, address account, uint256 amount); } contract GUMPAirdrop is IAirdropTokenDistributor, Ownable { address public immutable override token; bytes32 public immutable override merkleRoot; // This is a packed array of booleans. mapping(uint256 => uint256) private claimedBitMap; constructor(address token_) { } function isClaimed(uint256 index) public view override returns (bool) { } function _setClaimed(uint256 index) private { } function claim(uint256 index, address account, uint256 amount, bytes32[] calldata merkleProof) external override { } function returnAllToken() public onlyOwner { uint256 amount = IERC20(token).balanceOf(address(this)); require(<FILL_ME>) } }
IERC20(token).transfer(msg.sender,amount),'GUMPAirdrop: Transfer failed.'
291,240
IERC20(token).transfer(msg.sender,amount)
null
pragma solidity 0.4.23; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two numbers, truncating the quotient. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two numbers, throws on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function totalSupply() public view returns (uint256); function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 totalSupply_; /** * @dev total number of tokens in existence */ function totalSupply() public view returns (uint256) { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } } /** * @title Burnable Token * @dev Token that can be irreversibly burned (destroyed). */ contract BurnableToken is BasicToken { event Burn(address indexed burner, uint256 value); /** * @dev Burns a specific amount of tokens. * @param _value The amount of token to be burned. */ function burn(uint256 _value) public { } function _burn(address _who, uint256 _value) internal { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ constructor() public { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. * @param newOwner The address to transfer ownership to. */ function transferOwnership(address newOwner) public onlyOwner { } } /** * @title Claimable * @dev Extension for the Ownable contract, where the ownership needs to be claimed. * This allows the new owner to accept the transfer. */ contract Claimable is Ownable { address public pendingOwner; /** * @dev Modifier throws if called by any account other than the pendingOwner. */ modifier onlyPendingOwner() { } /** * @dev Allows the current owner to set the pendingOwner address. * @param newOwner The address to transfer ownership to. */ function transferOwnership(address newOwner) onlyOwner public { } /** * @dev Allows the pendingOwner address to finalize the transfer. */ function claimOwnership() onlyPendingOwner public { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is Ownable { event Pause(); event Unpause(); bool public paused = false; /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev called by the owner to pause, triggers stopped state */ function pause() onlyOwner whenNotPaused public { } /** * @dev called by the owner to unpause, returns to normal state */ function unpause() onlyOwner whenPaused public { } } contract PausableToken is StandardToken, BurnableToken, Claimable, Pausable { function transfer(address _to, uint256 _value) public whenNotPaused returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public whenNotPaused returns (bool) { } function approve(address _spender, uint256 _value) public whenNotPaused returns (bool) { } function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } contract LockableToken is PausableToken { using SafeMath for uint256; event Lock(address indexed owner, uint256 orderId, uint256 amount, uint256 releaseTimestamp); event UnLock(address indexed owner, uint256 orderId, uint256 amount); struct LockRecord { ///@dev order id uint256 orderId; ///@dev lock amount uint256 amount; ///@dev unlock timestamp uint256 releaseTimestamp; } mapping (address => LockRecord[]) ownedLockRecords; mapping (address => uint256) ownedLockAmount; /** * @dev Lock token until _timeSpan second. * @param _orderId uint256 * @param _amount uint256 */ function lockTokenForNode(uint256 _orderId, uint256 _amount, uint256 _timeSpan) public whenNotPaused { } function unlockToken() public whenNotPaused { } /** * @param _index uint256 Lock record idnex. * @return Return a lock record (lock amount, releaseTimestamp) */ function getLockByIndex(uint256 _index) public view returns(uint256, uint256, uint256) { } function getLockAmount() public view returns(uint256) { } /** * @dev Get lock records count */ function getLockRecordCount() view public returns(uint256) { } /** * @param _amount uint256 Lock amount. * @param _releaseTimestamp uint256 Unlock timestamp. */ function _lockToken(uint256 _orderId, uint256 _amount, uint256 _releaseTimestamp) internal { require(<FILL_ME>) balances[msg.sender] = balances[msg.sender].sub(_amount); ///@dev We don't care the orderId already exist or not. /// Because the web server will detect it. ownedLockRecords[msg.sender].push( LockRecord(_orderId, _amount, _releaseTimestamp) ); ownedLockAmount[msg.sender] = ownedLockAmount[msg.sender].add(_amount); emit Lock(msg.sender, _orderId, _amount, _releaseTimestamp); } /** * @dev using by internal. */ function _unlockTokenByIndex(uint256 _index) internal { } } contract BBEPayableToken is LockableToken { event Pay(address indexed owner, uint256 orderId, uint256 amount, uint256 burnAmount); address public cooAddress; /// @dev User pay action will consume a certain amount of token. //uint256 public payAmount; /// @dev User pay action will brun a certain amount of token their owned. //uint256 public payBrunAmount; /** * @dev The BBEPayableToken constructor sets the original `cooAddress` of the contract to the sender * account. */ constructor() public { } /// @dev Assigns a new address to act as the COO. /// @param _newCOO The address of the new COO. function setCOO(address _newCOO) external onlyOwner { } /** * @dev Pay for order * */ function payOrder(uint256 _orderId, uint256 _amount, uint256 _burnAmount) external whenNotPaused { } } contract BBECoin is BBEPayableToken { string public name = "BBE Coin"; string public symbol = "BBE"; uint8 public decimals = 8; // 8 billion in initial supply uint256 public constant INITIAL_SUPPLY = 800000000; constructor() public { } function globalBurnAmount() public view returns(uint256) { } }
ownedLockRecords[msg.sender].length<=20
291,241
ownedLockRecords[msg.sender].length<=20
"This method can only be used by the crowdsale address"
pragma solidity ^0.6.2; contract TokenMint is Ownable { using SafeMath for uint256; // Max tokens, setup in constructor uint256 public _totalSupplyCrowdsale = 0; uint256 public _totalSupplyCars = 0; // Current tokens minted uint256 public _currentSupplyCrowdsale = 0; uint256 public _currentSupplyCars = 0; // Store addresses address public _crowdsaleAddress = address(0); address public _carMechanicsAddress = address(0); // Token contract Token public _tokenContract; // // ******************* SETUP ******************* // // Constructor constructor () public Ownable() { } // Setup function setup(address tokenAddress, address crowdsaleAddress, address carMechanicsAddress) public onlyOwner returns (bool) { } // // ******************* MINTING ******************* // // For crowdsale to mint new tokens function mintForCrowdsale(address buyer, uint256 tokenAmount) public { // Only for crowdsale require(<FILL_ME>) // Check if we hit the limit uint256 newCurrent = _currentSupplyCrowdsale.add(tokenAmount); require(newCurrent < _totalSupplyCrowdsale, "Crowdsale can not mint more"); // Mint _tokenContract.mintToken(buyer, tokenAmount); // Update _currentSupplyCrowdsale = newCurrent; } // For car earnings function mintForCar(address owner, uint256 tokenAmount) public { } }
_msgSender()==_crowdsaleAddress,"This method can only be used by the crowdsale address"
291,265
_msgSender()==_crowdsaleAddress
"This method can only be used by the car mechanics address"
pragma solidity ^0.6.2; contract TokenMint is Ownable { using SafeMath for uint256; // Max tokens, setup in constructor uint256 public _totalSupplyCrowdsale = 0; uint256 public _totalSupplyCars = 0; // Current tokens minted uint256 public _currentSupplyCrowdsale = 0; uint256 public _currentSupplyCars = 0; // Store addresses address public _crowdsaleAddress = address(0); address public _carMechanicsAddress = address(0); // Token contract Token public _tokenContract; // // ******************* SETUP ******************* // // Constructor constructor () public Ownable() { } // Setup function setup(address tokenAddress, address crowdsaleAddress, address carMechanicsAddress) public onlyOwner returns (bool) { } // // ******************* MINTING ******************* // // For crowdsale to mint new tokens function mintForCrowdsale(address buyer, uint256 tokenAmount) public { } // For car earnings function mintForCar(address owner, uint256 tokenAmount) public { // Only for car require(<FILL_ME>) // Check if we hit the limit uint256 newCurrent = _currentSupplyCars.add(tokenAmount); require(newCurrent < _totalSupplyCars, "Car can not mint more"); // Mint _tokenContract.mintToken(owner, tokenAmount); // Update _currentSupplyCars = newCurrent; } }
_msgSender()==_carMechanicsAddress,"This method can only be used by the car mechanics address"
291,265
_msgSender()==_carMechanicsAddress
"You don't have a Dream Machine."
pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/IERC721.sol"; // import "@openzeppelin/[email protected]/token/ERC721/IERC721Receiver.sol"; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Metadata.sol"; // import "@openzeppelin/[email protected]/utils/Address.sol"; // import "@openzeppelin/[email protected]/utils/Context.sol"; // import "@openzeppelin/[email protected]/utils/Strings.sol"; // import "@openzeppelin/[email protected]/utils/introspection/ERC165.sol"; /** * This is a modified version of the ERC721 class, where we only store * the address of the minter into an _owners array upon minting. * * While this saves on minting gas costs, it means that the the balanceOf * function needs to do a bruteforce search through all the tokens. * * For small amounts of tokens (e.g. 8888), RPC services like Infura * can still query the function. * * It also means any future contracts that reads the balanceOf function * in a non-view function will incur a gigantic gas fee. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; string private _name; string private _symbol; address[] internal _owners; mapping(uint256 => address) private _tokenApprovals; mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function setApprovalForAll(address operator, bool approved) public virtual override { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { } function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _exists(uint256 tokenId) internal view virtual returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } function _safeMint(address to, uint256 tokenId) internal virtual { } function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _mint(address to, uint256 tokenId) internal virtual { } function _burn(uint256 tokenId) internal virtual { } function _transfer( address from, address to, uint256 tokenId ) internal virtual { } function _approve(address to, uint256 tokenId) internal virtual { } function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} } pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Enumerable.sol"; abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { } function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256 tokenId) { } function totalSupply() public view virtual override returns (uint256) { } function tokenByIndex(uint256 index) public view virtual override returns (uint256) { } } pragma solidity ^0.8.0; pragma abicoder v2; // import "@openzeppelin/[email protected]/access/Ownable.sol"; // import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; contract SorasDreamworldLucidDreaming is ERC721Enumerable, Ownable, ReentrancyGuard { using Strings for uint; uint public constant TOKEN_PRICE = 80000000000000000; // 0.08 ETH uint public constant PRE_SALE_TOKEN_PRICE = 50000000000000000; // 0.05 ETH uint public constant MAX_TOKENS_PER_PUBLIC_MINT = 10; // Only applies during public sale. uint public constant MAX_TOKENS = 8888; address public constant GENESIS_BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD; /// @dev 1: presale, 2: public sale, 3: genesis claim, 4: genesis burn, 255: closed. uint public saleState; /// @dev A mapping of the token names. mapping(uint => string) public tokenNames; // @dev Whether the presale slot has been used. One slot per address. mapping(address => bool) public presaleUsed; /// @dev 256-bit words, each representing 256 booleans. mapping(uint => uint) internal genesisClaimedMap; /// @dev The license text/url for every token. string public LICENSE = "https://www.nftlicense.org"; /// @dev Link to a Chainrand NFT. /// This contains all the information needed to reproduce /// the traits with a locked Chainlink VRF result. string public PROVENANCE; /// @dev The base URI string public baseURI; event TokenNameChanged(address _by, uint _tokenId, string _name); event LicenseSet(string _license); event ProvenanceSet(string _provenance); event SaleClosed(); event PreSaleOpened(); event PublicSaleOpened(); event GenesisClaimOpened(); event GenesisBurnOpened(); // IMPORTANT: Make sure to change this to the correct address before publishing! // Gen 0 mainnet address: 0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296 IERC721 internal genesisContract = IERC721(0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296); constructor() ERC721("Sora's Dreamworld: LUCID DREAMING", "SDLD") { } /// @dev Withdraws Ether for the owner. function withdraw() public onlyOwner { } /// @dev Sets the provenance. function setProvenance(string memory _provenance) public onlyOwner { } /// @dev Sets base URI for all token IDs. /// e.g. https://sorasdreamworld.io/tokens/dark/ function setBaseURI(string memory _baseURI) public onlyOwner { } /// @dev Open the pre-sale. function openPreSale() public onlyOwner { } /// @dev Open the public sale. function openPublicSale() public onlyOwner { } /// @dev Open the claim phase. function openGenesisClaim() public onlyOwner { } /// @dev Open the burn phase. function openGenesisBurn() public onlyOwner { } /// @dev Close the sale. function closeSale() public onlyOwner { } /// @dev Mint just one NFT. function mintOne(address _toAddress) internal { } /// @dev Force mint for the addresses. // Can be called anytime. // If called right after the creation of the contract, the tokens // are assigned sequentially starting from id 0. function forceMint(address[] memory _addresses) public onlyOwner { } /// @dev Self mint for the owner. /// Can be called anytime. /// This does not require the sale to be open. function selfMint(uint _numTokens) public onlyOwner { } /// @dev Sets the license text. function setLicense(string memory _license) public onlyOwner { } /// @dev Returns the license for tokens. function tokenLicense(uint _id) public view returns(string memory) { } /// @dev Mints tokens. function mint(uint _numTokens) public payable nonReentrant { // saleState == 1 || saleState == 2. Zero is not used. require(saleState < 3, "Not open."); require(_numTokens > 0, "Minimum number to mint is 1."); address sender = msg.sender; uint effectiveTokenPrice; if (saleState == 1) { effectiveTokenPrice = PRE_SALE_TOKEN_PRICE; require(_numTokens <= 1, "Number per mint exceeded."); require(<FILL_ME>) require(!presaleUsed[sender], "Presale slot already used."); presaleUsed[sender] = true; } else { // 2 effectiveTokenPrice = TOKEN_PRICE; require(_numTokens <= MAX_TOKENS_PER_PUBLIC_MINT, "Number per mint exceeded."); } require(msg.value >= effectiveTokenPrice * _numTokens, "Wrong Ether value."); for (uint i = 0; i < _numTokens; ++i) { mintOne(sender); } } /// @dev Returns whether the genesis token has been claimed. function checkGenesisClaimed(uint _genesisId) public view returns(bool) { } /// @dev Returns an array of uints representing whether the token has been claimed. function genesisClaimed(uint[] memory _genesisIds) public view returns(bool[] memory) { } /// @dev Use the genesis tokens to claim free mints. function genesisClaim(uint[] memory _genesisIds) public nonReentrant { } /// @dev Burns the genesis tokens for free mints. function genesisBurn(uint[] memory _genesisIds) public nonReentrant { } /// @dev Returns an array of the token ids under the owner. function tokensOfOwner(address _owner) external view returns (uint[] memory) { } /// @dev Change the token name. function changeTokenName(uint _id, string memory _name) public { } /// @dev Returns the token's URI for the metadata. function tokenURI(uint256 _id) public view virtual override returns (string memory) { } /// @dev Returns the most relevant stats in a single go to reduce RPC calls. function stats() external view returns (uint[] memory) { } }
genesisContract.balanceOf(sender)>0,"You don't have a Dream Machine."
291,275
genesisContract.balanceOf(sender)>0
"Presale slot already used."
pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/IERC721.sol"; // import "@openzeppelin/[email protected]/token/ERC721/IERC721Receiver.sol"; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Metadata.sol"; // import "@openzeppelin/[email protected]/utils/Address.sol"; // import "@openzeppelin/[email protected]/utils/Context.sol"; // import "@openzeppelin/[email protected]/utils/Strings.sol"; // import "@openzeppelin/[email protected]/utils/introspection/ERC165.sol"; /** * This is a modified version of the ERC721 class, where we only store * the address of the minter into an _owners array upon minting. * * While this saves on minting gas costs, it means that the the balanceOf * function needs to do a bruteforce search through all the tokens. * * For small amounts of tokens (e.g. 8888), RPC services like Infura * can still query the function. * * It also means any future contracts that reads the balanceOf function * in a non-view function will incur a gigantic gas fee. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; string private _name; string private _symbol; address[] internal _owners; mapping(uint256 => address) private _tokenApprovals; mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function setApprovalForAll(address operator, bool approved) public virtual override { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { } function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _exists(uint256 tokenId) internal view virtual returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } function _safeMint(address to, uint256 tokenId) internal virtual { } function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _mint(address to, uint256 tokenId) internal virtual { } function _burn(uint256 tokenId) internal virtual { } function _transfer( address from, address to, uint256 tokenId ) internal virtual { } function _approve(address to, uint256 tokenId) internal virtual { } function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} } pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Enumerable.sol"; abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { } function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256 tokenId) { } function totalSupply() public view virtual override returns (uint256) { } function tokenByIndex(uint256 index) public view virtual override returns (uint256) { } } pragma solidity ^0.8.0; pragma abicoder v2; // import "@openzeppelin/[email protected]/access/Ownable.sol"; // import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; contract SorasDreamworldLucidDreaming is ERC721Enumerable, Ownable, ReentrancyGuard { using Strings for uint; uint public constant TOKEN_PRICE = 80000000000000000; // 0.08 ETH uint public constant PRE_SALE_TOKEN_PRICE = 50000000000000000; // 0.05 ETH uint public constant MAX_TOKENS_PER_PUBLIC_MINT = 10; // Only applies during public sale. uint public constant MAX_TOKENS = 8888; address public constant GENESIS_BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD; /// @dev 1: presale, 2: public sale, 3: genesis claim, 4: genesis burn, 255: closed. uint public saleState; /// @dev A mapping of the token names. mapping(uint => string) public tokenNames; // @dev Whether the presale slot has been used. One slot per address. mapping(address => bool) public presaleUsed; /// @dev 256-bit words, each representing 256 booleans. mapping(uint => uint) internal genesisClaimedMap; /// @dev The license text/url for every token. string public LICENSE = "https://www.nftlicense.org"; /// @dev Link to a Chainrand NFT. /// This contains all the information needed to reproduce /// the traits with a locked Chainlink VRF result. string public PROVENANCE; /// @dev The base URI string public baseURI; event TokenNameChanged(address _by, uint _tokenId, string _name); event LicenseSet(string _license); event ProvenanceSet(string _provenance); event SaleClosed(); event PreSaleOpened(); event PublicSaleOpened(); event GenesisClaimOpened(); event GenesisBurnOpened(); // IMPORTANT: Make sure to change this to the correct address before publishing! // Gen 0 mainnet address: 0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296 IERC721 internal genesisContract = IERC721(0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296); constructor() ERC721("Sora's Dreamworld: LUCID DREAMING", "SDLD") { } /// @dev Withdraws Ether for the owner. function withdraw() public onlyOwner { } /// @dev Sets the provenance. function setProvenance(string memory _provenance) public onlyOwner { } /// @dev Sets base URI for all token IDs. /// e.g. https://sorasdreamworld.io/tokens/dark/ function setBaseURI(string memory _baseURI) public onlyOwner { } /// @dev Open the pre-sale. function openPreSale() public onlyOwner { } /// @dev Open the public sale. function openPublicSale() public onlyOwner { } /// @dev Open the claim phase. function openGenesisClaim() public onlyOwner { } /// @dev Open the burn phase. function openGenesisBurn() public onlyOwner { } /// @dev Close the sale. function closeSale() public onlyOwner { } /// @dev Mint just one NFT. function mintOne(address _toAddress) internal { } /// @dev Force mint for the addresses. // Can be called anytime. // If called right after the creation of the contract, the tokens // are assigned sequentially starting from id 0. function forceMint(address[] memory _addresses) public onlyOwner { } /// @dev Self mint for the owner. /// Can be called anytime. /// This does not require the sale to be open. function selfMint(uint _numTokens) public onlyOwner { } /// @dev Sets the license text. function setLicense(string memory _license) public onlyOwner { } /// @dev Returns the license for tokens. function tokenLicense(uint _id) public view returns(string memory) { } /// @dev Mints tokens. function mint(uint _numTokens) public payable nonReentrant { // saleState == 1 || saleState == 2. Zero is not used. require(saleState < 3, "Not open."); require(_numTokens > 0, "Minimum number to mint is 1."); address sender = msg.sender; uint effectiveTokenPrice; if (saleState == 1) { effectiveTokenPrice = PRE_SALE_TOKEN_PRICE; require(_numTokens <= 1, "Number per mint exceeded."); require(genesisContract.balanceOf(sender) > 0, "You don't have a Dream Machine."); require(<FILL_ME>) presaleUsed[sender] = true; } else { // 2 effectiveTokenPrice = TOKEN_PRICE; require(_numTokens <= MAX_TOKENS_PER_PUBLIC_MINT, "Number per mint exceeded."); } require(msg.value >= effectiveTokenPrice * _numTokens, "Wrong Ether value."); for (uint i = 0; i < _numTokens; ++i) { mintOne(sender); } } /// @dev Returns whether the genesis token has been claimed. function checkGenesisClaimed(uint _genesisId) public view returns(bool) { } /// @dev Returns an array of uints representing whether the token has been claimed. function genesisClaimed(uint[] memory _genesisIds) public view returns(bool[] memory) { } /// @dev Use the genesis tokens to claim free mints. function genesisClaim(uint[] memory _genesisIds) public nonReentrant { } /// @dev Burns the genesis tokens for free mints. function genesisBurn(uint[] memory _genesisIds) public nonReentrant { } /// @dev Returns an array of the token ids under the owner. function tokensOfOwner(address _owner) external view returns (uint[] memory) { } /// @dev Change the token name. function changeTokenName(uint _id, string memory _name) public { } /// @dev Returns the token's URI for the metadata. function tokenURI(uint256 _id) public view virtual override returns (string memory) { } /// @dev Returns the most relevant stats in a single go to reduce RPC calls. function stats() external view returns (uint[] memory) { } }
!presaleUsed[sender],"Presale slot already used."
291,275
!presaleUsed[sender]
"Invalid submission."
pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/IERC721.sol"; // import "@openzeppelin/[email protected]/token/ERC721/IERC721Receiver.sol"; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Metadata.sol"; // import "@openzeppelin/[email protected]/utils/Address.sol"; // import "@openzeppelin/[email protected]/utils/Context.sol"; // import "@openzeppelin/[email protected]/utils/Strings.sol"; // import "@openzeppelin/[email protected]/utils/introspection/ERC165.sol"; /** * This is a modified version of the ERC721 class, where we only store * the address of the minter into an _owners array upon minting. * * While this saves on minting gas costs, it means that the the balanceOf * function needs to do a bruteforce search through all the tokens. * * For small amounts of tokens (e.g. 8888), RPC services like Infura * can still query the function. * * It also means any future contracts that reads the balanceOf function * in a non-view function will incur a gigantic gas fee. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; string private _name; string private _symbol; address[] internal _owners; mapping(uint256 => address) private _tokenApprovals; mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function setApprovalForAll(address operator, bool approved) public virtual override { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { } function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _exists(uint256 tokenId) internal view virtual returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } function _safeMint(address to, uint256 tokenId) internal virtual { } function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _mint(address to, uint256 tokenId) internal virtual { } function _burn(uint256 tokenId) internal virtual { } function _transfer( address from, address to, uint256 tokenId ) internal virtual { } function _approve(address to, uint256 tokenId) internal virtual { } function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} } pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Enumerable.sol"; abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { } function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256 tokenId) { } function totalSupply() public view virtual override returns (uint256) { } function tokenByIndex(uint256 index) public view virtual override returns (uint256) { } } pragma solidity ^0.8.0; pragma abicoder v2; // import "@openzeppelin/[email protected]/access/Ownable.sol"; // import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; contract SorasDreamworldLucidDreaming is ERC721Enumerable, Ownable, ReentrancyGuard { using Strings for uint; uint public constant TOKEN_PRICE = 80000000000000000; // 0.08 ETH uint public constant PRE_SALE_TOKEN_PRICE = 50000000000000000; // 0.05 ETH uint public constant MAX_TOKENS_PER_PUBLIC_MINT = 10; // Only applies during public sale. uint public constant MAX_TOKENS = 8888; address public constant GENESIS_BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD; /// @dev 1: presale, 2: public sale, 3: genesis claim, 4: genesis burn, 255: closed. uint public saleState; /// @dev A mapping of the token names. mapping(uint => string) public tokenNames; // @dev Whether the presale slot has been used. One slot per address. mapping(address => bool) public presaleUsed; /// @dev 256-bit words, each representing 256 booleans. mapping(uint => uint) internal genesisClaimedMap; /// @dev The license text/url for every token. string public LICENSE = "https://www.nftlicense.org"; /// @dev Link to a Chainrand NFT. /// This contains all the information needed to reproduce /// the traits with a locked Chainlink VRF result. string public PROVENANCE; /// @dev The base URI string public baseURI; event TokenNameChanged(address _by, uint _tokenId, string _name); event LicenseSet(string _license); event ProvenanceSet(string _provenance); event SaleClosed(); event PreSaleOpened(); event PublicSaleOpened(); event GenesisClaimOpened(); event GenesisBurnOpened(); // IMPORTANT: Make sure to change this to the correct address before publishing! // Gen 0 mainnet address: 0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296 IERC721 internal genesisContract = IERC721(0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296); constructor() ERC721("Sora's Dreamworld: LUCID DREAMING", "SDLD") { } /// @dev Withdraws Ether for the owner. function withdraw() public onlyOwner { } /// @dev Sets the provenance. function setProvenance(string memory _provenance) public onlyOwner { } /// @dev Sets base URI for all token IDs. /// e.g. https://sorasdreamworld.io/tokens/dark/ function setBaseURI(string memory _baseURI) public onlyOwner { } /// @dev Open the pre-sale. function openPreSale() public onlyOwner { } /// @dev Open the public sale. function openPublicSale() public onlyOwner { } /// @dev Open the claim phase. function openGenesisClaim() public onlyOwner { } /// @dev Open the burn phase. function openGenesisBurn() public onlyOwner { } /// @dev Close the sale. function closeSale() public onlyOwner { } /// @dev Mint just one NFT. function mintOne(address _toAddress) internal { } /// @dev Force mint for the addresses. // Can be called anytime. // If called right after the creation of the contract, the tokens // are assigned sequentially starting from id 0. function forceMint(address[] memory _addresses) public onlyOwner { } /// @dev Self mint for the owner. /// Can be called anytime. /// This does not require the sale to be open. function selfMint(uint _numTokens) public onlyOwner { } /// @dev Sets the license text. function setLicense(string memory _license) public onlyOwner { } /// @dev Returns the license for tokens. function tokenLicense(uint _id) public view returns(string memory) { } /// @dev Mints tokens. function mint(uint _numTokens) public payable nonReentrant { } /// @dev Returns whether the genesis token has been claimed. function checkGenesisClaimed(uint _genesisId) public view returns(bool) { } /// @dev Returns an array of uints representing whether the token has been claimed. function genesisClaimed(uint[] memory _genesisIds) public view returns(bool[] memory) { } /// @dev Use the genesis tokens to claim free mints. function genesisClaim(uint[] memory _genesisIds) public nonReentrant { require(saleState == 3, "Not open."); uint n = _genesisIds.length; require(n > 0 && n % 3 == 0, "Please submit a positive multiple of 3."); address sender = msg.sender; uint qPrevInitial = 1 << 255; uint qPrev = qPrevInitial; uint m; for (uint i = 0; i < n; i += 3) { for (uint j = 0; j < 3; ++j) { uint t = _genesisIds[i + j]; uint q = t >> 8; uint r = t & 255; if (q != qPrev) { if (qPrev != qPrevInitial) { genesisClaimedMap[qPrev] = m; } m = genesisClaimedMap[q]; } qPrev = q; uint b = 1 << r; // Token must be unused and owned. require(<FILL_ME>) // Modifying the map and checking will ensure that there // are no duplicates in _genesisIds. m = m | b; } mintOne(sender); } genesisClaimedMap[qPrev] = m; } /// @dev Burns the genesis tokens for free mints. function genesisBurn(uint[] memory _genesisIds) public nonReentrant { } /// @dev Returns an array of the token ids under the owner. function tokensOfOwner(address _owner) external view returns (uint[] memory) { } /// @dev Change the token name. function changeTokenName(uint _id, string memory _name) public { } /// @dev Returns the token's URI for the metadata. function tokenURI(uint256 _id) public view virtual override returns (string memory) { } /// @dev Returns the most relevant stats in a single go to reduce RPC calls. function stats() external view returns (uint[] memory) { } }
m&b==0&&genesisContract.ownerOf(t)==sender,"Invalid submission."
291,275
m&b==0&&genesisContract.ownerOf(t)==sender
"You do not own this token."
pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/IERC721.sol"; // import "@openzeppelin/[email protected]/token/ERC721/IERC721Receiver.sol"; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Metadata.sol"; // import "@openzeppelin/[email protected]/utils/Address.sol"; // import "@openzeppelin/[email protected]/utils/Context.sol"; // import "@openzeppelin/[email protected]/utils/Strings.sol"; // import "@openzeppelin/[email protected]/utils/introspection/ERC165.sol"; /** * This is a modified version of the ERC721 class, where we only store * the address of the minter into an _owners array upon minting. * * While this saves on minting gas costs, it means that the the balanceOf * function needs to do a bruteforce search through all the tokens. * * For small amounts of tokens (e.g. 8888), RPC services like Infura * can still query the function. * * It also means any future contracts that reads the balanceOf function * in a non-view function will incur a gigantic gas fee. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; string private _name; string private _symbol; address[] internal _owners; mapping(uint256 => address) private _tokenApprovals; mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function setApprovalForAll(address operator, bool approved) public virtual override { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { } function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _exists(uint256 tokenId) internal view virtual returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } function _safeMint(address to, uint256 tokenId) internal virtual { } function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _mint(address to, uint256 tokenId) internal virtual { } function _burn(uint256 tokenId) internal virtual { } function _transfer( address from, address to, uint256 tokenId ) internal virtual { } function _approve(address to, uint256 tokenId) internal virtual { } function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} } pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Enumerable.sol"; abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { } function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256 tokenId) { } function totalSupply() public view virtual override returns (uint256) { } function tokenByIndex(uint256 index) public view virtual override returns (uint256) { } } pragma solidity ^0.8.0; pragma abicoder v2; // import "@openzeppelin/[email protected]/access/Ownable.sol"; // import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; contract SorasDreamworldLucidDreaming is ERC721Enumerable, Ownable, ReentrancyGuard { using Strings for uint; uint public constant TOKEN_PRICE = 80000000000000000; // 0.08 ETH uint public constant PRE_SALE_TOKEN_PRICE = 50000000000000000; // 0.05 ETH uint public constant MAX_TOKENS_PER_PUBLIC_MINT = 10; // Only applies during public sale. uint public constant MAX_TOKENS = 8888; address public constant GENESIS_BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD; /// @dev 1: presale, 2: public sale, 3: genesis claim, 4: genesis burn, 255: closed. uint public saleState; /// @dev A mapping of the token names. mapping(uint => string) public tokenNames; // @dev Whether the presale slot has been used. One slot per address. mapping(address => bool) public presaleUsed; /// @dev 256-bit words, each representing 256 booleans. mapping(uint => uint) internal genesisClaimedMap; /// @dev The license text/url for every token. string public LICENSE = "https://www.nftlicense.org"; /// @dev Link to a Chainrand NFT. /// This contains all the information needed to reproduce /// the traits with a locked Chainlink VRF result. string public PROVENANCE; /// @dev The base URI string public baseURI; event TokenNameChanged(address _by, uint _tokenId, string _name); event LicenseSet(string _license); event ProvenanceSet(string _provenance); event SaleClosed(); event PreSaleOpened(); event PublicSaleOpened(); event GenesisClaimOpened(); event GenesisBurnOpened(); // IMPORTANT: Make sure to change this to the correct address before publishing! // Gen 0 mainnet address: 0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296 IERC721 internal genesisContract = IERC721(0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296); constructor() ERC721("Sora's Dreamworld: LUCID DREAMING", "SDLD") { } /// @dev Withdraws Ether for the owner. function withdraw() public onlyOwner { } /// @dev Sets the provenance. function setProvenance(string memory _provenance) public onlyOwner { } /// @dev Sets base URI for all token IDs. /// e.g. https://sorasdreamworld.io/tokens/dark/ function setBaseURI(string memory _baseURI) public onlyOwner { } /// @dev Open the pre-sale. function openPreSale() public onlyOwner { } /// @dev Open the public sale. function openPublicSale() public onlyOwner { } /// @dev Open the claim phase. function openGenesisClaim() public onlyOwner { } /// @dev Open the burn phase. function openGenesisBurn() public onlyOwner { } /// @dev Close the sale. function closeSale() public onlyOwner { } /// @dev Mint just one NFT. function mintOne(address _toAddress) internal { } /// @dev Force mint for the addresses. // Can be called anytime. // If called right after the creation of the contract, the tokens // are assigned sequentially starting from id 0. function forceMint(address[] memory _addresses) public onlyOwner { } /// @dev Self mint for the owner. /// Can be called anytime. /// This does not require the sale to be open. function selfMint(uint _numTokens) public onlyOwner { } /// @dev Sets the license text. function setLicense(string memory _license) public onlyOwner { } /// @dev Returns the license for tokens. function tokenLicense(uint _id) public view returns(string memory) { } /// @dev Mints tokens. function mint(uint _numTokens) public payable nonReentrant { } /// @dev Returns whether the genesis token has been claimed. function checkGenesisClaimed(uint _genesisId) public view returns(bool) { } /// @dev Returns an array of uints representing whether the token has been claimed. function genesisClaimed(uint[] memory _genesisIds) public view returns(bool[] memory) { } /// @dev Use the genesis tokens to claim free mints. function genesisClaim(uint[] memory _genesisIds) public nonReentrant { } /// @dev Burns the genesis tokens for free mints. function genesisBurn(uint[] memory _genesisIds) public nonReentrant { } /// @dev Returns an array of the token ids under the owner. function tokensOfOwner(address _owner) external view returns (uint[] memory) { } /// @dev Change the token name. function changeTokenName(uint _id, string memory _name) public { require(<FILL_ME>) require(sha256(bytes(_name)) != sha256(bytes(tokenNames[_id])), "Name unchanged."); tokenNames[_id] = _name; emit TokenNameChanged(msg.sender, _id, _name); } /// @dev Returns the token's URI for the metadata. function tokenURI(uint256 _id) public view virtual override returns (string memory) { } /// @dev Returns the most relevant stats in a single go to reduce RPC calls. function stats() external view returns (uint[] memory) { } }
ownerOf(_id)==msg.sender,"You do not own this token."
291,275
ownerOf(_id)==msg.sender
"Name unchanged."
pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/IERC721.sol"; // import "@openzeppelin/[email protected]/token/ERC721/IERC721Receiver.sol"; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Metadata.sol"; // import "@openzeppelin/[email protected]/utils/Address.sol"; // import "@openzeppelin/[email protected]/utils/Context.sol"; // import "@openzeppelin/[email protected]/utils/Strings.sol"; // import "@openzeppelin/[email protected]/utils/introspection/ERC165.sol"; /** * This is a modified version of the ERC721 class, where we only store * the address of the minter into an _owners array upon minting. * * While this saves on minting gas costs, it means that the the balanceOf * function needs to do a bruteforce search through all the tokens. * * For small amounts of tokens (e.g. 8888), RPC services like Infura * can still query the function. * * It also means any future contracts that reads the balanceOf function * in a non-view function will incur a gigantic gas fee. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; string private _name; string private _symbol; address[] internal _owners; mapping(uint256 => address) private _tokenApprovals; mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function setApprovalForAll(address operator, bool approved) public virtual override { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { } function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _exists(uint256 tokenId) internal view virtual returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } function _safeMint(address to, uint256 tokenId) internal virtual { } function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { } function _mint(address to, uint256 tokenId) internal virtual { } function _burn(uint256 tokenId) internal virtual { } function _transfer( address from, address to, uint256 tokenId ) internal virtual { } function _approve(address to, uint256 tokenId) internal virtual { } function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { } function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} } pragma solidity ^0.8.0; // import "@openzeppelin/[email protected]/token/ERC721/extensions/IERC721Enumerable.sol"; abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { } function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256 tokenId) { } function totalSupply() public view virtual override returns (uint256) { } function tokenByIndex(uint256 index) public view virtual override returns (uint256) { } } pragma solidity ^0.8.0; pragma abicoder v2; // import "@openzeppelin/[email protected]/access/Ownable.sol"; // import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; contract SorasDreamworldLucidDreaming is ERC721Enumerable, Ownable, ReentrancyGuard { using Strings for uint; uint public constant TOKEN_PRICE = 80000000000000000; // 0.08 ETH uint public constant PRE_SALE_TOKEN_PRICE = 50000000000000000; // 0.05 ETH uint public constant MAX_TOKENS_PER_PUBLIC_MINT = 10; // Only applies during public sale. uint public constant MAX_TOKENS = 8888; address public constant GENESIS_BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD; /// @dev 1: presale, 2: public sale, 3: genesis claim, 4: genesis burn, 255: closed. uint public saleState; /// @dev A mapping of the token names. mapping(uint => string) public tokenNames; // @dev Whether the presale slot has been used. One slot per address. mapping(address => bool) public presaleUsed; /// @dev 256-bit words, each representing 256 booleans. mapping(uint => uint) internal genesisClaimedMap; /// @dev The license text/url for every token. string public LICENSE = "https://www.nftlicense.org"; /// @dev Link to a Chainrand NFT. /// This contains all the information needed to reproduce /// the traits with a locked Chainlink VRF result. string public PROVENANCE; /// @dev The base URI string public baseURI; event TokenNameChanged(address _by, uint _tokenId, string _name); event LicenseSet(string _license); event ProvenanceSet(string _provenance); event SaleClosed(); event PreSaleOpened(); event PublicSaleOpened(); event GenesisClaimOpened(); event GenesisBurnOpened(); // IMPORTANT: Make sure to change this to the correct address before publishing! // Gen 0 mainnet address: 0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296 IERC721 internal genesisContract = IERC721(0x4e2781e3aD94b2DfcF34c51De0D8e9358c69F296); constructor() ERC721("Sora's Dreamworld: LUCID DREAMING", "SDLD") { } /// @dev Withdraws Ether for the owner. function withdraw() public onlyOwner { } /// @dev Sets the provenance. function setProvenance(string memory _provenance) public onlyOwner { } /// @dev Sets base URI for all token IDs. /// e.g. https://sorasdreamworld.io/tokens/dark/ function setBaseURI(string memory _baseURI) public onlyOwner { } /// @dev Open the pre-sale. function openPreSale() public onlyOwner { } /// @dev Open the public sale. function openPublicSale() public onlyOwner { } /// @dev Open the claim phase. function openGenesisClaim() public onlyOwner { } /// @dev Open the burn phase. function openGenesisBurn() public onlyOwner { } /// @dev Close the sale. function closeSale() public onlyOwner { } /// @dev Mint just one NFT. function mintOne(address _toAddress) internal { } /// @dev Force mint for the addresses. // Can be called anytime. // If called right after the creation of the contract, the tokens // are assigned sequentially starting from id 0. function forceMint(address[] memory _addresses) public onlyOwner { } /// @dev Self mint for the owner. /// Can be called anytime. /// This does not require the sale to be open. function selfMint(uint _numTokens) public onlyOwner { } /// @dev Sets the license text. function setLicense(string memory _license) public onlyOwner { } /// @dev Returns the license for tokens. function tokenLicense(uint _id) public view returns(string memory) { } /// @dev Mints tokens. function mint(uint _numTokens) public payable nonReentrant { } /// @dev Returns whether the genesis token has been claimed. function checkGenesisClaimed(uint _genesisId) public view returns(bool) { } /// @dev Returns an array of uints representing whether the token has been claimed. function genesisClaimed(uint[] memory _genesisIds) public view returns(bool[] memory) { } /// @dev Use the genesis tokens to claim free mints. function genesisClaim(uint[] memory _genesisIds) public nonReentrant { } /// @dev Burns the genesis tokens for free mints. function genesisBurn(uint[] memory _genesisIds) public nonReentrant { } /// @dev Returns an array of the token ids under the owner. function tokensOfOwner(address _owner) external view returns (uint[] memory) { } /// @dev Change the token name. function changeTokenName(uint _id, string memory _name) public { require(ownerOf(_id) == msg.sender, "You do not own this token."); require(<FILL_ME>) tokenNames[_id] = _name; emit TokenNameChanged(msg.sender, _id, _name); } /// @dev Returns the token's URI for the metadata. function tokenURI(uint256 _id) public view virtual override returns (string memory) { } /// @dev Returns the most relevant stats in a single go to reduce RPC calls. function stats() external view returns (uint[] memory) { } }
sha256(bytes(_name))!=sha256(bytes(tokenNames[_id])),"Name unchanged."
291,275
sha256(bytes(_name))!=sha256(bytes(tokenNames[_id]))
"lack approvers permission"
// SPDX-License-Identifier: MIT pragma solidity 0.4.26; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. */ function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) { } /** * @dev Integer division of two numbers, truncating the quotient. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two numbers, throws on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256 c) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; address private proposedOwner; event OwnershipRenounced(address indexed previousOwner); event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ constructor() public { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev propose a new owner by an existing owner * @param _newOwner The address proposed to transfer ownership to. */ function proposeOwner(address _newOwner) public onlyOwner { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. */ function takeOwnership() public { } /** * @dev Transfers control of the contract to a newOwner. * @param _newOwner The address to transfer ownership to. */ function _transferOwnership(address _newOwner) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is Ownable { event Pause(); event Unpause(); bool public paused; //default as false /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev called by the owner to pause, triggers stopped state */ function pause() onlyOwner whenNotPaused public { } /** * @dev called by the owner to unpauseunpause, returns to normal state */ function unpause() onlyOwner whenPaused public { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval( address indexed owner, address indexed spender, uint256 value ); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 public totalSupply; /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } } /** * @title Standard ERC20 token * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint256 _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint256 _subtractedValue) public returns (bool) { } } /** * @title Pausable token * @dev StandardToken modified with pausable transfers. **/ contract PausableToken is StandardToken, Pausable { function transfer(address _to, uint256 _value) public whenNotPaused returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public whenNotPaused returns (bool) { } function approve(address _spender, uint256 _value) public whenNotPaused returns (bool) { } function increaseApproval(address _spender, uint256 _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint256 _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Frozenable Token * @dev Illegal address that can be frozened. */ contract FrozenableToken is Ownable { mapping (address => bool) public Approvers; mapping (address => bool) public frozenAccount; event FrozenFunds(address indexed to, bool frozen); modifier whenNotFrozen(address _who) { } function setApprover(address _wallet, bool _approve) public onlyOwner { } function freezeAccount(address _to, bool _freeze) public { require(<FILL_ME>) require(_to != address(0), "not to self"); frozenAccount[_to] = _freeze; emit FrozenFunds(_to, _freeze); } } /** *------------------Mintable token---------------------------- */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Mint method * @param _to newly minted tokens will be sent to this address * @param _amount amount to mint * @return A boolean that indicates if the operation was successful. */ function _mint(address _to, uint256 _amount) internal returns (bool) { } } contract BlueMooN is PausableToken, FrozenableToken, MintableToken { using SafeMath for uint256; string public constant name = "BlueMooN"; string public constant symbol = "BMOON"; uint256 public constant decimals = 18; uint public constant totalHolders = 6; // total number is fixed, wont change in future // but holders address can be updated thru setMintSplitHolder method // uint256 INITIAL_SUPPLY = 10 *(10 ** 5) * (10 ** uint256(decimals)); uint256 private INITIAL_SUPPLY = 0; mapping (uint => address) public holders; mapping (uint => uint256) public MintSplitHolderRatios; //index -> ratio boosted by 10000 mapping (address => bool) public Proposers; mapping (address => uint256) public Proposals; //address -> mintAmount /** * @dev Initializes the total release */ constructor() public { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public whenNotFrozen(_to) returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public whenNotFrozen(_from) returns (bool) { } function setProposer(address _wallet, bool _on) public onlyOwner { } /** * to update an split holder ratio at the index * index ranges from 0..totalHolders -1 */ function setMintSplitHolder(uint256 index, address _wallet, uint256 _ratio) public onlyOwner returns (bool) { } /** * @dev propose to mint * @param _amount amount to mint * @return mint propose ID */ function proposeMint(uint256 _amount) public returns(bool) { } function approveMint(address _proposer, uint256 _amount, bool _approve) public returns(bool) { } }
Approvers[msg.sender],"lack approvers permission"
291,315
Approvers[msg.sender]
"Non-proposer not allowed"
// SPDX-License-Identifier: MIT pragma solidity 0.4.26; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. */ function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) { } /** * @dev Integer division of two numbers, truncating the quotient. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two numbers, throws on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256 c) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; address private proposedOwner; event OwnershipRenounced(address indexed previousOwner); event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ constructor() public { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev propose a new owner by an existing owner * @param _newOwner The address proposed to transfer ownership to. */ function proposeOwner(address _newOwner) public onlyOwner { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. */ function takeOwnership() public { } /** * @dev Transfers control of the contract to a newOwner. * @param _newOwner The address to transfer ownership to. */ function _transferOwnership(address _newOwner) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is Ownable { event Pause(); event Unpause(); bool public paused; //default as false /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev called by the owner to pause, triggers stopped state */ function pause() onlyOwner whenNotPaused public { } /** * @dev called by the owner to unpauseunpause, returns to normal state */ function unpause() onlyOwner whenPaused public { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval( address indexed owner, address indexed spender, uint256 value ); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 public totalSupply; /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } } /** * @title Standard ERC20 token * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint256 _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint256 _subtractedValue) public returns (bool) { } } /** * @title Pausable token * @dev StandardToken modified with pausable transfers. **/ contract PausableToken is StandardToken, Pausable { function transfer(address _to, uint256 _value) public whenNotPaused returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public whenNotPaused returns (bool) { } function approve(address _spender, uint256 _value) public whenNotPaused returns (bool) { } function increaseApproval(address _spender, uint256 _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint256 _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Frozenable Token * @dev Illegal address that can be frozened. */ contract FrozenableToken is Ownable { mapping (address => bool) public Approvers; mapping (address => bool) public frozenAccount; event FrozenFunds(address indexed to, bool frozen); modifier whenNotFrozen(address _who) { } function setApprover(address _wallet, bool _approve) public onlyOwner { } function freezeAccount(address _to, bool _freeze) public { } } /** *------------------Mintable token---------------------------- */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Mint method * @param _to newly minted tokens will be sent to this address * @param _amount amount to mint * @return A boolean that indicates if the operation was successful. */ function _mint(address _to, uint256 _amount) internal returns (bool) { } } contract BlueMooN is PausableToken, FrozenableToken, MintableToken { using SafeMath for uint256; string public constant name = "BlueMooN"; string public constant symbol = "BMOON"; uint256 public constant decimals = 18; uint public constant totalHolders = 6; // total number is fixed, wont change in future // but holders address can be updated thru setMintSplitHolder method // uint256 INITIAL_SUPPLY = 10 *(10 ** 5) * (10 ** uint256(decimals)); uint256 private INITIAL_SUPPLY = 0; mapping (uint => address) public holders; mapping (uint => uint256) public MintSplitHolderRatios; //index -> ratio boosted by 10000 mapping (address => bool) public Proposers; mapping (address => uint256) public Proposals; //address -> mintAmount /** * @dev Initializes the total release */ constructor() public { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public whenNotFrozen(_to) returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public whenNotFrozen(_from) returns (bool) { } function setProposer(address _wallet, bool _on) public onlyOwner { } /** * to update an split holder ratio at the index * index ranges from 0..totalHolders -1 */ function setMintSplitHolder(uint256 index, address _wallet, uint256 _ratio) public onlyOwner returns (bool) { } /** * @dev propose to mint * @param _amount amount to mint * @return mint propose ID */ function proposeMint(uint256 _amount) public returns(bool) { require(<FILL_ME>) Proposals[msg.sender] = _amount; //mint once for a propoer at a time otherwise would be overwritten return true; } function approveMint(address _proposer, uint256 _amount, bool _approve) public returns(bool) { } }
Proposers[msg.sender],"Non-proposer not allowed"
291,315
Proposers[msg.sender]
"Over-approve mint amount not allowed"
// SPDX-License-Identifier: MIT pragma solidity 0.4.26; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { /** * @dev Multiplies two numbers, throws on overflow. */ function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) { } /** * @dev Integer division of two numbers, truncating the quotient. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two numbers, throws on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256 c) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; address private proposedOwner; event OwnershipRenounced(address indexed previousOwner); event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ constructor() public { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev propose a new owner by an existing owner * @param _newOwner The address proposed to transfer ownership to. */ function proposeOwner(address _newOwner) public onlyOwner { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. */ function takeOwnership() public { } /** * @dev Transfers control of the contract to a newOwner. * @param _newOwner The address to transfer ownership to. */ function _transferOwnership(address _newOwner) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is Ownable { event Pause(); event Unpause(); bool public paused; //default as false /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev called by the owner to pause, triggers stopped state */ function pause() onlyOwner whenNotPaused public { } /** * @dev called by the owner to unpauseunpause, returns to normal state */ function unpause() onlyOwner whenPaused public { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) public view returns (uint256); function transferFrom(address from, address to, uint256 value) public returns (bool); function approve(address spender, uint256 value) public returns (bool); event Approval( address indexed owner, address indexed spender, uint256 value ); } /** * @title Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; uint256 public totalSupply; /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Gets the balance of the specified address. * @param _owner The address to query the the balance of. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } } /** * @title Standard ERC20 token * @dev Implementation of the basic standard token. * @dev https://github.com/ethereum/EIPs/issues/20 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param _spender The address which will spend the funds. * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner, address _spender) public view returns (uint256) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _addedValue The amount of tokens to increase the allowance by. */ function increaseApproval(address _spender, uint256 _addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * * approve should be called when allowed[_spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * @param _spender The address which will spend the funds. * @param _subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseApproval(address _spender, uint256 _subtractedValue) public returns (bool) { } } /** * @title Pausable token * @dev StandardToken modified with pausable transfers. **/ contract PausableToken is StandardToken, Pausable { function transfer(address _to, uint256 _value) public whenNotPaused returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public whenNotPaused returns (bool) { } function approve(address _spender, uint256 _value) public whenNotPaused returns (bool) { } function increaseApproval(address _spender, uint256 _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint256 _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Frozenable Token * @dev Illegal address that can be frozened. */ contract FrozenableToken is Ownable { mapping (address => bool) public Approvers; mapping (address => bool) public frozenAccount; event FrozenFunds(address indexed to, bool frozen); modifier whenNotFrozen(address _who) { } function setApprover(address _wallet, bool _approve) public onlyOwner { } function freezeAccount(address _to, bool _freeze) public { } } /** *------------------Mintable token---------------------------- */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Mint method * @param _to newly minted tokens will be sent to this address * @param _amount amount to mint * @return A boolean that indicates if the operation was successful. */ function _mint(address _to, uint256 _amount) internal returns (bool) { } } contract BlueMooN is PausableToken, FrozenableToken, MintableToken { using SafeMath for uint256; string public constant name = "BlueMooN"; string public constant symbol = "BMOON"; uint256 public constant decimals = 18; uint public constant totalHolders = 6; // total number is fixed, wont change in future // but holders address can be updated thru setMintSplitHolder method // uint256 INITIAL_SUPPLY = 10 *(10 ** 5) * (10 ** uint256(decimals)); uint256 private INITIAL_SUPPLY = 0; mapping (uint => address) public holders; mapping (uint => uint256) public MintSplitHolderRatios; //index -> ratio boosted by 10000 mapping (address => bool) public Proposers; mapping (address => uint256) public Proposals; //address -> mintAmount /** * @dev Initializes the total release */ constructor() public { } /** * @dev transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public whenNotFrozen(_to) returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from, address _to, uint256 _value) public whenNotFrozen(_from) returns (bool) { } function setProposer(address _wallet, bool _on) public onlyOwner { } /** * to update an split holder ratio at the index * index ranges from 0..totalHolders -1 */ function setMintSplitHolder(uint256 index, address _wallet, uint256 _ratio) public onlyOwner returns (bool) { } /** * @dev propose to mint * @param _amount amount to mint * @return mint propose ID */ function proposeMint(uint256 _amount) public returns(bool) { } function approveMint(address _proposer, uint256 _amount, bool _approve) public returns(bool) { require( Approvers[msg.sender], "None-approver not allowed" ); if (!_approve) { delete Proposals[_proposer]; return true; } require( _amount > 0, "zero amount not allowed" ); require(<FILL_ME>) uint256 remaining = _amount; address _to; for (uint256 i = 0; i < totalHolders - 1; i++) { _to = holders[i]; uint256 _amt = _amount.mul(MintSplitHolderRatios[i]).div(10000); remaining = remaining.sub(_amt); _mint(_to, _amt); } _to = holders[totalHolders - 1]; _mint(_to, remaining); //for the last holder in the list Proposals[_proposer] -= _amount; if (Proposals[_proposer] == 0) delete Proposals[_proposer]; return true; } }
Proposals[_proposer]>=_amount,"Over-approve mint amount not allowed"
291,315
Proposals[_proposer]>=_amount
null
/** *Submitted for verification at Etherscan.io on 2019-07-18 */ /** * Source Code first verified at https://etherscan.io on Sunday, April 28, 2019 (UTC) */ pragma solidity ^0.5.7; /** * @title ERC20 interface * @dev see https://eips.ethereum.org/EIPS/eip-20 */ interface IERC20 { 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); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); event Freeze(address indexed from, uint256 value); event Unfreeze(address indexed from, uint256 value); } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * https://eips.ethereum.org/EIPS/eip-20 * Originally based on code by FirstBlood: * https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol * * This implementation emits additional Approval events, allowing applications to reconstruct the allowance status for * all accounts just by listening to said events. Note that this isn't required by the specification, and other * compliant implementations may not do it. */ contract ERC20 is IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowed; mapping (address => uint256) private _freezeOf; uint256 private _totalSupply; /** * @dev Total number of tokens in existence. */ function totalSupply() public view returns (uint256) { } /** * @dev Gets the balance of the specified address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the passed address. */ function balanceOf(address owner) public view returns (uint256) { } /** * @dev Gets the balance of the specified freeze address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the freeze address. */ function freezeOf(address owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param owner address The address which owns the funds. * @param spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address owner, address spender) public view returns (uint256) { } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred. */ function transfer(address to, uint256 value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param spender The address which will spend the funds. * @param value The amount of tokens to be spent. */ function approve(address spender, uint256 value) public returns (bool) { } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred */ function transferFrom(address from, address to, uint256 value) public returns (bool) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param addedValue The amount of tokens to increase the allowance by. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } /** * @dev Transfer token for a specified addresses. * @param from The address to transfer from. * @param to The address to transfer to. * @param value The amount to be transferred. */ function _transfer(address from, address to, uint256 value) internal { } /** * @dev Internal 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 { } /** * @dev Internal function that burns an amount of the token of a given * account. * @param account The account whose tokens will be burnt. * @param value The amount that will be burnt. */ function _burn(address account, uint256 value) internal { } function _freeze(uint256 value) internal { } function _unfreeze(uint256 value) internal{ require(<FILL_ME>) require(value > 0); _freezeOf[msg.sender] = _freezeOf[msg.sender].sub(value); _balances[msg.sender] = _balances[msg.sender].add(value); emit Unfreeze(msg.sender, value); } /** * @dev Approve an address to spend another addresses' tokens. * @param owner The address that owns the tokens. * @param spender The address that will spend the tokens. * @param value The number of tokens that can be spent. */ function _approve(address owner, address spender, uint256 value) internal { } } /** * @title ERC20Detailed token * @dev The decimals are only for visualization purposes. * All the operations are done using the smallest and indivisible token unit, * just as on Ethereum all the operations are done in wei. */ contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor (string memory name, string memory symbol, uint8 decimals) public { } /** * @return the name of the token. */ function name() public view returns (string memory) { } /** * @return the symbol of the token. */ function symbol() public view returns (string memory) { } /** * @return the number of decimals of the token. */ function decimals() public view returns (uint8) { } } /** * @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 { } /** * @dev Remove an account's access to this role. */ function remove(Role storage role, address account) internal { } /** * @dev Check if an account has this role. * @return bool */ function has(Role storage role, address account) internal view returns (bool) { } } contract PauserRole { using Roles for Roles.Role; event PauserAdded(address indexed account); event PauserRemoved(address indexed account); Roles.Role private _pausers; constructor () internal { } modifier onlyPauser() { } function isPauser(address account) public view returns (bool) { } function addPauser(address account) public onlyPauser { } function renouncePauser() public { } function _addPauser(address account) internal { } function _removePauser(address account) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is PauserRole { event Paused(address account); event Unpaused(address account); bool private _paused; constructor () internal { } /** * @return True if the contract is paused, false otherwise. */ function paused() public view returns (bool) { } /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev Called by a pauser to pause, triggers stopped state. */ function pause() public onlyPauser whenNotPaused { } /** * @dev Called by a pauser to unpause, returns to normal state. */ function unpause() public onlyPauser whenPaused { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Lockable is PauserRole{ mapping (address => bool) private lockers; event LockAccount(address account, bool islock); /** * @dev Check if the account is locked. * @param account specific account address. */ function isLock(address account) public view returns (bool) { } /** * @dev Lock or thaw account address * @param account specific account address. * @param islock true lock, false thaw. */ function lock(address account, bool islock) public onlyPauser { } } /** * @title Pausable token * @dev ERC20 modified with pausable transfers. */ contract ERC20Pausable is ERC20, Pausable,Lockable { function transfer(address to, uint256 value) public whenNotPaused returns (bool) { } function transferFrom(address from, address to, uint256 value) public whenNotPaused returns (bool) { } function approve(address spender, uint256 value) public whenNotPaused returns (bool) { } function increaseAllowance(address spender, uint addedValue) public whenNotPaused returns (bool) { } function decreaseAllowance(address spender, uint subtractedValue) public whenNotPaused returns (bool) { } } contract DeFiMingLP is ERC20, ERC20Detailed, ERC20Pausable { // metadata string public constant tokenName = "DeFiMingLP"; string public constant tokenSymbol = "DFMLP "; uint8 public constant decimalUnits = 8; uint256 public constant initialSupply = 11000000; constructor() ERC20Pausable() ERC20Detailed(tokenName, tokenSymbol, decimalUnits) ERC20() public { } function mint(uint256 value) public whenNotPaused { } /** * @dev Burns a specific amount of tokens. * @param value The amount of token to be burned. */ function burn(uint256 value) public whenNotPaused { } /** * @dev Freeze a specific amount of tokens. * @param value The amount of token to be Freeze. */ function freeze(uint256 value) public whenNotPaused { } /** * @dev unFreeze a specific amount of tokens. * @param value The amount of token to be unFreeze. */ function unfreeze(uint256 value) public whenNotPaused { } }
_freezeOf[msg.sender]>=value
291,318
_freezeOf[msg.sender]>=value
null
/** *Submitted for verification at Etherscan.io on 2019-07-18 */ /** * Source Code first verified at https://etherscan.io on Sunday, April 28, 2019 (UTC) */ pragma solidity ^0.5.7; /** * @title ERC20 interface * @dev see https://eips.ethereum.org/EIPS/eip-20 */ interface IERC20 { 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); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); event Freeze(address indexed from, uint256 value); event Unfreeze(address indexed from, uint256 value); } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * https://eips.ethereum.org/EIPS/eip-20 * Originally based on code by FirstBlood: * https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol * * This implementation emits additional Approval events, allowing applications to reconstruct the allowance status for * all accounts just by listening to said events. Note that this isn't required by the specification, and other * compliant implementations may not do it. */ contract ERC20 is IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowed; mapping (address => uint256) private _freezeOf; uint256 private _totalSupply; /** * @dev Total number of tokens in existence. */ function totalSupply() public view returns (uint256) { } /** * @dev Gets the balance of the specified address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the passed address. */ function balanceOf(address owner) public view returns (uint256) { } /** * @dev Gets the balance of the specified freeze address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the freeze address. */ function freezeOf(address owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param owner address The address which owns the funds. * @param spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address owner, address spender) public view returns (uint256) { } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred. */ function transfer(address to, uint256 value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param spender The address which will spend the funds. * @param value The amount of tokens to be spent. */ function approve(address spender, uint256 value) public returns (bool) { } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred */ function transferFrom(address from, address to, uint256 value) public returns (bool) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param addedValue The amount of tokens to increase the allowance by. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } /** * @dev Transfer token for a specified addresses. * @param from The address to transfer from. * @param to The address to transfer to. * @param value The amount to be transferred. */ function _transfer(address from, address to, uint256 value) internal { } /** * @dev Internal 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 { } /** * @dev Internal function that burns an amount of the token of a given * account. * @param account The account whose tokens will be burnt. * @param value The amount that will be burnt. */ function _burn(address account, uint256 value) internal { } function _freeze(uint256 value) internal { } function _unfreeze(uint256 value) internal{ } /** * @dev Approve an address to spend another addresses' tokens. * @param owner The address that owns the tokens. * @param spender The address that will spend the tokens. * @param value The number of tokens that can be spent. */ function _approve(address owner, address spender, uint256 value) internal { } } /** * @title ERC20Detailed token * @dev The decimals are only for visualization purposes. * All the operations are done using the smallest and indivisible token unit, * just as on Ethereum all the operations are done in wei. */ contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor (string memory name, string memory symbol, uint8 decimals) public { } /** * @return the name of the token. */ function name() public view returns (string memory) { } /** * @return the symbol of the token. */ function symbol() public view returns (string memory) { } /** * @return the number of decimals of the token. */ function decimals() public view returns (uint8) { } } /** * @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 { } /** * @dev Remove an account's access to this role. */ function remove(Role storage role, address account) internal { } /** * @dev Check if an account has this role. * @return bool */ function has(Role storage role, address account) internal view returns (bool) { } } contract PauserRole { using Roles for Roles.Role; event PauserAdded(address indexed account); event PauserRemoved(address indexed account); Roles.Role private _pausers; constructor () internal { } modifier onlyPauser() { } function isPauser(address account) public view returns (bool) { } function addPauser(address account) public onlyPauser { } function renouncePauser() public { } function _addPauser(address account) internal { } function _removePauser(address account) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is PauserRole { event Paused(address account); event Unpaused(address account); bool private _paused; constructor () internal { } /** * @return True if the contract is paused, false otherwise. */ function paused() public view returns (bool) { } /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev Called by a pauser to pause, triggers stopped state. */ function pause() public onlyPauser whenNotPaused { } /** * @dev Called by a pauser to unpause, returns to normal state. */ function unpause() public onlyPauser whenPaused { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Lockable is PauserRole{ mapping (address => bool) private lockers; event LockAccount(address account, bool islock); /** * @dev Check if the account is locked. * @param account specific account address. */ function isLock(address account) public view returns (bool) { } /** * @dev Lock or thaw account address * @param account specific account address. * @param islock true lock, false thaw. */ function lock(address account, bool islock) public onlyPauser { } } /** * @title Pausable token * @dev ERC20 modified with pausable transfers. */ contract ERC20Pausable is ERC20, Pausable,Lockable { function transfer(address to, uint256 value) public whenNotPaused returns (bool) { require(<FILL_ME>) require(!isLock(to)); return super.transfer(to, value); } function transferFrom(address from, address to, uint256 value) public whenNotPaused returns (bool) { } function approve(address spender, uint256 value) public whenNotPaused returns (bool) { } function increaseAllowance(address spender, uint addedValue) public whenNotPaused returns (bool) { } function decreaseAllowance(address spender, uint subtractedValue) public whenNotPaused returns (bool) { } } contract DeFiMingLP is ERC20, ERC20Detailed, ERC20Pausable { // metadata string public constant tokenName = "DeFiMingLP"; string public constant tokenSymbol = "DFMLP "; uint8 public constant decimalUnits = 8; uint256 public constant initialSupply = 11000000; constructor() ERC20Pausable() ERC20Detailed(tokenName, tokenSymbol, decimalUnits) ERC20() public { } function mint(uint256 value) public whenNotPaused { } /** * @dev Burns a specific amount of tokens. * @param value The amount of token to be burned. */ function burn(uint256 value) public whenNotPaused { } /** * @dev Freeze a specific amount of tokens. * @param value The amount of token to be Freeze. */ function freeze(uint256 value) public whenNotPaused { } /** * @dev unFreeze a specific amount of tokens. * @param value The amount of token to be unFreeze. */ function unfreeze(uint256 value) public whenNotPaused { } }
!isLock(msg.sender)
291,318
!isLock(msg.sender)
null
/** *Submitted for verification at Etherscan.io on 2019-07-18 */ /** * Source Code first verified at https://etherscan.io on Sunday, April 28, 2019 (UTC) */ pragma solidity ^0.5.7; /** * @title ERC20 interface * @dev see https://eips.ethereum.org/EIPS/eip-20 */ interface IERC20 { 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); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); event Freeze(address indexed from, uint256 value); event Unfreeze(address indexed from, uint256 value); } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * https://eips.ethereum.org/EIPS/eip-20 * Originally based on code by FirstBlood: * https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol * * This implementation emits additional Approval events, allowing applications to reconstruct the allowance status for * all accounts just by listening to said events. Note that this isn't required by the specification, and other * compliant implementations may not do it. */ contract ERC20 is IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowed; mapping (address => uint256) private _freezeOf; uint256 private _totalSupply; /** * @dev Total number of tokens in existence. */ function totalSupply() public view returns (uint256) { } /** * @dev Gets the balance of the specified address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the passed address. */ function balanceOf(address owner) public view returns (uint256) { } /** * @dev Gets the balance of the specified freeze address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the freeze address. */ function freezeOf(address owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param owner address The address which owns the funds. * @param spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address owner, address spender) public view returns (uint256) { } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred. */ function transfer(address to, uint256 value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param spender The address which will spend the funds. * @param value The amount of tokens to be spent. */ function approve(address spender, uint256 value) public returns (bool) { } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred */ function transferFrom(address from, address to, uint256 value) public returns (bool) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param addedValue The amount of tokens to increase the allowance by. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } /** * @dev Transfer token for a specified addresses. * @param from The address to transfer from. * @param to The address to transfer to. * @param value The amount to be transferred. */ function _transfer(address from, address to, uint256 value) internal { } /** * @dev Internal 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 { } /** * @dev Internal function that burns an amount of the token of a given * account. * @param account The account whose tokens will be burnt. * @param value The amount that will be burnt. */ function _burn(address account, uint256 value) internal { } function _freeze(uint256 value) internal { } function _unfreeze(uint256 value) internal{ } /** * @dev Approve an address to spend another addresses' tokens. * @param owner The address that owns the tokens. * @param spender The address that will spend the tokens. * @param value The number of tokens that can be spent. */ function _approve(address owner, address spender, uint256 value) internal { } } /** * @title ERC20Detailed token * @dev The decimals are only for visualization purposes. * All the operations are done using the smallest and indivisible token unit, * just as on Ethereum all the operations are done in wei. */ contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor (string memory name, string memory symbol, uint8 decimals) public { } /** * @return the name of the token. */ function name() public view returns (string memory) { } /** * @return the symbol of the token. */ function symbol() public view returns (string memory) { } /** * @return the number of decimals of the token. */ function decimals() public view returns (uint8) { } } /** * @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 { } /** * @dev Remove an account's access to this role. */ function remove(Role storage role, address account) internal { } /** * @dev Check if an account has this role. * @return bool */ function has(Role storage role, address account) internal view returns (bool) { } } contract PauserRole { using Roles for Roles.Role; event PauserAdded(address indexed account); event PauserRemoved(address indexed account); Roles.Role private _pausers; constructor () internal { } modifier onlyPauser() { } function isPauser(address account) public view returns (bool) { } function addPauser(address account) public onlyPauser { } function renouncePauser() public { } function _addPauser(address account) internal { } function _removePauser(address account) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is PauserRole { event Paused(address account); event Unpaused(address account); bool private _paused; constructor () internal { } /** * @return True if the contract is paused, false otherwise. */ function paused() public view returns (bool) { } /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev Called by a pauser to pause, triggers stopped state. */ function pause() public onlyPauser whenNotPaused { } /** * @dev Called by a pauser to unpause, returns to normal state. */ function unpause() public onlyPauser whenPaused { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Lockable is PauserRole{ mapping (address => bool) private lockers; event LockAccount(address account, bool islock); /** * @dev Check if the account is locked. * @param account specific account address. */ function isLock(address account) public view returns (bool) { } /** * @dev Lock or thaw account address * @param account specific account address. * @param islock true lock, false thaw. */ function lock(address account, bool islock) public onlyPauser { } } /** * @title Pausable token * @dev ERC20 modified with pausable transfers. */ contract ERC20Pausable is ERC20, Pausable,Lockable { function transfer(address to, uint256 value) public whenNotPaused returns (bool) { require(!isLock(msg.sender)); require(<FILL_ME>) return super.transfer(to, value); } function transferFrom(address from, address to, uint256 value) public whenNotPaused returns (bool) { } function approve(address spender, uint256 value) public whenNotPaused returns (bool) { } function increaseAllowance(address spender, uint addedValue) public whenNotPaused returns (bool) { } function decreaseAllowance(address spender, uint subtractedValue) public whenNotPaused returns (bool) { } } contract DeFiMingLP is ERC20, ERC20Detailed, ERC20Pausable { // metadata string public constant tokenName = "DeFiMingLP"; string public constant tokenSymbol = "DFMLP "; uint8 public constant decimalUnits = 8; uint256 public constant initialSupply = 11000000; constructor() ERC20Pausable() ERC20Detailed(tokenName, tokenSymbol, decimalUnits) ERC20() public { } function mint(uint256 value) public whenNotPaused { } /** * @dev Burns a specific amount of tokens. * @param value The amount of token to be burned. */ function burn(uint256 value) public whenNotPaused { } /** * @dev Freeze a specific amount of tokens. * @param value The amount of token to be Freeze. */ function freeze(uint256 value) public whenNotPaused { } /** * @dev unFreeze a specific amount of tokens. * @param value The amount of token to be unFreeze. */ function unfreeze(uint256 value) public whenNotPaused { } }
!isLock(to)
291,318
!isLock(to)
null
/** *Submitted for verification at Etherscan.io on 2019-07-18 */ /** * Source Code first verified at https://etherscan.io on Sunday, April 28, 2019 (UTC) */ pragma solidity ^0.5.7; /** * @title ERC20 interface * @dev see https://eips.ethereum.org/EIPS/eip-20 */ interface IERC20 { 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); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); event Freeze(address indexed from, uint256 value); event Unfreeze(address indexed from, uint256 value); } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * https://eips.ethereum.org/EIPS/eip-20 * Originally based on code by FirstBlood: * https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol * * This implementation emits additional Approval events, allowing applications to reconstruct the allowance status for * all accounts just by listening to said events. Note that this isn't required by the specification, and other * compliant implementations may not do it. */ contract ERC20 is IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowed; mapping (address => uint256) private _freezeOf; uint256 private _totalSupply; /** * @dev Total number of tokens in existence. */ function totalSupply() public view returns (uint256) { } /** * @dev Gets the balance of the specified address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the passed address. */ function balanceOf(address owner) public view returns (uint256) { } /** * @dev Gets the balance of the specified freeze address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the freeze address. */ function freezeOf(address owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param owner address The address which owns the funds. * @param spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address owner, address spender) public view returns (uint256) { } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred. */ function transfer(address to, uint256 value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param spender The address which will spend the funds. * @param value The amount of tokens to be spent. */ function approve(address spender, uint256 value) public returns (bool) { } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred */ function transferFrom(address from, address to, uint256 value) public returns (bool) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param addedValue The amount of tokens to increase the allowance by. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } /** * @dev Transfer token for a specified addresses. * @param from The address to transfer from. * @param to The address to transfer to. * @param value The amount to be transferred. */ function _transfer(address from, address to, uint256 value) internal { } /** * @dev Internal 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 { } /** * @dev Internal function that burns an amount of the token of a given * account. * @param account The account whose tokens will be burnt. * @param value The amount that will be burnt. */ function _burn(address account, uint256 value) internal { } function _freeze(uint256 value) internal { } function _unfreeze(uint256 value) internal{ } /** * @dev Approve an address to spend another addresses' tokens. * @param owner The address that owns the tokens. * @param spender The address that will spend the tokens. * @param value The number of tokens that can be spent. */ function _approve(address owner, address spender, uint256 value) internal { } } /** * @title ERC20Detailed token * @dev The decimals are only for visualization purposes. * All the operations are done using the smallest and indivisible token unit, * just as on Ethereum all the operations are done in wei. */ contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor (string memory name, string memory symbol, uint8 decimals) public { } /** * @return the name of the token. */ function name() public view returns (string memory) { } /** * @return the symbol of the token. */ function symbol() public view returns (string memory) { } /** * @return the number of decimals of the token. */ function decimals() public view returns (uint8) { } } /** * @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 { } /** * @dev Remove an account's access to this role. */ function remove(Role storage role, address account) internal { } /** * @dev Check if an account has this role. * @return bool */ function has(Role storage role, address account) internal view returns (bool) { } } contract PauserRole { using Roles for Roles.Role; event PauserAdded(address indexed account); event PauserRemoved(address indexed account); Roles.Role private _pausers; constructor () internal { } modifier onlyPauser() { } function isPauser(address account) public view returns (bool) { } function addPauser(address account) public onlyPauser { } function renouncePauser() public { } function _addPauser(address account) internal { } function _removePauser(address account) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is PauserRole { event Paused(address account); event Unpaused(address account); bool private _paused; constructor () internal { } /** * @return True if the contract is paused, false otherwise. */ function paused() public view returns (bool) { } /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev Called by a pauser to pause, triggers stopped state. */ function pause() public onlyPauser whenNotPaused { } /** * @dev Called by a pauser to unpause, returns to normal state. */ function unpause() public onlyPauser whenPaused { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Lockable is PauserRole{ mapping (address => bool) private lockers; event LockAccount(address account, bool islock); /** * @dev Check if the account is locked. * @param account specific account address. */ function isLock(address account) public view returns (bool) { } /** * @dev Lock or thaw account address * @param account specific account address. * @param islock true lock, false thaw. */ function lock(address account, bool islock) public onlyPauser { } } /** * @title Pausable token * @dev ERC20 modified with pausable transfers. */ contract ERC20Pausable is ERC20, Pausable,Lockable { function transfer(address to, uint256 value) public whenNotPaused returns (bool) { } function transferFrom(address from, address to, uint256 value) public whenNotPaused returns (bool) { require(!isLock(msg.sender)); require(<FILL_ME>) require(!isLock(to)); return super.transferFrom(from, to, value); } function approve(address spender, uint256 value) public whenNotPaused returns (bool) { } function increaseAllowance(address spender, uint addedValue) public whenNotPaused returns (bool) { } function decreaseAllowance(address spender, uint subtractedValue) public whenNotPaused returns (bool) { } } contract DeFiMingLP is ERC20, ERC20Detailed, ERC20Pausable { // metadata string public constant tokenName = "DeFiMingLP"; string public constant tokenSymbol = "DFMLP "; uint8 public constant decimalUnits = 8; uint256 public constant initialSupply = 11000000; constructor() ERC20Pausable() ERC20Detailed(tokenName, tokenSymbol, decimalUnits) ERC20() public { } function mint(uint256 value) public whenNotPaused { } /** * @dev Burns a specific amount of tokens. * @param value The amount of token to be burned. */ function burn(uint256 value) public whenNotPaused { } /** * @dev Freeze a specific amount of tokens. * @param value The amount of token to be Freeze. */ function freeze(uint256 value) public whenNotPaused { } /** * @dev unFreeze a specific amount of tokens. * @param value The amount of token to be unFreeze. */ function unfreeze(uint256 value) public whenNotPaused { } }
!isLock(from)
291,318
!isLock(from)
null
/** *Submitted for verification at Etherscan.io on 2019-07-18 */ /** * Source Code first verified at https://etherscan.io on Sunday, April 28, 2019 (UTC) */ pragma solidity ^0.5.7; /** * @title ERC20 interface * @dev see https://eips.ethereum.org/EIPS/eip-20 */ interface IERC20 { 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); function totalSupply() external view returns (uint256); function balanceOf(address who) external view returns (uint256); function allowance(address owner, address spender) external view returns (uint256); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); event Freeze(address indexed from, uint256 value); event Unfreeze(address indexed from, uint256 value); } /** * @title SafeMath * @dev Unsigned math operations with safety checks that revert on error. */ library SafeMath { /** * @dev Multiplies two unsigned integers, reverts on overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend). */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Adds two unsigned integers, reverts on overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo), * reverts when dividing by zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @title Standard ERC20 token * * @dev Implementation of the basic standard token. * https://eips.ethereum.org/EIPS/eip-20 * Originally based on code by FirstBlood: * https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol * * This implementation emits additional Approval events, allowing applications to reconstruct the allowance status for * all accounts just by listening to said events. Note that this isn't required by the specification, and other * compliant implementations may not do it. */ contract ERC20 is IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowed; mapping (address => uint256) private _freezeOf; uint256 private _totalSupply; /** * @dev Total number of tokens in existence. */ function totalSupply() public view returns (uint256) { } /** * @dev Gets the balance of the specified address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the passed address. */ function balanceOf(address owner) public view returns (uint256) { } /** * @dev Gets the balance of the specified freeze address. * @param owner The address to query the balance of. * @return A uint256 representing the amount owned by the freeze address. */ function freezeOf(address owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param owner address The address which owns the funds. * @param spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address owner, address spender) public view returns (uint256) { } /** * @dev Transfer token to a specified address. * @param to The address to transfer to. * @param value The amount to be transferred. */ function transfer(address to, uint256 value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * @param spender The address which will spend the funds. * @param value The amount of tokens to be spent. */ function approve(address spender, uint256 value) public returns (bool) { } /** * @dev Transfer tokens from one address to another. * Note that while this function emits an Approval event, this is not required as per the specification, * and other compliant implementations may not emit the event. * @param from address The address which you want to send tokens from * @param to address The address which you want to transfer to * @param value uint256 the amount of tokens to be transferred */ function transferFrom(address from, address to, uint256 value) public returns (bool) { } /** * @dev Increase the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To increment * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param addedValue The amount of tokens to increase the allowance by. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { } /** * @dev Decrease the amount of tokens that an owner allowed to a spender. * approve should be called when _allowed[msg.sender][spender] == 0. To decrement * allowed value is better to use this function to avoid 2 calls (and wait until * the first transaction is mined) * From MonolithDAO Token.sol * Emits an Approval event. * @param spender The address which will spend the funds. * @param subtractedValue The amount of tokens to decrease the allowance by. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { } /** * @dev Transfer token for a specified addresses. * @param from The address to transfer from. * @param to The address to transfer to. * @param value The amount to be transferred. */ function _transfer(address from, address to, uint256 value) internal { } /** * @dev Internal 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 { } /** * @dev Internal function that burns an amount of the token of a given * account. * @param account The account whose tokens will be burnt. * @param value The amount that will be burnt. */ function _burn(address account, uint256 value) internal { } function _freeze(uint256 value) internal { } function _unfreeze(uint256 value) internal{ } /** * @dev Approve an address to spend another addresses' tokens. * @param owner The address that owns the tokens. * @param spender The address that will spend the tokens. * @param value The number of tokens that can be spent. */ function _approve(address owner, address spender, uint256 value) internal { } } /** * @title ERC20Detailed token * @dev The decimals are only for visualization purposes. * All the operations are done using the smallest and indivisible token unit, * just as on Ethereum all the operations are done in wei. */ contract ERC20Detailed is IERC20 { string private _name; string private _symbol; uint8 private _decimals; constructor (string memory name, string memory symbol, uint8 decimals) public { } /** * @return the name of the token. */ function name() public view returns (string memory) { } /** * @return the symbol of the token. */ function symbol() public view returns (string memory) { } /** * @return the number of decimals of the token. */ function decimals() public view returns (uint8) { } } /** * @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 { } /** * @dev Remove an account's access to this role. */ function remove(Role storage role, address account) internal { } /** * @dev Check if an account has this role. * @return bool */ function has(Role storage role, address account) internal view returns (bool) { } } contract PauserRole { using Roles for Roles.Role; event PauserAdded(address indexed account); event PauserRemoved(address indexed account); Roles.Role private _pausers; constructor () internal { } modifier onlyPauser() { } function isPauser(address account) public view returns (bool) { } function addPauser(address account) public onlyPauser { } function renouncePauser() public { } function _addPauser(address account) internal { } function _removePauser(address account) internal { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Pausable is PauserRole { event Paused(address account); event Unpaused(address account); bool private _paused; constructor () internal { } /** * @return True if the contract is paused, false otherwise. */ function paused() public view returns (bool) { } /** * @dev Modifier to make a function callable only when the contract is not paused. */ modifier whenNotPaused() { } /** * @dev Modifier to make a function callable only when the contract is paused. */ modifier whenPaused() { } /** * @dev Called by a pauser to pause, triggers stopped state. */ function pause() public onlyPauser whenNotPaused { } /** * @dev Called by a pauser to unpause, returns to normal state. */ function unpause() public onlyPauser whenPaused { } } /** * @title Pausable * @dev Base contract which allows children to implement an emergency stop mechanism. */ contract Lockable is PauserRole{ mapping (address => bool) private lockers; event LockAccount(address account, bool islock); /** * @dev Check if the account is locked. * @param account specific account address. */ function isLock(address account) public view returns (bool) { } /** * @dev Lock or thaw account address * @param account specific account address. * @param islock true lock, false thaw. */ function lock(address account, bool islock) public onlyPauser { } } /** * @title Pausable token * @dev ERC20 modified with pausable transfers. */ contract ERC20Pausable is ERC20, Pausable,Lockable { function transfer(address to, uint256 value) public whenNotPaused returns (bool) { } function transferFrom(address from, address to, uint256 value) public whenNotPaused returns (bool) { } function approve(address spender, uint256 value) public whenNotPaused returns (bool) { require(!isLock(msg.sender)); require(<FILL_ME>) return super.approve(spender, value); } function increaseAllowance(address spender, uint addedValue) public whenNotPaused returns (bool) { } function decreaseAllowance(address spender, uint subtractedValue) public whenNotPaused returns (bool) { } } contract DeFiMingLP is ERC20, ERC20Detailed, ERC20Pausable { // metadata string public constant tokenName = "DeFiMingLP"; string public constant tokenSymbol = "DFMLP "; uint8 public constant decimalUnits = 8; uint256 public constant initialSupply = 11000000; constructor() ERC20Pausable() ERC20Detailed(tokenName, tokenSymbol, decimalUnits) ERC20() public { } function mint(uint256 value) public whenNotPaused { } /** * @dev Burns a specific amount of tokens. * @param value The amount of token to be burned. */ function burn(uint256 value) public whenNotPaused { } /** * @dev Freeze a specific amount of tokens. * @param value The amount of token to be Freeze. */ function freeze(uint256 value) public whenNotPaused { } /** * @dev unFreeze a specific amount of tokens. * @param value The amount of token to be unFreeze. */ function unfreeze(uint256 value) public whenNotPaused { } }
!isLock(spender)
291,318
!isLock(spender)
"CappedCrowdsale: cap exceeded"
pragma solidity >=0.5.0; contract TokenCrowdsale is Crowdsale, WhitelistCrowdsale, AllowanceCrowdsale, PausableCrowdsale, CappedCrowdsale, TimedCrowdsale { uint256 internal _minimum; uint256 internal _maximum; event LogTxEvent(address indexed _from, address indexed _to, uint256 _amount, string _data); constructor( uint256 _rate, address payable _wallet, IERC20 _token, uint256 _cap, uint256 _minCap, uint256 _maxCap, address _tokenWallet, uint256 _openingTime, uint256 _closingTime) public Crowdsale(_rate,_wallet,_token) AllowanceCrowdsale(_tokenWallet) CappedCrowdsale(_cap) TimedCrowdsale(_openingTime,_closingTime) { } /** * @dev returns the number of minimum purchase. */ function minCap() public view returns (uint256) { } /** * @dev returns the number of maximum purchase. */ function maxCap() public view returns (uint256) { } /** * @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(<FILL_ME>) super._preValidatePurchase(beneficiary, weiAmount); uint256 existingContribution = token().balanceOf(beneficiary); uint256 newContribution = existingContribution.add(weiAmount); require(newContribution >= _minimum, "Minimum of 1 ETH per investor"); require(newContribution <= _maximum,"Max number of token per client reached"); } }
weiRaised().add(weiAmount)<=cap(),"CappedCrowdsale: cap exceeded"
291,360
weiRaised().add(weiAmount)<=cap()
"The contract is already quarantined"
pragma solidity 0.5.11; /** * @notice Provides a way to quarantine (disable) contracts for a specified period of time * @dev The immunitiesRemaining member allows deployment to the platform with some * pre-verified contracts that don't get quarantined */ library Quarantine { struct Data { mapping(address => uint256) store; uint256 quarantinePeriod; uint256 immunitiesRemaining; } /** * @notice Checks whether a contract is quarantined */ function isQuarantined(Data storage _self, address _contractAddress) internal view returns (bool) { } /** * @notice Places a contract into quarantine * @param _contractAddress The address of the contract */ function quarantine(Data storage _self, address _contractAddress) internal { require(_contractAddress != address(0), "An empty address cannot be quarantined"); require(<FILL_ME>) if (_self.immunitiesRemaining == 0) { _self.store[_contractAddress] = block.timestamp + _self.quarantinePeriod; } else { _self.immunitiesRemaining--; } } }
_self.store[_contractAddress]==0,"The contract is already quarantined"
291,373
_self.store[_contractAddress]==0
"Deposit too large."
contract StrategyConvexRocketpool is StrategyConvexBase { /* ========== STATE VARIABLES ========== */ // these will likely change across different wants. // Curve stuff ICurveFi public constant curve = ICurveFi(0x447Ddd4960d9fdBF6af9a790560d0AF76795CB08); // This is our pool specific to this vault. bool public checkEarmark; // this determines if we should check if we need to earmark rewards before harvesting bool public mintReth; // use this to determine if we are depositing wsteth or reth to our curve pool (we mint both directly from ETH) // use Curve to sell our CVX and CRV rewards to WETH ICurveFi internal constant crveth = ICurveFi(0x8301AE4fc9c624d1D396cbDAa1ed877821D7C511); // use curve's new CRV-ETH crypto pool to sell our CRV ICurveFi internal constant cvxeth = ICurveFi(0xB576491F1E6e5E62f1d8F26062Ee822B40B0E0d4); // use curve's new CVX-ETH crypto pool to sell our CVX // stETH and rETH token contracts IstETH internal constant steth = IstETH(0xae7ab96520DE3A18E5e111B5EaAb095312D7fE84); IwstETH internal constant wsteth = IwstETH(0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0); IERC20 internal constant reth = IERC20(0xae78736Cd615f374D3085123A210448E74Fc6393); // rocketpool helper contract IRocketPoolHelper public constant rocketPoolHelper = IRocketPoolHelper(0x5943910C2e88480584092C7B95A3FD762cAbc699); address internal referral = 0xD20Eb2390e675b000ADb8511F62B28404115A1a4; // referral address, use EOA to claim on L2 uint256 public lastTendTime; // this is the timestamp that our last tend was called /* ========== CONSTRUCTOR ========== */ constructor( address _vault, uint256 _pid, string memory _name ) public StrategyConvexBase(_vault) { } /* ========== VARIABLE FUNCTIONS ========== */ // these will likely change across different wants. function prepareReturn(uint256 _debtOutstanding) internal override returns ( uint256 _profit, uint256 _loss, uint256 _debtPayment ) { } function adjustPosition(uint256 _debtOutstanding) internal override { } // Sells our CRV and CVX for ETH on Curve function _sellCrvAndCvx(uint256 _crvAmount, uint256 _convexAmount) internal returns (uint256 ethBalance) { } // mint wstETH from ETH function mintWsteth(uint256 _amount) internal { } // claim and swap our CRV and CVX for rETH function claimAndMintReth() internal { // this claims our CRV, CVX, and any extra tokens. rewardsContract.getReward(address(this), true); uint256 crvBalance = crv.balanceOf(address(this)); uint256 convexBalance = convexToken.balanceOf(address(this)); uint256 sendToVoter = crvBalance.mul(keepCRV).div(FEE_DENOMINATOR); if (sendToVoter > 0) { crv.safeTransfer(voter, sendToVoter); } uint256 crvRemainder = crv.balanceOf(address(this)); // sell the rest of our CRV and our CVX for ETH uint256 toDeposit = _sellCrvAndCvx(crvRemainder, convexBalance); // deposit our rETH only if there's space, and if it's large enough. this will prevent keepers from tending as well if needed. require(<FILL_ME>) require( toDeposit > rocketPoolHelper.getMinimumDepositSize(), "Deposit too small." ); // pull our most recent deposit contract address since it can be upgraded IRocketPoolDeposit rocketDepositPool = IRocketPoolDeposit(rocketPoolHelper.getRocketDepositPoolAddress()); rocketDepositPool.deposit{value: toDeposit}(); } // migrate our want token to a new strategy if needed, make sure to check claimRewards first // also send over any CRV or CVX that is claimed; for migrations we definitely want to claim function prepareMigration(address _newStrategy) internal override { } /* ========== KEEP3RS ========== */ // use this to determine when to harvest function harvestTrigger(uint256 callCostinEth) public view override returns (bool) { } function tendTrigger(uint256 callCostinEth) public view override returns (bool) { } // we will need to add rewards token here if we have them function claimableProfitInUsdt() internal view returns (uint256) { } // convert our keeper's eth cost into want, we don't need this anymore since we don't use baseStrategy harvestTrigger function ethToWant(uint256 _ethAmount) public view override returns (uint256) { } // check if the current baseFee is below our external target function isBaseFeeAcceptable() internal view returns (bool) { } // this contains logic to check if it's been long enough since we minted our rETH to move it function isRethFree() public view returns (bool) { } // check if someone needs to earmark rewards on convex before keepers harvest again function needsEarmarkReward() public view returns (bool needsEarmark) { } // include so our contract plays nicely with ether receive() external payable {} function sweepETH() public onlyGovernance { } /* ========== SETTERS ========== */ // These functions are useful for setting parameters of the strategy that may need to be adjusted. // Set whether we mint rETH or wstETH function setMintReth(bool _mintReth) external onlyVaultManagers { } // Min profit to start checking for harvests if gas is good, max will harvest no matter gas (both in USDT, 6 decimals). Credit threshold is in want token, and will trigger a harvest if credit is large enough. check earmark to look at convex's booster. function setHarvestTriggerParams( uint256 _harvestProfitMin, uint256 _harvestProfitMax, uint256 _creditThreshold, bool _checkEarmark ) external onlyVaultManagers { } // update our referral address as needed function setReferral(address _referral) external onlyVaultManagers { } }
rocketPoolHelper.rEthCanAcceptDeposit(toDeposit),"Deposit too large."
291,417
rocketPoolHelper.rEthCanAcceptDeposit(toDeposit)
"JellyFactory: Sender must be minter if locked"
pragma solidity 0.8.6; import "IBentoBoxFactory.sol"; import "IJellyContract.sol"; import "IERC20.sol"; import "BoringMath.sol"; import "JellyAccessControls.sol"; /** * @title Jelly Factory: * * ,,,, * g@@@@@@K * l@@@@@@@@P * $@@@@@@@" l@@@ l@@@ * "*NNM" l@@@ l@@@ * l@@@ l@@@ * ,g@@@g ,,gg@gg, l@@@ l@@@ ,ggg ,ggg * @@@@@@@@p g@@@EEEEE@@W l@@@ l@@@ $@@@ ,@@@Y * l@@@@@@@@@ @@@P ]@@@ l@@@ l@@@ $@@g ,@@@Y * l@@@@@@@@@ $@@D,,,,,,,,]@@@ l@@@ l@@@ '@@@p @@@Y * l@@@@@@@@@ @@@@EEEEEEEEEEEE l@@@ l@@@ "@@@p @@@Y * l@@@@@@@@@ l@@K l@@@ l@@@ '@@@, @@@Y * @@@@@@@@@ %@@@, ,g@@@ l@@@ l@@@ ^@@@@@@Y * "@@@@@@@@ "N@@@@@@@@E* l@@@ l@@@ "*@@@Y * "J@@@@@@ "**"" ''' ''' @@@Y * ,gg@@g "J@@@P @@@Y * @@@@@@@@p J@@' @@@Y * @@@@@@@@P J@h RNNY * 'B@@@@@@ $P * "JE@@@p"' * * */ /** * @author ProfWobble * @dev * - Generalised smart contract template factory * - Supports contracts with the IJellyContract interface * - Fees can be set at the template level. * */ contract JellyFactory { using BoringMath for uint256; using BoringMath128 for uint128; using BoringMath64 for uint64; /// @notice Responsible for access rights to the contract. JellyAccessControls public accessControls; /// PW: Give people the chance to use Spell factory, or a whitelist of bentoboxes. IBentoBoxFactory public bentoBox; bytes32 public constant CONTRACT_MINTER_ROLE = keccak256("CONTRACT_MINTER_ROLE"); /// @notice Struct to track Contract template. struct Contract { bool active; uint64 templateType; uint64 contractIndex; bytes32 templateId; } /// @notice Mapping from contract created through this contract to Contract struct. mapping(address => Contract) public contractInfo; /// @notice Contracts created using factory. address[] public contracts; /// @notice Struct to track Contract template. struct Template { uint64 currentTemplateId; uint128 minimumFee; uint32 integratorFeePct; bool locked; address feeAddress; uint64[] contractIds; } // /// @notice mapping from template type to template id mapping(bytes32 => Template) public templateInfo; /// @notice Template id to track respective contract template. uint256 public contractTemplateCount; /// @notice Mapping from template id to contract template mapping(bytes32 => address) private contractTemplates; ///@notice Any donations if set are sent here. address payable public jellyWallet; /// @notice New JellyFactory address. address public newAddress; /// @notice Event emitted when template is added to factory. event ContractTemplateAdded(address newContract, bytes32 templateId); /// @notice Event emitted when contract template is removed. event ContractTemplateRemoved(address contractAddr, bytes32 templateId); /// @notice Event emitted when contract is created using template id. event ContractCreated(address indexed owner, address indexed addr, address contractTemplate); /// @notice Event emitted when factory is deprecated. event FactoryDeprecated(address newAddress); /// @notice Event emitted when tokens are recovered. event Recovered(address indexed token, uint256 amount); /// @notice Event emitted when template fee changes. event SetFee(bytes32 indexed templateId, uint256 amount); /// @notice Event emitted when templates are locked. event SetLock(bytes32 indexed templateId, bool lock); /** * @notice Initializes the factory. * @param _accessControls Sets address to get the access controls from. */ constructor(address _accessControls, address _bentoBox) { } /** * @notice Sets the minimum fee. * @param _amount Fee amount. */ function setMinimumFee(bytes32 _templateId, uint256 _amount) external { } /** * @notice Sets the minimum fee. * @param _amount Fee amount. */ function setIntegratorFeePct(bytes32 _templateId, uint256 _amount) external { } /** * @notice Sets the factory to be locked or unlocked. * @param _locked bool. */ function setLocked(bytes32 _templateId, bool _locked) external { } /** * @notice Sets dividend address. * @param _wallet Dividend address. */ function setWallet(address payable _wallet) external { } /** * @notice Sets Bentobox address. * @param _bentoBox Bentobox address. */ function setBentoBox(address payable _bentoBox) external { } /** * @notice Sets the current template ID for any type. * @param _templateId ID of template. * @param _feeAddr The address fees are denominated. */ function setTemplateFeeAddr(bytes32 _templateId, address _feeAddr) external { } /** * @notice Used to check whether an address has the minter role * @param _address EOA or contract being checked * @return bool True if the account has the role or false if it does not */ function hasContractMinterRole(address _address) public view returns (bool) { } /** * @notice Used to get array indexes for a template ID * @param _templateId Template ID being checked */ function getContractIds(bytes32 _templateId) public view returns (uint64[] memory) { } /** * @notice Creates a new contract cloned from template. * @param _templateId Id of the template to create. * @param _integratorFeeAccount Address to pay the fee to. * @return newContract Contract address. */ function deployContract( bytes32 _templateId, address payable _integratorFeeAccount, bytes calldata _data ) external payable returns (address newContract) { } /** * @notice Creates a new JellyFactory from template using CREATE2. * @param _templateId Id of the template to create. * @param _integratorFeeAccount Address to pay the fee to. * @return newContract Contract address. */ function deploy2Contract( bytes32 _templateId, address payable _integratorFeeAccount, bytes calldata _data ) external payable returns (address newContract) { } /** * @notice Creates a new JellyFactory from template _templateId and transfers fees. * @param _templateId Id of the template to create. * @param _integratorFeeAccount Address to pay the fee to. * @return newContract Contract address. */ function _deployContract( bytes32 _templateId, address payable _integratorFeeAccount, bytes calldata _data, bool _useCreate2 ) internal returns (address newContract) { Template memory template = templateInfo[_templateId]; /// @dev If the contract is locked, only admin and minters can deploy. if (template.locked) { require(<FILL_ME>) } // PW: Convert this to erc20 transfers based on feeAddress address contractTemplate = contractTemplates[_templateId]; require(contractTemplate != address(0), "JellyFactory: Contract template doesn't exist"); require(msg.value >= uint256(template.minimumFee), "JellyFactory: Failed to transfer minimumFee"); uint256 integratorFee = 0; uint256 jellyFee = msg.value; if (_integratorFeeAccount != address(0) && _integratorFeeAccount != jellyWallet) { integratorFee = jellyFee * uint256(template.integratorFeePct) / 1000; jellyFee = jellyFee - integratorFee; } if (jellyFee > 0) { jellyWallet.transfer(jellyFee); } if (integratorFee > 0) { _integratorFeeAccount.transfer(integratorFee); } /// @dev Deploy using the BentoBox factory. newContract = bentoBox.deploy(contractTemplate, _data, _useCreate2); uint256 templateType = IJellyContract(newContract).TEMPLATE_TYPE(); uint64 contractCount = BoringMath.to64(contracts.length); contractInfo[address(newContract)] = Contract(true, BoringMath.to64(templateType), contractCount, _templateId); templateInfo[_templateId].contractIds.push(contractCount); contracts.push(address(newContract)); emit ContractCreated(msg.sender, address(newContract), contractTemplate); } /** * @notice Function to add an contract template to create through factory. * @dev Should have operator access. * @param _template Contract template to create an contract. */ function addContractTemplate(address _template) external { } /** * @dev Function to remove an contract template. * @dev Should have operator access. * @param _templateId Refers to template that is to be deleted. */ function removeContractTemplate(bytes32 _templateId) external { } /** * @notice Deprecates factory. * @param _newAddress Blank address. */ function deprecateFactory(address _newAddress) external { } /** * @notice Get the address based on template ID. * @param _templateId Contract template ID. * @return Address of the required template ID. */ function getContractTemplate(bytes32 _templateId) external view returns (address) { } /** * @notice Get the ID based on template address. * @param _contractTemplate Contract template address. * @return ID of the required template address. */ function getTemplateId(address _contractTemplate) external view returns (bytes32) { } /** * @notice Get contracts based on template ID. * @param _templateId Contract template ID. * @return Contracts with a specific template ID. */ function getContractsByTemplateId(bytes32 _templateId) external view returns (address[] memory) { } /** * @notice Get the total number of contracts in the factory. * @return Contract count. */ function numberOfDeployedContracts() external view returns (uint) { } function minimumFee(bytes32 _templateId) external view returns(uint128) { } function getContracts() external view returns(address[] memory) { } function getContractTemplateId(address _contract) external view returns(bytes32) { } // Token recovery receive () external payable { } /// @notice allows for the recovery of incorrect ERC20 tokens sent to contract function recoverERC20( address tokenAddress, uint256 tokenAmount ) external { } }
accessControls.hasAdminRole(msg.sender)||accessControls.hasMinterRole(msg.sender)||hasContractMinterRole(msg.sender),"JellyFactory: Sender must be minter if locked"
291,554
accessControls.hasAdminRole(msg.sender)||accessControls.hasMinterRole(msg.sender)||hasContractMinterRole(msg.sender)
null
// SPDX-License-Identifier: Unlicensed pragma solidity ^0.8.4; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval( address indexed owner, address indexed spender, uint256 value ); } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); constructor() { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint256 amountIn, uint256 amountOutMin, address[] calldata path, address to, uint256 deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint256 amountTokenDesired, uint256 amountTokenMin, uint256 amountETHMin, address to, uint256 deadline ) external payable returns ( uint256 amountToken, uint256 amountETH, uint256 liquidity ); } contract EverBust is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "EverBust"; string private constant _symbol = "EBUST"; uint8 private constant _decimals = 9; // RFI mapping(address => uint256) private _rOwned; mapping(address => uint256) private _tOwned; mapping(address => mapping(address => uint256)) private _allowances; mapping(address => bool) private _isExcludedFromFee; uint256 private constant MAX = ~uint256(0); uint256 private constant _tTotal = 1000000000000 * 10**9; uint256 private _rTotal = (MAX - (MAX % _tTotal)); uint256 private _tFeeTotal; uint256 private _taxFee = 2; uint256 private _teamFee = 10; // Bot detection mapping(address => bool) private bots; mapping(address => uint256) private cooldown; address payable private _devFund; address payable private _marketingFunds; address payable private _buybackWalletAddress; IUniswapV2Router02 private uniswapV2Router; address private uniswapV2Pair; bool private tradingOpen; bool private inSwap = false; bool private swapEnabled = false; bool private cooldownEnabled = false; uint256 private _maxTxAmount = _tTotal; uint256 public launchBlock; event MaxTxAmountUpdated(uint256 _maxTxAmount); modifier lockTheSwap { } constructor(address payable devFundAddr, address payable marketingFundAddr, address payable buybackAddr) { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public pure override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function transferFrom( address sender, address recipient, uint256 amount ) public override returns (bool) { } function setCooldownEnabled(bool onoff) external onlyOwner() { } function tokenFromReflection(uint256 rAmount) private view returns (uint256) { } function removeAllFee() private { } function restoreAllFee() private { } function _approve( address owner, address spender, uint256 amount ) private { } function _transfer( address from, address to, uint256 amount ) private { } function isExcluded(address account) public view returns (bool) { } function isBlackListed(address account) public view returns (bool) { } function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHToFee(uint256 amount) private { } function openTrading() external onlyOwner() { } function manualswap() external { require(<FILL_ME>) uint256 contractBalance = balanceOf(address(this)); swapTokensForEth(contractBalance); } function manualsend() external { } function setBots(address[] memory bots_) public onlyOwner { } function delBot(address notbot) public onlyOwner { } function _tokenTransfer( address sender, address recipient, uint256 amount, bool takeFee ) private { } function _transferStandard( address sender, address recipient, uint256 tAmount ) private { } function _takeTeam(uint256 tTeam) private { } function _reflectFee(uint256 rFee, uint256 tFee) private { } receive() external payable {} function _getValues(uint256 tAmount) private view returns ( uint256, uint256, uint256, uint256, uint256, uint256 ) { } function _getTValues( uint256 tAmount, uint256 taxFee, uint256 TeamFee ) private pure returns ( uint256, uint256, uint256 ) { } function _getRValues( uint256 tAmount, uint256 tFee, uint256 tTeam, uint256 currentRate ) private pure returns ( uint256, uint256, uint256 ) { } function _getRate() private view returns (uint256) { } function _getCurrentSupply() private view returns (uint256, uint256) { } function setMaxTxPercent(uint256 maxTxPercent) external onlyOwner() { } }
_msgSender()==_devFund
291,603
_msgSender()==_devFund
'VTableOwnership: caller is not the owner'
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; import '../VTable.sol'; contract VTableUpdateModule { using VTable for VTable.VTableStore; event VTableUpdate(bytes4 indexed selector, address oldImplementation, address newImplementation); struct ModuleDefinition { address implementation; bytes4[] selectors; } /** * @dev Updates the vtable */ function updateVTable(ModuleDefinition[] calldata modules) public { VTable.VTableStore storage vtable = VTable.instance(); require(<FILL_ME>) for (uint256 i = 0; i < modules.length; ++i) { ModuleDefinition memory module = modules[i]; for (uint256 j = 0; j < module.selectors.length; ++j) { vtable.setFunction(module.selectors[j], module.implementation); } } } }
VTable.instance().getOwner()==msg.sender,'VTableOwnership: caller is not the owner'
291,678
VTable.instance().getOwner()==msg.sender
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { require(<FILL_ME>) _; } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
authorized[msg.sender]||hotOwner==msg.sender
291,844
authorized[msg.sender]||hotOwner==msg.sender
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { require(_toAdd != address(0)); require(<FILL_ME>) authorized[_toAdd] = true; authorizedAddresses.push(_toAdd); emit AuthorityAdded(_toAdd); return true; } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!authorized[_toAdd]
291,844
!authorized[_toAdd]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { require(_toRemove != address(0)); require(<FILL_ME>) authorized[_toRemove] = false; authorizedAddresses[_toRemoveIndex] = authorizedAddresses[authorizedAddresses.length-1]; authorizedAddresses.pop(); emit AuthorityRemoved(_toRemove); return true; } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
authorized[_toRemove]
291,844
authorized[_toRemove]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ require(<FILL_ME>) require(_toBetalist != address(0)); require(!blacklisted[_toBetalist]); require(!betalisted[_toBetalist]); betalisted[_toBetalist]=true; emit BetalistedAddress(_toBetalist); return true; } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!emergencyFlag
291,844
!emergencyFlag
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_toBetalist != address(0)); require(<FILL_ME>) require(!betalisted[_toBetalist]); betalisted[_toBetalist]=true; emit BetalistedAddress(_toBetalist); return true; } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_toBetalist]
291,844
!blacklisted[_toBetalist]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_toBetalist != address(0)); require(!blacklisted[_toBetalist]); require(<FILL_ME>) betalisted[_toBetalist]=true; emit BetalistedAddress(_toBetalist); return true; } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!betalisted[_toBetalist]
291,844
!betalisted[_toBetalist]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_toRemoveBetalist != address(0)); require(<FILL_ME>) betalisted[_toRemoveBetalist]=false; emit RemovedFromBetalist(_toRemoveBetalist); return true; } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_toRemoveBetalist]
291,844
betalisted[_toRemoveBetalist]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_toBlacklist != address(0)); require(<FILL_ME>) blacklisted[_toBlacklist]=true; emit RemovedFromBlacklist(_toBlacklist); return true; } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_toBlacklist]
291,844
!blacklisted[_toBlacklist]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_toRemoveBlacklist != address(0)); require(<FILL_ME>) blacklisted[_toRemoveBlacklist]=false; emit RemovedFromBlacklist(_toRemoveBlacklist); return true; } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
blacklisted[_toRemoveBlacklist]
291,844
blacklisted[_toRemoveBlacklist]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { require(!emergencyFlag); require(_value <= balances[msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(<FILL_ME>) require(betalisted[msg.sender]); } require(!blacklisted[msg.sender]); require(!blacklisted[_to]); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); return true; } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_to]
291,844
betalisted[_to]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { require(!emergencyFlag); require(_value <= balances[msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(<FILL_ME>) } require(!blacklisted[msg.sender]); require(!blacklisted[_to]); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); return true; } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[msg.sender]
291,844
betalisted[msg.sender]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { require(!emergencyFlag); require(_value <= balances[msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(betalisted[msg.sender]); } require(<FILL_ME>) require(!blacklisted[_to]); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); return true; } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[msg.sender]
291,844
!blacklisted[msg.sender]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { require(!emergencyFlag); require(_value <= balances[msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(betalisted[msg.sender]); } require(!blacklisted[msg.sender]); require(<FILL_ME>) balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); return true; } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_to]
291,844
!blacklisted[_to]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { require(!emergencyFlag); if (requireBetalisted){ require(betalisted[msg.sender]); require(<FILL_ME>) } require(!blacklisted[msg.sender]); require(!blacklisted[_spender]); allowed[msg.sender][_spender] = _value; emit Approval(msg.sender, _spender, _value); return true; } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_spender]
291,844
betalisted[_spender]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { require(!emergencyFlag); if (requireBetalisted){ require(betalisted[msg.sender]); require(betalisted[_spender]); } require(!blacklisted[msg.sender]); require(<FILL_ME>) allowed[msg.sender][_spender] = _value; emit Approval(msg.sender, _spender, _value); return true; } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_spender]
291,844
!blacklisted[_spender]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ require(!emergencyFlag); require(_value <= balances[_from]); require(_value <= allowed[_from][msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(<FILL_ME>) require(betalisted[msg.sender]); } require(!blacklisted[_to]); require(!blacklisted[_from]); require(!blacklisted[msg.sender]); balances[_from] = balances[_from].sub(_value); balances[_to] = balances[_to].add(_value); allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value); emit Transfer(_from, _to, _value); return true; } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_from]
291,844
betalisted[_from]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ require(!emergencyFlag); require(_value <= balances[_from]); require(_value <= allowed[_from][msg.sender]); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(betalisted[_from]); require(betalisted[msg.sender]); } require(!blacklisted[_to]); require(<FILL_ME>) require(!blacklisted[msg.sender]); balances[_from] = balances[_from].sub(_value); balances[_to] = balances[_to].add(_value); allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value); emit Transfer(_from, _to, _value); return true; } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_from]
291,844
!blacklisted[_from]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(<FILL_ME>) if(requireBetalisted){ require(betalisted[_user]); require(betalisted[_developer]); } require(!blacklisted[_developer]); require(!blacklisted[_user]); isOperator[_developer][_user]=true; emit AssignedOperator(_developer,_user); return true; } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!isOperator[_developer][_user]
291,844
!isOperator[_developer][_user]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(!isOperator[_developer][_user]); if(requireBetalisted){ require(<FILL_ME>) require(betalisted[_developer]); } require(!blacklisted[_developer]); require(!blacklisted[_user]); isOperator[_developer][_user]=true; emit AssignedOperator(_developer,_user); return true; } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_user]
291,844
betalisted[_user]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(!isOperator[_developer][_user]); if(requireBetalisted){ require(betalisted[_user]); require(<FILL_ME>) } require(!blacklisted[_developer]); require(!blacklisted[_user]); isOperator[_developer][_user]=true; emit AssignedOperator(_developer,_user); return true; } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
betalisted[_developer]
291,844
betalisted[_developer]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(!isOperator[_developer][_user]); if(requireBetalisted){ require(betalisted[_user]); require(betalisted[_developer]); } require(<FILL_ME>) require(!blacklisted[_user]); isOperator[_developer][_user]=true; emit AssignedOperator(_developer,_user); return true; } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_developer]
291,844
!blacklisted[_developer]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(!isOperator[_developer][_user]); if(requireBetalisted){ require(betalisted[_user]); require(betalisted[_developer]); } require(!blacklisted[_developer]); require(<FILL_ME>) isOperator[_developer][_user]=true; emit AssignedOperator(_developer,_user); return true; } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
!blacklisted[_user]
291,844
!blacklisted[_user]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ require(!emergencyFlag); require(_developer != address(0)); require(_user != address(0)); require(<FILL_ME>) isOperator[_developer][_user]=false; emit RemovedOperator(_developer,_user); return true; } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
isOperator[_developer][_user]
291,844
isOperator[_developer][_user]
null
pragma solidity ^0.5.2; /** @title A contract for issuing, redeeming and transfering Sila StableCoins * * @author www.silamoney.com * Email: [email protected] * */ /**Run * @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) { } /** * @dev Integer division of two numbers truncating the quotient, reverts on division by zero. */ function div(uint256 _a, uint256 _b) internal pure returns (uint256) { } /** * @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) { } /** * @dev Adds two numbers, reverts on overflow. */ function add(uint256 _a, uint256 _b) internal pure returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract hotOwner and ColdOwner, and provides authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { // hot and cold wallet addresses address public hotOwner=0xCd39203A332Ff477a35dA3AD2AD7761cDBEAb7F0; address public coldOwner=0x1Ba688e70bb4F3CB266b8D721b5597bFbCCFF957; //events event OwnershipTransferred(address indexed _newHotOwner,address indexed _newColdOwner,address indexed _oldColdOwner); /** * @dev Reverts if called by any account other than the hotOwner. */ modifier onlyHotOwner() { } /** * @dev Reverts if called by any account other than the coldOwner. */ modifier onlyColdOwner() { } /** * @dev Function assigns new hotowner and coldOwner * @param _newHotOwner address The address which owns the funds. * @param _newColdOwner address The address which can change the hotOwner. */ function transferOwnership(address _newHotOwner,address _newColdOwner) public onlyColdOwner returns (bool) { } } /** * @title Authorizable * @dev The Authorizable contract can be used to authorize addresses to control silatoken main functions * functions, this will provide more flexibility in terms of signing trasactions */ contract Authorizable is Ownable { //map to check if the address is authorized to issue, redeem sila mapping(address => bool) authorized; //events for when address is added or removed event AuthorityAdded(address indexed _toAdd); event AuthorityRemoved(address indexed _toRemove); //array of authorized address to check for all the authorized addresses address[] public authorizedAddresses; modifier onlyAuthorized() { } /** * @dev Function addAuthorized adds addresses that can issue,redeem and transfer silas * @param _toAdd address of the added authority */ function addAuthorized(address _toAdd) onlyHotOwner public returns(bool) { } /** * @dev Function RemoveAuthorized removes addresses that can issue and redeem silas * @param _toRemove address of the added authority */ function removeAuthorized(address _toRemove,uint _toRemoveIndex) onlyHotOwner public returns(bool) { } // view all the authorized addresses function viewAuthorized() external view returns(address[] memory _authorizedAddresses){ } // check if the address is authorized function isAuthorized(address _authorized) external view returns(bool _isauthorized){ } } /** * @title EmergencyToggle * @dev The EmergencyToggle contract provides a way to pause the contract in emergency */ contract EmergencyToggle is Ownable{ //variable to pause the entire contract if true bool public emergencyFlag; //constructor constructor () public{ } /** * @dev onlyHotOwner can can pause the usage of issue,redeem, transfer functions */ function emergencyToggle() external onlyHotOwner{ } } /** * @title Token is Betalist,Blacklist */ contract Betalist is Authorizable,EmergencyToggle{ //maps for betalisted and blacklisted addresses mapping(address=>bool) betalisted; mapping(address=>bool) blacklisted; //events for betalist and blacklist event BetalistedAddress (address indexed _betalisted); event BlacklistedAddress (address indexed _blacklisted); event RemovedFromBlacklist(address indexed _toRemoveBlacklist); event RemovedFromBetalist(address indexed _toRemoveBetalist); //variable to check if betalist is required when calling several functions on smart contract bool public requireBetalisted; //constructor constructor () public{ } /** * @dev betaList the specified address * @param _toBetalist the address to betalist */ function betalistAddress(address _toBetalist) public onlyAuthorized returns(bool){ } /** * @dev remove from betaList the specified address * @param _toRemoveBetalist The address to be removed */ function removeAddressFromBetalist(address _toRemoveBetalist) public onlyAuthorized returns(bool){ } /** * @dev blackList the specified address * @param _toBlacklist The address to blacklist */ function blacklistAddress(address _toBlacklist) public onlyAuthorized returns(bool){ } /** * @dev remove from blackList the specified address * @param _toRemoveBlacklist The address to blacklist */ function removeAddressFromBlacklist(address _toRemoveBlacklist) public onlyAuthorized returns(bool){ } /** * @dev check the specified address if isBetaListed * @param _betalisted The address to transfer to. */ function isBetaListed(address _betalisted) external view returns(bool){ } /** * @dev check the specified address isBlackListed * @param _blacklisted The address to transfer to. */ function isBlackListed(address _blacklisted) external view returns(bool){ } } /** * @title Token is token Interface */ contract Token{ function balanceOf(address _owner) public view returns (uint256 balance); function transfer(address _to, uint256 _value) public returns (bool success); function transferFrom(address _from, address _to, uint256 _value) public returns (bool success); function approve(address _spender, uint256 _value) public returns (bool success); function allowance(address _owner, address _spender) public view returns (uint256 remaining); event Transfer(address indexed _from, address indexed _to, uint256 _value); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } /** *@title StandardToken *@dev Implementation of the basic standard token. */ contract StandardToken is Token,Betalist{ using SafeMath for uint256; mapping (address => uint256) balances; mapping (address => mapping (address => uint256)) allowed; uint256 public totalSupply; /** * @dev Gets the balance of the specified address. * @return An uint256 representing the amount owned by the passed address. */ function balanceOf(address _owner) public view returns (uint256) { } /** * @dev Function to check the amount of tokens that an owner allowed to a spender. * @param _owner address The address which owns the funds. * @param _spender address The address which will spend the funds. * @return A uint256 specifying the amount of tokens still available for the spender. */ function allowance(address _owner,address _spender)public view returns (uint256){ } /** * @dev Transfer token for a specified address * @param _to The address to transfer to. * @param _value The amount to be transferred. */ function transfer(address _to, uint256 _value) public returns (bool) { } /** * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender. * Beware that changing an allowance with this method brings the risk that someone may use both the old * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: * @param _value The amount of tokens to be spent. */ function approve(address _spender, uint256 _value) public returns (bool) { } /** * @dev Transfer tokens from one address to another * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _value uint256 the amount of tokens to be transferred */ function transferFrom(address _from,address _to,uint256 _value)public returns (bool){ } } contract AssignOperator is StandardToken{ //mappings mapping(address=>mapping(address=>bool)) isOperator; //Events event AssignedOperator (address indexed _operator,address indexed _for); event OperatorTransfer (address indexed _developer,address indexed _from,address indexed _to,uint _amount); event RemovedOperator (address indexed _operator,address indexed _for); /** * @dev AssignedOperator to transfer tokens on users behalf * @param _developer address The address which is allowed to transfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function assignOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev RemoveOperator allowed to transfer tokens on users behalf * @param _developer address The address which is allowed to trasnfer tokens on users behalf * @param _user address The address which developer want to transfer from */ function removeOperator(address _developer,address _user) public onlyAuthorized returns(bool){ } /** * @dev Operatransfer for developer to transfer tokens on users behalf without requiring ethers in managed ethereum accounts * @param _from address the address to transfer tokens from * @param _to address The address which developer want to transfer to * @param _amount the amount of tokens user wants to transfer */ function operatorTransfer(address _from,address _to,uint _amount) public returns (bool){ require(!emergencyFlag); require(<FILL_ME>) require(_amount <= balances[_from]); require(_from != address(0)); require(_to != address(0)); if (requireBetalisted){ require(betalisted[_to]); require(betalisted[_from]); require(betalisted[msg.sender]); } require(!blacklisted[_to]); require(!blacklisted[_from]); require(!blacklisted[msg.sender]); balances[_from] = balances[_from].sub(_amount); balances[_to] = balances[_to].add(_amount); emit OperatorTransfer(msg.sender,_from, _to, _amount); emit Transfer(_from,_to,_amount); return true; } /** * @dev checkIsOperator is developer an operator allowed to transfer tokens on users behalf * @param _developer the address allowed to trasnfer tokens * @param _for address The address which developer want to transfer from */ function checkIsOperator(address _developer,address _for) external view returns (bool){ } } /** *@title SilaToken *@dev Implementation for sila issue,redeem,protectedTransfer and batch functions */ contract SilaToken is AssignOperator{ using SafeMath for uint256; // parameters for silatoken string public constant name = "SilaToken"; string public constant symbol = "SILA"; uint256 public constant decimals = 18; string public version = "1.0"; //Events fired during successfull execution of main silatoken functions event Issued(address indexed _to,uint256 _value); event Redeemed(address indexed _from,uint256 _amount); event ProtectedTransfer(address indexed _from,address indexed _to,uint256 _amount); event ProtectedApproval(address indexed _owner,address indexed _spender,uint256 _amount); event GlobalLaunchSila(address indexed _launcher); /** * @dev issue tokens from sila to _to address * @dev onlyAuthorized addresses can call this function * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be issued */ function issue(address _to, uint256 _amount) public onlyAuthorized returns (bool) { } /** * @dev redeem tokens from _from address * @dev onlyAuthorized addresses can call this function * @param _from address is the address from which tokens are burnt * @param _amount uint256 the amount of tokens to be burnt */ function redeem(address _from,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Transfer tokens from one address to another * @dev onlyAuthorized addresses can call this function * @param _from address The address which you want to send tokens from * @param _to address The address which you want to transfer to * @param _amount uint256 the amount of tokens to be transferred */ function protectedTransfer(address _from,address _to,uint256 _amount) public onlyAuthorized returns(bool){ } /** * @dev Launch sila for global transfers to work as standard */ function globalLaunchSila() public onlyHotOwner{ } /** * @dev batchissue , isuue tokens in batches to multiple addresses at a time * @param _amounts The amount of tokens to be issued. * @param _toAddresses tokens to be issued to these addresses respectively */ function batchIssue(address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool) { } /** * @dev batchredeem , redeem tokens in batches from multiple addresses at a time * @param _amounts The amount of tokens to be redeemed. * @param _fromAddresses tokens to be redeemed to from addresses respectively */ function batchRedeem(address[] memory _fromAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } /** * @dev batchTransfer, transfer tokens in batches between multiple addresses at a time * @param _fromAddresses tokens to be transfered to these addresses respectively * @param _toAddresses tokens to be transfered to these addresses respectively * @param _amounts The amount of tokens to be transfered */ function protectedBatchTransfer(address[] memory _fromAddresses,address[] memory _toAddresses,uint256[] memory _amounts) public onlyAuthorized returns(bool){ } }
isOperator[msg.sender][_from]
291,844
isOperator[msg.sender][_from]
"TOKEN: Your account is blacklisted!"
/* SPDX-License-Identifier: MIT ______ _____ ___ _______ __ __ ___ ______ _______ ___ ________ / " \ (\" \|" \ /" "| |" |/ \| "| / " \ /" \ |" | |" "\ // ____ \ |.\\ \ |(: ______) |' / \: | // ____ \ |: ||| | (. ___ :) / / ) :)|: \. \\ | \/ | |: /' | / / ) :)|_____/ )|: | |: \ ) || (: (____/ // |. \ \. | // ___)_ \// /\' |(: (____/ // // / \ |___ (| (___\ || \ / | \ \ |(: "| / / \\ | \ / |: __ \ ( \_|: \ |: :) \"_____/ \___|\____\) \_______) |___/ \___| \"_____/ |__| \___) \_______)(________/ Twitter: https://twitter.com/oneworlderc20 Telegram: t.me/OneWorld_Quest Website: https://oneworld.quest/ */ pragma solidity ^0.8.7; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval( address indexed owner, address indexed spender, uint256 value ); } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); constructor() { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint256 amountIn, uint256 amountOutMin, address[] calldata path, address to, uint256 deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint256 amountTokenDesired, uint256 amountTokenMin, uint256 amountETHMin, address to, uint256 deadline ) external payable returns ( uint256 amountToken, uint256 amountETH, uint256 liquidity ); } contract ONE is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "ONE WORLD"; string private constant _symbol = "ONEWORLD"; uint8 private constant _decimals = 9; mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; mapping(address => bool) private _isExcludedFromFee; uint256 private constant MAX = ~uint256(0); uint256 public _totalSupply = 1000000000 * 10**9; //Buy Fee uint256 private _taxFeeOnBuy = 12; // 10 after the first 48h //Sell Fee uint256 private _taxFeeOnSell = 24; // 12 after the first 48h //Original Fee uint256 private _taxFee = _taxFeeOnSell; uint256 private _previoustaxFee = _taxFee; mapping(address => bool) public blacklist; address payable public marketingAddress = payable(0x2c12Bafb9d1652644Ce052f7E20b6B6428c499E0); IUniswapV2Router02 public uniswapV2Router; address public uniswapV2Pair; bool private tradingOpen; bool private inSwap = false; bool private swapEnabled = true; uint256 public _maxTxAmount = 7500000 * 10**9; // 0.75% uint256 public _maxWalletSize = 20000000 * 10**9; // 2% uint256 public _tokenSwapThreshold = 1000000 * 10**9; //0.1% event MaxTxAmountUpdated(uint256 _maxTxAmount); modifier lockTheSwap() { } constructor() { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public view override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function launch() public onlyOwner { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function _approve( address owner, address spender, uint256 amount ) private { } function removeAllFee() private { } function restoreAllFee() private { } function transferFrom( address sender, address recipient, uint256 amount ) public override returns (bool) { } // Transfer functions function _transfer( address from, address to, uint256 amount ) private { require(from != address(0), "ERC20: transfer from the zero address"); require(to != address(0), "ERC20: transfer to the zero address"); require(amount > 0, "Transfer amount must be greater than zero"); if (from != owner() && to != owner()) { //Trade start check require(tradingOpen,"TOKEN: This token isn't tradable yet"); require(amount <= _maxTxAmount, "TOKEN: Max Transaction Limit"); require(<FILL_ME>) if (to != uniswapV2Pair) { require( balanceOf(to) + amount < _maxWalletSize, "TOKEN: Balance exceeds wallet size!" ); } uint256 contractTokenBalance = balanceOf(address(this)); bool shouldSwap = contractTokenBalance >= _tokenSwapThreshold; if (contractTokenBalance >= _maxTxAmount) { contractTokenBalance = _maxTxAmount; } if (shouldSwap && !inSwap && from != uniswapV2Pair && swapEnabled) { swapTokensForEth(contractTokenBalance); uint256 contractETHBalance = address(this).balance; if (contractETHBalance > 0) { sendETHtoMarketing(address(this).balance); } } } bool takeFee = true; //Transfer Tokens if ( (_isExcludedFromFee[from] || _isExcludedFromFee[to]) || (from != uniswapV2Pair && to != uniswapV2Pair) ) { takeFee = false; } else { //Set Fee for Buys if (from == uniswapV2Pair && to != address(uniswapV2Router)) { _taxFee = _taxFeeOnBuy; } //Set Fee for Sells if (to == uniswapV2Pair && from != address(uniswapV2Router)) { _taxFee = _taxFeeOnSell; } } _tokenTransfer(from, to, amount, takeFee); } function _tokenTransfer( address sender, address recipient, uint256 amount, bool takeFee ) private { } function _transferStandard( address sender, address recipient, uint256 amount ) private { } // Swap and send functions function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHtoMarketing(uint256 amount) private { } function manualswap() external { } function manualsend() external { } // Blacklist and whitelist function blacklistAddresses(address[] memory _blacklist) public onlyOwner { } function whitelistAddress(address whitelist) external onlyOwner { } // Fee related functions function isExcludedFromFee(address account) public view returns (bool) { } // Setters function setExcludeFromFee(address account, bool excluded) external onlyOwner { } function setMarketingWalletAddress(address payable _marketingAddress) external onlyOwner { } function setFee( uint256 taxFeeOnBuy, uint256 taxFeeOnSell ) public onlyOwner { } function setMinSwapTokensThreshold(uint256 tokenSwapThreshold) public onlyOwner { } function setSwapEnabled(bool _swapEnabled) public onlyOwner { } function setMaxTxnAmount(uint256 maxTxAmount) public onlyOwner { } function setMaxWalletSize(uint256 maxWalletSize) public onlyOwner { } // Enable the current contract to receive ETH receive() external payable {} }
!blacklist[from]&&!blacklist[to],"TOKEN: Your account is blacklisted!"
291,847
!blacklist[from]&&!blacklist[to]
null
/* SPDX-License-Identifier: MIT ______ _____ ___ _______ __ __ ___ ______ _______ ___ ________ / " \ (\" \|" \ /" "| |" |/ \| "| / " \ /" \ |" | |" "\ // ____ \ |.\\ \ |(: ______) |' / \: | // ____ \ |: ||| | (. ___ :) / / ) :)|: \. \\ | \/ | |: /' | / / ) :)|_____/ )|: | |: \ ) || (: (____/ // |. \ \. | // ___)_ \// /\' |(: (____/ // // / \ |___ (| (___\ || \ / | \ \ |(: "| / / \\ | \ / |: __ \ ( \_|: \ |: :) \"_____/ \___|\____\) \_______) |___/ \___| \"_____/ |__| \___) \_______)(________/ Twitter: https://twitter.com/oneworlderc20 Telegram: t.me/OneWorld_Quest Website: https://oneworld.quest/ */ pragma solidity ^0.8.7; abstract contract Context { function _msgSender() internal view virtual returns (address) { } } interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); event Approval( address indexed owner, address indexed spender, uint256 value ); } contract Ownable is Context { address private _owner; address private _previousOwner; event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); constructor() { } function owner() public view returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner { } } library SafeMath { function add(uint256 a, uint256 b) internal pure returns (uint256) { } function sub(uint256 a, uint256 b) internal pure returns (uint256) { } function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } function mul(uint256 a, uint256 b) internal pure returns (uint256) { } function div(uint256 a, uint256 b) internal pure returns (uint256) { } function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { } } interface IUniswapV2Factory { function createPair(address tokenA, address tokenB) external returns (address pair); } interface IUniswapV2Router02 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint256 amountIn, uint256 amountOutMin, address[] calldata path, address to, uint256 deadline ) external; function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidityETH( address token, uint256 amountTokenDesired, uint256 amountTokenMin, uint256 amountETHMin, address to, uint256 deadline ) external payable returns ( uint256 amountToken, uint256 amountETH, uint256 liquidity ); } contract ONE is Context, IERC20, Ownable { using SafeMath for uint256; string private constant _name = "ONE WORLD"; string private constant _symbol = "ONEWORLD"; uint8 private constant _decimals = 9; mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; mapping(address => bool) private _isExcludedFromFee; uint256 private constant MAX = ~uint256(0); uint256 public _totalSupply = 1000000000 * 10**9; //Buy Fee uint256 private _taxFeeOnBuy = 12; // 10 after the first 48h //Sell Fee uint256 private _taxFeeOnSell = 24; // 12 after the first 48h //Original Fee uint256 private _taxFee = _taxFeeOnSell; uint256 private _previoustaxFee = _taxFee; mapping(address => bool) public blacklist; address payable public marketingAddress = payable(0x2c12Bafb9d1652644Ce052f7E20b6B6428c499E0); IUniswapV2Router02 public uniswapV2Router; address public uniswapV2Pair; bool private tradingOpen; bool private inSwap = false; bool private swapEnabled = true; uint256 public _maxTxAmount = 7500000 * 10**9; // 0.75% uint256 public _maxWalletSize = 20000000 * 10**9; // 2% uint256 public _tokenSwapThreshold = 1000000 * 10**9; //0.1% event MaxTxAmountUpdated(uint256 _maxTxAmount); modifier lockTheSwap() { } constructor() { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint8) { } function totalSupply() public view override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function launch() public onlyOwner { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function allowance(address owner, address spender) public view override returns (uint256) { } function approve(address spender, uint256 amount) public override returns (bool) { } function _approve( address owner, address spender, uint256 amount ) private { } function removeAllFee() private { } function restoreAllFee() private { } function transferFrom( address sender, address recipient, uint256 amount ) public override returns (bool) { } // Transfer functions function _transfer( address from, address to, uint256 amount ) private { } function _tokenTransfer( address sender, address recipient, uint256 amount, bool takeFee ) private { } function _transferStandard( address sender, address recipient, uint256 amount ) private { } // Swap and send functions function swapTokensForEth(uint256 tokenAmount) private lockTheSwap { } function sendETHtoMarketing(uint256 amount) private { } function manualswap() external { require(<FILL_ME>) uint256 contractBalance = balanceOf(address(this)); swapTokensForEth(contractBalance); } function manualsend() external { } // Blacklist and whitelist function blacklistAddresses(address[] memory _blacklist) public onlyOwner { } function whitelistAddress(address whitelist) external onlyOwner { } // Fee related functions function isExcludedFromFee(address account) public view returns (bool) { } // Setters function setExcludeFromFee(address account, bool excluded) external onlyOwner { } function setMarketingWalletAddress(address payable _marketingAddress) external onlyOwner { } function setFee( uint256 taxFeeOnBuy, uint256 taxFeeOnSell ) public onlyOwner { } function setMinSwapTokensThreshold(uint256 tokenSwapThreshold) public onlyOwner { } function setSwapEnabled(bool _swapEnabled) public onlyOwner { } function setMaxTxnAmount(uint256 maxTxAmount) public onlyOwner { } function setMaxWalletSize(uint256 maxWalletSize) public onlyOwner { } // Enable the current contract to receive ETH receive() external payable {} }
_msgSender()==marketingAddress
291,847
_msgSender()==marketingAddress
null
pragma solidity ^0.4.4; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ function Ownable() { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. * @param newOwner The address to transfer ownership to. */ function transferOwnership(address newOwner) onlyOwner { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { uint256 public totalSupply; function balanceOf(address who) constant returns (uint256); function transfer(address to, uint256 value) returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) constant returns (uint256); function transferFrom(address from, address to, uint256 value) returns (bool); function approve(address spender, uint256 value) returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title PoSTokenStandard * @dev the interface of PoSTokenStandard */ contract PoSTokenStandard { uint256 public stakeStartTime; uint256 public stakeMinAge; uint256 public stakeMaxAge; //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes function mine() returns (bool); function coinAge(address who) constant returns (uint256); function annualInterest() constant returns (uint256); event Mine(address indexed _address, uint _reward); } //Maximumcoin - Changed name of contract contract Maximumcoin is ERC20,PoSTokenStandard,Ownable { using SafeMath for uint256; //Maximumcoin - Changed name of contract string public name = "Maximum-coin"; string public symbol = "xMUM"; uint public decimals = 18; uint public chainStartTime; //chain start time uint public chainStartBlockNumber; //chain start block number uint public stakeStartTime; //stake start time uint public stakeMinAge = 3 days; // minimum age for coin age: 3D uint public stakeMaxAge = 90 days; // stake age of full weight: 90D uint public maxMintProofOfStake = 10**17; // default 10% annual interest uint public totalSupply; uint public maxTotalSupply; uint public totalInitialSupply; struct transferInStruct{ uint128 amount; uint64 time; } mapping(address => uint256) balances; mapping(address => mapping (address => uint256)) allowed; mapping(address => transferInStruct[]) transferIns; //Maximumcoin - Removed burn system //event Burn(address indexed burner, uint256 value); /** * @dev Fix for the ERC20 short address attack. */ modifier onlyPayloadSize(uint size) { } modifier canPoSMint() { } function MaximumcoinStart() onlyOwner { address recipient; uint value; uint64 _now = uint64(now); //kill start if this has already been ran require(<FILL_ME>) maxTotalSupply = 10**25; // 10 Mil. //Maximumcoin - Modified initial supply to 250k totalInitialSupply = 2.5*(10**23); // 250K chainStartTime = now; chainStartBlockNumber = block.number; //Free Airdrop and Bounty Program - 200K recipient = 0x1748b386a6F008Ce4Ad3a969974F4D7b7c0d92bE; value = 2 * (10**23); //run balances[recipient] = value; transferIns[recipient].push(transferInStruct(uint128(value),_now)); //iMAC development Team - 50K recipient = 0x8067d29f98A8E7F87713867c0e9bF5ae578B3237; value = 5 * (10**22); //run balances[recipient] = value; transferIns[recipient].push(transferInStruct(uint128(value),_now)); totalSupply = totalInitialSupply; } function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) returns (bool) { } function balanceOf(address _owner) constant returns (uint256 balance) { } function transferFrom(address _from, address _to, uint256 _value) onlyPayloadSize(3 * 32) returns (bool) { } function approve(address _spender, uint256 _value) returns (bool) { } function allowance(address _owner, address _spender) constant returns (uint256 remaining) { } //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes. function mine() canPoSMint returns (bool) { } function getBlockNumber() returns (uint blockNumber) { } function coinAge(address who) constant returns (uint myCoinAge) { } function annualInterest() constant returns(uint interest) { } function getProofOfStakeReward(address _address) internal returns (uint) { } function getCoinAge(address _address, uint _now) internal returns (uint _coinAge) { } function ownerSetStakeStartTime(uint timestamp) onlyOwner { } }
(maxTotalSupply<=0)
291,852
(maxTotalSupply<=0)
null
pragma solidity ^0.4.4; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ function Ownable() { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. * @param newOwner The address to transfer ownership to. */ function transferOwnership(address newOwner) onlyOwner { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { uint256 public totalSupply; function balanceOf(address who) constant returns (uint256); function transfer(address to, uint256 value) returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) constant returns (uint256); function transferFrom(address from, address to, uint256 value) returns (bool); function approve(address spender, uint256 value) returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title PoSTokenStandard * @dev the interface of PoSTokenStandard */ contract PoSTokenStandard { uint256 public stakeStartTime; uint256 public stakeMinAge; uint256 public stakeMaxAge; //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes function mine() returns (bool); function coinAge(address who) constant returns (uint256); function annualInterest() constant returns (uint256); event Mine(address indexed _address, uint _reward); } //Maximumcoin - Changed name of contract contract Maximumcoin is ERC20,PoSTokenStandard,Ownable { using SafeMath for uint256; //Maximumcoin - Changed name of contract string public name = "Maximum-coin"; string public symbol = "xMUM"; uint public decimals = 18; uint public chainStartTime; //chain start time uint public chainStartBlockNumber; //chain start block number uint public stakeStartTime; //stake start time uint public stakeMinAge = 3 days; // minimum age for coin age: 3D uint public stakeMaxAge = 90 days; // stake age of full weight: 90D uint public maxMintProofOfStake = 10**17; // default 10% annual interest uint public totalSupply; uint public maxTotalSupply; uint public totalInitialSupply; struct transferInStruct{ uint128 amount; uint64 time; } mapping(address => uint256) balances; mapping(address => mapping (address => uint256)) allowed; mapping(address => transferInStruct[]) transferIns; //Maximumcoin - Removed burn system //event Burn(address indexed burner, uint256 value); /** * @dev Fix for the ERC20 short address attack. */ modifier onlyPayloadSize(uint size) { } modifier canPoSMint() { } function MaximumcoinStart() onlyOwner { } function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) returns (bool) { } function balanceOf(address _owner) constant returns (uint256 balance) { } function transferFrom(address _from, address _to, uint256 _value) onlyPayloadSize(3 * 32) returns (bool) { } function approve(address _spender, uint256 _value) returns (bool) { } function allowance(address _owner, address _spender) constant returns (uint256 remaining) { } //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes. function mine() canPoSMint returns (bool) { } function getBlockNumber() returns (uint blockNumber) { } function coinAge(address who) constant returns (uint myCoinAge) { } function annualInterest() constant returns(uint interest) { } function getProofOfStakeReward(address _address) internal returns (uint) { require(<FILL_ME>) uint _now = now; uint _coinAge = getCoinAge(_address, _now); if(_coinAge <= 0) return 0; uint interest = maxMintProofOfStake; // Due to the high interest rate for the first two years, compounding should be taken into account. // Effective annual interest rate = (1 + (nominal rate / number of compounding periods)) ^ (number of compounding periods) - 1 //Maximumcoin - Modified initial interest rate to 300% if((_now.sub(stakeStartTime)).div(1 years) == 0) { // 1st year effective annual interest rate is 300% when we select the stakeMaxAge (90 days) as the compounding period. interest = (1650 * maxMintProofOfStake).div(100); } else if((_now.sub(stakeStartTime)).div(1 years) == 1) { // 2nd year effective annual interest rate is 100% when we select the stakeMaxAge (90 days) as the compounding period. interest = (770 * maxMintProofOfStake).div(100); } else if((_now.sub(stakeStartTime)).div(1 years) == 2){ // 3nd year effective annual interest rate is 50% interest = (435 * maxMintProofOfStake).div(100); } return (_coinAge * interest).div(365 * (10**decimals)); } function getCoinAge(address _address, uint _now) internal returns (uint _coinAge) { } function ownerSetStakeStartTime(uint timestamp) onlyOwner { } }
(now>=stakeStartTime)&&(stakeStartTime>0)
291,852
(now>=stakeStartTime)&&(stakeStartTime>0)
null
pragma solidity ^0.4.4; /** * @title SafeMath * @dev Math operations with safety checks that throw on error */ library SafeMath { function mul(uint256 a, uint256 b) internal constant returns (uint256) { } function div(uint256 a, uint256 b) internal constant returns (uint256) { } function sub(uint256 a, uint256 b) internal constant returns (uint256) { } function add(uint256 a, uint256 b) internal constant returns (uint256) { } } /** * @title Ownable * @dev The Ownable contract has an owner address, and provides basic authorization control * functions, this simplifies the implementation of "user permissions". */ contract Ownable { address public owner; /** * @dev The Ownable constructor sets the original `owner` of the contract to the sender * account. */ function Ownable() { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Allows the current owner to transfer control of the contract to a newOwner. * @param newOwner The address to transfer ownership to. */ function transferOwnership(address newOwner) onlyOwner { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic { uint256 public totalSupply; function balanceOf(address who) constant returns (uint256); function transfer(address to, uint256 value) returns (bool); event Transfer(address indexed from, address indexed to, uint256 value); } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 is ERC20Basic { function allowance(address owner, address spender) constant returns (uint256); function transferFrom(address from, address to, uint256 value) returns (bool); function approve(address spender, uint256 value) returns (bool); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @title PoSTokenStandard * @dev the interface of PoSTokenStandard */ contract PoSTokenStandard { uint256 public stakeStartTime; uint256 public stakeMinAge; uint256 public stakeMaxAge; //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes function mine() returns (bool); function coinAge(address who) constant returns (uint256); function annualInterest() constant returns (uint256); event Mine(address indexed _address, uint _reward); } //Maximumcoin - Changed name of contract contract Maximumcoin is ERC20,PoSTokenStandard,Ownable { using SafeMath for uint256; //Maximumcoin - Changed name of contract string public name = "Maximum-coin"; string public symbol = "xMUM"; uint public decimals = 18; uint public chainStartTime; //chain start time uint public chainStartBlockNumber; //chain start block number uint public stakeStartTime; //stake start time uint public stakeMinAge = 3 days; // minimum age for coin age: 3D uint public stakeMaxAge = 90 days; // stake age of full weight: 90D uint public maxMintProofOfStake = 10**17; // default 10% annual interest uint public totalSupply; uint public maxTotalSupply; uint public totalInitialSupply; struct transferInStruct{ uint128 amount; uint64 time; } mapping(address => uint256) balances; mapping(address => mapping (address => uint256)) allowed; mapping(address => transferInStruct[]) transferIns; //Maximumcoin - Removed burn system //event Burn(address indexed burner, uint256 value); /** * @dev Fix for the ERC20 short address attack. */ modifier onlyPayloadSize(uint size) { } modifier canPoSMint() { } function MaximumcoinStart() onlyOwner { } function transfer(address _to, uint256 _value) onlyPayloadSize(2 * 32) returns (bool) { } function balanceOf(address _owner) constant returns (uint256 balance) { } function transferFrom(address _from, address _to, uint256 _value) onlyPayloadSize(3 * 32) returns (bool) { } function approve(address _spender, uint256 _value) returns (bool) { } function allowance(address _owner, address _spender) constant returns (uint256 remaining) { } //Maximumcoin - Modified the correct technical term "mint" to a well know term "mine" for marketing purposes. function mine() canPoSMint returns (bool) { } function getBlockNumber() returns (uint blockNumber) { } function coinAge(address who) constant returns (uint myCoinAge) { } function annualInterest() constant returns(uint interest) { } function getProofOfStakeReward(address _address) internal returns (uint) { } function getCoinAge(address _address, uint _now) internal returns (uint _coinAge) { } function ownerSetStakeStartTime(uint timestamp) onlyOwner { require(<FILL_ME>) stakeStartTime = timestamp; } }
(stakeStartTime<=0)&&(timestamp>=chainStartTime)
291,852
(stakeStartTime<=0)&&(timestamp>=chainStartTime)
'!tradable'
pragma solidity >=0.8.0; contract RollerInu is ERC20('RollerInu', 'ROI'), Ownable { using SafeMath for uint256; uint256 constant public MAX_SUPPLY = 100000000000 * 1e18; // 1B max supply uint16 private MAX_BP_RATE = 10000; uint16 private devTaxRate = 400; uint16 private marketingTaxRate = 400; uint16 private burnTaxRate = 400; uint16 private maxTransferAmountRate = 1000; uint256 private numTokenToSwap = 500000000 * 1e18; // 0.5% of total supply IUniswapV2Router02 public uniswapRouter; // The trading pair address public uniswapPair; address public feeRecipient = 0xf9054E835566250EB85BBB5A241d071035D34Cf5; address public deadAddress = 0x000000000000000000000000000000000000dEaD; // In swap and withdraw bool private _inSwapAndWithdraw; // Automatic swap and liquify enabled bool private _swapAndWithdrawEnabled = false; mapping(address => bool) private _isExcludedFromFee; mapping(address => bool) private _isExcludedFromMaxTx; bool private _tradingOpen = false; mapping(address => bool) private _tradables; modifier onlyTradable(address _sender) { require(<FILL_ME>) _; } modifier lockTheSwap { } modifier transferTaxFree { } constructor() public { } //to recieve ETH from uniswapV2Router when swaping receive() external payable {} /// @notice Burns `_amount` token fromo `_from`. Must only be called by the owner. function burn(address _from, uint256 _amount) public onlyOwner { } function _transfer(address _sender, address _recepient, uint256 _amount) internal override onlyTradable(_sender) { } /** * @dev Update the swap router. * Can only be called by the current operator. */ function updateRouter(address _router) public onlyOwner { } /** * @dev Update the _swapAndWithdrawEnabled. * Can only be called by the current operator. */ function updateSwapAndWithdrawEnabled(bool _enabled) public onlyOwner { } function manualSwap() external onlyOwner { } function manualWithdraw() external onlyOwner { } /// @dev Swap and liquify function swapAndWithdraw() private lockTheSwap transferTaxFree { } /// @dev Swap tokens for eth function swapTokensForEth(uint256 tokenAmount) private { } /** * @dev Returns the max transfer amount. */ function maxTransferAmount() public view returns (uint256) { } function setMaxTransferAmountRate(uint16 _rate) external onlyOwner { } function enableTrading(bool _onoff) external onlyOwner { } function updateFees(uint16 _burnTaxRate, uint16 _devTaxRate, uint16 _marketingTaxRate) external onlyOwner { } function isExcludedFromFee(address _addr) external view returns (bool) { } function excludeFromFee(address _addr, bool _is) external onlyOwner { } function isExcludedFromMaxTx(address _addr) external view returns (bool) { } function excludeFromMaxTx(address _addr, bool _is) external onlyOwner { } function setTradable(address _addr, bool _is) external onlyOwner { } function updateFeeRecipient(address _addr) external { } function updateNumTokenToSwap(uint256 _percent) external onlyOwner { } mapping (address => address) internal _delegates; /// @notice A checkpoint for marking number of votes from a given block struct Checkpoint { uint32 fromBlock; uint256 votes; } /// @notice A record of votes checkpoints for each account, by index mapping (address => mapping (uint32 => Checkpoint)) public checkpoints; /// @notice The number of checkpoints for each account mapping (address => uint32) public numCheckpoints; /// @notice The EIP-712 typehash for the contract's domain bytes32 public constant DOMAIN_TYPEHASH = keccak256("EIP712Domain(string name,uint256 chainId,address verifyingContract)"); /// @notice The EIP-712 typehash for the delegation struct used by the contract bytes32 public constant DELEGATION_TYPEHASH = keccak256("Delegation(address delegatee,uint256 nonce,uint256 expiry)"); /// @notice A record of states for signing / validating signatures mapping (address => uint) public nonces; /// @notice An event thats emitted when an account changes its delegate event DelegateChanged(address indexed delegator, address indexed fromDelegate, address indexed toDelegate); /// @notice An event thats emitted when a delegate account's vote balance changes event DelegateVotesChanged(address indexed delegate, uint previousBalance, uint newBalance); /** * @notice Delegate votes from `msg.sender` to `delegatee` * @param delegator The address to get delegatee for */ function delegates(address delegator) external view returns (address) { } /** * @notice Delegate votes from `msg.sender` to `delegatee` * @param delegatee The address to delegate votes to */ function delegate(address delegatee) external { } /** * @notice Delegates votes from signatory to `delegatee` * @param delegatee The address to delegate votes to * @param nonce The contract state required to match the signature * @param expiry The time at which to expire the signature * @param v The recovery byte of the signature * @param r Half of the ECDSA signature pair * @param s Half of the ECDSA signature pair */ function delegateBySig( address delegatee, uint nonce, uint expiry, uint8 v, bytes32 r, bytes32 s ) external { } /** * @notice Gets the current votes balance for `account` * @param account The address to get votes balance * @return The number of current votes for `account` */ function getCurrentVotes(address account) external view returns (uint256) { } /** * @notice Determine the prior number of votes for an account as of a block number * @dev Block number must be a finalized block or else this function will revert to prevent misinformation. * @param account The address of the account to check * @param blockNumber The block number to get the vote balance at * @return The number of votes the account had as of the given block */ function getPriorVotes(address account, uint blockNumber) external view returns (uint256) { } function _delegate(address delegator, address delegatee) internal { } function _moveDelegates(address srcRep, address dstRep, uint256 amount) internal { } function _writeCheckpoint( address delegatee, uint32 nCheckpoints, uint256 oldVotes, uint256 newVotes ) internal { } function safe32(uint n, string memory errorMessage) internal pure returns (uint32) { } function getChainId() internal view returns (uint) { } }
_tradingOpen||_tradables[_sender],'!tradable'
291,863
_tradingOpen||_tradables[_sender]
'!values'
pragma solidity >=0.8.0; contract RollerInu is ERC20('RollerInu', 'ROI'), Ownable { using SafeMath for uint256; uint256 constant public MAX_SUPPLY = 100000000000 * 1e18; // 1B max supply uint16 private MAX_BP_RATE = 10000; uint16 private devTaxRate = 400; uint16 private marketingTaxRate = 400; uint16 private burnTaxRate = 400; uint16 private maxTransferAmountRate = 1000; uint256 private numTokenToSwap = 500000000 * 1e18; // 0.5% of total supply IUniswapV2Router02 public uniswapRouter; // The trading pair address public uniswapPair; address public feeRecipient = 0xf9054E835566250EB85BBB5A241d071035D34Cf5; address public deadAddress = 0x000000000000000000000000000000000000dEaD; // In swap and withdraw bool private _inSwapAndWithdraw; // Automatic swap and liquify enabled bool private _swapAndWithdrawEnabled = false; mapping(address => bool) private _isExcludedFromFee; mapping(address => bool) private _isExcludedFromMaxTx; bool private _tradingOpen = false; mapping(address => bool) private _tradables; modifier onlyTradable(address _sender) { } modifier lockTheSwap { } modifier transferTaxFree { } constructor() public { } //to recieve ETH from uniswapV2Router when swaping receive() external payable {} /// @notice Burns `_amount` token fromo `_from`. Must only be called by the owner. function burn(address _from, uint256 _amount) public onlyOwner { } function _transfer(address _sender, address _recepient, uint256 _amount) internal override onlyTradable(_sender) { } /** * @dev Update the swap router. * Can only be called by the current operator. */ function updateRouter(address _router) public onlyOwner { } /** * @dev Update the _swapAndWithdrawEnabled. * Can only be called by the current operator. */ function updateSwapAndWithdrawEnabled(bool _enabled) public onlyOwner { } function manualSwap() external onlyOwner { } function manualWithdraw() external onlyOwner { } /// @dev Swap and liquify function swapAndWithdraw() private lockTheSwap transferTaxFree { } /// @dev Swap tokens for eth function swapTokensForEth(uint256 tokenAmount) private { } /** * @dev Returns the max transfer amount. */ function maxTransferAmount() public view returns (uint256) { } function setMaxTransferAmountRate(uint16 _rate) external onlyOwner { } function enableTrading(bool _onoff) external onlyOwner { } function updateFees(uint16 _burnTaxRate, uint16 _devTaxRate, uint16 _marketingTaxRate) external onlyOwner { require(<FILL_ME>) burnTaxRate = _burnTaxRate; devTaxRate = _devTaxRate; marketingTaxRate = _marketingTaxRate; } function isExcludedFromFee(address _addr) external view returns (bool) { } function excludeFromFee(address _addr, bool _is) external onlyOwner { } function isExcludedFromMaxTx(address _addr) external view returns (bool) { } function excludeFromMaxTx(address _addr, bool _is) external onlyOwner { } function setTradable(address _addr, bool _is) external onlyOwner { } function updateFeeRecipient(address _addr) external { } function updateNumTokenToSwap(uint256 _percent) external onlyOwner { } mapping (address => address) internal _delegates; /// @notice A checkpoint for marking number of votes from a given block struct Checkpoint { uint32 fromBlock; uint256 votes; } /// @notice A record of votes checkpoints for each account, by index mapping (address => mapping (uint32 => Checkpoint)) public checkpoints; /// @notice The number of checkpoints for each account mapping (address => uint32) public numCheckpoints; /// @notice The EIP-712 typehash for the contract's domain bytes32 public constant DOMAIN_TYPEHASH = keccak256("EIP712Domain(string name,uint256 chainId,address verifyingContract)"); /// @notice The EIP-712 typehash for the delegation struct used by the contract bytes32 public constant DELEGATION_TYPEHASH = keccak256("Delegation(address delegatee,uint256 nonce,uint256 expiry)"); /// @notice A record of states for signing / validating signatures mapping (address => uint) public nonces; /// @notice An event thats emitted when an account changes its delegate event DelegateChanged(address indexed delegator, address indexed fromDelegate, address indexed toDelegate); /// @notice An event thats emitted when a delegate account's vote balance changes event DelegateVotesChanged(address indexed delegate, uint previousBalance, uint newBalance); /** * @notice Delegate votes from `msg.sender` to `delegatee` * @param delegator The address to get delegatee for */ function delegates(address delegator) external view returns (address) { } /** * @notice Delegate votes from `msg.sender` to `delegatee` * @param delegatee The address to delegate votes to */ function delegate(address delegatee) external { } /** * @notice Delegates votes from signatory to `delegatee` * @param delegatee The address to delegate votes to * @param nonce The contract state required to match the signature * @param expiry The time at which to expire the signature * @param v The recovery byte of the signature * @param r Half of the ECDSA signature pair * @param s Half of the ECDSA signature pair */ function delegateBySig( address delegatee, uint nonce, uint expiry, uint8 v, bytes32 r, bytes32 s ) external { } /** * @notice Gets the current votes balance for `account` * @param account The address to get votes balance * @return The number of current votes for `account` */ function getCurrentVotes(address account) external view returns (uint256) { } /** * @notice Determine the prior number of votes for an account as of a block number * @dev Block number must be a finalized block or else this function will revert to prevent misinformation. * @param account The address of the account to check * @param blockNumber The block number to get the vote balance at * @return The number of votes the account had as of the given block */ function getPriorVotes(address account, uint blockNumber) external view returns (uint256) { } function _delegate(address delegator, address delegatee) internal { } function _moveDelegates(address srcRep, address dstRep, uint256 amount) internal { } function _writeCheckpoint( address delegatee, uint32 nCheckpoints, uint256 oldVotes, uint256 newVotes ) internal { } function safe32(uint n, string memory errorMessage) internal pure returns (uint32) { } function getChainId() internal view returns (uint) { } }
_burnTaxRate+_devTaxRate+_marketingTaxRate<=MAX_BP_RATE,'!values'
291,863
_burnTaxRate+_devTaxRate+_marketingTaxRate<=MAX_BP_RATE
null
/** *Submitted for verification at Etherscan.io on 2020-07-01 */ pragma solidity ^0.5.13; /** * * EasySwap Liquidity Vault - Inspired on UniPower's Liquidity Vault - Thanks, Mr. Blobby * * Simple smart contract to decentralize the uniswap liquidity, providing proof of liquidity indefinitely. * * https://easyswap.trade */ contract LiquidityVault { ERC20 constant eswaToken = ERC20(0xA0471cdd5c0dc2614535fD7505b17A651a8F0DAB); ERC20 constant liquidityToken = ERC20(0x8C0e876F1da58140695673D07FF42D4786207D1B); address eswaaddress = msg.sender; uint256 public lastTradingFeeDistribution; uint256 public migrationLock; address public migrationRecipient; /** * To allow distributing of trading fees * * Has a hardcap of 1% per 24 hours -trading fees consistantly exceeding that 1% is not a bad problem to have(!) */ function distributeTradingFees(address recipient, uint256 amount) external { uint256 liquidityBalance = liquidityToken.balanceOf(address(this)); require(amount < (liquidityBalance / 100)); // Max 1% require(<FILL_ME>) // Max once a day require(msg.sender == eswaaddress); liquidityToken.transfer(recipient, amount); lastTradingFeeDistribution = now; } /** * This contract is just a simple initial decentralization of the liquidity (to squell the skeptics) in future may need to migrate to more advanced decentralization (DAO etc.) * So this function allows liquidity to be moved, after a 14 days lockup -preventing abuse. */ function startLiquidityMigration(address recipient) external { } /** * Moves liquidity to new location, assuming the 14 days lockup has passed -preventing abuse. */ function processMigration() external { } /** * This contract may also hold ESWA tokens (donations) to run trading contests, this function lets them be withdrawn. */ function distributeESWA(address recipient, uint256 amount) external { } } interface ERC20 { 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 approveAndCall(address spender, uint tokens, bytes calldata data) external returns (bool success); 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); }
lastTradingFeeDistribution+24hours<now
291,945
lastTradingFeeDistribution+24hours<now
"!approved"
// SPDX-License-Identifier: MIT pragma solidity ^0.5.17; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol"; import "../../interfaces/yearn/IConverter.sol"; import "../../interfaces/yearn/IOneSplitAudit.sol"; import "../../interfaces/yearn/IStrategy.sol"; contract Controller { using SafeERC20 for IERC20; using Address for address; using SafeMath for uint256; address public governance; address public strategist; address public rewards; mapping(address => address) public vaults; mapping(address => address) public strategies; mapping(address => mapping(address => bool)) public approvedStrategies; constructor(address _rewards) public { } function setRewards(address _rewards) public { } function setStrategist(address _strategist) public { } function setGovernance(address _governance) public { } function setVault(address _token, address _vault) public { } function approveStrategy(address _token, address _strategy) public { } function revokeStrategy(address _token, address _strategy) public { } function setStrategy(address _token, address _strategy) public { require(msg.sender == strategist || msg.sender == governance, "!strategist"); require(<FILL_ME>) address _current = strategies[_token]; if (_current != address(0)) { IStrategy(_current).withdrawAll(); } strategies[_token] = _strategy; } function earn(address _token, uint256 _amount) public { } function balanceOf(address _token) external view returns (uint256) { } function withdrawAll(address _token) public { } function inCaseTokensGetStuck(address _token, uint256 _amount) public { } function inCaseStrategyTokenGetStuck(address _strategy, address _token) public { } function withdraw(address _token, uint256 _amount) public { } }
approvedStrategies[_token][_strategy]==true,"!approved"
291,951
approvedStrategies[_token][_strategy]==true
"System closed"
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { require(<FILL_ME>) _; } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
!esm.isClosed(),"System closed"
291,972
!esm.isClosed()
"setuped yet."
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { require(<FILL_ME>) token = IERC20(_token); coin = ICoin(_coin); emit SetupCoin(_token, _coin); } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
address(token)==address(0)&&address(coin)==address(0),"setuped yet."
291,972
address(token)==address(0)&&address(coin)==address(0)
"Stake paused"
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { require(<FILL_ME>) require(coinAmount > 0, "The quantity is less than the minimum"); require(orcl.val() > 0, "Oracle price not initialized."); require(params.isNormal(orcl.val()), "STPT's price is too low."); address from = msg.sender; if (coins[from] == 0) { require( coinAmount >= params.minMint(), "First make coin must grater than minMint amount." ); } accuredToken(from); uint256 tokenAmount = getInputToken(coinAmount); token.transferFrom(from, address(this), tokenAmount); coin.mint(from, coinAmount); totalCoin = totalCoin.add(coinAmount); totalToken = totalToken.add(tokenAmount); coins[from] = coins[from].add(coinAmount); tokens[from] = tokens[from].add(tokenAmount); if (startRewardBlock == 0) { startRewardBlock = getBlockNumber(); } emit StakeEvent(tokenAmount, coinAmount); } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
!esm.isStakePaused(),"Stake paused"
291,972
!esm.isStakePaused()
"Oracle price not initialized."
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { require(!esm.isStakePaused(), "Stake paused"); require(coinAmount > 0, "The quantity is less than the minimum"); require(<FILL_ME>) require(params.isNormal(orcl.val()), "STPT's price is too low."); address from = msg.sender; if (coins[from] == 0) { require( coinAmount >= params.minMint(), "First make coin must grater than minMint amount." ); } accuredToken(from); uint256 tokenAmount = getInputToken(coinAmount); token.transferFrom(from, address(this), tokenAmount); coin.mint(from, coinAmount); totalCoin = totalCoin.add(coinAmount); totalToken = totalToken.add(tokenAmount); coins[from] = coins[from].add(coinAmount); tokens[from] = tokens[from].add(tokenAmount); if (startRewardBlock == 0) { startRewardBlock = getBlockNumber(); } emit StakeEvent(tokenAmount, coinAmount); } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
orcl.val()>0,"Oracle price not initialized."
291,972
orcl.val()>0
"STPT's price is too low."
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { require(!esm.isStakePaused(), "Stake paused"); require(coinAmount > 0, "The quantity is less than the minimum"); require(orcl.val() > 0, "Oracle price not initialized."); require(<FILL_ME>) address from = msg.sender; if (coins[from] == 0) { require( coinAmount >= params.minMint(), "First make coin must grater than minMint amount." ); } accuredToken(from); uint256 tokenAmount = getInputToken(coinAmount); token.transferFrom(from, address(this), tokenAmount); coin.mint(from, coinAmount); totalCoin = totalCoin.add(coinAmount); totalToken = totalToken.add(tokenAmount); coins[from] = coins[from].add(coinAmount); tokens[from] = tokens[from].add(tokenAmount); if (startRewardBlock == 0) { startRewardBlock = getBlockNumber(); } emit StakeEvent(tokenAmount, coinAmount); } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
params.isNormal(orcl.val()),"STPT's price is too low."
291,972
params.isNormal(orcl.val())
"Redeem paused"
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { require(<FILL_ME>) address staker = msg.sender; require(coins[staker] > 0, "No collateral"); require(coinAmount > 0, "The quantity is less than zero"); require(coinAmount <= coins[staker], "input amount overflow"); accuredToken(staker); uint256 tokenAmount = getInputToken(coinAmount); uint256 feeRate = params.feeRate(); uint256 fee = tokenAmount.mul(feeRate).div(1000); uint256 _pmFee = fee.div(3); uint256 move = tokenAmount.sub(fee); sFee = sFee.add(fee); pmFee = pmFee.add(_pmFee); token.transfer(pmFeeHolder, _pmFee); token.transfer(blackhole, fee - _pmFee); coin.burn(staker, coinAmount); token.transfer(receiver, move); coins[staker] = coins[staker].sub(coinAmount); tokens[staker] = tokens[staker].sub(tokenAmount); totalCoin = totalCoin.sub(coinAmount); totalToken = totalToken.sub(tokenAmount); emit RedeemEvent(tokenAmount, move, fee, coinAmount); } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
!esm.isRedeemPaused(),"Redeem paused"
291,972
!esm.isRedeemPaused()
"No collateral"
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { require(!esm.isRedeemPaused(), "Redeem paused"); address staker = msg.sender; require(<FILL_ME>) require(coinAmount > 0, "The quantity is less than zero"); require(coinAmount <= coins[staker], "input amount overflow"); accuredToken(staker); uint256 tokenAmount = getInputToken(coinAmount); uint256 feeRate = params.feeRate(); uint256 fee = tokenAmount.mul(feeRate).div(1000); uint256 _pmFee = fee.div(3); uint256 move = tokenAmount.sub(fee); sFee = sFee.add(fee); pmFee = pmFee.add(_pmFee); token.transfer(pmFeeHolder, _pmFee); token.transfer(blackhole, fee - _pmFee); coin.burn(staker, coinAmount); token.transfer(receiver, move); coins[staker] = coins[staker].sub(coinAmount); tokens[staker] = tokens[staker].sub(tokenAmount); totalCoin = totalCoin.sub(coinAmount); totalToken = totalToken.sub(tokenAmount); emit RedeemEvent(tokenAmount, move, fee, coinAmount); } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
coins[staker]>0,"No collateral"
291,972
coins[staker]>0
"System not Closed yet."
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { require(<FILL_ME>) address from = msg.sender; require(coinAmount > 0, "The quantity is less than zero"); require(coin.balanceOf(from) > 0, "The coin no balance."); require(coinAmount <= coin.balanceOf(from), "Coin balance exceed"); uint256 tokenAmount = getInputToken(coinAmount); coin.burn(from, coinAmount); token.transfer(receiver, tokenAmount); totalCoin = totalCoin.sub(coinAmount); totalToken = totalToken.sub(tokenAmount); emit RedeemEvent(tokenAmount, tokenAmount, 0, coinAmount); } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
esm.isClosed(),"System not Closed yet."
291,972
esm.isClosed()
"The coin no balance."
// SPDX-License-Identifier: MIT pragma solidity >=0.5.0 <0.8.0; import "./Math.sol"; import "./SafeMath.sol"; import "./IERC20.sol"; import "./Owned.sol"; import "./IDparam.sol"; import "./WhiteList.sol"; interface IOracle { function val() external returns (uint256); function poke(uint256 price) external; function peek() external; } interface IESM { function isStakePaused() external view returns (bool); function isRedeemPaused() external view returns (bool); function isClosed() external view returns (bool); function time() external view returns (uint256); function shutdown() external; } interface ICoin { function burn(address account, uint256 amount) external; function mint(address account, uint256 amount) external; function balanceOf(address account) external view returns (uint256); } contract FrontStake is Owned, WhiteList { using Math for uint256; using SafeMath for uint256; /** * @notice Struct reward pools state * @param index Accumulated earnings index * @param block Update index, updating blockNumber together */ struct RewardState { uint256 index; uint256 block; } /** * @notice reward pools state * @param index Accumulated earnings index by staker * @param reward Accumulative reward */ struct StakerState { uint256 index; uint256 reward; } /// @notice TThe reward pool put into by the project side uint256 public reward; /// @notice The number of token per-block uint256 public rewardSpeed = 0.5787e18; /// @notice Inital index uint256 public initialIndex = 1e36; /// @notice Amplification factor uint256 public doubleScale = 1e36; /// @notice The instance reward pools state RewardState public rewardState; /// @notice All staker-instances state mapping(address => StakerState) public stakerStates; /// @notice The amount by staker with token mapping(address => uint256) public tokens; /// @notice The amount by staker with coin mapping(address => uint256) public coins; /// @notice The total amount of out-coin in sys uint256 public totalCoin; /// @notice The total amount of stake-token in sys uint256 public totalToken; /// @notice Cumulative service fee, it will be burn, not join reward. uint256 public sFee; uint256 public pmFee; address public pmFeeHolder = 0x1CFC820F300103fC58a8804c221846fD25eC32D5; uint256 constant ONE = 10**8; address constant blackhole = 0x188407eeD7B1bb203dEd6801875C0B5Cb1027053; uint256 public startRewardBlock; /// @notice Dparam address IDparam params; /// @notice Oracle address IOracle orcl; /// @notice Esm address IESM esm; /// @notice Coin address ICoin coin; /// @notice Token address IERC20 token; /// @notice Setup Oracle address success event SetupOracle(address orcl); /// @notice Setup Dparam address success event SetupParam(address param); /// @notice Setup Esm address success event SetupEsm(address esm); /// @notice Setup Token&Coin address success event SetupCoin(address token, address coin); /// @notice Stake success event StakeEvent(uint256 token, uint256 coin); /// @notice redeem success event RedeemEvent(uint256 token, uint256 move, uint256 fee, uint256 coin); /// @notice Update index success event IndexUpdate(uint256 delt, uint256 block, uint256 index); /// @notice ClaimToken success event ClaimToken(address holder, uint256 amount); /// @notice InjectReward success event InjectReward(uint256 amount); /// @notice ExtractReward success event ExtractReward(address reciver, uint256 amount); /** * @notice Construct a new OinStake, owner by msg.sender * @param _param Dparam address * @param _orcl Oracle address * @param _esm Esm address */ constructor( address _param, address _orcl, address _esm ) public Owned(msg.sender) { } modifier notClosed() { } /** * @notice reset Dparams address. * @param _params Configuration dynamic params contract address */ function setupParams(address _params) public onlyWhiter { } /** * @notice reset Oracle address. * @param _orcl Configuration Oracle contract address */ function setupOracle(address _orcl) public onlyWhiter { } /** * @notice reset Esm address. * @param _esm Configuration Esm contract address */ function setupEsm(address _esm) public onlyWhiter { } /** * @notice get Dparam address. * @return Dparam contract address */ function getParamsAddr() public view returns (address) { } /** * @notice get Oracle address. * @return Oracle contract address */ function getOracleAddr() public view returns (address) { } /** * @notice get Esm address. * @return Esm contract address */ function getEsmAddr() public view returns (address) { } /** * @notice get token of staking address. * @return ERC20 address */ function getCoinAddress() public view returns (address) { } /** * @notice get StableToken address. * @return ERC20 address */ function getTokenAddress() public view returns (address) { } /** * @notice inject token address & coin address only once. * @param _token token address * @param _coin coin address */ function setup(address _token, address _coin) public onlyWhiter { } /** * @notice Get the number of debt by the `account` * @param account token address * @return (tokenAmount,coinAmount) */ function debtOf(address account) public view returns (uint256, uint256) { } /** * @notice Get the number of debt by the `account` * @param coinAmount The amount that staker want to get stableToken * @return The amount that staker want to transfer token. */ function getInputToken(uint256 coinAmount) public view returns (uint256 tokenAmount) { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be staking */ function stake(uint256 coinAmount) external notClosed { } /** * @notice Normally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _normalRedeem(uint256 coinAmount, address receiver) internal notClosed { } /** * @notice Abnormally redeem anyAmount internal * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function _abnormalRedeem(uint256 coinAmount, address receiver) internal { require(esm.isClosed(), "System not Closed yet."); address from = msg.sender; require(coinAmount > 0, "The quantity is less than zero"); require(<FILL_ME>) require(coinAmount <= coin.balanceOf(from), "Coin balance exceed"); uint256 tokenAmount = getInputToken(coinAmount); coin.burn(from, coinAmount); token.transfer(receiver, tokenAmount); totalCoin = totalCoin.sub(coinAmount); totalToken = totalToken.sub(tokenAmount); emit RedeemEvent(tokenAmount, tokenAmount, 0, coinAmount); } /** * @notice Normally redeem anyAmount * @param coinAmount The number of coin will be redeemed * @param receiver Address of receiving */ function redeem(uint256 coinAmount, address receiver) public { } /** * @notice Normally redeem anyAmount to msg.sender * @param coinAmount The number of coin will be redeemed */ function redeem(uint256 coinAmount) public { } /** * @notice normally redeem them all at once * @param holder reciver */ function redeemMax(address holder) public { } /** * @notice normally redeem them all at once to msg.sender */ function redeemMax() public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin * @param receiver Address of receiving */ function oRedeem(uint256 coinAmount, address receiver) public { } /** * @notice System shutdown under the redemption rule * @param coinAmount The number coin */ function oRedeem(uint256 coinAmount) public { } /** * @notice Refresh reward speed. */ function setRewardSpeed(uint256 speed) public onlyWhiter { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count */ function updateIndex() public { } /** * @notice Used to correct the effect of one's actions on one's own earnings * System shutdown will no longer count * @param account staker address */ function accuredToken(address account) internal { } /** * @notice Calculate the current holder's mining income * @param staker Address of holder */ function _getReward(address staker) internal view returns (uint256 value) { } /** * @notice Estimate the mortgagor's reward * @param account Address of staker */ function getHolderReward(address account) public view returns (uint256 value) { } /** * @notice Extract the current reward in one go * @param holder Address of receiver */ function claimToken(address holder) public { } /** * @notice Get block number now */ function getBlockNumber() public view returns (uint256) { } /** * @notice Inject token to reward * @param amount The number of injecting */ function injectReward(uint256 amount) external onlyOwner { } /** * @notice Extract token from reward * @param account Address of receiver * @param amount The number of extracting */ function extractReward(address account, uint256 amount) external onlyOwner { } function setupParam( uint256 liquidationLine, uint256 minMint, uint256 _feeRate, uint256 _rewardSpeed ) public onlyWhiter { } }
coin.balanceOf(from)>0,"The coin no balance."
291,972
coin.balanceOf(from)>0
null
/** *Submitted for verification at Etherscan.io on 2020-06-05 */ // Copyright (C) 2020 Maker Ecosystem Growth Holdings, INC. // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Affero General Public License for more details. // // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. pragma solidity ^0.5.15; import "./provableAPI_0.5.sol"; contract Draft90TokenAbstract { function mint(address account, uint256 amount) public; function burn(address account, uint256 amount) public; function balanceOf(address tokenOwner) public view returns (uint balance); } contract Draft180TokenAbstract { function mint(address account, uint256 amount) public; function burn(address account, uint256 amount) public; function balanceOf(address tokenOwner) public view returns (uint balance); } contract Draft270TokenAbstract { function mint(address account, uint256 amount) public; function burn(address account, uint256 amount) public; function balanceOf(address tokenOwner) public view returns (uint balance); } contract ADVMainAbstract { function mintADVToken(address to, uint amount) external; function burnADVToken() external; } contract IERC20Token { function transferFrom(address from, address to, uint tokens) public returns (bool success); function allowance(address owner, address spender) external view returns (uint256); } contract DraftMain is usingProvable { Draft90TokenAbstract public d90Token = Draft90TokenAbstract(0x50c26bDD0cCB78Ad61c7224b951E8caCCbC40319); Draft180TokenAbstract public d180Token = Draft180TokenAbstract(0x11D25fd9bD9220564b0C942f950833Dc6ADd2D21); Draft270TokenAbstract public d270Token = Draft270TokenAbstract(0x8b7A5234CdbB856d0712D4c63cb31a5Ed6f8d3D8); address public easyMainAddr; address public advTokenAddr; address payable public owner; struct LockList { address account; uint256 amount; uint256 time; } uint256 public ethusd = 0; uint public updatePriceFreq = 30 hours; uint constant d90Limit = 256 * 10**18; uint constant d180Limit = 512 * 10**18; uint constant d270Limit = 768 * 10**18; LockList[] public d90LockList; LockList[] public d180LockList; LockList[] public d270LockList; address payable public xi; address payable public mariano; address payable public marketing; address payable public vault; uint public d90Index; uint public d180Index; uint public d270Index; uint public d90LockedAmount; uint public d180LockedAmount; uint public d270LockedAmount; event LogPriceUpdated(string price); event LogNewProvableQuery(string description); modifier onlyOwner { } constructor(address payable _xi, address payable _mariano, address payable _marketing, address payable _vault, uint256 _ethusd) public { } function setEasymainAddr(address _addr) public onlyOwner { } function setAdvTokenAddr(address _addr) public onlyOwner { } function buyDraftTokenByADV(uint amount, address payable sponsor) public { require(sponsor != address(0x0)); require(amount > 0); uint diffAmount = 0; require(<FILL_ME>) IERC20Token(advTokenAddr).transferFrom(msg.sender, easyMainAddr, amount * 15); d90Token.mint(msg.sender, amount); d180Token.mint(msg.sender, amount); d270Token.mint(msg.sender, amount); d90LockList.push(LockList(msg.sender, amount, now)); d180LockList.push(LockList(msg.sender, amount, now)); d270LockList.push(LockList(msg.sender, amount, now)); d90LockedAmount = d90LockedAmount + amount; d180LockedAmount = d180LockedAmount + amount; d270LockedAmount = d270LockedAmount + amount; while (d90LockedAmount > d90Limit) { diffAmount = d90LockedAmount - d90Limit; if (d90LockList[d90Index].amount > diffAmount) { d90LockList[d90Index].amount = d90LockList[d90Index].amount - diffAmount; d90LockedAmount = d90LockedAmount - diffAmount; } else { d90LockedAmount = d90LockedAmount - d90LockList[d90Index].amount; delete d90LockList[d90Index]; d90Index ++; } } while (d180LockedAmount > d180Limit) { diffAmount = d180LockedAmount - d180Limit; if (d180LockList[d180Index].amount > diffAmount) { d180LockList[d180Index].amount = d180LockList[d180Index].amount - diffAmount; d180LockedAmount = d180LockedAmount - diffAmount; } else { d180LockedAmount = d180LockedAmount - d180LockList[d180Index].amount; delete d180LockList[d180Index]; d180Index ++; } } while (d270LockedAmount > d270Limit) { diffAmount = d270LockedAmount - d270Limit; if (d270LockList[d270Index].amount > diffAmount) { d270LockList[d270Index].amount = d270LockList[d270Index].amount - diffAmount; d270LockedAmount = d270LockedAmount - diffAmount; } else { d270LockedAmount = d270LockedAmount - d270LockList[d270Index].amount; delete d270LockList[d270Index]; d270Index ++; } } ADVMainAbstract(easyMainAddr).burnADVToken(); // uint oneper = amount * 1500 / ethusd / 100; uint oneper = amount * 15 / ethusd; address(xi).transfer(oneper); address(mariano).transfer(oneper); address(marketing).transfer(oneper * 8); address(sponsor).transfer(oneper * 10); address(vault).transfer(oneper * 50); } function buyDraftTokenByETH(uint amount, address payable sponsor) public payable { } function getD90LockedAmount(address account) public view returns (uint) { } function getD180LockedAmount(address account) public view returns (uint) { } function getD270LockedAmount(address account) public view returns (uint) { } function getD90AvailableAmount(address account) public view returns(uint) { } function getD180AvailableAmount(address account) public view returns(uint) { } function getD270AvailableAmount(address account) public view returns(uint) { } function () external payable { } function claimD90Token(uint amount) public { } function claimD180Token(uint amount) public { } function claimD270Token(uint amount) public { } function updateETHPrice(uint price) public onlyOwner { } function unlockTimedToken() public onlyOwner { } function sendEth(address payable to, uint amount) public onlyOwner { } function setEthUsd(uint256 _ethusd) public onlyOwner { } function __callback(bytes32 myid, string memory result) public { } function updatePrice() public payable { } function withdrawBalance(uint amount) public onlyOwner { } }
IERC20Token(advTokenAddr).allowance(msg.sender,address(this))>=amount*15
291,988
IERC20Token(advTokenAddr).allowance(msg.sender,address(this))>=amount*15