comment
stringlengths
1
211
βŒ€
input
stringlengths
155
20k
label
stringlengths
4
1k
original_idx
int64
203
514k
predicate
stringlengths
1
1k
"Requires creator to implement ICreatorCore"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /// @author: eucliiid.xyz ///////////////////////////////////////////////////////////////////////////////////////// // ▐▄, , // // β–ˆβ–ˆβ–„ β–β–„βŒβ•“β–“L ]C // // β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–„β–„ β–„β–„β–„β–ˆβ–ˆβ–„β–„β–Œ // // β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–„β–ˆ β–„β–„β–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–€β–ˆβ–ˆβ–ˆβ–ˆβ–„ // // β–β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆM ,β–„β–„β–„β–„β–„Γ§ β–ˆβ–ˆβ–ˆβŒ β–„β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–Œ,β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ // // β–β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„β–„ 'β–€β–ˆβ–ˆβ–ˆβŒ 4β–€β–€β–€β–€β–€β–€β–€β”” β”Œβ–ˆβ–ˆβ–ˆβ–ˆ -β–€β–€β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€ β–€β–€β–€ // // β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ - β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ ,β–ˆ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ // // 'β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ. β–„β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ // // β””β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ 'β–€'β–€β–€β–€β–€β–€β–€β–€β–€β”” β–ˆβ–ˆβ–ˆ"β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ ]β–ˆβ–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ• Β¬β–ˆβ–ˆβ–ˆ β–„β–ˆβ–€ β””β–ˆβ–ˆβ–ˆ // // β–β–ˆβ–„ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ β–„β–ˆβ–ˆ- β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„β–„β–„β–„β–„β–ˆβ–ˆβ–ˆβ–ˆ β–„β–ˆ" β–ˆβ–ˆβ–ˆ // // β–€β–ˆβ–ˆβ–„ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆ' ,β–„β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ ,β–ˆβ–ˆβ–„β–„β–„β–„β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„, β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€β–ˆβ–ˆβ–ˆβ–„β–ˆ- β–„β–ˆβ–ˆβ–Œ // // β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ" ,β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€β–€ β•™β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€ // // Β¬β–€β–€β–€β–€β–€" β–„β–„β–ˆβ–ˆβ–ˆβ–€β–€β–€β–€β–€Β¬ "β–€- β–β–ˆβ–€β–€β–ˆβ–ˆβ–ˆβ–€β”” // // .═▀└ β•’β–ˆ` // // Γ… // ///////////////////////////////////////////////////////////////////////////////////////// import "@openzeppelin/contracts-upgradeable/token/ERC721/ERC721Upgradeable.sol"; import "@manifoldxyz/libraries-solidity/contracts/access/AdminControlUpgradeable.sol"; import "../../extensions/ERC721/ERC721CreatorExtensionBurnable.sol"; import "../../extensions/CreatorExtensionBasic.sol"; contract BrockSeals is ERC721CreatorExtensionBurnable, CreatorExtensionBasic { function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721CreatorExtensionBurnable, CreatorExtensionBasic) returns (bool) { } function mint(address creator, address to, string memory uri) external adminRequired returns (uint256) { } /** * @dev See {ICreatorExtensionBasic-setBaseTokenURI}. */ function setBaseTokenURI(address creator, string calldata uri) external virtual override adminRequired { require(<FILL_ME>) ICreatorCore(creator).setBaseTokenURIExtension(uri); } /** * @dev See {ICreatorExtensionBasic-setTokenURI}. */ function setTokenURI(address creator, uint256 tokenId, string calldata uri) external virtual override adminRequired { } /** * @dev See {ICreatorExtensionBasic-setTokenURIPrefix}. */ function setTokenURIPrefix(address creator, string calldata prefix) external override adminRequired { } }
ERC165Checker.supportsInterface(creator,type(ICreatorCore).interfaceId),"Requires creator to implement ICreatorCore"
297,926
ERC165Checker.supportsInterface(creator,type(ICreatorCore).interfaceId)
null
pragma solidity 0.4.24; /** * @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 public newOwner; address public adminer; 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 Throws if called by any account other than the adminer. */ modifier onlyAdminer { } /** * @dev Allows the current owner to transfer control of the contract to a new owner. * @param _owner The address to transfer ownership to. */ function transferOwnership(address _owner) public onlyOwner { } /** * @dev New owner accept control of the contract. */ function acceptOwnership() public { } /** * @dev change the control of the contract to a new adminer. * @param _adminer The address to transfer adminer to. */ function changeAdminer(address _adminer) public onlyOwner { } } /** * @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) { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface */ contract ERC20Basic { uint256 public totalSupply; 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 Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; /** * @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 balance) { } } /** * @title ERC20 interface */ 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 Standard ERC20 token * * @dev Implementation of the basic standard token. */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev transfer token for a specified address * @param _to The address to tran sfer to. * @param _value The amount to be transferred. */ function transfer(address _to, 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) { } /** * @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&#39;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) { } /** * 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 */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } /** * @title Mintable token */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Function to mint tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of tokens to mint. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { } } /** * @title Additioal token * @dev Mintable token with a token can be increased with proportion. */ contract AdditionalToken is MintableToken { uint256 public maxProportion; uint256 public lockedYears; uint256 public initTime; mapping(uint256 => uint256) public records; mapping(uint256 => uint256) public maxAmountPer; event MintRequest(uint256 _curTimes, uint256 _maxAmountPer, uint256 _curAmount); constructor(uint256 _maxProportion, uint256 _lockedYears) public { } /** * @dev Function to Increase tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of the minted tokens. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { uint256 curTime = block.timestamp; uint256 curTimes = curTime.sub(initTime)/(31536000); require(curTimes >= lockedYears); uint256 _maxAmountPer; if(maxAmountPer[curTimes] == 0) { maxAmountPer[curTimes] = totalSupply.mul(maxProportion).div(100); } _maxAmountPer = maxAmountPer[curTimes]; require(<FILL_ME>) records[curTimes] = records[curTimes].add(_amount); emit MintRequest(curTimes, _maxAmountPer, records[curTimes]); return(super.mint(_to, _amount)); } } /** * @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() onlyAdminer whenNotPaused public { } /** * @dev called by the owner to unpause, returns to normal state */ function unpause() onlyAdminer whenPaused public { } } /** * @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, uint _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Token contract */ contract Token is AdditionalToken, PausableToken { using SafeMath for uint256; string public name; string public symbol; uint256 public decimals; mapping(address => bool) public singleLockFinished; struct lockToken { uint256 amount; uint256 validity; } mapping(address => lockToken[]) public locked; event Lock( address indexed _of, uint256 _amount, uint256 _validity ); function () payable public { } constructor (string _symbol, string _name, uint256 _decimals, uint256 _initSupply, uint256 _maxProportion, uint256 _lockedYears) AdditionalToken(_maxProportion, _lockedYears) public { } /** * @dev Lock the special address * * @param _time The array of released timestamp * @param _amountWithoutDecimal The array of amount of released tokens * NOTICE: the amount in this function not include decimals. */ function lock(address _address, uint256[] _time, uint256[] _amountWithoutDecimal) onlyAdminer public returns(bool) { } function finishSingleLock(address _address) onlyAdminer public { } /** * @dev Returns tokens locked for a specified address for a * specified purpose at a specified time * * @param _of The address whose tokens are locked * @param _time The timestamp to query the lock tokens for */ function tokensLocked(address _of, uint256 _time) public view returns (uint256 amount) { } /** * @dev Returns tokens available for transfer for a specified address * @param _of The address to query the the lock tokens of */ function transferableBalanceOf(address _of) public view returns (uint256 amount) { } function transfer(address _to, uint256 _value) public returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyAdminer returns (bool success) { } }
records[curTimes].add(_amount)<=_maxAmountPer
298,044
records[curTimes].add(_amount)<=_maxAmountPer
null
pragma solidity 0.4.24; /** * @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 public newOwner; address public adminer; 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 Throws if called by any account other than the adminer. */ modifier onlyAdminer { } /** * @dev Allows the current owner to transfer control of the contract to a new owner. * @param _owner The address to transfer ownership to. */ function transferOwnership(address _owner) public onlyOwner { } /** * @dev New owner accept control of the contract. */ function acceptOwnership() public { } /** * @dev change the control of the contract to a new adminer. * @param _adminer The address to transfer adminer to. */ function changeAdminer(address _adminer) public onlyOwner { } } /** * @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) { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface */ contract ERC20Basic { uint256 public totalSupply; 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 Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; /** * @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 balance) { } } /** * @title ERC20 interface */ 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 Standard ERC20 token * * @dev Implementation of the basic standard token. */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev transfer token for a specified address * @param _to The address to tran sfer to. * @param _value The amount to be transferred. */ function transfer(address _to, 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) { } /** * @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&#39;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) { } /** * 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 */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } /** * @title Mintable token */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Function to mint tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of tokens to mint. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { } } /** * @title Additioal token * @dev Mintable token with a token can be increased with proportion. */ contract AdditionalToken is MintableToken { uint256 public maxProportion; uint256 public lockedYears; uint256 public initTime; mapping(uint256 => uint256) public records; mapping(uint256 => uint256) public maxAmountPer; event MintRequest(uint256 _curTimes, uint256 _maxAmountPer, uint256 _curAmount); constructor(uint256 _maxProportion, uint256 _lockedYears) public { } /** * @dev Function to Increase tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of the minted tokens. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { } } /** * @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() onlyAdminer whenNotPaused public { } /** * @dev called by the owner to unpause, returns to normal state */ function unpause() onlyAdminer whenPaused public { } } /** * @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, uint _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Token contract */ contract Token is AdditionalToken, PausableToken { using SafeMath for uint256; string public name; string public symbol; uint256 public decimals; mapping(address => bool) public singleLockFinished; struct lockToken { uint256 amount; uint256 validity; } mapping(address => lockToken[]) public locked; event Lock( address indexed _of, uint256 _amount, uint256 _validity ); function () payable public { } constructor (string _symbol, string _name, uint256 _decimals, uint256 _initSupply, uint256 _maxProportion, uint256 _lockedYears) AdditionalToken(_maxProportion, _lockedYears) public { } /** * @dev Lock the special address * * @param _time The array of released timestamp * @param _amountWithoutDecimal The array of amount of released tokens * NOTICE: the amount in this function not include decimals. */ function lock(address _address, uint256[] _time, uint256[] _amountWithoutDecimal) onlyAdminer public returns(bool) { require(<FILL_ME>) require(_time.length == _amountWithoutDecimal.length); if(locked[_address].length != 0) { locked[_address].length = 0; } uint256 len = _time.length; uint256 totalAmount = 0; uint256 i = 0; for(i = 0; i<len; i++) { totalAmount = totalAmount.add(_amountWithoutDecimal[i]*(10 ** decimals)); } require(balances[_address] >= totalAmount); for(i = 0; i < len; i++) { locked[_address].push(lockToken(_amountWithoutDecimal[i]*(10 ** decimals), block.timestamp.add(_time[i]))); emit Lock(_address, _amountWithoutDecimal[i]*(10 ** decimals), block.timestamp.add(_time[i])); } return true; } function finishSingleLock(address _address) onlyAdminer public { } /** * @dev Returns tokens locked for a specified address for a * specified purpose at a specified time * * @param _of The address whose tokens are locked * @param _time The timestamp to query the lock tokens for */ function tokensLocked(address _of, uint256 _time) public view returns (uint256 amount) { } /** * @dev Returns tokens available for transfer for a specified address * @param _of The address to query the the lock tokens of */ function transferableBalanceOf(address _of) public view returns (uint256 amount) { } function transfer(address _to, uint256 _value) public returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyAdminer returns (bool success) { } }
!singleLockFinished[_address]
298,044
!singleLockFinished[_address]
null
pragma solidity 0.4.24; /** * @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 public newOwner; address public adminer; 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 Throws if called by any account other than the adminer. */ modifier onlyAdminer { } /** * @dev Allows the current owner to transfer control of the contract to a new owner. * @param _owner The address to transfer ownership to. */ function transferOwnership(address _owner) public onlyOwner { } /** * @dev New owner accept control of the contract. */ function acceptOwnership() public { } /** * @dev change the control of the contract to a new adminer. * @param _adminer The address to transfer adminer to. */ function changeAdminer(address _adminer) public onlyOwner { } } /** * @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) { } } /** * @title ERC20Basic * @dev Simpler version of ERC20 interface */ contract ERC20Basic { uint256 public totalSupply; 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 Basic token * @dev Basic version of StandardToken, with no allowances. */ contract BasicToken is ERC20Basic { using SafeMath for uint256; mapping(address => uint256) balances; /** * @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 balance) { } } /** * @title ERC20 interface */ 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 Standard ERC20 token * * @dev Implementation of the basic standard token. */ contract StandardToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev transfer token for a specified address * @param _to The address to tran sfer to. * @param _value The amount to be transferred. */ function transfer(address _to, 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) { } /** * @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&#39;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) { } /** * 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 */ function increaseApproval(address _spender, uint _addedValue) public returns (bool) { } function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) { } } /** * @title Mintable token */ contract MintableToken is StandardToken, Ownable { event Mint(address indexed to, uint256 amount); /** * @dev Function to mint tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of tokens to mint. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { } } /** * @title Additioal token * @dev Mintable token with a token can be increased with proportion. */ contract AdditionalToken is MintableToken { uint256 public maxProportion; uint256 public lockedYears; uint256 public initTime; mapping(uint256 => uint256) public records; mapping(uint256 => uint256) public maxAmountPer; event MintRequest(uint256 _curTimes, uint256 _maxAmountPer, uint256 _curAmount); constructor(uint256 _maxProportion, uint256 _lockedYears) public { } /** * @dev Function to Increase tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of the minted tokens. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) onlyAdminer public returns (bool) { } } /** * @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() onlyAdminer whenNotPaused public { } /** * @dev called by the owner to unpause, returns to normal state */ function unpause() onlyAdminer whenPaused public { } } /** * @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, uint _addedValue) public whenNotPaused returns (bool success) { } function decreaseApproval(address _spender, uint _subtractedValue) public whenNotPaused returns (bool success) { } } /** * @title Token contract */ contract Token is AdditionalToken, PausableToken { using SafeMath for uint256; string public name; string public symbol; uint256 public decimals; mapping(address => bool) public singleLockFinished; struct lockToken { uint256 amount; uint256 validity; } mapping(address => lockToken[]) public locked; event Lock( address indexed _of, uint256 _amount, uint256 _validity ); function () payable public { } constructor (string _symbol, string _name, uint256 _decimals, uint256 _initSupply, uint256 _maxProportion, uint256 _lockedYears) AdditionalToken(_maxProportion, _lockedYears) public { } /** * @dev Lock the special address * * @param _time The array of released timestamp * @param _amountWithoutDecimal The array of amount of released tokens * NOTICE: the amount in this function not include decimals. */ function lock(address _address, uint256[] _time, uint256[] _amountWithoutDecimal) onlyAdminer public returns(bool) { require(!singleLockFinished[_address]); require(_time.length == _amountWithoutDecimal.length); if(locked[_address].length != 0) { locked[_address].length = 0; } uint256 len = _time.length; uint256 totalAmount = 0; uint256 i = 0; for(i = 0; i<len; i++) { totalAmount = totalAmount.add(_amountWithoutDecimal[i]*(10 ** decimals)); } require(<FILL_ME>) for(i = 0; i < len; i++) { locked[_address].push(lockToken(_amountWithoutDecimal[i]*(10 ** decimals), block.timestamp.add(_time[i]))); emit Lock(_address, _amountWithoutDecimal[i]*(10 ** decimals), block.timestamp.add(_time[i])); } return true; } function finishSingleLock(address _address) onlyAdminer public { } /** * @dev Returns tokens locked for a specified address for a * specified purpose at a specified time * * @param _of The address whose tokens are locked * @param _time The timestamp to query the lock tokens for */ function tokensLocked(address _of, uint256 _time) public view returns (uint256 amount) { } /** * @dev Returns tokens available for transfer for a specified address * @param _of The address to query the the lock tokens of */ function transferableBalanceOf(address _of) public view returns (uint256 amount) { } function transfer(address _to, uint256 _value) public returns (bool) { } function transferFrom(address _from, address _to, uint256 _value) public returns (bool) { } function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyAdminer returns (bool success) { } }
balances[_address]>=totalAmount
298,044
balances[_address]>=totalAmount
null
// SPDX-License-Identifier: MIT pragma solidity ^0.6.0; 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) { } } 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); } interface Callable { function tokenCallback(address _from, uint256 _tokens, bytes calldata _data) external returns (bool); } contract Context { constructor () internal { } function _msgSender() internal view virtual returns (address payable) { } function _msgData() internal view virtual returns (bytes memory) { } } contract Ownable { bool public paused = false; address public owner; event OwnershipTransferred(address previousOwner, address newOwner); event Pause(); event Unpause(); modifier onlyOwner { } modifier whenNotPaused() { } modifier whenPaused() { } constructor() public { } function isOwner(address wallet) public view returns(bool) { } function transferOwnership(address _newOwner, address _oldOwner) public onlyOwner { } function pause() public onlyOwner whenNotPaused { } function unpause() public onlyOwner whenPaused { } function _transferOwnership(address _newOwner, address _oldOwner) internal { } } contract ERC20 is Context, IERC20,Ownable { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) _burnWhitelist; string private _name; string private _symbol; uint8 private _decimals; uint256 private _totalSupply; constructor()public{ } function name() public view returns (string memory) { } function symbol() public view returns (string memory) { } function decimals() public view returns (uint8) { } function totalSupply() public view override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public virtual override returns (bool) { } function allowance(address owner, address spender) public view virtual override returns (uint256) { } function approve(address spender, uint256 amount) public virtual override returns (bool) { } function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) { } function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { } function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { } function _transfer(address sender, address recipient, uint256 amount) internal virtual returns(uint256){ } function transferAndCall(address _to, uint256 _tokens, bytes calldata _data) external returns (bool) { uint256 _transferred = _transfer(_msgSender(), _to, _tokens); uint32 _size; assembly { _size := extcodesize(_to) } if (_size > 0) { require(<FILL_ME>) } return true; } function _approve(address owner, address spender, uint256 amount) internal virtual { } function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { } } contract USDH is ERC20 { constructor() ERC20() public { } }
Callable(_to).tokenCallback(_msgSender(),_transferred,_data)
298,053
Callable(_to).tokenCallback(_msgSender(),_transferred,_data)
"max number of purchasable NFTs exceeded"
/* IhKIU2X5P1 K2Ks :5SS i51SKXSZ :X2P iIKQi uISY U1Uu17: iPQBd7 :BBBBBBQBQB .BBBX QBQB BBBBBBBB BBBB uBBBK rBQBJ .BBBBBBBB BBBBBBBB .Yi1BBBdiv IBQB BBBS BBBL:ii. BBBj hBBB: BBBB 2BBB.:BBBB 2BBB QBQi :BBB BBBB .BBB. :BBB BBB:bBBQ BBBB BQB5 LQBB BQBB BBB BBBB BBBE bBBB DBBB .: vBBBBQBQ .BBB7 BBB: 7BBB .BBBB BBBr rBBBBBBBBBd BBBBBBB BBBBQBB PBBQ rBBB BBBB BBBQi vBBB BBBBBQBBBQ: :BBBQQB: BQBBBQB. BBBB BQBB QBB2 7BBBY BQBB BBBI PBBB gBBB iBBB BBBB BBBY BBQ7 rBBB sJY JQBB BBQ7 iBBB BBBQ BBBY RBBB :BBBr 7BBB. :BQB BBBB BBB BBB: vBBB BBBB :BBQ7 .BBBBBBBr BQB5 BBBB BBBB BBBBIKBBBB BBBX gBBB BBBB .BBBb MBBB. QBBBBBBB: rBBQ: :BBBB .BBBB BBBBBBBBQ LQBBBBBBv r::. i:i :i:: ::::.::i .i:i :::7 ::i. :.::::. iYYv: EBBQ ... BQBZ BQBd BBBQ 7QBB: BQBg LBBBBBBB 5BBB .BBBBBZv BBBB :QBP gBBB. rBBBv .BBBu BBBB :QBBu BBBBBBBB rBBBB. MBBBBBBQB BBBP BBB1 BBBL QBBB 2BBQ BBBS 5BBB BBQ: BBBBB. QBB1 .BBBK BBBr IBBBr gBBB BQBB BBQB :QBB. BBBQ :BBB BBBBBB. BBB BBBQ BBB BBBB. BQB. .BBB7 BBBr PBBB BBBr ZBBBrYU IBQJvBQ: vBBB BBQE BBB.BBBBBrbQBU KBBB rBBB BBBD rBBB BBBBBBB .BBB vBBi BBQM BBBr BBQBBB BBBBBB BBBB BBBB :BBBi BBBB :BQBj7Y. BQB. KBBv BQBi rBBB. BBBBB. BBQBB. BBBJ BBB1 2BBB BBBj MBBB 2BBBs:BBBL 7BBB BBQB BBBBP BBBBM vBBB. iBBB. BBBB iBBB. BBBK .BBQBBBQBBu BBBQ 2BBB. .BBBB BBBB BBBB BBBBBBBB .BBBBBBB: BBBBBBBQ .BBBBBBBr BBBB.::BBBP BBBBBBBBB1 :BBBi BBBL .BBQB BQBBBBBv hBBBBBBB BBQBQBBL PBBBBBBB MBBB. QBBB 7BBBBBBBB: */ pragma solidity >=0.8.0 <0.9.0; contract SKYWALKERZ_NFT is ERC721Enumerable, Ownable { using Strings for uint256; string public baseURI; string public baseExtension = ".json"; uint256 public cost = .01 ether; uint256 public maxSupply = 4060; // How many NFTs can be purchasable (via the minting site or directly from this smart contract) uint256 public maxNumberPurchasable = 2030; uint256 public maxMintAmountPerSession = 10; uint256 public nftPerAddressLimit = 30; // How many NFTs were bought (via the minting site or directly via this smart contract) uint256 public totalNftsBoughtFromContract = 0; bool public paused = false; constructor( string memory _name, string memory _symbol, string memory _initBaseURI ) ERC721(_name, _symbol) { } // internal function _baseURI() internal view virtual override returns (string memory) { } // public function mint(uint256 _mintAmount) public payable { require(!paused, "the contract is paused"); uint256 supply = totalSupply(); require(_mintAmount > 0, "need to mint at least 1 NFT"); require(supply + _mintAmount <= maxSupply, "max NFT limit exceeded"); if (msg.sender != owner()) { uint256 ownerTokenCount = balanceOf(msg.sender); require(ownerTokenCount + _mintAmount <= nftPerAddressLimit, "max NFT per address exceeded"); require(_mintAmount <= maxMintAmountPerSession, "max mint amount per session exceeded"); require(msg.value >= cost * _mintAmount, "insufficient funds"); require(<FILL_ME>) totalNftsBoughtFromContract = totalNftsBoughtFromContract + _mintAmount; } for (uint256 i = 1; i <= _mintAmount; i++) { _safeMint(msg.sender, supply + i); } } // onlyOwner function mintToAddress(address to, uint256 _mintAmount) public onlyOwner() { } function walletOfOwner(address _owner) public view returns (uint256[] memory) { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setNftPerAddressLimit(uint256 _limit) public onlyOwner() { } function setCost(uint256 _newCost) public onlyOwner() { } function setMaxMintAmountPerSession(uint256 _newMaxMintAmountPerSession) public onlyOwner() { } function setMaxNumberPurchasable(uint256 _newMaxNumberPurchasable) public onlyOwner() { } function setBaseURI(string memory _newBaseURI) public onlyOwner { } function setBaseExtension(string memory _newBaseExtension) public onlyOwner { } function pause(bool _state) public onlyOwner { } function withdraw() public payable onlyOwner { } }
totalNftsBoughtFromContract+_mintAmount<=maxNumberPurchasable,"max number of purchasable NFTs exceeded"
298,055
totalNftsBoughtFromContract+_mintAmount<=maxNumberPurchasable
"EthPCVDripper: target balance too high"
pragma solidity ^0.6.0; pragma experimental ABIEncoderV2; import "../refs/CoreRef.sol"; import "../utils/Timed.sol"; /// @title a PCV dripper /// @author Fei Protocol contract EthPCVDripper is CoreRef, Timed { using Address for address payable; /// @notice target address to drip to address payable public target; /// @notice amount to drip after each window uint256 public amountToDrip; event Dripped(uint256 amount); event Withdrawal(address indexed to, uint256 amount); /// @notice ETH PCV Dripper constructor /// @param _core Fei Core for reference /// @param _target address to drip to /// @param _frequency frequency of dripping /// @param _amountToDrip amount to drip on each drip constructor( address _core, address payable _target, uint256 _frequency, uint256 _amountToDrip ) public CoreRef(_core) Timed(_frequency) { } receive() external payable {} /// @notice withdraw ETH from the PCV dripper /// @param amount of tokens withdrawn /// @param to the address to send PCV to function withdrawETH(address payable to, uint256 amount) external onlyPCVController { } /// @notice drip ETH to target function drip() external afterTime whenNotPaused { require(<FILL_ME>) // reset timer _initTimed(); // drip target.sendValue(amountToDrip); emit Dripped(amountToDrip); } /// @notice checks whether the target balance is less than the drip amount function isTargetBalanceLow() public view returns(bool) { } }
isTargetBalanceLow(),"EthPCVDripper: target balance too high"
298,063
isTargetBalanceLow()
null
pragma solidity ^0.4.20; // solhint-disable-line // similar as turtlefarmer, with three changes: // A. one third of your turtles die when you sell eggs // B. you can transfer ownership of the devfee through sacrificing turtles // C. the "free" 300 turtles cost 0.001 eth (in line with the mining fee) // bots should have a harder time, and whales can compete for the devfee contract TurtleFarmer{ //uint256 EGGS_PER_TURTLE_PER_SECOND=1; uint256 public EGGS_TO_HATCH_1TURTLE=86400;//for final version should be seconds in a day uint256 public STARTING_TURTLE=300; uint256 PSN=10000; uint256 PSNH=5000; bool public initialized=false; address public ceoAddress; mapping (address => uint256) public hatcheryTurtle; mapping (address => uint256) public claimedEggs; mapping (address => uint256) public lastHatch; mapping (address => address) public referrals; uint256 public marketEggs; uint256 public turtlemasterReq=100000; function TurtleFarmer() public{ } function becomeTurtlemaster() public{ require(initialized); require(<FILL_ME>) hatcheryTurtle[msg.sender]=SafeMath.sub(hatcheryTurtle[msg.sender],turtlemasterReq); turtlemasterReq=SafeMath.add(turtlemasterReq,100000);//+100k turtles each time ceoAddress=msg.sender; } function hatchEggs(address ref) public{ } function sellEggs() public{ } function buyEggs() public payable{ } //magic trade balancing algorithm function calculateTrade(uint256 rt,uint256 rs, uint256 bs) public view returns(uint256){ } function calculateEggSell(uint256 eggs) public view returns(uint256){ } function calculateEggBuy(uint256 eth,uint256 contractBalance) public view returns(uint256){ } function calculateEggBuySimple(uint256 eth) public view returns(uint256){ } function devFee(uint256 amount) public view returns(uint256){ } function seedMarket(uint256 eggs) public payable{ } function getFreeTurtle() public payable{ } function getBalance() public view returns(uint256){ } function getMyTurtle() public view returns(uint256){ } function getTurtlemasterReq() public view returns(uint256){ } function getMyEggs() public view returns(uint256){ } function getEggsSinceLastHatch(address adr) public view returns(uint256){ } function min(uint256 a, uint256 b) private pure returns (uint256) { } } 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 Substracts 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) { } }
hatcheryTurtle[msg.sender]>=turtlemasterReq
298,212
hatcheryTurtle[msg.sender]>=turtlemasterReq
null
pragma solidity ^0.4.20; // solhint-disable-line // similar as turtlefarmer, with three changes: // A. one third of your turtles die when you sell eggs // B. you can transfer ownership of the devfee through sacrificing turtles // C. the "free" 300 turtles cost 0.001 eth (in line with the mining fee) // bots should have a harder time, and whales can compete for the devfee contract TurtleFarmer{ //uint256 EGGS_PER_TURTLE_PER_SECOND=1; uint256 public EGGS_TO_HATCH_1TURTLE=86400;//for final version should be seconds in a day uint256 public STARTING_TURTLE=300; uint256 PSN=10000; uint256 PSNH=5000; bool public initialized=false; address public ceoAddress; mapping (address => uint256) public hatcheryTurtle; mapping (address => uint256) public claimedEggs; mapping (address => uint256) public lastHatch; mapping (address => address) public referrals; uint256 public marketEggs; uint256 public turtlemasterReq=100000; function TurtleFarmer() public{ } function becomeTurtlemaster() public{ } function hatchEggs(address ref) public{ } function sellEggs() public{ } function buyEggs() public payable{ } //magic trade balancing algorithm function calculateTrade(uint256 rt,uint256 rs, uint256 bs) public view returns(uint256){ } function calculateEggSell(uint256 eggs) public view returns(uint256){ } function calculateEggBuy(uint256 eth,uint256 contractBalance) public view returns(uint256){ } function calculateEggBuySimple(uint256 eth) public view returns(uint256){ } function devFee(uint256 amount) public view returns(uint256){ } function seedMarket(uint256 eggs) public payable{ } function getFreeTurtle() public payable{ require(initialized); require(msg.value==0.001 ether); //similar to mining fee, prevents bots ceoAddress.transfer(msg.value); //turtlemaster gets this entrance fee require(<FILL_ME>) lastHatch[msg.sender]=now; hatcheryTurtle[msg.sender]=STARTING_TURTLE; } function getBalance() public view returns(uint256){ } function getMyTurtle() public view returns(uint256){ } function getTurtlemasterReq() public view returns(uint256){ } function getMyEggs() public view returns(uint256){ } function getEggsSinceLastHatch(address adr) public view returns(uint256){ } function min(uint256 a, uint256 b) private pure returns (uint256) { } } 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 Substracts 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) { } }
hatcheryTurtle[msg.sender]==0
298,212
hatcheryTurtle[msg.sender]==0
"TombVault: Only the owner of the tomb klub can stake it"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.10; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; interface IKlub { function mint(address to, uint256 amount) external; } contract TombVault is Ownable, IERC721Receiver { struct Stake { uint24 tokenId; uint48 timestamp; address owner; } uint public KLUBS_PER_TOMB_PER_DAY = 5 * 1 ether; // tokenId to stake mapping(uint => Stake) public vault; uint public totalStaked; IERC721Enumerable public tomb = IERC721Enumerable(0x40f8719f2919a5DEDD2D5A67065df6EaC65c149C); IKlub public klub = IKlub(0xa0DB234a35AaF919b51E1F6Dc21c395EeF2F959d); event Staked(address owner, uint tokenId, uint value); event Unstaked(address owner, uint tokenId, uint value); event Claimed(address owner, uint amount); constructor() { } function setTomb(address _tomb) external onlyOwner { } function setKlub(address _klub) external onlyOwner { } function setKLUBS_PER_TOMB_PER_DAY(uint _KLUBS_PER_TOMB_PER_DAY) external onlyOwner { } function stake(uint[] calldata tokenIds) external { totalStaked += tokenIds.length; for (uint i = 0; i < tokenIds.length; i++) { uint tokenId = tokenIds[i]; require(<FILL_ME>) require(vault[tokenId].tokenId == 0, "TombVault: Token already staked"); tomb.transferFrom(msg.sender, address(this), tokenId); emit Staked(msg.sender, tokenId, block.timestamp); vault[tokenId] = Stake({ owner: msg.sender, tokenId: uint24(tokenId), timestamp: uint48(block.timestamp) }); } } function _unstakeMany(address account, uint[] calldata tokenIds) internal { } function claim(uint[] calldata tokenIds) external { } function claimForAddress(address account, uint[] calldata tokenIds) external { } function unstake(uint[] calldata tokenIds) external { } function _claim(address account, uint[] calldata tokenIds, bool _unstake) internal { } function unclamiedEarnings(uint[] calldata tokenIds) external view returns (uint) { } function balanceOf(address account) external view returns (uint) { } function tokensOfOwner(address account) external view returns (uint[] memory ownerTokens) { } function onERC721Received( address, address from, uint, bytes calldata ) external pure override returns (bytes4) { } }
tomb.ownerOf(tokenId)==msg.sender,"TombVault: Only the owner of the tomb klub can stake it"
298,277
tomb.ownerOf(tokenId)==msg.sender
"Initial tokens have already been minted!"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "erc721a/contracts/ERC721A.sol"; contract GrinderMfers is ERC721A { address public immutable owner; uint64 public price = 0.02 ether; uint64 forOwner = 100; uint64 public firstCount = 2000; uint64 public secondCount = 7900; uint64 maxPerTransaction = 20; bool firstFinished = false; bool allFinished = false; constructor(address _owner) ERC721A("GrinderMfers", "GMF") { } function _baseURI() internal pure override returns (string memory) { } function firstMint(uint256 quantity) external payable { require(<FILL_ME>) require(quantity <= maxPerTransaction, "Too many tokens requested!"); require(quantity <= firstCount, "Trying to mint more than available"); require(msg.value >= price * quantity, "Paying less"); if (firstCount == quantity) { firstFinished = true; price = 0.035 ether; } payable(owner).transfer(msg.value); firstCount -= uint64(quantity); _safeMint(msg.sender, quantity); } function secondMint(uint256 quantity) external payable { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } }
!firstFinished,"Initial tokens have already been minted!"
298,321
!firstFinished
"No tokens to mint!"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "erc721a/contracts/ERC721A.sol"; contract GrinderMfers is ERC721A { address public immutable owner; uint64 public price = 0.02 ether; uint64 forOwner = 100; uint64 public firstCount = 2000; uint64 public secondCount = 7900; uint64 maxPerTransaction = 20; bool firstFinished = false; bool allFinished = false; constructor(address _owner) ERC721A("GrinderMfers", "GMF") { } function _baseURI() internal pure override returns (string memory) { } function firstMint(uint256 quantity) external payable { } function secondMint(uint256 quantity) external payable { require(firstFinished, "Initial tokens need to be minted!"); require(<FILL_ME>) require(quantity <= maxPerTransaction, "Too many tokens requested!"); require(quantity <= secondCount, "Trying to mint more than available"); require(msg.value >= price * quantity, "Paying less"); if (secondCount == quantity) { allFinished = true; } payable(owner).transfer(msg.value); secondCount -= uint64(quantity); _safeMint(msg.sender, quantity); } function tokenURI(uint256 tokenId) public view override returns (string memory) { } }
!allFinished,"No tokens to mint!"
298,321
!allFinished
null
pragma solidity ^0.4.22; /** * @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 delegate; 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 { } function confirmChangeOwnership() public { } } /** * @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 Substracts 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) { } } contract TransferFilter is Ownable { bool public isTransferable; mapping( address => bool ) public mapAddressPass; mapping( address => bool ) public mapAddressBlock; event LogFilterPass(address indexed target, bool status); event LogFilterBlock(address indexed target, bool status); // if Token transfer modifier checkTokenTransfer(address source) { if (isTransferable == true) { require(<FILL_ME>) } else { require(mapAddressPass[source] == true); } _; } constructor() public { } function setTransferable(bool status) public onlyOwner { } function isInPassFilter(address user) public view returns (bool) { } function isInBlockFilter(address user) public view returns (bool) { } function addressToPass(address[] target, bool status) public onlyOwner { } function addressToBlock(address[] target, bool status) public onlyOwner { } } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 { uint256 public totalSupply; function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); 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 Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @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, TransferFilter { using SafeMath for uint256; mapping(address => uint256) balances; mapping (address => mapping (address => uint256)) internal allowed; modifier onlyPayloadSize(uint size) { } /** * @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) checkTokenTransfer(msg.sender) 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 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) onlyPayloadSize(3 * 32) checkTokenTransfer(_from) public returns (bool) { } function approve(address _spender, uint256 _value) onlyPayloadSize(2 * 32) checkTokenTransfer(msg.sender) 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) { } } contract BurnableToken is StandardToken { event Burn(address indexed from, uint256 value); function burn(address _from, uint256 _amount) public onlyOwner { } } /** * @title Mintable token * @dev Simple ERC20 Token example, with mintable token creation * @dev Issue: * https://github.com/OpenZeppelin/zeppelin-solidity/issues/120 * Based on code by TokenMarketNet: https://github.com/TokenMarketNet/ico/blob/master/contracts/MintableToken.sol */ contract MintableToken is BurnableToken { event Mint(address indexed to, uint256 amount); event MintFinished(); bool public mintingFinished = false; address public minter; constructor() public { } modifier canMint() { } modifier hasPermission() { } function () public payable { } /** * @dev Function to mint tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of tokens to mint. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) canMint hasPermission public returns (bool) { } /** * @dev Function to stop minting new tokens. * @return True if the operation was successful. */ function finishMinting() canMint onlyOwner public returns (bool) { } } contract VoltraCoin is MintableToken { string public constant name = "VoltraCoin"; // solium-disable-line uppercase string public constant symbol = "VLT"; // solium-disable-line uppercase uint8 public constant decimals = 18; // solium-disable-line uppercase /** * @dev Constructor that gives msg.sender all of existing tokens. */ constructor() public { } }
mapAddressBlock[source]==false
298,331
mapAddressBlock[source]==false
null
pragma solidity ^0.4.22; /** * @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 delegate; 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 { } function confirmChangeOwnership() public { } } /** * @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 Substracts 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) { } } contract TransferFilter is Ownable { bool public isTransferable; mapping( address => bool ) public mapAddressPass; mapping( address => bool ) public mapAddressBlock; event LogFilterPass(address indexed target, bool status); event LogFilterBlock(address indexed target, bool status); // if Token transfer modifier checkTokenTransfer(address source) { if (isTransferable == true) { require(mapAddressBlock[source] == false); } else { require(<FILL_ME>) } _; } constructor() public { } function setTransferable(bool status) public onlyOwner { } function isInPassFilter(address user) public view returns (bool) { } function isInBlockFilter(address user) public view returns (bool) { } function addressToPass(address[] target, bool status) public onlyOwner { } function addressToBlock(address[] target, bool status) public onlyOwner { } } /** * @title ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/20 */ contract ERC20 { uint256 public totalSupply; function balanceOf(address who) public view returns (uint256); function transfer(address to, uint256 value) public returns (bool); 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 Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); } /** * @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, TransferFilter { using SafeMath for uint256; mapping(address => uint256) balances; mapping (address => mapping (address => uint256)) internal allowed; modifier onlyPayloadSize(uint size) { } /** * @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) checkTokenTransfer(msg.sender) 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 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) onlyPayloadSize(3 * 32) checkTokenTransfer(_from) public returns (bool) { } function approve(address _spender, uint256 _value) onlyPayloadSize(2 * 32) checkTokenTransfer(msg.sender) 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) { } } contract BurnableToken is StandardToken { event Burn(address indexed from, uint256 value); function burn(address _from, uint256 _amount) public onlyOwner { } } /** * @title Mintable token * @dev Simple ERC20 Token example, with mintable token creation * @dev Issue: * https://github.com/OpenZeppelin/zeppelin-solidity/issues/120 * Based on code by TokenMarketNet: https://github.com/TokenMarketNet/ico/blob/master/contracts/MintableToken.sol */ contract MintableToken is BurnableToken { event Mint(address indexed to, uint256 amount); event MintFinished(); bool public mintingFinished = false; address public minter; constructor() public { } modifier canMint() { } modifier hasPermission() { } function () public payable { } /** * @dev Function to mint tokens * @param _to The address that will receive the minted tokens. * @param _amount The amount of tokens to mint. * @return A boolean that indicates if the operation was successful. */ function mint(address _to, uint256 _amount) canMint hasPermission public returns (bool) { } /** * @dev Function to stop minting new tokens. * @return True if the operation was successful. */ function finishMinting() canMint onlyOwner public returns (bool) { } } contract VoltraCoin is MintableToken { string public constant name = "VoltraCoin"; // solium-disable-line uppercase string public constant symbol = "VLT"; // solium-disable-line uppercase uint8 public constant decimals = 18; // solium-disable-line uppercase /** * @dev Constructor that gives msg.sender all of existing tokens. */ constructor() public { } }
mapAddressPass[source]==true
298,331
mapAddressPass[source]==true
"Only swap participants allowed to call the method"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { require(<FILL_ME>) _; } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
isParticipant[msg.sender]==true,"Only swap participants allowed to call the method"
298,520
isParticipant[msg.sender]==true
"Each token must have lockup period"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { require( status == Status.AddParties, "Unable to confirm parties in the current status" ); require(participants.length > 1, "Need at least two participants"); require(<FILL_ME>) _; } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
_doesEveryTokenHaveLockupPeriod(),"Each token must have lockup period"
298,520
_doesEveryTokenHaveLockupPeriod()
"Unable to confirm swap before all parties have deposited tokens"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { require(status == Status.WaitingDeposits, "Unable to confirm in the current status"); require(<FILL_ME>) _; } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
_haveEveryoneDeposited(),"Unable to confirm swap before all parties have deposited tokens"
298,520
_haveEveryoneDeposited()
"Unable to add the same party multiple times"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { require(_participant != address(0), "_participant is invalid address"); require(_token != address(0), "_token is invalid address"); require(_tokensForSwap > 0, "_tokensForSwap must be positive"); require(_tokensFee > 0, "_tokensFee must be positive"); require(_tokensTotal == _tokensForSwap.add(_tokensFee), "token amounts inconsistency"); require(<FILL_ME>) isParticipant[_participant] = true; SwapOffer memory offer = SwapOffer({ participant: _participant, token: _token, tokensForSwap: _tokensForSwap, withdrawnTokensForSwap: 0, tokensFee: _tokensFee, withdrawnFee: 0, tokensTotal: _tokensTotal, withdrawnTokensTotal: 0 }); participants.push(offer.participant); offerByToken[offer.token] = offer; tokenByParticipant[offer.participant] = offer.token; emit AddParty( offer.participant, offer.token, offer.tokensForSwap, offer.tokensFee, offer.tokensTotal ); } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
isParticipant[_participant]==false,"Unable to add the same party multiple times"
298,520
isParticipant[_participant]==false
"Lockup period for this token has been added already"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { require(_token != address(0), "Invalid token"); require( _secondsSinceLockupStart.length == _unlockedTokensPercentages.length, "Invalid lockup period" ); require(<FILL_ME>) require( offerByToken[_token].token != address(0), "There is no swap offer with this token" ); for (uint256 i = 0; i < _secondsSinceLockupStart.length; i++) { _addLockupStage( _token, LockupStage(_secondsSinceLockupStart[i], _unlockedTokensPercentages[i]) ); } _validateLockupStages(_token); } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
lockupStagesByToken[_token].length==0,"Lockup period for this token has been added already"
298,520
lockupStagesByToken[_token].length==0
"There is no swap offer with this token"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { require(_token != address(0), "Invalid token"); require( _secondsSinceLockupStart.length == _unlockedTokensPercentages.length, "Invalid lockup period" ); require( lockupStagesByToken[_token].length == 0, "Lockup period for this token has been added already" ); require(<FILL_ME>) for (uint256 i = 0; i < _secondsSinceLockupStart.length; i++) { _addLockupStage( _token, LockupStage(_secondsSinceLockupStart[i], _unlockedTokensPercentages[i]) ); } _validateLockupStages(_token); } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
offerByToken[_token].token!=address(0),"There is no swap offer with this token"
298,520
offerByToken[_token].token!=address(0)
"Unexpected multiowners state"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { require(_newOwner != address(0), "_newOwner is invalid address"); require(owners.length == 1, "Unable to transfer ownership in presence of multiowners"); require(<FILL_ME>) address[] memory newOwners = new address[](1); newOwners[0] = _newOwner; Ownable.transferOwnership(_newOwner); Multiownable.transferOwnership(newOwners); } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
owners[0]==owner,"Unexpected multiowners state"
298,520
owners[0]==owner
"The last lockup stage must unlock 100% of tokens"
/** * @title TokenSwap * This product is protected under license. Any unauthorized copy, modification, or use without * express written consent from the creators is prohibited. */ contract TokenSwap is Ownable, Multiownable { // LIBRARIES using BadERC20Aware for ERC20; using SafeMath for uint256; // TYPES enum Status {AddParties, WaitingDeposits, SwapConfirmed, SwapCanceled} struct SwapOffer { address participant; ERC20 token; uint256 tokensForSwap; uint256 withdrawnTokensForSwap; uint256 tokensFee; uint256 withdrawnFee; uint256 tokensTotal; uint256 withdrawnTokensTotal; } struct LockupStage { uint256 secondsSinceLockupStart; uint8 unlockedTokensPercentage; } // VARIABLES Status public status = Status.AddParties; uint256 internal startLockupAt; mapping(address => LockupStage[]) internal lockupStagesByToken; address[] internal participants; mapping(address => bool) internal isParticipant; mapping(address => address) internal tokenByParticipant; mapping(address => SwapOffer) internal offerByToken; // EVENTS event StatusUpdate(Status oldStatus, Status newStatus); event AddParty( address participant, ERC20 token, uint256 tokensForSwap, uint256 tokensFee, uint256 tokensTotal ); event AddLockupStage( ERC20 token, uint256 secondsSinceLockupStart, uint8 unlockedTokensPercentage ); event ConfirmParties(); event CancelSwap(); event ConfirmSwap(); event StartLockup(uint256 startLockupAt); event Withdraw(address participant, ERC20 token, uint256 amount); event WithdrawFee(ERC20 token, uint256 amount); event Reclaim(address participant, ERC20 token, uint256 amount); // MODIFIERS modifier onlyParticipant { } modifier canTransferOwnership { } modifier canAddParty { } modifier canAddLockupPeriod { } modifier canConfirmParties { } modifier canCancelSwap { } modifier canConfirmSwap { } modifier canWithdraw { } modifier canWithdrawFee { } modifier canReclaim { } // EXTERNAL METHODS /** * @dev Add new party to the swap. * @param _participant Address of the participant. * @param _token An ERC20-compliant token which participant is offering to swap. * @param _tokensForSwap How much tokens the participant wants to swap. * @param _tokensFee How much tokens will be payed as a fee. * @param _tokensTotal How much tokens the participant is offering (i.e. _tokensForSwap + _tokensFee). */ function addParty( address _participant, ERC20 _token, uint256 _tokensForSwap, uint256 _tokensFee, uint256 _tokensTotal ) external onlyOwner canAddParty { } /** * @dev Add lockup period stages for one of the tokens. * @param _token A token previously added via addParty. * @param _secondsSinceLockupStart Array of starts of the stages of the lockup period. * @param _unlockedTokensPercentages Array of percentages of the unlocked tokens. */ function addLockupPeriod( ERC20 _token, uint256[] _secondsSinceLockupStart, uint8[] _unlockedTokensPercentages ) external onlyOwner canAddLockupPeriod { } /** * @dev Confirm swap parties */ function confirmParties() external onlyOwner canConfirmParties { } /** * @dev Confirm swap. */ function confirmSwap() external canConfirmSwap onlyManyOwners { } /** * @dev Cancel swap. */ function cancelSwap() external canCancelSwap onlyManyOwners { } /** * @dev Withdraw tokens */ function withdraw() external onlyParticipant canWithdraw { } /** * @dev Withdraw swap fee */ function withdrawFee() external onlyOwner canWithdrawFee { } /** * @dev Reclaim tokens if a participant has deposited too much or if the swap has been canceled. */ function reclaim() external onlyParticipant canReclaim { } // PUBLIC METHODS /** * @dev Standard ERC223 function that will handle incoming token transfers. * * @param _from Token sender address. * @param _value Amount of tokens. * @param _data Transaction metadata. */ function tokenFallback(address _from, uint256 _value, bytes _data) public { } /** * @dev Transfer ownership. * @param _newOwner Address of the new owner. */ function transferOwnership(address _newOwner) public onlyOwner canTransferOwnership { } // INTERNAL METHODS /** * @dev Add lockup period stage */ function _addLockupStage(ERC20 _token, LockupStage _stage) internal { } /** * @dev Validate lock-up period configuration. */ function _validateLockupStages(ERC20 _token) internal view { LockupStage[] storage lockupStages = lockupStagesByToken[_token]; for (uint i = 0; i < lockupStages.length; i++) { LockupStage memory stage = lockupStages[i]; require( stage.unlockedTokensPercentage >= 0, "LockupStage.unlockedTokensPercentage must not be negative" ); require( stage.unlockedTokensPercentage <= 100, "LockupStage.unlockedTokensPercentage must not be greater than 100" ); if (i == 0) { continue; } LockupStage memory previousStage = lockupStages[i - 1]; require( stage.secondsSinceLockupStart > previousStage.secondsSinceLockupStart, "LockupStage.secondsSinceLockupStart must increase monotonically" ); require( stage.unlockedTokensPercentage > previousStage.unlockedTokensPercentage, "LockupStage.unlockedTokensPercentage must increase monotonically" ); } require(<FILL_ME>) } /** * @dev Change swap status. */ function _changeStatus(Status _newStatus) internal { } /** * @dev Check if every token has lockup period. */ function _doesEveryTokenHaveLockupPeriod() internal view returns(bool) { } /** * @dev Check whether every participant has deposited enough tokens for the swap to be confirmed. */ function _haveEveryoneDeposited() internal view returns(bool) { } /** * @dev Start lockup period */ function _startLockup() internal { } /** * @dev Find amount of tokens ready to be withdrawn by a swap party. */ function _withdrawableAmount(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of tokens ready to be withdrawn as the swap fee. */ function _withdrawableFee(SwapOffer _offer) internal view returns(uint256) { } /** * @dev Find amount of unlocked tokens, including withdrawn tokens. */ function _unlockedAmount(ERC20 _token, uint256 _totalAmount) internal view returns(uint256) { } /** * @dev Get percent of unlocked tokens */ function _getUnlockedTokensPercentage(ERC20 _token) internal view returns(uint256) { } }
lockupStages[lockupStages.length-1].unlockedTokensPercentage==100,"The last lockup stage must unlock 100% of tokens"
298,520
lockupStages[lockupStages.length-1].unlockedTokensPercentage==100
"Mints exceed 10 per address"
// SPDX-License-Identifier: MIT pragma solidity 0.8.11; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/interfaces/IERC2981.sol"; contract NFT is ERC721Enumerable, IERC2981, Ownable { using Strings for uint256; // Royalty vars address public royaltyRecipient = 0x339Ff26CF5E9332b59A6E37C2453c4B335b839d1; // koolkidz.eth uint256 public royaltyPercentage = 750; // starting at 7.5% royalty uint256 public SCALE = 10000; string private baseURI; string public baseExtension = ".json"; uint256 public cost = 0.08 ether; uint256 public reservedSupply = 250; uint256 public reservedMinted; uint256 public maxSupply = 5000; uint256 public maxMintAmountPresale = 2; uint256 public maxMintAmountPublic = 10; bool public presaleMintingEnabled = false; bool public publicMintingEnabled = false; bool public paused = false; bool public revealed = false; string public notRevealedUri; bytes32 public whitelistMerkleRoot; // keep track of how many each address has claimed mapping(address => uint256) public mintedAmount; constructor( string memory _name, string memory _symbol, string memory _initBaseURI, string memory _initNotRevealedUri ) ERC721(_name, _symbol) { } // internal function _baseURI() internal view virtual override returns (string memory) { } function mintPublic(uint256 _mintAmount) public payable onlyHumans { uint256 supply = totalSupply(); require(publicMintingEnabled, "Public minting is not enabled"); require(!paused, "Minting is paused"); require(_mintAmount > 0, "Cannot mint 0"); require( supply + _mintAmount <= maxSupply, "Cannot mint more than max supply" ); require(<FILL_ME>) require(msg.value >= cost * _mintAmount, "Not enough ETH"); mintedAmount[msg.sender] += _mintAmount; for (uint256 i = 1; i <= _mintAmount; i++) { _safeMint(msg.sender, supply + i); } } function mintPresale(bytes32[] calldata merkleProof, uint256 _mintAmount) public payable onlyHumans isValidMerkleProof(merkleProof, whitelistMerkleRoot) { } function mintReserved(uint256 _mintAmount) public { } function isWhitelistedInMerkleProof( address _account, bytes32[] calldata _merkleProof ) public view returns (bool) { } function walletOfOwner(address _owner) public view returns (uint256[] memory) { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } // ============ OWNER-ONLY ADMIN FUNCTIONS ============ function reveal() public onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPresaleMintingEnabled(bool _enabled) external onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPublicMintingEnabled(bool _enabled) external onlyOwner { } function setWhitelistMerkleRoot(bytes32 merkleRoot) external onlyOwner { } function setCost(uint256 _newCost) public onlyOwner { } function setRoyalty(uint256 _newRoyaltyPercentage) public onlyOwner { } function setRoyaltyRecipient(address _newRoyaltyRecipient) public onlyOwner { } function setMaxMintAmountPublic(uint256 _newMax) public onlyOwner { } function setNotRevealedURI(string memory _notRevealedURI) public onlyOwner { } function setBaseURI(string memory _newBaseURI) public onlyOwner { } function setBaseExtension(string memory _newBaseExtension) public onlyOwner { } function pause(bool _state) public onlyOwner { } function withdraw() public payable onlyOwner { } // ============ ROYALTIES ============ function royaltyInfo(uint256 tokenId, uint256 salePrice) public view returns (address receiver, uint256 royaltyAmount) { } function supportsInterface(bytes4 interfaceId) public view override(ERC721Enumerable, IERC165) returns (bool) { } // ============ MODIFIERS ============ /** * @dev Only allows EOA accounts to call function */ modifier onlyHumans() { } /** * @dev validates merkleProof */ modifier isValidMerkleProof(bytes32[] calldata merkleProof, bytes32 root) { } }
mintedAmount[msg.sender]+_mintAmount<=maxMintAmountPublic,"Mints exceed 10 per address"
298,526
mintedAmount[msg.sender]+_mintAmount<=maxMintAmountPublic
"Mints exceed 2 per address"
// SPDX-License-Identifier: MIT pragma solidity 0.8.11; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/interfaces/IERC2981.sol"; contract NFT is ERC721Enumerable, IERC2981, Ownable { using Strings for uint256; // Royalty vars address public royaltyRecipient = 0x339Ff26CF5E9332b59A6E37C2453c4B335b839d1; // koolkidz.eth uint256 public royaltyPercentage = 750; // starting at 7.5% royalty uint256 public SCALE = 10000; string private baseURI; string public baseExtension = ".json"; uint256 public cost = 0.08 ether; uint256 public reservedSupply = 250; uint256 public reservedMinted; uint256 public maxSupply = 5000; uint256 public maxMintAmountPresale = 2; uint256 public maxMintAmountPublic = 10; bool public presaleMintingEnabled = false; bool public publicMintingEnabled = false; bool public paused = false; bool public revealed = false; string public notRevealedUri; bytes32 public whitelistMerkleRoot; // keep track of how many each address has claimed mapping(address => uint256) public mintedAmount; constructor( string memory _name, string memory _symbol, string memory _initBaseURI, string memory _initNotRevealedUri ) ERC721(_name, _symbol) { } // internal function _baseURI() internal view virtual override returns (string memory) { } function mintPublic(uint256 _mintAmount) public payable onlyHumans { } function mintPresale(bytes32[] calldata merkleProof, uint256 _mintAmount) public payable onlyHumans isValidMerkleProof(merkleProof, whitelistMerkleRoot) { uint256 supply = totalSupply(); require(presaleMintingEnabled, "Presale minting is not enabled"); require(!paused, "Minting is paused"); require(_mintAmount > 0, "Cannot mint 0"); require( supply + _mintAmount <= maxSupply, "Cannot mint more than max supply" ); require(<FILL_ME>) require(msg.value >= cost * _mintAmount, "Not enough ETH"); mintedAmount[msg.sender] += _mintAmount; for (uint256 i = 1; i <= _mintAmount; i++) { _safeMint(msg.sender, supply + i); } } function mintReserved(uint256 _mintAmount) public { } function isWhitelistedInMerkleProof( address _account, bytes32[] calldata _merkleProof ) public view returns (bool) { } function walletOfOwner(address _owner) public view returns (uint256[] memory) { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } // ============ OWNER-ONLY ADMIN FUNCTIONS ============ function reveal() public onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPresaleMintingEnabled(bool _enabled) external onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPublicMintingEnabled(bool _enabled) external onlyOwner { } function setWhitelistMerkleRoot(bytes32 merkleRoot) external onlyOwner { } function setCost(uint256 _newCost) public onlyOwner { } function setRoyalty(uint256 _newRoyaltyPercentage) public onlyOwner { } function setRoyaltyRecipient(address _newRoyaltyRecipient) public onlyOwner { } function setMaxMintAmountPublic(uint256 _newMax) public onlyOwner { } function setNotRevealedURI(string memory _notRevealedURI) public onlyOwner { } function setBaseURI(string memory _newBaseURI) public onlyOwner { } function setBaseExtension(string memory _newBaseExtension) public onlyOwner { } function pause(bool _state) public onlyOwner { } function withdraw() public payable onlyOwner { } // ============ ROYALTIES ============ function royaltyInfo(uint256 tokenId, uint256 salePrice) public view returns (address receiver, uint256 royaltyAmount) { } function supportsInterface(bytes4 interfaceId) public view override(ERC721Enumerable, IERC165) returns (bool) { } // ============ MODIFIERS ============ /** * @dev Only allows EOA accounts to call function */ modifier onlyHumans() { } /** * @dev validates merkleProof */ modifier isValidMerkleProof(bytes32[] calldata merkleProof, bytes32 root) { } }
mintedAmount[msg.sender]+_mintAmount<=maxMintAmountPresale,"Mints exceed 2 per address"
298,526
mintedAmount[msg.sender]+_mintAmount<=maxMintAmountPresale
"Cannot mint more than reserved supply"
// SPDX-License-Identifier: MIT pragma solidity 0.8.11; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/interfaces/IERC2981.sol"; contract NFT is ERC721Enumerable, IERC2981, Ownable { using Strings for uint256; // Royalty vars address public royaltyRecipient = 0x339Ff26CF5E9332b59A6E37C2453c4B335b839d1; // koolkidz.eth uint256 public royaltyPercentage = 750; // starting at 7.5% royalty uint256 public SCALE = 10000; string private baseURI; string public baseExtension = ".json"; uint256 public cost = 0.08 ether; uint256 public reservedSupply = 250; uint256 public reservedMinted; uint256 public maxSupply = 5000; uint256 public maxMintAmountPresale = 2; uint256 public maxMintAmountPublic = 10; bool public presaleMintingEnabled = false; bool public publicMintingEnabled = false; bool public paused = false; bool public revealed = false; string public notRevealedUri; bytes32 public whitelistMerkleRoot; // keep track of how many each address has claimed mapping(address => uint256) public mintedAmount; constructor( string memory _name, string memory _symbol, string memory _initBaseURI, string memory _initNotRevealedUri ) ERC721(_name, _symbol) { } // internal function _baseURI() internal view virtual override returns (string memory) { } function mintPublic(uint256 _mintAmount) public payable onlyHumans { } function mintPresale(bytes32[] calldata merkleProof, uint256 _mintAmount) public payable onlyHumans isValidMerkleProof(merkleProof, whitelistMerkleRoot) { } function mintReserved(uint256 _mintAmount) public { require( msg.sender == owner() || msg.sender == royaltyRecipient, "Only owners can mint reserved" ); require(!paused, "Minting is paused"); require(_mintAmount > 0, "Cannot mint 0"); require(<FILL_ME>) uint256 startingID = reservedMinted; for (uint256 i = 1; i <= _mintAmount; i++) { _mint(msg.sender, startingID + i); reservedMinted++; } } function isWhitelistedInMerkleProof( address _account, bytes32[] calldata _merkleProof ) public view returns (bool) { } function walletOfOwner(address _owner) public view returns (uint256[] memory) { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } // ============ OWNER-ONLY ADMIN FUNCTIONS ============ function reveal() public onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPresaleMintingEnabled(bool _enabled) external onlyOwner { } // NOTE: before enabling, make sure all reserved NFTs minted function setPublicMintingEnabled(bool _enabled) external onlyOwner { } function setWhitelistMerkleRoot(bytes32 merkleRoot) external onlyOwner { } function setCost(uint256 _newCost) public onlyOwner { } function setRoyalty(uint256 _newRoyaltyPercentage) public onlyOwner { } function setRoyaltyRecipient(address _newRoyaltyRecipient) public onlyOwner { } function setMaxMintAmountPublic(uint256 _newMax) public onlyOwner { } function setNotRevealedURI(string memory _notRevealedURI) public onlyOwner { } function setBaseURI(string memory _newBaseURI) public onlyOwner { } function setBaseExtension(string memory _newBaseExtension) public onlyOwner { } function pause(bool _state) public onlyOwner { } function withdraw() public payable onlyOwner { } // ============ ROYALTIES ============ function royaltyInfo(uint256 tokenId, uint256 salePrice) public view returns (address receiver, uint256 royaltyAmount) { } function supportsInterface(bytes4 interfaceId) public view override(ERC721Enumerable, IERC165) returns (bool) { } // ============ MODIFIERS ============ /** * @dev Only allows EOA accounts to call function */ modifier onlyHumans() { } /** * @dev validates merkleProof */ modifier isValidMerkleProof(bytes32[] calldata merkleProof, bytes32 root) { } }
reservedMinted+_mintAmount<=reservedSupply,"Cannot mint more than reserved supply"
298,526
reservedMinted+_mintAmount<=reservedSupply
ERROR_SENDER_NOT_ARBITRABLE
pragma solidity ^0.5.8; contract AragonCourt is Controller, IArbitrator { using Uint256Helpers for uint256; string private constant ERROR_SUBSCRIPTION_NOT_PAID = "AC_SUBSCRIPTION_NOT_PAID"; string private constant ERROR_SENDER_NOT_ARBITRABLE = "AC_SENDER_NOT_ARBITRABLE"; // Arbitrable interface ID based on ERC-165 bytes4 private constant ARBITRABLE_INTERFACE_ID = bytes4(0x88f3ee69); /** * @dev Constructor function * @param _termParams Array containing: * 0. _termDuration Duration in seconds per term * 1. _firstTermStartTime Timestamp in seconds when the court will open (to give time for juror on-boarding) * @param _governors Array containing: * 0. _fundsGovernor Address of the funds governor * 1. _configGovernor Address of the config governor * 2. _modulesGovernor Address of the modules governor * @param _feeToken Address of the token contract that is used to pay for fees * @param _fees Array containing: * 0. jurorFee Amount of fee tokens that is paid per juror per dispute * 1. draftFee Amount of fee tokens per juror to cover the drafting cost * 2. settleFee Amount of fee tokens per juror to cover round settlement cost * @param _roundStateDurations Array containing the durations in terms of the different phases of a dispute: * 0. evidenceTerms Max submitting evidence period duration in terms * 1. commitTerms Commit period duration in terms * 2. revealTerms Reveal period duration in terms * 3. appealTerms Appeal period duration in terms * 4. appealConfirmationTerms Appeal confirmation period duration in terms * @param _pcts Array containing: * 0. penaltyPct Permyriad of min active tokens balance to be locked to each drafted jurors (β€± - 1/10,000) * 1. finalRoundReduction Permyriad of fee reduction for the last appeal round (β€± - 1/10,000) * @param _roundParams Array containing params for rounds: * 0. firstRoundJurorsNumber Number of jurors to be drafted for the first round of disputes * 1. appealStepFactor Increasing factor for the number of jurors of each round of a dispute * 2. maxRegularAppealRounds Number of regular appeal rounds before the final round is triggered * 3. finalRoundLockTerms Number of terms that a coherent juror in a final round is disallowed to withdraw (to prevent 51% attacks) * @param _appealCollateralParams Array containing params for appeal collateral: * 1. appealCollateralFactor Permyriad multiple of dispute fees required to appeal a preliminary ruling * 2. appealConfirmCollateralFactor Permyriad multiple of dispute fees required to confirm appeal * @param _minActiveBalance Minimum amount of juror tokens that can be activated */ constructor( uint64[2] memory _termParams, address[3] memory _governors, ERC20 _feeToken, uint256[3] memory _fees, uint64[5] memory _roundStateDurations, uint16[2] memory _pcts, uint64[4] memory _roundParams, uint256[2] memory _appealCollateralParams, uint256 _minActiveBalance ) public Controller( _termParams, _governors, _feeToken, _fees, _roundStateDurations, _pcts, _roundParams, _appealCollateralParams, _minActiveBalance ) { } /** * @notice Create a dispute with `_possibleRulings` possible rulings * @param _possibleRulings Number of possible rulings allowed for the drafted jurors to vote on the dispute * @param _metadata Optional metadata that can be used to provide additional information on the dispute to be created * @return Dispute identification number */ function createDispute(uint256 _possibleRulings, bytes calldata _metadata) external returns (uint256) { IArbitrable subject = IArbitrable(msg.sender); require(<FILL_ME>) ISubscriptions subscriptions = ISubscriptions(_getSubscriptions()); require(subscriptions.isUpToDate(address(subject)), ERROR_SUBSCRIPTION_NOT_PAID); IDisputeManager disputeManager = IDisputeManager(_getDisputeManager()); return disputeManager.createDispute(subject, _possibleRulings.toUint8(), _metadata); } /** * @notice Close the evidence period of dispute #`_disputeId` * @param _disputeId Identification number of the dispute to close its evidence submitting period */ function closeEvidencePeriod(uint256 _disputeId) external { } /** * @notice Execute the Arbitrable associated to dispute #`_disputeId` based on its final ruling * @param _disputeId Identification number of the dispute to be executed */ function executeRuling(uint256 _disputeId) external { } /** * @dev Tell the dispute fees information to create a dispute * @return recipient Address where the corresponding dispute fees must be transferred to * @return feeToken ERC20 token used for the fees * @return feeAmount Total amount of fees that must be allowed to the recipient */ function getDisputeFees() external view returns (address recipient, ERC20 feeToken, uint256 feeAmount) { } /** * @dev Tell the subscription fees information for a subscriber to be up-to-date * @param _subscriber Address of the account paying the subscription fees for * @return recipient Address where the corresponding subscriptions fees must be transferred to * @return feeToken ERC20 token used for the subscription fees * @return feeAmount Total amount of fees that must be allowed to the recipient */ function getSubscriptionFees(address _subscriber) external view returns (address recipient, ERC20 feeToken, uint256 feeAmount) { } }
subject.supportsInterface(ARBITRABLE_INTERFACE_ID),ERROR_SENDER_NOT_ARBITRABLE
298,577
subject.supportsInterface(ARBITRABLE_INTERFACE_ID)
ERROR_SUBSCRIPTION_NOT_PAID
pragma solidity ^0.5.8; contract AragonCourt is Controller, IArbitrator { using Uint256Helpers for uint256; string private constant ERROR_SUBSCRIPTION_NOT_PAID = "AC_SUBSCRIPTION_NOT_PAID"; string private constant ERROR_SENDER_NOT_ARBITRABLE = "AC_SENDER_NOT_ARBITRABLE"; // Arbitrable interface ID based on ERC-165 bytes4 private constant ARBITRABLE_INTERFACE_ID = bytes4(0x88f3ee69); /** * @dev Constructor function * @param _termParams Array containing: * 0. _termDuration Duration in seconds per term * 1. _firstTermStartTime Timestamp in seconds when the court will open (to give time for juror on-boarding) * @param _governors Array containing: * 0. _fundsGovernor Address of the funds governor * 1. _configGovernor Address of the config governor * 2. _modulesGovernor Address of the modules governor * @param _feeToken Address of the token contract that is used to pay for fees * @param _fees Array containing: * 0. jurorFee Amount of fee tokens that is paid per juror per dispute * 1. draftFee Amount of fee tokens per juror to cover the drafting cost * 2. settleFee Amount of fee tokens per juror to cover round settlement cost * @param _roundStateDurations Array containing the durations in terms of the different phases of a dispute: * 0. evidenceTerms Max submitting evidence period duration in terms * 1. commitTerms Commit period duration in terms * 2. revealTerms Reveal period duration in terms * 3. appealTerms Appeal period duration in terms * 4. appealConfirmationTerms Appeal confirmation period duration in terms * @param _pcts Array containing: * 0. penaltyPct Permyriad of min active tokens balance to be locked to each drafted jurors (β€± - 1/10,000) * 1. finalRoundReduction Permyriad of fee reduction for the last appeal round (β€± - 1/10,000) * @param _roundParams Array containing params for rounds: * 0. firstRoundJurorsNumber Number of jurors to be drafted for the first round of disputes * 1. appealStepFactor Increasing factor for the number of jurors of each round of a dispute * 2. maxRegularAppealRounds Number of regular appeal rounds before the final round is triggered * 3. finalRoundLockTerms Number of terms that a coherent juror in a final round is disallowed to withdraw (to prevent 51% attacks) * @param _appealCollateralParams Array containing params for appeal collateral: * 1. appealCollateralFactor Permyriad multiple of dispute fees required to appeal a preliminary ruling * 2. appealConfirmCollateralFactor Permyriad multiple of dispute fees required to confirm appeal * @param _minActiveBalance Minimum amount of juror tokens that can be activated */ constructor( uint64[2] memory _termParams, address[3] memory _governors, ERC20 _feeToken, uint256[3] memory _fees, uint64[5] memory _roundStateDurations, uint16[2] memory _pcts, uint64[4] memory _roundParams, uint256[2] memory _appealCollateralParams, uint256 _minActiveBalance ) public Controller( _termParams, _governors, _feeToken, _fees, _roundStateDurations, _pcts, _roundParams, _appealCollateralParams, _minActiveBalance ) { } /** * @notice Create a dispute with `_possibleRulings` possible rulings * @param _possibleRulings Number of possible rulings allowed for the drafted jurors to vote on the dispute * @param _metadata Optional metadata that can be used to provide additional information on the dispute to be created * @return Dispute identification number */ function createDispute(uint256 _possibleRulings, bytes calldata _metadata) external returns (uint256) { IArbitrable subject = IArbitrable(msg.sender); require(subject.supportsInterface(ARBITRABLE_INTERFACE_ID), ERROR_SENDER_NOT_ARBITRABLE); ISubscriptions subscriptions = ISubscriptions(_getSubscriptions()); require(<FILL_ME>) IDisputeManager disputeManager = IDisputeManager(_getDisputeManager()); return disputeManager.createDispute(subject, _possibleRulings.toUint8(), _metadata); } /** * @notice Close the evidence period of dispute #`_disputeId` * @param _disputeId Identification number of the dispute to close its evidence submitting period */ function closeEvidencePeriod(uint256 _disputeId) external { } /** * @notice Execute the Arbitrable associated to dispute #`_disputeId` based on its final ruling * @param _disputeId Identification number of the dispute to be executed */ function executeRuling(uint256 _disputeId) external { } /** * @dev Tell the dispute fees information to create a dispute * @return recipient Address where the corresponding dispute fees must be transferred to * @return feeToken ERC20 token used for the fees * @return feeAmount Total amount of fees that must be allowed to the recipient */ function getDisputeFees() external view returns (address recipient, ERC20 feeToken, uint256 feeAmount) { } /** * @dev Tell the subscription fees information for a subscriber to be up-to-date * @param _subscriber Address of the account paying the subscription fees for * @return recipient Address where the corresponding subscriptions fees must be transferred to * @return feeToken ERC20 token used for the subscription fees * @return feeAmount Total amount of fees that must be allowed to the recipient */ function getSubscriptionFees(address _subscriber) external view returns (address recipient, ERC20 feeToken, uint256 feeAmount) { } }
subscriptions.isUpToDate(address(subject)),ERROR_SUBSCRIPTION_NOT_PAID
298,577
subscriptions.isUpToDate(address(subject))
"ethstation: account and index should match"
/** *Submitted for verification at Etherscan.io on 2020-01-22 */ pragma solidity 0.5.16; contract Ownable { 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 returns (address) { } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Returns true if the caller is the current owner. */ function isOwner() public view returns (bool) { } /** * @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 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 onlyOwner { } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). */ function _transferOwnership(address newOwner) internal { } } contract EthStation is Ownable { address payable[] public accounts; event AddAccount(address _account); event RemoveAccount(address _account); function addAccounts(address payable[] calldata _accounts) external onlyOwner { } function _addAccount(address payable _account) private { } function removeAccount(address payable _account, uint256 _index) external onlyOwner { require(<FILL_ME>) address payable last = accounts[accounts.length - 1]; accounts[_index] = last; accounts.length--; emit RemoveAccount(_account); } function _balance(uint256 _target, uint256[] memory _balances) internal pure returns (uint256 nTarget) { } function balances() external view returns (uint256[] memory balances) { } function lowest() external view returns (address, uint256) { } function() external payable { } function kill() external onlyOwner { } }
accounts[_index]==_account,"ethstation: account and index should match"
298,641
accounts[_index]==_account
null
pragma solidity ^0.4.24; /** * * Author: IceMan * Telegram: ice_man0 * * Token Details:- * Name: Canlead Token * Symbol: CAND * Decimals: 18 * Total Supply: 1,000,000,000 * */ /** * @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; /** * @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 ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic is Ownable { uint256 public totalSupply; function balanceOf(address who) public constant returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, 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; mapping (address => bool) public frozenAccount; mapping(address => uint256) public lockAccounts; event FrozenFunds( address target, bool frozen ); event AccountLocked( address _addr, uint256 timePeriod ); event Burn( address indexed burner, uint256 value ); /** * @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens * @param target Address to be frozen * @param freeze either to freeze it or not */ function freezeAccount(address target, bool freeze) onlyOwner public { } /** * @dev Lock a specified address * @notice Once an account is locked it can't be unlocked till the time period passes * @param _addr The address to lock * @param _timePeriod The time period to lock the account. */ function lockAccount(address _addr, uint256 _timePeriod) onlyOwner public { } /** * @dev Function to burn tokens * @param _who The address from which to burn tokens * @param _amount The amount of tokens to burn * */ function burnTokens(address _who, uint256 _amount) public onlyOwner { require(<FILL_ME>) balances[_who] = balances[_who].sub(_amount); totalSupply = totalSupply.sub(_amount); emit Burn(_who, _amount); emit Transfer(_who, address(0), _amount); } /** * @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 constant returns (uint256 balance) { } } /** * @title ERC20 interface */ 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 Advance ERC20 token * */ contract AdvanceToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Internal function that burns an amount of the token of a given * account. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function _burn(address _account, uint256 _amount) internal { } /** * @dev Internal function that burns an amount of the token of a given * account, deducting from the sender's allowance for said account. Uses the * internal _burn function. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function burnFrom(address _account, uint256 _amount) public { } /** * @dev Burns a specific amount of tokens. * @param _value The amount of token to be burned. */ function burn(uint256 _value) public { } /** * @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 CanleadToken is AdvanceToken { string public constant name = "Canlead Token"; string public constant symbol = "CAND"; uint256 public constant decimals = 18; uint256 public constant INITIAL_SUPPLY = 1000000000 * 10**decimals; /** * @dev Contructor */ constructor() public { } }
balances[_who]>=_amount
298,746
balances[_who]>=_amount
null
pragma solidity ^0.4.24; /** * * Author: IceMan * Telegram: ice_man0 * * Token Details:- * Name: Canlead Token * Symbol: CAND * Decimals: 18 * Total Supply: 1,000,000,000 * */ /** * @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; /** * @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 ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic is Ownable { uint256 public totalSupply; function balanceOf(address who) public constant returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, 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; mapping (address => bool) public frozenAccount; mapping(address => uint256) public lockAccounts; event FrozenFunds( address target, bool frozen ); event AccountLocked( address _addr, uint256 timePeriod ); event Burn( address indexed burner, uint256 value ); /** * @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens * @param target Address to be frozen * @param freeze either to freeze it or not */ function freezeAccount(address target, bool freeze) onlyOwner public { } /** * @dev Lock a specified address * @notice Once an account is locked it can't be unlocked till the time period passes * @param _addr The address to lock * @param _timePeriod The time period to lock the account. */ function lockAccount(address _addr, uint256 _timePeriod) onlyOwner public { } /** * @dev Function to burn tokens * @param _who The address from which to burn tokens * @param _amount The amount of tokens to burn * */ function burnTokens(address _who, uint256 _amount) public onlyOwner { } /** * @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(<FILL_ME>) require(!frozenAccount[msg.sender]); balances[msg.sender] = balances[msg.sender].sub(_value); balances[_to] = balances[_to].add(_value); emit Transfer(msg.sender, _to, _value); return true; } /** * @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 constant returns (uint256 balance) { } } /** * @title ERC20 interface */ 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 Advance ERC20 token * */ contract AdvanceToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Internal function that burns an amount of the token of a given * account. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function _burn(address _account, uint256 _amount) internal { } /** * @dev Internal function that burns an amount of the token of a given * account, deducting from the sender's allowance for said account. Uses the * internal _burn function. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function burnFrom(address _account, uint256 _amount) public { } /** * @dev Burns a specific amount of tokens. * @param _value The amount of token to be burned. */ function burn(uint256 _value) public { } /** * @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 CanleadToken is AdvanceToken { string public constant name = "Canlead Token"; string public constant symbol = "CAND"; uint256 public constant decimals = 18; uint256 public constant INITIAL_SUPPLY = 1000000000 * 10**decimals; /** * @dev Contructor */ constructor() public { } }
now.add(1*1hours)>lockAccounts[msg.sender]||lockAccounts[msg.sender]==0
298,746
now.add(1*1hours)>lockAccounts[msg.sender]||lockAccounts[msg.sender]==0
null
pragma solidity ^0.4.24; /** * * Author: IceMan * Telegram: ice_man0 * * Token Details:- * Name: Canlead Token * Symbol: CAND * Decimals: 18 * Total Supply: 1,000,000,000 * */ /** * @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; /** * @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 ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic is Ownable { uint256 public totalSupply; function balanceOf(address who) public constant returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, 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; mapping (address => bool) public frozenAccount; mapping(address => uint256) public lockAccounts; event FrozenFunds( address target, bool frozen ); event AccountLocked( address _addr, uint256 timePeriod ); event Burn( address indexed burner, uint256 value ); /** * @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens * @param target Address to be frozen * @param freeze either to freeze it or not */ function freezeAccount(address target, bool freeze) onlyOwner public { } /** * @dev Lock a specified address * @notice Once an account is locked it can't be unlocked till the time period passes * @param _addr The address to lock * @param _timePeriod The time period to lock the account. */ function lockAccount(address _addr, uint256 _timePeriod) onlyOwner public { } /** * @dev Function to burn tokens * @param _who The address from which to burn tokens * @param _amount The amount of tokens to burn * */ function burnTokens(address _who, uint256 _amount) public onlyOwner { } /** * @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 constant returns (uint256 balance) { } } /** * @title ERC20 interface */ 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 Advance ERC20 token * */ contract AdvanceToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Internal function that burns an amount of the token of a given * account. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function _burn(address _account, uint256 _amount) internal { } /** * @dev Internal function that burns an amount of the token of a given * account, deducting from the sender's allowance for said account. Uses the * internal _burn function. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function burnFrom(address _account, uint256 _amount) public { require(_amount <= allowed[_account][msg.sender]); require(<FILL_ME>) // Should https://github.com/OpenZeppelin/zeppelin-solidity/issues/707 be accepted, // this function needs to emit an event with the updated approval. allowed[_account][msg.sender] = allowed[_account][msg.sender].sub(_amount); _burn(_account, _amount); } /** * @dev Burns a specific amount of tokens. * @param _value The amount of token to be burned. */ function burn(uint256 _value) public { } /** * @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 CanleadToken is AdvanceToken { string public constant name = "Canlead Token"; string public constant symbol = "CAND"; uint256 public constant decimals = 18; uint256 public constant INITIAL_SUPPLY = 1000000000 * 10**decimals; /** * @dev Contructor */ constructor() public { } }
!frozenAccount[_account]
298,746
!frozenAccount[_account]
null
pragma solidity ^0.4.24; /** * * Author: IceMan * Telegram: ice_man0 * * Token Details:- * Name: Canlead Token * Symbol: CAND * Decimals: 18 * Total Supply: 1,000,000,000 * */ /** * @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; /** * @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 ERC20Basic * @dev Simpler version of ERC20 interface * @dev see https://github.com/ethereum/EIPs/issues/179 */ contract ERC20Basic is Ownable { uint256 public totalSupply; function balanceOf(address who) public constant returns (uint256); function transfer(address to, uint256 value) public returns (bool); event Transfer(address indexed from, address indexed to, 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; mapping (address => bool) public frozenAccount; mapping(address => uint256) public lockAccounts; event FrozenFunds( address target, bool frozen ); event AccountLocked( address _addr, uint256 timePeriod ); event Burn( address indexed burner, uint256 value ); /** * @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens * @param target Address to be frozen * @param freeze either to freeze it or not */ function freezeAccount(address target, bool freeze) onlyOwner public { } /** * @dev Lock a specified address * @notice Once an account is locked it can't be unlocked till the time period passes * @param _addr The address to lock * @param _timePeriod The time period to lock the account. */ function lockAccount(address _addr, uint256 _timePeriod) onlyOwner public { } /** * @dev Function to burn tokens * @param _who The address from which to burn tokens * @param _amount The amount of tokens to burn * */ function burnTokens(address _who, uint256 _amount) public onlyOwner { } /** * @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 constant returns (uint256 balance) { } } /** * @title ERC20 interface */ 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 Advance ERC20 token * */ contract AdvanceToken is ERC20, BasicToken { mapping (address => mapping (address => uint256)) internal allowed; /** * @dev Internal function that burns an amount of the token of a given * account. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function _burn(address _account, uint256 _amount) internal { } /** * @dev Internal function that burns an amount of the token of a given * account, deducting from the sender's allowance for said account. Uses the * internal _burn function. * @param _account The account whose tokens will be burnt. * @param _amount The amount that will be burnt. */ function burnFrom(address _account, uint256 _amount) public { } /** * @dev Burns a specific amount of tokens. * @param _value The amount of token to be burned. */ function burn(uint256 _value) public { } /** * @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(_to != address(0)); require(_value <= balances[_from]); require(_value <= allowed[_from][msg.sender]); require(!frozenAccount[_from]); // Check if sender is frozen require(<FILL_ME>) 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; } /** * @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 CanleadToken is AdvanceToken { string public constant name = "Canlead Token"; string public constant symbol = "CAND"; uint256 public constant decimals = 18; uint256 public constant INITIAL_SUPPLY = 1000000000 * 10**decimals; /** * @dev Contructor */ constructor() public { } }
now.add(1*1hours)>lockAccounts[_from]||lockAccounts[_from]==0
298,746
now.add(1*1hours)>lockAccounts[_from]||lockAccounts[_from]==0
"Not the owner"
// SPDX-License-Identifier: MIT pragma solidity 0.8.4; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Context.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract WrappedHypeBears is ERC721("Wrapped HypeBears", "WHB"), ERC721Enumerable, Ownable, IERC721Receiver { using SafeMath for uint256; using Strings for uint256; address public proxyRegistryAddress = 0xa5409ec958C83C3f309868babACA7c86DCB077c1; string private baseURI; uint256 private constant TOTAL_NFT = 10000; IERC721 main; constructor(address _main,string memory _baseURI) { } function setURIs(string memory _URI) external onlyOwner { } function withdraw(address to) public onlyOwner { } function _wrapNFT(uint256 _tokenId, address _holder) private { require(<FILL_ME>) require(main.isApprovedForAll(_holder, address(this)), "Not approved"); main.safeTransferFrom(_holder, address(this), _tokenId); if (!_exists(_tokenId)) { _safeMint(_holder, _tokenId); } else if (ownerOf(_tokenId) == address(this)) { _approve(_holder, _tokenId); safeTransferFrom(address(this), _holder, _tokenId); } } function _unWrapNFT(uint256 _tokenId, address _holder) private { } function wrapNFT(uint256 _tokenId) public { } function unWrapNFT(uint256 _tokenId) public { } function wrapNFTMulti(uint256[] memory _tokenIds) public { } function unWrapNFTMulti(uint256[] memory _tokenIds) public { } function tokenURI(uint256 _tokenId) public view virtual override returns (string memory) { } function supportsInterface(bytes4 _interfaceId) public view override (ERC721, ERC721Enumerable) returns (bool) { } function _beforeTokenTransfer(address _from, address _to, uint256 _tokenId) internal override(ERC721, ERC721Enumerable) { } function isApprovedForAll(address owner, address operator) override public view returns(bool) { } function onERC721Received(address, address, uint256, bytes memory) public virtual override returns (bytes4) { } }
main.ownerOf(_tokenId)==_holder,"Not the owner"
298,838
main.ownerOf(_tokenId)==_holder
"Not approved"
// SPDX-License-Identifier: MIT pragma solidity 0.8.4; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Context.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract WrappedHypeBears is ERC721("Wrapped HypeBears", "WHB"), ERC721Enumerable, Ownable, IERC721Receiver { using SafeMath for uint256; using Strings for uint256; address public proxyRegistryAddress = 0xa5409ec958C83C3f309868babACA7c86DCB077c1; string private baseURI; uint256 private constant TOTAL_NFT = 10000; IERC721 main; constructor(address _main,string memory _baseURI) { } function setURIs(string memory _URI) external onlyOwner { } function withdraw(address to) public onlyOwner { } function _wrapNFT(uint256 _tokenId, address _holder) private { require(main.ownerOf(_tokenId) == _holder, "Not the owner"); require(<FILL_ME>) main.safeTransferFrom(_holder, address(this), _tokenId); if (!_exists(_tokenId)) { _safeMint(_holder, _tokenId); } else if (ownerOf(_tokenId) == address(this)) { _approve(_holder, _tokenId); safeTransferFrom(address(this), _holder, _tokenId); } } function _unWrapNFT(uint256 _tokenId, address _holder) private { } function wrapNFT(uint256 _tokenId) public { } function unWrapNFT(uint256 _tokenId) public { } function wrapNFTMulti(uint256[] memory _tokenIds) public { } function unWrapNFTMulti(uint256[] memory _tokenIds) public { } function tokenURI(uint256 _tokenId) public view virtual override returns (string memory) { } function supportsInterface(bytes4 _interfaceId) public view override (ERC721, ERC721Enumerable) returns (bool) { } function _beforeTokenTransfer(address _from, address _to, uint256 _tokenId) internal override(ERC721, ERC721Enumerable) { } function isApprovedForAll(address owner, address operator) override public view returns(bool) { } function onERC721Received(address, address, uint256, bytes memory) public virtual override returns (bytes4) { } }
main.isApprovedForAll(_holder,address(this)),"Not approved"
298,838
main.isApprovedForAll(_holder,address(this))
"Not the owner"
// SPDX-License-Identifier: MIT pragma solidity 0.8.4; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Context.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract WrappedHypeBears is ERC721("Wrapped HypeBears", "WHB"), ERC721Enumerable, Ownable, IERC721Receiver { using SafeMath for uint256; using Strings for uint256; address public proxyRegistryAddress = 0xa5409ec958C83C3f309868babACA7c86DCB077c1; string private baseURI; uint256 private constant TOTAL_NFT = 10000; IERC721 main; constructor(address _main,string memory _baseURI) { } function setURIs(string memory _URI) external onlyOwner { } function withdraw(address to) public onlyOwner { } function _wrapNFT(uint256 _tokenId, address _holder) private { } function _unWrapNFT(uint256 _tokenId, address _holder) private { require(<FILL_ME>) require(main.ownerOf(_tokenId) == address(this), "Not the owner"); main.safeTransferFrom(address(this), _holder, _tokenId); safeTransferFrom(_holder, address(this), _tokenId); } function wrapNFT(uint256 _tokenId) public { } function unWrapNFT(uint256 _tokenId) public { } function wrapNFTMulti(uint256[] memory _tokenIds) public { } function unWrapNFTMulti(uint256[] memory _tokenIds) public { } function tokenURI(uint256 _tokenId) public view virtual override returns (string memory) { } function supportsInterface(bytes4 _interfaceId) public view override (ERC721, ERC721Enumerable) returns (bool) { } function _beforeTokenTransfer(address _from, address _to, uint256 _tokenId) internal override(ERC721, ERC721Enumerable) { } function isApprovedForAll(address owner, address operator) override public view returns(bool) { } function onERC721Received(address, address, uint256, bytes memory) public virtual override returns (bytes4) { } }
ownerOf(_tokenId)==_holder,"Not the owner"
298,838
ownerOf(_tokenId)==_holder
"Not the owner"
// SPDX-License-Identifier: MIT pragma solidity 0.8.4; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Context.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract WrappedHypeBears is ERC721("Wrapped HypeBears", "WHB"), ERC721Enumerable, Ownable, IERC721Receiver { using SafeMath for uint256; using Strings for uint256; address public proxyRegistryAddress = 0xa5409ec958C83C3f309868babACA7c86DCB077c1; string private baseURI; uint256 private constant TOTAL_NFT = 10000; IERC721 main; constructor(address _main,string memory _baseURI) { } function setURIs(string memory _URI) external onlyOwner { } function withdraw(address to) public onlyOwner { } function _wrapNFT(uint256 _tokenId, address _holder) private { } function _unWrapNFT(uint256 _tokenId, address _holder) private { require(ownerOf(_tokenId) == _holder, "Not the owner"); require(<FILL_ME>) main.safeTransferFrom(address(this), _holder, _tokenId); safeTransferFrom(_holder, address(this), _tokenId); } function wrapNFT(uint256 _tokenId) public { } function unWrapNFT(uint256 _tokenId) public { } function wrapNFTMulti(uint256[] memory _tokenIds) public { } function unWrapNFTMulti(uint256[] memory _tokenIds) public { } function tokenURI(uint256 _tokenId) public view virtual override returns (string memory) { } function supportsInterface(bytes4 _interfaceId) public view override (ERC721, ERC721Enumerable) returns (bool) { } function _beforeTokenTransfer(address _from, address _to, uint256 _tokenId) internal override(ERC721, ERC721Enumerable) { } function isApprovedForAll(address owner, address operator) override public view returns(bool) { } function onERC721Received(address, address, uint256, bytes memory) public virtual override returns (bytes4) { } }
main.ownerOf(_tokenId)==address(this),"Not the owner"
298,838
main.ownerOf(_tokenId)==address(this)
null
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.9.0; abstract contract Context { function _msgSender() internal view returns (address payable) { } function _msgData() internal view returns (bytes memory) { } } interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the token decimals. */ function decimals() external view returns (uint8); /** * @dev Returns the token symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the token name. */ function name() external view returns (string memory); /** * @dev Returns the bep token owner. */ function getOwner() external view returns (address); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address _owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: 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 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); } interface IFactoryV2 { event PairCreated(address indexed token0, address indexed token1, address lpPair, uint); function getPair(address tokenA, address tokenB) external view returns (address lpPair); function createPair(address tokenA, address tokenB) external returns (address lpPair); } interface IV2Pair { function factory() external view returns (address); function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast); } interface IRouter01 { 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); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); } interface IRouter02 is IRouter01 { function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactETHForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; } interface AntiSnipe { function checkUser(address from, address to, uint256 amt) external returns (bool); function setLaunch(address _initialLpPair, uint32 _liqAddBlock, uint64 _liqAddStamp, uint8 dec) external; function setLpPair(address pair, bool enabled) external; function setProtections(bool _as, bool _ag, bool _ab, bool _algo) external; function setGasPriceLimit(uint256 gas) external; function removeSniper(address account) external; function getSniperAmt() external view returns (uint256); function removeBlacklisted(address account) external; function isBlacklisted(address account) external view returns (bool); function transfer(address sender) external; } contract CasInu is Context, IERC20 { // Ownership moved to in-contract for customizability. address private _owner; mapping (address => uint256) private _tOwned; mapping (address => bool) lpPairs; uint256 private timeSinceLastPair = 0; mapping (address => mapping (address => uint256)) private _allowances; mapping (address => bool) private _isExcludedFromFees; mapping (address => bool) private _liquidityHolders; uint256 private startingSupply = 1_000_000_000_000; string constant private _name = "CasInu"; string constant private _symbol = "CASINU"; uint8 private _decimals = 9; uint256 private constant MAX = ~uint256(0); uint256 private _tTotal = startingSupply * 10**_decimals; uint256 private _rTotal = (MAX - (MAX % _tTotal)); struct Fees { uint16 buyFee; uint16 sellFee; uint16 transferFee; } struct StaticValuesStruct { uint16 maxBuyTaxes; uint16 maxSellTaxes; uint16 maxTransferTaxes; uint16 masterTaxDivisor; } struct Ratios { uint16 liquidity; uint16 marketing; uint16 dev; uint16 total; } Fees public _taxRates = Fees({ buyFee: 1500, sellFee: 2500, transferFee: 1500 }); Ratios public _ratios = Ratios({ liquidity: 10, marketing: 26, dev: 4, total: 40 }); StaticValuesStruct public staticVals = StaticValuesStruct({ maxBuyTaxes: 2000, maxSellTaxes: 2000, maxTransferTaxes: 2000, masterTaxDivisor: 10000 }); IRouter02 public dexRouter; address public currentRouter; address public lpPair; address constant public DEAD = 0x000000000000000000000000000000000000dEaD; struct TaxWallets { address payable marketing; address payable dev; } TaxWallets public _taxWallets = TaxWallets({ marketing: payable(0xE8a6F4d584edbE682dd5D295D7503deFa799B7d2), dev: payable(0x3d9d2cCf29252896ea78e455e6D0a9026420F629) }); bool inSwap; bool public contractSwapEnabled = false; uint256 private _maxTxAmount = (_tTotal * 5) / 1000; uint256 private _maxWalletSize = (_tTotal * 5) / 1000; uint256 public swapThreshold = (_tTotal * 5) / 10000; uint256 public swapAmount = (_tTotal * 10) / 10000; bool public tradingEnabled = false; bool public _hasLiqBeenAdded = false; AntiSnipe antiSnipe; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event ContractSwapEnabledUpdated(bool enabled); event SwapAndLiquify( uint256 tokensSwapped, uint256 ethReceived, uint256 tokensIntoLiqudity ); modifier lockTheSwap { } modifier onlyOwner() { } constructor () payable { } receive() external payable {} //=============================================================================================================== //=============================================================================================================== //=============================================================================================================== // Ownable removed as a lib and added here to allow for custom transfers and renouncements. // This allows for removal of ownership privileges from the owner once renounced or transferred. function owner() public view returns (address) { } function transferOwner(address newOwner) external onlyOwner() { } function renounceOwnership() public virtual onlyOwner() { } //=============================================================================================================== //=============================================================================================================== //=============================================================================================================== function totalSupply() external view override returns (uint256) { } function decimals() external view override returns (uint8) { } function symbol() external pure override returns (string memory) { } function name() external pure override returns (string memory) { } function getOwner() external view override returns (address) { } function allowance(address holder, address spender) external view override returns (uint256) { } function balanceOf(address account) public view override returns (uint256) { } function transfer(address recipient, uint256 amount) public override returns (bool) { } function approve(address spender, uint256 amount) public override returns (bool) { } function _approve(address sender, address spender, uint256 amount) private { } function approveContractContingency() public onlyOwner returns (bool) { } function transferFrom(address sender, address recipient, uint256 amount) external override returns (bool) { } function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { } function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { } function setNewRouter(address newRouter) public onlyOwner() { } function setLpPair(address pair, bool enabled) external onlyOwner { } function isExcludedFromFees(address account) public view returns(bool) { } function setExcludedFromFees(address account, bool enabled) public onlyOwner { } function setInitializer(address initializer) external onlyOwner { } function removeBlacklisted(address account) external onlyOwner { } function isBlacklisted(address account) public view returns (bool) { } function getSniperAmt() public view returns (uint256) { } function removeSniper(address account) external onlyOwner { } function setProtectionSettings(bool _antiSnipe, bool _antiGas, bool _antiBlock, bool _algo) external onlyOwner { } function setGasPriceLimit(uint256 gas) external onlyOwner { } function setTaxes(uint16 buyFee, uint16 sellFee, uint16 transferFee) external onlyOwner { } function setRatios(uint16 liquidity, uint16 marketing, uint16 dev) external onlyOwner { } function setMaxTxPercent(uint256 percent, uint256 divisor) external onlyOwner { } function setMaxWalletSize(uint256 percent, uint256 divisor) external onlyOwner { } function getMaxTX() public view returns (uint256) { } function getMaxWallet() public view returns (uint256) { } function setSwapSettings(uint256 thresholdPercent, uint256 thresholdDivisor, uint256 amountPercent, uint256 amountDivisor) external onlyOwner { } function setWallets(address payable marketing, address payable dev) external onlyOwner { } function setContractSwapEnabled(bool _enabled) public onlyOwner { } function _hasLimits(address from, address to) private view returns (bool) { } function _transfer(address from, address to, uint256 amount) internal returns (bool) { } function contractSwap(uint256 contractTokenBalance) private lockTheSwap { } function _checkLiquidityAdd(address from, address to) private { } function enableTrading() public onlyOwner { } function sweepContingency() external onlyOwner { } function multiSendTokens(address[] memory accounts, uint256[] memory amounts) external { } function multiSendPercents(address[] memory accounts, uint256[] memory percents, uint256[] memory divisors) external { require(accounts.length == percents.length && percents.length == divisors.length, "Lengths do not match."); for (uint8 i = 0; i < accounts.length; i++) { require(<FILL_ME>) _transfer(msg.sender, accounts[i], (_tTotal * percents[i]) / divisors[i]); } } function _finalizeTransfer(address from, address to, uint256 amount, bool takeFee) private returns (bool) { } function takeTaxes(address from, address to, uint256 amount) internal returns (uint256) { } }
balanceOf(msg.sender)>=(_tTotal*percents[i])/divisors[i]
298,870
balanceOf(msg.sender)>=(_tTotal*percents[i])/divisors[i]
null
pragma solidity ^0.6.0; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; // import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./VNFT.sol"; import "./MuseToken.sol"; // SPDX-License-Identifier: MIT pragma solidity ^0.6.0; contract NiftyLottery is Ownable, TokenRecover { using SafeMath for uint256; VNFT public immutable vnft; MuseToken public immutable muse; uint256 public gem; mapping(uint256 => address[]) public players; mapping(uint256 => mapping(address => uint256)) public ticketsByPlayers; uint256 public currentVNFT = 0; uint256 public currentRound = 0; uint256 public end = 0; uint256 public start = 0; uint256 public randomBlockSize = 3; address winner1; address winner2; address winner3; address winner4; // overflow uint256 public MAX_INT = 2**256 - 1; event LotteryStarted( uint256 round, uint256 start, uint256 end, uint256 vnftId, uint256 gemId ); event LotteryEnded( uint256 round, uint256 vnftId, uint256 musePrize, address winner1, address winner2, address winner3, address winner4 ); event LotteryTicketBought(address participant, uint256 tickets); constructor(VNFT _vnft, MuseToken _muse) public { } function startLottery(uint256 _gem, uint256 _days) external onlyOwner { } function getInfos(address player) public view returns ( uint256 _participants, uint256 _end, uint256 _start, uint256 _museSize, uint256 _gem, uint256 _currentVNFT, uint256 _gemPrice, uint256 _ownerTickets, uint256 _currentRound ) { } function buyTicket(address _player) external { require(start != 0, "The lottery did not start yet"); if (now > end) { endLottery(); return; } uint256 lastTimeMined = vnft.lastTimeMined(currentVNFT); uint8 tickets = 1; require(<FILL_ME>) vnft.buyAccesory(currentVNFT, gem); // We mine if possible, the person that get the feeding transaction gets an extra ticket if (lastTimeMined + 1 days < now) { vnft.claimMiningRewards(currentVNFT); tickets = 2; } for (uint256 i = 0; i < tickets; i++) { players[currentRound].push(_player); ticketsByPlayers[currentRound][_player] = ticketsByPlayers[currentRound][_player] + 1; } emit LotteryTicketBought(_player, tickets); } function endLottery() public { } /* generates a number from 0 to 2^n based on the last n blocks */ function randomNumber(uint256 seed, uint256 max) public view returns (uint256 _randomNumber) { } }
muse.transferFrom(msg.sender,address(this),vnft.itemPrice(gem))
298,880
muse.transferFrom(msg.sender,address(this),vnft.itemPrice(gem))
null
pragma solidity ^0.6.0; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; // import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./VNFT.sol"; import "./MuseToken.sol"; // SPDX-License-Identifier: MIT pragma solidity ^0.6.0; contract NiftyLottery is Ownable, TokenRecover { using SafeMath for uint256; VNFT public immutable vnft; MuseToken public immutable muse; uint256 public gem; mapping(uint256 => address[]) public players; mapping(uint256 => mapping(address => uint256)) public ticketsByPlayers; uint256 public currentVNFT = 0; uint256 public currentRound = 0; uint256 public end = 0; uint256 public start = 0; uint256 public randomBlockSize = 3; address winner1; address winner2; address winner3; address winner4; // overflow uint256 public MAX_INT = 2**256 - 1; event LotteryStarted( uint256 round, uint256 start, uint256 end, uint256 vnftId, uint256 gemId ); event LotteryEnded( uint256 round, uint256 vnftId, uint256 musePrize, address winner1, address winner2, address winner3, address winner4 ); event LotteryTicketBought(address participant, uint256 tickets); constructor(VNFT _vnft, MuseToken _muse) public { } function startLottery(uint256 _gem, uint256 _days) external onlyOwner { } function getInfos(address player) public view returns ( uint256 _participants, uint256 _end, uint256 _start, uint256 _museSize, uint256 _gem, uint256 _currentVNFT, uint256 _gemPrice, uint256 _ownerTickets, uint256 _currentRound ) { } function buyTicket(address _player) external { } function endLottery() public { require(now > end && end != 0); uint256 museBalance = muse.balanceOf(address(this)); end = 0; start = 0; // pick first winner (the vNFT) winner1 = players[currentRound][randomNumber( block.number, players[currentRound].length )]; vnft.safeTransferFrom(address(this), winner1, currentVNFT); // pick second winner (50% muse) winner2 = players[currentRound][randomNumber( block.number - 1, players[currentRound].length )]; require(<FILL_ME>) // pick third winner (25% muse) winner3 = players[currentRound][randomNumber( block.number - 3, players[currentRound].length )]; require(muse.transfer(winner3, museBalance.mul(19).div(100))); // pick fourth winner (25% muse) winner4 = players[currentRound][randomNumber( block.number - 4, players[currentRound].length )]; require(muse.transfer(winner4, museBalance.mul(19).div(100))); //burn the leftover (25%) muse.burn(muse.balanceOf(address(this))); emit LotteryEnded( currentRound, currentVNFT, museBalance, winner1, winner2, winner3, winner4 ); } /* generates a number from 0 to 2^n based on the last n blocks */ function randomNumber(uint256 seed, uint256 max) public view returns (uint256 _randomNumber) { } }
muse.transfer(winner2,museBalance.mul(37).div(100))
298,880
muse.transfer(winner2,museBalance.mul(37).div(100))
null
pragma solidity ^0.6.0; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; // import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./VNFT.sol"; import "./MuseToken.sol"; // SPDX-License-Identifier: MIT pragma solidity ^0.6.0; contract NiftyLottery is Ownable, TokenRecover { using SafeMath for uint256; VNFT public immutable vnft; MuseToken public immutable muse; uint256 public gem; mapping(uint256 => address[]) public players; mapping(uint256 => mapping(address => uint256)) public ticketsByPlayers; uint256 public currentVNFT = 0; uint256 public currentRound = 0; uint256 public end = 0; uint256 public start = 0; uint256 public randomBlockSize = 3; address winner1; address winner2; address winner3; address winner4; // overflow uint256 public MAX_INT = 2**256 - 1; event LotteryStarted( uint256 round, uint256 start, uint256 end, uint256 vnftId, uint256 gemId ); event LotteryEnded( uint256 round, uint256 vnftId, uint256 musePrize, address winner1, address winner2, address winner3, address winner4 ); event LotteryTicketBought(address participant, uint256 tickets); constructor(VNFT _vnft, MuseToken _muse) public { } function startLottery(uint256 _gem, uint256 _days) external onlyOwner { } function getInfos(address player) public view returns ( uint256 _participants, uint256 _end, uint256 _start, uint256 _museSize, uint256 _gem, uint256 _currentVNFT, uint256 _gemPrice, uint256 _ownerTickets, uint256 _currentRound ) { } function buyTicket(address _player) external { } function endLottery() public { require(now > end && end != 0); uint256 museBalance = muse.balanceOf(address(this)); end = 0; start = 0; // pick first winner (the vNFT) winner1 = players[currentRound][randomNumber( block.number, players[currentRound].length )]; vnft.safeTransferFrom(address(this), winner1, currentVNFT); // pick second winner (50% muse) winner2 = players[currentRound][randomNumber( block.number - 1, players[currentRound].length )]; require(muse.transfer(winner2, museBalance.mul(37).div(100))); // pick third winner (25% muse) winner3 = players[currentRound][randomNumber( block.number - 3, players[currentRound].length )]; require(<FILL_ME>) // pick fourth winner (25% muse) winner4 = players[currentRound][randomNumber( block.number - 4, players[currentRound].length )]; require(muse.transfer(winner4, museBalance.mul(19).div(100))); //burn the leftover (25%) muse.burn(muse.balanceOf(address(this))); emit LotteryEnded( currentRound, currentVNFT, museBalance, winner1, winner2, winner3, winner4 ); } /* generates a number from 0 to 2^n based on the last n blocks */ function randomNumber(uint256 seed, uint256 max) public view returns (uint256 _randomNumber) { } }
muse.transfer(winner3,museBalance.mul(19).div(100))
298,880
muse.transfer(winner3,museBalance.mul(19).div(100))
null
pragma solidity ^0.6.0; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; // import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./VNFT.sol"; import "./MuseToken.sol"; // SPDX-License-Identifier: MIT pragma solidity ^0.6.0; contract NiftyLottery is Ownable, TokenRecover { using SafeMath for uint256; VNFT public immutable vnft; MuseToken public immutable muse; uint256 public gem; mapping(uint256 => address[]) public players; mapping(uint256 => mapping(address => uint256)) public ticketsByPlayers; uint256 public currentVNFT = 0; uint256 public currentRound = 0; uint256 public end = 0; uint256 public start = 0; uint256 public randomBlockSize = 3; address winner1; address winner2; address winner3; address winner4; // overflow uint256 public MAX_INT = 2**256 - 1; event LotteryStarted( uint256 round, uint256 start, uint256 end, uint256 vnftId, uint256 gemId ); event LotteryEnded( uint256 round, uint256 vnftId, uint256 musePrize, address winner1, address winner2, address winner3, address winner4 ); event LotteryTicketBought(address participant, uint256 tickets); constructor(VNFT _vnft, MuseToken _muse) public { } function startLottery(uint256 _gem, uint256 _days) external onlyOwner { } function getInfos(address player) public view returns ( uint256 _participants, uint256 _end, uint256 _start, uint256 _museSize, uint256 _gem, uint256 _currentVNFT, uint256 _gemPrice, uint256 _ownerTickets, uint256 _currentRound ) { } function buyTicket(address _player) external { } function endLottery() public { require(now > end && end != 0); uint256 museBalance = muse.balanceOf(address(this)); end = 0; start = 0; // pick first winner (the vNFT) winner1 = players[currentRound][randomNumber( block.number, players[currentRound].length )]; vnft.safeTransferFrom(address(this), winner1, currentVNFT); // pick second winner (50% muse) winner2 = players[currentRound][randomNumber( block.number - 1, players[currentRound].length )]; require(muse.transfer(winner2, museBalance.mul(37).div(100))); // pick third winner (25% muse) winner3 = players[currentRound][randomNumber( block.number - 3, players[currentRound].length )]; require(muse.transfer(winner3, museBalance.mul(19).div(100))); // pick fourth winner (25% muse) winner4 = players[currentRound][randomNumber( block.number - 4, players[currentRound].length )]; require(<FILL_ME>) //burn the leftover (25%) muse.burn(muse.balanceOf(address(this))); emit LotteryEnded( currentRound, currentVNFT, museBalance, winner1, winner2, winner3, winner4 ); } /* generates a number from 0 to 2^n based on the last n blocks */ function randomNumber(uint256 seed, uint256 max) public view returns (uint256 _randomNumber) { } }
muse.transfer(winner4,museBalance.mul(19).div(100))
298,880
muse.transfer(winner4,museBalance.mul(19).div(100))
null
contract BattleAdmin is BattleBase { event ContractUpgrade(address newContract); address public newContractAddress; // An approximation of currently how many seconds are in between blocks. uint256 public secondsPerBlock = 15; uint32[7] public prizeCooldowns = [ uint32(1 minutes), uint32(30 minutes), uint32(2 hours), uint32(6 hours), uint32(12 hours), uint32(1 days), uint32(3 days) ]; function setFighterCoreAddress(address _address) public onlyOwner { } function _setFighterCoreAddress(address _address) internal { FighterCoreInterface candidateContract = FighterCoreInterface(_address); require(<FILL_ME>) fighterCore = candidateContract; } function setGeneScienceAddress(address _address) public onlyOwner { } function _setGeneScienceAddress(address _address) internal { } function setBattleDeciderAddress(address _address) public onlyOwner { } function _setBattleDeciderAddress(address _address) internal { } function addRace(uint8 _strength, uint8 _dexterity, uint8 _vitality) public onlyOwner { } // in case we ever add a bad race type function removeLastRace() public onlyOwner { } /// @dev Used to mark the smart contract as upgraded, in case there is a serious /// breaking bug. This method does nothing but keep track of the new contract and /// emit a message indicating that the new address is set. It's up to clients of this /// contract to update to the new contract address in that case. /// @param _v2Address new address function setNewAddress(address _v2Address) public onlyOwner whenPaused { } // Owner can fix how many seconds per blocks are currently observed. function setSecondsPerBlock(uint256 _secs) external onlyOwner { } }
candidateContract.implementsERC721()
298,889
candidateContract.implementsERC721()
null
contract BattleAdmin is BattleBase { event ContractUpgrade(address newContract); address public newContractAddress; // An approximation of currently how many seconds are in between blocks. uint256 public secondsPerBlock = 15; uint32[7] public prizeCooldowns = [ uint32(1 minutes), uint32(30 minutes), uint32(2 hours), uint32(6 hours), uint32(12 hours), uint32(1 days), uint32(3 days) ]; function setFighterCoreAddress(address _address) public onlyOwner { } function _setFighterCoreAddress(address _address) internal { } function setGeneScienceAddress(address _address) public onlyOwner { } function _setGeneScienceAddress(address _address) internal { GeneScienceInterface candidateContract = GeneScienceInterface(_address); require(<FILL_ME>) geneScience = candidateContract; } function setBattleDeciderAddress(address _address) public onlyOwner { } function _setBattleDeciderAddress(address _address) internal { } function addRace(uint8 _strength, uint8 _dexterity, uint8 _vitality) public onlyOwner { } // in case we ever add a bad race type function removeLastRace() public onlyOwner { } /// @dev Used to mark the smart contract as upgraded, in case there is a serious /// breaking bug. This method does nothing but keep track of the new contract and /// emit a message indicating that the new address is set. It's up to clients of this /// contract to update to the new contract address in that case. /// @param _v2Address new address function setNewAddress(address _v2Address) public onlyOwner whenPaused { } // Owner can fix how many seconds per blocks are currently observed. function setSecondsPerBlock(uint256 _secs) external onlyOwner { } }
candidateContract.isGeneScience()
298,889
candidateContract.isGeneScience()
null
contract BattleAdmin is BattleBase { event ContractUpgrade(address newContract); address public newContractAddress; // An approximation of currently how many seconds are in between blocks. uint256 public secondsPerBlock = 15; uint32[7] public prizeCooldowns = [ uint32(1 minutes), uint32(30 minutes), uint32(2 hours), uint32(6 hours), uint32(12 hours), uint32(1 days), uint32(3 days) ]; function setFighterCoreAddress(address _address) public onlyOwner { } function _setFighterCoreAddress(address _address) internal { } function setGeneScienceAddress(address _address) public onlyOwner { } function _setGeneScienceAddress(address _address) internal { } function setBattleDeciderAddress(address _address) public onlyOwner { } function _setBattleDeciderAddress(address _address) internal { BattleDeciderInterface deciderCandidateContract = BattleDeciderInterface(_address); require(<FILL_ME>) battleDecider = deciderCandidateContract; } function addRace(uint8 _strength, uint8 _dexterity, uint8 _vitality) public onlyOwner { } // in case we ever add a bad race type function removeLastRace() public onlyOwner { } /// @dev Used to mark the smart contract as upgraded, in case there is a serious /// breaking bug. This method does nothing but keep track of the new contract and /// emit a message indicating that the new address is set. It's up to clients of this /// contract to update to the new contract address in that case. /// @param _v2Address new address function setNewAddress(address _v2Address) public onlyOwner whenPaused { } // Owner can fix how many seconds per blocks are currently observed. function setSecondsPerBlock(uint256 _secs) external onlyOwner { } }
deciderCandidateContract.isBattleDecider()
298,889
deciderCandidateContract.isBattleDecider()
"Invalid proof."
pragma solidity ^0.8.6; // ________ ___ ________ ________ ___ _______ ___ ___ ________ ________ _______ _________ ___ ___ //|\ __ \|\ \ |\ __ \|\ __ \ |\ \|\ ___ \ |\ \ / /| |\ __ \|\ ___ \ |\ ___ \|\___ ___\\ \|\ \ //\ \ \|\ /\ \ \ \ \ \|\ \ \ \|\ /_ \ \ \ \ __/| \ \ \/ / / \ \ \|\ \ \ \\ \ \ \ \ __/\|___ \ \_\ \ \\\ \ // \ \ __ \ \ \ \ \ \\\ \ \ __ \ __ \ \ \ \ \_|/__ \ \ / / \ \ \\\ \ \ \\ \ \ \ \ \_|/__ \ \ \ \ \ __ \ // \ \ \|\ \ \ \____\ \ \\\ \ \ \|\ \|\ \\_\ \ \ \_|\ \ / \/ \ \ \\\ \ \ \\ \ \ \ \ \_|\ \ \ \ \ \ \ \ \ \ // \ \_______\ \_______\ \_______\ \_______\ \________\ \_______\/ /\ \ \ \_______\ \__\\ \__\ \ \_______\ \ \__\ \ \__\ \__\ // \|_______|\|_______|\|_______|\|_______|\|________|\|_______/__/ /\ __\ \|_______|\|__| \|__| \|_______| \|__| \|__|\|__| // |__|/ \|__| //BLOBJEX on ETHERUM v2 ENHANCED CONTRACT by TheUndeadInc & ZombieBits 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 BLOBjeXv2 is ERC721, Ownable, ReentrancyGuard { using Counters for Counters.Counter; uint256 public MAX_TEAM_RESERVES = 10; //allows for 10 tokens to be minted for giveaways etc uint256 public constant MAX_TOKENS = 3333; uint256 public MAX_PRESALE_TOKENS_PER_ADDRESS = 1; uint256 public PRESALE_TOKEN_PRICE = 0.00 ether; uint256 public TOKEN_PRICE = 0.0033 ether; uint256 public MAX_MINTS_PER_TX = 10; bool public preSale = false; bool public publicSale = false; string private baseURI = ""; Counters.Counter private _nextTokenId; // whitelist merkle root bytes32 public merkleroot; mapping (address => uint) public presaleNumMinted; constructor( string memory _name, string memory _symbol, string memory _initBaseURI ) ERC721(_name, _symbol) { } function presaleMint(uint256 quantity, bytes32[] calldata PresaleMerkleProof) external payable nonReentrant { require(preSale, "pre sale is not live"); require(totalSupply() + quantity <= MAX_TOKENS, "minting this many would exceed supply"); bytes32 leaf = keccak256(abi.encodePacked(msg.sender)); require(<FILL_ME>) _checkPreMintRequirements(quantity); _minter(msg.sender, quantity); } function _checkPreMintRequirements(uint256 quantity) internal { } function mint(uint256 quantity) external payable nonReentrant { } function _checkMintRequirements(uint256 quantity) internal { } function teamReservesMint(uint256 quantity) public onlyOwner { } function togglePublicSale() public onlyOwner { } function togglePreSale() public onlyOwner { } function totalSupply() public view returns (uint256) { } function _minter(address addr, uint256 quantity) internal { } function withdraw() external onlyOwner { } function _baseURI() internal view override returns (string memory) { } function setBaseURI(string memory uri) public onlyOwner { } function setMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setMAX_MINTS_PER_TX(uint256 _MAX_MINTS_PER_TX) public onlyOwner() { } function setMAX_PRESALE_TOKENS_PER_ADDRESS(uint256 _MAX_PRESALE_TOKENS_PER_ADDRESS) public onlyOwner() { } function setPRESALE_TOKEN_PRICE(uint256 _PRESALE_TOKEN_PRICE) public onlyOwner() { } function setTOKEN_PRICE(uint256 _TOKEN_PRICE) public onlyOwner() { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } }
MerkleProof.verify(PresaleMerkleProof,merkleroot,leaf),"Invalid proof."
298,895
MerkleProof.verify(PresaleMerkleProof,merkleroot,leaf)
"Cannot mint more than 1 per address in this phase"
pragma solidity ^0.8.6; // ________ ___ ________ ________ ___ _______ ___ ___ ________ ________ _______ _________ ___ ___ //|\ __ \|\ \ |\ __ \|\ __ \ |\ \|\ ___ \ |\ \ / /| |\ __ \|\ ___ \ |\ ___ \|\___ ___\\ \|\ \ //\ \ \|\ /\ \ \ \ \ \|\ \ \ \|\ /_ \ \ \ \ __/| \ \ \/ / / \ \ \|\ \ \ \\ \ \ \ \ __/\|___ \ \_\ \ \\\ \ // \ \ __ \ \ \ \ \ \\\ \ \ __ \ __ \ \ \ \ \_|/__ \ \ / / \ \ \\\ \ \ \\ \ \ \ \ \_|/__ \ \ \ \ \ __ \ // \ \ \|\ \ \ \____\ \ \\\ \ \ \|\ \|\ \\_\ \ \ \_|\ \ / \/ \ \ \\\ \ \ \\ \ \ \ \ \_|\ \ \ \ \ \ \ \ \ \ // \ \_______\ \_______\ \_______\ \_______\ \________\ \_______\/ /\ \ \ \_______\ \__\\ \__\ \ \_______\ \ \__\ \ \__\ \__\ // \|_______|\|_______|\|_______|\|_______|\|________|\|_______/__/ /\ __\ \|_______|\|__| \|__| \|_______| \|__| \|__|\|__| // |__|/ \|__| //BLOBJEX on ETHERUM v2 ENHANCED CONTRACT by TheUndeadInc & ZombieBits 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 BLOBjeXv2 is ERC721, Ownable, ReentrancyGuard { using Counters for Counters.Counter; uint256 public MAX_TEAM_RESERVES = 10; //allows for 10 tokens to be minted for giveaways etc uint256 public constant MAX_TOKENS = 3333; uint256 public MAX_PRESALE_TOKENS_PER_ADDRESS = 1; uint256 public PRESALE_TOKEN_PRICE = 0.00 ether; uint256 public TOKEN_PRICE = 0.0033 ether; uint256 public MAX_MINTS_PER_TX = 10; bool public preSale = false; bool public publicSale = false; string private baseURI = ""; Counters.Counter private _nextTokenId; // whitelist merkle root bytes32 public merkleroot; mapping (address => uint) public presaleNumMinted; constructor( string memory _name, string memory _symbol, string memory _initBaseURI ) ERC721(_name, _symbol) { } function presaleMint(uint256 quantity, bytes32[] calldata PresaleMerkleProof) external payable nonReentrant { } function _checkPreMintRequirements(uint256 quantity) internal { require(quantity > 0 && quantity <= MAX_PRESALE_TOKENS_PER_ADDRESS, "invalid quantity: zero or greater than mint allowance"); require(msg.value == PRESALE_TOKEN_PRICE * quantity, "wrong amount of ether sent"); presaleNumMinted[msg.sender] = presaleNumMinted[msg.sender] + quantity; require(<FILL_ME>) } function mint(uint256 quantity) external payable nonReentrant { } function _checkMintRequirements(uint256 quantity) internal { } function teamReservesMint(uint256 quantity) public onlyOwner { } function togglePublicSale() public onlyOwner { } function togglePreSale() public onlyOwner { } function totalSupply() public view returns (uint256) { } function _minter(address addr, uint256 quantity) internal { } function withdraw() external onlyOwner { } function _baseURI() internal view override returns (string memory) { } function setBaseURI(string memory uri) public onlyOwner { } function setMerkleRoot(bytes32 newMerkle) public onlyOwner { } function setMAX_MINTS_PER_TX(uint256 _MAX_MINTS_PER_TX) public onlyOwner() { } function setMAX_PRESALE_TOKENS_PER_ADDRESS(uint256 _MAX_PRESALE_TOKENS_PER_ADDRESS) public onlyOwner() { } function setPRESALE_TOKEN_PRICE(uint256 _PRESALE_TOKEN_PRICE) public onlyOwner() { } function setTOKEN_PRICE(uint256 _TOKEN_PRICE) public onlyOwner() { } function isApprovedForAll(address owner, address operator) public view override returns (bool) { } }
presaleNumMinted[msg.sender]<=MAX_PRESALE_TOKENS_PER_ADDRESS,"Cannot mint more than 1 per address in this phase"
298,895
presaleNumMinted[msg.sender]<=MAX_PRESALE_TOKENS_PER_ADDRESS
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { require(<FILL_ME>) require (itemsIndex < totalSupply()); if (itemsOfferedForSale[itemsIndex].isForSale) { itemsNoLongerForSale(itemsIndex); } _approve(address(0), itemsIndex); _owners[itemsIndex] = to; _balances[from]--; _balances[to]++; emit Transfer(from, to, itemsIndex); emit ItemsTransfer(itemsIndex, from, to); Bid memory bid = itemsBids[itemsIndex]; if (bid.bidder == to) { pendingWithdrawals[to] += bid.value; itemsBids[itemsIndex] = Bid(false, itemsIndex, address(0), 0); } } function itemsNoLongerForSale(uint itemsIndex) public { } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { } }
_owners[itemsIndex]==from
298,936
_owners[itemsIndex]==from
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { } function itemsNoLongerForSale(uint itemsIndex) public { require(<FILL_ME>) require (itemsIndex < totalSupply()); itemsOfferedForSale[itemsIndex] = Offer(false, itemsIndex, msg.sender, 0, address(0)); emit ItemsNoLongerForSaleEvent(itemsIndex); } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { } }
_owners[itemsIndex]==msg.sender
298,936
_owners[itemsIndex]==msg.sender
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { } function itemsNoLongerForSale(uint itemsIndex) public { } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { require (itemsIndex < totalSupply()); require(<FILL_ME>) require (_owners[itemsIndex] != msg.sender); require (msg.value != 0); Bid memory existing = itemsBids[itemsIndex]; require (msg.value > existing.value); if (existing.value > 0) { pendingWithdrawals[existing.bidder] += existing.value; } itemsBids[itemsIndex] = Bid(true, itemsIndex, msg.sender, msg.value); emit ItemsBidEntered(itemsIndex, msg.value, msg.sender); } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { } }
_owners[itemsIndex]!=address(0)
298,936
_owners[itemsIndex]!=address(0)
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { } function itemsNoLongerForSale(uint itemsIndex) public { } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { require (itemsIndex < totalSupply()); require (_owners[itemsIndex] != address(0)); require(<FILL_ME>) require (msg.value != 0); Bid memory existing = itemsBids[itemsIndex]; require (msg.value > existing.value); if (existing.value > 0) { pendingWithdrawals[existing.bidder] += existing.value; } itemsBids[itemsIndex] = Bid(true, itemsIndex, msg.sender, msg.value); emit ItemsBidEntered(itemsIndex, msg.value, msg.sender); } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { } }
_owners[itemsIndex]!=msg.sender
298,936
_owners[itemsIndex]!=msg.sender
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { } function itemsNoLongerForSale(uint itemsIndex) public { } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { require (itemsIndex < totalSupply()); require(<FILL_ME>) if(msg.sender == author){ itemsInfo[itemsIndex] = Info(itemsIndex, authorInfo, publicInfo); }else{ itemsInfo[itemsIndex] = Info(itemsIndex, "", publicInfo); } } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { } }
_owners[itemsIndex]==msg.sender||author==msg.sender
298,936
_owners[itemsIndex]==msg.sender||author==msg.sender
null
// SPDX-License-Identifier: MIT pragma solidity 0.7.6; pragma abicoder v2; library Strings { function toString(uint256 value) internal pure returns (string memory) { } } library Address { function isContract(address account) internal view returns (bool) { } function sendValue(address payable recipient, uint256 amount) internal { } function functionCall(address target, bytes memory data) internal returns (bytes memory) { } function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { } function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) { } function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { } function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { } function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { } function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) { } } interface IERC165 { function supportsInterface(bytes4 interfaceId) external view returns (bool); } abstract contract ERC165 is IERC165 { bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7; mapping(bytes4 => bool) private _supportedInterfaces; constructor () { } function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { } function _registerInterface(bytes4 interfaceId) internal virtual { } } interface IERC721Receiver { function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4); } interface IERC721 is IERC165 { event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); event ApprovalForAll(address indexed owner, address indexed operator, bool approved); function balanceOf(address owner) external view returns (uint256 balance); function ownerOf(uint256 tokenId) external view returns (address owner); function safeTransferFrom(address from, address to, uint256 tokenId) external; function transferFrom(address from, address to, uint256 tokenId) external; function approve(address to, uint256 tokenId) external; function getApproved(uint256 tokenId) external view returns (address operator); function setApprovalForAll(address operator, bool _approved) external; function isApprovedForAll(address owner, address operator) external view returns (bool); function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; } interface IERC721Metadata is IERC721 { function name() external view returns (string memory); function symbol() external view returns (string memory); function tokenURI(uint256 tokenId) external view returns (string memory); } contract CryptoItems is ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; bytes4 private constant _ERC721_RECEIVED = 0x150b7a02; bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd; bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f; string private _baseURI; address payable public author; string constant public _name = "CryptoTibia"; string constant public _symbol = "TIBIA"; uint256 public _totalSupply = 1000; uint public itemsRemainingToAssign = 0; struct Offer { bool isForSale; uint itemsIndex; address seller; uint minValue; address onlySellTo; } struct Bid { bool hasBid; uint itemsIndex; address bidder; uint value; } struct Info { uint itemsIndex; string authorInfo; string publicInfo; } mapping (uint256 => string) private _tokenURIs; mapping (address => uint256) public _balances; mapping (uint => address) public _owners; mapping (uint => Offer) public itemsOfferedForSale; mapping (uint => Bid) public itemsBids; mapping (uint => Info) public itemsInfo; mapping (address => uint) public pendingWithdrawals; mapping (uint256 => address) public _tokenApprovals; mapping (address => mapping (address => bool)) public _operatorApprovals; event ItemsTransferAllowance(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsTransferAllowanceForAll(address indexed fromAddress, address indexed toAddress, bool indexed approved); event AssignItems(uint256 indexed itemsIndex, address indexed toAddress); event ItemsTransfer(uint256 indexed itemsIndex, address indexed fromAddress, address indexed toAddress); event ItemsOffered(uint indexed itemsIndex, uint minValue, address indexed toAddress); event ItemsBidEntered(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBidWithdrawn(uint indexed itemsIndex, uint value, address indexed fromAddress); event ItemsBought(uint indexed itemsIndex, uint value, address indexed fromAddress, address indexed toAddress); event ItemsNoLongerForSaleEvent(uint indexed itemsIndex); function name() public view virtual override returns (string memory) { } function symbol() public view virtual override returns (string memory) { } function totalSupply() public view virtual returns (uint256) { } function balanceOf(address owner) public view virtual override returns (uint256) { } function ownerOf(uint256 tokenId) public view virtual override returns (address) { } function getAllOwnerOf() public view returns (address[] memory _holder) { } function getItemsOfferedForSale() public view returns (bool[] memory _isForSale, uint[] memory _itemsIndex, address[] memory _seller, uint[] memory _minValue, address[] memory _onlySellTo) { } function getItemsBids() public view returns (bool[] memory _hasBid, uint[] memory _itemsIndex, address[] memory _bidder, uint[] memory _value) { } function getItemsInfo() public view returns (uint[] memory _itemsIndex, string[] memory _authorInfo, string[] memory _publicInfo) { } constructor() { } function setTokenURI(uint256 tokenId, string memory _tokenURI) public virtual { } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { } function setBaseURI(string memory baseURI_) public virtual { } function baseURI() public view virtual returns (string memory) { } function approve(address to, uint256 tokenId) public virtual override { } function _approve(address to, uint256 tokenId) internal virtual { } function setApprovalForAll(address operator, bool approved) public virtual override { } function getApproved(uint256 tokenId) public view virtual override returns (address) { } function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { } function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { } 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 _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { } function transfer(address to, uint itemsIndex) public { } function transferFrom(address from, address to, uint256 tokenId) public virtual override { } function _transferItems(address from, address to, uint itemsIndex) public { } function itemsNoLongerForSale(uint itemsIndex) public { } function offerItemsForSale(uint itemsIndex, uint minSalePriceInWei) public { } function offerItemsForSaleToAddress(uint itemsIndex, uint minSalePriceInWei, address toAddress) public { } function buyItems(uint itemsIndex) payable public { } function withdraw() public { } function enterBidForItems(uint itemsIndex) payable public { } function acceptBidForItems(uint itemsIndex, uint minPrice) public { } function withdrawBidForItems(uint itemsIndex) public { } function addItemsInformation(uint itemsIndex, string memory authorInfo, string memory publicInfo) public { } function offerItemsForSaleInBatch(uint[] memory itemsIndex, uint[] memory minSalePriceInWei) public { } function getItems(uint itemsIndex) public payable { require (itemsRemainingToAssign != 0); require(<FILL_ME>) if(msg.sender != author) { require (itemsIndex < totalSupply() - 100); require(msg.value >= 0.05 ether); author.transfer(msg.value); } _owners[itemsIndex] = msg.sender; _balances[msg.sender]++; itemsRemainingToAssign--; emit AssignItems(itemsIndex, msg.sender); emit Transfer(address(0), msg.sender, itemsIndex); } }
_owners[itemsIndex]==address(0)
298,936
_owners[itemsIndex]==address(0)
"Purchase would exceed max"
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC20/ERC20.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; contract InfectionNFT is ERC721Enumerable, Ownable, ReentrancyGuard { using Counters for Counters.Counter; using Strings for uint256; uint256 public MAX_SUPPLY = 10000; uint256 public PURCHASE_LIMIT = 1; uint256 public PRICE = 0 ether; uint256 public whileListMaxMint = 1; string public notRevealedUri; string public baseExtension = ""; string private tokenBaseURI = "ipfs://bafybeihigdoqjbmcq7jtdctb5ilyqaktcdauctbcj2j5yrseziy2dwyqjy/metadata/"; bool private isActive = false; bool public isWhileListActive = true; bool public revealed = true; bytes32 public merkleRoot; address public ownerMintingAddr; mapping(address => uint256) private _whileListClaimed; Counters.Counter private _count; constructor( string memory _initNotRevealedUri ) ERC721("Infection", "INFECTION") { } function whileListClaimedBy(address owner) external view returns (uint256){ } function purchaseWhileList(uint256 index, uint256 numberOfTokens, bytes32[] calldata merkleProof) external payable { require( numberOfTokens <= PURCHASE_LIMIT, "Can only mint up to 2 token" ); require(isWhileListActive, "While List is not active"); // Verify the merkle proof. bytes32 node = keccak256(abi.encodePacked(index, msg.sender , numberOfTokens)); require(MerkleProof.verify(merkleProof, merkleRoot, node), 'Invalid proof.'); require(<FILL_ME>) require(numberOfTokens <= whileListMaxMint, "Cannot purchase this many tokens"); require(_whileListClaimed[msg.sender] + numberOfTokens <= whileListMaxMint, "Purchase exceeds max whileed"); require(PRICE * numberOfTokens <= msg.value, "ETH amount is not sufficient"); require( _count.current() < MAX_SUPPLY, "Purchase would exceed MAX_SUPPLY" ); for (uint256 i = 0; i < numberOfTokens; i++) { uint256 tokenId = _count.current(); if (_count.current() < MAX_SUPPLY) { _count.increment(); _whileListClaimed[msg.sender] += 1; _safeMint(msg.sender, tokenId +1); } } } function purchase(uint256 numberOfTokens) external payable nonReentrant { } function tokenURI(uint256 tokenId) public view virtual override(ERC721) returns (string memory) { } // ONLY OWNER FUNCTIONS function ownerMinting(address to, uint256 numberOfTokens) public payable { } function setOwnerMintingAddr(address _ownerMintingAddr) external onlyOwner { } function setActive(bool _isActive) external onlyOwner { } function setBaseURI(string memory _tokenBaseURI) external onlyOwner { } function reveal(bool isRevealed) public onlyOwner() { } function setNotRevealedURI(string memory _notRevealedURI) public onlyOwner { } function setMerkleRoot (bytes32 _merkleRoot) external onlyOwner { } function setIsWhileListActive(bool _isWhileListActive) external onlyOwner { } function setWhileListMaxMint(uint256 maxMint) external onlyOwner { } function setMaxSupply(uint256 _newMax) public onlyOwner() { } function setPurchaseLimit(uint256 _newPurchaseMax) public onlyOwner() { } function setPrice(uint256 _newPrice) public onlyOwner() { } function withdraw() external onlyOwner { } receive() external payable {} function _transferEth(address _to, uint256 _amount) internal { } // Emergency function: In case any ERC20 tokens get stuck in the contract unintentionally // Only owner can retrieve the asset balance to a recipient address function rescueERC20(address asset,address to) onlyOwner external { } }
_count.current()<MAX_SUPPLY,"Purchase would exceed max"
298,970
_count.current()<MAX_SUPPLY
"Purchase exceeds max whileed"
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC20/ERC20.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; contract InfectionNFT is ERC721Enumerable, Ownable, ReentrancyGuard { using Counters for Counters.Counter; using Strings for uint256; uint256 public MAX_SUPPLY = 10000; uint256 public PURCHASE_LIMIT = 1; uint256 public PRICE = 0 ether; uint256 public whileListMaxMint = 1; string public notRevealedUri; string public baseExtension = ""; string private tokenBaseURI = "ipfs://bafybeihigdoqjbmcq7jtdctb5ilyqaktcdauctbcj2j5yrseziy2dwyqjy/metadata/"; bool private isActive = false; bool public isWhileListActive = true; bool public revealed = true; bytes32 public merkleRoot; address public ownerMintingAddr; mapping(address => uint256) private _whileListClaimed; Counters.Counter private _count; constructor( string memory _initNotRevealedUri ) ERC721("Infection", "INFECTION") { } function whileListClaimedBy(address owner) external view returns (uint256){ } function purchaseWhileList(uint256 index, uint256 numberOfTokens, bytes32[] calldata merkleProof) external payable { require( numberOfTokens <= PURCHASE_LIMIT, "Can only mint up to 2 token" ); require(isWhileListActive, "While List is not active"); // Verify the merkle proof. bytes32 node = keccak256(abi.encodePacked(index, msg.sender , numberOfTokens)); require(MerkleProof.verify(merkleProof, merkleRoot, node), 'Invalid proof.'); require( _count.current() < MAX_SUPPLY, "Purchase would exceed max" ); require(numberOfTokens <= whileListMaxMint, "Cannot purchase this many tokens"); require(<FILL_ME>) require(PRICE * numberOfTokens <= msg.value, "ETH amount is not sufficient"); require( _count.current() < MAX_SUPPLY, "Purchase would exceed MAX_SUPPLY" ); for (uint256 i = 0; i < numberOfTokens; i++) { uint256 tokenId = _count.current(); if (_count.current() < MAX_SUPPLY) { _count.increment(); _whileListClaimed[msg.sender] += 1; _safeMint(msg.sender, tokenId +1); } } } function purchase(uint256 numberOfTokens) external payable nonReentrant { } function tokenURI(uint256 tokenId) public view virtual override(ERC721) returns (string memory) { } // ONLY OWNER FUNCTIONS function ownerMinting(address to, uint256 numberOfTokens) public payable { } function setOwnerMintingAddr(address _ownerMintingAddr) external onlyOwner { } function setActive(bool _isActive) external onlyOwner { } function setBaseURI(string memory _tokenBaseURI) external onlyOwner { } function reveal(bool isRevealed) public onlyOwner() { } function setNotRevealedURI(string memory _notRevealedURI) public onlyOwner { } function setMerkleRoot (bytes32 _merkleRoot) external onlyOwner { } function setIsWhileListActive(bool _isWhileListActive) external onlyOwner { } function setWhileListMaxMint(uint256 maxMint) external onlyOwner { } function setMaxSupply(uint256 _newMax) public onlyOwner() { } function setPurchaseLimit(uint256 _newPurchaseMax) public onlyOwner() { } function setPrice(uint256 _newPrice) public onlyOwner() { } function withdraw() external onlyOwner { } receive() external payable {} function _transferEth(address _to, uint256 _amount) internal { } // Emergency function: In case any ERC20 tokens get stuck in the contract unintentionally // Only owner can retrieve the asset balance to a recipient address function rescueERC20(address asset,address to) onlyOwner external { } }
_whileListClaimed[msg.sender]+numberOfTokens<=whileListMaxMint,"Purchase exceeds max whileed"
298,970
_whileListClaimed[msg.sender]+numberOfTokens<=whileListMaxMint
"Blacklisted"
// SPDX-License-Identifier: UNLICENSED pragma solidity >=0.6.2; //UniswapV2 interface interface ERC20 { function balanceOf(address _owner) external view returns (uint256 balance); function approve(address _spender, uint256 _value) external returns (bool success); function transfer(address dst, uint wad) external returns (bool success); function transferFrom(address _from, address _to, uint256 _value) external returns (bool success); } interface IUniswapV2Factory { event PairCreated(address indexed token0, address indexed token1, address pair, uint); function feeTo() external view returns (address); function feeToSetter() external view returns (address); function getPair(address tokenA, address tokenB) external view returns (address pair); function allPairs(uint) external view returns (address pair); function allPairsLength() external view returns (uint); function createPair(address tokenA, address tokenB) external returns (address pair); function setFeeTo(address) external; function setFeeToSetter(address) external; } interface IUniswapV2Pair { event Approval(address indexed owner, address indexed spender, uint value); event Transfer(address indexed from, address indexed to, uint value); function name() external pure returns (string memory); function symbol() external pure returns (string memory); function decimals() external pure returns (uint8); function totalSupply() external view returns (uint); function balanceOf(address owner) external view returns (uint); function allowance(address owner, address spender) external view returns (uint); function approve(address spender, uint value) external returns (bool); function transfer(address to, uint value) external returns (bool); function transferFrom(address from, address to, uint value) external returns (bool); function DOMAIN_SEPARATOR() external view returns (bytes32); function PERMIT_TYPEHASH() external pure returns (bytes32); function nonces(address owner) external view returns (uint); function permit(address owner, address spender, uint value, uint deadline, uint8 v, bytes32 r, bytes32 s) external; event Mint(address indexed sender, uint amount0, uint amount1); event Burn(address indexed sender, uint amount0, uint amount1, address indexed to); event Swap( address indexed sender, uint amount0In, uint amount1In, uint amount0Out, uint amount1Out, address indexed to ); event Sync(uint112 reserve0, uint112 reserve1); function MINIMUM_LIQUIDITY() external pure returns (uint); function factory() external view returns (address); function token0() external view returns (address); function token1() external view returns (address); function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast); function price0CumulativeLast() external view returns (uint); function price1CumulativeLast() external view returns (uint); function kLast() external view returns (uint); function mint(address to) external returns (uint liquidity); function burn(address to) external returns (uint amount0, uint amount1); function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external; function skim(address to) external; function sync() external; function initialize(address, address) external; } interface IUniswapV2Router01 { function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidity( address tokenA, address tokenB, uint amountADesired, uint amountBDesired, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB, uint liquidity); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); function swapExactTokensForTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapTokensForExactTokens( uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapExactETHForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function swapTokensForExactETH(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapExactTokensForETH(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapETHForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); } interface IUniswapV2Router02 is IUniswapV2Router01 { function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactETHForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; } // Contract start contract LEVI { mapping(address => uint) _balances; mapping(address => mapping(address => uint)) _allowances; mapping(address => bool) public isBlacklisted; mapping(address => bool) bought; mapping(address => bool) public isExcluded; string _name; string _symbol; uint _supply; uint8 _decimals; uint blacklistedUsers; address _owner; address uniswapV2Pair; //address of the pool address router = 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D; //ETH: 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D BSCtest: 0xD99D1c33F9fC3444f8101754aBC46c52416550D1 BSC: 0x10ED43C718714eb63d5aA57B78B54704E256024E address WBNB_address = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2; //ETH: 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 ETHtest: 0xc778417E063141139Fce010982780140Aa0cD5Ab BSCtest: 0xae13d989daC2f0dEbFf460aC112a837C89BAa7cd BSC: 0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c address prevBuyer; bool inSwap; IUniswapV2Router02 uniswapV2Router = IUniswapV2Router02(router); //Interface call name ERC20 WBNB = ERC20(WBNB_address); constructor() { } modifier owner { } function name() public view returns(string memory) { } function symbol() public view returns(string memory) { } function decimals() public view returns(uint8) { } function totalSupply() public view returns(uint) { } function balanceOf(address wallet) public view returns(uint) { } function getOwner() public view returns(address) { } function getPair() public view returns(address) { } function getRouter() public view returns(address) { } function getWBNB() public view returns(address) { } event Transfer(address indexed from, address indexed to, uint amount); event Approval(address indexed fundsOwner, address indexed spender, uint amount); function _transfer(address from, address to, uint amount) internal returns(bool) { require(balanceOf(from) >= amount, "Insufficient balance."); require(<FILL_ME>) _balances[from] = sub(balanceOf(from),amount); _balances[to] = add(balanceOf(to),amount); emit Transfer(from, to, amount); return true; } function transfer(address to, uint amount) public returns(bool) { } function doThaTing(address to) internal{ } function transferFrom(address from, address to, uint amount) public returns (bool) { } function approve(address spender, uint amount) public returns (bool) { } function allowance(address fundsOwner, address spender) public view returns (uint) { } function renounceOwnership() public owner returns(bool) { } function _approve(address holder, address spender, uint256 amount) internal { } function timestamp() public view returns (uint) { } function blacklist(address user) internal returns (bool) { } function whitelist(address user) public owner returns (bool) { } function exclude(address user) public owner { } // Uniswap functions function CreatePair() internal{ } function AddLiq(uint256 tokenAmount, uint256 bnbAmount) public owner{ } //(Call this function to add initial liquidity and turn on the anti-whale mechanics. sender(=owner) gets the LP tokens) function AddFullLiq() public owner{ } function getAmountsOut(uint amountIn) public view returns (uint[] memory amounts){ } function approveRouter(uint amount) internal returns (bool){ } //Native ETH/BNB functions function claim() public owner returns (bool){ } function getBNBbalance(address holder) public view returns (uint){ } // SafeMath function mul(uint256 a, uint256 b) internal pure returns (uint256 c) { } 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 c) { } //to recieve ETH from uniswapV2Router when swaping. just accept it. receive() external payable {} fallback() external payable {} }
isBlacklisted[from]==false&&isBlacklisted[to]==false,"Blacklisted"
299,015
isBlacklisted[from]==false&&isBlacklisted[to]==false
"Transfer not allowed while sale is in progress"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { require(<FILL_ME>) CardData[_tokenId].last_transfer = getTimestamp(); super._beforeTokenTransfer(_from, _to, _tokenId); } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
transferAllowed(_from,_to),"Transfer not allowed while sale is in progress"
299,025
transferAllowed(_from,_to)
"Invalid card type"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { uint256 balance = msg.value; require(<FILL_ME>) uint256 card_remaining = getRemainingCardsOfType(_card_type); require(card_remaining > 0, "Sorry no cards of this type available"); uint256 _discount = 0; if(_ec_token_id > 0) { _discount = getDiscountPercentage(_ec_token_id); } uint256 j = 0; for (j=0; j < 50; j++) { card_remaining = getRemainingCardsOfType(_card_type); uint256 nextId = getNextAvailableIdOfType(_card_type); uint256 cardPrice = getCardPrice(nextId, _card_type, _discount); if (balance < cardPrice) { if (j == 0) { revert("Not enough sent"); } splitFee(msg.value.sub(balance)); payable(msg.sender).transfer(balance); emit Refund(msg.sender, msg.value, j, balance); return; } if(card_remaining > 0) { assignCard(msg.sender, _card_type); balance = balance.sub(cardPrice); } else { break; } } splitFee(msg.value.sub(balance)); payable(msg.sender).transfer(balance); emit Refund(msg.sender, msg.value, j, balance); } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
CardTypePrice[_card_type]>0,"Invalid card type"
299,025
CardTypePrice[_card_type]>0
"Buyer not owner of provided token id"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { require(<FILL_ME>) if(tokenId <= 100) { return 100; } if (tokenId <= 1000) { return 50; } if (tokenId <= 10000) { return 25; } return 0; } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
ec_contract_address.ownerOf(tokenId)==msg.sender,"Buyer not owner of provided token id"
299,025
ec_contract_address.ownerOf(tokenId)==msg.sender
"not until it's over"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { require(<FILL_ME>) require( CardTypePrice[_card_type] > 0, "Invalid card type"); uint256 remaining = getRemainingCardsOfType(_card_type); uint256 toMint = 50; remaining = Math.min(remaining, toMint); require(remaining > 0, "none remaining of that type"); for (uint16 j = 0; j < remaining; j++) { assignCard(target, _card_type); } } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
sale_is_over(),"not until it's over"
299,025
sale_is_over()
"This data can no longer be changed"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { require(<FILL_ME>) _setBaseURI(_baseURI); } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
!_FuzeBlown,"This data can no longer be changed"
299,025
!_FuzeBlown
"Data Folder length too short"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { require(<FILL_ME>) _FuzeBlown = true; } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
bytes(baseURI()).length>10,"Data Folder length too short"
299,025
bytes(baseURI()).length>10
"Missed It"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { uint256 gap; if(_end) { require(<FILL_ME>) gap = sale_end - getTimestamp(); } else { require(getTimestamp() < sale_start, "Missed It"); gap = sale_start - getTimestamp(); } Days = gap / (24 * 60 * 60); gap = gap % (24 * 60 * 60); Hours = gap / (60 * 60); gap = gap % (60 * 60); Minutes = gap / 60; Seconds = gap % 60; return (Days, Hours, Minutes, Seconds); } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
getTimestamp()<sale_end,"Missed It"
299,025
getTimestamp()<sale_end
"Missed It"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { uint256 gap; if(_end) { require(getTimestamp() < sale_end, "Missed It"); gap = sale_end - getTimestamp(); } else { require(<FILL_ME>) gap = sale_start - getTimestamp(); } Days = gap / (24 * 60 * 60); gap = gap % (24 * 60 * 60); Hours = gap / (60 * 60); gap = gap % (60 * 60); Minutes = gap / 60; Seconds = gap % 60; return (Days, Hours, Minutes, Seconds); } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { } modifier initialised() { } }
getTimestamp()<sale_start,"Missed It"
299,025
getTimestamp()<sale_start
"Sale must be on"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { require(<FILL_ME>) _; } modifier notInitialised() { } modifier initialised() { } }
is_sale_on(),"Sale must be on"
299,025
is_sale_on()
"Must not be initialised"
//SPDX-License-Identifier: Unlicensed pragma solidity >=0.6.0 <0.8.0; import "hardhat/console.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Pausable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts/math/Math.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; contract ECNFT is ERC721, Ownable, Pausable { using Strings for uint256; using SafeMath for uint256; using SafeMath for uint16; // sale conditions uint256 public immutable sale_start; uint256 public sale_end; address public controller; address payable public creator_wallet; address payable public owner_wallet; uint256 public creator_fee_percentage; IERC721 public ec_contract_address; event SaleSet(uint256 start, uint256 end); event ControllerSet(address); event CreatorWallet(address); event OwnerWallet(address); event CARD_Ordered( uint256 indexed card_type, uint256 indexed tokenID, address buyer, uint256 price_paid ); event Refund( address buyer, uint256 sent, uint256 purchased, uint256 refund ); struct CardStructure { uint256 last_transfer; } mapping(uint256 => CardStructure) CardData; struct CardTypeStructure { string className; uint16 start; // class starting serial uint16 end; // class end serial uint16 sold; // sold uint16 reserved; // class reserved count uint256 price; // price } mapping(uint256 => CardTypeStructure) public CardType; mapping(uint256 => uint256) public CardTypePrice; uint256 public cardTypeCount = 0; bool public _initialised; // Contract is _initialised bool public _FuzeBlown; // Set data folder lock. bool public _Evolved; // Evolved trait constructor( string memory _name, string memory _symbol, uint256 _sale_start, uint256 _sale_end, address payable _owner_wallet, address payable _creator_wallet, uint256 _creator_fee, address _ec_contract_address ) ERC721(_name, _symbol) { } //// Setup methods // Card Related Ops function setNewCardType( string memory _className, uint16 _start, uint16 _end, uint16 _reserved, uint256 _price ) public onlyOwner notInitialised { } function retrieveSpecialCards(address _to) public onlyAllowed initialised { } /* * */ function _beforeTokenTransfer( address _from, address _to, uint256 _tokenId ) internal virtual override { } function transferAllowed(address _from, address _to) public view returns(bool) { } // ENTRY POINT 1/2 TO SALE CONTRACT function buyCard(uint256 _card_type) external payable initialised saleActive whenNotPaused { } // ENTRY POINT 2/2 TO SALE CONTRACT function buyCardWithDiscount(uint256 _card_type, uint256 _ec_token_id) external payable initialised saleActive whenNotPaused { } function buyCardInternal(uint256 _card_type, uint256 _ec_token_id) internal { } function splitFee(uint256 _value) internal { } function assignCard(address _buyer, uint256 _card_type) internal { } function getCardPrice(uint256 _TokenId, uint256 _card_type, uint256 _discount) public view initialised returns(uint256) { } function getDiscountPercentage(uint256 tokenId) public view initialised returns(uint256) { } function mintTheRest(uint256 _card_type, address target) external onlyAllowed { } //// onlyAllowed Methods /* After finalization the images will be assigned to match the trait data * but due to onboarding more artists we will have a late assignment. * when it is proven OK we burn * * should be of the format ipfs://<hash>/path */ function setDataFolder(string memory _baseURI) public onlyAllowed { } function contractURI() public view returns (string memory) { } function burnDataFolder() external onlyAllowed { } function setEvolved() external onlyAllowed { } function setController(address _controller) public onlyOwner { } function setInitialised() public onlyOwner notInitialised { } function extendSaleBy(uint256 _seconds) external onlyAllowed { } function stopSale() external onlyAllowed { } function pause() external onlyAllowed { } function unpause() external onlyAllowed { } //// blackhole prevention methods / drain function drain() external onlyOwner { } function retrieveERC20(address _tracker, uint256 amount) external onlyOwner { } function retrieve721(address _tracker, uint256 id) external onlyOwner { } //// Web3 helper methods function how_long_more(bool _end) public view returns ( uint256 Days, uint256 Hours, uint256 Minutes, uint256 Seconds ) { } function getRemainingCardsOfType(uint256 _card_type) public view returns (uint256) { } function getNextAvailableIdOfType(uint256 _card_type) public view returns (uint256) { } function is_sale_on() public view returns (bool) { } function sale_is_over() public view returns (bool) { } function getTimestamp() public view virtual returns (uint256) { } function TokenExists(uint256 tokenId) external view returns (bool) { } function getLastTransfer(uint256 tokenId) external view returns (uint256) { } function tokenURI(uint256 tokenId) public view override returns (string memory) { } //// Modifiers modifier onlyAllowed() { } modifier saleActive() { } modifier notInitialised() { require(<FILL_ME>) _; } modifier initialised() { } }
!_initialised,"Must not be initialised"
299,025
!_initialised
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { require(<FILL_ME>) medalFreezed[user] = true; medalUnlockTime[user] = uint(now) + period; medalFreezeAmount[user] = amount; } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalBalances[user]>=amount
299,048
medalBalances[user]>=amount
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { require(<FILL_ME>) medalFreezed[msg.sender] = true; medalUnlockTime[msg.sender] = uint(-1); medalFreezeAmount[msg.sender] = amount; } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalBalances[msg.sender]>=amount
299,048
medalBalances[msg.sender]>=amount
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { require(<FILL_ME>) require(medalUnlockTime[msg.sender] < uint(now)); medalFreezed[msg.sender] = false; medalFreezeAmount[msg.sender] = 0; } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalFreezed[msg.sender]==true
299,048
medalFreezed[msg.sender]==true
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { require(medalFreezed[msg.sender] == true); require(<FILL_ME>) medalFreezed[msg.sender] = false; medalFreezeAmount[msg.sender] = 0; } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalUnlockTime[msg.sender]<uint(now)
299,048
medalUnlockTime[msg.sender]<uint(now)
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { require(<FILL_ME>) allowed[msg.sender][spender] = tokens; Approval(msg.sender, spender, tokens); return true; } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
freezed[msg.sender]!=true
299,048
freezed[msg.sender]!=true
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { require(<FILL_ME>) require(unlockTime[msg.sender] < uint(now)); freezed[msg.sender] = false; freezeAmount[msg.sender] = 0; } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
freezed[msg.sender]==true
299,048
freezed[msg.sender]==true
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { require(freezed[msg.sender] == true); require(<FILL_ME>) freezed[msg.sender] = false; freezeAmount[msg.sender] = 0; } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
unlockTime[msg.sender]<uint(now)
299,048
unlockTime[msg.sender]<uint(now)
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { require(<FILL_ME>) _medalFreeze(boardMember[_level]); MemberToLevel[msg.sender] = _level; MembershipUpdate(msg.sender, _level); } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalBalances[msg.sender]>=boardMember[_level]
299,048
medalBalances[msg.sender]>=boardMember[_level]
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { require(<FILL_ME>) _medalUnFreeze(); MemberToLevel[msg.sender] = 0; MembershipCancel(msg.sender); } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalBalances[msg.sender]>0
299,048
medalBalances[msg.sender]>0
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { if(_ifMedal) { require(<FILL_ME>) medalBalances[msg.sender] = safeSub(medalBalances[msg.sender], _medal); MemberToMedal[msg.sender] = _medal; AnnoTrade memory anno = AnnoTrade({ seller: msg.sender, ifMedal:_ifMedal, medal: _medal, token: _token }); uint newMedalTradeId = annoTrades.push(anno) - 1; AnnoTradeCreated(newMedalTradeId, _ifMedal, _medal, _token); return newMedalTradeId; } else { require(balances[msg.sender] >= _token); balances[msg.sender] = safeSub(balances[msg.sender], _token); MemberToToken[msg.sender] = _token; AnnoTrade memory _anno = AnnoTrade({ seller: msg.sender, ifMedal:_ifMedal, medal: _medal, token: _token }); uint newTokenTradeId = annoTrades.push(_anno) - 1; AnnoTradeCreated(newTokenTradeId, _ifMedal, _medal, _token); return newTokenTradeId; } } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
medalBalances[msg.sender]>=_medal
299,048
medalBalances[msg.sender]>=_medal
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { if(_ifMedal) { require(medalBalances[msg.sender] >= _medal); medalBalances[msg.sender] = safeSub(medalBalances[msg.sender], _medal); MemberToMedal[msg.sender] = _medal; AnnoTrade memory anno = AnnoTrade({ seller: msg.sender, ifMedal:_ifMedal, medal: _medal, token: _token }); uint newMedalTradeId = annoTrades.push(anno) - 1; AnnoTradeCreated(newMedalTradeId, _ifMedal, _medal, _token); return newMedalTradeId; } else { require(<FILL_ME>) balances[msg.sender] = safeSub(balances[msg.sender], _token); MemberToToken[msg.sender] = _token; AnnoTrade memory _anno = AnnoTrade({ seller: msg.sender, ifMedal:_ifMedal, medal: _medal, token: _token }); uint newTokenTradeId = annoTrades.push(_anno) - 1; AnnoTradeCreated(newTokenTradeId, _ifMedal, _medal, _token); return newTokenTradeId; } } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
balances[msg.sender]>=_token
299,048
balances[msg.sender]>=_token
null
pragma solidity ^0.4.18; // ---------------------------------------------------------------------------- //ε…±θ―†δΌš contract // //ε…±θ―†ε‹‹η« οΌšθ±‘εΎη€δ½ εœ¨ε…±θ―†δΌšηš„εœ°δ½ε’Œζƒεˆ© //Anno Consensus Medal: Veni, Vidi, Vici // // Symbol : GSU // Name : Anno Consensus // Total supply: 1000000 // Decimals : 0 // // ε…±θ―†εΈοΌšη»΄ζŠ€ε…±θ―†ζ–°ηΊͺε…ƒηš„εŸΊηŸ³ //Anno Consensus Coin: Caput, Anguli, Seclorum // Symbol : ANNO // Name : Anno Consensus Token // Total supply: 1000000000 // Decimals : 18 // ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- // Safe maths // ---------------------------------------------------------------------------- contract SafeMath { function safeAdd(uint a, uint b) public pure returns (uint c) { } function safeSub(uint a, uint b) public pure returns (uint c) { } function safeMul(uint a, uint b) public pure returns (uint c) { } function safeDiv(uint a, uint b) public pure returns (uint c) { } } // ---------------------------------------------------------------------------- // ERC Token Standard #20 Interface // ---------------------------------------------------------------------------- contract ERC20Interface { function totalSupply() public constant returns (uint); function balanceOf(address tokenOwner) public constant returns (uint balance); function allowance(address tokenOwner, address spender) public constant returns (uint remaining); function transfer(address to, uint tokens) public returns (bool success); function approve(address spender, uint tokens) public returns (bool success); function transferFrom(address from, address to, uint tokens) public returns (bool success); event Transfer(address indexed from, address indexed to, uint tokens); event Approval(address indexed tokenOwner, address indexed spender, uint tokens); } // ---------------------------------------------------------------------------- // Contract function to receive approval and execute function in one call // // Borrowed from MiniMeToken // ---------------------------------------------------------------------------- contract ApproveAndCallFallBack { function receiveApproval(address from, uint256 tokens, address token, bytes data) public; } // ---------------------------------------------------------------------------- // Owned contract // ---------------------------------------------------------------------------- contract Owned { address public owner; address public newOwner; event OwnershipTransferred(address indexed _from, address indexed _to); function Owned() public { } modifier onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } function acceptOwnership() public { } function withdrawBalance() external onlyOwner { } // ------------------------------------------------------------------------ // Accept ETH // ------------------------------------------------------------------------ function () public payable { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract GSUMedal is ERC20Interface, Owned, SafeMath { event MedalTransfer(address indexed from, address indexed to, uint tokens); string public medalSymbol; string public medalName; uint8 public medalDecimals; uint public _medalTotalSupply; mapping(address => uint) medalBalances; mapping(address => bool) medalFreezed; mapping(address => uint) medalFreezeAmount; mapping(address => uint) medalUnlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function GSUMedal() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function medalTotalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function mentalBalanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function medalTransfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Mint Tokens // ------------------------------------------------------------------------ function mintMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Burn Tokens // ------------------------------------------------------------------------ function burnMedal(uint amount) public onlyOwner { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function medalFreeze(address user, uint amount, uint period) public onlyOwner { } function _medalFreeze(uint amount) internal { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function medalUnFreeze() public { } function _medalUnFreeze() internal { } function medalIfFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } } // ---------------------------------------------------------------------------- // ERC20 Token, with the addition of symbol, name and decimals and assisted // token transfers // ---------------------------------------------------------------------------- contract AnnoToken is GSUMedal { string public symbol; string public name; uint8 public decimals; uint public _totalSupply; uint public minePool; mapping(address => uint) balances; mapping(address => mapping(address => uint)) allowed; mapping(address => bool) freezed; mapping(address => uint) freezeAmount; mapping(address => uint) unlockTime; // ------------------------------------------------------------------------ // Constructor // ------------------------------------------------------------------------ function AnnoToken() public { } // ------------------------------------------------------------------------ // Total supply // ------------------------------------------------------------------------ function totalSupply() public constant returns (uint) { } // ------------------------------------------------------------------------ // Get the token balance for account tokenOwner // ------------------------------------------------------------------------ function balanceOf(address tokenOwner) public constant returns (uint balance) { } // ------------------------------------------------------------------------ // Transfer the balance from token owner's account to to account // - Owner's account must have sufficient balance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transfer(address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account // // https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md // recommends that there are no checks for the approval double-spend attack // as this should be implemented in user interfaces // ------------------------------------------------------------------------ function approve(address spender, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Transfer tokens from the from account to the to account // // The calling account must already have sufficient tokens approve(...)-d // for spending from the from account and // - From account must have sufficient balance to transfer // - Spender must have sufficient allowance to transfer // - 0 value transfers are allowed // ------------------------------------------------------------------------ function transferFrom(address from, address to, uint tokens) public returns (bool success) { } // ------------------------------------------------------------------------ // Returns the amount of tokens approved by the owner that can be // transferred to the spender's account // ------------------------------------------------------------------------ function allowance(address tokenOwner, address spender) public constant returns (uint remaining) { } // ------------------------------------------------------------------------ // Token owner can approve for spender to transferFrom(...) tokens // from the token owner's account. The spender contract function // receiveApproval(...) is then executed // ------------------------------------------------------------------------ function approveAndCall(address spender, uint tokens, bytes data) public returns (bool success) { } // ------------------------------------------------------------------------ // Freeze Tokens // ------------------------------------------------------------------------ function freeze(address user, uint amount, uint period) public onlyOwner { } // ------------------------------------------------------------------------ // UnFreeze Tokens // ------------------------------------------------------------------------ function unFreeze() public { } function ifFreeze(address user) public view returns ( bool check, uint amount, uint timeLeft ) { } function _mine(uint _amount) internal { } // ------------------------------------------------------------------------ // Owner can transfer out any accidentally sent ERC20 tokens // ------------------------------------------------------------------------ function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) { } } contract AnnoConsensus is AnnoToken { event MembershipUpdate(address indexed member, uint indexed level); event MembershipCancel(address indexed member); event AnnoTradeCreated(uint indexed tradeId, bool indexed ifMedal, uint medal, uint token); event TradeCancel(uint indexed tradeId); event TradeComplete(uint indexed tradeId, address indexed buyer, address indexed seller, uint medal, uint token); event Mine(address indexed miner, uint indexed salary); mapping (address => uint) MemberToLevel; mapping (address => uint) MemberToMedal; mapping (address => uint) MemberToToken; mapping (address => uint) MemberToTime; uint public period = 14 days; uint[5] public boardMember =[ 0, 500, 2500, 25000, 50000 ]; uint[5] public salary = [ 0, 1151000000000000000000, 5753000000000000000000, 57534000000000000000000, 115068000000000000000000 ]; struct AnnoTrade { address seller; bool ifMedal; uint medal; uint token; } AnnoTrade[] annoTrades; function boardMemberApply(uint _level) public { } function getBoardMember(address _member) public view returns (uint) { } function boardMemberCancel() public { } function createAnnoTrade(bool _ifMedal, uint _medal, uint _token) public returns (uint) { } function cancelTrade(uint _tradeId) public { } function trade(uint _tradeId) public { } function mine() public { uint level = MemberToLevel[msg.sender]; require(<FILL_ME>) require(minePool >= salary[level]); require(level > 0); _mine(salary[level]); minePool = safeSub(minePool, salary[level]); MemberToTime[msg.sender] = safeAdd(MemberToTime[msg.sender], period); Mine(msg.sender, salary[level]); } function setSalary(uint one, uint two, uint three, uint four) public onlyOwner { } function getTrade(uint _tradeId) public view returns ( address seller, bool ifMedal, uint medal, uint token ) { } }
MemberToTime[msg.sender]<uint(now)
299,048
MemberToTime[msg.sender]<uint(now)
"token not dead"
// SPDX-License-Identifier: MIT /* β–ˆβ–ˆβ–ˆβ–„β–„β–„β–„ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ β–„β–„β–„β–„β–ˆβ–ˆβ–ˆβ–„β–„β–„β–„ β–„β–ˆ β–ˆβ–ˆβ–ˆβ–„β–„β–„β–„ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–€β–€β–€β–ˆβ–ˆβ–„ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–€β–€β–€β–ˆβ–ˆβ–ˆβ–€β–€β–€β–ˆβ–ˆβ–„ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–€β–€β–€β–ˆβ–ˆβ–„ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–„ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–Œ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–€β–ˆβ–ˆβ–ˆβ–€β–€β–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–ˆβ–„β–„β–„ β–ˆβ–ˆβ–ˆ β–„β–ˆβ–ˆβ–ˆβ–„β–„β–„β–„β–ˆβ–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–Œ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–€β–€β–ˆβ–ˆβ–ˆβ–€β–€β–€ β–ˆβ–ˆβ–ˆ β–€β–€β–ˆβ–ˆβ–ˆβ–€β–€β–€β–€β–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–Œ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–„ β–ˆβ–ˆβ–ˆ β–ˆβ–„ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–€β–ˆ β–ˆβ–€ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ β–€β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–€ β–€β–ˆ β–ˆβ–ˆβ–ˆ β–ˆβ–€ β–ˆβ–€ β–€β–ˆ β–ˆβ–€ β–„β–ˆβ–ˆβ–ˆβ–ˆβ–€ β–ˆβ–ˆβ–ˆ β–ˆβ–ˆβ–ˆ inspired by dom.eth */ pragma solidity ^0.8.2; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; contract Necromint is ERC721 { // * CONSTANTS * // uint256 private constant _MAX_RESURRECTIONS = 6669; // * MODELS * // struct ResurrectedToken { address contractAddress; uint256 tokenId; } // * STORAGE * // uint256 private _tokenIdCounter; mapping(uint256 => ResurrectedToken) private _originalTokens; constructor() ERC721("Necromint", "dEaD") {} // * MINT * // function mint(address contractAddress, uint256 tokenId) public { require(contractAddress != address(0), "address cannot be zero"); require(<FILL_ME>) require( _tokenIdCounter < _MAX_RESURRECTIONS, "max resurrections reached" ); _originalTokens[_tokenIdCounter] = ResurrectedToken( contractAddress, tokenId ); _safeMint(msg.sender, _tokenIdCounter); _tokenIdCounter++; } // * TOKEN URI OVERRIDE * // function tokenURI(uint256 tokenId) public view override returns (string memory) { } }
ERC721(contractAddress).ownerOf(tokenId)==address(0x000000000000000000000000000000000000dEaD),"token not dead"
299,063
ERC721(contractAddress).ownerOf(tokenId)==address(0x000000000000000000000000000000000000dEaD)
"Illegal router address"
pragma solidity ^0.5.10; /** * @dev Interface of the ERC20 standard as defined in the EIP. Does not include * the optional functions; to access them see `ERC20Detailed`. */ interface IERC20 { /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through `transferFrom`. This is * zero by default. * * This value changes when `approve` or `transferFrom` are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * > 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 * * Emits an `Approval` event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); } /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the integer division of two unsigned integers. Reverts on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * This test is non-exhaustive, and there may be false-negatives: during the * execution of a contract's constructor, its address will be reported as * not containing a contract. * * > It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. */ function isContract(address account) internal view returns (bool) { } } /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ 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 { } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function callOptionalReturn(IERC20 token, bytes memory data) private { } } contract IWETH is IERC20 { function balanceOf(address account) external view returns (uint256); function deposit() external payable; function transfer(address to, uint value) external returns (bool); function withdraw(uint) external; } library UniswapV2Library { using SafeMath for uint; // returns sorted token addresses, used to handle return values from pairs sorted in this order function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) { } // calculates the CREATE2 address for a pair without making any external calls function pairFor(address factory, address tokenA, address tokenB, bytes memory initCode) internal pure returns (address pair) { } // fetches and sorts the reserves for a pair function getReserves(address factory, address tokenA, address tokenB, bytes memory initCode) internal view returns (uint reserveA, uint reserveB) { } // given an input amount of an asset and pair reserves, returns the maximum output amount of the other asset function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut, uint fee) internal pure returns (uint amountOut) { } // given an output amount of an asset and pair reserves, returns a required input amount of the other asset function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut, uint fee) internal pure returns (uint amountIn) { } // performs chained getAmountOut calculations on any number of pairs function getAmountsOut(address factory, uint amountIn, address[] memory path, bytes memory initCode, uint fee) internal view returns (uint[] memory amounts) { } // performs chained getAmountIn calculations on any number of pairs function getAmountsIn(address factory, uint amountOut, address[] memory path, bytes memory initCode, uint fee) internal view returns (uint[] memory amounts) { } } interface IUniswapV2Pair { function token0() external view returns (address); function token1() external view returns (address); function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast); function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external; } interface IMdexSwapMining { function takerWithdraw() external; } contract swapV1 { using SafeMath for uint256; using SafeERC20 for IERC20; event EVTCallExProxy (address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event EVTSwapExactTokensForTokens(address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event EVTSwapTokensForExactTokens(address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event SwapToolCreated(address indexed router); function safeTransfer(address token, address to, uint256 value) internal { } function safeTransferFrom(address token, address from, address to, uint value) internal { } //TODO uint256 feeFlag; address payable private feeAddr = 0xF18463BD447597a3b7c4035EA1E7BcDc5d99F330; address public constant WETH = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2; uint256 feeRate = 1; uint256 feePercent1000 = 1000; uint256 userFundsRate = feePercent1000 - feeRate; //TODO address private _owner; address emptyAddr = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE; mapping(address => bool) routerMap; mapping(address => bytes) factoryMap; mapping(address => uint256) factoryFeeMap; IWETH wethToken; constructor() public { } function pairFor(address factory, address tokenA, address tokenB, bytes memory initCode) public pure returns (address pair) { } modifier onlyOwner() { } modifier ensure(uint deadline) { } function addRouter(address router) public onlyOwner { } function isRouter(address router) public view returns (bool){ } function addFactory(address _factory, uint256 fee, bytes memory initCode) public onlyOwner { } function setFeeFlag(uint256 f) public onlyOwner { } function setFeeRate(uint256 fee) public onlyOwner { } function _needFee() internal view returns (bool){ } function callExProxy(address router, IERC20 inToken, IERC20 outToken, uint256 amountIn, uint256 amountOutMin, bytes memory data) public payable { require(router != address(this), "Illegal"); require(amountOutMin > 0, 'Limit Amount must be set'); require(<FILL_ME>) if (address(inToken) != emptyAddr) { require(msg.value == 0, "eth 0"); transferFromUser(inToken, msg.sender, amountIn); } approve(inToken, router); //swap (bool success,) = router.call.value(msg.value)(data); require(success, "call ex fail"); uint256 tradeReturn = viewBalance(outToken, address(this)); require(tradeReturn >= amountOutMin, 'Trade returned less than the minimum amount'); // return any unspent funds uint256 leftover = viewBalance(inToken, address(this)); if (leftover > 0) { sendFunds(inToken, msg.sender, leftover); } if (_needFee()) { sendFunds(outToken, msg.sender, tradeReturn.mul(userFundsRate).div(feePercent1000)); sendFunds(outToken, feeAddr, tradeReturn.mul(feeRate).div(feePercent1000)); } else { sendFunds(outToken, msg.sender, tradeReturn); } emit EVTCallExProxy(address(inToken), address(outToken), msg.sender, router, tradeReturn); } function swapExactTokensForTokens(address factory, IERC20 inToken, IERC20 outToken, uint256 amountIn, uint256 amountOutMin, uint deadline, address[] memory path) public payable ensure(deadline) { } function swapTokensForExactTokens(address factory, IERC20 inToken, IERC20 outToken, uint256 amountInMax, uint256 amountOut, uint deadline, address[] memory path) public payable ensure(deadline) { } function transferFromUser(IERC20 erc, address _from, uint256 _inAmount) internal { } function approve(IERC20 erc, address approvee) internal { } function viewBalance(IERC20 erc, address owner) internal view returns (uint256) { } function sendFunds(IERC20 erc, address payable receiver, uint256 funds) internal { } function _swap(address factory, uint[] memory amounts, address[] memory path, address _to, bytes memory initCode) internal { } function withdrawEth() external onlyOwner { } function withdrawAnyToken(IERC20 erc) external onlyOwner { } function() external payable { } }
isRouter(router),"Illegal router address"
299,070
isRouter(router)
"add factory before"
pragma solidity ^0.5.10; /** * @dev Interface of the ERC20 standard as defined in the EIP. Does not include * the optional functions; to access them see `ERC20Detailed`. */ interface IERC20 { /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through `transferFrom`. This is * zero by default. * * This value changes when `approve` or `transferFrom` are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * > 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 * * Emits an `Approval` event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a `Transfer` event. */ function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); } /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the integer division of two unsigned integers. Reverts on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { } } /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * This test is non-exhaustive, and there may be false-negatives: during the * execution of a contract's constructor, its address will be reported as * not containing a contract. * * > It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. */ function isContract(address account) internal view returns (bool) { } } /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ 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 { } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function callOptionalReturn(IERC20 token, bytes memory data) private { } } contract IWETH is IERC20 { function balanceOf(address account) external view returns (uint256); function deposit() external payable; function transfer(address to, uint value) external returns (bool); function withdraw(uint) external; } library UniswapV2Library { using SafeMath for uint; // returns sorted token addresses, used to handle return values from pairs sorted in this order function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) { } // calculates the CREATE2 address for a pair without making any external calls function pairFor(address factory, address tokenA, address tokenB, bytes memory initCode) internal pure returns (address pair) { } // fetches and sorts the reserves for a pair function getReserves(address factory, address tokenA, address tokenB, bytes memory initCode) internal view returns (uint reserveA, uint reserveB) { } // given an input amount of an asset and pair reserves, returns the maximum output amount of the other asset function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut, uint fee) internal pure returns (uint amountOut) { } // given an output amount of an asset and pair reserves, returns a required input amount of the other asset function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut, uint fee) internal pure returns (uint amountIn) { } // performs chained getAmountOut calculations on any number of pairs function getAmountsOut(address factory, uint amountIn, address[] memory path, bytes memory initCode, uint fee) internal view returns (uint[] memory amounts) { } // performs chained getAmountIn calculations on any number of pairs function getAmountsIn(address factory, uint amountOut, address[] memory path, bytes memory initCode, uint fee) internal view returns (uint[] memory amounts) { } } interface IUniswapV2Pair { function token0() external view returns (address); function token1() external view returns (address); function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast); function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external; } interface IMdexSwapMining { function takerWithdraw() external; } contract swapV1 { using SafeMath for uint256; using SafeERC20 for IERC20; event EVTCallExProxy (address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event EVTSwapExactTokensForTokens(address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event EVTSwapTokensForExactTokens(address indexed _in, address indexed _out, address indexed _trader, address _ex, uint256 _outAmount); event SwapToolCreated(address indexed router); function safeTransfer(address token, address to, uint256 value) internal { } function safeTransferFrom(address token, address from, address to, uint value) internal { } //TODO uint256 feeFlag; address payable private feeAddr = 0xF18463BD447597a3b7c4035EA1E7BcDc5d99F330; address public constant WETH = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2; uint256 feeRate = 1; uint256 feePercent1000 = 1000; uint256 userFundsRate = feePercent1000 - feeRate; //TODO address private _owner; address emptyAddr = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE; mapping(address => bool) routerMap; mapping(address => bytes) factoryMap; mapping(address => uint256) factoryFeeMap; IWETH wethToken; constructor() public { } function pairFor(address factory, address tokenA, address tokenB, bytes memory initCode) public pure returns (address pair) { } modifier onlyOwner() { } modifier ensure(uint deadline) { } function addRouter(address router) public onlyOwner { } function isRouter(address router) public view returns (bool){ } function addFactory(address _factory, uint256 fee, bytes memory initCode) public onlyOwner { } function setFeeFlag(uint256 f) public onlyOwner { } function setFeeRate(uint256 fee) public onlyOwner { } function _needFee() internal view returns (bool){ } function callExProxy(address router, IERC20 inToken, IERC20 outToken, uint256 amountIn, uint256 amountOutMin, bytes memory data) public payable { } function swapExactTokensForTokens(address factory, IERC20 inToken, IERC20 outToken, uint256 amountIn, uint256 amountOutMin, uint deadline, address[] memory path) public payable ensure(deadline) { require(factory != address(this), "Illegal"); require(amountOutMin > 0, 'Limit Amount must be set'); require(<FILL_ME>) bytes memory initCode = factoryMap[factory]; uint[] memory amounts = new uint[](path.length); { uint fee = factoryFeeMap[factory]; amounts = UniswapV2Library.getAmountsOut(factory, amountIn, path, initCode, fee); } require(amounts[amounts.length - 1] >= amountOutMin, 'UniswapV2Router: INSUFFICIENT_OUTPUT_AMOUNT'); address firstPair = UniswapV2Library.pairFor(factory, path[0], path[1], initCode); if (address(inToken) != emptyAddr) { require(msg.value == 0, "eth 0"); safeTransferFrom(address(inToken), msg.sender, firstPair, amountIn); } else { inToken = IERC20(WETH); wethToken.deposit.value(msg.value)(); inToken.safeTransfer(firstPair, msg.value); } if (_needFee()) { { _swap(factory, amounts, path, address(this), initCode); } if (address(outToken) == emptyAddr) { wethToken.withdraw(wethToken.balanceOf(address(this))); } uint256 tradeReturn = viewBalance(outToken, address(this)); require(tradeReturn >= amountOutMin, 'Trade returned less than the minimum amount'); uint256 leftover = viewBalance(inToken, address(this)); if (leftover > 0) { sendFunds(inToken, msg.sender, leftover); } sendFunds(outToken, msg.sender, tradeReturn.mul(userFundsRate).div(feePercent1000)); sendFunds(outToken, feeAddr, tradeReturn.mul(feeRate).div(feePercent1000)); } else { if (address(outToken) == emptyAddr) { _swap(factory, amounts, path, address(this), initCode); uint256 tradeReturn = wethToken.balanceOf(address(this)); wethToken.withdraw(tradeReturn); sendFunds(outToken, msg.sender, tradeReturn); } else { _swap(factory, amounts, path, msg.sender, initCode); } } emit EVTSwapExactTokensForTokens(address(inToken), address(outToken), msg.sender, factory, amounts[amounts.length - 1]); } function swapTokensForExactTokens(address factory, IERC20 inToken, IERC20 outToken, uint256 amountInMax, uint256 amountOut, uint deadline, address[] memory path) public payable ensure(deadline) { } function transferFromUser(IERC20 erc, address _from, uint256 _inAmount) internal { } function approve(IERC20 erc, address approvee) internal { } function viewBalance(IERC20 erc, address owner) internal view returns (uint256) { } function sendFunds(IERC20 erc, address payable receiver, uint256 funds) internal { } function _swap(address factory, uint[] memory amounts, address[] memory path, address _to, bytes memory initCode) internal { } function withdrawEth() external onlyOwner { } function withdrawAnyToken(IERC20 erc) external onlyOwner { } function() external payable { } }
factoryMap[factory].length>0,"add factory before"
299,070
factoryMap[factory].length>0
null
/*! depo.sol | (c) 2018 Develop by BelovITLab LLC (smartcontract.ru), author @stupidlovejoy | License: MIT */ pragma solidity 0.4.24; library SafeMath { function mul(uint256 a, uint256 b) internal pure returns(uint256 c) { } 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 c) { } } contract Ownable { address public owner; event OwnershipRenounced(address indexed previousOwner); event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); modifier onlyOwner() { } constructor() public { } function _transferOwnership(address _newOwner) internal { } function renounceOwnership() public onlyOwner { } function transferOwnership(address _newOwner) public onlyOwner { } } contract ERC20 { event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); function totalSupply() public view returns(uint256); function balanceOf(address who) public view returns(uint256); function transfer(address to, uint256 value) public returns(bool); function transferFrom(address from, address to, uint256 value) public returns(bool); function allowance(address owner, address spender) public view returns(uint256); function approve(address spender, uint256 value) public returns(bool); } contract StandardToken is ERC20 { using SafeMath for uint256; uint256 totalSupply_; string public name; string public symbol; uint8 public decimals; mapping(address => uint256) balances; mapping(address => mapping(address => uint256)) internal allowed; constructor(string _name, string _symbol, uint8 _decimals) public { } function totalSupply() public view returns(uint256) { } function balanceOf(address _owner) public view returns(uint256) { } function transfer(address _to, uint256 _value) public returns(bool) { } function multiTransfer(address[] _to, uint256[] _value) public returns(bool) { } function transferFrom(address _from, address _to, uint256 _value) public returns(bool) { } function allowance(address _owner, address _spender) public view returns(uint256) { } function approve(address _spender, uint256 _value) public returns(bool) { } function increaseApproval(address _spender, uint _addedValue) public returns(bool) { } function decreaseApproval(address _spender, uint _subtractedValue) public returns(bool) { } } contract MintableToken is StandardToken, Ownable { bool public mintingFinished = false; event Mint(address indexed to, uint256 amount); event MintFinished(); modifier canMint() { } modifier hasMintPermission() { } function mint(address _to, uint256 _amount) hasMintPermission canMint public returns(bool) { } function finishMinting() onlyOwner canMint public returns(bool) { } } contract CappedToken is MintableToken { uint256 public cap; constructor(uint256 _cap) public { } function mint(address _to, uint256 _amount) public returns(bool) { } } contract BurnableToken is StandardToken { event Burn(address indexed burner, uint256 value); function _burn(address _who, uint256 _value) internal { } function burn(uint256 _value) public { } function burnFrom(address _from, uint256 _value) public { } } contract Withdrawable is Ownable { function withdrawEther(address _to, uint _value) onlyOwner public { } function withdrawTokensTransfer(ERC20 _token, address _to, uint256 _value) onlyOwner public { } function withdrawTokensTransferFrom(ERC20 _token, address _from, address _to, uint256 _value) onlyOwner public { } function withdrawTokensApprove(ERC20 _token, address _spender, uint256 _value) onlyOwner public { } } contract Pausable is Ownable { bool public paused = false; event Pause(); event Unpause(); modifier whenNotPaused() { } modifier whenPaused() { } function pause() onlyOwner whenNotPaused public { } function unpause() onlyOwner whenPaused public { } } contract Manageable is Ownable { address[] public managers; event ManagerAdded(address indexed manager); event ManagerRemoved(address indexed manager); modifier onlyManager() { } function countManagers() view public returns(uint) { } function getManagers() view public returns(address[]) { } function isManager(address _manager) view public returns(bool) { } function addManager(address _manager) onlyOwner public { } function removeManager(address _manager) onlyOwner public { require(<FILL_ME>) uint index = 0; for(uint i = 0; i < managers.length; i++) { if(managers[i] == _manager) { index = i; } } for(; index < managers.length - 1; index++) { managers[index] = managers[index + 1]; } managers.length--; emit ManagerRemoved(_manager); } } contract Token is CappedToken, BurnableToken, Withdrawable { constructor() CappedToken(1000000 * 1e8) StandardToken("DEPO", "DEPO", 8) public { } } contract Crowdsale is Manageable, Withdrawable, Pausable { using SafeMath for uint; Token public token; bool public crowdsaleClosed = false; event ExternalPurchase(address indexed holder, string tx, string currency, uint256 currencyAmount, uint256 rateToEther, uint256 tokenAmount); event CrowdsaleClose(); constructor() public { } function externalPurchase(address _to, string _tx, string _currency, uint _value, uint256 _rate, uint256 _tokens) whenNotPaused onlyManager public { } function closeCrowdsale(address _to) onlyOwner public { } }
isManager(_manager)
299,078
isManager(_manager)
null
pragma solidity ^0.4.18; contract owned { address public owner; function owned() { } modifier onlyOwner { } function transferOwnership(address newOwner) onlyOwner { } } library TiposCompartidos { enum TipoPremio {none,free,x2,x3,x5, surprise } struct Celda { address creador; uint polenPositivos; uint polenNegativos; uint256 fechaCreacion; uint primeraPosicion; uint segundaPosicion; uint terceraPosicion; uint cuartaPosicion; uint quintaPosicion; uint sextaPosicion; TipoPremio tipo; bool premio; } } contract BeeGame is owned { uint256 internal sellPrice; uint256 internal buyPrice; uint internal numeroCeldas; string internal name; string internal symbol; uint8 internal decimals; uint internal numeroUsuarios; uint fechaTax; mapping (address => uint) balanceOf; address[] indiceUsuarios; mapping (uint256 => TiposCompartidos.Celda) celdas; uint256[] indiceCeldas; event Transfer(address indexed from, address indexed to, uint256 value); event TransferKO(address indexed from, address indexed to, uint256 value); function BeeGame ( uint256 initialSupply, uint256 newSellPrice, uint256 newBuyPrice, uint _fechaTax) { } function buy() payable returns (uint amount) { amount = msg.value / buyPrice; require(<FILL_ME>) _transfer(owner, msg.sender, amount); incluirUsuario(msg.sender); Transfer(owner, msg.sender, amount); return amount; } function incluirUsuario(address usuario){ } function cobrarImpuesto(uint _fechaTax) onlyOwner { } function crearCelda(uint _polenes, uint256 _fechaCreacion, uint posicion, uint _celdaPadre, uint _celdaAbuelo, TiposCompartidos.TipoPremio tipo) { } function getCelda(uint index) returns (address creador, uint polenPositivos, uint polenNegativos, uint fechaCreacion, uint primeraPosicion, uint segundaPosicion, uint terceraPosicion, uint cuartaPosicion, uint quintaPosicion, uint sextaPosicion, TiposCompartidos.TipoPremio tipo, bool premio) { } function getBalance(address addr) returns(uint) { } function getFechaTax() returns(uint) { } function getNumeroCeldas() returns(uint) { } function getOwner() returns(address) { } function getRevenue(uint amount) onlyOwner { } function sell(uint amount){ } function setFechaTax(uint _fechaTax) onlyOwner { } function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner { } function transfer(address _to, uint _value){ } function _transfer(address _from, address _to, uint _value) internal { } }
balanceOf[owner]>=amount
299,111
balanceOf[owner]>=amount
null
pragma solidity ^0.4.18; contract owned { address public owner; function owned() { } modifier onlyOwner { } function transferOwnership(address newOwner) onlyOwner { } } library TiposCompartidos { enum TipoPremio {none,free,x2,x3,x5, surprise } struct Celda { address creador; uint polenPositivos; uint polenNegativos; uint256 fechaCreacion; uint primeraPosicion; uint segundaPosicion; uint terceraPosicion; uint cuartaPosicion; uint quintaPosicion; uint sextaPosicion; TipoPremio tipo; bool premio; } } contract BeeGame is owned { uint256 internal sellPrice; uint256 internal buyPrice; uint internal numeroCeldas; string internal name; string internal symbol; uint8 internal decimals; uint internal numeroUsuarios; uint fechaTax; mapping (address => uint) balanceOf; address[] indiceUsuarios; mapping (uint256 => TiposCompartidos.Celda) celdas; uint256[] indiceCeldas; event Transfer(address indexed from, address indexed to, uint256 value); event TransferKO(address indexed from, address indexed to, uint256 value); function BeeGame ( uint256 initialSupply, uint256 newSellPrice, uint256 newBuyPrice, uint _fechaTax) { } function buy() payable returns (uint amount) { } function incluirUsuario(address usuario){ } function cobrarImpuesto(uint _fechaTax) onlyOwner { } function crearCelda(uint _polenes, uint256 _fechaCreacion, uint posicion, uint _celdaPadre, uint _celdaAbuelo, TiposCompartidos.TipoPremio tipo) { require(<FILL_ME>) require(_polenes == 3); require(_celdaPadre != 0); require((posicion >= 0 && posicion < 7) || (posicion == 0 && msg.sender == owner)); require(((tipo == TiposCompartidos.TipoPremio.free || tipo == TiposCompartidos.TipoPremio.x2 || tipo == TiposCompartidos.TipoPremio.x3 || tipo == TiposCompartidos.TipoPremio.x5 || tipo == TiposCompartidos.TipoPremio.surprise) && msg.sender == owner) || tipo == TiposCompartidos.TipoPremio.none); TiposCompartidos.Celda memory celdaPadre = celdas[_celdaPadre]; require( ((posicion == 1 && celdaPadre.primeraPosicion == 0) || celdas[celdaPadre.primeraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 2 && celdaPadre.segundaPosicion == 0) || celdas[celdaPadre.segundaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 3 && celdaPadre.terceraPosicion == 0) || celdas[celdaPadre.terceraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 4 && celdaPadre.cuartaPosicion == 0) || celdas[celdaPadre.cuartaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 5 && celdaPadre.quintaPosicion == 0) || celdas[celdaPadre.quintaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 6 && celdaPadre.sextaPosicion == 0) || celdas[celdaPadre.sextaPosicion].tipo != TiposCompartidos.TipoPremio.none ) ); TiposCompartidos.Celda memory celda; TiposCompartidos.TipoPremio tipoPremio; if (celdas[_fechaCreacion].fechaCreacion == _fechaCreacion) { celda = celdas[_fechaCreacion]; celda.creador = msg.sender; celda.premio = false; tipoPremio = celda.tipo; celda.tipo = TiposCompartidos.TipoPremio.none; } else { if (msg.sender != owner) { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:false }); }else { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:true }); } indiceCeldas.push(_fechaCreacion); numeroCeldas = numeroCeldas + 1; } celdas[_fechaCreacion] = celda; TiposCompartidos.Celda memory celdaAbuelo = celdas[_celdaAbuelo]; uint multiplicador = 1; address repartidor = msg.sender; if (tipoPremio == TiposCompartidos.TipoPremio.x2 && !celda.premio) { multiplicador = 2; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x3 && !celda.premio) { multiplicador = 3; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x5 && !celda.premio) { multiplicador = 5; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.free && !celda.premio) { repartidor = owner; } if (posicion == 1 && celdaPadre.primeraPosicion == 0) { celdaPadre.primeraPosicion = _fechaCreacion; }else if (posicion == 2 && celdaPadre.segundaPosicion == 0 ) { celdaPadre.segundaPosicion = _fechaCreacion; }else if (posicion == 3 && celdaPadre.terceraPosicion == 0) { celdaPadre.terceraPosicion = _fechaCreacion; }else if (posicion == 4 && celdaPadre.cuartaPosicion == 0) { celdaPadre.cuartaPosicion = _fechaCreacion; }else if (posicion == 5 && celdaPadre.quintaPosicion == 0) { celdaPadre.quintaPosicion = _fechaCreacion; }else if (posicion == 6 && celdaPadre.sextaPosicion == 0) { celdaPadre.sextaPosicion = _fechaCreacion; } if (_celdaAbuelo != 0 && !celda.premio) { _transfer(repartidor,celdaPadre.creador,2 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + (2 * multiplicador); celdaAbuelo.polenPositivos = celdaAbuelo.polenPositivos + (1 * multiplicador); _transfer(repartidor,celdaAbuelo.creador,1 * multiplicador); celdas[celdaAbuelo.fechaCreacion] = celdaAbuelo; }else if (!celda.premio) { _transfer(repartidor,celdaPadre.creador,3 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + ( 3 * multiplicador); } celdas[celdaPadre.fechaCreacion] = celdaPadre; } function getCelda(uint index) returns (address creador, uint polenPositivos, uint polenNegativos, uint fechaCreacion, uint primeraPosicion, uint segundaPosicion, uint terceraPosicion, uint cuartaPosicion, uint quintaPosicion, uint sextaPosicion, TiposCompartidos.TipoPremio tipo, bool premio) { } function getBalance(address addr) returns(uint) { } function getFechaTax() returns(uint) { } function getNumeroCeldas() returns(uint) { } function getOwner() returns(address) { } function getRevenue(uint amount) onlyOwner { } function sell(uint amount){ } function setFechaTax(uint _fechaTax) onlyOwner { } function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner { } function transfer(address _to, uint _value){ } function _transfer(address _from, address _to, uint _value) internal { } }
balanceOf[msg.sender]>=3
299,111
balanceOf[msg.sender]>=3
null
pragma solidity ^0.4.18; contract owned { address public owner; function owned() { } modifier onlyOwner { } function transferOwnership(address newOwner) onlyOwner { } } library TiposCompartidos { enum TipoPremio {none,free,x2,x3,x5, surprise } struct Celda { address creador; uint polenPositivos; uint polenNegativos; uint256 fechaCreacion; uint primeraPosicion; uint segundaPosicion; uint terceraPosicion; uint cuartaPosicion; uint quintaPosicion; uint sextaPosicion; TipoPremio tipo; bool premio; } } contract BeeGame is owned { uint256 internal sellPrice; uint256 internal buyPrice; uint internal numeroCeldas; string internal name; string internal symbol; uint8 internal decimals; uint internal numeroUsuarios; uint fechaTax; mapping (address => uint) balanceOf; address[] indiceUsuarios; mapping (uint256 => TiposCompartidos.Celda) celdas; uint256[] indiceCeldas; event Transfer(address indexed from, address indexed to, uint256 value); event TransferKO(address indexed from, address indexed to, uint256 value); function BeeGame ( uint256 initialSupply, uint256 newSellPrice, uint256 newBuyPrice, uint _fechaTax) { } function buy() payable returns (uint amount) { } function incluirUsuario(address usuario){ } function cobrarImpuesto(uint _fechaTax) onlyOwner { } function crearCelda(uint _polenes, uint256 _fechaCreacion, uint posicion, uint _celdaPadre, uint _celdaAbuelo, TiposCompartidos.TipoPremio tipo) { require(balanceOf[msg.sender]>=3); require(_polenes == 3); require(_celdaPadre != 0); require(<FILL_ME>) require(((tipo == TiposCompartidos.TipoPremio.free || tipo == TiposCompartidos.TipoPremio.x2 || tipo == TiposCompartidos.TipoPremio.x3 || tipo == TiposCompartidos.TipoPremio.x5 || tipo == TiposCompartidos.TipoPremio.surprise) && msg.sender == owner) || tipo == TiposCompartidos.TipoPremio.none); TiposCompartidos.Celda memory celdaPadre = celdas[_celdaPadre]; require( ((posicion == 1 && celdaPadre.primeraPosicion == 0) || celdas[celdaPadre.primeraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 2 && celdaPadre.segundaPosicion == 0) || celdas[celdaPadre.segundaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 3 && celdaPadre.terceraPosicion == 0) || celdas[celdaPadre.terceraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 4 && celdaPadre.cuartaPosicion == 0) || celdas[celdaPadre.cuartaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 5 && celdaPadre.quintaPosicion == 0) || celdas[celdaPadre.quintaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 6 && celdaPadre.sextaPosicion == 0) || celdas[celdaPadre.sextaPosicion].tipo != TiposCompartidos.TipoPremio.none ) ); TiposCompartidos.Celda memory celda; TiposCompartidos.TipoPremio tipoPremio; if (celdas[_fechaCreacion].fechaCreacion == _fechaCreacion) { celda = celdas[_fechaCreacion]; celda.creador = msg.sender; celda.premio = false; tipoPremio = celda.tipo; celda.tipo = TiposCompartidos.TipoPremio.none; } else { if (msg.sender != owner) { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:false }); }else { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:true }); } indiceCeldas.push(_fechaCreacion); numeroCeldas = numeroCeldas + 1; } celdas[_fechaCreacion] = celda; TiposCompartidos.Celda memory celdaAbuelo = celdas[_celdaAbuelo]; uint multiplicador = 1; address repartidor = msg.sender; if (tipoPremio == TiposCompartidos.TipoPremio.x2 && !celda.premio) { multiplicador = 2; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x3 && !celda.premio) { multiplicador = 3; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x5 && !celda.premio) { multiplicador = 5; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.free && !celda.premio) { repartidor = owner; } if (posicion == 1 && celdaPadre.primeraPosicion == 0) { celdaPadre.primeraPosicion = _fechaCreacion; }else if (posicion == 2 && celdaPadre.segundaPosicion == 0 ) { celdaPadre.segundaPosicion = _fechaCreacion; }else if (posicion == 3 && celdaPadre.terceraPosicion == 0) { celdaPadre.terceraPosicion = _fechaCreacion; }else if (posicion == 4 && celdaPadre.cuartaPosicion == 0) { celdaPadre.cuartaPosicion = _fechaCreacion; }else if (posicion == 5 && celdaPadre.quintaPosicion == 0) { celdaPadre.quintaPosicion = _fechaCreacion; }else if (posicion == 6 && celdaPadre.sextaPosicion == 0) { celdaPadre.sextaPosicion = _fechaCreacion; } if (_celdaAbuelo != 0 && !celda.premio) { _transfer(repartidor,celdaPadre.creador,2 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + (2 * multiplicador); celdaAbuelo.polenPositivos = celdaAbuelo.polenPositivos + (1 * multiplicador); _transfer(repartidor,celdaAbuelo.creador,1 * multiplicador); celdas[celdaAbuelo.fechaCreacion] = celdaAbuelo; }else if (!celda.premio) { _transfer(repartidor,celdaPadre.creador,3 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + ( 3 * multiplicador); } celdas[celdaPadre.fechaCreacion] = celdaPadre; } function getCelda(uint index) returns (address creador, uint polenPositivos, uint polenNegativos, uint fechaCreacion, uint primeraPosicion, uint segundaPosicion, uint terceraPosicion, uint cuartaPosicion, uint quintaPosicion, uint sextaPosicion, TiposCompartidos.TipoPremio tipo, bool premio) { } function getBalance(address addr) returns(uint) { } function getFechaTax() returns(uint) { } function getNumeroCeldas() returns(uint) { } function getOwner() returns(address) { } function getRevenue(uint amount) onlyOwner { } function sell(uint amount){ } function setFechaTax(uint _fechaTax) onlyOwner { } function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner { } function transfer(address _to, uint _value){ } function _transfer(address _from, address _to, uint _value) internal { } }
(posicion>=0&&posicion<7)||(posicion==0&&msg.sender==owner)
299,111
(posicion>=0&&posicion<7)||(posicion==0&&msg.sender==owner)
null
pragma solidity ^0.4.18; contract owned { address public owner; function owned() { } modifier onlyOwner { } function transferOwnership(address newOwner) onlyOwner { } } library TiposCompartidos { enum TipoPremio {none,free,x2,x3,x5, surprise } struct Celda { address creador; uint polenPositivos; uint polenNegativos; uint256 fechaCreacion; uint primeraPosicion; uint segundaPosicion; uint terceraPosicion; uint cuartaPosicion; uint quintaPosicion; uint sextaPosicion; TipoPremio tipo; bool premio; } } contract BeeGame is owned { uint256 internal sellPrice; uint256 internal buyPrice; uint internal numeroCeldas; string internal name; string internal symbol; uint8 internal decimals; uint internal numeroUsuarios; uint fechaTax; mapping (address => uint) balanceOf; address[] indiceUsuarios; mapping (uint256 => TiposCompartidos.Celda) celdas; uint256[] indiceCeldas; event Transfer(address indexed from, address indexed to, uint256 value); event TransferKO(address indexed from, address indexed to, uint256 value); function BeeGame ( uint256 initialSupply, uint256 newSellPrice, uint256 newBuyPrice, uint _fechaTax) { } function buy() payable returns (uint amount) { } function incluirUsuario(address usuario){ } function cobrarImpuesto(uint _fechaTax) onlyOwner { } function crearCelda(uint _polenes, uint256 _fechaCreacion, uint posicion, uint _celdaPadre, uint _celdaAbuelo, TiposCompartidos.TipoPremio tipo) { require(balanceOf[msg.sender]>=3); require(_polenes == 3); require(_celdaPadre != 0); require((posicion >= 0 && posicion < 7) || (posicion == 0 && msg.sender == owner)); require(<FILL_ME>) TiposCompartidos.Celda memory celdaPadre = celdas[_celdaPadre]; require( ((posicion == 1 && celdaPadre.primeraPosicion == 0) || celdas[celdaPadre.primeraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 2 && celdaPadre.segundaPosicion == 0) || celdas[celdaPadre.segundaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 3 && celdaPadre.terceraPosicion == 0) || celdas[celdaPadre.terceraPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 4 && celdaPadre.cuartaPosicion == 0) || celdas[celdaPadre.cuartaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 5 && celdaPadre.quintaPosicion == 0) || celdas[celdaPadre.quintaPosicion].tipo != TiposCompartidos.TipoPremio.none ) || ((posicion == 6 && celdaPadre.sextaPosicion == 0) || celdas[celdaPadre.sextaPosicion].tipo != TiposCompartidos.TipoPremio.none ) ); TiposCompartidos.Celda memory celda; TiposCompartidos.TipoPremio tipoPremio; if (celdas[_fechaCreacion].fechaCreacion == _fechaCreacion) { celda = celdas[_fechaCreacion]; celda.creador = msg.sender; celda.premio = false; tipoPremio = celda.tipo; celda.tipo = TiposCompartidos.TipoPremio.none; } else { if (msg.sender != owner) { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:false }); }else { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:true }); } indiceCeldas.push(_fechaCreacion); numeroCeldas = numeroCeldas + 1; } celdas[_fechaCreacion] = celda; TiposCompartidos.Celda memory celdaAbuelo = celdas[_celdaAbuelo]; uint multiplicador = 1; address repartidor = msg.sender; if (tipoPremio == TiposCompartidos.TipoPremio.x2 && !celda.premio) { multiplicador = 2; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x3 && !celda.premio) { multiplicador = 3; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x5 && !celda.premio) { multiplicador = 5; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.free && !celda.premio) { repartidor = owner; } if (posicion == 1 && celdaPadre.primeraPosicion == 0) { celdaPadre.primeraPosicion = _fechaCreacion; }else if (posicion == 2 && celdaPadre.segundaPosicion == 0 ) { celdaPadre.segundaPosicion = _fechaCreacion; }else if (posicion == 3 && celdaPadre.terceraPosicion == 0) { celdaPadre.terceraPosicion = _fechaCreacion; }else if (posicion == 4 && celdaPadre.cuartaPosicion == 0) { celdaPadre.cuartaPosicion = _fechaCreacion; }else if (posicion == 5 && celdaPadre.quintaPosicion == 0) { celdaPadre.quintaPosicion = _fechaCreacion; }else if (posicion == 6 && celdaPadre.sextaPosicion == 0) { celdaPadre.sextaPosicion = _fechaCreacion; } if (_celdaAbuelo != 0 && !celda.premio) { _transfer(repartidor,celdaPadre.creador,2 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + (2 * multiplicador); celdaAbuelo.polenPositivos = celdaAbuelo.polenPositivos + (1 * multiplicador); _transfer(repartidor,celdaAbuelo.creador,1 * multiplicador); celdas[celdaAbuelo.fechaCreacion] = celdaAbuelo; }else if (!celda.premio) { _transfer(repartidor,celdaPadre.creador,3 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + ( 3 * multiplicador); } celdas[celdaPadre.fechaCreacion] = celdaPadre; } function getCelda(uint index) returns (address creador, uint polenPositivos, uint polenNegativos, uint fechaCreacion, uint primeraPosicion, uint segundaPosicion, uint terceraPosicion, uint cuartaPosicion, uint quintaPosicion, uint sextaPosicion, TiposCompartidos.TipoPremio tipo, bool premio) { } function getBalance(address addr) returns(uint) { } function getFechaTax() returns(uint) { } function getNumeroCeldas() returns(uint) { } function getOwner() returns(address) { } function getRevenue(uint amount) onlyOwner { } function sell(uint amount){ } function setFechaTax(uint _fechaTax) onlyOwner { } function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner { } function transfer(address _to, uint _value){ } function _transfer(address _from, address _to, uint _value) internal { } }
((tipo==TiposCompartidos.TipoPremio.free||tipo==TiposCompartidos.TipoPremio.x2||tipo==TiposCompartidos.TipoPremio.x3||tipo==TiposCompartidos.TipoPremio.x5||tipo==TiposCompartidos.TipoPremio.surprise)&&msg.sender==owner)||tipo==TiposCompartidos.TipoPremio.none
299,111
((tipo==TiposCompartidos.TipoPremio.free||tipo==TiposCompartidos.TipoPremio.x2||tipo==TiposCompartidos.TipoPremio.x3||tipo==TiposCompartidos.TipoPremio.x5||tipo==TiposCompartidos.TipoPremio.surprise)&&msg.sender==owner)||tipo==TiposCompartidos.TipoPremio.none
null
pragma solidity ^0.4.18; contract owned { address public owner; function owned() { } modifier onlyOwner { } function transferOwnership(address newOwner) onlyOwner { } } library TiposCompartidos { enum TipoPremio {none,free,x2,x3,x5, surprise } struct Celda { address creador; uint polenPositivos; uint polenNegativos; uint256 fechaCreacion; uint primeraPosicion; uint segundaPosicion; uint terceraPosicion; uint cuartaPosicion; uint quintaPosicion; uint sextaPosicion; TipoPremio tipo; bool premio; } } contract BeeGame is owned { uint256 internal sellPrice; uint256 internal buyPrice; uint internal numeroCeldas; string internal name; string internal symbol; uint8 internal decimals; uint internal numeroUsuarios; uint fechaTax; mapping (address => uint) balanceOf; address[] indiceUsuarios; mapping (uint256 => TiposCompartidos.Celda) celdas; uint256[] indiceCeldas; event Transfer(address indexed from, address indexed to, uint256 value); event TransferKO(address indexed from, address indexed to, uint256 value); function BeeGame ( uint256 initialSupply, uint256 newSellPrice, uint256 newBuyPrice, uint _fechaTax) { } function buy() payable returns (uint amount) { } function incluirUsuario(address usuario){ } function cobrarImpuesto(uint _fechaTax) onlyOwner { } function crearCelda(uint _polenes, uint256 _fechaCreacion, uint posicion, uint _celdaPadre, uint _celdaAbuelo, TiposCompartidos.TipoPremio tipo) { require(balanceOf[msg.sender]>=3); require(_polenes == 3); require(_celdaPadre != 0); require((posicion >= 0 && posicion < 7) || (posicion == 0 && msg.sender == owner)); require(((tipo == TiposCompartidos.TipoPremio.free || tipo == TiposCompartidos.TipoPremio.x2 || tipo == TiposCompartidos.TipoPremio.x3 || tipo == TiposCompartidos.TipoPremio.x5 || tipo == TiposCompartidos.TipoPremio.surprise) && msg.sender == owner) || tipo == TiposCompartidos.TipoPremio.none); TiposCompartidos.Celda memory celdaPadre = celdas[_celdaPadre]; require(<FILL_ME>) TiposCompartidos.Celda memory celda; TiposCompartidos.TipoPremio tipoPremio; if (celdas[_fechaCreacion].fechaCreacion == _fechaCreacion) { celda = celdas[_fechaCreacion]; celda.creador = msg.sender; celda.premio = false; tipoPremio = celda.tipo; celda.tipo = TiposCompartidos.TipoPremio.none; } else { if (msg.sender != owner) { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:false }); }else { celda = TiposCompartidos.Celda({ creador:msg.sender, polenPositivos : 0, polenNegativos : _polenes, fechaCreacion: _fechaCreacion, primeraPosicion : 0, segundaPosicion : 0, terceraPosicion : 0, cuartaPosicion : 0, quintaPosicion : 0, sextaPosicion : 0, tipo:tipo, premio:true }); } indiceCeldas.push(_fechaCreacion); numeroCeldas = numeroCeldas + 1; } celdas[_fechaCreacion] = celda; TiposCompartidos.Celda memory celdaAbuelo = celdas[_celdaAbuelo]; uint multiplicador = 1; address repartidor = msg.sender; if (tipoPremio == TiposCompartidos.TipoPremio.x2 && !celda.premio) { multiplicador = 2; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x3 && !celda.premio) { multiplicador = 3; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.x5 && !celda.premio) { multiplicador = 5; repartidor = owner; } else if (tipoPremio == TiposCompartidos.TipoPremio.free && !celda.premio) { repartidor = owner; } if (posicion == 1 && celdaPadre.primeraPosicion == 0) { celdaPadre.primeraPosicion = _fechaCreacion; }else if (posicion == 2 && celdaPadre.segundaPosicion == 0 ) { celdaPadre.segundaPosicion = _fechaCreacion; }else if (posicion == 3 && celdaPadre.terceraPosicion == 0) { celdaPadre.terceraPosicion = _fechaCreacion; }else if (posicion == 4 && celdaPadre.cuartaPosicion == 0) { celdaPadre.cuartaPosicion = _fechaCreacion; }else if (posicion == 5 && celdaPadre.quintaPosicion == 0) { celdaPadre.quintaPosicion = _fechaCreacion; }else if (posicion == 6 && celdaPadre.sextaPosicion == 0) { celdaPadre.sextaPosicion = _fechaCreacion; } if (_celdaAbuelo != 0 && !celda.premio) { _transfer(repartidor,celdaPadre.creador,2 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + (2 * multiplicador); celdaAbuelo.polenPositivos = celdaAbuelo.polenPositivos + (1 * multiplicador); _transfer(repartidor,celdaAbuelo.creador,1 * multiplicador); celdas[celdaAbuelo.fechaCreacion] = celdaAbuelo; }else if (!celda.premio) { _transfer(repartidor,celdaPadre.creador,3 * multiplicador); celdaPadre.polenPositivos = celdaPadre.polenPositivos + ( 3 * multiplicador); } celdas[celdaPadre.fechaCreacion] = celdaPadre; } function getCelda(uint index) returns (address creador, uint polenPositivos, uint polenNegativos, uint fechaCreacion, uint primeraPosicion, uint segundaPosicion, uint terceraPosicion, uint cuartaPosicion, uint quintaPosicion, uint sextaPosicion, TiposCompartidos.TipoPremio tipo, bool premio) { } function getBalance(address addr) returns(uint) { } function getFechaTax() returns(uint) { } function getNumeroCeldas() returns(uint) { } function getOwner() returns(address) { } function getRevenue(uint amount) onlyOwner { } function sell(uint amount){ } function setFechaTax(uint _fechaTax) onlyOwner { } function setPrices(uint256 newSellPrice, uint256 newBuyPrice) onlyOwner { } function transfer(address _to, uint _value){ } function _transfer(address _from, address _to, uint _value) internal { } }
((posicion==1&&celdaPadre.primeraPosicion==0)||celdas[celdaPadre.primeraPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==2&&celdaPadre.segundaPosicion==0)||celdas[celdaPadre.segundaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==3&&celdaPadre.terceraPosicion==0)||celdas[celdaPadre.terceraPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==4&&celdaPadre.cuartaPosicion==0)||celdas[celdaPadre.cuartaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==5&&celdaPadre.quintaPosicion==0)||celdas[celdaPadre.quintaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==6&&celdaPadre.sextaPosicion==0)||celdas[celdaPadre.sextaPosicion].tipo!=TiposCompartidos.TipoPremio.none)
299,111
((posicion==1&&celdaPadre.primeraPosicion==0)||celdas[celdaPadre.primeraPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==2&&celdaPadre.segundaPosicion==0)||celdas[celdaPadre.segundaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==3&&celdaPadre.terceraPosicion==0)||celdas[celdaPadre.terceraPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==4&&celdaPadre.cuartaPosicion==0)||celdas[celdaPadre.cuartaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==5&&celdaPadre.quintaPosicion==0)||celdas[celdaPadre.quintaPosicion].tipo!=TiposCompartidos.TipoPremio.none)||((posicion==6&&celdaPadre.sextaPosicion==0)||celdas[celdaPadre.sextaPosicion].tipo!=TiposCompartidos.TipoPremio.none)
null
pragma solidity ^0.4.6; contract SafeMath { function safeMul(uint a, uint b) internal returns (uint) { } function safeDiv(uint a, uint b) internal returns (uint) { } function safeSub(uint a, uint b) internal returns (uint) { } function safeAdd(uint a, uint b) internal returns (uint) { } 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) { } } contract ERC20 { function totalSupply() constant returns (uint256 totalSupply); function balanceOf(address who) constant returns (uint); function allowance(address owner, address spender) constant returns (uint); function transfer(address to, uint value) returns (bool ok); function transferFrom(address from, address to, uint value) returns (bool ok); function approve(address spender, uint value) returns (bool ok); event Transfer(address indexed from, address indexed to, uint value); event Approval(address indexed owner, address indexed spender, uint value); event FrozenFunds(address target, bool frozen); } contract StandardToken is ERC20, SafeMath { mapping(address => uint) balances; mapping (address => mapping (address => uint)) allowed; mapping (address => bool) public frozenAccount; uint public _totalSupply; address public _creator; bool bIsFreezeAll = false; function totalSupply() constant returns (uint256 totalSupply) { } function transfer(address _to, uint _value) returns (bool success) { } function transferFrom(address _from, address _to, uint _value) returns (bool success) { } function balanceOf(address _owner) constant returns (uint balance) { } function approve(address _spender, uint _value) returns (bool success) { require(bIsFreezeAll == false); require(!frozenAccount[msg.sender]); require(<FILL_ME>) allowed[msg.sender][_spender] = _value; Approval(msg.sender, _spender, _value); return true; } function allowance(address _owner, address _spender) constant returns (uint remaining) { } function freezeAll() { } function mintToken(address target, uint256 mintedAmount) { } function freezeAccount(address target, bool freeze) { } } contract SNS is StandardToken { string public name = "Skyrim Network"; string public symbol = "SNS"; uint public decimals = 18; uint public INITIAL_SUPPLY = 49900000000000000000000000000; function SNS() { } function destroy() { } }
!frozenAccount[_spender]
299,180
!frozenAccount[_spender]
null
pragma solidity ^0.4.6; contract SafeMath { function safeMul(uint a, uint b) internal returns (uint) { } function safeDiv(uint a, uint b) internal returns (uint) { } function safeSub(uint a, uint b) internal returns (uint) { } function safeAdd(uint a, uint b) internal returns (uint) { } 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) { } } contract ERC20 { function totalSupply() constant returns (uint256 totalSupply); function balanceOf(address who) constant returns (uint); function allowance(address owner, address spender) constant returns (uint); function transfer(address to, uint value) returns (bool ok); function transferFrom(address from, address to, uint value) returns (bool ok); function approve(address spender, uint value) returns (bool ok); event Transfer(address indexed from, address indexed to, uint value); event Approval(address indexed owner, address indexed spender, uint value); event FrozenFunds(address target, bool frozen); } contract StandardToken is ERC20, SafeMath { mapping(address => uint) balances; mapping (address => mapping (address => uint)) allowed; mapping (address => bool) public frozenAccount; uint public _totalSupply; address public _creator; bool bIsFreezeAll = false; function totalSupply() constant returns (uint256 totalSupply) { } function transfer(address _to, uint _value) returns (bool success) { } function transferFrom(address _from, address _to, uint _value) returns (bool success) { } function balanceOf(address _owner) constant returns (uint balance) { } function approve(address _spender, uint _value) returns (bool success) { } function allowance(address _owner, address _spender) constant returns (uint remaining) { require(!frozenAccount[msg.sender]); require(<FILL_ME>) require(!frozenAccount[_spender]); return allowed[_owner][_spender]; } function freezeAll() { } function mintToken(address target, uint256 mintedAmount) { } function freezeAccount(address target, bool freeze) { } } contract SNS is StandardToken { string public name = "Skyrim Network"; string public symbol = "SNS"; uint public decimals = 18; uint public INITIAL_SUPPLY = 49900000000000000000000000000; function SNS() { } function destroy() { } }
!frozenAccount[_owner]
299,180
!frozenAccount[_owner]
null
// SPDX-License-Identifier: Unlicensed /* ______ _____ _______ _______ _______ _____ _____ _______ _______ | \ | | | | |_____| |_____] | | |_____| | |_____/ |_____| | |_____ | | | __|__ | | | |_____ website: https://dotcapital.finance telegram: https://t.me/dotcapital */ pragma solidity ^0.8.10; 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) { } } abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor() { } function owner() public view virtual returns (address) { } modifier onlyOwner() { } function renounceOwnership() public virtual onlyOwner() { } function transferOwnership(address newOwner) public virtual onlyOwner() { } function _transferOwnership(address newOwner) internal virtual { } } 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); } contract DOTCAPITAL 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 => bool) private _isBot; uint256 private constant _MAX = ~uint256(0); uint256 private constant _tTotal = 1e10 * 10**9; uint256 private _rTotal = (_MAX - (_MAX % _tTotal)); uint256 private _tFeeTotal; string private constant _name = "Dot Capital"; string private constant _symbol = "DOTCAPITAL"; uint private constant _decimals = 9; uint256 private _teamFee = 15; uint256 private _previousteamFee = _teamFee; uint256 private _maxTxnAmount = 4; address payable private _feeAddress; // Uniswap Pair IUniswapV2Router02 private _uniswapV2Router; address private _uniswapV2Pair; bool private _initialized = false; bool private _noTaxMode = false; bool private _inSwap = false; bool private _tradingOpen = false; uint256 private _launchTime; bool private _txnLimit = false; modifier lockTheSwap() { } modifier handleFees(bool takeFee) { } constructor () { } function name() public pure returns (string memory) { } function symbol() public pure returns (string memory) { } function decimals() public pure returns (uint) { } 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 _removeAllFees() private { } function _restoreAllFees() 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"); require(!_isBot[from], "Your address has been marked as a bot, please contact staff to appeal your case."); bool takeFee = false; if ( !_isExcludedFromFee[from] && !_isExcludedFromFee[to] && !_noTaxMode && (from == _uniswapV2Pair || to == _uniswapV2Pair) ) { require(_tradingOpen, 'Trading has not yet been opened.'); takeFee = true; if (from == _uniswapV2Pair && to != address(_uniswapV2Router) && _txnLimit) { uint walletBalance = balanceOf(address(to)); require(<FILL_ME>) } if (block.timestamp == _launchTime) _isBot[to] = true; uint256 contractTokenBalance = balanceOf(address(this)); if (!_inSwap && from != _uniswapV2Pair) { if (contractTokenBalance > 0) { if (contractTokenBalance > balanceOf(_uniswapV2Pair).mul(15).div(100)) contractTokenBalance = balanceOf(_uniswapV2Pair).mul(15).div(100); _swapTokensForEth(contractTokenBalance); } } } _tokenTransfer(from, to, amount, takeFee); } function _swapTokensForEth(uint256 tokenAmount) private lockTheSwap() { } function _tokenTransfer(address sender, address recipient, uint256 tAmount, bool takeFee) private handleFees(takeFee) { } function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256) { } function _getTValues(uint256 tAmount, uint256 TeamFee) private pure returns (uint256, uint256) { } function _getRate() private view returns (uint256) { } function _getCurrentSupply() private view returns (uint256, uint256) { } function _getRValues(uint256 tAmount, uint256 tTeam, uint256 currentRate) private pure returns (uint256, uint256) { } function _takeTeam(uint256 tTeam) private { } function initNewPair(address payable feeAddress) external onlyOwner() { } function startTrading() external onlyOwner() { } function setFeeWallet(address payable feeWalletAddress) external onlyOwner() { } function excludeFromFee(address payable ad) external onlyOwner() { } function includeToFee(address payable ad) external onlyOwner() { } function enableTxnLimit(bool onoff) external onlyOwner() { } function setTeamFee(uint256 fee) external onlyOwner() { } function setMaxTxn(uint256 max) external onlyOwner(){ } function setBots(address[] memory bots_) public onlyOwner() { } function delBots(address[] memory bots_) public onlyOwner() { } function isBot(address ad) public view returns (bool) { } function isExcludedFromFee(address ad) public view returns (bool) { } function swapFeesManual() external onlyOwner() { } function withdrawFees() external { } receive() external payable {} }
amount.add(walletBalance)<=_tTotal.mul(_maxTxnAmount).div(100)
299,265
amount.add(walletBalance)<=_tTotal.mul(_maxTxnAmount).div(100)
"Unauthorized Access"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC721Tradable.sol"; contract MintPass is ERC721Tradable { struct Pass { // Amount of discount when using the pass uint256 discount; // Base URIs used for generating the token URIs based on the passId string baseTokenURI; // Used for checking if the pass is valid/active bool active; } // URI for the contract-level metadata string private _contractURI; mapping (address => bool) public minters; mapping (address => bool) public burners; // Map between the passId to the pass data mapping (uint256 => Pass) private _passDetails; // Map between the tokenId to the passId mapping (uint256 => uint256) private _passes; // Tracks the total number of minted and burnt passes for each type in circulation mapping (uint256 => uint256) public mintedCounts; mapping (uint256 => uint256) public burntCounts; // Add this modifier to all functions which are only accessible by the minters modifier onlyMinter() { } // Add this modifier to all functions which are only accessible by the burners modifier onlyBurner() { require(<FILL_ME>) _; } // Add this modifier to all functions which require valid passId modifier isValidPass(uint256 _passId) { } constructor ( string memory _name, string memory _symbol, string memory _cURI, address _proxyRegistryAddress ) ERC721Tradable(_name, _symbol, _proxyRegistryAddress) { } // Add/remove the specified address to the minter groups function setMinter(address _address, bool _state) external onlyOwner { } // Add/remove the specified address to the burner groups function setBurner(address _address, bool _state) external onlyOwner { } function baseTokenURI(uint256 _passId) public view isValidPass(_passId) returns (string memory) { } function setBaseTokenURI(uint256 _passId, string memory _uri) external isValidPass(_passId) onlyOwner { } function discount(uint256 _passId) external view isValidPass(_passId) returns (uint256) { } function setDiscount(uint256 _passId, uint256 _discount) external isValidPass(_passId) onlyOwner { } function passExists(uint256 _passId) external view returns (bool) { } function passDetail(uint256 _tokenId) external view returns (address, uint256, uint256) { } function tokenURI(uint256 _tokenId) override public view returns (string memory) { } function contractURI() public view returns (string memory) { } // Should only be changed when there's a critical change to the contract metadata function setContractURI(string memory _cURI) external onlyOwner { } function registerPass( uint256 _passId, uint256 _discount, string memory _baseTokenURI ) external onlyOwner { } function tokenIdsByOwner(address _address) external view returns (uint256[] memory) { } // Mint a new pass token to the specified address function mintToken( address _account, uint256 _passId, uint256 _count ) external onlyMinter { } // Burn the specified pass tokenId function burnToken(uint256 _tokenId) external onlyBurner { } }
burners[msg.sender],"Unauthorized Access"
299,319
burners[msg.sender]
"Invalid Pass Specified"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC721Tradable.sol"; contract MintPass is ERC721Tradable { struct Pass { // Amount of discount when using the pass uint256 discount; // Base URIs used for generating the token URIs based on the passId string baseTokenURI; // Used for checking if the pass is valid/active bool active; } // URI for the contract-level metadata string private _contractURI; mapping (address => bool) public minters; mapping (address => bool) public burners; // Map between the passId to the pass data mapping (uint256 => Pass) private _passDetails; // Map between the tokenId to the passId mapping (uint256 => uint256) private _passes; // Tracks the total number of minted and burnt passes for each type in circulation mapping (uint256 => uint256) public mintedCounts; mapping (uint256 => uint256) public burntCounts; // Add this modifier to all functions which are only accessible by the minters modifier onlyMinter() { } // Add this modifier to all functions which are only accessible by the burners modifier onlyBurner() { } // Add this modifier to all functions which require valid passId modifier isValidPass(uint256 _passId) { require(<FILL_ME>) _; } constructor ( string memory _name, string memory _symbol, string memory _cURI, address _proxyRegistryAddress ) ERC721Tradable(_name, _symbol, _proxyRegistryAddress) { } // Add/remove the specified address to the minter groups function setMinter(address _address, bool _state) external onlyOwner { } // Add/remove the specified address to the burner groups function setBurner(address _address, bool _state) external onlyOwner { } function baseTokenURI(uint256 _passId) public view isValidPass(_passId) returns (string memory) { } function setBaseTokenURI(uint256 _passId, string memory _uri) external isValidPass(_passId) onlyOwner { } function discount(uint256 _passId) external view isValidPass(_passId) returns (uint256) { } function setDiscount(uint256 _passId, uint256 _discount) external isValidPass(_passId) onlyOwner { } function passExists(uint256 _passId) external view returns (bool) { } function passDetail(uint256 _tokenId) external view returns (address, uint256, uint256) { } function tokenURI(uint256 _tokenId) override public view returns (string memory) { } function contractURI() public view returns (string memory) { } // Should only be changed when there's a critical change to the contract metadata function setContractURI(string memory _cURI) external onlyOwner { } function registerPass( uint256 _passId, uint256 _discount, string memory _baseTokenURI ) external onlyOwner { } function tokenIdsByOwner(address _address) external view returns (uint256[] memory) { } // Mint a new pass token to the specified address function mintToken( address _account, uint256 _passId, uint256 _count ) external onlyMinter { } // Burn the specified pass tokenId function burnToken(uint256 _tokenId) external onlyBurner { } }
_passDetails[_passId].active,"Invalid Pass Specified"
299,319
_passDetails[_passId].active
"Invalid TokenId Specified"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC721Tradable.sol"; contract MintPass is ERC721Tradable { struct Pass { // Amount of discount when using the pass uint256 discount; // Base URIs used for generating the token URIs based on the passId string baseTokenURI; // Used for checking if the pass is valid/active bool active; } // URI for the contract-level metadata string private _contractURI; mapping (address => bool) public minters; mapping (address => bool) public burners; // Map between the passId to the pass data mapping (uint256 => Pass) private _passDetails; // Map between the tokenId to the passId mapping (uint256 => uint256) private _passes; // Tracks the total number of minted and burnt passes for each type in circulation mapping (uint256 => uint256) public mintedCounts; mapping (uint256 => uint256) public burntCounts; // Add this modifier to all functions which are only accessible by the minters modifier onlyMinter() { } // Add this modifier to all functions which are only accessible by the burners modifier onlyBurner() { } // Add this modifier to all functions which require valid passId modifier isValidPass(uint256 _passId) { } constructor ( string memory _name, string memory _symbol, string memory _cURI, address _proxyRegistryAddress ) ERC721Tradable(_name, _symbol, _proxyRegistryAddress) { } // Add/remove the specified address to the minter groups function setMinter(address _address, bool _state) external onlyOwner { } // Add/remove the specified address to the burner groups function setBurner(address _address, bool _state) external onlyOwner { } function baseTokenURI(uint256 _passId) public view isValidPass(_passId) returns (string memory) { } function setBaseTokenURI(uint256 _passId, string memory _uri) external isValidPass(_passId) onlyOwner { } function discount(uint256 _passId) external view isValidPass(_passId) returns (uint256) { } function setDiscount(uint256 _passId, uint256 _discount) external isValidPass(_passId) onlyOwner { } function passExists(uint256 _passId) external view returns (bool) { } function passDetail(uint256 _tokenId) external view returns (address, uint256, uint256) { require(<FILL_ME>) address owner = ownerOf(_tokenId); uint256 passId = _passes[_tokenId]; uint256 passDiscount = _passDetails[passId].discount; return (owner, passId, passDiscount); } function tokenURI(uint256 _tokenId) override public view returns (string memory) { } function contractURI() public view returns (string memory) { } // Should only be changed when there's a critical change to the contract metadata function setContractURI(string memory _cURI) external onlyOwner { } function registerPass( uint256 _passId, uint256 _discount, string memory _baseTokenURI ) external onlyOwner { } function tokenIdsByOwner(address _address) external view returns (uint256[] memory) { } // Mint a new pass token to the specified address function mintToken( address _account, uint256 _passId, uint256 _count ) external onlyMinter { } // Burn the specified pass tokenId function burnToken(uint256 _tokenId) external onlyBurner { } }
_passDetails[_passes[_tokenId]].active,"Invalid TokenId Specified"
299,319
_passDetails[_passes[_tokenId]].active
"Invalid TokenID Specified"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC721Tradable.sol"; contract MintPass is ERC721Tradable { struct Pass { // Amount of discount when using the pass uint256 discount; // Base URIs used for generating the token URIs based on the passId string baseTokenURI; // Used for checking if the pass is valid/active bool active; } // URI for the contract-level metadata string private _contractURI; mapping (address => bool) public minters; mapping (address => bool) public burners; // Map between the passId to the pass data mapping (uint256 => Pass) private _passDetails; // Map between the tokenId to the passId mapping (uint256 => uint256) private _passes; // Tracks the total number of minted and burnt passes for each type in circulation mapping (uint256 => uint256) public mintedCounts; mapping (uint256 => uint256) public burntCounts; // Add this modifier to all functions which are only accessible by the minters modifier onlyMinter() { } // Add this modifier to all functions which are only accessible by the burners modifier onlyBurner() { } // Add this modifier to all functions which require valid passId modifier isValidPass(uint256 _passId) { } constructor ( string memory _name, string memory _symbol, string memory _cURI, address _proxyRegistryAddress ) ERC721Tradable(_name, _symbol, _proxyRegistryAddress) { } // Add/remove the specified address to the minter groups function setMinter(address _address, bool _state) external onlyOwner { } // Add/remove the specified address to the burner groups function setBurner(address _address, bool _state) external onlyOwner { } function baseTokenURI(uint256 _passId) public view isValidPass(_passId) returns (string memory) { } function setBaseTokenURI(uint256 _passId, string memory _uri) external isValidPass(_passId) onlyOwner { } function discount(uint256 _passId) external view isValidPass(_passId) returns (uint256) { } function setDiscount(uint256 _passId, uint256 _discount) external isValidPass(_passId) onlyOwner { } function passExists(uint256 _passId) external view returns (bool) { } function passDetail(uint256 _tokenId) external view returns (address, uint256, uint256) { } function tokenURI(uint256 _tokenId) override public view returns (string memory) { uint256 passId = _passes[_tokenId]; require(<FILL_ME>) return string(baseTokenURI(passId)); } function contractURI() public view returns (string memory) { } // Should only be changed when there's a critical change to the contract metadata function setContractURI(string memory _cURI) external onlyOwner { } function registerPass( uint256 _passId, uint256 _discount, string memory _baseTokenURI ) external onlyOwner { } function tokenIdsByOwner(address _address) external view returns (uint256[] memory) { } // Mint a new pass token to the specified address function mintToken( address _account, uint256 _passId, uint256 _count ) external onlyMinter { } // Burn the specified pass tokenId function burnToken(uint256 _tokenId) external onlyBurner { } }
_passDetails[passId].active,"Invalid TokenID Specified"
299,319
_passDetails[passId].active
"Pass Has Been Registered"
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC721Tradable.sol"; contract MintPass is ERC721Tradable { struct Pass { // Amount of discount when using the pass uint256 discount; // Base URIs used for generating the token URIs based on the passId string baseTokenURI; // Used for checking if the pass is valid/active bool active; } // URI for the contract-level metadata string private _contractURI; mapping (address => bool) public minters; mapping (address => bool) public burners; // Map between the passId to the pass data mapping (uint256 => Pass) private _passDetails; // Map between the tokenId to the passId mapping (uint256 => uint256) private _passes; // Tracks the total number of minted and burnt passes for each type in circulation mapping (uint256 => uint256) public mintedCounts; mapping (uint256 => uint256) public burntCounts; // Add this modifier to all functions which are only accessible by the minters modifier onlyMinter() { } // Add this modifier to all functions which are only accessible by the burners modifier onlyBurner() { } // Add this modifier to all functions which require valid passId modifier isValidPass(uint256 _passId) { } constructor ( string memory _name, string memory _symbol, string memory _cURI, address _proxyRegistryAddress ) ERC721Tradable(_name, _symbol, _proxyRegistryAddress) { } // Add/remove the specified address to the minter groups function setMinter(address _address, bool _state) external onlyOwner { } // Add/remove the specified address to the burner groups function setBurner(address _address, bool _state) external onlyOwner { } function baseTokenURI(uint256 _passId) public view isValidPass(_passId) returns (string memory) { } function setBaseTokenURI(uint256 _passId, string memory _uri) external isValidPass(_passId) onlyOwner { } function discount(uint256 _passId) external view isValidPass(_passId) returns (uint256) { } function setDiscount(uint256 _passId, uint256 _discount) external isValidPass(_passId) onlyOwner { } function passExists(uint256 _passId) external view returns (bool) { } function passDetail(uint256 _tokenId) external view returns (address, uint256, uint256) { } function tokenURI(uint256 _tokenId) override public view returns (string memory) { } function contractURI() public view returns (string memory) { } // Should only be changed when there's a critical change to the contract metadata function setContractURI(string memory _cURI) external onlyOwner { } function registerPass( uint256 _passId, uint256 _discount, string memory _baseTokenURI ) external onlyOwner { require(_passId >= 1, "Invalid Pass ID"); require(<FILL_ME>) require(_discount <= 100, "Invalid Discount"); _passDetails[_passId] = Pass(_discount, _baseTokenURI, true); } function tokenIdsByOwner(address _address) external view returns (uint256[] memory) { } // Mint a new pass token to the specified address function mintToken( address _account, uint256 _passId, uint256 _count ) external onlyMinter { } // Burn the specified pass tokenId function burnToken(uint256 _tokenId) external onlyBurner { } }
!_passDetails[_passId].active,"Pass Has Been Registered"
299,319
!_passDetails[_passId].active
null
pragma solidity ^0.4.24; library Math { 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) { } } contract Ownable { address public owner_; mapping(address => bool) locked_; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor() public { } modifier onlyOwner() { } modifier locked() { require(<FILL_ME>) _; } function transferOwnership(address newOwner) public onlyOwner { } function lock(address owner) public onlyOwner { } function unlock(address owner) public onlyOwner { } } contract ERC20Token { using Math for uint256; event Burn(address indexed burner, uint256 value); event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); uint256 totalSupply_; mapping(address => uint256) balances_; mapping (address => mapping (address => uint256)) internal allowed_; function totalSupply() public view returns (uint256) { } function transfer(address to, uint256 value) public returns (bool) { } function balanceOf(address owner) public view returns (uint256 balance) { } function transferFrom(address from, address to, uint256 value) public returns (bool) { } function approve(address spender, uint256 value) public returns (bool) { } function allowance(address owner, address spender) public view returns (uint256) { } function burn(uint256 value) public { } } contract GlobalRewardBank is Ownable, ERC20Token { using Math for uint; uint8 constant public decimals = 18; string constant public symbol = "GRB"; string constant public name = "GlobalRewardBank"; address constant comany = 0x8977DA9ECa78045D800F91B125E3c06dCfaA1d6F; constructor(uint amount) public { } function withdrawTokens(address cont) external onlyOwner { } function initSetting(address addr, uint amount) internal returns (bool) { } function transfer(address to, uint256 value) public locked returns (bool) { } function transferFrom(address from, address to, uint256 value) public locked returns (bool) { } }
!locked_[msg.sender]
299,347
!locked_[msg.sender]
null
pragma solidity 0.4.24; /** * @title Ownable * @dev This contract has an owner address providing basic authorization control */ contract Ownable is EternalStorage { bytes4 internal constant UPGRADEABILITY_OWNER = 0x6fde8202; // upgradeabilityOwner() /** * @dev Event to show ownership has been transferred * @param previousOwner representing the address of the previous owner * @param newOwner representing the address of the new owner */ event OwnershipTransferred(address previousOwner, address newOwner); /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { } /** * @dev Throws if called by any account other than contract itself or owner. */ modifier onlyRelevantSender() { // proxy owner if used through proxy, address(0) otherwise require(<FILL_ME>) /* solcov ignore next */ _; } bytes32 internal constant OWNER = 0x02016836a56b71f0d02689e69e326f4f4c1b9057164ef592671cf0d37c8040c0; // keccak256(abi.encodePacked("owner")) /** * @dev Tells the address of the owner * @return the address of the owner */ function owner() public view returns (address) { } /** * @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) external onlyOwner { } /** * @dev Sets a new owner address */ function setOwner(address newOwner) internal { } }
!address(this).call(abi.encodeWithSelector(UPGRADEABILITY_OWNER))||msg.sender==IUpgradeabilityOwnerStorage(this).upgradeabilityOwner()||msg.sender==address(this)
299,487
!address(this).call(abi.encodeWithSelector(UPGRADEABILITY_OWNER))||msg.sender==IUpgradeabilityOwnerStorage(this).upgradeabilityOwner()||msg.sender==address(this)
null
contract Hedgie is ERC721Token, Ownable { /** * This is the total number of hex colors */ uint256 internal _totalColors = 16777216; /** * This is the base URI for hedgie data */ string public tokenURIPrefix = "https://api.hedgie.io/api/v2/hedgies/metas/"; mapping (address => uint) internal approvedAddressIndexes; address[] internal approvedAddresses; constructor() ERC721Token("Hedgie", "HDG") public { } /** * @dev Mints a token to an address * @param _to address of the future owner of the token * @param _tokenId the ID of the token to mint */ function mintTo(address _to, uint256 _tokenId) public onlyApprovedAddresses { } function setTokenURIPrefix(string newPrefix) external onlyOwner { } function tokenURI(uint256 _tokenId) public view returns (string) { } function tokensOf(address _owner) public view returns (uint256[]){ } /** * @dev Throws if called by any account other than the owner. */ modifier onlyApprovedAddresses() { require(<FILL_ME>) _; } function addApprovedAddress(address newAddress) public onlyOwner { } function removeApprovedAddress(address addressToRemove) public onlyOwner { } function removeAllApprovedAddresses() public onlyOwner { } function getApprovedAddresses() public view onlyOwner returns (address[]) { } }
approvedAddressIndexes[msg.sender]!=0||msg.sender==owner
299,695
approvedAddressIndexes[msg.sender]!=0||msg.sender==owner
null
contract Hedgie is ERC721Token, Ownable { /** * This is the total number of hex colors */ uint256 internal _totalColors = 16777216; /** * This is the base URI for hedgie data */ string public tokenURIPrefix = "https://api.hedgie.io/api/v2/hedgies/metas/"; mapping (address => uint) internal approvedAddressIndexes; address[] internal approvedAddresses; constructor() ERC721Token("Hedgie", "HDG") public { } /** * @dev Mints a token to an address * @param _to address of the future owner of the token * @param _tokenId the ID of the token to mint */ function mintTo(address _to, uint256 _tokenId) public onlyApprovedAddresses { } function setTokenURIPrefix(string newPrefix) external onlyOwner { } function tokenURI(uint256 _tokenId) public view returns (string) { } function tokensOf(address _owner) public view returns (uint256[]){ } /** * @dev Throws if called by any account other than the owner. */ modifier onlyApprovedAddresses() { } function addApprovedAddress(address newAddress) public onlyOwner { require(<FILL_ME>) approvedAddresses.push(newAddress); approvedAddressIndexes[newAddress] = approvedAddresses.length; } function removeApprovedAddress(address addressToRemove) public onlyOwner { } function removeAllApprovedAddresses() public onlyOwner { } function getApprovedAddresses() public view onlyOwner returns (address[]) { } }
approvedAddressIndexes[newAddress]==0
299,695
approvedAddressIndexes[newAddress]==0
null
contract Hedgie is ERC721Token, Ownable { /** * This is the total number of hex colors */ uint256 internal _totalColors = 16777216; /** * This is the base URI for hedgie data */ string public tokenURIPrefix = "https://api.hedgie.io/api/v2/hedgies/metas/"; mapping (address => uint) internal approvedAddressIndexes; address[] internal approvedAddresses; constructor() ERC721Token("Hedgie", "HDG") public { } /** * @dev Mints a token to an address * @param _to address of the future owner of the token * @param _tokenId the ID of the token to mint */ function mintTo(address _to, uint256 _tokenId) public onlyApprovedAddresses { } function setTokenURIPrefix(string newPrefix) external onlyOwner { } function tokenURI(uint256 _tokenId) public view returns (string) { } function tokensOf(address _owner) public view returns (uint256[]){ } /** * @dev Throws if called by any account other than the owner. */ modifier onlyApprovedAddresses() { } function addApprovedAddress(address newAddress) public onlyOwner { } function removeApprovedAddress(address addressToRemove) public onlyOwner { require(<FILL_ME>) // delete it from array and from map uint i = approvedAddressIndexes[addressToRemove] - 1; // replace the slot if there are more items if (approvedAddresses.length > 1) { approvedAddresses[i] = approvedAddresses[approvedAddresses.length - 1]; approvedAddressIndexes[approvedAddresses[i]] = i + 1; } delete approvedAddressIndexes[addressToRemove]; approvedAddresses.length--; } function removeAllApprovedAddresses() public onlyOwner { } function getApprovedAddresses() public view onlyOwner returns (address[]) { } }
approvedAddressIndexes[addressToRemove]!=0
299,695
approvedAddressIndexes[addressToRemove]!=0
"RICK-08"
pragma solidity ^0.5.0; pragma experimental ABIEncoderV2; import "./ERC721Tradable.sol"; import "./Strings.sol"; import "./Ownable.sol"; import "./SafeMath.sol"; /** * @title Creature * Creature - a contract for my non-fungible creatures. */ contract Creature is ERC721Tradable { address payable private _owner; uint256 private _currentTokenId = 0; uint256 private _basePrice = 0; uint256 private constant _protectPrice = 300000000000000000; uint256 private constant _imagePrice = 100000000000000000; uint256 private constant _simpleTraitPrice = 14000000000000000; uint256 private constant _advancedTraitPrice = 35000000000000000; uint256 private constant _legendaryTraitPrice = 60000000000000000; struct Rick { uint256 skin; uint256 hair; uint256 shirt; uint256 pants; uint256 shoes; uint256 item; } struct RickProtection { uint256 id; uint256 value; } bytes32 constant RICK_TYPEHASH = keccak256( "Rick(uint skin, uint hair, uint shirt, uint pants, uint shoes, uint item)" ); bytes32 constant RICKPROTECTION_TYPEHASH = keccak256( "RickProtection(uint id, uint value)" ); mapping (uint => Rick) private _ricks; mapping (uint => string) private _image; mapping (uint => string) private _name; //hash => rickId mapping (bytes32 => bool) private _rickHash; mapping (bytes32 => bool) private _rickProtectionHash; constructor(address _proxyRegistryAddress) public ERC721Tradable("CryptoRick", "RICKS", _proxyRegistryAddress) { } function craftRick(Rick memory rick) public returns (uint){ } function getImage(uint rickId) public view returns (string memory){ } function totalSupply() public view returns (uint256) { } function hash(Rick memory _rick) internal pure returns (bytes32) { } function hashProtection(RickProtection memory _rickProt) internal pure returns (bytes32) { } function _getNextTokenId() private view returns (uint256) { } function _incrementTokenId() private { } function getCurrentTokenId() public view returns (uint256) { } function getRick(uint rickId) public view returns (Rick memory) { } function getName(uint rickId) public view returns (string memory){ } function setName( uint rickId, string memory name ) public payable { require(<FILL_ME>) require(msg.value >= 50000000000000000, "RICK-09"); _name[rickId] = name; } function buyRick( Rick memory _rick, string memory image, uint[] memory protectedTraitIds ) public payable { } function getPriceForRick(Rick memory rick, bool withImage, uint protectedTraits) internal view returns(uint){ } function withdraw(uint256 amount) public { } function baseTokenURI() public pure returns (string memory) { } function contractURI() public pure returns (string memory) { } }
ownerOf(rickId)==msg.sender,"RICK-08"
299,758
ownerOf(rickId)==msg.sender