Cryo Explorer Ethereum Mainnet

Address Contract Verified

Address 0x77D0cb0ab54F9E74b9405a5B3f60DA06A78F1AAd
Balance 0 ETH
Nonce 1
Code Size 10563 bytes
Indexed Transactions 0
External Etherscan · Sourcify

Contract Bytecode

10563 bytes
0x60806040526004361061014b5760003560e01c806370a08231116100b657806395d89b411161006f57806395d89b4114610461578063a457c2d71461048c578063a9059cbb146104c9578063d3fc986414610506578063dd62ed3e1461052f578063f2fde38b1461056c5761014b565b806370a0823114610365578063715018a6146103a2578063721e602a146103b9578063760a2e8a146103e25780638456cb591461041f5780638da5cb5b146104365761014b565b8063313ce56711610108578063313ce5671461026557806332cb6b0c1461029057806339509351146102bb5780633f4ba83a146102f857806340f6ac311461030f5780635c975abb1461033a5761014b565b806306fdde0314610150578063095ea7b31461017b5780630fae7eb6146101b857806318160ddd146101e157806323b872dd1461020c578063307cf63f14610249575b600080fd5b34801561015c57600080fd5b50610165610595565b604051610172919061189d565b60405180910390f35b34801561018757600080fd5b506101a2600480360381019061019d9190611967565b610627565b6040516101af91906119c2565b60405180910390f35b3480156101c457600080fd5b506101df60048036038101906101da9190611a19565b61064a565b005b3480156101ed57600080fd5b506101f66106c0565b6040516102039190611a55565b60405180910390f35b34801561021857600080fd5b50610233600480360381019061022e9190611a70565b6106ca565b60405161024091906119c2565b60405180910390f35b610263600480360381019061025e9190611b28565b6106f9565b005b34801561027157600080fd5b5061027a610811565b6040516102879190611ba4565b60405180910390f35b34801561029c57600080fd5b506102a5610816565b6040516102b29190611a55565b60405180910390f35b3480156102c757600080fd5b506102e260048036038101906102dd9190611967565b610821565b6040516102ef91906119c2565b60405180910390f35b34801561030457600080fd5b5061030d610858565b005b34801561031b57600080fd5b5061032461086a565b6040516103319190611bce565b60405180910390f35b34801561034657600080fd5b5061034f610884565b60405161035c91906119c2565b60405180910390f35b34801561037157600080fd5b5061038c60048036038101906103879190611be9565b61089b565b6040516103999190611a55565b60405180910390f35b3480156103ae57600080fd5b506103b76108e3565b005b3480156103c557600080fd5b506103e060048036038101906103db9190611c42565b6108f7565b005b3480156103ee57600080fd5b5061040960048036038101906104049190611be9565b61095a565b60405161041691906119c2565b60405180910390f35b34801561042b57600080fd5b506104346109b0565b005b34801561044257600080fd5b5061044b6109c2565b6040516104589190611c91565b60405180910390f35b34801561046d57600080fd5b506104766109ec565b604051610483919061189d565b60405180910390f35b34801561049857600080fd5b506104b360048036038101906104ae9190611967565b610a7e565b6040516104c091906119c2565b60405180910390f35b3480156104d557600080fd5b506104f060048036038101906104eb9190611967565b610af5565b6040516104fd91906119c2565b60405180910390f35b34801561051257600080fd5b5061052d60048036038101906105289190611ddc565b610b18565b005b34801561053b57600080fd5b5061055660048036038101906105519190611e4b565b610bc1565b6040516105639190611a55565b60405180910390f35b34801561057857600080fd5b50610593600480360381019061058e9190611be9565b610c48565b005b6060600380546105a490611eba565b80601f01602080910402602001604051908101604052809291908181526020018280546105d090611eba565b801561061d5780601f106105f25761010080835404028352916020019161061d565b820191906000526020600020905b81548152906001019060200180831161060057829003601f168201915b5050505050905090565b600080610632610ccb565b905061063f818585610cd3565b600191505092915050565b610652610e9c565b60008163ffffffff16101561069c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161069390611f37565b60405180910390fd5b80600560156101000a81548163ffffffff021916908363ffffffff16021790555050565b6000600254905090565b6000806106d5610ccb565b90506106e2858285610f1a565b6106ed858585610fa6565b60019150509392505050565b600560159054906101000a900463ffffffff1663ffffffff16341015610754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161074b90611fc9565b60405180910390fd5b61076561075f610ccb565b8461121c565b61076d6109c2565b73ffffffffffffffffffffffffffffffffffffffff166108fc349081150290604051600060405180830381858888f193505050501580156107b2573d6000803e3d6000fd5b506107bb610ccb565b73ffffffffffffffffffffffffffffffffffffffff167fe5aadd65e4d4a654aee8b04b44be1fa1a26deb44951ba912fc6cffd439c2730b83838660405161080493929190612016565b60405180910390a2505050565b600090565b661ff973cafa800081565b60008061082c610ccb565b905061084d81858561083e8589610bc1565b6108489190612077565b610cd3565b600191505092915050565b610860610e9c565b6108686113e9565b565b6000600560159054906101000a900463ffffffff16905090565b6000600560009054906101000a900460ff16905090565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b6108eb610e9c565b6108f5600061144c565b565b6108ff610e9c565b80600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b6000600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050919050565b6109b8610e9c565b6109c0611512565b565b6000600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6060600480546109fb90611eba565b80601f0160208091040260200160405190810160405280929190818152602001828054610a2790611eba565b8015610a745780601f10610a4957610100808354040283529160200191610a74565b820191906000526020600020905b815481529060010190602001808311610a5757829003601f168201915b5050505050905090565b600080610a89610ccb565b90506000610a978286610bc1565b905083811015610adc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ad39061211d565b60405180910390fd5b610ae98286868403610cd3565b60019250505092915050565b600080610b00610ccb565b9050610b0d818585610fa6565b600191505092915050565b610b20610e9c565b661ff973cafa800082610b316106c0565b610b3b9190612077565b10610b7b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b72906121af565b60405180910390fd5b610b858383611575565b7f2b1520a218b88043d694007a5f30f20e6682a0723fdc417401eedd86b09000f081604051610bb4919061189d565b60405180910390a1505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b610c50610e9c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610cbf576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cb690612241565b60405180910390fd5b610cc88161144c565b50565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610d42576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d39906122d3565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610db1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610da890612365565b60405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92583604051610e8f9190611a55565b60405180910390a3505050565b610ea4610ccb565b73ffffffffffffffffffffffffffffffffffffffff16610ec26109c2565b73ffffffffffffffffffffffffffffffffffffffff1614610f18576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f0f906123d1565b60405180910390fd5b565b6000610f268484610bc1565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610fa05781811015610f92576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f899061243d565b60405180910390fd5b610f9f8484848403610cd3565b5b50505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603611015576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161100c906124cf565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603611084576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161107b90612561565b60405180910390fd5b61108f8383836116cb565b60008060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015611115576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161110c906125f3565b60405180910390fd5b8181036000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040516112039190611a55565b60405180910390a3611216848484611770565b50505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160361128b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161128290612685565b60405180910390fd5b611297826000836116cb565b60008060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508181101561131d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161131490612717565b60405180910390fd5b8181036000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190555081600260008282540392505081905550600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040516113d09190611a55565b60405180910390a36113e483600084611770565b505050565b6113f1611775565b6000600560006101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa611435610ccb565b6040516114429190611c91565b60405180910390a1565b6000600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b61151a6117be565b6001600560006101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861155e610ccb565b60405161156b9190611c91565b60405180910390a1565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036115e4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115db90612783565b60405180910390fd5b6115f0600083836116cb565b80600260008282546116029190612077565b92505081905550806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516116b39190611a55565b60405180910390a36116c760008383611770565b5050565b6116d36117be565b600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615611760576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161175790612815565b60405180910390fd5b61176b838383611808565b505050565b505050565b61177d610884565b6117bc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117b390612881565b60405180910390fd5b565b6117c6610884565b15611806576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117fd906128ed565b60405180910390fd5b565b505050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561184757808201518184015260208101905061182c565b60008484015250505050565b6000601f19601f8301169050919050565b600061186f8261180d565b6118798185611818565b9350611889818560208601611829565b61189281611853565b840191505092915050565b600060208201905081810360008301526118b78184611864565b905092915050565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006118fe826118d3565b9050919050565b61190e816118f3565b811461191957600080fd5b50565b60008135905061192b81611905565b92915050565b6000819050919050565b61194481611931565b811461194f57600080fd5b50565b6000813590506119618161193b565b92915050565b6000806040838503121561197e5761197d6118c9565b5b600061198c8582860161191c565b925050602061199d85828601611952565b9150509250929050565b60008115159050919050565b6119bc816119a7565b82525050565b60006020820190506119d760008301846119b3565b92915050565b600063ffffffff82169050919050565b6119f6816119dd565b8114611a0157600080fd5b50565b600081359050611a13816119ed565b92915050565b600060208284031215611a2f57611a2e6118c9565b5b6000611a3d84828501611a04565b91505092915050565b611a4f81611931565b82525050565b6000602082019050611a6a6000830184611a46565b92915050565b600080600060608486031215611a8957611a886118c9565b5b6000611a978682870161191c565b9350506020611aa88682870161191c565b9250506040611ab986828701611952565b9150509250925092565b600080fd5b600080fd5b600080fd5b60008083601f840112611ae857611ae7611ac3565b5b8235905067ffffffffffffffff811115611b0557611b04611ac8565b5b602083019150836001820283011115611b2157611b20611acd565b5b9250929050565b600080600060408486031215611b4157611b406118c9565b5b6000611b4f86828701611952565b935050602084013567ffffffffffffffff811115611b7057611b6f6118ce565b5b611b7c86828701611ad2565b92509250509250925092565b600060ff82169050919050565b611b9e81611b88565b82525050565b6000602082019050611bb96000830184611b95565b92915050565b611bc8816119dd565b82525050565b6000602082019050611be36000830184611bbf565b92915050565b600060208284031215611bff57611bfe6118c9565b5b6000611c0d8482850161191c565b91505092915050565b611c1f816119a7565b8114611c2a57600080fd5b50565b600081359050611c3c81611c16565b92915050565b60008060408385031215611c5957611c586118c9565b5b6000611c678582860161191c565b9250506020611c7885828601611c2d565b9150509250929050565b611c8b816118f3565b82525050565b6000602082019050611ca66000830184611c82565b92915050565b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b611ce982611853565b810181811067ffffffffffffffff82111715611d0857611d07611cb1565b5b80604052505050565b6000611d1b6118bf565b9050611d278282611ce0565b919050565b600067ffffffffffffffff821115611d4757611d46611cb1565b5b611d5082611853565b9050602081019050919050565b82818337600083830152505050565b6000611d7f611d7a84611d2c565b611d11565b905082815260208101848484011115611d9b57611d9a611cac565b5b611da6848285611d5d565b509392505050565b600082601f830112611dc357611dc2611ac3565b5b8135611dd3848260208601611d6c565b91505092915050565b600080600060608486031215611df557611df46118c9565b5b6000611e038682870161191c565b9350506020611e1486828701611952565b925050604084013567ffffffffffffffff811115611e3557611e346118ce565b5b611e4186828701611dae565b9150509250925092565b60008060408385031215611e6257611e616118c9565b5b6000611e708582860161191c565b9250506020611e818582860161191c565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680611ed257607f821691505b602082108103611ee557611ee4611e8b565b5b50919050565b7f6275726e20666565732063616e6e6f74206265206e6567617469766500000000600082015250565b6000611f21601c83611818565b9150611f2c82611eeb565b602082019050919050565b60006020820190508181036000830152611f5081611f14565b9050919050565b7f7472616e73616374696f6e2076616c756520646f6573206e6f7420636f76657260008201527f20746865204d4c5820756e777261702066656573000000000000000000000000602082015250565b6000611fb3603483611818565b9150611fbe82611f57565b604082019050919050565b60006020820190508181036000830152611fe281611fa6565b9050919050565b6000611ff58385611818565b9350612002838584611d5d565b61200b83611853565b840190509392505050565b60006040820190508181036000830152612031818587611fe9565b90506120406020830184611a46565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061208282611931565b915061208d83611931565b92508282019050808211156120a5576120a4612048565b5b92915050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760008201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b6000612107602583611818565b9150612112826120ab565b604082019050919050565b60006020820190508181036000830152612136816120fa565b9050919050565b7f746f74616c20737570706c792063616e6e6f742062652067726561746572207460008201527f68616e2039653135000000000000000000000000000000000000000000000000602082015250565b6000612199602883611818565b91506121a48261213d565b604082019050919050565b600060208201905081810360008301526121c88161218c565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b600061222b602683611818565b9150612236826121cf565b604082019050919050565b6000602082019050818103600083015261225a8161221e565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b60006122bd602483611818565b91506122c882612261565b604082019050919050565b600060208201905081810360008301526122ec816122b0565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f20616464726560008201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b600061234f602283611818565b915061235a826122f3565b604082019050919050565b6000602082019050818103600083015261237e81612342565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b60006123bb602083611818565b91506123c682612385565b602082019050919050565b600060208201905081810360008301526123ea816123ae565b9050919050565b7f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000600082015250565b6000612427601d83611818565b9150612432826123f1565b602082019050919050565b600060208201905081810360008301526124568161241a565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b60006124b9602583611818565b91506124c48261245d565b604082019050919050565b600060208201905081810360008301526124e8816124ac565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b600061254b602383611818565b9150612556826124ef565b604082019050919050565b6000602082019050818103600083015261257a8161253e565b9050919050565b7f45524332303a207472616e7366657220616d6f756e742065786365656473206260008201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b60006125dd602683611818565b91506125e882612581565b604082019050919050565b6000602082019050818103600083015261260c816125d0565b9050919050565b7f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360008201527f7300000000000000000000000000000000000000000000000000000000000000602082015250565b600061266f602183611818565b915061267a82612613565b604082019050919050565b6000602082019050818103600083015261269e81612662565b9050919050565b7f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60008201527f6365000000000000000000000000000000000000000000000000000000000000602082015250565b6000612701602283611818565b915061270c826126a5565b604082019050919050565b60006020820190508181036000830152612730816126f4565b9050919050565b7f45524332303a206d696e7420746f20746865207a65726f206164647265737300600082015250565b600061276d601f83611818565b915061277882612737565b602082019050919050565b6000602082019050818103600083015261279c81612760565b9050919050565b7f616464726573732066726f6d20697320696e20746865206c697374206f66207660008201527f657374696e672061646472657373657300000000000000000000000000000000602082015250565b60006127ff603083611818565b915061280a826127a3565b604082019050919050565b6000602082019050818103600083015261282e816127f2565b9050919050565b7f5061757361626c653a206e6f7420706175736564000000000000000000000000600082015250565b600061286b601483611818565b915061287682612835565b602082019050919050565b6000602082019050818103600083015261289a8161285e565b9050919050565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b60006128d7601083611818565b91506128e2826128a1565b602082019050919050565b60006020820190508181036000830152612906816128ca565b905091905056fea26469706673582212208f2ac657bb6103bb2930b08add291d36d900bceb3bc6a59fe5809ec277cae2fd64736f6c63430008110033

