Skip to content

L1 Vault

Compare
Choose a tag to compare
@elenadimitrova elenadimitrova released this 23 Apr 14:40
· 20 commits to master since this release

Wallet redesign

This is major redesign of the wallet aiming to significantly reduce the gas cost of operating the wallet by simplifying the scope and the code of the smart-contracts. #187

  • The security features designed to protect the wallet from a loss of the owner key remain unchanged (guardians, lock, recovery and transferOwnership).
  • The security features designed to protect the wallet from a theft of the owner key are strengthen yet simplified by:
    • pushing the daily limit to 0 which enables us to remove all the logic associated to it
    • generalising whitelisting by adding, on top of trusted contacts, the ability to opt-in/opt-out from registries of authorised dapps, and introducing a first default registry managed by Argent (to include Compound, Maker, Paraswap, and all the dapps currently integrated in the app).
  • Merging transferToken, approve, callContracts, and approveAndCall into a generic multiCall method that can take as input an array of transactions (to, value data).
  • Removing all the specific modules (ApprovedTransfer, TransferManager, CompoundManager , GuardianManager etc) as their logic can now be implemented through the new multiCall method.

As a result of this reduced scope the entire wallet functionality is implemented in a single ArgentModule which further reduces the cost of creation, operation and upgrades.

Static calls #195
ERC 1271, ERC 721 and ERC 165 supported by default on wallets
Added ERC 1155 support included by default for new wallets, and opt-in via the enableERC1155TokenReceiver() method for old wallets.

Authorisation sessions #196
Extending the concept of guardian approved operations by introducing sessions - additional signing keys that, once approved by a majority of guardians, can be used to bypass all the security checks during a pre-defined validity period.

When completing a recovery procedure any sessions are cleared. #206

Updated Relayer refunds #193
Updates the refund mechanism in the RelayerManager module.

Infrastructure updates

Enable ENS subname registration for the wallet owner. #184

Allow anyone to create wallets #181
removes the restriction on who can create new wallets. Any account possessing a valid signature from a WalletFactory manager can create a wallet. Also constructs the CREATE2 salt in a way that is compatible with zkSync.

Enable refund for wallet creation #191
Updates the WalletFactory to make the creation of wallet payable to the user. The amount and the token used must be approved by the wallet owner through a signature which is then provided to the createCounterfactualWallet method.

DappRegistry #199
uses bit vectors for more gas-efficient reads of authorisations and writes of enabled registries
implements timelocks for updating dapp filters and changing timelock

Filters

  • ParaswapV2, AaveV2, Balancer, Yearn, DSR #208
  • Compound #209
  • Lido #213
  • UniswapV2 #214
  • Paraswap V4 #221
  • Aave V1 #224
  • Additional filter checks for UniV1/V2 & ParaswapPool trades via Paraswap #230
  • Paraswap sub-filters for simpleSwap #236

MultiCallHelper #215
used by clients to determine in 1 call if and why a sequence of transactions will be authorised

Removed price logic from TokenPriceRegistry and renamed it TokenRegistry #227

Non-functional updates

Upgrade contracts to Solidity 0.8 #229
Upgrades all infrastructure, wallet and modules contracts to the latest solidity 0.8.3

Refactor revert error messages to shorten them under 32 characters long. #202

** Integration testing against a mainnet fork**

Make use of immutable properties where possible #223

Remove legacy code #232

Change optimisation runs to 300 for modules (set to 400 in #218 then dropped to 300 in #229)

When wallet is locked no refunds are issued

Change the value of the ETH-TOKEN constant from 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE to address(0) to save gas. #187

Production contracts

0xAb00eA153c43575184ff11Dd5e713c96bE005573 BaseWallet
0x536384FCd25b576265B6775F383D5ac408FF9dB7 WalletFactory
0x3d31D91003f9327623CaEc2e326B6BC681Bc3167 DappRegistry
0x8e4C969571a9C7aE8b5342874Ab532Dd7EB697bF MultiCallHelper
0xD270702a8344C4801Afbd0951cf17A2798700046 TokenRegistry
0x9D58779365B067D5D3fCc6e92d237aCd06F1e6a1 ArgentModule
0xF32FDDEF964b98b1d2d2b1C071ac60ED55d4D217 ArgentENSManager