---
# System prepended metadata

title: Certik Audit

---

# Certik Audit

Scope (in order of importance)

- Contracts in folders governance, reserve, staking, ubi
- Upgrade process script and contract 
    - scripts/upgradeToV2/upgradeToV2.ts
    - utils/ProtocolUpgrade.sol
- GDX + GDAO merklehash calculations for airdrop
    - scripts/gdx/gdxAirdropCalculations.ts
    - scripts/governance/airdropCalculations.ts
- Helpers contracts in utils folder
    - NameService.sol
    - DAOContract.sol
    - DAOUpgradeableContract.sol

### Contracts to fully audit

#### Governance
- GReputation.sol - GDAO token contract
- ClaimersDistribution.sol - integrate with ubi/UBIScheme to distribute GDAO to claimers
- StakersDistribution.sol - integrates with staking/SimpleStaking to distribute GDAO to stakers
- GovernanceStaking.sol - G$ staking contract, distributes GDAO to G$ stakers.
- MultiBaseGovernanceShareField.sol - helper contract used in StakersDistribution and GovernanceStaking to calculate pro-rata GDAO rewards

#### Staking
- SimpleStaking.sol - Basic logic used by all staking contracts
- BaseShareField.sol - helper contract to calculate staking rewards pro-rata
- GoodCompoundStaking.sol - instance of SimpleStaking using Compound

#### Utils
- ProtocolUpgrade.sol - DAO actions to execute by Avatar to migrate existing DAO to new version
- NameService.sol - simple contracts registery
- DAOContract.sol - simple helper contract to get basic DAO data
- DAOUpgradeableContract.sol - DAOContract that is UUPS upgradable and can be upgraded only by DAO (avatar)

### The following contracts should only be audited for changes

#### Governance
- CompoundVotingMachine.sol vs https://github.com/compound-finance/compound-protocol/blob/b9b14038612d846b83f8a009a82c38974ff2dcfe/contracts/Governance/GovernorAlpha.sol

- Reputation.sol vs https://github.com/daostack/infra/blob/60a79a1be02942174e21156c3c9655a7f0695dbd/contracts/Reputation.sol

#### Reserve
- GoodMarketMaker.sol vs https://github.com/GoodDollar/GoodContracts/blob/b84605c983cb431cbca11ecd3185f1afd1494ce4/stakingModel/contracts/GoodMarketMaker.sol

- GoodReserveCDai.sol vs https://github.com/GoodDollar/GoodContracts/blob/b84605c983cb431cbca11ecd3185f1afd1494ce4/stakingModel/contracts/GoodReserveCDai.sol

#### Staking
- GoodFundManager.sol vs 
https://github.com/GoodDollar/GoodContracts/blob/b84605c983cb431cbca11ecd3185f1afd1494ce4/stakingModel/contracts/GoodFundManager.sol

#### UBI
- UBIScheme.sol
https://github.com/GoodDollar/GoodContracts/blob/b84605c983cb431cbca11ecd3185f1afd1494ce4/stakingModel/contracts/UBIScheme.sol


### Scripts to audit
- scripts/upgradeToV2/upgradeToV2.ts
- scripts/gdx/gdxAirdropCalculations.ts
- scripts/governance/airdropCalculations.ts
