Kinto Wallet

Deployment Address
Interface: IKintoWallet.sol

Basics

  • Executes transactions according to the Account Abstraction standard.
  • Validates user operations signatures.
  • Manages signers and signers policy.
  • The emergency recovery process can be triggered through a unique signer.
  • Approves applications and tokens allowances explicitly.
  • Manages the funder whitelist

State functions

initialize(address anOwner, address _recoverer) external virtual initializer onlyFactory
execute(address dest, uint256 value, bytes calldata func) external override
executeBatch(address[] calldata dest, uint256[] calldata values, bytes[] calldata func) external override
setSignerPolicy(uint8 policy) public override onlySelf
resetSigners(address[] calldata newSigners, uint8 policy) external override onlySelf
setFunderWhitelist(address[] calldata newWhitelist, bool[] calldata flags) external override onlySelf
approveTokens(address app, address[] calldata tokens, uint256[] calldata amount) external override onlySelf
revokeTokens(address app, address[] calldata tokens) external override onlySelf
setAppKey(address app, address signer) external override onlySelf
setAppWhitelist(address[] calldata apps, bool[] calldata flags) external override onlySelf
startRecovery() external override onlyFactory
finishRecovery(address[] calldata newSigners) external override onlyFactory
changeRecoverer(address newRecoverer) external override onlyFactory()
cancelRecovery() public override onlySelf

1. initialize (Factory only)
Initializes the KintoWallet with an owner and a recoverer.
function initialize(address anOwner, address _recoverer) external virtual initializer onlyFactory;
Parameter
Type
Explanation
anOwner
address
The initial owner of the KintoWallet.
_recoverer
address
The address designated as the recoverer for the wallet.
2. execute (EntryPoint only)
Executes a transaction.
function execute(address dest, uint256 value, bytes calldata func) external override;
Parameter
Type
Explanation
dest
address
The destination address.
value
uint256
The value to be transferred.
func
bytes
The calldata of the function.
3. executeBatch (EntryPoint only)
Executes a batch of transactions.
function executeBatch(address[] calldata dest, uint256[] calldata values, bytes[] calldata func) external override;
Parameter
Type
Explanation
dest
address[]
Array of destination addresses.
values
uint256[]
Array of values to be transferred.
func
bytes[]
Array of calldata for each function.
4. setSignerPolicy (only callable by Wallet itself)
Sets the signer policy of the wallet.
function setSignerPolicy(uint8 policy) public override onlySelf;
Parameter
Type
Explanation
policy
uint8
The new signer policy.
5. resetSigners (only callable by Wallet itself)
Resets the signers of the wallet.
function resetSigners(address[] calldata newSigners, uint8 policy) external override onlySelf;
Parameter
Type
Explanation
newSigners
address[]
Array of new signers.
policy
uint8
The signer policy to apply.
6. setFunderWhitelist (only callable by Wallet itself)
Sets the funder whitelist.
function setFunderWhitelist(address[] calldata newWhitelist, bool[] calldata flags) external override onlySelf;
Parameter
Type
Explanation
newWhitelist
address[]
Array of addresses to whitelist.
flags
bool[]
Flags to allow or disallow funders.
7. approveTokens (only callable by Wallet itself)
Approves tokens for a specific app.
function approveTokens(address app, address[] calldata tokens, uint256[] calldata amount) external override onlySelf;
Parameter
Type
Explanation
app
address
Address of the app.
tokens
address[]
Array of token addresses.
amount
uint256[]
Array of amounts for each token.
8. revokeTokens (only callable by Wallet itself)
Revokes token approvals for a specific app.
function revokeTokens(address app, address[] calldata tokens) external override onlySelf;
Parameter
Type
Explanation
app
address
Address of the app.
tokens
address[]
Array of token addresses.
9. setAppKey (only callable by Wallet itself)
Sets the app key for a specific app.
function setAppKey(address app, address signer) external override onlySelf;
Parameter
Type
Explanation
app
address
Address of the app.
signer
address
Address of the app signer.
10. setAppWhitelist (only callable by Wallet itself)
Sets the app whitelist.
function setAppWhitelist(address[] calldata apps, bool[] calldata flags) external override onlySelf;
Parameter
Type
Explanation
apps
address[]
Array of app addresses.
flags
bool[]
Flags to allow or disallow apps.
11. startRecovery (only callable by Wallet Factory)
Starts the recovery process.
function startRecovery() external override onlyFactory;
No parameters.
12. finishRecovery (only callable by Wallet Factory)
Finishes the recovery process and resets the signers.
function finishRecovery(address[] calldata newSigners) external override onlyFactory;
Parameter
Type
Explanation
newSigners
address[]
Array of new signers.
13. changeRecoverer (only callable by Wallet Factory)
Changes the recoverer.
function changeRecoverer(address newRecoverer) external override onlyFactory();
Parameter
Type
Explanation
newRecoverer
address
Address of the new recoverer.
14. cancelRecovery (only callable by Wallet Factory)
Cancels the recovery process.
function cancelRecovery() public override onlySelf;

View Functions

isFunderWhitelisted(address funder) external view override returns (bool)
entryPoint() public view virtual override returns (IEntryPoint)
getNonce() public view virtual override returns (uint)
getOwnersCount() external view override returns (uint)
1. isFunderWhitelisted
Checks if a funder is whitelisted.
function isFunderWhitelisted(address funder) external view override returns (bool);
Parameter
Type
Explanation
funder
address
The funder address to check.
2. entryPoint
Returns the entry point of the wallet.
function entryPoint() public view virtual override returns (IEntryPoint);
No parameters.
3. getNonce
Gets the current nonce of the wallet.
function getNonce() public view virtual override returns (uint);
No parameters.
4. getOwnersCount
Returns the count of owners of the wallet.
function getOwnersCount() external view override returns (uint);
No parameters.