Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
TokenTracker
Latest 25 from a total of 44 transactions
| Transaction Hash |
Method
|
Block
|
From
|
|
To
|
||||
|---|---|---|---|---|---|---|---|---|---|
| Redeem Underlyin... | 21259495 | 476 days ago | IN | 0 ETH | 0.00334568 | ||||
| Redeem Underlyin... | 21024947 | 509 days ago | IN | 0 ETH | 0.00179535 | ||||
| Mint | 20461266 | 588 days ago | IN | 0 ETH | 0.00813686 | ||||
| Redeem Underlyin... | 20415149 | 594 days ago | IN | 0 ETH | 0.00105259 | ||||
| Redeem Underlyin... | 20380145 | 599 days ago | IN | 0 ETH | 0.00139672 | ||||
| Mint | 20258716 | 616 days ago | IN | 0 ETH | 0.00121155 | ||||
| Mint | 20258714 | 616 days ago | IN | 0 ETH | 0.0021579 | ||||
| Redeem Underlyin... | 20178482 | 627 days ago | IN | 0 ETH | 0.00415786 | ||||
| Redeem Underlyin... | 20144330 | 632 days ago | IN | 0 ETH | 0.00133748 | ||||
| Redeem Underlyin... | 20057572 | 644 days ago | IN | 0 ETH | 0.00205199 | ||||
| Mint | 20051502 | 645 days ago | IN | 0 ETH | 0.00148779 | ||||
| Mint | 20051496 | 645 days ago | IN | 0 ETH | 0.00202388 | ||||
| Mint | 20001499 | 652 days ago | IN | 0 ETH | 0.00185369 | ||||
| Redeem Underlyin... | 20001495 | 652 days ago | IN | 0 ETH | 0.00270147 | ||||
| Mint | 20001491 | 652 days ago | IN | 0 ETH | 0.00184817 | ||||
| Mint | 19897333 | 667 days ago | IN | 0 ETH | 0.00201506 | ||||
| Redeem Underlyin... | 19897313 | 667 days ago | IN | 0 ETH | 0.00292434 | ||||
| Mint | 19894322 | 667 days ago | IN | 0 ETH | 0.00212303 | ||||
| Redeem Underlyin... | 19894313 | 667 days ago | IN | 0 ETH | 0.00287037 | ||||
| Mint | 19893775 | 667 days ago | IN | 0 ETH | 0.00117759 | ||||
| Mint | 19892793 | 667 days ago | IN | 0 ETH | 0.00166018 | ||||
| Mint | 19857707 | 672 days ago | IN | 0 ETH | 0.00233936 | ||||
| Redeem Underlyin... | 19828700 | 676 days ago | IN | 0 ETH | 0.00183274 | ||||
| Redeem Underlyin... | 19624772 | 705 days ago | IN | 0 ETH | 0.01877612 | ||||
| Redeem Underlyin... | 19497438 | 723 days ago | IN | 0 ETH | 0.00953564 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions
Loading...
Loading
Contract Name:
CErc721NoBorrowDelegator
Compiler Version
v0.8.23+commit.f704f362
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
import "contracts/CTokenInterfaces.sol";
import "contracts/CErc721TokenInterfaces.sol";
import "contracts/CErc20InterestMarketInterfaces.sol";
contract CErc721NoBorrowDelegator is CTokenInterface, CErc721Interface, CErc721NoBorrowInterface, CDelegatorInterface {
error Unauthorized();
/**
* @notice Construct a new money market
* @param underlying_ The address of the underlying asset
* @param comptroller_ The address of the Comptroller
* @param interestRateModel_ The address of the interest rate model
* @param initialExchangeRateMantissa_ The initial exchange rate, scaled by 1e18
* @param name_ ERC-20 name of this token
* @param symbol_ ERC-20 symbol of this token
* @param decimals_ ERC-20 decimal precision of this token
* @param admin_ Address of the administrator of this token
* @param implementation_ The address of the implementation the contract delegates to
* @param becomeImplementationData The encoded args for becomeImplementation
*/
constructor(address underlying_,
ComptrollerInterface comptroller_,
InterestRateModel interestRateModel_,
uint initialExchangeRateMantissa_,
string memory name_,
string memory symbol_,
uint8 decimals_,
address payable admin_,
address implementation_,
bytes memory becomeImplementationData) {
// Creator of the contract is admin during initialization
admin = payable(msg.sender);
// First delegate gets to initialize the delegator (i.e. storage contract)
delegateTo(implementation_, abi.encodeWithSignature("initialize(address,address,address,uint256,string,string,uint8)",
underlying_,
comptroller_,
interestRateModel_,
initialExchangeRateMantissa_,
name_,
symbol_,
decimals_));
// New implementations always get set via the settor (post-initialize)
_setImplementation(implementation_, false, becomeImplementationData);
// Set the proper admin now that initialization is done
admin = admin_;
}
/**
* @notice Called by the admin to update the implementation of the delegator
* @param implementation_ The address of the new implementation for delegation
* @param allowResign Flag to indicate whether to call _resignImplementation on the old implementation
* @param becomeImplementationData The encoded bytes data to be passed to _becomeImplementation
*/
function _setImplementation(address implementation_, bool allowResign, bytes memory becomeImplementationData) override public {
if (msg.sender != admin) {
revert Unauthorized();
}
if (allowResign) {
delegateToImplementation(abi.encodeWithSignature("_resignImplementation()"));
}
address oldImplementation = implementation;
implementation = implementation_;
delegateToImplementation(abi.encodeWithSignature("_becomeImplementation(bytes)", becomeImplementationData));
emit NewImplementation(oldImplementation, implementation);
}
/**
* @notice Sender supplies assets into the market and receives cTokens in exchange
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param nftIds The NFT IDs to supply
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function mint(uint[] memory nftIds) external override returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("mint(uint256[])", nftIds));
return abi.decode(data, (uint));
}
/**
* @notice Redeems the interest accrued from the supplied assets. Owed interest will also be paid from this amount.
* @param redeemer The address to redeem the interest for
* If the caller is not the comptroller the sender is the redeemer.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemInterest(address redeemer) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("redeemInterest(address)", redeemer));
return abi.decode(data, (uint));
}
/**
* @notice Redeems the interest accrued from the supplied assets. Owed interest will also be paid from this amount.
* @param redeemer The address to redeem the interest for
* Only the comptroller can call.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _redeemInterestForLiquidation(address redeemer) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_redeemInterestForLiquidation(address)", redeemer));
return abi.decode(data, (uint));
}
/**
* @notice Sender redeems cTokens in exchange for the underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param redeemTokens The number of cTokens to redeem into underlying
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeem(uint redeemTokens) external override returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("redeem(uint256)", redeemTokens));
return abi.decode(data, (uint));
}
/**
* @notice Sender redeems cTokens in exchange for a specified amount of underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param redeemNFTCount The amount of underlying NFTs to redeem
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemUnderlying(uint redeemNFTCount) external override returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("redeemUnderlying(uint256)", redeemNFTCount));
return abi.decode(data, (uint));
}
/**
* @notice Sender redeems cTokens in exchange for a specified amount of underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param nftIds The NFT IDs to redeem
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemUnderlyingNfts(uint[] memory nftIds) external override returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("redeemUnderlyingNfts(uint256[])", nftIds));
return abi.decode(data, (uint));
}
/**
* @notice Sender borrows assets from the protocol to their own address
* @param borrowNFTCount The amount of underlying NFTs to borrow
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function borrow(uint borrowNFTCount) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("borrow(uint256)", borrowNFTCount));
return abi.decode(data, (uint));
}
/**
* @notice Sender repays their own borrow
* @param nftIds The NFT IDs to be used for the repayment
* @param repayInterest The min amount of interest to be repaid in interest market units
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function repayBorrow(uint[] memory nftIds, uint repayInterest) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("repayBorrow(uint256[],uint256)", nftIds, repayInterest));
return abi.decode(data, (uint));
}
/**
* @notice Repays a loan on behalf of another user
* @param borrower The account with the debt being payed off
* @param nftIds The NFT IDs to be used for the repayment
* @param repayInterest The min amount of interest to be repaid in interest market units
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function repayBorrowBehalf(address borrower, uint[] memory nftIds, uint repayInterest) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("repayBorrowBehalf(address,uint256[],uint256)", borrower, nftIds, repayInterest));
return abi.decode(data, (uint));
}
/**
* @notice The liquidator liquidates the borrowers collateral.
* This function can only be called by the Comptroller.
* @param liquidator The liquidator who called Comptroller::batchLiquidateBorrow
* @param borrower The borrower of this cToken to be liquidated
* @param nftIds The NFT IDs of the underlying borrowed asset to repay
* @return uint The amount of the underlying borrowed asset that was actually repaid
*/
function _liquidateBorrow(address liquidator, address borrower, uint[] memory nftIds) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_liquidateBorrow(address,address,uint256[])", liquidator, borrower, nftIds));
return abi.decode(data, (uint));
}
/**
* @notice Transfer `amount` tokens from `msg.sender` to `dst`
* @param dst The address of the destination account
* @param amount The number of tokens to transfer
* @return Whether or not the transfer succeeded
*/
function transfer(address dst, uint amount) override external returns (bool) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("transfer(address,uint256)", dst, amount));
return abi.decode(data, (bool));
}
/**
* @notice Transfer `amount` tokens from `src` to `dst`
* @param src The address of the source account
* @param dst The address of the destination account
* @param amount The number of tokens to transfer
* @return Whether or not the transfer succeeded
*/
function transferFrom(address src, address dst, uint256 amount) override external returns (bool) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("transferFrom(address,address,uint256)", src, dst, amount));
return abi.decode(data, (bool));
}
/**
* @notice Approve `spender` to transfer up to `amount` from `src`
* @dev This will overwrite the approval amount for `spender`
* and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
* @param spender The address of the account which may transfer tokens
* @param amount The number of tokens that are approved (-1 means infinite)
* @return Whether or not the approval succeeded
*/
function approve(address spender, uint256 amount) override external returns (bool) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("approve(address,uint256)", spender, amount));
return abi.decode(data, (bool));
}
/**
* @notice Get the current allowance from `owner` for `spender`
* @param owner The address of the account which owns the tokens to be spent
* @param spender The address of the account which may transfer tokens
* @return The number of tokens allowed to be spent (-1 means infinite)
*/
function allowance(address owner, address spender) override external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("allowance(address,address)", owner, spender));
return abi.decode(data, (uint));
}
/**
* @notice Get the token balance of the `owner`
* @param owner The address of the account to query
* @return The number of tokens owned by `owner`
*/
function balanceOf(address owner) override external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("balanceOf(address)", owner));
return abi.decode(data, (uint));
}
/**
* @notice Get the underlying balance of the `owner`
* @dev This also accrues interest in a transaction
* @param owner The address of the account to query
* @return The amount of underlying owned by `owner`
*/
function balanceOfUnderlying(address owner) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("balanceOfUnderlying(address)", owner));
return abi.decode(data, (uint));
}
/**
* @notice Accrue interest and return the current supply interest balance of account
* @param account The address whose balance should be calculated
* @return uint The calculated supply interest balance
*/
function supplyInterestCurrent(address account) external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("supplyInterestCurrent(address)", account));
return abi.decode(data, (uint));
}
/**
* @notice Return the supply interest balance of account based on stored data
* @param account The address whose balance should be calculated
* @return uint The calculated supply interest balance
*/
function supplyInterestStored(address account) external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("supplyInterestStored(address)", account));
return abi.decode(data, (uint));
}
/**
* @notice Accrue interest and return the current borrow balance of account
* @param account The address whose balance should be calculated
* @return (uint The calculated balance, uint The interest balance)
*/
function borrowAndInterestBalanceCurrent(address account) external returns (uint, uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("borrowAndInterestBalanceCurrent(address)", account));
return abi.decode(data, (uint, uint));
}
/**
* @notice Return the borrow balance of account based on stored data
* @param account The address whose balance should be calculated
* @return (uint The calculated balance, uint The interest balance)
*/
function borrowAndInterestBalanceStored(address account) external view returns (uint, uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("borrowAndInterestBalanceStored(address)", account));
return abi.decode(data, (uint, uint));
}
/**
* @notice Get a snapshot of the account's balances, and the cached exchange rate
* @dev This is used by comptroller to more efficiently perform liquidity checks.
* @param account Address of the account to snapshot
* @return (possible error, token balance, borrow balance, exchange rate mantissa, borrow interest balance)
*/
function getAccountSnapshot(address account) override external view returns (uint, uint, uint, uint, uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("getAccountSnapshot(address)", account));
return abi.decode(data, (uint, uint, uint, uint, uint));
}
/**
* @notice Returns the current per-block borrow interest rate for this cToken
* @return uint The borrow interest rate per block, scaled by 1e18
*/
function borrowRatePerBlock() override external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("borrowRatePerBlock()"));
return abi.decode(data, (uint));
}
/**
* @notice Returns the current per-block supply interest rate for this cToken
* @return uint The supply interest rate per block, scaled by 1e18
*/
function supplyRatePerBlock() override external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("supplyRatePerBlock()"));
return abi.decode(data, (uint));
}
/**
* @notice Returns the current total borrows plus accrued interest
* @return uint The total borrows with interest
*/
function totalBorrowsCurrent() override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("totalBorrowsCurrent()"));
return abi.decode(data, (uint));
}
/**
* @notice Accrue interest to updated borrowIndex and then calculate account's borrow balance using the updated borrowIndex
* @param account The address whose balance should be calculated after updating borrowIndex
* @return uint The calculated balance
*/
function borrowBalanceCurrent(address account) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("borrowBalanceCurrent(address)", account));
return abi.decode(data, (uint));
}
/**
* @notice Return the borrow balance of account based on stored data
* @param account The address whose balance should be calculated
* @return uint The calculated balance
*/
function borrowBalanceStored(address account) override public view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("borrowBalanceStored(address)", account));
return abi.decode(data, (uint));
}
/**
* @notice Accrue interest then return the up-to-date exchange rate
* @return uint Calculated exchange rate scaled by 1e18
*/
function exchangeRateCurrent() override public returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("exchangeRateCurrent()"));
return abi.decode(data, (uint));
}
/**
* @notice Calculates the exchange rate from the underlying to the CToken
* @dev This function does not accrue interest before calculating the exchange rate
* @return uint Calculated exchange rate scaled by 1e18
*/
function exchangeRateStored() override public view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("exchangeRateStored()"));
return abi.decode(data, (uint));
}
/**
* @notice Get cash balance of this cToken in the underlying asset
* @return uint The quantity of underlying asset owned by this contract
*/
function getCash() override external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("getCash()"));
return abi.decode(data, (uint));
}
/**
* @notice Applies accrued interest to total borrows and reserves.
* @dev This calculates interest accrued from the last checkpointed block
* up to the current block and writes new checkpoint to storage.
* @return uint NO_ERROR if interest is up to date, otherwise the current assetExchangeRate.
*/
function accrueInterest() override public returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("accrueInterest()"));
return abi.decode(data, (uint));
}
/**
* @notice Transfers collateral tokens (this market) to the liquidator.
* This function can only be called by the Comptroller.
* @param liquidator The account receiving seized collateral
* @param borrower The account having collateral seized
* @param seizeTokens The number of cTokens to seize
* @return uint actual seizeTokens
*/
function _seize(address liquidator, address borrower, uint seizeTokens) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_seize(address,address,uint256)", liquidator, borrower, seizeTokens));
return abi.decode(data, (uint));
}
/**
* @notice A public function to sweep accidental ERC-20 transfers to this contract. Tokens are sent to admin (timelock)
* @param token The address of the ERC-20 token to sweep
*/
function sweepToken(EIP20NonStandardInterface token) override external {
delegateToImplementation(abi.encodeWithSignature("sweepToken(address)", token));
}
/**
* @notice Gets the amount of NFTs held/managed by this contract
* @return uint The number of NFTs held/managed
*/
function getNFTsHeld() external view returns (uint) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("getNFTsHeld()"));
return abi.decode(data, (uint));
}
/**
* @notice Gets the amount of NFTs held by a user
* @return uint The number of NFTs held by a user
*/
function getNFTsHeldByUser(address user) external view returns (uint[] memory) {
bytes memory data = delegateToViewImplementation(abi.encodeWithSignature("getNFTsHeldByUser(address)", user));
return abi.decode(data, (uint[]));
}
/*** Admin Functions ***/
/**
* @notice Begins transfer of admin rights. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
* @dev Admin function to begin change of admin. The newPendingAdmin must call `_acceptAdmin` to finalize the transfer.
* @param newPendingAdmin New pending admin.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _setPendingAdmin(address payable newPendingAdmin) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_setPendingAdmin(address)", newPendingAdmin));
return abi.decode(data, (uint));
}
/**
* @notice Sets a new comptroller for the market
* @dev Admin function to set a new comptroller
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _setComptroller(ComptrollerInterface newComptroller) override public returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_setComptroller(address)", newComptroller));
return abi.decode(data, (uint));
}
/**
* @notice Not supported.
*/
function _setProtocolSeizeShare(uint newProtocolSeizeShareMantissa) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_setProtocolSeizeShare(uint256)", newProtocolSeizeShareMantissa));
return abi.decode(data, (uint));
}
/**
* @notice accrues interest and sets a new reserve factor for the protocol using _setReserveFactorFresh
* @dev Admin function to accrue interest and set a new reserve factor
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _setReserveFactor(uint newReserveFactorMantissa) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_setReserveFactor(uint256)", newReserveFactorMantissa));
return abi.decode(data, (uint));
}
/**
* @notice Accepts transfer of admin rights. msg.sender must be pendingAdmin
* @dev Admin function for pending admin to accept role and update admin
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _acceptAdmin() override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_acceptAdmin()"));
return abi.decode(data, (uint));
}
/**
* @notice Accrues interest and reduces reserves by transferring to admin
* @param reduceAmount Amount of reduction to reserves
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _reduceReserves(uint reduceAmount) override external returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_reduceReserves(uint256)", reduceAmount));
return abi.decode(data, (uint));
}
/**
* @notice Accrues interest and updates the interest rate model using _setInterestRateModelFresh
* @dev Admin function to accrue interest and update the interest rate model
* @param newInterestRateModel the new interest rate model to use
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _setInterestRateModel(InterestRateModel newInterestRateModel) override public returns (uint) {
bytes memory data = delegateToImplementation(abi.encodeWithSignature("_setInterestRateModel(address)", newInterestRateModel));
return abi.decode(data, (uint));
}
/**
* @notice Internal method to delegate execution to another contract
* @dev It returns to the external caller whatever the implementation returns or forwards reverts
* @param callee The contract to delegatecall
* @param data The raw data to delegatecall
* @return The returned bytes from the delegatecall
*/
function delegateTo(address callee, bytes memory data) internal returns (bytes memory) {
(bool success, bytes memory returnData) = callee.delegatecall(data);
assembly {
if eq(success, 0) {
revert(add(returnData, 0x20), returndatasize())
}
}
return returnData;
}
/**
* @notice Delegates execution to the implementation contract
* @dev It returns to the external caller whatever the implementation returns or forwards reverts
* @param data The raw data to delegatecall
* @return The returned bytes from the delegatecall
*/
function delegateToImplementation(bytes memory data) public returns (bytes memory) {
return delegateTo(implementation, data);
}
/**
* @notice Delegates execution to an implementation contract
* @dev It returns to the external caller whatever the implementation returns or forwards reverts
* There are an additional 2 prefix uints from the wrapper returndata, which we ignore since we make an extra hop.
* @param data The raw data to delegatecall
* @return The returned bytes from the delegatecall
*/
function delegateToViewImplementation(bytes memory data) public view returns (bytes memory) {
(bool success, bytes memory returnData) = address(this).staticcall(abi.encodeWithSignature("delegateToImplementation(bytes)", data));
assembly {
if eq(success, 0) {
revert(add(returnData, 0x20), returndatasize())
}
}
return abi.decode(returnData, (bytes));
}
/**
* @notice Delegates execution to an implementation contract
* @dev It returns to the external caller whatever the implementation returns or forwards reverts
*/
fallback() external payable {
if (msg.value != 0) {
revert CannotReceiveValueGtZero();
}
// delegate all other functions to current implementation
(bool success, ) = implementation.delegatecall(msg.data);
assembly {
let free_mem_ptr := mload(0x40)
returndatacopy(free_mem_ptr, 0, returndatasize())
switch success
case 0 { revert(free_mem_ptr, returndatasize()) }
default { return(free_mem_ptr, returndatasize()) }
}
}
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
import "contracts/ComptrollerInterface.sol";
import "contracts/InterestRateModel.sol";
import "contracts/EIP20NonStandardInterface.sol";
import "contracts/ErrorReporter.sol";
contract CTokenStorage {
/**
* @dev Guard variable for re-entrancy checks
*/
bool internal _notEntered;
/**
* @notice EIP-20 token name for this token
*/
string public name;
/**
* @notice EIP-20 token symbol for this token
*/
string public symbol;
/**
* @notice EIP-20 token decimals for this token
*/
uint8 public decimals;
// Maximum borrow rate that can ever be applied (.0005% / block)
uint internal constant borrowRateMaxMantissa = 0.0005e16;
// Maximum fraction of interest that can be set aside for reserves
uint internal constant reserveFactorMaxMantissa = 1e18;
// Maximum protocol seize share that can be set
uint internal constant protocolSeizeShareMaxMantissa = 20e16;
/**
* @notice Administrator for this contract
*/
address payable public admin;
/**
* @notice Pending administrator for this contract
*/
address payable public pendingAdmin;
/**
* @notice Contract which oversees inter-cToken operations
*/
ComptrollerInterface public comptroller;
/**
* @notice Model which tells what the current interest rate should be
*/
InterestRateModel public interestRateModel;
// Initial exchange rate used when minting the first CTokens (used when totalSupply = 0)
uint internal initialExchangeRateMantissa;
/**
* @notice Fraction of interest currently set aside for reserves
*/
uint public reserveFactorMantissa;
/**
* @notice Block number that interest was last accrued at
*/
uint public accrualBlockNumber;
/**
* @notice Accumulator of the total earned interest rate since the opening of the market
*/
uint public borrowIndex;
/**
* @notice Total amount of outstanding borrows of the underlying in this market
*/
uint public totalBorrows;
/**
* @notice Total amount of reserves of the underlying held in this market
*/
uint public totalReserves;
/**
* @notice Total number of tokens in circulation
*/
uint public totalSupply;
// Official record of token balances for each account
mapping (address => uint) internal accountTokens;
// Approved token transfer amounts on behalf of others
mapping (address => mapping (address => uint)) internal transferAllowances;
/**
* @notice Container for borrow balance information
* @member principal Total balance (with accrued interest), after applying the most recent balance-changing action
* @member interestIndex Global borrowIndex as of the most recent balance-changing action
* @member interestAccrued Total interest accrued for markets that track it separately from borrow balance
*/
struct BorrowSnapshot {
uint principal;
uint interestIndex;
uint interestAccrued;
}
// Mapping of account addresses to outstanding borrow balances
mapping(address => BorrowSnapshot) internal accountBorrows;
/**
* @notice Share of seized collateral that is added to reserves
*/
uint public protocolSeizeShareMantissa = 2.8e16; //2.8%
/**
* @notice MarketType enum
*/
enum MarketType {
UNDEFINED_MARKET,
ERC20_MARKET,
ERC721_MARKET,
ERC20_INTEREST_MARKET
}
/**
* @notice Indicates a token market type
*/
MarketType public marketType;
}
abstract contract CTokenInterface is CTokenStorage {
/**
* @notice Indicator that this is a CToken contract (for inspection)
*/
bool public constant isCToken = true;
/*** Market Events ***/
/**
* @notice Event emitted when interest is accrued
*/
event AccrueInterest(uint cashPrior, uint interestAccumulated, uint borrowIndex, uint totalBorrows);
/**
* @notice Event emitted when tokens are minted
*/
event Mint(address minter, uint mintAmount, uint mintTokens);
/**
* @notice Event emitted when tokens are redeemed
*/
event Redeem(address redeemer, uint redeemAmount, uint redeemTokens);
/**
* @notice Event emitted when underlying is borrowed
*/
event Borrow(address borrower, uint borrowAmount, uint accountBorrows, uint totalBorrows);
/**
* @notice Event emitted when a borrow is repaid
*/
event RepayBorrow(address payer, address borrower, uint repayAmount, uint accountBorrows, uint totalBorrows);
/**
* @notice Event emitted when a borrow is liquidated
*/
event LiquidateBorrow(address liquidator, address borrower, uint repayAmount);
/*** Admin Events ***/
/**
* @notice Event emitted when pendingAdmin is changed
*/
event NewPendingAdmin(address oldPendingAdmin, address newPendingAdmin);
/**
* @notice Event emitted when pendingAdmin is accepted, which means admin is updated
*/
event NewAdmin(address oldAdmin, address newAdmin);
/**
* @notice Event emitted when comptroller is changed
*/
event NewComptroller(ComptrollerInterface oldComptroller, ComptrollerInterface newComptroller);
/**
* @notice Event emitted when interestRateModel is changed
*/
event NewMarketInterestRateModel(InterestRateModel oldInterestRateModel, InterestRateModel newInterestRateModel);
/**
* @notice Event emitted when the seize share is changed
*/
event NewProtocolSeizeShare(uint oldProtocolSeizeShareMantissa, uint newProtocolSeizeShareMantissa);
/**
* @notice Event emitted when the reserve factor is changed
*/
event NewReserveFactor(uint oldReserveFactorMantissa, uint newReserveFactorMantissa);
/**
* @notice Event emitted when the reserves are added
*/
event ReservesAdded(address benefactor, uint addAmount, uint newTotalReserves);
/**
* @notice Event emitted when the reserves are reduced
*/
event ReservesReduced(address admin, uint reduceAmount, uint newTotalReserves);
/**
* @notice EIP20 Transfer event
*/
event Transfer(address indexed from, address indexed to, uint amount);
/**
* @notice EIP20 Approval event
*/
event Approval(address indexed owner, address indexed spender, uint amount);
/*** User Interface ***/
function transfer(address dst, uint amount) virtual external returns (bool);
function transferFrom(address src, address dst, uint amount) virtual external returns (bool);
function approve(address spender, uint amount) virtual external returns (bool);
function allowance(address owner, address spender) virtual external view returns (uint);
function balanceOf(address owner) virtual external view returns (uint);
function balanceOfUnderlying(address owner) virtual external returns (uint);
function getAccountSnapshot(address account) virtual external view returns (uint, uint, uint, uint, uint);
function borrowRatePerBlock() virtual external view returns (uint);
function supplyRatePerBlock() virtual external view returns (uint);
function totalBorrowsCurrent() virtual external returns (uint);
function borrowBalanceCurrent(address account) virtual external returns (uint);
function borrowBalanceStored(address account) virtual external view returns (uint);
function exchangeRateCurrent() virtual external returns (uint);
function exchangeRateStored() virtual external view returns (uint);
function getCash() virtual external view returns (uint);
function accrueInterest() virtual external returns (uint);
function _seize(address liquidator, address borrower, uint seizeTokens) virtual external returns (uint);
function sweepToken(EIP20NonStandardInterface token) virtual external;
/*** Admin Functions ***/
function _setPendingAdmin(address payable newPendingAdmin) virtual external returns (uint);
function _acceptAdmin() virtual external returns (uint);
function _setComptroller(ComptrollerInterface newComptroller) virtual external returns (uint);
function _setProtocolSeizeShare(uint newProtocolSeizeShareMantissa) virtual external returns (uint);
function _setReserveFactor(uint newReserveFactorMantissa) virtual external returns (uint);
function _reduceReserves(uint reduceAmount) virtual external returns (uint);
function _setInterestRateModel(InterestRateModel newInterestRateModel) virtual external returns (uint);
}
contract CErc20Storage {
/**
* @notice Underlying asset for this CToken
*/
address public underlying;
}
abstract contract CErc20Interface is CErc20Storage {
/*** User Interface ***/
function mint(uint mintAmount) virtual external returns (uint);
function redeem(uint redeemTokens) virtual external returns (uint);
function redeemUnderlying(uint redeemAmount) virtual external returns (uint);
function borrow(uint borrowAmount) virtual external returns (uint);
function repayBorrow(uint repayAmount) virtual external returns (uint);
function repayBorrowBehalf(address borrower, uint repayAmount) virtual external returns (uint);
function _liquidateBorrow(address liquidator, address borrower, uint repayAmount) virtual external returns (uint);
/*** Admin Functions ***/
function _addReserves(uint addAmount) virtual external returns (uint);
}
interface IWeth {
function transferFrom(address src, address dst, uint wad) external;
function withdraw(uint256 wad) external;
}
abstract contract CEtherInterface is CErc20Storage {
/*** User Interface ***/
function mint() virtual external payable;
function redeem(uint redeemTokens) virtual external returns (uint);
function redeemUnderlying(uint redeemAmount) virtual external returns (uint);
function borrow(uint borrowAmount) virtual external returns (uint);
function repayBorrow() virtual external payable;
function repayBorrowBehalf(address borrower) virtual external payable;
function _liquidateBorrow(address liquidator, address borrower, uint repayAmount) virtual external returns (uint);
/*** Admin Functions ***/
function _addReserves() virtual external payable returns (uint);
}
contract CDelegationStorage {
/**
* @notice Implementation address for this contract
*/
address public implementation;
}
abstract contract CDelegatorInterface is CDelegationStorage {
/**
* @notice Emitted when implementation is changed
*/
event NewImplementation(address oldImplementation, address newImplementation);
error CannotReceiveValueGtZero();
/**
* @notice Called by the admin to update the implementation of the delegator
* @param implementation_ The address of the new implementation for delegation
* @param allowResign Flag to indicate whether to call _resignImplementation on the old implementation
* @param becomeImplementationData The encoded bytes data to be passed to _becomeImplementation
*/
function _setImplementation(address implementation_, bool allowResign, bytes memory becomeImplementationData) virtual external;
}
abstract contract CDelegateInterface is CDelegationStorage {
/**
* @notice Called by the delegator on a delegate to initialize it for duty
* @dev Should revert if any issues arise which make it unfit for delegation
* @param data The encoded bytes data for any initialization
*/
function _becomeImplementation(bytes memory data) virtual external;
/**
* @notice Called by the delegator on a delegate to forfeit its responsibility
*/
function _resignImplementation() virtual external;
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
abstract contract ComptrollerInterface {
/// @notice Indicator that this is a Comptroller contract (for inspection)
bool public constant isComptroller = true;
/*** Assets You Are In ***/
function autoEnterMarkets(address account) virtual external;
function autoExitMarkets(address account) virtual external;
function enterMarkets(address[] calldata cTokens) virtual external returns (uint[] memory);
function exitMarket(address cToken) virtual external returns (uint);
function redeemAllInterest(address lender, address[] memory cTokens) virtual external returns (uint[] memory);
/*** Policy Hooks ***/
function mintAllowed(address cToken, address minter, uint mintAmount) virtual external returns (uint);
function redeemAllowed(address cToken, address redeemer, uint redeemTokens) virtual external returns (uint);
function borrowAllowed(address cToken, address borrower, uint borrowAmount) virtual external returns (uint);
function repayBorrowAllowed(
address cToken,
address payer,
address borrower,
uint repayAmount) virtual external returns (uint);
function collectInterestAllowed(
address cTokenInterestMarket,
address cTokenSupplyMarket,
address lender,
uint interestAmount) virtual external returns (uint);
function payInterestAllowed(
address cTokenInterestMarket,
address cTokenBorrowMarket,
address payer,
uint payTokens) virtual external returns (uint);
function transferAllowed(address cToken, address src, address dst, uint transferTokens) virtual external returns (uint);
function isListed(address cToken) virtual external view returns (bool);
function getAssetsExchangeRate(address cTokenA, address cTokenB) virtual external view returns (uint);
function _checkEoaOrWL(address msgSender) virtual external view returns (bool);
/*** Liquidity/Liquidation Calculations ***/
struct Liquidatables {
address cToken; // token to liquidate
uint amount; // non-NFT markets
uint[] nftIds; // NFT markets
}
function topUpInterestShortfall(address borrower, uint maxTopUpTokens, address cTokenCollateral) virtual external returns (uint[2] memory);
function batchLiquidateBorrow(address borrower, Liquidatables[] memory liquidatables, address[] memory cTokenCollaterals, uint minSeizedValue) virtual external returns (uint[][2] memory results);
function liquidateCalculateSeizeTokensNormed(address cTokenCollateral, uint normedRepayAmount) virtual public view returns (uint);
function interestMarket() virtual external view returns (address);
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
/**
* @title Compound's InterestRateModel Interface
* @author Compound
*/
abstract contract InterestRateModel {
/// @notice Indicator that this is an InterestRateModel contract (for inspection)
bool public constant isInterestRateModel = true;
/**
* @notice Calculates the current borrow interest rate per block
* @param cash The total amount of cash the market has
* @param borrows The total amount of borrows the market has outstanding
* @param reserves The total amount of reserves the market has
* @return The borrow rate per block (as a percentage, and scaled by 1e18)
*/
function getBorrowRate(uint cash, uint borrows, uint reserves) virtual public view returns (uint);
/**
* @notice Calculates the current supply interest rate per block
* @param cash The total amount of cash the market has
* @param borrows The total amount of borrows the market has outstanding
* @param reserves The total amount of reserves the market has
* @param reserveFactorMantissa The current reserve factor the market has
* @return The supply rate per block (as a percentage, and scaled by 1e18)
*/
function getSupplyRate(uint cash, uint borrows, uint reserves, uint reserveFactorMantissa) virtual public view returns (uint);
/**
* @notice Calculates the current borrow and supply rate per block
* @param cash The amount of cash in the market
* @param borrows The amount of borrows in the market
* @param reserves The amount of reserves in the market
* @param reserveFactorMantissa The current reserve factor for the market
* @return (uint, uint) The borrow rate percentage per block as a mantissa (scaled by BASE),
* supply rate percentage per block as a mantissa (scaled by BASE)
*/
function getMarketRates(uint cash, uint borrows, uint reserves, uint reserveFactorMantissa) virtual public view returns (uint, uint) {
return (getBorrowRate(cash, borrows, reserves), getSupplyRate(cash, borrows, reserves, reserveFactorMantissa));
}
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
/**
* @title EIP20NonStandardInterface
* @dev Version of ERC20 with no return values for `transfer` and `transferFrom`
* See https://medium.com/coinmonks/missing-return-value-bug-at-least-130-tokens-affected-d67bf08521ca
*/
interface EIP20NonStandardInterface {
/**
* @notice Get the total number of tokens in circulation
* @return The supply of tokens
*/
function totalSupply() external view returns (uint256);
/**
* @notice Gets the balance of the specified address
* @param owner The address from which the balance will be retrieved
* @return balance The balance
*/
function balanceOf(address owner) external view returns (uint256 balance);
///
/// !!!!!!!!!!!!!!
/// !!! NOTICE !!! `transfer` does not return a value, in violation of the ERC-20 specification
/// !!!!!!!!!!!!!!
///
/**
* @notice Transfer `amount` tokens from `msg.sender` to `dst`
* @param dst The address of the destination account
* @param amount The number of tokens to transfer
*/
function transfer(address dst, uint256 amount) external;
///
/// !!!!!!!!!!!!!!
/// !!! NOTICE !!! `transferFrom` does not return a value, in violation of the ERC-20 specification
/// !!!!!!!!!!!!!!
///
/**
* @notice Transfer `amount` tokens from `src` to `dst`
* @param src The address of the source account
* @param dst The address of the destination account
* @param amount The number of tokens to transfer
*/
function transferFrom(address src, address dst, uint256 amount) external;
/**
* @notice Approve `spender` to transfer up to `amount` from `src`
* @dev This will overwrite the approval amount for `spender`
* and is subject to issues noted [here](https://eips.ethereum.org/EIPS/eip-20#approve)
* @param spender The address of the account which may transfer tokens
* @param amount The number of tokens that are approved
* @return success Whether or not the approval succeeded
*/
function approve(address spender, uint256 amount) external returns (bool success);
/**
* @notice Get the current allowance from `owner` for `spender`
* @param owner The address of the account which owns the tokens to be spent
* @param spender The address of the account which may transfer tokens
* @return remaining The number of tokens allowed to be spent
*/
function allowance(address owner, address spender) external view returns (uint256 remaining);
event Transfer(address indexed from, address indexed to, uint256 amount);
event Approval(address indexed owner, address indexed spender, uint256 amount);
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
contract ComptrollerErrorReporter {
enum Error {
NO_ERROR,
UNAUTHORIZED,
COMPTROLLER_MISMATCH,
INSUFFICIENT_SHORTFALL,
INSUFFICIENT_LIQUIDITY,
INVALID_CLOSE_FACTOR,
INVALID_COLLATERAL_FACTOR,
INVALID_LIQUIDATION_INCENTIVE,
MARKET_NOT_ENTERED, // no longer possible
MARKET_NOT_LISTED,
MARKET_ALREADY_LISTED,
MATH_ERROR,
NONZERO_BORROW_BALANCE,
PRICE_ERROR,
REJECTION,
SNAPSHOT_ERROR,
TOO_MANY_ASSETS,
TOO_MUCH_REPAY,
INVALID_MARKET_TYPE,
TOO_LITTLE_INTEREST_RESERVE,
NONZERO_INTEREST_BALANCE,
LIQUIDATE_SEIZE_TOO_LITTLE
}
enum FailureInfo {
ACCEPT_ADMIN_PENDING_ADMIN_CHECK,
ACCEPT_PENDING_IMPLEMENTATION_ADDRESS_CHECK,
EXIT_MARKET_BALANCE_OWED,
EXIT_MARKET_REJECTION,
SET_CLOSE_FACTOR_OWNER_CHECK,
SET_CLOSE_FACTOR_VALIDATION,
SET_COLLATERAL_FACTOR_OWNER_CHECK,
SET_COLLATERAL_FACTOR_NO_EXISTS,
SET_COLLATERAL_FACTOR_VALIDATION,
SET_COLLATERAL_FACTOR_WITHOUT_PRICE,
SET_IMPLEMENTATION_OWNER_CHECK,
SET_LIQUIDATION_INCENTIVE_OWNER_CHECK,
SET_LIQUIDATION_INCENTIVE_VALIDATION,
SET_MAX_ASSETS_OWNER_CHECK,
SET_PENDING_ADMIN_OWNER_CHECK,
SET_PENDING_IMPLEMENTATION_OWNER_CHECK,
SET_PRICE_ORACLE_OWNER_CHECK,
SUPPORT_MARKET_EXISTS,
SUPPORT_MARKET_OWNER_CHECK,
SET_PAUSE_GUARDIAN_OWNER_CHECK
}
/**
* @dev `error` corresponds to enum Error; `info` corresponds to enum FailureInfo, and `detail` is an arbitrary
* contract-specific code that enables us to report opaque error codes from upgradeable contracts.
**/
event Failure(uint error, uint info, uint detail);
error Unauthorized();
error InitializationFailed();
error GetAccountSnapshotFailed(uint256 errorCode);
error SeizePaused();
error MintPaused();
error BorrowPaused();
error CollectInterestPaused();
error PayInterestPaused();
error TransferPaused();
error InsufficientShortfall(uint errorCode, uint value);
error InvalidTopUpLimit();
error TopUpLimitExceeded();
error TopUpZero();
error SeizeFailed();
error TopUpFailed();
error LiquidateError();
error LiquidateSeizeTooLittle();
error LiquidateSeizeTooMuch();
error LiquidateSeizeBellowMinValue(uint minSeizedValue, uint liquidatedValueTotal);
error ExcessRefundFailed();
error BorrowCapReached();
error MarketAlreadyAdded();
error InvalidInput();
error OnlyAdminCanUnpause();
error ChangeNotAuthorized();
error MarketNotListed();
error SameMarket();
error WrongMarketType();
error PriceError();
error ComptrollerMismatch();
error InvalidMarket();
/**
* @dev use this when reporting a known error from the money market or a non-upgradeable collaborator
*/
function fail(Error err, FailureInfo info) internal returns (uint) {
emit Failure(uint(err), uint(info), 0);
return uint(err);
}
/**
* @dev use this when reporting an opaque error from an upgradeable collaborator contract
*/
function failOpaque(Error err, FailureInfo info, uint opaqueError) internal returns (uint) {
emit Failure(uint(err), uint(info), opaqueError);
return uint(err);
}
}
contract TokenErrorReporter {
uint public constant NO_ERROR = 0; // support legacy return codes
error Unauthorized();
error Unsupported();
error AlreadyInitialized();
error InitializeExchangeRateInvalid();
error InitializeSetComptrollerFailed(uint256 errorCode);
error InitializeSetInterestRateModelFailed(uint256 errorCode);
error InitializeMarketTypeNotSet();
error InitializeInvalidMarketType();
error EnsureNonEmptyAmountTooSmall();
error TransferComptrollerRejection(uint256 errorCode);
error TransferNotAllowed();
error TransferNotEnough();
error TransferTooMuch();
error TransferInvalidAmount();
error TransferInFailed();
error InsufficientBalanceAfterTransfer();
error TransferOutFailed();
error TransferFailed();
error NftAmountTooHigh();
error NftNotFound(uint256 nftId);
error MintComptrollerRejection(uint256 errorCode);
error MintFreshnessCheck();
error RedeemComptrollerRejection(uint256 errorCode);
error RedeemFreshnessCheck();
error RedeemTransferOutNotPossible();
error RedeemInvalidInputs();
error RedeemTokensIsZero();
error BorrowComptrollerRejection(uint256 errorCode);
error BorrowFreshnessCheck();
error BorrowCashNotAvailable();
error RepayBorrowComptrollerRejection(uint256 errorCode);
error RepayBorrowFreshnessCheck();
error RepayTooHigh();
error LiquidateComptrollerRejection(uint256 errorCode);
error LiquidateFreshnessCheck();
error LiquidateCollateralFreshnessCheck();
error LiquidateAccrueBorrowInterestFailed(uint256 errorCode);
error LiquidateAccrueCollateralInterestFailed(uint256 errorCode);
error LiquidateLiquidatorIsBorrower();
error LiquidateCloseAmountIsZero();
error LiquidateCloseAmountIsUintMax();
error LiquidateRepayBorrowFreshFailed(uint256 errorCode);
error LiquidateSeizeComptrollerRejection(uint256 errorCode);
error LiquidateSeizeLiquidatorIsBorrower();
error AcceptAdminPendingAdminCheck();
error SetComptrollerOwnerCheck();
error SetPendingAdminOwnerCheck();
error SetReserveFactorAdminCheck();
error SetReserveFactorFreshCheck();
error SetReserveFactorBoundsCheck();
error AddReservesFactorFreshCheck(uint256 actualAddAmount);
error ReduceReservesAdminCheck();
error ReduceReservesFreshCheck();
error ReduceReservesCashNotAvailable();
error ReduceReservesCashValidation();
error SetInterestRateModelOwnerCheck();
error SetInterestRateModelFreshCheck();
error SetProtocolSeizeShareAdminCheck();
error SetProtocolSeizeShareTooHigh();
error BorrowRateIsAbsurdlyHigh(uint borrowRateMantissa);
error InvalidComptrollerAddress(address comptrollerAddress);
error InvalidRateModelAddress(address interestRateModelAddress);
error Reentry();
error CannotSweepUnderlying();
error CollectInterestFailed();
error CollectInterestNotAllowed();
error PayInterestNotAllowed();
error InsufficientBalance();
error PayInterestError();
error SenderMismatch();
error ValueMismatch();
error PriceError();
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
import "contracts/CErc20InterestMarketInterfaces.sol";
contract CErc721Storage {
/**
* @notice NFTs supplied
*/
uint[] public heldNFTs;
/**
* @notice Accumulator of the total earned interest rate by suppliers since the opening of the market
*/
uint public supplyIndex;
struct SupplyInterestSnapshot {
uint interestIndex;
uint interestAccrued;
}
mapping(address => SupplyInterestSnapshot) internal supplyInterest;
/**
* @notice NFTs supplied per user
*/
uint public userHeldNFTCount;
mapping(address => uint[]) public userHeldNFTs;
}
abstract contract CErc721Interface is CErc20Interface, CErc721Storage {
/**
* @notice Event emitted when interest tokens are redeemed
*/
event RedeemInterest(address redeemer, uint redeemInterest, uint redeemTokens);
/**
* @notice Not supported. Use mint(uint[]) instead.
*/
function mint(uint) override external returns (uint) {
revert TokenErrorReporter.Unsupported();
}
/**
* @notice Sender supplies assets into the market and receives cTokens in exchange
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param nftIds The NFT IDs to supply
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function mint(uint[] memory nftIds) virtual external returns (uint);
/**
* @notice Redeems the interest accrued from the supplied assets. Owed interest will also be paid from this amount.
* @param redeemer The address to redeem the interest for
* If the caller is not the comptroller the sender is the redeemer.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemInterest(address redeemer) virtual external returns (uint);
/**
* @notice Redeems the interest accrued from the supplied assets. Owed interest will also be paid from this amount.
* @param redeemer The address to redeem the interest for
* Only the comptroller can call.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function _redeemInterestForLiquidation(address redeemer) virtual external returns (uint);
/**
* @notice Not supported. Use repayBorrow(uint[], uint) instead.
*/
function repayBorrow(uint) override external returns (uint) {
revert TokenErrorReporter.Unsupported();
}
/**
* @notice Sender repays their own borrow
* @param nftIds The NFT IDs to be used for the repayment
* @param repayInterest The min amount of interest to be repaid in interest market units
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function repayBorrow(uint[] memory nftIds, uint repayInterest) virtual external returns (uint);
/**
* @notice Not supported. Use repayBorrowBehalf(address, uint[], uint) instead.
*/
function repayBorrowBehalf(address, uint) override external returns (uint) {
revert TokenErrorReporter.Unsupported();
}
/**
* @notice Repays a loan on behalf of another user
* @param borrower The account with the debt being payed off
* @param nftIds The NFT IDs to be used for the repayment
* @param repayInterest The min amount of interest to be repaid in interest market units
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function repayBorrowBehalf(address borrower, uint[] memory nftIds, uint repayInterest) virtual external returns (uint);
/**
* @notice Not supported.
*/
function _addReserves(uint addAmount) override external returns (uint) {
revert TokenErrorReporter.Unsupported();
}
/**
* @notice Not supported. Use _liquidateBorrow(address, address, uint[]) instead.
*/
function _liquidateBorrow(address liquidator, address borrower, uint repayAmount) override external returns (uint) {
revert TokenErrorReporter.Unsupported();
}
/**
* @notice The liquidator liquidates the borrowers collateral.
* This function can only be called by the Comptroller.
* @param liquidator The liquidator who called Comptroller::batchLiquidateBorrow
* @param borrower The borrower of this cToken to be liquidated
* @param nftIds The NFT IDs of the underlying borrowed asset to repay
* @return uint The amount of the underlying borrowed asset that was actually repaid
*/
function _liquidateBorrow(address liquidator, address borrower, uint[] memory nftIds) virtual external returns (uint);
event Mint(address minter, uint mintAmount, uint mintTokens, uint[] nftIds);
event Redeem(address redeemer, uint redeemAmount, uint redeemTokens, uint[] nftIds);
event Borrow(address borrower, uint[] nftIds, uint accountBorrows, uint totalBorrows);
event RepayBorrow(address payer, address borrower, uint[] nftIds, uint repayInterest, uint accountBorrows, uint totalBorrows);
event LiquidateBorrow(address liquidator, address borrower, uint[] nftIds, uint repayInterest);
}
abstract contract CErc721NoBorrowInterface {
/**
* @notice Sender redeems cTokens in exchange for a specified amount of underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param nftIds The NFT IDs to redeem
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemUnderlyingNfts(uint[] memory nftIds) virtual external returns (uint);
}// SPDX-License-Identifier: BSD-3-Clause
pragma solidity 0.8.23;
import "contracts/CTokenInterfaces.sol";
contract CErc20InterestMarketStorage {
uint public totalVirtual;
}
abstract contract CErc20InterestMarketInterface is CErc20Interface, CErc20InterestMarketStorage {
/**
* @notice Collect the interest from supplied ERC721 tokens for the lender and adds them to his supply.
* Must be called by the supply market.
* @param lender The address for which the interest should be collected
* @param interestTokens The amount of market tokens to claim
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function collectInterest(address lender, uint interestTokens) virtual external returns (uint);
/**
* @notice Pay the interest for borrowed ERC721 tokens.
* Must be called by the borrow market.
* @param payer The address that pays the interest
* @param interestTokens The amount of market tokens to pay
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function payInterest(address payer, uint interestTokens) virtual external returns (uint);
/**
* @notice Sender claims interest from NFT markets then redeems cTokens in exchange for the underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param redeemTokens The number of cTokens to redeem into underlying
* @param cTokens The list of cToken addresses to redeem interest from.
* Only possible for cErc721 markets.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemWithClaim(uint redeemTokens, address[] memory cTokens) virtual external returns (uint);
/**
* @notice Sender claims interest from NFT markets then redeems cTokens in exchange for a specified amount of underlying asset
* @dev Accrues interest whether or not the operation succeeds, unless reverted
* @param redeemAmount The amount of underlying to redeem
* @param cTokens The list of cToken addresses to redeem interest from.
* Only possible for cErc721 markets.
* @return uint 0=success, otherwise a failure (see ErrorReporter.sol for details)
*/
function redeemUnderlyingWithClaim(uint redeemAmount, address[] memory cTokens) virtual external returns (uint);
event CollectInterest(address supplyMarket, address lender, uint interestTokens);
event PayInterest(address borrowMarket, address payer, uint interestTokens);
}{
"evmVersion": "shanghai",
"optimizer": {
"enabled": true,
"runs": 200
},
"libraries": {
"CErc721NoBorrowDelegator.sol": {}
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"underlying_","type":"address"},{"internalType":"contract ComptrollerInterface","name":"comptroller_","type":"address"},{"internalType":"contract InterestRateModel","name":"interestRateModel_","type":"address"},{"internalType":"uint256","name":"initialExchangeRateMantissa_","type":"uint256"},{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint8","name":"decimals_","type":"uint8"},{"internalType":"address payable","name":"admin_","type":"address"},{"internalType":"address","name":"implementation_","type":"address"},{"internalType":"bytes","name":"becomeImplementationData","type":"bytes"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"CannotReceiveValueGtZero","type":"error"},{"inputs":[],"name":"Unauthorized","type":"error"},{"inputs":[],"name":"Unsupported","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"cashPrior","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"interestAccumulated","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"borrowIndex","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalBorrows","type":"uint256"}],"name":"AccrueInterest","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256","name":"accountBorrows","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalBorrows","type":"uint256"}],"name":"Borrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256","name":"borrowAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"accountBorrows","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalBorrows","type":"uint256"}],"name":"Borrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"liquidator","type":"address"},{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256","name":"repayInterest","type":"uint256"}],"name":"LiquidateBorrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"liquidator","type":"address"},{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256","name":"repayAmount","type":"uint256"}],"name":"LiquidateBorrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"minter","type":"address"},{"indexed":false,"internalType":"uint256","name":"mintAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"mintTokens","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"minter","type":"address"},{"indexed":false,"internalType":"uint256","name":"mintAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"mintTokens","type":"uint256"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"NewAdmin","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract ComptrollerInterface","name":"oldComptroller","type":"address"},{"indexed":false,"internalType":"contract ComptrollerInterface","name":"newComptroller","type":"address"}],"name":"NewComptroller","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldImplementation","type":"address"},{"indexed":false,"internalType":"address","name":"newImplementation","type":"address"}],"name":"NewImplementation","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract InterestRateModel","name":"oldInterestRateModel","type":"address"},{"indexed":false,"internalType":"contract InterestRateModel","name":"newInterestRateModel","type":"address"}],"name":"NewMarketInterestRateModel","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldPendingAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newPendingAdmin","type":"address"}],"name":"NewPendingAdmin","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldProtocolSeizeShareMantissa","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newProtocolSeizeShareMantissa","type":"uint256"}],"name":"NewProtocolSeizeShare","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"oldReserveFactorMantissa","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newReserveFactorMantissa","type":"uint256"}],"name":"NewReserveFactor","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"redeemer","type":"address"},{"indexed":false,"internalType":"uint256","name":"redeemAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"redeemTokens","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"Redeem","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"redeemer","type":"address"},{"indexed":false,"internalType":"uint256","name":"redeemAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"redeemTokens","type":"uint256"}],"name":"Redeem","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"redeemer","type":"address"},{"indexed":false,"internalType":"uint256","name":"redeemInterest","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"redeemTokens","type":"uint256"}],"name":"RedeemInterest","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"payer","type":"address"},{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"},{"indexed":false,"internalType":"uint256","name":"repayInterest","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"accountBorrows","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalBorrows","type":"uint256"}],"name":"RepayBorrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"payer","type":"address"},{"indexed":false,"internalType":"address","name":"borrower","type":"address"},{"indexed":false,"internalType":"uint256","name":"repayAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"accountBorrows","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"totalBorrows","type":"uint256"}],"name":"RepayBorrow","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"benefactor","type":"address"},{"indexed":false,"internalType":"uint256","name":"addAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newTotalReserves","type":"uint256"}],"name":"ReservesAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"uint256","name":"reduceAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newTotalReserves","type":"uint256"}],"name":"ReservesReduced","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Transfer","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[],"name":"_acceptAdmin","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"addAmount","type":"uint256"}],"name":"_addReserves","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"repayAmount","type":"uint256"}],"name":"_liquidateBorrow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"_liquidateBorrow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"redeemer","type":"address"}],"name":"_redeemInterestForLiquidation","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"reduceAmount","type":"uint256"}],"name":"_reduceReserves","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"liquidator","type":"address"},{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256","name":"seizeTokens","type":"uint256"}],"name":"_seize","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract ComptrollerInterface","name":"newComptroller","type":"address"}],"name":"_setComptroller","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"implementation_","type":"address"},{"internalType":"bool","name":"allowResign","type":"bool"},{"internalType":"bytes","name":"becomeImplementationData","type":"bytes"}],"name":"_setImplementation","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract InterestRateModel","name":"newInterestRateModel","type":"address"}],"name":"_setInterestRateModel","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"newPendingAdmin","type":"address"}],"name":"_setPendingAdmin","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newProtocolSeizeShareMantissa","type":"uint256"}],"name":"_setProtocolSeizeShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newReserveFactorMantissa","type":"uint256"}],"name":"_setReserveFactor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"accrualBlockNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"accrueInterest","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOfUnderlying","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"borrowNFTCount","type":"uint256"}],"name":"borrow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"borrowAndInterestBalanceCurrent","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"borrowAndInterestBalanceStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"borrowBalanceCurrent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"borrowBalanceStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"borrowIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"borrowRatePerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"comptroller","outputs":[{"internalType":"contract ComptrollerInterface","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"name":"delegateToImplementation","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"data","type":"bytes"}],"name":"delegateToViewImplementation","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exchangeRateCurrent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"exchangeRateStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getAccountSnapshot","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCash","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNFTsHeld","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNFTsHeldByUser","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"heldNFTs","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"implementation","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"interestRateModel","outputs":[{"internalType":"contract InterestRateModel","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isCToken","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"marketType","outputs":[{"internalType":"enum CTokenStorage.MarketType","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"mint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"mint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingAdmin","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"protocolSeizeShareMantissa","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"redeemTokens","type":"uint256"}],"name":"redeem","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"redeemer","type":"address"}],"name":"redeemInterest","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"redeemNFTCount","type":"uint256"}],"name":"redeemUnderlying","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"redeemUnderlyingNfts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"repayBorrow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"},{"internalType":"uint256","name":"repayInterest","type":"uint256"}],"name":"repayBorrow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"repayBorrowBehalf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"borrower","type":"address"},{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"},{"internalType":"uint256","name":"repayInterest","type":"uint256"}],"name":"repayBorrowBehalf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"reserveFactorMantissa","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"supplyIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"supplyInterestCurrent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"supplyInterestStored","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"supplyRatePerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract EIP20NonStandardInterface","name":"token","type":"address"}],"name":"sweepToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBorrows","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBorrowsCurrent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalReserves","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"dst","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"src","type":"address"},{"internalType":"address","name":"dst","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"underlying","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"userHeldNFTCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"userHeldNFTs","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]Contract Creation Code
6080604052666379da05b600006011553480156200001b575f80fd5b5060405162002979380380620029798339810160408190526200003e91620003ac565b60038054610100600160a81b0319163361010002179055604051620000af9083906200007b908d908d908d908d908d908d908d90602401620004de565b60408051601f198184030181529190526020810180516001600160e01b03908116631a31d46560e01b17909152620000f316565b50620000bd825f836200016b565b5050600380546001600160a01b0390921661010002610100600160a81b0319909216919091179055506200057e95505050505050565b60605f80846001600160a01b03168460405162000111919062000546565b5f60405180830381855af49150503d805f81146200014b576040519150601f19603f3d011682016040523d82523d5f602084013e62000150565b606091505b5090925090508162000163573d60208201fd5b949350505050565b60035461010090046001600160a01b031633146200019b576040516282b42960e81b815260040160405180910390fd5b8115620001dd576040805160048152602481019091526020810180516001600160e01b0390811663153ab50560e01b17909152620001db91906200029816565b505b601880546001600160a01b038581166001600160a01b03198316179092556040519116906200024a906200021690849060240162000563565b60408051601f198184030181529190526020810180516001600160e01b03908116630adccee560e31b179091526200029816565b50601854604080516001600160a01b03808516825290921660208301527fd604de94d45953f9138079ec1b82d533cb2160c906d1076d1f7ed54befbca97a910160405180910390a150505050565b601854606090620002b3906001600160a01b031683620000f3565b92915050565b80516001600160a01b0381168114620002d0575f80fd5b919050565b634e487b7160e01b5f52604160045260245ffd5b5f5b8381101562000305578181015183820152602001620002eb565b50505f910152565b5f82601f8301126200031d575f80fd5b81516001600160401b03808211156200033a576200033a620002d5565b604051601f8301601f19908116603f01168101908282118183101715620003655762000365620002d5565b816040528381528660208588010111156200037e575f80fd5b62000391846020830160208901620002e9565b9695505050505050565b805160ff81168114620002d0575f80fd5b5f805f805f805f805f806101408b8d031215620003c7575f80fd5b620003d28b620002b9565b9950620003e260208c01620002b9565b9850620003f260408c01620002b9565b60608c015160808d015191995097506001600160401b038082111562000416575f80fd5b620004248e838f016200030d565b975060a08d01519150808211156200043a575f80fd5b620004488e838f016200030d565b96506200045860c08e016200039b565b95506200046860e08e01620002b9565b9450620004796101008e01620002b9565b93506101208d015191508082111562000490575f80fd5b506200049f8d828e016200030d565b9150509295989b9194979a5092959850565b5f8151808452620004ca816020860160208601620002e9565b601f01601f19169290920160200192915050565b6001600160a01b0388811682528781166020830152861660408201526060810185905260e0608082018190525f906200051a90830186620004b1565b82810360a08401526200052e8186620004b1565b91505060ff831660c083015298975050505050505050565b5f825162000559818460208701620002e9565b9190910192915050565b602081525f620005776020830184620004b1565b9392505050565b6123ed806200058c5f395ff3fe60806040526004361061040f575f3560e01c806370a082311161021d578063b71d1a0c11610122578063e9c714f2116100aa578063f851a44011610079578063f851a44014610c42578063f8e93ef914610c66578063f8f9da2814610c85578063fca7820b14610c99578063fe9c44ae14610cb85761040f565b8063e9c714f214610bd1578063f16bfc6f14610be5578063f2b3abbd14610c04578063f3fdb15a14610c235761040f565b8063c5ebeaec116100f1578063c5ebeaec14610b41578063ceed311214610b60578063db006a7514610b7f578063dd62ed3e14610b9e578063e91dcfd114610bbd5761040f565b8063b71d1a0c14610aa8578063bd6d894d14610ac7578063c281f00b14610adb578063c37f68e214610afa5761040f565b8063949b9148116101a5578063a0712d6811610174578063a0712d681461051e578063a6afed9514610a4c578063a9059cbb14610a60578063aa5af0fd14610a7f578063ae9d70b014610a945761040f565b8063949b9148146109e557806395d89b4114610a0457806395dd919314610a1857806398f1bc1214610a375761040f565b806383030846116101ec5780638303084614610951578063852a12e31461097057806385a050bc1461098f5780638ecde492146109bb5780638f840ddd146109d05761040f565b806370a08231146108e0578063734090ee146108ff57806373acee981461091e5780637c409a37146109325761040f565b80632e85fb4111610323578063555bcc40116102ab578063654288f51161027a578063654288f5146108545780636752e702146108735780636c540baf146108885780636f307dc31461089d5780636ff2bf2b146108c15761040f565b8063555bcc40146107d85780635c60da1b146107f75780635fe3b56714610816578063601a0bf1146108355761040f565b80633b1d21a2116102f25780633b1d21a2146107715780633e9410101461051e5780634487152f146107855780634576b5db146107a457806347bd3718146107c35761040f565b80632e85fb41146106d4578063313ce567146106f3578063371159fe1461071e5780633af9e669146107525761040f565b806318160ddd116103a65780631be19560116103755780631be195601461061f57806323b872dd1461063e5780632608f8181461065d57806326782247146106775780632dd48909146106ae5761040f565b806318160ddd146105bd578063182df0f5146105d257806319caf46c146105e657806319d1b799146106055761040f565b80630e7d0586116103e25780630e7d05861461054b57806316d812f61461056a578063173b99041461058957806317bfdfbc1461059e5761040f565b806306fdde03146104a65780630933c1ed146104d0578063095ea7b3146104ef5780630e7527021461051e575b341561042e57604051635ffd892360e11b815260040160405180910390fd5b6018546040515f916001600160a01b03169061044d9083903690611c96565b5f60405180830381855af49150503d805f8114610485576040519150601f19603f3d011682016040523d82523d5f602084013e61048a565b606091505b505090506040513d5f823e8180156104a0573d82f35b3d82fd5b005b3480156104b1575f80fd5b506104ba610ccc565b6040516104c79190611cf2565b60405180910390f35b3480156104db575f80fd5b506104ba6104ea366004611dc2565b610d58565b3480156104fa575f80fd5b5061050e610509366004611e0b565b610d77565b60405190151581526020016104c7565b348015610529575f80fd5b5061053d610538366004611e35565b610de8565b6040519081526020016104c7565b348015610556575f80fd5b5061053d610565366004611ed6565b610e02565b348015610575575f80fd5b5061053d610584366004611e35565b610e64565b348015610594575f80fd5b5061053d60085481565b3480156105a9575f80fd5b5061053d6105b8366004611f08565b610e83565b3480156105c8575f80fd5b5061053d600d5481565b3480156105dd575f80fd5b5061053d610ecf565b3480156105f1575f80fd5b5061053d610600366004611f08565b610f21565b348015610610575f80fd5b5061053d610538366004611f23565b34801561062a575f80fd5b506104a4610639366004611f08565b610f6d565b348015610649575f80fd5b5061050e610658366004611f23565b610fb8565b348015610668575f80fd5b5061053d610538366004611e0b565b348015610682575f80fd5b50600454610696906001600160a01b031681565b6040516001600160a01b0390911681526020016104c7565b3480156106b9575f80fd5b506012546106c79060ff1681565b6040516104c79190611f61565b3480156106df575f80fd5b5061053d6106ee366004611f23565b611032565b3480156106fe575f80fd5b5060035461070c9060ff1681565b60405160ff90911681526020016104c7565b348015610729575f80fd5b5061073d610738366004611f08565b6110a3565b604080519283526020830191909152016104c7565b34801561075d575f80fd5b5061053d61076c366004611f08565b611111565b34801561077c575f80fd5b5061053d61115d565b348015610790575f80fd5b506104ba61079f366004611dc2565b61118f565b3480156107af575f80fd5b5061053d6107be366004611f08565b611246565b3480156107ce575f80fd5b5061053d600b5481565b3480156107e3575f80fd5b506104a46107f2366004611f94565b611292565b348015610802575f80fd5b50601854610696906001600160a01b031681565b348015610821575f80fd5b50600554610696906001600160a01b031681565b348015610840575f80fd5b5061053d61084f366004611e35565b6113ae565b34801561085f575f80fd5b5061053d61086e366004611e0b565b6113f5565b34801561087e575f80fd5b5061053d60115481565b348015610893575f80fd5b5061053d60095481565b3480156108a8575f80fd5b506012546106969061010090046001600160a01b031681565b3480156108cc575f80fd5b5061073d6108db366004611f08565b611420565b3480156108eb575f80fd5b5061053d6108fa366004611f08565b61146e565b34801561090a575f80fd5b5061053d610919366004611f08565b6114ba565b348015610929575f80fd5b5061053d611506565b34801561093d575f80fd5b5061053d61094c366004611ff2565b61153c565b34801561095c575f80fd5b5061053d61096b366004611e35565b611599565b34801561097b575f80fd5b5061053d61098a366004611e35565b6115e0565b34801561099a575f80fd5b506109ae6109a9366004611f08565b611627565b6040516104c7919061206e565b3480156109c6575f80fd5b5061053d60165481565b3480156109db575f80fd5b5061053d600c5481565b3480156109f0575f80fd5b5061053d6109ff366004611f08565b61168a565b348015610a0f575f80fd5b506104ba6116d6565b348015610a23575f80fd5b5061053d610a32366004611f08565b6116e3565b348015610a42575f80fd5b5061053d60145481565b348015610a57575f80fd5b5061053d61172f565b348015610a6b575f80fd5b5061050e610a7a366004611e0b565b611765565b348015610a8a575f80fd5b5061053d600a5481565b348015610a9f575f80fd5b5061053d6117b8565b348015610ab3575f80fd5b5061053d610ac2366004611f08565b6117ee565b348015610ad2575f80fd5b5061053d61183a565b348015610ae6575f80fd5b5061053d610af5366004612080565b611870565b348015610b05575f80fd5b50610b19610b14366004611f08565b6118b9565b604080519586526020860194909452928401919091526060830152608082015260a0016104c7565b348015610b4c575f80fd5b5061053d610b5b366004611e35565b61193a565b348015610b6b575f80fd5b5061053d610b7a3660046120d5565b611981565b348015610b8a575f80fd5b5061053d610b99366004611e35565b6119ca565b348015610ba9575f80fd5b5061053d610bb8366004612129565b611a11565b348015610bc8575f80fd5b5061053d611a65565b348015610bdc575f80fd5b5061053d611a9b565b348015610bf0575f80fd5b5061053d610bff366004611f08565b611ad1565b348015610c0f575f80fd5b5061053d610c1e366004611f08565b611b1d565b348015610c2e575f80fd5b50600654610696906001600160a01b031681565b348015610c4d575f80fd5b506003546106969061010090046001600160a01b031681565b348015610c71575f80fd5b5061053d610c80366004611ed6565b611b69565b348015610c90575f80fd5b5061053d611bae565b348015610ca4575f80fd5b5061053d610cb3366004611e35565b611be4565b348015610cc3575f80fd5b5061050e600181565b60018054610cd990612160565b80601f0160208091040260200160405190810160405280929190818152602001828054610d0590612160565b8015610d505780601f10610d2757610100808354040283529160200191610d50565b820191905f5260205f20905b815481529060010190602001808311610d3357829003601f168201915b505050505081565b601854606090610d71906001600160a01b031683611c2b565b92915050565b6040516001600160a01b0383166024820152604481018290525f908190610dca9060640160408051601f198184030181529190526020810180516001600160e01b031663095ea7b360e01b179052610d58565b905080806020019051810190610de09190612198565b949350505050565b5f604051634851657960e11b815260040160405180910390fd5b5f80610e4783604051602401610e18919061206e565b60408051601f198184030181529190526020810180516001600160e01b031663073e82c360e11b179052610d58565b905080806020019051810190610e5d91906121b3565b9392505050565b60138181548110610e73575f80fd5b5f91825260209091200154905081565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166305eff7ef60e21b179052610d58565b6040805160048152602481019091526020810180516001600160e01b031663182df0f560e01b1790525f908190610f059061118f565b905080806020019051810190610f1b91906121b3565b91505090565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316630672bd1b60e21b179052610d58565b6040516001600160a01b0382166024820152610fb49060440160408051601f198184030181529190526020810180516001600160e01b031662df0cab60e51b179052610d58565b5050565b6040516001600160a01b03808516602483015283166044820152606481018290525f9081906110139060840160408051601f198184030181529190526020810180516001600160e01b03166323b872dd60e01b179052610d58565b9050808060200190518101906110299190612198565b95945050505050565b6040516001600160a01b03808516602483015283166044820152606481018290525f90819061108d9060840160408051601f198184030181529190526020810180516001600160e01b0316632e85fb4160e01b179052610d58565b90508080602001905181019061102991906121b3565b6040516001600160a01b03821660248201525f90819081906110f19060440160408051601f198184030181529190526020810180516001600160e01b0316631b88acff60e11b179052610d58565b90508080602001905181019061110791906121ca565b9250925050915091565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316633af9e66960e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316631d8e90d160e11b1790525f908190610f05905b60605f80306001600160a01b0316846040516024016111ae9190611cf2565b60408051601f198184030181529181526020820180516001600160e01b0316630933c1ed60e01b179052516111e391906121ec565b5f60405180830381855afa9150503d805f811461121b576040519150601f19603f3d011682016040523d82523d5f602084013e611220565b606091505b50909250905081611232573d60208201fd5b80806020019051810190610de09190612207565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316634576b5db60e01b179052610d58565b60035461010090046001600160a01b031633146112c1576040516282b42960e81b815260040160405180910390fd5b81156112fb576040805160048152602481019091526020810180516001600160e01b031663153ab50560e01b1790526112f990610d58565b505b601880546001600160a01b038581166001600160a01b031983161790925560405191169061136090611331908490602401611cf2565b60408051601f198184030181529190526020810180516001600160e01b0316630adccee560e31b179052610d58565b50601854604080516001600160a01b03808516825290921660208301527fd604de94d45953f9138079ec1b82d533cb2160c906d1076d1f7ed54befbca97a910160405180910390a150505050565b5f80610e47836040516024016113c691815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663601a0bf160e01b179052610d58565b6017602052815f5260405f20818154811061140e575f80fd5b905f5260205f20015f91509150505481565b6040516001600160a01b03821660248201525f90819081906110f19060440160408051601f198184030181529190526020810180516001600160e01b0316636ff2bf2b60e01b17905261118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166370a0823160e01b17905261118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166339a0487760e11b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316630e759dd360e31b1790525f908190610f0590610d58565b5f806115838484604051602401611554929190612270565b60408051601f198184030181529190526020810180516001600160e01b0316637c409a3760e01b179052610d58565b905080806020019051810190610de091906121b3565b5f80610e47836040516024016115b191815260200190565b60408051601f198184030181529190526020810180516001600160e01b0316634181842360e11b179052610d58565b5f80610e47836040516024016115f891815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663852a12e360e01b179052610d58565b6040516001600160a01b03821660248201526060905f906116749060440160408051601f198184030181529190526020810180516001600160e01b0316632168142f60e21b17905261118f565b905080806020019051810190610e5d9190612291565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316631293722960e31b17905261118f565b60028054610cd990612160565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166395dd919360e01b17905261118f565b6040805160048152602481019091526020810180516001600160e01b031663a6afed9560e01b1790525f908190610f0590610d58565b6040516001600160a01b0383166024820152604481018290525f908190610dca9060640160408051601f198184030181529190526020810180516001600160e01b031663a9059cbb60e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316630ae9d70b60e41b1790525f908190610f059061118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316632dc7468360e21b179052610d58565b6040805160048152602481019091526020810180516001600160e01b031663bd6d894d60e01b1790525f908190610f0590610d58565b5f8061108d85858560405160240161188a9392919061231d565b60408051601f198184030181529190526020810180516001600160e01b031663c281f00b60e01b179052610d58565b5f805f805f80611911876040516024016118e291906001600160a01b0391909116815260200190565b60408051601f198184030181529190526020810180516001600160e01b03166361bfb47160e11b17905261118f565b9050808060200190518101906119279190612350565b939b929a50909850965090945092505050565b5f80610e478360405160240161195291815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663317afabb60e21b179052610d58565b5f8061108d85858560405160240161199b9392919061238c565b60408051601f198184030181529190526020810180516001600160e01b0316636776988960e11b179052610d58565b5f80610e47836040516024016119e291815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663db006a7560e01b179052610d58565b6040516001600160a01b038084166024830152821660448201525f9081906115839060640160408051601f198184030181529190526020810180516001600160e01b0316636eb1769f60e11b17905261118f565b6040805160048152602481019091526020810180516001600160e01b031663e91dcfd160e01b1790525f908190610f059061118f565b6040805160048152602481019091526020810180516001600160e01b03166374e38a7960e11b1790525f908190610f0590610d58565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b031663f16bfc6f60e01b179052610d58565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b031663f2b3abbd60e01b179052610d58565b5f80610e4783604051602401611b7f919061206e565b60408051601f198184030181529190526020810180516001600160e01b031663f8e93ef960e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316631f1f3b4560e31b1790525f908190610f059061118f565b5f80610e4783604051602401611bfc91815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663fca7820b60e01b179052610d58565b60605f80846001600160a01b031684604051611c4791906121ec565b5f60405180830381855af49150503d805f8114611c7f576040519150601f19603f3d011682016040523d82523d5f602084013e611c84565b606091505b50909250905081610de0573d60208201fd5b818382375f9101908152919050565b5f5b83811015611cbf578181015183820152602001611ca7565b50505f910152565b5f8151808452611cde816020860160208601611ca5565b601f01601f19169290920160200192915050565b602081525f610e5d6020830184611cc7565b634e487b7160e01b5f52604160045260245ffd5b604051601f8201601f1916810167ffffffffffffffff81118282101715611d4157611d41611d04565b604052919050565b5f67ffffffffffffffff821115611d6257611d62611d04565b50601f01601f191660200190565b5f82601f830112611d7f575f80fd5b8135611d92611d8d82611d49565b611d18565b818152846020838601011115611da6575f80fd5b816020850160208301375f918101602001919091529392505050565b5f60208284031215611dd2575f80fd5b813567ffffffffffffffff811115611de8575f80fd5b610de084828501611d70565b6001600160a01b0381168114611e08575f80fd5b50565b5f8060408385031215611e1c575f80fd5b8235611e2781611df4565b946020939093013593505050565b5f60208284031215611e45575f80fd5b5035919050565b5f67ffffffffffffffff821115611e6557611e65611d04565b5060051b60200190565b5f82601f830112611e7e575f80fd5b81356020611e8e611d8d83611e4c565b8083825260208201915060208460051b870101935086841115611eaf575f80fd5b602086015b84811015611ecb5780358352918301918301611eb4565b509695505050505050565b5f60208284031215611ee6575f80fd5b813567ffffffffffffffff811115611efc575f80fd5b610de084828501611e6f565b5f60208284031215611f18575f80fd5b8135610e5d81611df4565b5f805f60608486031215611f35575f80fd5b8335611f4081611df4565b92506020840135611f5081611df4565b929592945050506040919091013590565b6020810160048310611f8157634e487b7160e01b5f52602160045260245ffd5b91905290565b8015158114611e08575f80fd5b5f805f60608486031215611fa6575f80fd5b8335611fb181611df4565b92506020840135611fc181611f87565b9150604084013567ffffffffffffffff811115611fdc575f80fd5b611fe886828701611d70565b9150509250925092565b5f8060408385031215612003575f80fd5b823567ffffffffffffffff811115612019575f80fd5b61202585828601611e6f565b95602094909401359450505050565b5f815180845260208085019450602084015f5b8381101561206357815187529582019590820190600101612047565b509495945050505050565b602081525f610e5d6020830184612034565b5f805f60608486031215612092575f80fd5b833561209d81611df4565b9250602084013567ffffffffffffffff8111156120b8575f80fd5b6120c486828701611e6f565b925050604084013590509250925092565b5f805f606084860312156120e7575f80fd5b83356120f281611df4565b9250602084013561210281611df4565b9150604084013567ffffffffffffffff81111561211d575f80fd5b611fe886828701611e6f565b5f806040838503121561213a575f80fd5b823561214581611df4565b9150602083013561215581611df4565b809150509250929050565b600181811c9082168061217457607f821691505b60208210810361219257634e487b7160e01b5f52602260045260245ffd5b50919050565b5f602082840312156121a8575f80fd5b8151610e5d81611f87565b5f602082840312156121c3575f80fd5b5051919050565b5f80604083850312156121db575f80fd5b505080516020909101519092909150565b5f82516121fd818460208701611ca5565b9190910192915050565b5f60208284031215612217575f80fd5b815167ffffffffffffffff81111561222d575f80fd5b8201601f8101841361223d575f80fd5b805161224b611d8d82611d49565b81815285602083850101111561225f575f80fd5b611029826020830160208601611ca5565b604081525f6122826040830185612034565b90508260208301529392505050565b5f60208083850312156122a2575f80fd5b825167ffffffffffffffff8111156122b8575f80fd5b8301601f810185136122c8575f80fd5b80516122d6611d8d82611e4c565b81815260059190911b820183019083810190878311156122f4575f80fd5b928401925b82841015612312578351825292840192908401906122f9565b979650505050505050565b6001600160a01b03841681526060602082018190525f9061234090830185612034565b9050826040830152949350505050565b5f805f805f60a08688031215612364575f80fd5b5050835160208501516040860151606087015160809097015192989197509594509092509050565b6001600160a01b038481168252831660208201526060604082018190525f906110299083018461203456fea2646970667358221220b2ca2f3ec5d1e605f5a00f45447057633a460f2dc93c169936e839546e22ad2d64736f6c6343000817003300000000000000000000000032bb5a147b5371fd901aa4a72b7f82c58a87e36d000000000000000000000000f9c70750bf615de83fe7ff62d30c7faacd8f8ba00000000000000000000000008cd2001327a919653b9e0e1adb9298772ed8d25c000000000000000000000000000000000000000000a56fa5b99019a5c800000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000000000000000000800000000000000000000000043a314183c0033528827be7cf426523bac412780000000000000000000000000f97309070d159e9f94b0b04da0097a77c4b9185500000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000001a46756e6769667920426974204265617273204e6f426f72726f77000000000000000000000000000000000000000000000000000000000000000000000000000866424954425f4e4200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x60806040526004361061040f575f3560e01c806370a082311161021d578063b71d1a0c11610122578063e9c714f2116100aa578063f851a44011610079578063f851a44014610c42578063f8e93ef914610c66578063f8f9da2814610c85578063fca7820b14610c99578063fe9c44ae14610cb85761040f565b8063e9c714f214610bd1578063f16bfc6f14610be5578063f2b3abbd14610c04578063f3fdb15a14610c235761040f565b8063c5ebeaec116100f1578063c5ebeaec14610b41578063ceed311214610b60578063db006a7514610b7f578063dd62ed3e14610b9e578063e91dcfd114610bbd5761040f565b8063b71d1a0c14610aa8578063bd6d894d14610ac7578063c281f00b14610adb578063c37f68e214610afa5761040f565b8063949b9148116101a5578063a0712d6811610174578063a0712d681461051e578063a6afed9514610a4c578063a9059cbb14610a60578063aa5af0fd14610a7f578063ae9d70b014610a945761040f565b8063949b9148146109e557806395d89b4114610a0457806395dd919314610a1857806398f1bc1214610a375761040f565b806383030846116101ec5780638303084614610951578063852a12e31461097057806385a050bc1461098f5780638ecde492146109bb5780638f840ddd146109d05761040f565b806370a08231146108e0578063734090ee146108ff57806373acee981461091e5780637c409a37146109325761040f565b80632e85fb4111610323578063555bcc40116102ab578063654288f51161027a578063654288f5146108545780636752e702146108735780636c540baf146108885780636f307dc31461089d5780636ff2bf2b146108c15761040f565b8063555bcc40146107d85780635c60da1b146107f75780635fe3b56714610816578063601a0bf1146108355761040f565b80633b1d21a2116102f25780633b1d21a2146107715780633e9410101461051e5780634487152f146107855780634576b5db146107a457806347bd3718146107c35761040f565b80632e85fb41146106d4578063313ce567146106f3578063371159fe1461071e5780633af9e669146107525761040f565b806318160ddd116103a65780631be19560116103755780631be195601461061f57806323b872dd1461063e5780632608f8181461065d57806326782247146106775780632dd48909146106ae5761040f565b806318160ddd146105bd578063182df0f5146105d257806319caf46c146105e657806319d1b799146106055761040f565b80630e7d0586116103e25780630e7d05861461054b57806316d812f61461056a578063173b99041461058957806317bfdfbc1461059e5761040f565b806306fdde03146104a65780630933c1ed146104d0578063095ea7b3146104ef5780630e7527021461051e575b341561042e57604051635ffd892360e11b815260040160405180910390fd5b6018546040515f916001600160a01b03169061044d9083903690611c96565b5f60405180830381855af49150503d805f8114610485576040519150601f19603f3d011682016040523d82523d5f602084013e61048a565b606091505b505090506040513d5f823e8180156104a0573d82f35b3d82fd5b005b3480156104b1575f80fd5b506104ba610ccc565b6040516104c79190611cf2565b60405180910390f35b3480156104db575f80fd5b506104ba6104ea366004611dc2565b610d58565b3480156104fa575f80fd5b5061050e610509366004611e0b565b610d77565b60405190151581526020016104c7565b348015610529575f80fd5b5061053d610538366004611e35565b610de8565b6040519081526020016104c7565b348015610556575f80fd5b5061053d610565366004611ed6565b610e02565b348015610575575f80fd5b5061053d610584366004611e35565b610e64565b348015610594575f80fd5b5061053d60085481565b3480156105a9575f80fd5b5061053d6105b8366004611f08565b610e83565b3480156105c8575f80fd5b5061053d600d5481565b3480156105dd575f80fd5b5061053d610ecf565b3480156105f1575f80fd5b5061053d610600366004611f08565b610f21565b348015610610575f80fd5b5061053d610538366004611f23565b34801561062a575f80fd5b506104a4610639366004611f08565b610f6d565b348015610649575f80fd5b5061050e610658366004611f23565b610fb8565b348015610668575f80fd5b5061053d610538366004611e0b565b348015610682575f80fd5b50600454610696906001600160a01b031681565b6040516001600160a01b0390911681526020016104c7565b3480156106b9575f80fd5b506012546106c79060ff1681565b6040516104c79190611f61565b3480156106df575f80fd5b5061053d6106ee366004611f23565b611032565b3480156106fe575f80fd5b5060035461070c9060ff1681565b60405160ff90911681526020016104c7565b348015610729575f80fd5b5061073d610738366004611f08565b6110a3565b604080519283526020830191909152016104c7565b34801561075d575f80fd5b5061053d61076c366004611f08565b611111565b34801561077c575f80fd5b5061053d61115d565b348015610790575f80fd5b506104ba61079f366004611dc2565b61118f565b3480156107af575f80fd5b5061053d6107be366004611f08565b611246565b3480156107ce575f80fd5b5061053d600b5481565b3480156107e3575f80fd5b506104a46107f2366004611f94565b611292565b348015610802575f80fd5b50601854610696906001600160a01b031681565b348015610821575f80fd5b50600554610696906001600160a01b031681565b348015610840575f80fd5b5061053d61084f366004611e35565b6113ae565b34801561085f575f80fd5b5061053d61086e366004611e0b565b6113f5565b34801561087e575f80fd5b5061053d60115481565b348015610893575f80fd5b5061053d60095481565b3480156108a8575f80fd5b506012546106969061010090046001600160a01b031681565b3480156108cc575f80fd5b5061073d6108db366004611f08565b611420565b3480156108eb575f80fd5b5061053d6108fa366004611f08565b61146e565b34801561090a575f80fd5b5061053d610919366004611f08565b6114ba565b348015610929575f80fd5b5061053d611506565b34801561093d575f80fd5b5061053d61094c366004611ff2565b61153c565b34801561095c575f80fd5b5061053d61096b366004611e35565b611599565b34801561097b575f80fd5b5061053d61098a366004611e35565b6115e0565b34801561099a575f80fd5b506109ae6109a9366004611f08565b611627565b6040516104c7919061206e565b3480156109c6575f80fd5b5061053d60165481565b3480156109db575f80fd5b5061053d600c5481565b3480156109f0575f80fd5b5061053d6109ff366004611f08565b61168a565b348015610a0f575f80fd5b506104ba6116d6565b348015610a23575f80fd5b5061053d610a32366004611f08565b6116e3565b348015610a42575f80fd5b5061053d60145481565b348015610a57575f80fd5b5061053d61172f565b348015610a6b575f80fd5b5061050e610a7a366004611e0b565b611765565b348015610a8a575f80fd5b5061053d600a5481565b348015610a9f575f80fd5b5061053d6117b8565b348015610ab3575f80fd5b5061053d610ac2366004611f08565b6117ee565b348015610ad2575f80fd5b5061053d61183a565b348015610ae6575f80fd5b5061053d610af5366004612080565b611870565b348015610b05575f80fd5b50610b19610b14366004611f08565b6118b9565b604080519586526020860194909452928401919091526060830152608082015260a0016104c7565b348015610b4c575f80fd5b5061053d610b5b366004611e35565b61193a565b348015610b6b575f80fd5b5061053d610b7a3660046120d5565b611981565b348015610b8a575f80fd5b5061053d610b99366004611e35565b6119ca565b348015610ba9575f80fd5b5061053d610bb8366004612129565b611a11565b348015610bc8575f80fd5b5061053d611a65565b348015610bdc575f80fd5b5061053d611a9b565b348015610bf0575f80fd5b5061053d610bff366004611f08565b611ad1565b348015610c0f575f80fd5b5061053d610c1e366004611f08565b611b1d565b348015610c2e575f80fd5b50600654610696906001600160a01b031681565b348015610c4d575f80fd5b506003546106969061010090046001600160a01b031681565b348015610c71575f80fd5b5061053d610c80366004611ed6565b611b69565b348015610c90575f80fd5b5061053d611bae565b348015610ca4575f80fd5b5061053d610cb3366004611e35565b611be4565b348015610cc3575f80fd5b5061050e600181565b60018054610cd990612160565b80601f0160208091040260200160405190810160405280929190818152602001828054610d0590612160565b8015610d505780601f10610d2757610100808354040283529160200191610d50565b820191905f5260205f20905b815481529060010190602001808311610d3357829003601f168201915b505050505081565b601854606090610d71906001600160a01b031683611c2b565b92915050565b6040516001600160a01b0383166024820152604481018290525f908190610dca9060640160408051601f198184030181529190526020810180516001600160e01b031663095ea7b360e01b179052610d58565b905080806020019051810190610de09190612198565b949350505050565b5f604051634851657960e11b815260040160405180910390fd5b5f80610e4783604051602401610e18919061206e565b60408051601f198184030181529190526020810180516001600160e01b031663073e82c360e11b179052610d58565b905080806020019051810190610e5d91906121b3565b9392505050565b60138181548110610e73575f80fd5b5f91825260209091200154905081565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166305eff7ef60e21b179052610d58565b6040805160048152602481019091526020810180516001600160e01b031663182df0f560e01b1790525f908190610f059061118f565b905080806020019051810190610f1b91906121b3565b91505090565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316630672bd1b60e21b179052610d58565b6040516001600160a01b0382166024820152610fb49060440160408051601f198184030181529190526020810180516001600160e01b031662df0cab60e51b179052610d58565b5050565b6040516001600160a01b03808516602483015283166044820152606481018290525f9081906110139060840160408051601f198184030181529190526020810180516001600160e01b03166323b872dd60e01b179052610d58565b9050808060200190518101906110299190612198565b95945050505050565b6040516001600160a01b03808516602483015283166044820152606481018290525f90819061108d9060840160408051601f198184030181529190526020810180516001600160e01b0316632e85fb4160e01b179052610d58565b90508080602001905181019061102991906121b3565b6040516001600160a01b03821660248201525f90819081906110f19060440160408051601f198184030181529190526020810180516001600160e01b0316631b88acff60e11b179052610d58565b90508080602001905181019061110791906121ca565b9250925050915091565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316633af9e66960e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316631d8e90d160e11b1790525f908190610f05905b60605f80306001600160a01b0316846040516024016111ae9190611cf2565b60408051601f198184030181529181526020820180516001600160e01b0316630933c1ed60e01b179052516111e391906121ec565b5f60405180830381855afa9150503d805f811461121b576040519150601f19603f3d011682016040523d82523d5f602084013e611220565b606091505b50909250905081611232573d60208201fd5b80806020019051810190610de09190612207565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316634576b5db60e01b179052610d58565b60035461010090046001600160a01b031633146112c1576040516282b42960e81b815260040160405180910390fd5b81156112fb576040805160048152602481019091526020810180516001600160e01b031663153ab50560e01b1790526112f990610d58565b505b601880546001600160a01b038581166001600160a01b031983161790925560405191169061136090611331908490602401611cf2565b60408051601f198184030181529190526020810180516001600160e01b0316630adccee560e31b179052610d58565b50601854604080516001600160a01b03808516825290921660208301527fd604de94d45953f9138079ec1b82d533cb2160c906d1076d1f7ed54befbca97a910160405180910390a150505050565b5f80610e47836040516024016113c691815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663601a0bf160e01b179052610d58565b6017602052815f5260405f20818154811061140e575f80fd5b905f5260205f20015f91509150505481565b6040516001600160a01b03821660248201525f90819081906110f19060440160408051601f198184030181529190526020810180516001600160e01b0316636ff2bf2b60e01b17905261118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166370a0823160e01b17905261118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166339a0487760e11b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316630e759dd360e31b1790525f908190610f0590610d58565b5f806115838484604051602401611554929190612270565b60408051601f198184030181529190526020810180516001600160e01b0316637c409a3760e01b179052610d58565b905080806020019051810190610de091906121b3565b5f80610e47836040516024016115b191815260200190565b60408051601f198184030181529190526020810180516001600160e01b0316634181842360e11b179052610d58565b5f80610e47836040516024016115f891815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663852a12e360e01b179052610d58565b6040516001600160a01b03821660248201526060905f906116749060440160408051601f198184030181529190526020810180516001600160e01b0316632168142f60e21b17905261118f565b905080806020019051810190610e5d9190612291565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316631293722960e31b17905261118f565b60028054610cd990612160565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b03166395dd919360e01b17905261118f565b6040805160048152602481019091526020810180516001600160e01b031663a6afed9560e01b1790525f908190610f0590610d58565b6040516001600160a01b0383166024820152604481018290525f908190610dca9060640160408051601f198184030181529190526020810180516001600160e01b031663a9059cbb60e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316630ae9d70b60e41b1790525f908190610f059061118f565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b0316632dc7468360e21b179052610d58565b6040805160048152602481019091526020810180516001600160e01b031663bd6d894d60e01b1790525f908190610f0590610d58565b5f8061108d85858560405160240161188a9392919061231d565b60408051601f198184030181529190526020810180516001600160e01b031663c281f00b60e01b179052610d58565b5f805f805f80611911876040516024016118e291906001600160a01b0391909116815260200190565b60408051601f198184030181529190526020810180516001600160e01b03166361bfb47160e11b17905261118f565b9050808060200190518101906119279190612350565b939b929a50909850965090945092505050565b5f80610e478360405160240161195291815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663317afabb60e21b179052610d58565b5f8061108d85858560405160240161199b9392919061238c565b60408051601f198184030181529190526020810180516001600160e01b0316636776988960e11b179052610d58565b5f80610e47836040516024016119e291815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663db006a7560e01b179052610d58565b6040516001600160a01b038084166024830152821660448201525f9081906115839060640160408051601f198184030181529190526020810180516001600160e01b0316636eb1769f60e11b17905261118f565b6040805160048152602481019091526020810180516001600160e01b031663e91dcfd160e01b1790525f908190610f059061118f565b6040805160048152602481019091526020810180516001600160e01b03166374e38a7960e11b1790525f908190610f0590610d58565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b031663f16bfc6f60e01b179052610d58565b6040516001600160a01b03821660248201525f908190610e479060440160408051601f198184030181529190526020810180516001600160e01b031663f2b3abbd60e01b179052610d58565b5f80610e4783604051602401611b7f919061206e565b60408051601f198184030181529190526020810180516001600160e01b031663f8e93ef960e01b179052610d58565b6040805160048152602481019091526020810180516001600160e01b0316631f1f3b4560e31b1790525f908190610f059061118f565b5f80610e4783604051602401611bfc91815260200190565b60408051601f198184030181529190526020810180516001600160e01b031663fca7820b60e01b179052610d58565b60605f80846001600160a01b031684604051611c4791906121ec565b5f60405180830381855af49150503d805f8114611c7f576040519150601f19603f3d011682016040523d82523d5f602084013e611c84565b606091505b50909250905081610de0573d60208201fd5b818382375f9101908152919050565b5f5b83811015611cbf578181015183820152602001611ca7565b50505f910152565b5f8151808452611cde816020860160208601611ca5565b601f01601f19169290920160200192915050565b602081525f610e5d6020830184611cc7565b634e487b7160e01b5f52604160045260245ffd5b604051601f8201601f1916810167ffffffffffffffff81118282101715611d4157611d41611d04565b604052919050565b5f67ffffffffffffffff821115611d6257611d62611d04565b50601f01601f191660200190565b5f82601f830112611d7f575f80fd5b8135611d92611d8d82611d49565b611d18565b818152846020838601011115611da6575f80fd5b816020850160208301375f918101602001919091529392505050565b5f60208284031215611dd2575f80fd5b813567ffffffffffffffff811115611de8575f80fd5b610de084828501611d70565b6001600160a01b0381168114611e08575f80fd5b50565b5f8060408385031215611e1c575f80fd5b8235611e2781611df4565b946020939093013593505050565b5f60208284031215611e45575f80fd5b5035919050565b5f67ffffffffffffffff821115611e6557611e65611d04565b5060051b60200190565b5f82601f830112611e7e575f80fd5b81356020611e8e611d8d83611e4c565b8083825260208201915060208460051b870101935086841115611eaf575f80fd5b602086015b84811015611ecb5780358352918301918301611eb4565b509695505050505050565b5f60208284031215611ee6575f80fd5b813567ffffffffffffffff811115611efc575f80fd5b610de084828501611e6f565b5f60208284031215611f18575f80fd5b8135610e5d81611df4565b5f805f60608486031215611f35575f80fd5b8335611f4081611df4565b92506020840135611f5081611df4565b929592945050506040919091013590565b6020810160048310611f8157634e487b7160e01b5f52602160045260245ffd5b91905290565b8015158114611e08575f80fd5b5f805f60608486031215611fa6575f80fd5b8335611fb181611df4565b92506020840135611fc181611f87565b9150604084013567ffffffffffffffff811115611fdc575f80fd5b611fe886828701611d70565b9150509250925092565b5f8060408385031215612003575f80fd5b823567ffffffffffffffff811115612019575f80fd5b61202585828601611e6f565b95602094909401359450505050565b5f815180845260208085019450602084015f5b8381101561206357815187529582019590820190600101612047565b509495945050505050565b602081525f610e5d6020830184612034565b5f805f60608486031215612092575f80fd5b833561209d81611df4565b9250602084013567ffffffffffffffff8111156120b8575f80fd5b6120c486828701611e6f565b925050604084013590509250925092565b5f805f606084860312156120e7575f80fd5b83356120f281611df4565b9250602084013561210281611df4565b9150604084013567ffffffffffffffff81111561211d575f80fd5b611fe886828701611e6f565b5f806040838503121561213a575f80fd5b823561214581611df4565b9150602083013561215581611df4565b809150509250929050565b600181811c9082168061217457607f821691505b60208210810361219257634e487b7160e01b5f52602260045260245ffd5b50919050565b5f602082840312156121a8575f80fd5b8151610e5d81611f87565b5f602082840312156121c3575f80fd5b5051919050565b5f80604083850312156121db575f80fd5b505080516020909101519092909150565b5f82516121fd818460208701611ca5565b9190910192915050565b5f60208284031215612217575f80fd5b815167ffffffffffffffff81111561222d575f80fd5b8201601f8101841361223d575f80fd5b805161224b611d8d82611d49565b81815285602083850101111561225f575f80fd5b611029826020830160208601611ca5565b604081525f6122826040830185612034565b90508260208301529392505050565b5f60208083850312156122a2575f80fd5b825167ffffffffffffffff8111156122b8575f80fd5b8301601f810185136122c8575f80fd5b80516122d6611d8d82611e4c565b81815260059190911b820183019083810190878311156122f4575f80fd5b928401925b82841015612312578351825292840192908401906122f9565b979650505050505050565b6001600160a01b03841681526060602082018190525f9061234090830185612034565b9050826040830152949350505050565b5f805f805f60a08688031215612364575f80fd5b5050835160208501516040860151606087015160809097015192989197509594509092509050565b6001600160a01b038481168252831660208201526060604082018190525f906110299083018461203456fea2646970667358221220b2ca2f3ec5d1e605f5a00f45447057633a460f2dc93c169936e839546e22ad2d64736f6c63430008170033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000032bb5a147b5371fd901aa4a72b7f82c58a87e36d000000000000000000000000f9c70750bf615de83fe7ff62d30c7faacd8f8ba00000000000000000000000008cd2001327a919653b9e0e1adb9298772ed8d25c000000000000000000000000000000000000000000a56fa5b99019a5c800000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000000000000000000800000000000000000000000043a314183c0033528827be7cf426523bac412780000000000000000000000000f97309070d159e9f94b0b04da0097a77c4b9185500000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000001a46756e6769667920426974204265617273204e6f426f72726f77000000000000000000000000000000000000000000000000000000000000000000000000000866424954425f4e4200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : underlying_ (address): 0x32BB5a147b5371Fd901Aa4a72B7F82c58A87e36d
Arg [1] : comptroller_ (address): 0xf9c70750bF615dE83fE7FF62D30C7faACD8f8Ba0
Arg [2] : interestRateModel_ (address): 0x8cd2001327a919653B9E0E1ADB9298772eD8d25c
Arg [3] : initialExchangeRateMantissa_ (uint256): 200000000000000000000000000
Arg [4] : name_ (string): Fungify Bit Bears NoBorrow
Arg [5] : symbol_ (string): fBITB_NB
Arg [6] : decimals_ (uint8): 8
Arg [7] : admin_ (address): 0x43A314183c0033528827Be7cF426523bAc412780
Arg [8] : implementation_ (address): 0xf97309070d159e9f94b0B04Da0097a77c4b91855
Arg [9] : becomeImplementationData (bytes): 0x
-----Encoded View---------------
16 Constructor Arguments found :
Arg [0] : 00000000000000000000000032bb5a147b5371fd901aa4a72b7f82c58a87e36d
Arg [1] : 000000000000000000000000f9c70750bf615de83fe7ff62d30c7faacd8f8ba0
Arg [2] : 0000000000000000000000008cd2001327a919653b9e0e1adb9298772ed8d25c
Arg [3] : 000000000000000000000000000000000000000000a56fa5b99019a5c8000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000180
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [7] : 00000000000000000000000043a314183c0033528827be7cf426523bac412780
Arg [8] : 000000000000000000000000f97309070d159e9f94b0b04da0097a77c4b91855
Arg [9] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [10] : 000000000000000000000000000000000000000000000000000000000000001a
Arg [11] : 46756e6769667920426974204265617273204e6f426f72726f77000000000000
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [13] : 66424954425f4e42000000000000000000000000000000000000000000000000
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [15] : 0000000000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 33 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.