Parsing the session key: Web3 version of Secret-Free Payment

avatar
Maxlion
2 years ago
This article is approximately 590 words,and reading the entire article takes about 1 minutes
It will greatly narrow the sensory gap between Web3 and Web2 products.

Wallet authorization has always been a necessary process for interacting with DApps, but when we interact with DeFi and GameFi, we often need to authorize multiple times in a short period of time, which greatly affects the user experience. The Session Keys (Session Keys) technology that Odaily has recently paid attention to,secondary title

Parsing the session key: Web3 version of Secret-Free Payment

How do session keys work?

simply speaking,The session key allows the user to sign a token to approve a specific transaction in advance before interacting with the application. The user can customize the frequency, maximum gas price, daily limit and other parameters. When the user signs the token and then interacts with the application, it complies with The transaction with the previous parameter conditions will be automatically executed in the background and gas will be paid.

secondary title

About address, smart contract account, account abstraction

There are currently two addresses on Ethereum: the first address is the usual wallet address, also known as externally owned account (EOA), which has the functions of sending and receiving tokens, paying gas, and executing transactions; the other is the smart contract address , various dapps deployed on Ethereum run in the form of smart contracts.

Parsing the session key: Web3 version of Secret-Free Payment

However, there are many problems in such address design. Many Ethereum developers believe that the design of EOA address hinders the development of wallets in terms of multi-signature, privacy protection, gas optimization, etc., and is not conducive to the programmable transaction. Therefore, V God, Ansgar Dietrichs, Matt Garnett, Will Villanueva, Sam Wilson and others proposed and completed the Ethereum Improvement ProposalEIP-2938, and put forward the concept of user abstraction.

Regarding the account abstraction, simply speaking, it is to allow the smart contract address to pay gas and execute transactions, so that it has all the functions of the wallet address.The smart contract address based on account abstraction is the smart contract account, and the concept of smart contract wallet is derived from it (like a personal Metamask account and Metamask, the wallet software).

The session key is a sub-technology of smart contract wallet based on account abstraction.

As mentioned earlier, wallets that support session keys support user-defined parameters for password-free payment, but the options for these parameters depend entirely on the wallet developer. And the session key does not support all DApps. The supported DApp depends on whether the smart contract wallet you use allows calling the contract of the Dapp. This process is centralized.

in conclusion,The session key is the secret-free payment of Web3, allowing users to authorize the DApp only once and then sign subsequent transactions and pay gas by default in the backgroundExample

Example

MatchBoxDAO, the chain game incubator on StarkNetHow to Make On-Chain Gaming Competitive: ‘Session Keys’ [Part 1] presents some use cases for session keys, including:

  • User-friendly and uninterrupted gameplay;

  • The ability to set up multiple DeFi positions;

  • Confirmation when filling out forms with many entries;

  • Unmanaged and self-directed IRAs;

  • Re-manage assets in wallet/inventory...

Parsing the session key: Web3 version of Secret-Free Payment

by

byLenster For example, all interactions on the on-chain social media Lenster developed based on the social protocol Lens Protocol require authorization and Matic payment, and every comment and forwarding requires wallet authorization, which greatly affects the user experience.

Parsing the session key: Web3 version of Secret-Free Payment

reference link

reference link

1.   Argent Xs tweet about session keys

2. 《How to Make On-Chain Gaming Competitive: ‘Session Keys’ [Part 1]》 ——MatchBoxDAO 

3. 《From Sign-In with Ethereum to Session Keys》——Wayne Chang

4. 《An overview of Account Abstraction in Ethereum blockchain》——Yash Kamal Chaturvedi

5.   EIP-86:Abstraction of transaction origin and signature 

6.   EIP-2938:Account Abstraction 

7.   EIP-4337:Account Abstraction via Entry Point Contract specification 

Related Reading

Actively reject poisoning attacks - the opportunity for contract wallets to appear

Original article, author:Maxlion。Reprint/Content Collaboration/For Reporting, Please Contact report@odaily.email;Illegal reprinting must be punished by law.

ODAILY reminds readers to establish correct monetary and investment concepts, rationally view blockchain, and effectively improve risk awareness; We can actively report and report any illegal or criminal clues discovered to relevant departments.

Recommended Reading
Editor’s Picks