[ARFC] Onboard tBTC to Aave v3 on Ethereum, Arbitrum and Optimism

[ARFC] Onboard tBTC to Aave v3 on Ethereum, Arbitrum and Optimism.

Author: ACI (Aave Chan Initiative)

Date: 2024-05-13

Proposal updated with Risk Parameters provided by Risk Service Providers to just onboard tBTC to Aave v3 on Ethereum.


Summary:

The proposal aims to onboard Threshold Network’s tBTC, to the Aave v3 protocol on Ethereum, Arbitrum and Optimism. tBTC is backed one-to-one with Bitcoin.

Motivation/Background:

tBTC is Threshold’s decentralized and permissionless bridge to bring BTC to the Ethereum network. tBTC has been designed to allow Bitcoin holders to participate in Ethereum’s Decentralized Finance (DeFi) applications. Users wishing to utilize their Bitcoin on Ethereum can use the tBTC decentralized bridge to deposit their Bitcoin into the system and get a minted tBTC token in their Ethereum wallet.

Having recently acquired a Chainlink oracle, tBTC enables Aave users to have access to the only wrapped Bitcoin, which can be permissionlessly minted and redeemed, where the BTC that backs it is not held by a central intermediary, but is instead held by a decentralized network of nodes using threshold cryptography. This implies a fully decentralized and permissionless lending and borrowing experience for BTC (i.e. bridge native BTC to tBTC and borrow via Aave).

tBTC was created by a decentralized effort of contributors at the Threshold Network DAO, and extensively utilizes the Threshold Network’s threshold cryptography to create a secure BTC asset. tBTC is a product launched on Threshold Network, on which many other decentralized applications are being built.

Threshold Network DAO was born out of the first on-chain merger between two decentralized protocols, Keep Network and NuCypher early in 2022. The DAO has successfully operated since that time, and supports an active community of contributors that work towards building tBTC liquidity and usability.

Benefits for Aave:

  • Further decentralization and trust minimisation in the Aave stack.
  • A range of lending options for those who wish to earn yield on their BTC.
  • Collaboration with the Threshold Network DAO, opening up the opportunity to incorporate other Threshold products (such as Threshold Access Control and thUSD) into the Aave offering.
  • Preferable yields on tBTC through active incentive participation, boosting Aave protocol use, fees and TVL.
  • Additional incentive allocation originating from Arbitrium’s LTIPP.

Specification

Ticker: TBTC

Contract Addresses:

Ethereum: 0x18084fba666a33d37592fa2633fd49a74dd93a88

Arbitrum: 0x6c84a8f1c29108f47a79964b5fe888d4f4d0de40

Optimism: 0x6c84a8f1c29108F47a79964b5Fe888D4f4D0dE40

Chainlink Oracle:

Ethereum: 0x8350b7De6a6a2C1368E7D4Bd968190e13E354297

Arbitrum: 0xE808488e8627F6531bA79a13A9E0271B39abEb1C

Optimism: 0x5a61374950D4BFa5a3D4f2CA36FC1d23A92b6f21

Risk parameters

Parameter Value
Isolation Mode No
Borrowable Yes
Collateral Enabled Yes
Supply Cap (tBTC) 550
Borrow Cap (tBTC) 275
Debt Ceiling -
LTV 73.00%
LT 78.00%
Liquidation Bonus 7.50%
Liquidation Protocol Fee 10.00%
Variable Base 0.0%
Variable Slope1 4.00%
Variable Slope2 300.00%
Uoptimal 45.00%
Reserve Factor 20.00%
Stable Borrowing Disabled
Flashloanable Yes
Siloed Borrowing No
Borrowed in Isolation No

CAPO

Price Cap
4%

Emission schedule

tBTC is one-to-one backed with real Bitcoin, meaning that there isn’t an emissions schedule, but a mint and redeem function that adjusts the supply of tBTC based on native BTC coming into and out of the system.

Risks

For tBTC, wallets are created periodically based on governance. In order for the wallet to move funds, it produces signatures using a Threshold Elliptic Curve Digital Signature Algorithm, requiring 51-of-100 Signers to cooperate. The 100 signers on each wallet are chosen with our Sortition Pool, and the randomness is provided by the Random Beacon. More can be found here - Wallet Generation | Threshold Docs 1

