Skip to content
Documentation

Price Oracle

The whole model stands on the mark price. This is the most sensitive part of the protocol.

The problem

The spot price of a small token can be moved with little capital. A manipulated price would let an attacker open positions cheaply, or push honest traders into liquidation. An oracle for emerging tokens has to make that expensive.

Current design

The prototype uses signed prices.

  1. Read

    A price service reads the token's price from its most liquid pool and refuses tokens whose liquidity is below a minimum.

  2. Sign

    The service signs the price together with the token, a timestamp, the chain and the contract it is meant for.

  3. Submit

    The trader's transaction submits the signed price just before acting. The contract accepts it only if the signature is valid and the price is recent.

A signature made for one chain or contract cannot be reused on another.

Limits of this design