Hacker News new | ask | show | jobs
by rat_melter 1991 days ago
>How do the oracles work with these kinds of smart contracts?

It depends. Many exploits are based on asymmetric oracle data, or asymmetric trades using flash loans. Mainly oracles will be used for aggregated price feed data from centralized exchanges, thus making the prices an average across the board. This keeps it even for everyone involved that integrates the same oracles that everyone else does, and a proper oracle network will keep bad actors at bay by mitigating excessive arbitrage opportunities. Well-meaning oracles are critical for these kinds of decentralized finance opportunities.

>You can borrow crypto against other crypto?! What is the use case for that?

If I put my tokens up for borrowing, I'm providing liquidity into a pool. It allows me to leverage my own money into a series of "IOU's" from smart contracts that pay out dividends by collecting small fees from people who borrow from this pool as a payment for providing this utility.

To answer your second question: The use case is ultimately adding liquidity to the market, and getting paid for doing so, while also being able to leverage the IOU's (in some scenarios) into more dividends payouts.

It sounds more complicated than it is. Boiling it down looks something like this:

  Provide - ETH-BTC  to a pool          || Receive -  aETHBTC  tokens (an IOU)
  Provide - aETHBTC  to a pool (an IOU) || Receive -  aETHBTC  tokens (an IOU)
  Provide - yaETHBTC to a pool (an IOU) || Receive - yyaETHBTC tokens (an IOU)
  ... etc.
It's interesting and affords a lot of opportunities, but you should be careful to read every contract and only enter positions that have none or little "impermanent loss". I'd recommend you find the fee structure for a pool, find the market demand and study what the pros/cons are of lending your money. You may lend out a token and it may drop in value while those IOUs become worth less while you're trying to cash them out. Or, you may borrow an asset against your assets to market sell and effectively short the borrowed token, only to be liquidated when the token rises and you need to pay back your loan.

Just be careful of your gas bill while you're learning :)

1 comments

Thanks a lot for the detailed answer. I'm presently not interested in using any of these services, but I am trying to keep up with the developments of crpytofinance.