DIVA Protocol
  • 👋Welcome
  • 🔅Introduction
    • Derivative contracts
    • What is DIVA Protocol
      • What problem does it solve
      • How it works
        • Reference assets
        • Payoff curves
        • Collateral
        • Oracles
        • Settlement
          • Timelines
          • Challenge
          • Status
          • Fast settlement
          • Fallback data provider
        • Fees
        • Compliance feature
      • Vision
      • Terminology
    • What is DIVA Token
      • Owner election mechanism
      • Token distribution
    • DIVA Development Fund
    • FAQ
  • 🌈DIVA App
    • What is DIVA App
    • Overview
    • Create position tokens
    • Trade position tokens
    • Add liquidity
    • Remove liquidity
  • ⚙️Guides
    • DIVA App Training
      • Prepare
      • Testnet
      • Create
      • Trade
      • Add
      • Remove
      • Settle
      • Redeem
      • Fees
    • Quiz
  • 🪄Use cases
    • Overview
    • Insurance
      • Credit default protection
      • Agrarian insurance
      • DeFi Hack insurance
      • Peg insurance
    • Yield optimization
      • Bullish accumulation
      • Bearish accumulation
    • Risk management
      • Downside protection
      • Increasing cost protection
    • Directional bets
      • Downside bet
      • "Bottom-Is-In" bet
      • Upside bet
      • "Top-Is-In" bet
    • Leverage
  • 👨‍🎓Pricing derivatives
    • Introduction
    • Underlying value
    • Volatility
    • Time
  • ⚓Oracle integrations
    • Overview
    • Tellor
  • ⚒️For developers
    • Overview
    • Technical resources
    • Smart contracts
      • Functions
        • Core protocol functions
        • Getter functions
        • Setter functions
        • ABI
      • Contract addresses
      • Example scripts
    • TheGraph
      • DIVA subgraphs
      • Whitelist subgraph
    • Project ideas
  • 📱Contact & Media Links
    • Social media
  • 👨‍🎓Technical Blog
    • Flash loans in DIVA Protocol
    • NDVI outcome reporting guide for Tellor Reporters
    • Enabling capital efficiency in DeFi
Powered by GitBook
On this page
  • Pool configuration
  • Sell long position tokens
  • 💵 Payoff scenarios
  • Variations
  1. Use cases
  2. Insurance

DeFi Hack insurance

An insurance product that protects users in the event of a protocol hack

PreviousAgrarian insuranceNextPeg insurance

Last updated 2 years ago

Bob has deposited funds into a new DeFi protocol called FutureOfDeFi. He is concerned that it might get hacked and he may lose all his funds. Bob would like to protect himself by buying an insurance against such an event. In other words, he would like to purchase a position that will pay out a certain amount of money in the event of a hack and zero otherwise.

The FutureOfDeFi team would like to offer such an insurance product to their users to signal confidence in the security of their protocol. In other words, they are willing to accept the risk of losing a certain amount of money (which they have to deposit upfront) in the event of a hack in exchange for a fee (also referred to as "premium").

Pool configuration

As there is no existing market, the FutureOfDeFi team uses the DIVA App to create those directionally reversed positions using the following configuration (the oracle is defined in a second step and not displayed below):

  • Note that any outcome value below inflection (which is 1 in our example) means "not hacked" and any value equal to or above inflection means "hacked".

After creating the pool, the FutureOfDeFi team puts 100 long position tokens for sale, for a price of DAI 0.03 each, and keeps the short position tokens. Bob purchases all long position tokens for a total of DAI 3. After the trade, the two parties end up with the following positions:

💵 Payoff scenarios

1) FutureOfDeFi was hacked (final value=1):

  • The FutureOfDeFi team received a premium of DAI 5 from selling the long position tokens to Bob, but loses the collateral that they initially deposited into the pool -> net loss for FutureOfDeFi: DAI 95 -> net gain for Bob: DAI 95

2) FutureOfDeFi was not hacked (final value=0):

  • The FutureOfDeFi team can redeem all the collateral that they initially deposited into the pool (DAI 100) and in addition keep the premium of DAI 5 -> net gain for FutureOfDeFi: DAI 5 (5% yield on initially deposited capital) -> net loss for Bob: DAI 5

Instead of using a binary metric ("hacked" or "not hacked"), the FutureOfDeFi team could have chosen the USD amount stolen during a hack as the underlying metric and attach a cliff shaped pattern to it. Below an example configuration using the DIVA App:

After a trade, the two parties would end up with the following positions:

In this example, if the protocol is hacked, there will be a linearly increasing payout for Bob in the range $10mln to $70mln and a jump to the maximum payoff if the hacked amount exceeds $70mln.

Sell long position tokens

Variations

🪄
🤝
🌈
⚙️
Example configuration for a DeFi Hack insurance product in the DIVA App using a binary payoff profile.
Payoff profiles for Bob and FutureOfDeFi team for 100 long/short tokens, each paying out a maximum amount of DAI 1.0 per token. Floor and Cap are automatically set equal to inflection in the background to achieve a binary shaped payoff profile.
Example configuration of a DeFi Hack insurance products using a non-binary underlying metric and payoff profile.
Payoff profiles for Bob and FutureOfDeFi team for 100 long/short tokens, each paying out a maximum amount of DAI 1.0 per token.