Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): bump lib/aave-v3-origin from 6948864 to 105baaf #595

Merged
merged 4 commits into from
Sep 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/aave-v3-origin
Submodule aave-v3-origin updated 92 files
+78 −0 .github/workflows/certora-stata.yml
+1 −0 Makefile
+ audits/11-09-2024_Certora_StataTokenV2.pdf
+ bun.lockb
+1 −0 certora/conf/AToken.conf
+1 −0 certora/conf/NEW-pool-no-summarizations.conf
+1 −0 certora/conf/NEW-pool-simple-properties.conf
+1 −0 certora/conf/ReserveConfiguration.conf
+1 −0 certora/conf/StableDebtToken.conf
+1 −0 certora/conf/UserConfiguration.conf
+1 −0 certora/conf/VariableDebtToken.conf
+1 −1 certora/scripts/run-all.sh
+6 −6 certora/specs/NEW-pool-base.spec
+1 −1 certora/specs/NEW-pool-no-summarizations.spec
+33 −0 certora/stata/Makefile
+48 −0 certora/stata/applyHarness.patch
+40 −0 certora/stata/conf/verifyAToken.conf
+40 −0 certora/stata/conf/verifyDoubleClaim.conf
+40 −0 certora/stata/conf/verifyERC4626.conf
+39 −0 certora/stata/conf/verifyERC4626DepositSummarization.conf
+40 −0 certora/stata/conf/verifyERC4626Extended.conf
+41 −0 certora/stata/conf/verifyERC4626MintDepositSummarization.conf
+40 −0 certora/stata/conf/verifyStataToken.conf
+73 −0 certora/stata/harness/StataTokenV2Harness.sol
+89 −0 certora/stata/harness/pool/SymbolicLendingPool.sol
+42 −0 certora/stata/harness/rewards/RewardsControllerHarness.sol
+23 −0 certora/stata/harness/rewards/TransferStrategyHarness.sol
+30 −0 certora/stata/harness/rewards/TransferStrategyMultiRewardHarness.sol
+49 −0 certora/stata/harness/tokens/DummyERC20Impl.sol
+5 −0 certora/stata/harness/tokens/DummyERC20_aTokenUnderlying.sol
+5 −0 certora/stata/harness/tokens/DummyERC20_rewardToken.sol
+2 −0 certora/stata/munged/.gitignore
+95 −0 certora/stata/scripts/run-all.sh
+399 −0 certora/stata/specs/StataToken/StataToken.spec
+246 −0 certora/stata/specs/StataToken/aTokenProperties.spec
+65 −0 certora/stata/specs/StataToken/double_claim.spec
+754 −0 certora/stata/specs/erc4626/erc4626.spec
+163 −0 certora/stata/specs/erc4626/erc4626DepositSummarization.spec
+254 −0 certora/stata/specs/erc4626/erc4626Extended.spec
+220 −0 certora/stata/specs/erc4626/erc4626MintDepositSummarization.spec
+236 −0 certora/stata/specs/methods/CVLMath.spec
+12 −0 certora/stata/specs/methods/erc20.spec
+195 −0 certora/stata/specs/methods/methods_base.spec
+75 −0 certora/stata/specs/methods/methods_multi_reward.spec
+22 −19 foundry.toml
+1 −1 lib/solidity-utils
+1 −1 package.json
+3 −1 remappings.txt
+1 −1 scripts/misc/DeployAaveV3MarketBatchedBase.sol
+7 −6 src/deployments/contracts/procedures/AaveV3HelpersProcedureTwo.sol
+8 −5 src/periphery/contracts/adapters/paraswap/BaseParaSwapBuyAdapter.sol
+1 −0 src/periphery/contracts/adapters/paraswap/BaseParaSwapSellAdapter.sol
+21 −5 src/periphery/contracts/adapters/paraswap/ParaSwapRepayAdapter.sol
+0 −180 src/periphery/contracts/dependencies/openzeppelin/ECDSA.sol
+0 −207 src/periphery/contracts/dependencies/solmate/ERC20.sol
+0 −42 src/periphery/contracts/libraries/RayMathExplicitRounding.sol
+305 −0 src/periphery/contracts/static-a-token/ERC20AaveLMUpgradeable.sol
+291 −0 src/periphery/contracts/static-a-token/ERC4626StataTokenUpgradeable.sol
+68 −7 src/periphery/contracts/static-a-token/README.md
+0 −41 src/periphery/contracts/static-a-token/StataOracle.sol
+91 −0 src/periphery/contracts/static-a-token/StataTokenFactory.sol
+121 −0 src/periphery/contracts/static-a-token/StataTokenV2.sol
+0 −14 src/periphery/contracts/static-a-token/StaticATokenErrors.sol
+0 −86 src/periphery/contracts/static-a-token/StaticATokenFactory.sol
+0 −712 src/periphery/contracts/static-a-token/StaticATokenLM.sol
+ src/periphery/contracts/static-a-token/inheritance.png
+2 −0 src/periphery/contracts/static-a-token/interfaces/IAToken.sol
+106 −0 src/periphery/contracts/static-a-token/interfaces/IERC20AaveLM.sol
+0 −241 src/periphery/contracts/static-a-token/interfaces/IERC4626.sol
+71 −0 src/periphery/contracts/static-a-token/interfaces/IERC4626StataToken.sol
+0 −32 src/periphery/contracts/static-a-token/interfaces/IInitializableStaticATokenLM.sol
+0 −31 src/periphery/contracts/static-a-token/interfaces/IStataOracle.sol
+26 −0 src/periphery/contracts/static-a-token/interfaces/IStataTokenFactory.sol
+22 −0 src/periphery/contracts/static-a-token/interfaces/IStataTokenV2.sol
+0 −24 src/periphery/contracts/static-a-token/interfaces/IStaticATokenFactory.sol
+0 −214 src/periphery/contracts/static-a-token/interfaces/IStaticATokenLM.sol
+1 −1 tests/DeploymentsGasLimits.t.sol
+7 −7 tests/core/Pool.t.sol
+1 −1 tests/core/PoolConfigurator.upgradeabilty.t.sol
+404 −0 tests/periphery/static-a-token/ERC20AaveLMUpgradable.t.sol
+482 −0 tests/periphery/static-a-token/ERC4626StataTokenUpgradeable.t.sol
+0 −57 tests/periphery/static-a-token/StataOracle.t.sol
+35 −0 tests/periphery/static-a-token/StataTokenV2Getters.sol
+108 −0 tests/periphery/static-a-token/StataTokenV2Pausable.t.sol
+83 −0 tests/periphery/static-a-token/StataTokenV2Permit.sol
+54 −0 tests/periphery/static-a-token/StataTokenV2Rescuable.sol
+0 −609 tests/periphery/static-a-token/StaticATokenLM.t.sol
+0 −252 tests/periphery/static-a-token/StaticATokenMetaTransactions.t.sol
+0 −50 tests/periphery/static-a-token/StaticATokenNoLM.t.sol
+40 −36 tests/periphery/static-a-token/TestBase.sol
+1 −1 tests/utils/DiffUtils.sol
+4 −79 tests/utils/SigUtils.sol
9 changes: 5 additions & 4 deletions scripts/configs/abis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import {mainnetProtoV3Pool} from './pools/ethereum';