Verified Source Code Full Match

Compiler: v0.8.17+commit.8df45f5f EVM: london Optimization: No
WrappedMillix.sol 105 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.9;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/security/Pausable.sol";
import "@openzeppelin/contracts/access/Ownable.sol";

interface IMillixBridge {
    /**
     * @dev Emitted when `amount` tokens are moved from account (`from`) to millix network address (`to`)
     */
    event UnwrapMillix(address indexed from, string to, uint256 amount);

    /**
     * @dev Emitted when `amount` tokens are minted from millix transaction (`txhash`)
     */
    event MintWrappedMillix(string txhash);

    function unwrap(uint256 amount, string calldata to) external payable;
}

/// @custom:security-contact [email protected]
contract WrappedMillix is ERC20, Pausable, Ownable, IMillixBridge {
    uint256 public constant MAX_SUPPLY = 9 * 10**15;
    uint32 private _burnFees = 662780;
    mapping(address => bool) private _vesting;

    constructor() ERC20("WrappedMillix", "WMLX") {}

    function decimals() public view virtual override returns (uint8) {
        return 0;
    }

    function pause() public onlyOwner {
        _pause();
    }

    function unpause() public onlyOwner {
        _unpause();
    }

    function mint(
        address to,
        uint256 amount,
        string memory txhash
    ) public onlyOwner {
        require(
            totalSupply() + amount < MAX_SUPPLY,
            "total supply cannot be greater than 9e15"
        );
        _mint(to, amount);
        emit MintWrappedMillix(txhash);
    }

    /**
     * @dev Set current burn fees.
     */
    function setBurnFees(uint32 fees) public onlyOwner {
        require(fees >= 0, "burn fees cannot be negative");
        _burnFees = fees;
    }

    /**
     * @dev Returns current burn fees.
     */
    function burnFees() public view virtual returns (uint32) {
        return _burnFees;
    }

    /**
     * @dev Returns true if an address is vested
     */
    function isVested(address addr) public view returns (bool) {
        return _vesting[addr];
    }

    /**
     * @dev Add address to vesting list
     */
    function setVestingState(address addr, bool vested) public onlyOwner {
        _vesting[addr] = vested;
    }

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal override whenNotPaused {
        require(
            !_vesting[from],
            "address from is in the list of vesting addresses"
        );
        super._beforeTokenTransfer(from, to, amount);
    }

    function unwrap(uint256 amount, string calldata to) public payable {
        require(
            msg.value >= _burnFees,
            "transaction value does not cover the MLX unwrap fees"
        );
        _burn(_msgSender(), amount);
        payable(owner()).transfer(msg.value);
        emit UnwrapMillix(_msgSender(), to, amount);
    }
}
Context.sol 24 lines
// SPDX-License-Identifier: MIT
// 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;
    }
}
Ownable.sol 83 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @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 {
        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 {
        _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 {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _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);
    }
}
Pausable.sol 105 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @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());
    }
}
ERC20.sol 389 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol)