The Threshold Council multisig is a 6/9 Gnosis Safe multisig with 9 unique signers that form the Threshold Network Council. The Council has limited upgrade privileges over the smart contracts. However, those privileges do not include any custodial power over deposited BTC:

Council Multisig Ethereum Address: 0x9F6e831c8F8939DC0C830C6e492e7cEf4f9C2F5f

Useful Links:

Project: https://www.threshold.network/

Minting dashboard: https://dashboard.threshold.network/tBTC/mint

GitHub: GitHub - keep-network/tbtc-v2: Trustlessly tokenized Bitcoin everywhere, version 2

Docs: tBTC Bitcoin Bridge | Threshold Docs

Audit: About

Immunfi Bug Bounty: Threshold Network Bug Bounties | Immunefi | Immunefi

Llama Risk Report: Collateral Risk Assessment: Threshold BTC (tBTC) - HackMD

Twitter: x.com

Discord: Threshold Network ✜

Dune: https://dune.com/threshold/tbtc & https://dune.com/sensecapital/tbtc-liquidity

Disclaimer:

This proposal is powered by Skywards. The Aave Chan Initiative is not directly affiliated with Threshold Network and did not receive compensation for creation this proposal.

Next Steps:

  1. Publication of a standard ARFC, collect community and service providers feedback before escalating the proposal to the ARFC Snapshot stage.
  2. If the ARFC Snapshot outcome is positive, publish an AIP vote for final confirmation and enforcement of the proposal.

Copyright:

Copyright and related rights waived under CC0.

1 Like

Overview

Chaos Labs supports listing tBTC on Aave V3 Ethereum. Following is our analysis and risk parameter recommendations for the initial listing.

Note: The following analysis is conducted solely from a market risk viewpoint, excluding centralization and third-party risk considerations. If the community aims to reduce exposure to tBTC, adopting more conservative supply and borrow caps should be considered.

Liquidity and Market Cap

tBTC is a wrapped version of BTC that is available on Ethereum, as well as on other chains via the Wormhole bridge. Note that we do not generally recommend listing bridged assets; this, combined with limited liquidity on other networks, leads us to only recommend an Ethereum listing at this time.

Over the past 180 days, its average market cap is $97.24M and its average daily trading volume is $3.04M, including both centralized and decentralized exchanges. However, it has undergone rapid growth in recent weeks, and its current market cap stands at over $200M.

Untitled - 2024-05-16T170400.949

tBTC Volatility

Relative to BTC, we find that tBTC has a 30-day annualized volatility of 4.85%.

Untitled - 2024-05-16T170402.524

Relative to USD, we find it has a 30-day annualized volatility of 47.62% and a largest single-day price drop of 8.28%.

Untitled - 2024-05-16T170403.993

Liquidation Threshold

Considering the volatility of the asset, we recommend setting the LT to 78% and the LTV to 73%, mirroring similar assets on Ethereum V3.

Supply Cap, Borrow Cap, and Liquidation Bonus

Chaos Labs’ approach to initial supply caps is generally proposed through setting the Supply Cap at 2x the liquidity available under the Liquidation Penalty price impact, which leads to a recommendation of 550 tBTC. Based on this, we recommend a borrow cap of 275 tBTC.

IR Curve Parameters

We recommend aligning the interest rate parameters with those of similar assets on Ethereum to ensure consistency across similar assets on Aave v3.

CAPO recommendations:

Given tBTC’s capability to be redeemed 1:1 for BTC in a permissionless manner within a matter of hours, we recommend aligning our price cap recommendations with those of traditional stablecoins.

Price Cap
4%

Specification

Following the above analysis, we recommend listing tBTC with the following parameter settings:

Parameter Value - Ethereum Value - Arbitrum
Isolation Mode No No
Borrowable Yes Yes
Collateral Enabled Yes Yes
Supply Cap (tBTC) 550 80
Borrow Cap (tBTC) 275 40
Debt Ceiling - -
LTV 73.00% 73.00%
LT 78.00% 78.00%
Liquidation Bonus 7.50% 7.50%
Liquidation Protocol Fee 10.00% 10.00%
Variable Base 0.0% 0.0%
Variable Slope1 4.00% 4.00%
Variable Slope2 300.00% 300.00%
Uoptimal 45.00% 45.00%
Reserve Factor 20.00% 20.00%
Stable Borrowing Disabled Disabled
Flashloanable Yes Yes
Siloed Borrowing No No
Borrowed in Isolation No No
2 Likes

