Address Contract Partially Verified
Address
0x2BfF6f4284774836d867CEd2e9B96c27aAee55B7
Balance
0 ETH
Nonce
1
Code Size
17951 bytes
Creator
0x54Af0D48...6209 at tx 0xcab4fbb1...096f14
Indexed Transactions
0
Contract Bytecode
17951 bytes
0x60806040526004361061025b575f3560e01c80635c975abb11610143578063a0712d68116100b5578063d2d8cb6711610079578063d2d8cb6714610845578063daefe6d21461086f578063e985e9c514610899578063f2fde38b146108d5578063f81227d4146108fd578063fdc9b483146109135761025b565b8063a0712d6814610787578063a22cb465146107a3578063b88d4fde146107cb578063c87b56dd146107f3578063cca979111461082f5761025b565b8063715018a611610107578063715018a6146106a1578063748c4557146106b75780637b51715d146106f3578063894a8cac1461071d5780638da5cb5b1461073357806395d89b411461075d5761025b565b80635c975abb146105ad5780635d04aeab146105d75780636352211e146105ff57806368fc68c71461063b57806370a08231146106655761025b565b806327ac36c4116101dc57806342966c68116101a057806342966c68146104d9578063452b67cb14610501578063471a42941461051d5780634f699a431461054757806355f804b31461056f57806359c74f29146105975761025b565b806327ac36c41461043157806330f72cd4146104475780633ccfd60b146104715780634230baee1461048757806342842e0e146104b15761025b565b80631096952311610223578063109695231461036557806316c38b3c1461038d57806318160ddd146103b557806323b872dd146103df57806323eb0032146104075761025b565b806301ffc9a71461025f57806306fdde031461029b578063081812fc146102c5578063095ea7b3146103015780630c9a631314610329575b5f5ffd5b34801561026a575f5ffd5b5061028560048036038101906102809190612c05565b61093d565b6040516102929190612c4a565b60405180910390f35b3480156102a6575f5ffd5b506102af610a1e565b6040516102bc9190612cd3565b60405180910390f35b3480156102d0575f5ffd5b506102eb60048036038101906102e69190612d26565b610aad565b6040516102f89190612d90565b60405180910390f35b34801561030c575f5ffd5b5061032760048036038101906103229190612dd3565b610b2e565b005b348015610334575f5ffd5b5061034f600480360381019061034a9190612e11565b610c44565b60405161035c9190612c4a565b60405180910390f35b348015610370575f5ffd5b5061038b60048036038101906103869190612f68565b610c61565b005b348015610398575f5ffd5b506103b360048036038101906103ae9190612fd9565b610c7c565b005b3480156103c0575f5ffd5b506103c9610ca2565b6040516103d69190613013565b60405180910390f35b3480156103ea575f5ffd5b506104056004803603810190610400919061302c565b610cb8565b005b348015610412575f5ffd5b5061041b610d18565b6040516104289190613013565b60405180910390f35b34801561043c575f5ffd5b50610445610d1d565b005b348015610452575f5ffd5b5061045b610d76565b6040516104689190612c4a565b60405180910390f35b34801561047c575f5ffd5b50610485610d89565b005b348015610492575f5ffd5b5061049b610da9565b6040516104a89190613013565b60405180910390f35b3480156104bc575f5ffd5b506104d760048036038101906104d2919061302c565b610daf565b005b3480156104e4575f5ffd5b506104ff60048036038101906104fa9190612d26565b610dce565b005b61051b60048036038101906105169190612d26565b610e41565b005b348015610528575f5ffd5b50610531611063565b60405161053e9190612c4a565b60405180910390f35b348015610552575f5ffd5b5061056d60048036038101906105689190613140565b611075565b005b34801561057a575f5ffd5b5061059560048036038101906105909190612f68565b61110b565b005b3480156105a2575f5ffd5b506105ab611126565b005b3480156105b8575f5ffd5b506105c1611158565b6040516105ce9190612c4a565b60405180910390f35b3480156105e2575f5ffd5b506105fd60048036038101906105f89190613140565b61116e565b005b34801561060a575f5ffd5b5061062560048036038101906106209190612d26565b611204565b6040516106329190612d90565b60405180910390f35b348015610646575f5ffd5b5061064f6112b0565b60405161065c9190613013565b60405180910390f35b348015610670575f5ffd5b5061068b60048036038101906106869190612e11565b6112b5565b6040516106989190613013565b60405180910390f35b3480156106ac575f5ffd5b506106b5611369565b005b3480156106c2575f5ffd5b506106dd60048036038101906106d89190612e11565b61137c565b6040516106ea9190612c4a565b60405180910390f35b3480156106fe575f5ffd5b50610707611399565b6040516107149190613013565b60405180910390f35b348015610728575f5ffd5b5061073161139f565b005b34801561073e575f5ffd5b506107476113d1565b6040516107549190612d90565b60405180910390f35b348015610768575f5ffd5b506107716113f9565b60405161077e9190612cd3565b60405180910390f35b6107a1600480360381019061079c9190612d26565b611489565b005b3480156107ae575f5ffd5b506107c960048036038101906107c49190613187565b6115c6565b005b3480156107d6575f5ffd5b506107f160048036038101906107ec9190613263565b6115dc565b005b3480156107fe575f5ffd5b5061081960048036038101906108149190612d26565b61163e565b6040516108269190612cd3565b60405180910390f35b34801561083a575f5ffd5b506108436116e2565b005b348015610850575f5ffd5b5061085961184e565b6040516108669190613013565b60405180910390f35b34801561087a575f5ffd5b50610883611859565b6040516108909190612cd3565b60405180910390f35b3480156108a4575f5ffd5b506108bf60048036038101906108ba91906132e3565b6118e5565b6040516108cc9190612c4a565b60405180910390f35b3480156108e0575f5ffd5b506108fb60048036038101906108f69190612e11565b611973565b005b348015610908575f5ffd5b506109116119f7565b005b34801561091e575f5ffd5b50610927611a2b565b6040516109349190612c4a565b60405180910390f35b5f7f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480610a0757507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80610a175750610a1682611a3d565b5b9050919050565b60605f8054610a2c9061334e565b80601f0160208091040260200160405190810160405280929190818152602001828054610a589061334e565b8015610aa35780601f10610a7a57610100808354040283529160200191610aa3565b820191905f5260205f20905b815481529060010190602001808311610a8657829003601f168201915b5050505050905090565b5f610ab782611aa6565b610af6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aed906133ee565b60405180910390fd5b60045f8381526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b5f610b3882611204565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610ba8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b9f9061347c565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16610bc7611b0e565b73ffffffffffffffffffffffffffffffffffffffff161480610bf65750610bf581610bf0611b0e565b6118e5565b5b610c35576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c2c9061350a565b60405180910390fd5b610c3f8383611b15565b505050565b600f602052805f5260405f205f915054906101000a900460ff1681565b610c69611bcb565b8060089081610c7891906136c8565b5050565b610c84611bcb565b80610c9657610c91611c52565b610c9f565b610c9e611cb4565b5b50565b5f600b54600a54610cb391906137c4565b905090565b610cc9610cc3611b0e565b82611d17565b610d08576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cff90613867565b60405180910390fd5b610d13838383611df3565b505050565b609681565b610d25611bcb565b5f600a5490505f5f90505b6014811015610d7257600a5f815480929190610d4b90613885565b9190505550610d65338284610d6091906138cc565b61204e565b8080600101915050610d30565b5050565b600c60019054906101000a900460ff1681565b610d91611bcb565b5f479050610da6610da06113d1565b8261206b565b50565b600a5481565b610dc983838360405180602001604052805f8152506115dc565b505050565b610ddf610dd9611b0e565b82611d17565b610e1e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e159061396f565b60405180910390fd5b610e278161215b565b600b5f815480929190610e3990613885565b919050555050565b610e4961226d565b600c60019054906101000a900460ff16610e98576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e8f906139d7565b60405180910390fd5b6096811115610edc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ed390613a65565b60405180910390fd5b60011515600d5f3373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16151514610f6c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f6390613af3565b60405180910390fd5b3481662386f26fc10000610f809190613b11565b1115610fc1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fb890613bc2565b60405180910390fd5b5f5f90505b81811015611003575f600a549050600a5f815480929190610fe690613885565b9190505550610ff5338261204e565b508080600101915050610fc6565b505f600d5f3373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055506110606122bc565b50565b600c5f9054906101000a900460ff1681565b61107d611bcb565b5f5f90505b8151811015611107576001600d5f8484815181106110a3576110a2613be0565b5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055508080600101915050611082565b5050565b611113611bcb565b806009908161112291906136c8565b5050565b61112e611bcb565b600c5f9054906101000a900460ff1615600c5f6101000a81548160ff021916908315150217905550565b5f600660149054906101000a900460ff16905090565b611176611bcb565b5f5f90505b8151811015611200576001600f5f84848151811061119c5761119b613be0565b5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff021916908315150217905550808060010191505061117b565b5050565b5f5f60025f8481526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690505f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036112a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161129e90613c7d565b60405180910390fd5b80915050919050565b601481565b5f5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611324576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161131b90613d0b565b60405180910390fd5b60035f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b611371611bcb565b61137a5f6122c6565b565b600d602052805f5260405f205f915054906101000a900460ff1681565b600b5481565b6113a7611bcb565b600e5f9054906101000a900460ff1615600e5f6101000a81548160ff021916908315150217905550565b5f60065f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6060600180546114089061334e565b80601f01602080910402602001604051908101604052809291908181526020018280546114349061334e565b801561147f5780601f106114565761010080835404028352916020019161147f565b820191905f5260205f20905b81548152906001019060200180831161146257829003601f168201915b5050505050905090565b61149161226d565b600c5f9054906101000a900460ff166114df576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016114d6906139d7565b60405180910390fd5b6096811115611523576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161151a90613a65565b60405180910390fd5b3481662386f26fc100006115379190613b11565b1115611578576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161156f90613bc2565b60405180910390fd5b5f5f90505b818110156115ba575f600a549050600a5f81548092919061159d90613885565b91905055506115ac338261204e565b50808060010191505061157d565b506115c36122bc565b50565b6115d86115d1611b0e565b8383612389565b5050565b6115ed6115e7611b0e565b83611d17565b61162c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161162390613867565b60405180910390fd5b611638848484846124f0565b50505050565b606061164982611aa6565b611688576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161167f90613d99565b60405180910390fd5b5f61169161254c565b90505f8151116116af5760405180602001604052805f8152506116da565b806116b9846125dc565b6040516020016116ca929190613df1565b6040516020818303038152906040525b915050919050565b6116ea61226d565b600e5f9054906101000a900460ff16611738576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161172f906139d7565b60405180910390fd5b60011515600f5f3373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff161515146117c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117bf90613e84565b60405180910390fd5b5f600a549050600a5f8154809291906117e090613885565b91905055506117ef338261204e565b5f600f5f3373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055505061184c6122bc565b565b662386f26fc1000081565b600880546118669061334e565b80601f01602080910402602001604051908101604052809291908181526020018280546118929061334e565b80156118dd5780601f106118b4576101008083540402835291602001916118dd565b820191905f5260205f20905b8154815290600101906020018083116118c057829003601f168201915b505050505081565b5f60055f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f9054906101000a900460ff16905092915050565b61197b611bcb565b5f73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036119eb575f6040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081526004016119e29190612d90565b60405180910390fd5b6119f4816122c6565b50565b6119ff611bcb565b600c60019054906101000a900460ff1615600c60016101000a81548160ff021916908315150217905550565b600e5f9054906101000a900460ff1681565b5f7f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b5f5f73ffffffffffffffffffffffffffffffffffffffff1660025f8481526020019081526020015f205f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614159050919050565b5f33905090565b8160045f8381526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16611b8583611204565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b611bd3611b0e565b73ffffffffffffffffffffffffffffffffffffffff16611bf16113d1565b73ffffffffffffffffffffffffffffffffffffffff1614611c5057611c14611b0e565b6040517f118cdaa7000000000000000000000000000000000000000000000000000000008152600401611c479190612d90565b60405180910390fd5b565b611c5a612735565b5f600660146101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa611c9d611b0e565b604051611caa9190612d90565b60405180910390a1565b611cbc61277e565b6001600660146101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611d00611b0e565b604051611d0d9190612d90565b60405180910390a1565b5f611d2182611aa6565b611d60576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d5790613f12565b60405180910390fd5b5f611d6a83611204565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480611dac5750611dab81856118e5565b5b80611dea57508373ffffffffffffffffffffffffffffffffffffffff16611dd284610aad565b73ffffffffffffffffffffffffffffffffffffffff16145b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff16611e1382611204565b73ffffffffffffffffffffffffffffffffffffffff1614611e69576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e6090613fa0565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611ed7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611ece9061402e565b60405180910390fd5b611ee28383836127c8565b611eec5f82611b15565b600160035f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f828254611f3991906137c4565b92505081905550600160035f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f828254611f8d91906138cc565b925050819055508160025f8381526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a46120498383836127cd565b505050565b612067828260405180602001604052805f8152506127d2565b5050565b804710156120ae576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120a590614096565b60405180910390fd5b5f8273ffffffffffffffffffffffffffffffffffffffff16826040516120d3906140e1565b5f6040518083038185875af1925050503d805f811461210d576040519150601f19603f3d011682016040523d82523d5f602084013e612112565b606091505b5050905080612156576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161214d90614165565b60405180910390fd5b505050565b5f61216582611204565b9050612172815f846127c8565b61217c5f83611b15565b600160035f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8282546121c991906137c4565b9250508190555060025f8381526020019081526020015f205f6101000a81549073ffffffffffffffffffffffffffffffffffffffff0219169055815f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612269815f846127cd565b5050565b6002600754036122b2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122a9906141cd565b60405180910390fd5b6002600781905550565b6001600781905550565b5f60065f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1690508160065f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036123f7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016123ee90614235565b60405180910390fd5b8060055f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f6101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516124e39190612c4a565b60405180910390a3505050565b6124fb848484611df3565b6125078484848461282c565b612546576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161253d906142c3565b60405180910390fd5b50505050565b60606009805461255b9061334e565b80601f01602080910402602001604051908101604052809291908181526020018280546125879061334e565b80156125d25780601f106125a9576101008083540402835291602001916125d2565b820191905f5260205f20905b8154815290600101906020018083116125b557829003601f168201915b5050505050905090565b60605f8203612622576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050612730565b5f8290505f5b5f821461265157808061263a90613885565b915050600a8261264a919061430e565b9150612628565b5f8167ffffffffffffffff81111561266c5761266b612e44565b5b6040519080825280601f01601f19166020018201604052801561269e5781602001600182028036833780820191505090505b5090505b5f8514612729576001826126b691906137c4565b9150600a856126c5919061433e565b60306126d191906138cc565b60f81b8183815181106126e7576126e6613be0565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600a85612722919061430e565b94506126a2565b8093505050505b919050565b61273d611158565b61277c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612773906143b8565b60405180910390fd5b565b612786611158565b156127c6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127bd90614420565b60405180910390fd5b565b505050565b505050565b6127dc83836129ae565b6127e85f84848461282c565b612827576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161281e906142c3565b60405180910390fd5b505050565b5f61284c8473ffffffffffffffffffffffffffffffffffffffff16612b7d565b156129a1578373ffffffffffffffffffffffffffffffffffffffff1663150b7a02612875611b0e565b8786866040518563ffffffff1660e01b81526004016128979493929190614490565b6020604051808303815f875af19250505080156128d257506040513d601f19601f820116820180604052508101906128cf91906144ee565b60015b612951573d805f8114612900576040519150601f19603f3d011682016040523d82523d5f602084013e612905565b606091505b505f815103612949576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612940906142c3565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150506129a6565b600190505b949350505050565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603612a1c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612a1390614563565b60405180910390fd5b612a2581611aa6565b15612a65576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612a5c906145cb565b60405180910390fd5b612a705f83836127c8565b600160035f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f828254612abd91906138cc565b925050819055508160025f8381526020019081526020015f205f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff165f73ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612b795f83836127cd565b5050565b5f5f8273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b5f604051905090565b5f5ffd5b5f5ffd5b5f7fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b612be481612bb0565b8114612bee575f5ffd5b50565b5f81359050612bff81612bdb565b92915050565b5f60208284031215612c1a57612c19612ba8565b5b5f612c2784828501612bf1565b91505092915050565b5f8115159050919050565b612c4481612c30565b82525050565b5f602082019050612c5d5f830184612c3b565b92915050565b5f81519050919050565b5f82825260208201905092915050565b8281835e5f83830152505050565b5f601f19601f8301169050919050565b5f612ca582612c63565b612caf8185612c6d565b9350612cbf818560208601612c7d565b612cc881612c8b565b840191505092915050565b5f6020820190508181035f830152612ceb8184612c9b565b905092915050565b5f819050919050565b612d0581612cf3565b8114612d0f575f5ffd5b50565b5f81359050612d2081612cfc565b92915050565b5f60208284031215612d3b57612d3a612ba8565b5b5f612d4884828501612d12565b91505092915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f612d7a82612d51565b9050919050565b612d8a81612d70565b82525050565b5f602082019050612da35f830184612d81565b92915050565b612db281612d70565b8114612dbc575f5ffd5b50565b5f81359050612dcd81612da9565b92915050565b5f5f60408385031215612de957612de8612ba8565b5b5f612df685828601612dbf565b9250506020612e0785828601612d12565b9150509250929050565b5f60208284031215612e2657612e25612ba8565b5b5f612e3384828501612dbf565b91505092915050565b5f5ffd5b5f5ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b612e7a82612c8b565b810181811067ffffffffffffffff82111715612e9957612e98612e44565b5b80604052505050565b5f612eab612b9f565b9050612eb78282612e71565b919050565b5f67ffffffffffffffff821115612ed657612ed5612e44565b5b612edf82612c8b565b9050602081019050919050565b828183375f83830152505050565b5f612f0c612f0784612ebc565b612ea2565b905082815260208101848484011115612f2857612f27612e40565b5b612f33848285612eec565b509392505050565b5f82601f830112612f4f57612f4e612e3c565b5b8135612f5f848260208601612efa565b91505092915050565b5f60208284031215612f7d57612f7c612ba8565b5b5f82013567ffffffffffffffff811115612f9a57612f99612bac565b5b612fa684828501612f3b565b91505092915050565b612fb881612c30565b8114612fc2575f5ffd5b50565b5f81359050612fd381612faf565b92915050565b5f60208284031215612fee57612fed612ba8565b5b5f612ffb84828501612fc5565b91505092915050565b61300d81612cf3565b82525050565b5f6020820190506130265f830184613004565b92915050565b5f5f5f6060848603121561304357613042612ba8565b5b5f61305086828701612dbf565b935050602061306186828701612dbf565b925050604061307286828701612d12565b9150509250925092565b5f67ffffffffffffffff82111561309657613095612e44565b5b602082029050602081019050919050565b5f5ffd5b5f6130bd6130b88461307c565b612ea2565b905080838252602082019050602084028301858111156130e0576130df6130a7565b5b835b8181101561310957806130f58882612dbf565b8452602084019350506020810190506130e2565b5050509392505050565b5f82601f83011261312757613126612e3c565b5b81356131378482602086016130ab565b91505092915050565b5f6020828403121561315557613154612ba8565b5b5f82013567ffffffffffffffff81111561317257613171612bac565b5b61317e84828501613113565b91505092915050565b5f5f6040838503121561319d5761319c612ba8565b5b5f6131aa85828601612dbf565b92505060206131bb85828601612fc5565b9150509250929050565b5f67ffffffffffffffff8211156131df576131de612e44565b5b6131e882612c8b565b9050602081019050919050565b5f613207613202846131c5565b612ea2565b90508281526020810184848401111561322357613222612e40565b5b61322e848285612eec565b509392505050565b5f82601f83011261324a57613249612e3c565b5b813561325a8482602086016131f5565b91505092915050565b5f5f5f5f6080858703121561327b5761327a612ba8565b5b5f61328887828801612dbf565b945050602061329987828801612dbf565b93505060406132aa87828801612d12565b925050606085013567ffffffffffffffff8111156132cb576132ca612bac565b5b6132d787828801613236565b91505092959194509250565b5f5f604083850312156132f9576132f8612ba8565b5b5f61330685828601612dbf565b925050602061331785828601612dbf565b9150509250929050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f600282049050600182168061336557607f821691505b60208210810361337857613377613321565b5b50919050565b7f4552433732313a20617070726f76656420717565727920666f72206e6f6e65785f8201527f697374656e7420746f6b656e0000000000000000000000000000000000000000602082015250565b5f6133d8602c83612c6d565b91506133e38261337e565b604082019050919050565b5f6020820190508181035f830152613405816133cc565b9050919050565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e655f8201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b5f613466602183612c6d565b91506134718261340c565b604082019050919050565b5f6020820190508181035f8301526134938161345a565b9050919050565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f775f8201527f6e6572206e6f7220617070726f76656420666f7220616c6c0000000000000000602082015250565b5f6134f4603883612c6d565b91506134ff8261349a565b604082019050919050565b5f6020820190508181035f830152613521816134e8565b9050919050565b5f819050815f5260205f209050919050565b5f6020601f8301049050919050565b5f82821b905092915050565b5f600883026135847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82613549565b61358e8683613549565b95508019841693508086168417925050509392505050565b5f819050919050565b5f6135c96135c46135bf84612cf3565b6135a6565b612cf3565b9050919050565b5f819050919050565b6135e2836135af565b6135f66135ee826135d0565b848454613555565b825550505050565b5f5f905090565b61360d6135fe565b6136188184846135d9565b505050565b5b8181101561363b576136305f82613605565b60018101905061361e565b5050565b601f8211156136805761365181613528565b61365a8461353a565b81016020851015613669578190505b61367d6136758561353a565b83018261361d565b50505b505050565b5f82821c905092915050565b5f6136a05f1984600802613685565b1980831691505092915050565b5f6136b88383613691565b9150826002028217905092915050565b6136d182612c63565b67ffffffffffffffff8111156136ea576136e9612e44565b5b6136f4825461334e565b6136ff82828561363f565b5f60209050601f831160018114613730575f841561371e578287015190505b61372885826136ad565b86555061378f565b601f19841661373e86613528565b5f5b8281101561376557848901518255600182019150602085019450602081019050613740565b86831015613782578489015161377e601f891682613691565b8355505b6001600288020188555050505b505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f6137ce82612cf3565b91506137d983612cf3565b92508282039050818111156137f1576137f0613797565b5b92915050565b7f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f5f8201527f776e6572206e6f7220617070726f766564000000000000000000000000000000602082015250565b5f613851603183612c6d565b915061385c826137f7565b604082019050919050565b5f6020820190508181035f83015261387e81613845565b9050919050565b5f61388f82612cf3565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036138c1576138c0613797565b5b600182019050919050565b5f6138d682612cf3565b91506138e183612cf3565b92508282019050808211156138f9576138f8613797565b5b92915050565b7f4552433732314275726e61626c653a2063616c6c6572206973206e6f74206f775f8201527f6e6572206e6f7220617070726f76656400000000000000000000000000000000602082015250565b5f613959603083612c6d565b9150613964826138ff565b604082019050919050565b5f6020820190508181035f8301526139868161394d565b9050919050565b7f4d696e74206973206e6f742061637469766500000000000000000000000000005f82015250565b5f6139c1601283612c6d565b91506139cc8261398d565b602082019050919050565b5f6020820190508181035f8301526139ee816139b5565b9050919050565b7f596f752077656e74206f766572206d617820746f6b656e7320706572207472615f8201527f6e73616374696f6e000000000000000000000000000000000000000000000000602082015250565b5f613a4f602883612c6d565b9150613a5a826139f5565b604082019050919050565b5f6020820190508181035f830152613a7c81613a43565b9050919050565b7f596f7520617265206e6f74206f6e207468652070726573616c652077616c6c655f8201527f74206c697374206f72206861766520616c7265616479206d696e746564000000602082015250565b5f613add603d83612c6d565b9150613ae882613a83565b604082019050919050565b5f6020820190508181035f830152613b0a81613ad1565b9050919050565b5f613b1b82612cf3565b9150613b2683612cf3565b9250828202613b3481612cf3565b91508282048414831517613b4b57613b4a613797565b5b5092915050565b7f596f752073656e742074686520696e636f727265637420616d6f756e74206f665f8201527f2045544800000000000000000000000000000000000000000000000000000000602082015250565b5f613bac602483612c6d565b9150613bb782613b52565b604082019050919050565b5f6020820190508181035f830152613bd981613ba0565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b7f4552433732313a206f776e657220717565727920666f72206e6f6e65786973745f8201527f656e7420746f6b656e0000000000000000000000000000000000000000000000602082015250565b5f613c67602983612c6d565b9150613c7282613c0d565b604082019050919050565b5f6020820190508181035f830152613c9481613c5b565b9050919050565b7f4552433732313a2062616c616e636520717565727920666f7220746865207a655f8201527f726f206164647265737300000000000000000000000000000000000000000000602082015250565b5f613cf5602a83612c6d565b9150613d0082613c9b565b604082019050919050565b5f6020820190508181035f830152613d2281613ce9565b9050919050565b7f4552433732314d657461646174613a2055524920717565727920666f72206e6f5f8201527f6e6578697374656e7420746f6b656e0000000000000000000000000000000000602082015250565b5f613d83602f83612c6d565b9150613d8e82613d29565b604082019050919050565b5f6020820190508181035f830152613db081613d77565b9050919050565b5f81905092915050565b5f613dcb82612c63565b613dd58185613db7565b9350613de5818560208601612c7d565b80840191505092915050565b5f613dfc8285613dc1565b9150613e088284613dc1565b91508190509392505050565b7f596f7520617265206e6f74206f6e2074686520667265652077616c6c6574206c5f8201527f697374206f72206861766520616c7265616479206d696e746564000000000000602082015250565b5f613e6e603a83612c6d565b9150613e7982613e14565b604082019050919050565b5f6020820190508181035f830152613e9b81613e62565b9050919050565b7f4552433732313a206f70657261746f7220717565727920666f72206e6f6e65785f8201527f697374656e7420746f6b656e0000000000000000000000000000000000000000602082015250565b5f613efc602c83612c6d565b9150613f0782613ea2565b604082019050919050565b5f6020820190508181035f830152613f2981613ef0565b9050919050565b7f4552433732313a207472616e736665722066726f6d20696e636f7272656374205f8201527f6f776e6572000000000000000000000000000000000000000000000000000000602082015250565b5f613f8a602583612c6d565b9150613f9582613f30565b604082019050919050565b5f6020820190508181035f830152613fb781613f7e565b9050919050565b7f4552433732313a207472616e7366657220746f20746865207a65726f206164645f8201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b5f614018602483612c6d565b915061402382613fbe565b604082019050919050565b5f6020820190508181035f8301526140458161400c565b9050919050565b7f416464726573733a20696e73756666696369656e742062616c616e63650000005f82015250565b5f614080601d83612c6d565b915061408b8261404c565b602082019050919050565b5f6020820190508181035f8301526140ad81614074565b9050919050565b5f81905092915050565b50565b5f6140cc5f836140b4565b91506140d7826140be565b5f82019050919050565b5f6140eb826140c1565b9150819050919050565b7f416464726573733a20756e61626c6520746f2073656e642076616c75652c20725f8201527f6563697069656e74206d61792068617665207265766572746564000000000000602082015250565b5f61414f603a83612c6d565b915061415a826140f5565b604082019050919050565b5f6020820190508181035f83015261417c81614143565b9050919050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c005f82015250565b5f6141b7601f83612c6d565b91506141c282614183565b602082019050919050565b5f6020820190508181035f8301526141e4816141ab565b9050919050565b7f4552433732313a20617070726f766520746f2063616c6c6572000000000000005f82015250565b5f61421f601983612c6d565b915061422a826141eb565b602082019050919050565b5f6020820190508181035f83015261424c81614213565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e2045524337323152655f8201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b5f6142ad603283612c6d565b91506142b882614253565b604082019050919050565b5f6020820190508181035f8301526142da816142a1565b9050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b5f61431882612cf3565b915061432383612cf3565b925082614333576143326142e1565b5b828204905092915050565b5f61434882612cf3565b915061435383612cf3565b925082614363576143626142e1565b5b828206905092915050565b7f5061757361626c653a206e6f74207061757365640000000000000000000000005f82015250565b5f6143a2601483612c6d565b91506143ad8261436e565b602082019050919050565b5f6020820190508181035f8301526143cf81614396565b9050919050565b7f5061757361626c653a20706175736564000000000000000000000000000000005f82015250565b5f61440a601083612c6d565b9150614415826143d6565b602082019050919050565b5f6020820190508181035f830152614437816143fe565b9050919050565b5f81519050919050565b5f82825260208201905092915050565b5f6144628261443e565b61446c8185614448565b935061447c818560208601612c7d565b61448581612c8b565b840191505092915050565b5f6080820190506144a35f830187612d81565b6144b06020830186612d81565b6144bd6040830185613004565b81810360608301526144cf8184614458565b905095945050505050565b5f815190506144e881612bdb565b92915050565b5f6020828403121561450357614502612ba8565b5b5f614510848285016144da565b91505092915050565b7f4552433732313a206d696e7420746f20746865207a65726f20616464726573735f82015250565b5f61454d602083612c6d565b915061455882614519565b602082019050919050565b5f6020820190508181035f83015261457a81614541565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e746564000000005f82015250565b5f6145b5601c83612c6d565b91506145c082614581565b602082019050919050565b5f6020820190508181035f8301526145e2816145a9565b905091905056fea264697066735822122098f54539dfb22f37f5bc925dd2890b58178c99a9a77bee37f2e8881b6964330b64736f6c634300081e0033
Verified Source Code Partial Match
Compiler: v0.8.30+commit.73712a01
EVM: prague
Optimization: No
SBSDraftTokenSeasonThree.sol 3042 lines
// File: @openzeppelin/contracts/utils/introspection/IERC165.sol
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}
// File: @openzeppelin/contracts/token/ERC721/IERC721.sol
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721.sol)
pragma solidity ^0.8.0;
/**
* @dev Required interface of an ERC721 compliant contract.
*/
interface IERC721 is IERC165 {
/**
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
*/
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
*/
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
*/
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
/**
* @dev Returns the number of tokens in ``owner``'s account.
*/
function balanceOf(address owner) external view returns (uint256 balance);
/**
* @dev Returns the owner of the `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function ownerOf(uint256 tokenId) external view returns (address owner);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes calldata data
) external;
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) external;
/**
* @dev Transfers `tokenId` token from `from` to `to`.
*
* WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
*
* Emits a {Transfer} event.
*/
function transferFrom(
address from,
address to,
uint256 tokenId
) external;
/**
* @dev Gives permission to `to` to transfer `tokenId` token to another account.
* The approval is cleared when the token is transferred.
*
* Only a single account can be approved at a time, so approving the zero address clears previous approvals.
*
* Requirements:
*
* - The caller must own the token or be an approved operator.
* - `tokenId` must exist.
*
* Emits an {Approval} event.
*/
function approve(address to, uint256 tokenId) external;
/**
* @dev Approve or remove `operator` as an operator for the caller.
* Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
*
* Requirements:
*
* - The `operator` cannot be the caller.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool _approved) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
*
* See {setApprovalForAll}
*/
function isApprovedForAll(address owner, address operator) external view returns (bool);
}
// File: @openzeppelin/contracts/token/ERC721/IERC721Receiver.sol
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)
pragma solidity ^0.8.0;
/**
* @title ERC721 token receiver interface
* @dev Interface for any contract that wants to support safeTransfers
* from ERC721 asset contracts.
*/
interface IERC721Receiver {
/**
* @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
* by `operator` from `from`, this function is called.
*
* It must return its Solidity selector to confirm the token transfer.
* If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
*
* The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
*/
function onERC721Received(
address operator,
address from,
uint256 tokenId,
bytes calldata data
) external returns (bytes4);
}
// File: @openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)
pragma solidity ^0.8.0;
/**
* @title ERC-721 Non-Fungible Token Standard, optional metadata extension
* @dev See https://eips.ethereum.org/EIPS/eip-721
*/
interface IERC721Metadata is IERC721 {
/**
* @dev Returns the token collection name.
*/
function name() external view returns (string memory);
/**
* @dev Returns the token collection symbol.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
*/
function tokenURI(uint256 tokenId) external view returns (string memory);
}
// File: @openzeppelin/contracts/utils/Address.sol
// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCall(target, data, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
require(isContract(target), "Address: delegate call to non-contract");
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}
// File: @openzeppelin/contracts/utils/Context.sol
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
// File: @openzeppelin/contracts/utils/Strings.sol
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)
pragma solidity ^0.8.0;
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
// Inspired by OraclizeAPI's implementation - MIT licence
// https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol
if (value == 0) {
return "0";
}
uint256 temp = value;
uint256 digits;
while (temp != 0) {
digits++;
temp /= 10;
}
bytes memory buffer = new bytes(digits);
while (value != 0) {
digits -= 1;
buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
value /= 10;
}
return string(buffer);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
if (value == 0) {
return "0x00";
}
uint256 temp = value;
uint256 length = 0;
while (temp != 0) {
length++;
temp >>= 8;
}
return toHexString(value, length);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = _HEX_SYMBOLS[value & 0xf];
value >>= 4;
}
require(value == 0, "Strings: hex length insufficient");
return string(buffer);
}
}
// File: @openzeppelin/contracts/utils/introspection/ERC165.sol
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*
* Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}
// File: @openzeppelin/contracts/token/ERC721/ERC721.sol
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/ERC721.sol)
pragma solidity ^0.8.0;
/**
* @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
* the Metadata extension, but not including the Enumerable extension, which is available separately as
* {ERC721Enumerable}.
*/
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
using Address for address;
using Strings for uint256;
// Token name
string private _name;
// Token symbol
string private _symbol;
// Mapping from token ID to owner address
mapping(uint256 => address) private _owners;
// Mapping owner address to token count
mapping(address => uint256) private _balances;
// Mapping from token ID to approved address
mapping(uint256 => address) private _tokenApprovals;
// Mapping from owner to operator approvals
mapping(address => mapping(address => bool)) private _operatorApprovals;
/**
* @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
*/
constructor(string memory name_, string memory symbol_) {
_name = name_;
_symbol = symbol_;
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
return
interfaceId == type(IERC721).interfaceId ||
interfaceId == type(IERC721Metadata).interfaceId ||
super.supportsInterface(interfaceId);
}
/**
* @dev See {IERC721-balanceOf}.
*/
function balanceOf(address owner) public view virtual override returns (uint256) {
require(owner != address(0), "ERC721: balance query for the zero address");
return _balances[owner];
}
/**
* @dev See {IERC721-ownerOf}.
*/
function ownerOf(uint256 tokenId) public view virtual override returns (address) {
address owner = _owners[tokenId];
require(owner != address(0), "ERC721: owner query for nonexistent token");
return owner;
}
/**
* @dev See {IERC721Metadata-name}.
*/
function name() public view virtual override returns (string memory) {
return _name;
}
/**
* @dev See {IERC721Metadata-symbol}.
*/
function symbol() public view virtual override returns (string memory) {
return _symbol;
}
/**
* @dev See {IERC721Metadata-tokenURI}.
*/
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");
string memory baseURI = _baseURI();
return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
}
/**
* @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
* token will be the concatenation of the `baseURI` and the `tokenId`. Empty
* by default, can be overridden in child contracts.
*/
function _baseURI() internal view virtual returns (string memory) {
return "";
}
/**
* @dev See {IERC721-approve}.
*/
function approve(address to, uint256 tokenId) public virtual override {
address owner = ERC721.ownerOf(tokenId);
require(to != owner, "ERC721: approval to current owner");
require(
_msgSender() == owner || isApprovedForAll(owner, _msgSender()),
"ERC721: approve caller is not owner nor approved for all"
);
_approve(to, tokenId);
}
/**
* @dev See {IERC721-getApproved}.
*/
function getApproved(uint256 tokenId) public view virtual override returns (address) {
require(_exists(tokenId), "ERC721: approved query for nonexistent token");
return _tokenApprovals[tokenId];
}
/**
* @dev See {IERC721-setApprovalForAll}.
*/
function setApprovalForAll(address operator, bool approved) public virtual override {
_setApprovalForAll(_msgSender(), operator, approved);
}
/**
* @dev See {IERC721-isApprovedForAll}.
*/
function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
return _operatorApprovals[owner][operator];
}
/**
* @dev See {IERC721-transferFrom}.
*/
function transferFrom(
address from,
address to,
uint256 tokenId
) public virtual override {
//solhint-disable-next-line max-line-length
require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
_transfer(from, to, tokenId);
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) public virtual override {
safeTransferFrom(from, to, tokenId, "");
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes memory _data
) public virtual override {
require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
_safeTransfer(from, to, tokenId, _data);
}
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* `_data` is additional data, it has no specified format and it is sent in call to `to`.
*
* This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
* implement alternative mechanisms to perform token transfer, such as signature-based.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeTransfer(
address from,
address to,
uint256 tokenId,
bytes memory _data
) internal virtual {
_transfer(from, to, tokenId);
require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
}
/**
* @dev Returns whether `tokenId` exists.
*
* Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
*
* Tokens start existing when they are minted (`_mint`),
* and stop existing when they are burned (`_burn`).
*/
function _exists(uint256 tokenId) internal view virtual returns (bool) {
return _owners[tokenId] != address(0);
}
/**
* @dev Returns whether `spender` is allowed to manage `tokenId`.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
require(_exists(tokenId), "ERC721: operator query for nonexistent token");
address owner = ERC721.ownerOf(tokenId);
return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender);
}
/**
* @dev Safely mints `tokenId` and transfers it to `to`.
*
* Requirements:
*
* - `tokenId` must not exist.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeMint(address to, uint256 tokenId) internal virtual {
_safeMint(to, tokenId, "");
}
/**
* @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
* forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
*/
function _safeMint(
address to,
uint256 tokenId,
bytes memory _data
) internal virtual {
_mint(to, tokenId);
require(
_checkOnERC721Received(address(0), to, tokenId, _data),
"ERC721: transfer to non ERC721Receiver implementer"
);
}
/**
* @dev Mints `tokenId` and transfers it to `to`.
*
* WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
*
* Requirements:
*
* - `tokenId` must not exist.
* - `to` cannot be the zero address.
*
* Emits a {Transfer} event.
*/
function _mint(address to, uint256 tokenId) internal virtual {
require(to != address(0), "ERC721: mint to the zero address");
require(!_exists(tokenId), "ERC721: token already minted");
_beforeTokenTransfer(address(0), to, tokenId);
_balances[to] += 1;
_owners[tokenId] = to;
emit Transfer(address(0), to, tokenId);
_afterTokenTransfer(address(0), to, tokenId);
}
/**
* @dev Destroys `tokenId`.
* The approval is cleared when the token is burned.
*
* Requirements:
*
* - `tokenId` must exist.
*
* Emits a {Transfer} event.
*/
function _burn(uint256 tokenId) internal virtual {
address owner = ERC721.ownerOf(tokenId);
_beforeTokenTransfer(owner, address(0), tokenId);
// Clear approvals
_approve(address(0), tokenId);
_balances[owner] -= 1;
delete _owners[tokenId];
emit Transfer(owner, address(0), tokenId);
_afterTokenTransfer(owner, address(0), tokenId);
}
/**
* @dev Transfers `tokenId` from `from` to `to`.
* As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
*
* Requirements:
*
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
*
* Emits a {Transfer} event.
*/
function _transfer(
address from,
address to,
uint256 tokenId
) internal virtual {
require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
require(to != address(0), "ERC721: transfer to the zero address");
_beforeTokenTransfer(from, to, tokenId);
// Clear approvals from the previous owner
_approve(address(0), tokenId);
_balances[from] -= 1;
_balances[to] += 1;
_owners[tokenId] = to;
emit Transfer(from, to, tokenId);
_afterTokenTransfer(from, to, tokenId);
}
/**
* @dev Approve `to` to operate on `tokenId`
*
* Emits a {Approval} event.
*/
function _approve(address to, uint256 tokenId) internal virtual {
_tokenApprovals[tokenId] = to;
emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
}
/**
* @dev Approve `operator` to operate on all of `owner` tokens
*
* Emits a {ApprovalForAll} event.
*/
function _setApprovalForAll(
address owner,
address operator,
bool approved
) internal virtual {
require(owner != operator, "ERC721: approve to caller");
_operatorApprovals[owner][operator] = approved;
emit ApprovalForAll(owner, operator, approved);
}
/**
* @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
* The call is not executed if the target address is not a contract.
*
* @param from address representing the previous owner of the given token ID
* @param to target address that will receive the tokens
* @param tokenId uint256 ID of the token to be transferred
* @param _data bytes optional data to send along with the call
* @return bool whether the call correctly returned the expected magic value
*/
function _checkOnERC721Received(
address from,
address to,
uint256 tokenId,
bytes memory _data
) private returns (bool) {
if (to.isContract()) {
try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
return retval == IERC721Receiver.onERC721Received.selector;
} catch (bytes memory reason) {
if (reason.length == 0) {
revert("ERC721: transfer to non ERC721Receiver implementer");
} else {
assembly {
revert(add(32, reason), mload(reason))
}
}
}
} else {
return true;
}
}
/**
* @dev Hook that is called before any token transfer. This includes minting
* and burning.
*
* Calling conditions:
*
* - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
* transferred to `to`.
* - When `from` is zero, `tokenId` will be minted for `to`.
* - When `to` is zero, ``from``'s `tokenId` will be burned.
* - `from` and `to` are never both zero.
*
* To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
*/
function _beforeTokenTransfer(
address from,
address to,
uint256 tokenId
) internal virtual {}
/**
* @dev Hook that is called after any transfer of tokens. This includes
* minting and burning.
*
* Calling conditions:
*
* - when `from` and `to` are both non-zero.
* - `from` and `to` are never both zero.
*
* To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
*/
function _afterTokenTransfer(
address from,
address to,
uint256 tokenId
) internal virtual {}
}
// File: @openzeppelin/contracts/access/Ownable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol)
pragma solidity ^0.8.20;
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
* specific functions.
*
* The initial owner is set to the address provided by the deployer. This can
* later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available the modifier
* `onlyOwner`, which can be applied to your functions to restrict their use to
* the owner.
*/
abstract contract Ownable is Context {
address private _owner;
/**
* @dev The caller account is not authorized to perform an operation.
*/
error OwnableUnauthorizedAccount(address account);
/**
* @dev The owner is not a valid owner account. (eg. `address(0)`)
*/
error OwnableInvalidOwner(address owner);
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the address provided by the deployer as the initial owner.
*/
constructor(address initialOwner) {
if (initialOwner == address(0)) {
revert OwnableInvalidOwner(address(0));
}
_transferOwnership(initialOwner);
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
_checkOwner();
_;
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view virtual returns (address) {
return _owner;
}
/**
* @dev Throws if the sender is not the owner.
*/
function _checkOwner() internal view virtual {
if (owner() != _msgSender()) {
revert OwnableUnauthorizedAccount(_msgSender());
}
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby disabling any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
_transferOwnership(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 {
if (newOwner == address(0)) {
revert OwnableInvalidOwner(address(0));
}
_transferOwnership(newOwner);
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Internal function without access restriction.
*/
function _transferOwnership(address newOwner) internal virtual {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}
// File: @openzeppelin/contracts/security/Pausable.sol
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)
pragma solidity ^0.8.0;
/**
* @dev Contract module which allows children to implement an emergency stop
* mechanism that can be triggered by an authorized account.
*
* This module is used through inheritance. It will make available the
* modifiers `whenNotPaused` and `whenPaused`, which can be applied to
* the functions of your contract. Note that they will not be pausable by
* simply including this module, only once the modifiers are put in place.
*/
abstract contract Pausable is Context {
/**
* @dev Emitted when the pause is triggered by `account`.
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by `account`.
*/
event Unpaused(address account);
bool private _paused;
/**
* @dev Initializes the contract in unpaused state.
*/
constructor() {
_paused = false;
}
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*
* Requirements:
*
* - The contract must not be paused.
*/
modifier whenNotPaused() {
_requireNotPaused();
_;
}
/**
* @dev Modifier to make a function callable only when the contract is paused.
*
* Requirements:
*
* - The contract must be paused.
*/
modifier whenPaused() {
_requirePaused();
_;
}
/**
* @dev Returns true if the contract is paused, and false otherwise.
*/
function paused() public view virtual returns (bool) {
return _paused;
}
/**
* @dev Throws if the contract is paused.
*/
function _requireNotPaused() internal view virtual {
require(!paused(), "Pausable: paused");
}
/**
* @dev Throws if the contract is not paused.
*/
function _requirePaused() internal view virtual {
require(paused(), "Pausable: not paused");
}
/**
* @dev Triggers stopped state.
*
* Requirements:
*
* - The contract must not be paused.
*/
function _pause() internal virtual whenNotPaused {
_paused = true;
emit Paused(_msgSender());
}
/**
* @dev Returns to normal state.
*
* Requirements:
*
* - The contract must be paused.
*/
function _unpause() internal virtual whenPaused {
_paused = false;
emit Unpaused(_msgSender());
}
}
// File: @openzeppelin/contracts/security/ReentrancyGuard.sol
// OpenZeppelin Contracts (last updated v4.9.0) (security/ReentrancyGuard.sol)
pragma solidity ^0.8.0;
/**
* @dev Contract module that helps prevent reentrant calls to a function.
*
* Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
* available, which can be applied to functions to make sure there are no nested
* (reentrant) calls to them.
*
* Note that because there is a single `nonReentrant` guard, functions marked as
* `nonReentrant` may not call one another. This can be worked around by making
* those functions `private`, and then adding `external` `nonReentrant` entry
* points to them.
*
* TIP: If you would like to learn more about reentrancy and alternative ways
* to protect against it, check out our blog post
* https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
*/
abstract contract ReentrancyGuard {
// Booleans are more expensive than uint256 or any type that takes up a full
// word because each write operation emits an extra SLOAD to first read the
// slot's contents, replace the bits taken up by the boolean, and then write
// back. This is the compiler's defense against contract upgrades and
// pointer aliasing, and it cannot be disabled.
// The values being non-zero value makes deployment a bit more expensive,
// but in exchange the refund on every call to nonReentrant will be lower in
// amount. Since refunds are capped to a percentage of the total
// transaction's gas, it is best to keep them low in cases like this one, to
// increase the likelihood of the full refund coming into effect.
uint256 private constant _NOT_ENTERED = 1;
uint256 private constant _ENTERED = 2;
uint256 private _status;
constructor() {
_status = _NOT_ENTERED;
}
/**
* @dev Prevents a contract from calling itself, directly or indirectly.
* Calling a `nonReentrant` function from another `nonReentrant`
* function is not supported. It is possible to prevent this from happening
* by making the `nonReentrant` function external, and making it call a
* `private` function that does the actual work.
*/
modifier nonReentrant() {
_nonReentrantBefore();
_;
_nonReentrantAfter();
}
function _nonReentrantBefore() private {
// On the first call to nonReentrant, _status will be _NOT_ENTERED
require(_status != _ENTERED, "ReentrancyGuard: reentrant call");
// Any calls to nonReentrant after this point will fail
_status = _ENTERED;
}
function _nonReentrantAfter() private {
// By storing the original value once again, a refund is triggered (see
// https://eips.ethereum.org/EIPS/eip-2200)
_status = _NOT_ENTERED;
}
/**
* @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a
* `nonReentrant` function in the call stack.
*/
function _reentrancyGuardEntered() internal view returns (bool) {
return _status == _ENTERED;
}
}
// File: hardhat/console.sol
pragma solidity >=0.4.22 <0.9.0;
library console {
address constant CONSOLE_ADDRESS =
0x000000000000000000636F6e736F6c652e6c6f67;
function _sendLogPayloadImplementation(bytes memory payload) internal view {
address consoleAddress = CONSOLE_ADDRESS;
/// @solidity memory-safe-assembly
assembly {
pop(
staticcall(
gas(),
consoleAddress,
add(payload, 32),
mload(payload),
0,
0
)
)
}
}
function _castToPure(
function(bytes memory) internal view fnIn
) internal pure returns (function(bytes memory) pure fnOut) {
assembly {
fnOut := fnIn
}
}
function _sendLogPayload(bytes memory payload) internal pure {
_castToPure(_sendLogPayloadImplementation)(payload);
}
function log() internal pure {
_sendLogPayload(abi.encodeWithSignature("log()"));
}
function logInt(int256 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(int256)", p0));
}
function logUint(uint256 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(uint256)", p0));
}
function logString(string memory p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(string)", p0));
}
function logBool(bool p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bool)", p0));
}
function logAddress(address p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(address)", p0));
}
function logBytes(bytes memory p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes)", p0));
}
function logBytes1(bytes1 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes1)", p0));
}
function logBytes2(bytes2 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes2)", p0));
}
function logBytes3(bytes3 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes3)", p0));
}
function logBytes4(bytes4 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes4)", p0));
}
function logBytes5(bytes5 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes5)", p0));
}
function logBytes6(bytes6 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes6)", p0));
}
function logBytes7(bytes7 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes7)", p0));
}
function logBytes8(bytes8 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes8)", p0));
}
function logBytes9(bytes9 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes9)", p0));
}
function logBytes10(bytes10 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes10)", p0));
}
function logBytes11(bytes11 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes11)", p0));
}
function logBytes12(bytes12 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes12)", p0));
}
function logBytes13(bytes13 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes13)", p0));
}
function logBytes14(bytes14 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes14)", p0));
}
function logBytes15(bytes15 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes15)", p0));
}
function logBytes16(bytes16 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes16)", p0));
}
function logBytes17(bytes17 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes17)", p0));
}
function logBytes18(bytes18 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes18)", p0));
}
function logBytes19(bytes19 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes19)", p0));
}
function logBytes20(bytes20 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes20)", p0));
}
function logBytes21(bytes21 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes21)", p0));
}
function logBytes22(bytes22 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes22)", p0));
}
function logBytes23(bytes23 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes23)", p0));
}
function logBytes24(bytes24 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes24)", p0));
}
function logBytes25(bytes25 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes25)", p0));
}
function logBytes26(bytes26 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes26)", p0));
}
function logBytes27(bytes27 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes27)", p0));
}
function logBytes28(bytes28 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes28)", p0));
}
function logBytes29(bytes29 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes29)", p0));
}
function logBytes30(bytes30 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes30)", p0));
}
function logBytes31(bytes31 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes31)", p0));
}
function logBytes32(bytes32 p0) internal pure {
_sendLogPayload(abi.encodeWithSignature("log(bytes32)", p0));
}
function log(uint256 p0) internal pure {
_s...
// [truncated — 119914 bytes total]
Read Contract
MAX_TOKENS_PURCHASE 0x23eb0032 → uint256
RESERVED_TOKENS 0x68fc68c7 → uint256
SPOILEDBANANASOCIETY_PROVENANCE 0xdaefe6d2 → string
TOKEN_PRICE 0xd2d8cb67 → uint256
balanceOf 0x70a08231 → uint256
freeWalletIsActive 0xfdc9b483 → bool
freeWalletList 0x0c9a6313 → bool
getApproved 0x081812fc → address
isApprovedForAll 0xe985e9c5 → bool
mintIsActive 0x471a4294 → bool
name 0x06fdde03 → string
numTokensBurned 0x7b51715d → uint256
numTokensMinted 0x4230baee → uint256
owner 0x8da5cb5b → address
ownerOf 0x6352211e → address
paused 0x5c975abb → bool
presaleIsActive 0x30f72cd4 → bool
presaleWalletList 0x748c4557 → bool
supportsInterface 0x01ffc9a7 → bool
symbol 0x95d89b41 → string
tokenURI 0xc87b56dd → string
totalSupply 0x18160ddd → uint256
Write Contract 21 functions
These functions modify contract state and require a wallet transaction to execute.
approve 0x095ea7b3
address to
uint256 tokenId
burn 0x42966c68
uint256 tokenId
flipFreeWalletState 0x894a8cac
No parameters
flipMintState 0x59c74f29
No parameters
flipPresaleState 0xf81227d4
No parameters
initFreeWalletList 0x5d04aeab
address[] walletList
initPresaleWalletList 0x4f699a43
address[] walletList
mint 0xa0712d68
uint256 numberOfTokens
mintFreeWalletList 0xcca97911
No parameters
mintPresaleWalletList 0x452b67cb
uint256 numberOfTokens
renounceOwnership 0x715018a6
No parameters
reserveTokens 0x27ac36c4
No parameters
safeTransferFrom 0x42842e0e
address from
address to
uint256 tokenId
safeTransferFrom 0xb88d4fde
address from
address to
uint256 tokenId
bytes _data
setApprovalForAll 0xa22cb465
address operator
bool approved
setBaseURI 0x55f804b3
string uri
setPaused 0x16c38b3c
bool _setPaused
setProvenanceHash 0x10969523
string provenanceHash
transferFrom 0x23b872dd
address from
address to
uint256 tokenId
transferOwnership 0xf2fde38b
address newOwner
withdraw 0x3ccfd60b
No parameters
Token Balances (1)
View Transfers →Recent Transactions
No transactions found for this address