Lava Loans Protocol v2: DLC Based Bitcoin Collateralized Loans

3 months ago 25

The Lava Loans protocol (v2) is simply a strategy designed by Lava gathering upon Discreet Log Contracts (DLCs) to facilitate a trustless Bitcoin collateralized indebtedness system. The immense implosion successful the marketplace past rhythm caused by centralized platforms facilitating Bitcoin backed loans showed that near unchecked, specified products and services tin contiguous a monolithic systemic hazard to the full marketplace successful the ecosystem.

Lava seeks to supply the aforesaid inferior users of specified centralized platforms sought successful a decentralized and atomic fashion, utilizing DLCs.

DLCs, for those unfamiliar with the concept, are a astute declaration designed to settee a definite mode depending connected the result of immoderate lawsuit extracurricular of the Bitcoin protocol, i.e. the terms of Bitcoin, the result of a sports game, etc. This is done by depending connected an oracle, oregon a acceptable of aggregate oracles, who motion a connection attesting to the existent result of the existent satellite event. These signed messages are utilized arsenic the ground for adapter signatures that unlock circumstantial pre-signed transactions that settee the declaration a definite way.

The payment of DLCs is they tin beryllium done privately. As agelong arsenic the oracle(s) people the keys they volition usage to motion outcomes for circumstantial events astatine circumstantial times, immoderate idiosyncratic tin instrumentality that accusation and conception pre-signed transactions to settee correctly based connected the scope of imaginable outcomes without the oracle ever knowing that a declaration exists. The oracle simply publically broadcasts the signed connection astatine the due time, and that gives some users each the needed accusation to settee the declaration correctly.

Lava is designed to marque usage of a modified variant of DLCs, successful summation to stablecoins connected different networks, successful bid to facilitate a bitcoin collateralized indebtedness that tin beryllium entered into atomically and trustlessly (i.e. guaranteeing that the lender cannot summation power of bitcoin without releasing power of the stablecoin to the borrower).

Instantiation

The backing of the DLC is simply a 2 measurement process successful the Lava protocol, fixed the request that the stablecoins fixed successful speech for the collateral being locked successful the declaration indispensable beryllium atomic. In the archetypal phase, the borrower creates a publication that allows them to assertion their coin backmost aft a timelock, oregon allows the lender to implicit the backing with a hash preimage and signature from the borrower. They past motion a transaction that moves the coins from this staging code into the DLC. The lender past exchanges a hashlock for usage aboriginal successful the protocol with the borrower.

From this point, the lender needs to money a akin atomic speech declaration with the borrower connected the concatenation hosting the stablecoin. This declaration allows the borrower to assertion the stablecoins with the aforesaid preimage utilized to finalize the DLC connected Bitcoin, oregon the lender to reclaim the stablecoins aft a timeout. The declaration connected the alt-chain is besides collateralized with other stablecoins that stay successful the contract, and cannot beryllium claimed backmost by the lender until aft the completion of the contract. This volition beryllium explained later.

After the setup phase, the borrower releases the preimage to the hashlock, claims the stablecoins, and enables the lender to determination the bitcoin from the staging code into a finalized DLC. At this constituent the declaration is active.

Execution

During the beingness of the declaration determination are 3 ways that the indebtedness tin beryllium settled, either astatine expiry oregon during its lifetime. Firstly, the lender tin execute the DLC with the borrower’s adaptor signature, and an attestation of the existent terms from the oracle(s). Secondly, the borrower tin execute with the lender’s adaptor signature and an attestation from the oracle(s). Lastly, the borrower tin repay the indebtedness connected the alt-chain, enabling them to assertion backmost bitcoin collateral erstwhile the lender claims their repayment and stablecoin collateral. All of these execution paths disperse the due magnitude of bitcoin to some parties based connected the marketplace terms attested to by the oracle(s).

The repayment way makes usage of the 2nd hash preimage that the lender generated during the setup. The DLC publication is modified allowing the borrower to assertion backmost the collateral astatine immoderate clip during the declaration beingness arsenic agelong arsenic they person the preimage to that the lender has generated. On the alt-chain, the stablecoin declaration is besides established to necessitate the lender to uncover that preimage to assertion backmost their repayment and collateral.

This operation for repayment is added to woody with the inducement wherever a repayment is made, but the lender does not finalize the repayment due to the fact that the involvement outgo connected the indebtedness outstanding is greater than the involvement that could beryllium earned from them issuing a caller loan. This is besides the crushed that the lender is required to collateralize the alt-chain declaration with other stablecoins, creating an inducement for them to redeem a repayment. Without doing so, they cannot assertion the collateral back, thereby creating an inducement for them to grant the repayment and merchandise the bitcoin collateral adjacent erstwhile determination is simply a fiscal inducement owed to the involvement payments to not bash so.

Once the lender releases the preimage to assertion backmost the repayment and the stablecoin collateral, the borrower is past susceptible of unilaterally spending the DLC output by utilizing the released preimage. This guarantees that the borrower is capable to unilaterally reclaim their bitcoin collateral aft the lender takes possession of their indebtedness repayment.

Liquidation and Safe Guards

Like the DLC Markets proposal, Lava supports a liquidation procedure. In the lawsuit that the oracle attests to a terms that is beneath a pre-defined liquidation level, pre-signed transactions corresponding to the liquidation lawsuit tin beryllium utilized by the lender to assertion the entirety of the collateral. This is to warrant that during the lawsuit of a monolithic terms plaything that lowers the collateral worth beyond the indebtedness value, the lender is susceptible of liquidating it erstwhile indispensable to screen the stablecoin worth the borrower claimed. Otherwise, they could beryllium faced with the hazard of waiting until the declaration expiry and being stuck with bitcoin that is little invaluable than what they person lent out, resulting successful a fiscal nonaccomplishment for the lender.

In summation to the liquidation procedure, determination is besides an exigency betterment enactment disposable agelong aft the declaration expiry. During acceptable up signatures for pre-signed transactions agelong aft the declaration expiry are exchanged. These are utilized successful the lawsuit that the oracle(s) neglect to present signatures connected terms attestations, oregon successful the lawsuit that the borrower stops cooperating with the lender, oregon vice versa.

The lender is susceptible of utilizing 1 of these to assertion the entirety of the bitcoin collateral successful the lawsuit the oracle(s) don’t attest to the price, oregon the borrower becomes non-cooperative successful that case. This is to guarantee that the bitcoin successful the DLC is ne'er astatine hazard of being burned. For akin reasons, a transaction timelocked for agelong aft the lender’s is available. This allows the borrower to yet assertion backmost their collateral if the oracle(s) and lender go unresponsive.

Conclusion

By somewhat modifying the DLC protocol to see a basal hashlock, and the instauration of the liquidation mechanics akin to DLC Markets, the Lava protocol has created a variant of DLCs perfectly suited for bitcoin collateralized lending. While the dependence connected oracles inactive exists, similar with immoderate DLC protocol oregon application, the introduction and exit of the indebtedness is wholly atomic and trustless betwixt the borrower and lender.

This proves an immense magnitude of worth successful subtly tweaking existing Bitcoin declaration structures to acceptable circumstantial usage cases, and offers a pathway to gathering a wide demanded request successful the ecosystem that does not contiguous the systemic hazard of instability that centralized equivalents created successful the past. 

Read Entire Article