Skip to content

myfridayio/dss-conduits

 
 

Repository files navigation

dss-conduits

Foundry CI Foundry License: AGPL v3

Overview

The Conduit is a smart contract that facilitates the deployment of funds to yield bearing strategies as part of the DSS Allocator System. The Conduit has a standard interface, defined in the dss-allocator repo here. There are intended to be many Conduit implementations, each with a different use case. All Conduits can be found in the src directory.

For technical documentation and further information on specific Conduits, please see the wiki.

Upgradeability

Since Conduits will likely require maintenance as their desired usage evolves, they will be upgradeable contracts, using upgradeable-proxy for upgradeable logic. This is a non-transparent proxy contract that gives upgrade rights to the PauseProxy.

Testing

To run the tests, do the following:

forge test

Functionality

deposit

The deposit function is used to move funds from a given ilks buffer into the Conduit. From the Conduit, the funds can be deployed to a yield bearing strategy. This can happen atomically in the case of DeFi protocols, or can happen in a separate function call made by a permissioned actor in the case of Real World Asset strategies.

withdraw

The withdraw function is used to move funds from the Conduit into a given ilks buffer. This can pull funds atomically from a yield bearing strategy in the case of DeFi protocols, or can pull the funds directly from the Conduit in the case of a Real World Asset strategy where the permissioned actor has returned the funds manually. Both situations require that there is available liquidity, which is why maxWithdraw exists. This view function should report the maximum amount of asset that can be withdrawn for a given ilk.

Disclaimer

This code belongs to the MakerDAO community and the Copyright for the code belongs to the Dai Foundation.


About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Solidity 74.5%
  • Ruby 25.4%
  • Makefile 0.1%