Summary

LlamaRisk is supportive of @ChaosLabs’s recommendation to onboard tBTC on Ethereum mainnet. We’ve prepared an updated report referencing LlamaRisk’s initial assessment of tBTC published on November 1st, 2023. We are also of the opinion that tBTC does not have sufficient liquidity to be onboarded on Optimism and Arbitrum networks.

Asset rating

In updating our assessment of tBTC, we are revising our risk rating. Based on the risks identified for each category, the following chart summarizes a risk rating for tBTC as collateral. The rating for each category is ranked from excellent, good, ok, and poor.

  • We rank tBTC ok on liquidity (unchanged) since it remains a minor tokenized BTC asset. Its liquidity provision on DEX appears adequate, although listing on CEX (Kraken) needs more volume. The introduction of the Wormhole bridge has increased tBTC’s availability across multiple chains, but Curve still holds the majority of liquidity and volume, albeit to a lesser extent since the initial analysis.
  • We rank tBTC good in volatility (unchanged) due to the permissionless ease of mints/redemptions that facilitate arbitrage, with a small fee on each action. tBTC has exhibited strong peg strength since redemptions were activated in July 2023.
  • We rank tBTC ok in smart contracts (unchanged) since there has been no change to its system architecture since deployment. The $500,000 ImmuneFi bug bounty program remains.
  • We rank tBTC good in dependencies as it has recently added a Chainlink oracle, reducing reliance on Curve EMA and permitting further DeFi integration. Significant off-chain processes that introduce complexity to the system remain a risk vector.
    *We rank tBTC good in decentralization (unchanged) for prioritizing permissionless access, a decentralized bridge network, and a reasonably convincing pathway to on-chain governance.
  • We rank tBTC ok in legal (unchanged) as the legal structure(s) are domiciled in a prominent jurisdiction, while no enforcement actions against Threshold are evident. Clarifying the legal status of cross-chain bridges and fortifying the protocol’s defenses could be better implemented.

Specific Consideration for Ethereum mainnet

Our previous assessment reviewed tBTC favorably, with moderate concerns about liquidity provisions and the lack of a dependable oracle. Considering liquidity provisions, holder distribution, and DeFi integration, tBTC is suitable for listing on Aave V3. The newly launched Chainlink price feed addresses the primary concern raised in the previous assessment by providing a dependable Oracle source.

The Ethereum mainnet remains the primary network for tBTC, holding the most significant share of the token’s activity, despite the Wormhole bridge expanding tBTC’s availability across multiple chains.

tBTC’s liquidity on Ethereum is sufficient for listing on Aave V3, with a diverse set of liquidity providers. The token’s volatility remains low due to the permissionless nature of mints and redemptions, which facilitates efficient arbitrage.

Although risks associated with the significant off-chain processes in the tBTC system persist, the overall risk profile has improved since the initial analysis. The Chainlink oracle, ongoing bug bounty program, and strong peg strength since July 2023 contribute to a favorable outlook for tBTC on the Ethereum mainnet.

In conclusion, we recommend listing tBTC on Aave V3 for the Ethereum mainnet, with appropriate risk parameters based on the token’s liquidity, volatility, and overall market conditions.

Specific Consideration for Optimism and Arbitrum

Despite the recent growth in tBTC availability across multiple chains through the Wormhole integration, liquidity on Optimism and Arbitrum still needs to be increased to recommend onboarding. The main liquidity pool (Curve) holds significantly less TVL than Ethereum mainnet, with an important price impact for trades as small as five tBTC.

While tBTC has seen some volume on L2s, the overall liquidity profile is unimpressive and does not show strengthening growth trends. Positive trends in liquidity depth and utilization are necessary to minimize the creation of bad debt due to missed liquidations.

We do not recommend onboarding tBTC on Aave V3 for Optimism and Arbitrum networks.

3 Likes

In light of both Risk Service Providers feedback, the current ARFC to Onboard tBTC will be only submitted/escalated to Aave v3 on Ethereum.

2 Likes

Threshold Network would like to thank both @ChaosLabs and @LlamaRisk for their recommendations.