/**
* @dev These abis can be inferred directly from code as they exist as a dependency
* For contracts that are not unique, the path needs to be prefixed
*/
export const ABI_INTERFACES = [
'ICollector',
Expand All @@ -15,11 +16,11 @@ export const ABI_INTERFACES = [
'IGovernancePowerStrategy',
'IDataWarehouse',
'IExecutorWithTimelock',
'IERC20',
'lib/aave-v3-origin/src/core/contracts/dependencies/openzeppelin/contracts/IERC20.sol:IERC20',
'IERC20Detailed',
'IAToken',
'IDefaultInterestRateStrategy',
'IAaveOracle',
'lib/aave-v3-origin/src/core/contracts/interfaces/IAaveOracle.sol:IAaveOracle',
'IExecutor',
'ICrossChainController',
'IWithGuardian',
Expand All @@ -32,8 +33,8 @@ export const ABI_INTERFACES = [
'IPoolAddressesProvider',
'IPoolConfigurator',
'IStakeToken',
'IStaticATokenFactory',
'IStaticATokenLM',
'IStataTokenFactory',
'IStataTokenV2',
];

/**
Expand Down
7 changes: 5 additions & 2 deletions scripts/generateABIs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@ export async function generateABIs(removeExisting: boolean) {
} else {
mkdirSync('./src/ts/abis');
}
for (const INTERFACE of ABI_INTERFACES) {
const {stdout, stderr} = await awaitableExec(`forge inspect ${INTERFACE} abi`);
const imports: string[] = [];
for (const INTERFACE_PATH of ABI_INTERFACES) {
const {stdout, stderr} = await awaitableExec(`forge inspect ${INTERFACE_PATH} abi`);
const INTERFACE =
INTERFACE_PATH.split(':').length > 1 ? INTERFACE_PATH.split(':')[1] : INTERFACE_PATH;
if (stderr) {
throw new Error(`Failed to generate abi for ${INTERFACE}`);
}
Expand Down
4 changes: 3 additions & 1 deletion scripts/generator/abis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@ import {ABI_INTERFACES, DOWNLOAD_ABI_INTERFACES} from '../configs/abis';

export function generateABIImports() {
const jsExports: string[] = [];
for (const INTERFACE of ABI_INTERFACES) {
for (const INTERFACE_PATH of ABI_INTERFACES) {
const INTERFACE =
INTERFACE_PATH.split(':').length > 1 ? INTERFACE_PATH.split(':')[1] : INTERFACE_PATH;
const varName = `${INTERFACE}_ABI`;
jsExports.push(`export {${varName}} from './abis/${INTERFACE}';`);
}
Expand Down
2 changes: 0 additions & 2 deletions src/AaveV2.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
pragma solidity >=0.6.0;
pragma experimental ABIEncoderV2;

import {AggregatorInterface} from './common/AggregatorInterface.sol';

library DataTypes {
// refer to the whitepaper, section 1.1 basic concepts for a formal description of these properties.
struct ReserveData {
Expand Down
18 changes: 0 additions & 18 deletions src/common/AggregatorInterface.sol

This file was deleted.

4 changes: 2 additions & 2 deletions src/test/AaveV2Ethereum.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import {AaveV2Ethereum} from '../AaveAddressBook.sol';
// imports are unused but required so forge inspect can find the source code
import {IERC20Detailed} from 'aave-v3-origin/core/contracts/dependencies/openzeppelin/contracts/IERC20Detailed.sol';
import {IWithGuardian} from 'solidity-utils/contracts/access-control/interfaces/IWithGuardian.sol';
import {IStaticATokenFactory} from 'aave-v3-origin/periphery/contracts/static-a-token/interfaces/IStaticATokenFactory.sol';
import {IStaticATokenLM} from 'aave-v3-origin/periphery/contracts/static-a-token/interfaces/IStaticATokenLM.sol';
import {IStataTokenFactory} from 'aave-v3-origin/periphery/contracts/static-a-token/interfaces/IStataTokenFactory.sol';
import {IStataTokenV2} from 'aave-v3-origin/periphery/contracts/static-a-token/interfaces/IStataTokenV2.sol';

contract AaveAddressBookTest is Test {
function setUp() public {}
Expand Down
4 changes: 2 additions & 2 deletions src/ts/AaveAddressBook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,8 @@ export {IPool_ABI} from './abis/IPool';
export {IPoolAddressesProvider_ABI} from './abis/IPoolAddressesProvider';
export {IPoolConfigurator_ABI} from './abis/IPoolConfigurator';
export {IStakeToken_ABI} from './abis/IStakeToken';
export {IStaticATokenFactory_ABI} from './abis/IStaticATokenFactory';
export {IStaticATokenLM_ABI} from './abis/IStaticATokenLM';
export {IStataTokenFactory_ABI} from './abis/IStataTokenFactory';
export {IStataTokenV2_ABI} from './abis/IStataTokenV2';
export {IPayloadsControllerDataHelper_ABI} from './abis/IPayloadsControllerDataHelper';
export {IGovernanceDataHelper_ABI} from './abis/IGovernanceDataHelper';
export {IMetaDelegateHelper_ABI} from './abis/IMetaDelegateHelper';
Expand Down
19 changes: 19 additions & 0 deletions src/ts/abis/ICrossChainController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -694,6 +694,25 @@ export const ICrossChainController_ABI = [
],
stateMutability: 'view',
},
{
type: 'function',
name: 'maxRescue',
inputs: [
{
name: 'erc20Token',
type: 'address',
internalType: 'address',
},
],
outputs: [
{
name: '',
type: 'uint256',
internalType: 'uint256',
},
],
stateMutability: 'view',
},
{
type: 'function',
name: 'receiveCrossChainMessage',
Expand Down
6 changes: 3 additions & 3 deletions src/ts/abis/IERC20.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ export const IERC20_ABI = [
name: 'transfer',
inputs: [
{
name: 'to',
name: 'recipient',
type: 'address',
internalType: 'address',
},
Expand All @@ -109,12 +109,12 @@ export const IERC20_ABI = [
name: 'transferFrom',
inputs: [
{
name: 'from',
name: 'sender',
type: 'address',
internalType: 'address',
},
{
name: 'to',
name: 'recipient',
type: 'address',
internalType: 'address',
},
Expand Down
6 changes: 3 additions & 3 deletions src/ts/abis/IPoolConfigurator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const IPoolConfigurator_ABI = [
internalType: 'uint40',
},
],
stateMutability: 'nonpayable',
stateMutability: 'view',
},
{
type: 'function',
Expand Down Expand Up @@ -78,7 +78,7 @@ export const IPoolConfigurator_ABI = [
internalType: 'address',
},
],
stateMutability: 'nonpayable',
stateMutability: 'view',
},
{
type: 'function',
Expand All @@ -97,7 +97,7 @@ export const IPoolConfigurator_ABI = [
internalType: 'uint256',
},
],
stateMutability: 'nonpayable',
stateMutability: 'view',
},
{
type: 'function',
Expand Down
19 changes: 19 additions & 0 deletions src/ts/abis/IRescuable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,25 @@ export const IRescuable_ABI = [
outputs: [],
stateMutability: 'nonpayable',
},
{
type: 'function',
name: 'maxRescue',
inputs: [
{
name: 'erc20Token',
type: 'address',
internalType: 'address',
},
],
outputs: [
{
name: '',
type: 'uint256',
internalType: 'uint256',
},
],
stateMutability: 'view',
},
{
type: 'function',
name: 'whoCanRescue',
Expand Down
65 changes: 65 additions & 0 deletions src/ts/abis/IStataTokenFactory.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
// AUTOGENERATED - MANUALLY CHANGES WILL BE REVERTED BY THE GENERATOR
export const IStataTokenFactory_ABI = [
{
type: 'function',
name: 'createStataTokens',
inputs: [
{
name: 'underlyings',
type: 'address[]',
internalType: 'address[]',
},
],
outputs: [
{
name: '',
type: 'address[]',
internalType: 'address[]',
},
],
stateMutability: 'nonpayable',
},
{
type: 'function',
name: 'getStataToken',
inputs: [
{
name: 'underlying',
type: 'address',
internalType: 'address',
},
],
outputs: [
{
name: '',
type: 'address',
internalType: 'address',
},
],
stateMutability: 'view',
},
{
type: 'function',
name: 'getStataTokens',
inputs: [],
outputs: [
{
name: '',
type: 'address[]',
internalType: 'address[]',
},
],
stateMutability: 'view',
},
{
type: 'error',
name: 'NotListedUnderlying',
inputs: [
{
name: 'underlying',
type: 'address',
internalType: 'address',
},
],
},
] as const;
Loading
Loading