Simple extendable smart account implementations (Smarter Accounts
or NANI
). v1.2.3
Built with the Foundry testing suite and Solady solidity optimizations, this codebase demonstrates contemporary and efficient account abstractions through a representative implementation (Account
, v1.2.3
) and factory that deploys related ERC1967
minimal proxies with UUPS
upgradeability. As such, Accounts
users can upgrade into any account implementation at any time from their NANI wallet, such as Kernel
or Coinbase, while the latest version of NANI
Accounts
will be maintained and deployed here.
All Accounts
support the following standards: ERC173
, EIP712
, ERC1271
, ERC1822
, ERC1967
, ERC2098
, ERC4337
, ERC5267
, ERC6492
, ERC7582
Currently, Accounts
is the most optimized smart account implementation available to the public with a companion user interface on nani.ooo
. Incentives are designed for participation in testing and development. Governance of the Accounts
implementation and interface models is also introduced in v1.2.3
.
Run: curl -L https://foundry.paradigm.xyz | bash && source ~/.bashrc && foundryup
Build the foundry project with forge build
. Run contract tests with forge test
. Measure gas fees with forge snapshot
. Format code with forge fmt
.
v1.2.3
Chain | Factory | Implementation | Commit |
---|---|---|---|
Ethereum, Arbitrum / Nova, Optimism, Base, Zora, Blast, Gnosis, Polygon / zkEVM, BNB, Avalanche & testnets | 0x0000000000009f1E546FC4A8F68eB98031846cb8 | 0x0000000000002259DC557B2D35A3Bbbf3A70eB75 | ffe035982fc03887895bafde845ad17490063cdc |
Account URL (Unruggable): 0x0000000000004Bf084D1821a0d9D271A84E5c8E4
Set hard 'rug' limits for ETH txs
Utilizes ERC7582
minimal modular account interface.
JointValidator: 0x000000000000D3D2b2980A7BC509018E4d88e947
Add joint owners to your smart account with full concurrent rights
RecoveryValidator: 0x000000000000a78fB292191473E51Dd34700c43D
Add backups to your smart account (can set time delay and m/n scheme)
PaymentValidator: 0x000000000000dF3C51a888aB783C3E6355e33fe0
Add payment plans and delegate token transfer permissions (e.g., invoice agents)
PermitValidator: 0x000000000000E8C738709eE8778063711B073680
Add arbitrary permissions within the Permit structure (e.g., voting and swapping rights)
RemoteValidator: 0x0000000000159aAFCA7067005E28665a28B5B4cf
Add simple scheduled transactions sequence (e.g., DCA) or other 'remote' agent operations
token-weighted ownership (simulates multisig m/n and DAO voting)
token-bound ownership (NFTs are owners, i.e., "my Milady is my key")
hard checks for smart accounts (i.e., "can't spend more than 0.1 ETH")
NEETH (ARB): 0x00000000000009B4AB3f1bC2b029bd7513Fbd8ED
NEETH (BASE): 0x00000000000077E2072D61672eb6EC18a136c80A
magic paymaster: stake ETH and use DeFi yield to sponsor transactions
lib
├─ forge-std — https://github.com/foundry-rs/forge-std
├─ solady — https://github.com/vectorized/solady
src
├─ Account — Account Contract
├─ Accounts - Factory Contract
test
└─ Account.t - Test Contract
These smart contracts and testing suite are being provided as is. No guarantee, representation or warranty is being made, express or implied, as to the safety or correctness of anything provided herein or through related user interfaces. This repository and related code have not been audited and as such there can be no assurance anything will work as intended, and users may experience delays, failures, errors, omissions, loss of transmitted information or loss of funds. The creators are not liable for any of the foregoing. Users should proceed with caution and use at their own risk.
See LICENSE for more details.