We are happy to delay the onboarding of tBTC to Arbitrum and Optimism at this point in time, we are looking to make a concerted effort to boost TVL and liquidity on both these L2’s over the coming months, so hopefully we can revisit these markets at a later stage.

1 Like

Following feedback and Risk Service Providers recommendations, the current proposal has been escalated to ARFC Snapshot, to Onboard tBTC to Aave v3 only on Ethereum at this moment.

Vote will start tomorrow, we encourage everyone to participate.

After Snapshot monitoring, the current ARFC Snapshot just ended, reaching both Quorum and YAE as winning option with 670K votes.

Therefore, the proposal to Onboard tBTC to Aave V3 only on Ethereum has passed.
Next step will be the publication of an AIP for final confirmation.

1 Like

Can I suggest Polygon too? Unleashing Bitcoin: tBTC Launches on Polygon, Powered by Wormhole! I have read the troubling news on WBTC. I don’t know enough about tBTC, and scared it will go the way of renBTC some day, but I agree that the WBTC news is enough that we should have both options. My personal interest in asking is Polygon is the only AAVE market left to cheaply (in gas) borrow EURS as AAVE Arbitrum stopped supporting EURS. There are lots of other options unique to Polygon, thanks.

1 Like

Also I respect everything Llama and LlamaRisk (part of why I am only interested in borrowing–not lending–EURS), and would ask @LlamaRisk to speak to the risk of supporting tBTC on Optimism, Arbitrum, and Polygon within the context of recent WBTC news–as that context seems missing in the assessment.

1 Like

tBTC (Threshold Network) technical analysis


Summary

This is a technical analysis of all the smart contracts of the tBTC asset and main dependencies.

Disclosure: This is not an exhaustive security review of the asset like the ones done by the team supporting the Threshold Network, but an analysis from an Aave technical service provider on different aspects we consider critical to review before a new type of listing. Consequently, like with any security review, this is not an absolute statement that the asset is flawless, only that, in our opinion, we don’t see significant problems with its integration with Aave, apart from different trust points.


Analysis

tBTC is a trustless and decentralized Ethereum <> Bitcoin bridge that allows users to tokenize their Bitcoin on the Ethereum ecosystem, allowing them to participate in Ethereum’s DeFi applications.


tbtc-diagram
High-level overview of tBTC


Users send their Bitcoin to a randomly chosen group of operators who run nodes on the Threshold Network. These nodes are secured through threshold cryptography that requires a minimum number of participants to perform operations. After necessary confirmations, users can reveal the BTC they have deposited through the Bridge on the Ethereum blockchain and mint their tBTC tokens.

For the context of this analysis, our focus has been on the following aspects, critical for the correct and secure integration with Aave:

  • Access control (ownerships, admin roles) and nature of the entities involved.
  • Any miscellaneous aspect of the code we can consider of importance.
  • A recommendation of pricing strategy to be used in the integration asset <> Aave.

General points

  • The only upgradeable contract within the system is the Bridge, and its upgradeability admin is the governance council’s Gnosis Safe 6-of-9.
  • It uses an OZ transparent proxy pattern for proxies. The other non-upgradable contracts use OZ Ownable for access control, the OZ Governance for general governance, and libraries from Keep Network for cryptography validations.
  • The integrity of Bitcoin funds is secured by Threshold Network stakers, who periodically create 51-of-100 threshold-ECDSA wallets to hold them and maintain account balances.
  • tBTC uses a randomly selected group of operators running Threshold Network nodes. Before operators can move funds, they need to reach a majority agreement. These selected operators change every week, which helps protect against any bad actors trying to take control of BTC held by the system. The system can slash their stake if any operator is identified as a bad actor.
  • If the secured Bitcoin gets lost from the system, tBTC is to be backstopped by Threshold DAO through its treasury assets, where the Treasury Guild is responsible for moving from liquidity management to covering any loss.

Contracts

The following is a non-exhaustive overview of the main smart contracts involved with tBTC.


tBTC

