• Stars
    star
    135
  • Rank 269,297 (Top 6 %)
  • Language
    Solidity
  • License
    Other
  • Created almost 2 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Maple V2 Core

Foundry CI GitBook - Documentation Foundry License: BUSL 1.1

Overview

This repository brings together the core smart contracts of the Maple V2 protocol as dependencies in order to perform integration tests and simulations.

Submodules

Submodules imported:

Versions of dependencies can be checked with git submodule status.

Setup

This project was built using Foundry. Refer to installation instructions here.

git clone [email protected]:maple-labs/maple-core-v2.git
cd maple-core-v2
forge install

Commands

To make it easier to perform some tasks within the repo, a few commands are available through a makefile:

Build Commands

Command Action
make build Compile all contracts in the repo, including submodules.
make clean Delete cached files.

Test Commands

Command Description
make test Run all tests located in contracts/tests/.
make e2e Run all end-to-end tests.
make fuzz Run all fuzz tests.
make integration Run all integration tests (Must have ETH_RPC_URL configured to mainnet).
make invariant Run the invariant tests.

Specific tests can be run using forge test conventions, specified in more detail in the Foundry Book.

Simulation Commands

For the following commands, a $ETH_RPC_URL environment value needs to be configured with a valid rpc url.

Command Description
make upgrade Run the upgrade simulations against mainnet

Audit Reports

December 2022 Release

Auditor Report Link
Trail of Bits 2022-08-24 - Trail of Bits Report
Spearbit 2022-10-17 - Spearbit Report
Three Sigma 2022-10-24 - Three Sigma Report

June 2023 Release

Auditor Report Link
Spearbit Auditors via Cantina 2023-06-05 - Cantina Report
Three Sigma 2023-04-10 - Three Sigma Report

Bug Bounty

For all information related to the ongoing bug bounty for these contracts run by Immunefi, please visit this site.

About Maple

Maple Finance is a decentralized corporate credit market. Maple provides capital to institutional borrowers through globally accessible fixed-income yield opportunities.


More Repositories

1

revenue-distribution-token

Token to distribute aggregated vested earnings of any underlying token using the ERC-4626 standard.
Solidity
161
star
2

maple-core

Maple Core Protocol
Shell
72
star
3

erc20

Maple implementation of the ERC-20 standard
Solidity
63
star
4

loan

Maple protocol smart contracts to facilitate on-chain loans between Pools and institutional borrowers.
Solidity
33
star
5

contract-test-utils

It provides helper functions to test the maple-core contracts.
Solidity
21
star
6

proxy-factory

Generic factory for deploying upgradeable proxy contracts
Solidity
21
star
7

contract-test-suite

Contract Test Suite
Solidity
18
star
8

xMPL

Token for accruing protocol revenues
Solidity
16
star
9

maple-proxy-factory

A Maple flavored proxy factory
Solidity
11
star
10

pool-v2

Solidity
10
star
11

debt-locker

Solidity
7
star
12

erc20-helper

Solidity
3
star
13

non-transparent-proxy

Non-transparent proxy for non-factory based upgradeable contracts.
Solidity
3
star
14

maple-tools

Various Maple Tools
JavaScript
2
star
15

address-registry

Solidity
2
star
16

loan-simulations

Repo for simulating loans on mainnet to test migrations, refinances, etc.
Solidity
2
star
17

chainlink-oracle

Solidity
2
star
18

liquidations

Flash loan liqudation module
Solidity
2
star
19

mpl-migration

Solidity
2
star
20

maple-docs

Maple Protocol Documentation
2
star
21

globals-v2

Repo for MapleGlobals V2
Solidity
2
star
22

proxy-factory-erc20-demo

Proxy Factory ERC20 Demo
Solidity
1
star
23

treasury

Solidity
1
star
24

withdrawal-manager

Repo for doing smart contracts research for PoolV2
Solidity
1
star
25

liquidity-locker

Solidity
1
star
26

maple-token

Solidity
1
star
27

hardhat-scripts

Hardhat Ethereum scripts
JavaScript
1
star
28

mpl-rewards

Solidity
1
star