Add Collateral - AtomicLoans/atomicloans-rfc GitHub Wiki

After establishing a Refundable and Seizable collateral address for the loan, borrowers can add additional collateral by sending Bitcoin to either Refundable and/or Seizable collateral addresses to increase their collateralization ratio.

Collateral Tx Confirmations

Once additional collateral has been sent to either collateral addresses, the SPV Relay will provide two proofs. One after 1 confirmation, and another after 6 confirmations.

Trust assumptions

This system assumes that the SPV Relay correctly verifies the PoW done on the Bitcoin chain, and allows any party to provide proofs in the case that the SPV Relay Manager goes offline.

Min Seizable Collateral

In order to successfully add collateral, the necessary amount of Seizable collateral must be added before adding Refundable collateral. This is to ensure that the Lender can always seize the necessary amount to recuperate their loan principal.

Temporary Collateral

After 1 confirmations, temporary collateral will increased. Once the proof for 6 confirmations has been received, the temporary Refundable or Seizable collateral will be moved to Refundable or Seizable collateral.

In the case that Refundable collateral is added when the minimum Seizable collateral is not satisfied, that collateral will be added to unaccountedRefundableCollateral until Seizable collateral is satisfied, in which case that unaccountedRefundableCollateral will be moved to Refundable collateral.

Interfaces

SPV Relay Interface

The Loans.sol contract is the SPV Consumer, and receives proofs in the spv function.