It’s a non-upgradeable ERC20 token with EIP2612 permit functionality that represents 1:1 of Bitcoin in the Ethereum ecosystem.

  • It uses the Ownable OZ pattern, in which the owner is the Vault contract.
  • New tBTC tokens can be created by calling the mint() function, which is restricted to be called only by the Vault contract.
  • Users can burn their tBTC tokens via the burn() function.
  • The contract includes functionality to recover tokens sent by mistake to its address. The Vault contract can rescue ERC20 and ERC721 tokens by calling recoverERC20() and recoverERC721() respectively.

Bridge

The Bridge is the system’s core smart contract. It manages Bitcoin deposits and redemptions within the tBTC system, facilitating the minting and redemption of tBTC tokens on the Ethereum blockchain. It binds those services to governance, giving it more precise control of the network. The bridge also includes mechanisms to handle fraud, such as detecting unexpected transactions of wallet operators in the Bitcoin blockchain.

In implementation terms, it is an OZ Transparent Proxy with upgradeability by the general governance multi-sig council.


Deposits and Redemptions

  • Users deposit BTC into off-chain ECDSA wallets associated with the Bridge, using specific Bitcoin transaction types containing information about the depositor’s Ethereum address. Once the deposit is made, the depositor reveals their Ethereum address and other required information via the revealDeposit() or revealDepositWithExtraData() functions. The off-chain ECDSA wallet listens for these deposit events, verifies them on the Bitcoin Network, and, if valid, sweeps the funds via the submitDepositSweepProof() function, which will update the depositor balance in the Bank contract.
  • The minimum deposit amount is 0.01 BTC and can be tracked via the depositDustThreshold variable. During the sweep, the Bridge contract first computing the fee for the sweep. Currently, the fee deposit (depositTreasuryFeeDivisor storage variable) is zero.
  • Users with a tBTC balance can request redemption via the requestRedemption() function by providing the BTC wallet and redeeming amount. The Bridge transfers their balance in the Bank contract and coordinates with the off-chain wallet for redemption. As soon the redemption request is sent, the operators listen to it, and within a few hours to one day, the BTC is sent to the user. Once the BTC is sent to the users’ BTC address, the maintainers confirm it via the submitRedemptionProof() and burn the tokens in the bank contract.
  • The maximum redemption amount is equivalent to the amount held by the largest wallet, and the minimum amount is 0.009 BTC; it can be accessed via the redemptionDustThreshold variable. During the redemption, the Bridge computes the redemption fee of 0.2% set in the redemptionTreasuryFeeDivisor variable.
  • The maximum redemption amount is equivalent to the amount held by the largest wallet, and the minimum amount is 0.009 BTC; it can be accessed via the redemptionDustThreshold variable. During the redemption, the Bridge computes the redemption fee of 0.2% set in the redemptionTreasuryFeeDivisor variable.

Access Control

  • The critical functions of the Bridge are controlled by the Bridge Governance contract, which is protected by the modifier onlyGovernance. The Bridge Governance contract is responsible for updating its governable parameters regarding the governance delay individual for each parameter.
  • The contract’s parameters, such as deposit/redemption fees and thresholds, are governable. They are updated via the updateDepositParameters() and updateRedemptionParameters() functions.
  • Governance can add/remove maintainers and vaults by calling the setSpvMaintainerStatus() and setVaultStatus() functions.
  • The governance can also update the management of funds across the wallets and the wallet’s lifecycle by calling the updateMovingFundsParameters() and updateWalletParameters(), respectively.
  • The fraud parameters can be updated via the updateFraudParameters() function.
  • The system’s treasury address can be updated by calling the updateTreasury() function.

Wallet Lifecycle

Creation

  • A new wallet is created when both the conditions defined by walletCreationPeriod (14 days) and walletCreationMinBtcBalance (0 BTC) storage variables are met. The maximum amount a wallet can hold in the creation is 100 BTC, stored in the walletCreationMaxBtcBalance variable.
  • It started by calling the requestNewWallet() function, formalising it as the creation process is asynchronous. This process involves selecting a group of 100 operators from the pool of available operators using a sortition process, where the probability of selection is based on the operator’s stake in the system.
  • When the wallet is created, the ECDSA Wallet Registry calls the callback __ecdsaWalletCreatedCallback() function to store the wallet’s public key in the Bridge contract.

Misc management

  • If a wallet is older than the walletMaxAge (182 days) or its liveness drops below a certain threshold as time passes and some operators may leave the system, the system will initiate a transfer of funds to a new wallet.

