Address Contract Partially Verified
Address
0x896d8a30C32eAd64f2e1195C2C8E0932Be7Dc20B
Balance
0.001657 ETH ($3.29)
Nonce
1
Code Size
10275 bytes
Creator
0xb69Dd1e9...3E13 at tx 0x84732af3...30b49d
Indexed Transactions
0
Contract Bytecode
10275 bytes
0x6080604052600436106102235760003560e01c80638f32d59b1161012e578063bfca6c11116100ab578063e29e4fbc1161006f578063e29e4fbc146106ff578063e99d286614610735578063f2fde38b14610768578063f446c1d01461079b578063f73a12e1146107b05761022a565b8063bfca6c111461062f578063c0324c7714610662578063c67e2b6014610692578063cf59d563146106d5578063ddca3f43146106ea5761022a565b8063ae2e933b116100f2578063ae2e933b146105b1578063b6b55f25146105c6578063b8b89e1b146105f0578063bc063e1a14610605578063be2b6ce11461061a5761022a565b80638f32d59b146105335780639e166bdf14610548578063aa5f7e261461055d578063aaf5eb6814610587578063adfaab121461059c5761022a565b80635c532c5d116101bc5780636d9a640a116101805780636d9a640a1461046c5780636e9fe670146104ab5780637bd2bea7146104c05780637cd44272146104d55780638da5cb5b1461051e5761022a565b80635c532c5d1461037c5780635da937c4146103915780636b926206146103a65780636cf69811146103d95780636d5ccc80146104395761022a565b8062f714ce1461022f57806304a764c01461026a578063068d5911146102a65780630fdb11cf146102e25780632bbca157146102f75780633078fff51461030c578063396984151461033d5780634426ebd0146103525780634641257d146103675761022a565b3661022a57005b600080fd5b34801561023b57600080fd5b506102686004803603604081101561025257600080fd5b50803590602001356001600160a01b03166107c5565b005b34801561027657600080fd5b506102946004803603602081101561028d57600080fd5b503561099b565b60408051918252519081900360200190f35b3480156102b257600080fd5b50610294600480360360808110156102c957600080fd5b5080359060208101359060408101359060600135610aff565b3480156102ee57600080fd5b50610294610c7e565b34801561030357600080fd5b50610294610e13565b34801561031857600080fd5b50610321610e37565b604080516001600160a01b039092168252519081900360200190f35b34801561034957600080fd5b50610294610e5b565b34801561035e57600080fd5b50610321610e60565b34801561037357600080fd5b50610268610e84565b34801561038857600080fd5b50610294610f05565b34801561039d57600080fd5b50610321610f0b565b3480156103b257600080fd5b50610268600480360360208110156103c957600080fd5b50356001600160a01b0316610f2f565b610425600480360360c08110156103ef57600080fd5b506001600160a01b038135811691602081013591604082013581169160608101359091169060808101359060a001351515610fd8565b604080519115158252519081900360200190f35b34801561044557600080fd5b506102686004803603602081101561045c57600080fd5b50356001600160a01b0316610ff3565b34801561047857600080fd5b506102946004803603606081101561048f57600080fd5b50803590602081013590604001356001600160a01b031661113c565b3480156104b757600080fd5b506102946114c4565b3480156104cc57600080fd5b506103216114c9565b3480156104e157600080fd5b50610294600480360360808110156104f857600080fd5b506001600160a01b038135811691602081013590911690604081013590606001356114ed565b34801561052a57600080fd5b50610321611527565b34801561053f57600080fd5b50610425611536565b34801561055457600080fd5b50610321611547565b34801561056957600080fd5b506102686004803603602081101561058057600080fd5b5035611556565b34801561059357600080fd5b50610294611611565b3480156105a857600080fd5b5061032161161d565b3480156105bd57600080fd5b5061032161162c565b3480156105d257600080fd5b50610268600480360360208110156105e957600080fd5b5035611650565b3480156105fc57600080fd5b50610294611892565b34801561061157600080fd5b506102946118b6565b34801561062657600080fd5b506103216118bb565b34801561063b57600080fd5b506106446118ca565b60408051938452602084019290925282820152519081900360600190f35b34801561066e57600080fd5b506102686004803603604081101561068557600080fd5b5080359060200135611a88565b34801561069e57600080fd5b506106bc600480360360208110156106b557600080fd5b5035611c06565b6040805192835260208301919091528051918290030190f35b3480156106e157600080fd5b50610321611ea5565b3480156106f657600080fd5b50610294611ec9565b34801561070b57600080fd5b506102946004803603606081101561072257600080fd5b5080359060208101359060400135611ecf565b34801561074157600080fd5b506102686004803603602081101561075857600080fd5b50356001600160a01b031661204d565b34801561077457600080fd5b506102686004803603602081101561078b57600080fd5b50356001600160a01b031661240a565b3480156107a757600080fd5b506102946124a2565b3480156107bc57600080fd5b506103216124a8565b6004546001600160a01b03163314610824576040805162461bcd60e51b815260206004820152601f60248201527f42414d4d3a2063616c6c6572206973206e6f742074686520636869636b656e00604482015290519081900360640190fd5b7f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b0316632e54bf95836040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b15801561088a57600080fd5b505af115801561089e573d6000803e3d6000fd5b505050506000821115610958577f0000000000000000000000005f98805a4e8be255a32880fdec7f6728c6568ba06001600160a01b031663a9059cbb82846040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561092b57600080fd5b505af115801561093f573d6000803e3d6000fd5b505050506040513d602081101561095557600080fd5b50505b6040805183815290516001600160a01b038316917f98824d89d47225910d3e61aa38b640d29d58b43e2dc47b4d986a588c88e0a2a8919081900360200190a25050565b60008060007f0000000000000000000000003d7ae7e594f2f2091ad8798313450130d0aba3a06001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b1580156109f957600080fd5b505afa158015610a0d573d6000803e3d6000fd5b505050506040513d6020811015610a2357600080fd5b505160408051633fabe5a360e21b8152905160ff90921693506000916001600160a01b037f0000000000000000000000003d7ae7e594f2f2091ad8798313450130d0aba3a0169163feaf968c9160048083019260a0929190829003018186803b158015610a8f57600080fd5b505afa158015610aa3573d6000803e3d6000fd5b505050506040513d60a0811015610ab957600080fd5b50602001519150819050600a83900a811115610af357600a83900a610ae4868463ffffffff6124cc16565b81610aeb57fe5b049350610af7565b8493505b505050919050565b600080610b0d858585611ecf565b90506000610b326002610b26898963ffffffff61252e16565b9063ffffffff6124cc16565b610b42838063ffffffff6124cc16565b81610b4957fe5b049050610b5d84600463ffffffff6124cc16565b610b6d828463ffffffff6124cc16565b81610b7457fe5b0490506000610bb2610b8d86600263ffffffff6124cc16565b8481610b9557fe5b04610ba68a8a63ffffffff61252e16565b9063ffffffff61252e16565b9050600083815b60ff811015610c5a5790915081906000610bdd86610ba6858063ffffffff6124cc16565b90506000610c0688610bfa88610ba688600263ffffffff6124cc16565b9063ffffffff61258816565b9050808281610c1157fe5b049350610c2585600163ffffffff61252e16565b8411158015610c445750610c4084600163ffffffff61252e16565b8511155b15610c50575050610c5a565b5050600101610bb9565b50610c706001610bfa8a8463ffffffff61258816565b9a9950505050505050505050565b6000806000807f0000000000000000000000005f4ec3df9cbd43714fe2740f5e3616155c5b84196001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015610cdd57600080fd5b505afa925050508015610d0257506040513d6020811015610cfd57600080fd5b505160015b610d125760009350505050610e10565b60ff1692507f0000000000000000000000005f4ec3df9cbd43714fe2740f5e3616155c5b84196001600160a01b031663feaf968c6040518163ffffffff1660e01b815260040160a06040518083038186803b158015610d7057600080fd5b505afa925050508015610db257506040513d60a0811015610d9057600080fd5b5080516020820151604083015160608401516080909401519293919290919060015b610dc25760009350505050610e10565b5091945090925050504281610e10011015610de35760009350505050610e10565b600a83900a80610e0184670de0b6b3a764000063ffffffff6124cc16565b81610e0857fe5b049450505050505b90565b7f0000000000000000000000000000000000000000000000000000000000093a8081565b7f0000000000000000000000005f4ec3df9cbd43714fe2740f5e3616155c5b841981565b60c881565b7f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb81565b7f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b0316632e54bf9560006040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b158015610eeb57600080fd5b505af1158015610eff573d6000803e3d6000fd5b50505050565b60025481565b7f000000000000000000000000000000000000000000000000000000000000000081565b610f37611536565b610f76576040805162461bcd60e51b815260206004820181905260248201526000805160206127ce833981519152604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b03831690811790915542600281905560408051928352602083019190915280517f51c2376ab22964da251ae3c11975a2242308e1b1e6a01e7e68b19bae15e47fc89281900390910190a150565b600080610fe78760008761113c565b11979650505050505050565b610ffb611536565b61103a576040805162461bcd60e51b815260206004820181905260248201526000805160206127ce833981519152604482015290519081900360640190fd5b6001600160a01b038116611090576040805162461bcd60e51b8152602060048201526018602482015277736574436869636b656e3a206e756c6c206164647265737360401b604482015290519081900360640190fd5b6004546001600160a01b0316156110e8576040805162461bcd60e51b81526020600482015260176024820152761cd95d10da1a58dad95b8e88185b1c9958591e481cd95d604a1b604482015290519081900360640190fd5b600480546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f8866ab9b1301e4f7714b07d5df7c589700d2cb8d014ed2443521fad9fc0834159181900360200190a150565b600080600061114a86611c06565b9150915084821015611196576040805162461bcd60e51b815260206004820152601060248201526f39bbb0b81d103637bb903932ba3ab93760811b604482015290519081900360640190fd5b604080516323b872dd60e01b81523360048201523060248201526044810188905290516001600160a01b037f0000000000000000000000005f98805a4e8be255a32880fdec7f6728c6568ba016916323b872dd9160648083019260209291908290030181600087803b15801561120b57600080fd5b505af115801561121f573d6000803e3d6000fd5b505050506040513d602081101561123557600080fd5b50506001600160a01b037f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb16635f788d65611276888463ffffffff61258816565b7f00000000000000000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b815260040180838152602001826001600160a01b03166001600160a01b0316815260200192505050600060405180830381600087803b1580156112e657600080fd5b505af11580156112fa573d6000803e3d6000fd5b5050505060008111156113d4577f0000000000000000000000005f98805a4e8be255a32880fdec7f6728c6568ba06001600160a01b031663a9059cbb7f0000000000000000000000007095f0b91a1010c11820b4e263927835a4cf52c9836040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b1580156113a757600080fd5b505af11580156113bb573d6000803e3d6000fd5b505050506040513d60208110156113d157600080fd5b50505b6040516000906001600160a01b0386169084908381818185875af1925050503d806000811461141f576040519150601f19603f3d011682016040523d82523d6000602084013e611424565b606091505b5050905080611475576040805162461bcd60e51b81526020600482015260186024820152771cddd85c0e881cd95b991a5b99c81155120819985a5b195960421b604482015290519081900360640190fd5b60408051888152602081018590524281830152905133917fc690f9b0d999c94570f07e58078c65fc21a4400d416daf05414dc565eb6a1342919081900360600190a250909150505b9392505050565b601481565b7f0000000000000000000000006dea81c8171d0ba574754ef6f8b412f2ed88c54d81565b6000806114f984611c06565b5090508361151582670de0b6b3a764000063ffffffff6124cc16565b8161151c57fe5b049695505050505050565b6000546001600160a01b031690565b6000546001600160a01b0316331490565b6004546001600160a01b031681565b7f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b0316635f788d65827f00000000000000000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b815260040180838152602001826001600160a01b03166001600160a01b0316815260200192505050600060405180830381600087803b1580156115f657600080fd5b505af115801561160a573d6000803e3d6000fd5b5050505050565b670de0b6b3a764000081565b6003546001600160a01b031681565b7f0000000000000000000000007095f0b91a1010c11820b4e263927835a4cf52c981565b6004546001600160a01b031633146116af576040805162461bcd60e51b815260206004820152601f60248201527f42414d4d3a2063616c6c6572206973206e6f742074686520636869636b656e00604482015290519081900360640190fd5b604080516323b872dd60e01b81523360048201523060248201526044810183905290516001600160a01b037f0000000000000000000000005f98805a4e8be255a32880fdec7f6728c6568ba016916323b872dd9160648083019260209291908290030181600087803b15801561172457600080fd5b505af1158015611738573d6000803e3d6000fd5b505050506040513d602081101561174e57600080fd5b50516117a1576040805162461bcd60e51b815260206004820152601c60248201527f6465706f7369743a207472616e7366657246726f6d206661696c656400000000604482015290519081900360640190fd5b7f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b0316635f788d65827f00000000000000000000000000000000000000000000000000000000000000006040518363ffffffff1660e01b815260040180838152602001826001600160a01b03166001600160a01b0316815260200192505050600060405180830381600087803b15801561184157600080fd5b505af1158015611855573d6000803e3d6000fd5b50506040805184815290513393507f35db3d768e685509e031bae369804ca7dc6656af739e079f1d3312cadc7b19d892509081900360200190a250565b7f000000000000000000000000000000000000000000000000000000000000025881565b606481565b6001546001600160a01b031681565b60008060007f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b0316631cdc4700306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561194557600080fd5b505afa158015611959573d6000803e3d6000fd5b505050506040513d602081101561196f57600080fd5b50516040805163389e92a560e01b81523060048201529051919350600091611a1b9147916001600160a01b037f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb169163389e92a5916024808301926020929190829003018186803b1580156119e357600080fd5b505afa1580156119f7573d6000803e3d6000fd5b505050506040513d6020811015611a0d57600080fd5b50519063ffffffff61252e16565b90506000611a27610c7e565b905080158015611a375750600082115b15611a4b575060009350839150611a839050565b670de0b6b3a7640000611a64838363ffffffff6124cc16565b81611a6b57fe5b049250611a7e848463ffffffff61252e16565b945050505b909192565b611a90611536565b611acf576040805162461bcd60e51b815260206004820181905260248201526000805160206127ce833981519152604482015290519081900360640190fd5b6064811115611b21576040805162461bcd60e51b8152602060048201526019602482015278736574506172616d733a2066656520697320746f6f2062696760381b604482015290519081900360640190fd5b6014821015611b70576040805162461bcd60e51b81526020600482015260166024820152751cd95d14185c985b5cce8810481d1bdbc81cdb585b1b60521b604482015290519081900360640190fd5b60c8821115611bbd576040805162461bcd60e51b8152602060048201526014602482015273736574506172616d733a204120746f6f2062696760601b604482015290519081900360640190fd5b60058190556006829055604080518381526020810183905281517f3d5244a9b2f415f6ebc57f5d8ca058f82b1561d1cbf0c010ab3e4a8773c1f6b5929181900390910190a15050565b6000806000611ced600460009054906101000a90046001600160a01b03166001600160a01b03166366462ab16040518163ffffffff1660e01b815260040160206040518083038186803b158015611c5c57600080fd5b505afa158015611c70573d6000803e3d6000fd5b505050506040513d6020811015611c8657600080fd5b505160408051621cdc4760e81b815230600482015290516001600160a01b037f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb1691631cdc4700916024808301926020929190829003018186803b1580156119e357600080fd5b90506000611d6b477f00000000000000000000000066017d22b0f8556afdd19fc67041899eb65a21bb6001600160a01b031663389e92a5306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156119e357600080fd5b90506000611d77610c7e565b905080611d8e575060009350839250611ea0915050565b6000670de0b6b3a7640000611da9848463ffffffff6124cc16565b81611db057fe5b0490506000611dff83611dd18a670de0b6b3a764000063ffffffff6124cc16565b81611dd857fe5b047f00000000000000000000000000000000000000000000000000000000000002586125ca565b905087856000611e26611e1986600263ffffffff6124cc16565b899063ffffffff61252e16565b90506000611e38848484600654610aff565b9050600087611e5583670de0b6b3a764000063ffffffff6124cc16565b81611e5c57fe5b049050611e688161099b565b905080891015611e755750875b80861015611e805750845b809b50611e938d610bfa8f6005546125ca565b9a50505050505050505050505b915091565b7f0000000000000000000000005f98805a4e8be255a32880fdec7f6728c6568ba081565b60055481565b600083158015611edd575082155b15611eea575060006114bd565b6000611efc858563ffffffff61252e16565b905060005b60ff8110156120445781611f216001610ba689600263ffffffff6124cc16565b611f31828563ffffffff6124cc16565b81611f3857fe5b049050611f516001610ba688600263ffffffff6124cc16565b611f61828563ffffffff6124cc16565b81611f6857fe5b049050826000611faa82610b26611f8686600263ffffffff6124cc16565b610ba6611f998e8e63ffffffff61252e16565b610b268d600263ffffffff6124cc16565b90506000611fc886610b266001610bfa8c600263ffffffff6124cc16565b9050611feb611fde85600363ffffffff6124cc16565b829063ffffffff61252e16565b8281611ff357fe5b04955061200783600163ffffffff61252e16565b8611158015612026575061202286600163ffffffff61252e16565b8311155b156120345750505050612044565b505060019092019150611f019050565b50949350505050565b612055611536565b612094576040805162461bcd60e51b815260206004820181905260248201526000805160206127ce833981519152604482015290519081900360640190fd5b6001600160a01b0381166120e6576040805162461bcd60e51b815260206004820152601460248201527373657453656c6c65723a2030206164647265737360601b604482015290519081900360640190fd5b6003546001600160a01b0316156122b7577f0000000000000000000000000000000000000000000000000000000000093a8060025401421015612167576040805162461bcd60e51b815260206004820152601460248201527373657453656c6c65723a20746f6f206561726c7960601b604482015290519081900360640190fd5b6001546001600160a01b038281169116146121c0576040805162461bcd60e51b815260206004820152601460248201527373657453656c6c65723a20212070656e64696e6760601b604482015290519081900360640190fd5b6003546040805163095ea7b360e01b81526001600160a01b03928316600482015260006024820181905291517f0000000000000000000000006dea81c8171d0ba574754ef6f8b412f2ed88c54d9093169263095ea7b392604480840193602093929083900390910190829087803b15801561223a57600080fd5b505af115801561224e573d6000803e3d6000fd5b505050506040513d602081101561226457600080fd5b50516122b7576040805162461bcd60e51b815260206004820152601d60248201527f73657453656c6c65723a203020616c6c6f77616e6365206661696c6564000000604482015290519081900360640190fd5b7f0000000000000000000000006dea81c8171d0ba574754ef6f8b412f2ed88c54d6001600160a01b031663095ea7b3826000196040518363ffffffff1660e01b815260040180836001600160a01b03166001600160a01b0316815260200182815260200192505050602060405180830381600087803b15801561233957600080fd5b505af115801561234d573d6000803e3d6000fd5b505050506040513d602081101561236357600080fd5b50516123b6576040805162461bcd60e51b815260206004820152601f60248201527f73657453656c6c65723a2067656d20616c6c6f77616e6365206661696c656400604482015290519081900360640190fd5b600380546001600160a01b0383166001600160a01b0319909116811790915560408051918252517fc327e3b018c0d052a165f61f521694d76a3824944df1c6f740258aa1ee1a21cc9181900360200190a150565b612412611536565b612451576040805162461bcd60e51b815260206004820181905260248201526000805160206127ce833981519152604482015290519081900360640190fd5b6001600160a01b0381166124965760405162461bcd60e51b81526004018080602001828103825260268152602001806127876026913960400191505060405180910390fd5b61249f8161269f565b50565b60065481565b7f0000000000000000000000003d7ae7e594f2f2091ad8798313450130d0aba3a081565b6000826124db57506000612528565b828202828482816124e857fe5b04146125255760405162461bcd60e51b81526004018080602001828103825260218152602001806127ad6021913960400191505060405180910390fd5b90505b92915050565b600082820183811015612525576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b600061252583836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506126ef565b6000612710821315612623576040805162461bcd60e51b815260206004820152601a60248201527f7265647563654270733a206270732065786365656473206d6178000000000000604482015290519081900360640190fd5b61270f1982121561267b576040805162461bcd60e51b815260206004820152601a60248201527f7265647563654270733a206270732065786365656473206d696e000000000000604482015290519081900360640190fd5b6127106126908484830163ffffffff6124cc16565b8161269757fe5b049392505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000818484111561277e5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561274357818101518382015260200161272b565b50505050905090810190601f1680156127705780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50505090039056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a2646970667358221220c3d8cea05da49d593fe12c1e768a5a8c2c0b55b40dcc29f8fef868f9874ec9d864736f6c634300060b0033
Verified Source Code Partial Match
Compiler: v0.6.11+commit.5ef660b1
EVM: istanbul
Optimization: Yes (100 runs)
main.sol 4693 lines
// This contract is part of Zellic’s smart contract dataset, which is a collection of publicly available contract code gathered as of March 2023.
/*
B.PROTOCOL TERMS OF USE
=======================
THE TERMS OF USE CONTAINED HEREIN (THESE “TERMS”) GOVERN YOUR USE OF B.PROTOCOL, WHICH IS A DECENTRALIZED PROTOCOL ON THE ETHEREUM BLOCKCHAIN (the “PROTOCOL”) THAT enables a backstop liquidity mechanism FOR DECENTRALIZED LENDING PLATFORMS (“DLPs”).
PLEASE READ THESE TERMS CAREFULLY AT https://github.com/backstop-protocol/Terms-and-Conditions, INCLUDING ALL DISCLAIMERS AND RISK FACTORS, BEFORE USING THE PROTOCOL. BY USING THE PROTOCOL, YOU ARE IRREVOCABLY CONSENTING TO BE BOUND BY THESE TERMS.
IF YOU DO NOT AGREE TO ALL OF THESE TERMS, DO NOT USE THE PROTOCOL. YOUR RIGHT TO USE THE PROTOCOL IS SUBJECT AND DEPENDENT BY YOUR AGREEMENT TO ALL TERMS AND CONDITIONS SET FORTH HEREIN, WHICH AGREEMENT SHALL BE EVIDENCED BY YOUR USE OF THE PROTOCOL.
Minors Prohibited: The Protocol is not directed to individuals under the age of eighteen (18) or the age of majority in your jurisdiction if the age of majority is greater. If you are under the age of eighteen or the age of majority (if greater), you are not authorized to access or use the Protocol. By using the Protocol, you represent and warrant that you are above such age.
License; No Warranties; Limitation of Liability;
(a) The software underlying the Protocol is licensed for use in accordance with the 3-clause BSD License, which can be accessed here: https://opensource.org/licenses/BSD-3-Clause.
(b) THE PROTOCOL IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS", “WITH ALL FAULTS” and “AS AVAILABLE” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
(c) IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
// Sources flattened with hardhat v2.1.1 https://hardhat.org
// File contracts/Interfaces/IBorrowerOperations.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.6.11;
// Common interface for the Trove Manager.
interface IBorrowerOperations {
// --- Events ---
event TroveManagerAddressChanged(address _newTroveManagerAddress);
event ActivePoolAddressChanged(address _activePoolAddress);
event DefaultPoolAddressChanged(address _defaultPoolAddress);
event StabilityPoolAddressChanged(address _stabilityPoolAddress);
event GasPoolAddressChanged(address _gasPoolAddress);
event CollSurplusPoolAddressChanged(address _collSurplusPoolAddress);
event PriceFeedAddressChanged(address _newPriceFeedAddress);
event SortedTrovesAddressChanged(address _sortedTrovesAddress);
event LUSDTokenAddressChanged(address _lusdTokenAddress);
event LQTYStakingAddressChanged(address _lqtyStakingAddress);
event TroveCreated(address indexed _borrower, uint arrayIndex);
event TroveUpdated(address indexed _borrower, uint _debt, uint _coll, uint stake, uint8 operation);
event LUSDBorrowingFeePaid(address indexed _borrower, uint _LUSDFee);
// --- Functions ---
function setAddresses(
address _troveManagerAddress,
address _activePoolAddress,
address _defaultPoolAddress,
address _stabilityPoolAddress,
address _gasPoolAddress,
address _collSurplusPoolAddress,
address _priceFeedAddress,
address _sortedTrovesAddress,
address _lusdTokenAddress,
address _lqtyStakingAddress
) external;
function openTrove(uint _maxFee, uint _LUSDAmount, address _upperHint, address _lowerHint) external payable;
function addColl(address _upperHint, address _lowerHint) external payable;
function moveETHGainToTrove(address _user, address _upperHint, address _lowerHint) external payable;
function withdrawColl(uint _amount, address _upperHint, address _lowerHint) external;
function withdrawLUSD(uint _maxFee, uint _amount, address _upperHint, address _lowerHint) external;
function repayLUSD(uint _amount, address _upperHint, address _lowerHint) external;
function closeTrove() external;
function adjustTrove(uint _maxFee, uint _collWithdrawal, uint _debtChange, bool isDebtIncrease, address _upperHint, address _lowerHint) external payable;
function claimCollateral() external;
function getCompositeDebt(uint _debt) external pure returns (uint);
}
// File contracts/Interfaces/IStabilityPool.sol
// MIT
pragma solidity 0.6.11;
/*
* The Stability Pool holds LUSD tokens deposited by Stability Pool depositors.
*
* When a trove is liquidated, then depending on system conditions, some of its LUSD debt gets offset with
* LUSD in the Stability Pool: that is, the offset debt evaporates, and an equal amount of LUSD tokens in the Stability Pool is burned.
*
* Thus, a liquidation causes each depositor to receive a LUSD loss, in proportion to their deposit as a share of total deposits.
* They also receive an ETH gain, as the ETH collateral of the liquidated trove is distributed among Stability depositors,
* in the same proportion.
*
* When a liquidation occurs, it depletes every deposit by the same fraction: for example, a liquidation that depletes 40%
* of the total LUSD in the Stability Pool, depletes 40% of each deposit.
*
* A deposit that has experienced a series of liquidations is termed a "compounded deposit": each liquidation depletes the deposit,
* multiplying it by some factor in range ]0,1[
*
* Please see the implementation spec in the proof document, which closely follows on from the compounded deposit / ETH gain derivations:
* https://github.com/liquity/liquity/blob/master/papers/Scalable_Reward_Distribution_with_Compounding_Stakes.pdf
*
* --- LQTY ISSUANCE TO STABILITY POOL DEPOSITORS ---
*
* An LQTY issuance event occurs at every deposit operation, and every liquidation.
*
* Each deposit is tagged with the address of the front end through which it was made.
*
* All deposits earn a share of the issued LQTY in proportion to the deposit as a share of total deposits. The LQTY earned
* by a given deposit, is split between the depositor and the front end through which the deposit was made, based on the front end's kickbackRate.
*
* Please see the system Readme for an overview:
* https://github.com/liquity/dev/blob/main/README.md#lqty-issuance-to-stability-providers
*/
interface IStabilityPool {
// --- Events ---
event StabilityPoolETHBalanceUpdated(uint _newBalance);
event StabilityPoolLUSDBalanceUpdated(uint _newBalance);
event BorrowerOperationsAddressChanged(address _newBorrowerOperationsAddress);
event TroveManagerAddressChanged(address _newTroveManagerAddress);
event ActivePoolAddressChanged(address _newActivePoolAddress);
event DefaultPoolAddressChanged(address _newDefaultPoolAddress);
event LUSDTokenAddressChanged(address _newLUSDTokenAddress);
event SortedTrovesAddressChanged(address _newSortedTrovesAddress);
event PriceFeedAddressChanged(address _newPriceFeedAddress);
event CommunityIssuanceAddressChanged(address _newCommunityIssuanceAddress);
event P_Updated(uint _P);
event S_Updated(uint _S, uint128 _epoch, uint128 _scale);
event G_Updated(uint _G, uint128 _epoch, uint128 _scale);
event EpochUpdated(uint128 _currentEpoch);
event ScaleUpdated(uint128 _currentScale);
event FrontEndRegistered(address indexed _frontEnd, uint _kickbackRate);
event FrontEndTagSet(address indexed _depositor, address indexed _frontEnd);
event DepositSnapshotUpdated(address indexed _depositor, uint _P, uint _S, uint _G);
event FrontEndSnapshotUpdated(address indexed _frontEnd, uint _P, uint _G);
event UserDepositChanged(address indexed _depositor, uint _newDeposit);
event FrontEndStakeChanged(address indexed _frontEnd, uint _newFrontEndStake, address _depositor);
event ETHGainWithdrawn(address indexed _depositor, uint _ETH, uint _LUSDLoss);
event LQTYPaidToDepositor(address indexed _depositor, uint _LQTY);
event LQTYPaidToFrontEnd(address indexed _frontEnd, uint _LQTY);
event EtherSent(address _to, uint _amount);
// --- Functions ---
/*
* Called only once on init, to set addresses of other Liquity contracts
* Callable only by owner, renounces ownership at the end
*/
function setAddresses(
address _borrowerOperationsAddress,
address _troveManagerAddress,
address _activePoolAddress,
address _lusdTokenAddress,
address _sortedTrovesAddress,
address _priceFeedAddress,
address _communityIssuanceAddress
) external;
/*
* Initial checks:
* - Frontend is registered or zero address
* - Sender is not a registered frontend
* - _amount is not zero
* ---
* - Triggers a LQTY issuance, based on time passed since the last issuance. The LQTY issuance is shared between *all* depositors and front ends
* - Tags the deposit with the provided front end tag param, if it's a new deposit
* - Sends depositor's accumulated gains (LQTY, ETH) to depositor
* - Sends the tagged front end's accumulated LQTY gains to the tagged front end
* - Increases deposit and tagged front end's stake, and takes new snapshots for each.
*/
function provideToSP(uint _amount, address _frontEndTag) external;
/*
* Initial checks:
* - _amount is zero or there are no under collateralized troves left in the system
* - User has a non zero deposit
* ---
* - Triggers a LQTY issuance, based on time passed since the last issuance. The LQTY issuance is shared between *all* depositors and front ends
* - Removes the deposit's front end tag if it is a full withdrawal
* - Sends all depositor's accumulated gains (LQTY, ETH) to depositor
* - Sends the tagged front end's accumulated LQTY gains to the tagged front end
* - Decreases deposit and tagged front end's stake, and takes new snapshots for each.
*
* If _amount > userDeposit, the user withdraws all of their compounded deposit.
*/
function withdrawFromSP(uint _amount) external;
/*
* Initial checks:
* - User has a non zero deposit
* - User has an open trove
* - User has some ETH gain
* ---
* - Triggers a LQTY issuance, based on time passed since the last issuance. The LQTY issuance is shared between *all* depositors and front ends
* - Sends all depositor's LQTY gain to depositor
* - Sends all tagged front end's LQTY gain to the tagged front end
* - Transfers the depositor's entire ETH gain from the Stability Pool to the caller's trove
* - Leaves their compounded deposit in the Stability Pool
* - Updates snapshots for deposit and tagged front end stake
*/
function withdrawETHGainToTrove(address _upperHint, address _lowerHint) external;
/*
* Initial checks:
* - Frontend (sender) not already registered
* - User (sender) has no deposit
* - _kickbackRate is in the range [0, 100%]
* ---
* Front end makes a one-time selection of kickback rate upon registering
*/
function registerFrontEnd(uint _kickbackRate) external;
/*
* Initial checks:
* - Caller is TroveManager
* ---
* Cancels out the specified debt against the LUSD contained in the Stability Pool (as far as possible)
* and transfers the Trove's ETH collateral from ActivePool to StabilityPool.
* Only called by liquidation functions in the TroveManager.
*/
function offset(uint _debt, uint _coll) external;
/*
* Returns the total amount of ETH held by the pool, accounted in an internal variable instead of `balance`,
* to exclude edge cases like ETH received from a self-destruct.
*/
function getETH() external view returns (uint);
/*
* Returns LUSD held in the pool. Changes when users deposit/withdraw, and when Trove debt is offset.
*/
function getTotalLUSDDeposits() external view returns (uint);
/*
* Calculates the ETH gain earned by the deposit since its last snapshots were taken.
*/
function getDepositorETHGain(address _depositor) external view returns (uint);
/*
* Calculate the LQTY gain earned by a deposit since its last snapshots were taken.
* If not tagged with a front end, the depositor gets a 100% cut of what their deposit earned.
* Otherwise, their cut of the deposit's earnings is equal to the kickbackRate, set by the front end through
* which they made their deposit.
*/
function getDepositorLQTYGain(address _depositor) external view returns (uint);
/*
* Return the LQTY gain earned by the front end.
*/
function getFrontEndLQTYGain(address _frontEnd) external view returns (uint);
/*
* Return the user's compounded deposit.
*/
function getCompoundedLUSDDeposit(address _depositor) external view returns (uint);
/*
* Return the front end's compounded stake.
*
* The front end's compounded stake is equal to the sum of its depositors' compounded deposits.
*/
function getCompoundedFrontEndStake(address _frontEnd) external view returns (uint);
/*
* Fallback function
* Only callable by Active Pool, it just accounts for ETH received
* receive() external payable;
*/
}
// File contracts/Interfaces/IPriceFeed.sol
// MIT
pragma solidity 0.6.11;
interface IPriceFeed {
// --- Events ---
event LastGoodPriceUpdated(uint _lastGoodPrice);
// --- Function ---
function fetchPrice() external returns (uint);
}
// File contracts/Interfaces/ILiquityBase.sol
// MIT
pragma solidity 0.6.11;
interface ILiquityBase {
function priceFeed() external view returns (IPriceFeed);
}
// File contracts/Dependencies/IERC20.sol
// MIT
pragma solidity 0.6.11;
/**
* Based on the OpenZeppelin IER20 interface:
* https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC20/IERC20.sol
*
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipient`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address recipient, uint256 amount) external returns (bool);
/**
* @dev Returns the remaining number of tokens that `spender` will be
* allowed to spend on behalf of `owner` through {transferFrom}. This is
* zero by default.
*
* This value changes when {approve} or {transferFrom} are called.
*/
function allowance(address owner, address spender) external view returns (uint256);
function increaseAllowance(address spender, uint256 addedValue) external returns (bool);
function decreaseAllowance(address spender, uint256 subtractedValue) external returns (bool);
/**
* @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
* transaction ordering. One possible solution to mitigate this race
* condition is to first reduce the spender's allowance to 0 and set the
* desired value afterwards:
* https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
*
* Emits an {Approval} event.
*/
function approve(address spender, uint256 amount) external returns (bool);
/**
* @dev Moves `amount` tokens from `sender` to `recipient` using the
* allowance mechanism. `amount` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
function name() external view returns (string memory);
function symbol() external view returns (string memory);
function decimals() external view returns (uint8);
/**
* @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);
}
// File contracts/Dependencies/IERC2612.sol
// MIT
pragma solidity 0.6.11;
/**
* @dev Interface of the ERC2612 standard as defined in the EIP.
*
* Adds the {permit} method, which can be used to change one's
* {IERC20-allowance} without having to send a transaction, by signing a
* message. This allows users to spend tokens without having to hold Ether.
*
* See https://eips.ethereum.org/EIPS/eip-2612.
*
* Code adapted from https://github.com/OpenZeppelin/openzeppelin-contracts/pull/2237/
*/
interface IERC2612 {
/**
* @dev Sets `amount` as the allowance of `spender` over `owner`'s tokens,
* given `owner`'s signed approval.
*
* IMPORTANT: The same issues {IERC20-approve} has related to transaction
* ordering also apply here.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `owner` cannot be the zero address.
* - `spender` cannot be the zero address.
* - `deadline` must be a timestamp in the future.
* - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
* over the EIP712-formatted function arguments.
* - the signature must use ``owner``'s current nonce (see {nonces}).
*
* For more information on the signature format, see the
* https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
* section].
*/
function permit(address owner, address spender, uint256 amount,
uint256 deadline, uint8 v, bytes32 r, bytes32 s) external;
/**
* @dev Returns the current ERC2612 nonce for `owner`. This value must be
* included whenever a signature is generated for {permit}.
*
* Every successful call to {permit} increases `owner`'s nonce by one. This
* prevents a signature from being used multiple times.
*
* `owner` can limit the time a Permit is valid for by setting `deadline` to
* a value in the near future. The deadline argument can be set to uint(-1) to
* create Permits that effectively never expire.
*/
function nonces(address owner) external view returns (uint256);
function version() external view returns (string memory);
function permitTypeHash() external view returns (bytes32);
function domainSeparator() external view returns (bytes32);
}
// File contracts/Interfaces/ILUSDToken.sol
// MIT
pragma solidity 0.6.11;
interface ILUSDToken is IERC20, IERC2612 {
// --- Events ---
event TroveManagerAddressChanged(address _troveManagerAddress);
event StabilityPoolAddressChanged(address _newStabilityPoolAddress);
event BorrowerOperationsAddressChanged(address _newBorrowerOperationsAddress);
event LUSDTokenBalanceUpdated(address _user, uint _amount);
// --- Functions ---
function mint(address _account, uint256 _amount) external;
function burn(address _account, uint256 _amount) external;
function sendToPool(address _sender, address poolAddress, uint256 _amount) external;
function returnFromPool(address poolAddress, address user, uint256 _amount ) external;
}
// File contracts/Interfaces/ILQTYToken.sol
// MIT
pragma solidity 0.6.11;
interface ILQTYToken is IERC20, IERC2612 {
// --- Events ---
event CommunityIssuanceAddressSet(address _communityIssuanceAddress);
event LQTYStakingAddressSet(address _lqtyStakingAddress);
event LockupContractFactoryAddressSet(address _lockupContractFactoryAddress);
// --- Functions ---
function sendToLQTYStaking(address _sender, uint256 _amount) external;
function getDeploymentStartTime() external view returns (uint256);
function getLpRewardsEntitlement() external view returns (uint256);
}
// File contracts/Interfaces/ILQTYStaking.sol
// MIT
pragma solidity 0.6.11;
interface ILQTYStaking {
// --- Events --
event LQTYTokenAddressSet(address _lqtyTokenAddress);
event LUSDTokenAddressSet(address _lusdTokenAddress);
event TroveManagerAddressSet(address _troveManager);
event BorrowerOperationsAddressSet(address _borrowerOperationsAddress);
event ActivePoolAddressSet(address _activePoolAddress);
event StakeChanged(address indexed staker, uint newStake);
event StakingGainsWithdrawn(address indexed staker, uint LUSDGain, uint ETHGain);
event F_ETHUpdated(uint _F_ETH);
event F_LUSDUpdated(uint _F_LUSD);
event TotalLQTYStakedUpdated(uint _totalLQTYStaked);
event EtherSent(address _account, uint _amount);
event StakerSnapshotsUpdated(address _staker, uint _F_ETH, uint _F_LUSD);
// --- Functions ---
function setAddresses
(
address _lqtyTokenAddress,
address _lusdTokenAddress,
address _troveManagerAddress,
address _borrowerOperationsAddress,
address _activePoolAddress
) external;
function stake(uint _LQTYamount) external;
function unstake(uint _LQTYamount) external;
function increaseF_ETH(uint _ETHFee) external;
function increaseF_LUSD(uint _LQTYFee) external;
function getPendingETHGain(address _user) external view returns (uint);
function getPendingLUSDGain(address _user) external view returns (uint);
}
// File contracts/Interfaces/ITroveManager.sol
// MIT
pragma solidity 0.6.11;
// Common interface for the Trove Manager.
interface ITroveManager is ILiquityBase {
// --- Events ---
event BorrowerOperationsAddressChanged(address _newBorrowerOperationsAddress);
event PriceFeedAddressChanged(address _newPriceFeedAddress);
event LUSDTokenAddressChanged(address _newLUSDTokenAddress);
event ActivePoolAddressChanged(address _activePoolAddress);
event DefaultPoolAddressChanged(address _defaultPoolAddress);
event StabilityPoolAddressChanged(address _stabilityPoolAddress);
event GasPoolAddressChanged(address _gasPoolAddress);
event CollSurplusPoolAddressChanged(address _collSurplusPoolAddress);
event SortedTrovesAddressChanged(address _sortedTrovesAddress);
event LQTYTokenAddressChanged(address _lqtyTokenAddress);
event LQTYStakingAddressChanged(address _lqtyStakingAddress);
event Liquidation(uint _liquidatedDebt, uint _liquidatedColl, uint _collGasCompensation, uint _LUSDGasCompensation);
event Redemption(uint _attemptedLUSDAmount, uint _actualLUSDAmount, uint _ETHSent, uint _ETHFee);
event TroveUpdated(address indexed _borrower, uint _debt, uint _coll, uint stake, uint8 operation);
event TroveLiquidated(address indexed _borrower, uint _debt, uint _coll, uint8 operation);
event BaseRateUpdated(uint _baseRate);
event LastFeeOpTimeUpdated(uint _lastFeeOpTime);
event TotalStakesUpdated(uint _newTotalStakes);
event SystemSnapshotsUpdated(uint _totalStakesSnapshot, uint _totalCollateralSnapshot);
event LTermsUpdated(uint _L_ETH, uint _L_LUSDDebt);
event TroveSnapshotsUpdated(uint _L_ETH, uint _L_LUSDDebt);
event TroveIndexUpdated(address _borrower, uint _newIndex);
// --- Functions ---
function setAddresses(
address _borrowerOperationsAddress,
address _activePoolAddress,
address _defaultPoolAddress,
address _stabilityPoolAddress,
address _gasPoolAddress,
address _collSurplusPoolAddress,
address _priceFeedAddress,
address _lusdTokenAddress,
address _sortedTrovesAddress,
address _lqtyTokenAddress,
address _lqtyStakingAddress
) external;
function stabilityPool() external view returns (IStabilityPool);
function lusdToken() external view returns (ILUSDToken);
function lqtyToken() external view returns (ILQTYToken);
function lqtyStaking() external view returns (ILQTYStaking);
function getTroveOwnersCount() external view returns (uint);
function getTroveFromTroveOwnersArray(uint _index) external view returns (address);
function getNominalICR(address _borrower) external view returns (uint);
function getCurrentICR(address _borrower, uint _price) external view returns (uint);
function liquidate(address _borrower) external;
function liquidateTroves(uint _n) external;
function batchLiquidateTroves(address[] calldata _troveArray) external;
function redeemCollateral(
uint _LUSDAmount,
address _firstRedemptionHint,
address _upperPartialRedemptionHint,
address _lowerPartialRedemptionHint,
uint _partialRedemptionHintNICR,
uint _maxIterations,
uint _maxFee
) external;
function updateStakeAndTotalStakes(address _borrower) external returns (uint);
function updateTroveRewardSnapshots(address _borrower) external;
function addTroveOwnerToArray(address _borrower) external returns (uint index);
function applyPendingRewards(address _borrower) external;
function getPendingETHReward(address _borrower) external view returns (uint);
function getPendingLUSDDebtReward(address _borrower) external view returns (uint);
function hasPendingRewards(address _borrower) external view returns (bool);
function getEntireDebtAndColl(address _borrower) external view returns (
uint debt,
uint coll,
uint pendingLUSDDebtReward,
uint pendingETHReward
);
function closeTrove(address _borrower) external;
function removeStake(address _borrower) external;
function getRedemptionRate() external view returns (uint);
function getRedemptionRateWithDecay() external view returns (uint);
function getRedemptionFeeWithDecay(uint _ETHDrawn) external view returns (uint);
function getBorrowingRate() external view returns (uint);
function getBorrowingRateWithDecay() external view returns (uint);
function getBorrowingFee(uint LUSDDebt) external view returns (uint);
function getBorrowingFeeWithDecay(uint _LUSDDebt) external view returns (uint);
function decayBaseRateFromBorrowing() external;
function getTroveStatus(address _borrower) external view returns (uint);
function getTroveStake(address _borrower) external view returns (uint);
function getTroveDebt(address _borrower) external view returns (uint);
function getTroveColl(address _borrower) external view returns (uint);
function setTroveStatus(address _borrower, uint num) external;
function increaseTroveColl(address _borrower, uint _collIncrease) external returns (uint);
function decreaseTroveColl(address _borrower, uint _collDecrease) external returns (uint);
function increaseTroveDebt(address _borrower, uint _debtIncrease) external returns (uint);
function decreaseTroveDebt(address _borrower, uint _collDecrease) external returns (uint);
function getTCR(uint _price) external view returns (uint);
function checkRecoveryMode(uint _price) external view returns (bool);
}
// File contracts/Interfaces/ISortedTroves.sol
// MIT
pragma solidity 0.6.11;
// Common interface for the SortedTroves Doubly Linked List.
interface ISortedTroves {
// --- Events ---
event SortedTrovesAddressChanged(address _sortedDoublyLLAddress);
event BorrowerOperationsAddressChanged(address _borrowerOperationsAddress);
event NodeAdded(address _id, uint _NICR);
event NodeRemoved(address _id);
// --- Functions ---
function setParams(uint256 _size, address _TroveManagerAddress, address _borrowerOperationsAddress) external;
function insert(address _id, uint256 _ICR, address _prevId, address _nextId) external;
function remove(address _id) external;
function reInsert(address _id, uint256 _newICR, address _prevId, address _nextId) external;
function contains(address _id) external view returns (bool);
function isFull() external view returns (bool);
function isEmpty() external view returns (bool);
function getSize() external view returns (uint256);
function getMaxSize() external view returns (uint256);
function getFirst() external view returns (address);
function getLast() external view returns (address);
function getNext(address _id) external view returns (address);
function getPrev(address _id) external view returns (address);
function validInsertPosition(uint256 _ICR, address _prevId, address _nextId) external view returns (bool);
function findInsertPosition(uint256 _ICR, address _prevId, address _nextId) external view returns (address, address);
}
// File contracts/Interfaces/ICommunityIssuance.sol
// MIT
pragma solidity 0.6.11;
interface ICommunityIssuance {
// --- Events ---
event LQTYTokenAddressSet(address _lqtyTokenAddress);
event StabilityPoolAddressSet(address _stabilityPoolAddress);
event TotalLQTYIssuedUpdated(uint _totalLQTYIssued);
// --- Functions ---
function setAddresses(address _lqtyTokenAddress, address _stabilityPoolAddress) external;
function issueLQTY() external returns (uint);
function sendLQTY(address _account, uint _LQTYamount) external;
}
// File contracts/Dependencies/BaseMath.sol
// MIT
pragma solidity 0.6.11;
contract BaseMath {
uint constant public DECIMAL_PRECISION = 1e18;
}
// File contracts/Dependencies/SafeMath.sol
// MIT
pragma solidity 0.6.11;
/**
* Based on OpenZeppelin's SafeMath:
* https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/math/SafeMath.sol
*
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming languages.
* `SafeMath` restores this intuition by reverting the transaction when an
* operation overflows.
*
* Using this library instead of the unchecked operations eliminates an entire
* class of bugs, so it's recommended to use it always.
*/
library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a + b;
require(c >= a, "SafeMath: addition overflow");
return c;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
* - Subtraction cannot overflow.
*/
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
return sub(a, b, "SafeMath: subtraction overflow");
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
* - Subtraction cannot overflow.
*
* _Available since v2.4.0._
*/
function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @dev Returns the multiplication of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `*` operator.
*
* Requirements:
* - Multiplication cannot overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b, "SafeMath: multiplication overflow");
return c;
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
* - The divisor cannot be zero.
*/
function div(uint256 a, uint256 b) internal pure returns (uint256) {
return div(a, b, "SafeMath: division by zero");
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts with custom message on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
* - The divisor cannot be zero.
*
* _Available since v2.4.0._
*/
function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
// Solidity only automatically asserts when dividing by 0
require(b > 0, errorMessage);
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
* - The divisor cannot be zero.
*/
function mod(uint256 a, uint256 b) internal pure returns (uint256) {
return mod(a, b, "SafeMath: modulo by zero");
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts with custom message when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
* - The divisor cannot be zero.
*
* _Available since v2.4.0._
*/
function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b != 0, errorMessage);
return a % b;
}
}
// File contracts/Dependencies/console.sol
// MIT
pragma solidity 0.6.11;
// Buidler's helper contract for console logging
library console {
address constant CONSOLE_ADDRESS = address(0x000000000000000000636F6e736F6c652e6c6f67);
function log() internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log()"));
ignored;
} function logInt(int p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(int)", p0));
ignored;
}
function logUint(uint p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint)", p0));
ignored;
}
function logString(string memory p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string)", p0));
ignored;
}
function logBool(bool p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool)", p0));
ignored;
}
function logAddress(address p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address)", p0));
ignored;
}
function logBytes(bytes memory p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes)", p0));
ignored;
}
function logByte(byte p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(byte)", p0));
ignored;
}
function logBytes1(bytes1 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes1)", p0));
ignored;
}
function logBytes2(bytes2 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes2)", p0));
ignored;
}
function logBytes3(bytes3 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes3)", p0));
ignored;
}
function logBytes4(bytes4 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes4)", p0));
ignored;
}
function logBytes5(bytes5 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes5)", p0));
ignored;
}
function logBytes6(bytes6 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes6)", p0));
ignored;
}
function logBytes7(bytes7 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes7)", p0));
ignored;
}
function logBytes8(bytes8 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes8)", p0));
ignored;
}
function logBytes9(bytes9 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes9)", p0));
ignored;
}
function logBytes10(bytes10 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes10)", p0));
ignored;
}
function logBytes11(bytes11 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes11)", p0));
ignored;
}
function logBytes12(bytes12 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes12)", p0));
ignored;
}
function logBytes13(bytes13 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes13)", p0));
ignored;
}
function logBytes14(bytes14 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes14)", p0));
ignored;
}
function logBytes15(bytes15 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes15)", p0));
ignored;
}
function logBytes16(bytes16 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes16)", p0));
ignored;
}
function logBytes17(bytes17 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes17)", p0));
ignored;
}
function logBytes18(bytes18 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes18)", p0));
ignored;
}
function logBytes19(bytes19 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes19)", p0));
ignored;
}
function logBytes20(bytes20 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes20)", p0));
ignored;
}
function logBytes21(bytes21 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes21)", p0));
ignored;
}
function logBytes22(bytes22 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes22)", p0));
ignored;
}
function logBytes23(bytes23 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes23)", p0));
ignored;
}
function logBytes24(bytes24 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes24)", p0));
ignored;
}
function logBytes25(bytes25 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes25)", p0));
ignored;
}
function logBytes26(bytes26 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes26)", p0));
ignored;
}
function logBytes27(bytes27 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes27)", p0));
ignored;
}
function logBytes28(bytes28 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes28)", p0));
ignored;
}
function logBytes29(bytes29 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes29)", p0));
ignored;
}
function logBytes30(bytes30 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes30)", p0));
ignored;
}
function logBytes31(bytes31 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes31)", p0));
ignored;
}
function logBytes32(bytes32 p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bytes32)", p0));
ignored;
}
function log(uint p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint)", p0));
ignored;
}
function log(string memory p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string)", p0));
ignored;
}
function log(bool p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool)", p0));
ignored;
}
function log(address p0) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address)", p0));
ignored;
}
function log(uint p0, uint p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,uint)", p0, p1));
ignored;
}
function log(uint p0, string memory p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,string)", p0, p1));
ignored;
}
function log(uint p0, bool p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,bool)", p0, p1));
ignored;
}
function log(uint p0, address p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,address)", p0, p1));
ignored;
}
function log(string memory p0, uint p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,uint)", p0, p1));
ignored;
}
function log(string memory p0, string memory p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,string)", p0, p1));
ignored;
}
function log(string memory p0, bool p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,bool)", p0, p1));
ignored;
}
function log(string memory p0, address p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,address)", p0, p1));
ignored;
}
function log(bool p0, uint p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool,uint)", p0, p1));
ignored;
}
function log(bool p0, string memory p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool,string)", p0, p1));
ignored;
}
function log(bool p0, bool p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool,bool)", p0, p1));
ignored;
}
function log(bool p0, address p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(bool,address)", p0, p1));
ignored;
}
function log(address p0, uint p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address,uint)", p0, p1));
ignored;
}
function log(address p0, string memory p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address,string)", p0, p1));
ignored;
}
function log(address p0, bool p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address,bool)", p0, p1));
ignored;
}
function log(address p0, address p1) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(address,address)", p0, p1));
ignored;
}
function log(uint p0, uint p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,uint,uint)", p0, p1, p2));
ignored;
}
function log(uint p0, uint p1, string memory p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,uint,string)", p0, p1, p2));
ignored;
}
function log(uint p0, uint p1, bool p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,uint,bool)", p0, p1, p2));
ignored;
}
function log(uint p0, uint p1, address p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,uint,address)", p0, p1, p2));
ignored;
}
function log(uint p0, string memory p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,string,uint)", p0, p1, p2));
ignored;
}
function log(uint p0, string memory p1, string memory p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,string,string)", p0, p1, p2));
ignored;
}
function log(uint p0, string memory p1, bool p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,string,bool)", p0, p1, p2));
ignored;
}
function log(uint p0, string memory p1, address p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,string,address)", p0, p1, p2));
ignored;
}
function log(uint p0, bool p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,bool,uint)", p0, p1, p2));
ignored;
}
function log(uint p0, bool p1, string memory p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,bool,string)", p0, p1, p2));
ignored;
}
function log(uint p0, bool p1, bool p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,bool,bool)", p0, p1, p2));
ignored;
}
function log(uint p0, bool p1, address p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,bool,address)", p0, p1, p2));
ignored;
}
function log(uint p0, address p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,address,uint)", p0, p1, p2));
ignored;
}
function log(uint p0, address p1, string memory p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,address,string)", p0, p1, p2));
ignored;
}
function log(uint p0, address p1, bool p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,address,bool)", p0, p1, p2));
ignored;
}
function log(uint p0, address p1, address p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(uint,address,address)", p0, p1, p2));
ignored;
}
function log(string memory p0, uint p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,uint,uint)", p0, p1, p2));
ignored;
}
function log(string memory p0, uint p1, string memory p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,uint,string)", p0, p1, p2));
ignored;
}
function log(string memory p0, uint p1, bool p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,uint,bool)", p0, p1, p2));
ignored;
}
function log(string memory p0, uint p1, address p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.encodeWithSignature("log(string,uint,address)", p0, p1, p2));
ignored;
}
function log(string memory p0, string memory p1, uint p2) internal view {
(bool ignored, ) = CONSOLE_ADDRESS.staticcall(abi.e...
// [truncated — 184527 bytes total]
Read Contract
A 0xf446c1d0 → uint256
LUSD 0xcf59d563 → address
MAX_A 0x39698415 → uint256
MAX_FEE 0xbc063e1a → uint256
MIN_A 0x6e9fe670 → uint256
PRECISION 0xaaf5eb68 → uint256
SP 0x4426ebd0 → address
chicken 0x9e166bdf → address
compensateForLusdDeviation 0x04a764c0 → uint256
fee 0xddca3f43 → uint256
feePool 0xae2e933b → address
fetchPrice 0x0fdb11cf → uint256
frontEndTag 0x5da937c4 → address
gem 0x7bd2bea7 → address
gemSeller 0xadfaab12 → address
getConversionRate 0x7cd44272 → uint256
getLUSDValue 0xbfca6c11 → uint256, uint256, uint256
getReturn 0x068d5911 → uint256
getSumFixedPoint 0xe29e4fbc → uint256
getSwapEthAmount 0xc67e2b60 → uint256, uint256
isOwner 0x8f32d59b → bool
lusd2UsdPriceAggregator 0xf73a12e1 → address
maxDiscount 0xb8b89e1b → uint256
owner 0x8da5cb5b → address
pendingGemSeller 0xbe2b6ce1 → address
pendingGemSellerUpdateTime 0x5c532c5d → uint256
priceAggregator 0x3078fff5 → address
timelockDuration 0x2bbca157 → uint256
Write Contract 11 functions
These functions modify contract state and require a wallet transaction to execute.
compound 0xaa5f7e26
uint256 lusdAmount
deposit 0xb6b55f25
uint256 lusdAmount
harvest 0x4641257d
No parameters
setChicken 0x6d5ccc80
address _chicken
setParams 0xc0324c77
uint256 _A
uint256 _fee
setPendingSeller 0x6b926206
address _pendingSeller
setSeller 0xe99d2866
address _seller
swap 0x6d9a640a
uint256 lusdAmount
uint256 minEthReturn
address dest
returns: uint256
trade 0x6cf69811
address
uint256 srcAmount
address
address destAddress
uint256
bool
returns: bool
transferOwnership 0xf2fde38b
address newOwner
withdraw 0x00f714ce
uint256 lusdAmount
address to
Recent Transactions
No transactions found for this address