pragma solidity ^0.8.0;

import "./IERC20.sol";
import "./extensions/IERC20Metadata.sol";
import "../../utils/Context.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin Contracts guidelines: functions revert
 * instead returning `false` on failure. This behavior is nonetheless
 * conventional and does not conflict with the expectations of ERC20
 * applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20, IERC20Metadata {
    mapping(address => uint256) private _balances;

    mapping(address => mapping(address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @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_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @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 18;
    }

    /**
     * @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:
     *
     * - `to` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address to, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _transfer(owner, to, 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}.
     *
     * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on
     * `transferFrom`. This is semantically equivalent to an infinite approval.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        address owner = _msgSender();
        _approve(owner, 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}.
     *
     * NOTE: Does not update the allowance if the current allowance
     * is the maximum `uint256`.
     *
     * Requirements:
     *
     * - `from` and `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     * - the caller must have allowance for ``from``'s tokens of at least
     * `amount`.
     */
    function transferFrom(
        address from,
        address to,
        uint256 amount
    ) public virtual override returns (bool) {
        address spender = _msgSender();
        _spendAllowance(from, spender, amount);
        _transfer(from, to, amount);
        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) {
        address owner = _msgSender();
        _approve(owner, spender, allowance(owner, spender) + 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) {
        address owner = _msgSender();
        uint256 currentAllowance = allowance(owner, spender);
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        unchecked {
            _approve(owner, spender, currentAllowance - subtractedValue);
        }

        return true;
    }

    /**
     * @dev Moves `amount` of tokens from `from` to `to`.
     *
     * This 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:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `from` must have a balance of at least `amount`.
     */
    function _transfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {
        require(from != address(0), "ERC20: transfer from the zero address");
        require(to != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(from, to, amount);

        uint256 fromBalance = _balances[from];
        require(fromBalance >= amount, "ERC20: transfer amount exceeds balance");
        unchecked {
            _balances[from] = fromBalance - amount;
            // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by
            // decrementing then incrementing.
            _balances[to] += amount;
        }

        emit Transfer(from, to, amount);

        _afterTokenTransfer(from, to, 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: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        unchecked {
            // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above.
            _balances[account] += amount;
        }
        emit Transfer(address(0), account, amount);

        _afterTokenTransfer(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);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
            // Overflow not possible: amount <= accountBalance <= totalSupply.
            _totalSupply -= amount;
        }

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(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);
    }

    /**
     * @dev Updates `owner` s allowance for `spender` based on spent `amount`.
     *
     * Does not update the allowance amount in case of infinite allowance.
     * Revert if not enough allowance is available.
     *
     * Might emit an {Approval} event.
     */
    function _spendAllowance(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        uint256 currentAllowance = allowance(owner, spender);
        if (currentAllowance != type(uint256).max) {
            require(currentAllowance >= amount, "ERC20: insufficient allowance");
            unchecked {
                _approve(owner, spender, currentAllowance - amount);
            }
        }
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens 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 amount
    ) 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, `amount` of ``from``'s tokens
     * has been transferred to `to`.
     * - when `from` is zero, `amount` tokens have been minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens have been 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 _afterTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {}
}
IERC20.sol 82 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @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 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 `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, 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 `from` to `to` 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 from,
        address to,
        uint256 amount
    ) external returns (bool);
}
IERC20Metadata.sol 28 lines
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";

/**
 * @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);
}

Read Contract

MAX_SUPPLY 0x32cb6b0c → uint256
allowance 0xdd62ed3e → uint256
balanceOf 0x70a08231 → uint256
burnFees 0x40f6ac31 → uint32
decimals 0x313ce567 → uint8
isVested 0x760a2e8a → bool
name 0x06fdde03 → string
owner 0x8da5cb5b → address
paused 0x5c975abb → bool
symbol 0x95d89b41 → string
totalSupply 0x18160ddd → uint256

Write Contract 13 functions

These functions modify contract state and require a wallet transaction to execute.

approve 0x095ea7b3
address spender
uint256 amount
returns: bool
decreaseAllowance 0xa457c2d7
address spender
uint256 subtractedValue
returns: bool
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
mint 0xd3fc9864
address to
uint256 amount
string txhash
pause 0x8456cb59
No parameters
renounceOwnership 0x715018a6
No parameters
setBurnFees 0x0fae7eb6
uint32 fees
setVestingState 0x721e602a
address addr
bool vested
transfer 0xa9059cbb
address to
uint256 amount
returns: bool
transferFrom 0x23b872dd
address from
address to
uint256 amount
returns: bool
transferOwnership 0xf2fde38b
address newOwner
unpause 0x3f4ba83a
No parameters
unwrap 0x307cf63f
uint256 amount
string to

Recent Transactions

No transactions found for this address