Migration of wallets (closing)

  • The closing of a wallet initiates by calling the notifyWalletCloseable() function, and the funds are moved to a new wallet.
  • Operators submit the proof of the transfer of funds by calling submitMovingFundsProof() function.

Fraud prevention

  • The bridge can handle suspicious transactions of funds being moved that do not comply with protocol rules. Anyone who detects these transactions can accuse wallets of fraud by calling the submitFraudChallenge() and passing the wallet and an ether amount to be held by the bridge. Anyone can defeat the pending fraud challenge against a wallet by calling the defeatFraudChallenge(). In the case where the fraud is defeated successfully, the amount of ether deposited by the challenger is sent to the treasury. If the fraud challenge is not defeated in time, the challenger can call the notifyFraudChallengeDefeatTimeout() function, which will slash the stake of each operator, and the ether deposited by the challenger is returned + rewards.

MaintainerProxy

The MaintainerProxy smart contract defines functions that off-chain clients call to interact with the network. The DAO must approve maintainers before they can call these functions. Maintainers execute important tasks within the system, such as submitting proofs for Bitcoin transactions and managing the lifecycle of wallets. The Maintainer Proxy ensures that these maintainers are reimbursed for their gas costs after completing their calls.

It is a non-upgradeable contract using the Ownable OZ pattern.

  • The governance multi-sig council owns the contract and is assigned to add/remove trusted maintainers, change the gas refund parameters, and update the bridge contract if needed.
  • SPV Maintainers sent proofs of deposit and redemptions via the submitDepositSweepProof() and submitRedemptionProof() functions, which forward the call to them Bridge contract. The governance can add/remove SPV Maintainers by calling the authorizeSpvMaintainer() and unauthorizeSpvMaintainer() functions.
  • The Wallet Maintainers sent proof of funds being moved by calling submitMovingFundsProof() and submitMovedFundsSweepProof() functions, which forward them to the Bridge contract. They can also call maintenance and cleanup functions like requestNewWallet(), notifyMovingFundsBelowDust(), notifyWalletCloseable(), or notifyWalletClosingPeriodElapsed(). The governance can add/remove Wallet Maintainers by calling the authorizeWalletMaintainer() and unauthorizeWalletMaintainer() functions.

Bank

The Bank contract is responsible for tracking Bitcoin balances in the tBTC Bridge system. It manages minting and burn operations through the tBTC contract, facilitates the transfer and approval of balances between different accounts, and integrates with the Bridge contract to update balances whenever Bitcoin is deposited or withdrawn from the system.

The Bank is a central, non-upgradeable contract keeping track of Bitcoin balances. It utilizes the Ownable OZ pattern.

  • The system’s mint functions are restricted to the Bridge contract via the onlyBridge modifier. The bridge can increase balances in batch by calling the increaseBalances(), increase for one account via the increaseBalance() function, or increase the Vault contract balance and tokenize tBTC for an account by calling the increaseBalanceAndCall() function.
  • The balanceOf(account) mapping tracks the Bitcoin balance of each account within the system. Users can transfer their Bitcoin balance by calling the transferBalance() function, and an allowed spender can transfer the users’ balance via the transferBalanceFrom() function.
  • Users can set an allowance for a spender over the caller’s balance via the approveBalance() function. They can also increase and decrease the allowance by calling increaseBalanceAllowance() and decreaseBalanceAllowance() functions. It also includes the EIP-2612 permit mechanism for gas-efficient approvals via the permit() function.
  • The governance can upgrade the Bridge contract by calling the updateBridge() function. It’s protected by the onlyOwner modifier.

Vault

The Vault is a custody contract that is responsible for managing the minting and burning of tBTC tokens based on the Bitcoin balances held in the Bank contract. This contract ensures that the supply of tBTC is directly tied to the amount of Bitcoin held, maintaining a 1:1 peg.
A user with a Bank balance gives the Vault an allowance. Then, it uses that allowance to transfer the balance itself, holding on behalf of the user in exchange for minting the user the equivalent amount of tBTC tokens. Later, anyone with tBTC tokens can return them to the Vault, and the vault will grant them Bank balance.


Access Control

  • The Vault contract is controlled by the governance multi-sig council, which can upgrade it to another Vault contract and recover any ERC20 or ERC721 sent by mistake to the tBTC token contract. These functions are restricted via the onlyOwner modifier.
  • The Vault upgrade happens in two steps with a 24-hour governance delay. The owner of the Vault contract can initiate the upgrade by calling the initiateUpgrade() function and finalizing the upgrade to another vault via the finalizeUpgrade() function. The new vault receives ownership of the tBTC token as well as the entire Vault balance in the Bank contract.
  • The owner can rescue ERC20 and ERC721 tokens by calling recoverERC20() and recoverERC721() respectively.

Mint and Burn tBTC

  • Users with a Bank balance can mint tBTC tokens by calling the mint() function. They must first give allowance to the Vault so it can transfer the user’s Bank balance.
  • The bank can mint tBTC tokens directly to a user’s account via the receiveBalanceApproval() function. This function is restricted with the onlyBank modifier.
  • Users with tBTC tokens can burn them in exchange for Bank balance via the unmint() function. If the user wants to receive the BTC balance in the Bitcoin Network, it can directly call the unmintAndRedeem() function, which internally routes the redemption via the Bank contract, calling the approveBalanceAndCall() function.
  • A helper function called amountToSatoshis(amount) converts a given amount of tBTC to satoshis and handles rounding as tBTC has 18 decimals and BTC has 8 decimals. The function checks if the amount is not divisible by 1e10, and if it isn’t, the remainder is left on the caller’s account.

Miscellaneous

  • The system has three technical audit reviews by CertiK, LeastAuthority, and ChainSecurity.
  • Overall, the TBTC system appears to be a modular and secure implementation designed to bridge Bitcoin to Ethereum in a decentralized manner. The critical control points, such as bridge parameters and the upgradeability of the contracts, are designed to be kept under the governance’s control, which makes sense to keep the system more robust and trustless.

Asset pricing

Previously, there has been extensive discussion on this forum regarding the pricing mechanism of WBTC, and using BTC/USD (trusting the custody security of WBTC) versus purely monitoring secondary market venues of WBTC, with a WBTC/USD (or WBTC/BTC + BTC/USD) feed.

On Aave, WBTC was initially using the first approach, but changed after community decision to the second. There was extensive arguments for that, but a very important one was WBTC having very deep secondary market liquidity, so not being prone to temporary (malicious) market manipulations.

Now with tBTC, the situation is akin to early days of WBTC on Aave, with important differences:

  • tBTC has considerably lower market cap and trading volume than WBTC.
  • Trading venues are mainly decentralised exchanges, and an important part of the pairs are with WBTC.
  • Redeeming tBTC to BTC is pretty fast, taking hours order of magnitude.

Holistically considering this security analysis and the previous market dynamics, we see two options for pricing that we will discuss with risk providers before AIP:

  • If risk parameters (LTV/LT) and caps are quite conservative, it is an option to use a secondary market tBTC/USD (or tBTC/BTC + BTC/USD) feed with CAPO over BTC/USD. However, it is very difficult to evaluate how realistic are DEX manipulations with current volumes.
  • Another option is to simply use BTC/USD, trusting the security of the asset and its BTC reserves, but not having any type of risk of market manipulation on DEXes. Currently this is the option we believe is the most reasonable.

We will be working on further integration of Chainlink Proof-of-Reserve for assets like this, so we will also discuss with the Threshold team about the need to actively try to support the system, to improve assurances. In parallel, risk providers should evaluate how secondary market liquidity (including listings on CEXes) improves, as the best approach would be to align the strategy with others’ like WBTC, pricing based on tBTC/USD.


Conclusion

We think tBTC doesn’t have any problem in terms of integration with Aave, and there is no major technical blocker for listing.
The main pending item is to coordinate with the risk service provider on choosing the most appropriate pricing mechanism, from the options we outlined in this report.

6 Likes

Thank you @bgdlabs for the comprehensive technical analysis. We agree there are two options for tBTC pricing:

  1. Using a secondary market tBTC/USD price feed (or tBTC/BTC + BTC/USD) with conservative risk parameters and borrow caps. However, the current tBTC market depth is low and mostly on DEXes, making it potentially vulnerable to manipulation.
  2. Using the BTC/USD price feed directly, effectively trusting the security of tBTC and its Bitcoin reserves. This avoids DEX manipulation risks but requires ongoing validation of the Threshold Network’s security.

Given the current tBTC market dynamics, using the BTC/USD price feed (option 2) is the most prudent path forward for initial integration. However, risk parameters should be set conservatively to account for tBTC’s nascent stage. This is a temporary solution, and improvements will need to be implemented as the ecosystem matures.

@bgdlabs prospective work on integrating Chainlink Proof-of-Reserve (PoR) feeds for assets like tBTC would provide real-time on-chain verification that the Threshold Network holds sufficient Bitcoin collateral to back the minted tBTC supply. This additional layer of transparency and auditability would significantly boost confidence in tBTC’s reserve backing and peg stability. If a PoR check fails, indicating a potential discrepancy between tBTC supply and the underlying Bitcoin reserves, we recommend exploring the following programatic protective measures:

  • Switch to the market price: begin using secondary market tBTC/USD price feeds, allowing the price to reflect any depeg from BTC due to reserve discrepancies.
  • Set Loan-to-Value (LTV) to 0%: Temporarily disable borrowing against tBTC collateral by setting its LTV ratio to zero. This action prevents new loans from being issued against potentially undercollateralized tBTC and protects the protocol from insolvency risks.

There are various considerations and scenarios to examine for such a system, and we are happy to assist with this research.

Regarding liquidity: Mainnet liquidity has improved, allowing 335 tBTC to WBTC at 7.5% slippage. Arbitrum liquidity is also conducive to onboarding, with 197 tBTC to WBTC at 7.5% slippage. However, we believe Optimism liquidity remains too low for onboarding at this time.

We will align with @ChaosLabs and propose revised parameters for onboarding shortly.

1 Like

How about onboarding tbtc on the base market aswell?

Overview

After reviewing the previously recommended parameters and characteristics for tBTC, we reaffirm our original recommendation, as there have not been any significant changes to the asset’s characteristics.

Regarding tBTC pricing, we commend @bgdlabs for their comprehensive analysis and support using the BTC/USD price feed (option 2) during the initial phase of the market to mitigate the risk of price manipulation.

We also endorse @LlamaRisk’s proposal to utilize Chainlink’s Proof-of-Reserve feeds as a trigger to switch to market pricing, which would help prevent unnecessary bad debt in the event of insolvency.

In terms of liquidity, we highlight that while there are improvements in certain areas compared to previous analyses, this is largely due to the volatility of liquidity depth, which remains highly concentrated. Overall, on-chain liquidity has decreased slightly since our last review.

image - 2024-09-17T013408.180

Therefore, we do not recommend more aggressive listing parameters for the Ethereum deployment.

We support an Arbitrum listing with parameters aligned to the Ethereum deployment but with reduced supply and borrow caps of 80 tBTC and 40 tBTC, respectively, following Aave’s methodology of keeping volatile assets’ caps below 50% of the on-chain supply.

Finally, we agree that liquidity on Optimism is too low to list the asset at this point in time.

CAPO recommendations:

Given tBTC’s capability to be redeemed 1:1 for BTC permissionlessly within hours, we recommend aligning our price cap recommendations with those of similar assets.

Price Cap
4%

Specification

Following the previously recommended parameters, we recommend listing tBTC on Arbitrum with the following parameter settings:

Parameter Value
Isolation Mode No
Borrowable Yes
Collateral Enabled Yes
Supply Cap (tBTC) 80
Borrow Cap (tBTC) 40
Debt Ceiling -
LTV 73.00%
LT 78.00%
Liquidation Bonus 7.50%
Liquidation Protocol Fee 10.00%
Variable Base 0.0%
Variable Slope1 4.00%
Variable Slope2 300.00%
Uoptimal 45.00%
Reserve Factor 20.00%
Stable Borrowing Disabled
Flashloanable Yes
Siloed Borrowing No
Borrowed in Isolation No

We will update the recommendation in our first response.

2 Likes

Hello,

After discussing with Service providers the best path forward for this AIP implementation:

  1. This proposal will be implemented on the Ethereum Main instance only first, as it is the instance with the most potential and liquidity.

  2. onboarding will use a BTC/USD feed, until the tBTC/USD feed with a capo is mature enough to upgrade the oracle.

5 Likes

Where is the Proof of Liquidity and deposit commitments? cc @ACI