Content
@
0 reply
0 recast
0 reaction
Matt Hamilton
@ham
Been diving into ERC-4337 & smart accounts lately. An interesting use case with positive UX impact -- Session management. An example using an MMORPG: 🧵
1 reply
0 recast
1 reaction
Matt Hamilton
@ham
Smart Contract Account Setup: Players create a self-custodied smart contract account at registration. Key parts are split using Multi-Party Computation (MPC) for enhanced security - one part on the player’s device, another secured remotely.
1 reply
0 recast
0 reaction
Matt Hamilton
@ham
Session Initialization: At login, players provide a signature for a session-specific authorization. This is recorded onchain as a session ID by updating a state variable in the smart contract account. The session ID is unique per session and is secured against unauthorized updates.
1 reply
0 recast
0 reaction
Matt Hamilton
@ham
Transaction Bundling: Player actions are collected into a UserOperation bundle, reducing the need for individual transaction signatures and streamlining gameplay.
1 reply
0 recast
0 reaction
Matt Hamilton
@ham
Session-Based Authorization: Actions are authenticated against the session ID via the validateUserOp function to ensure they are part of the current, active session.
1 reply
0 recast
0 reaction
Matt Hamilton
@ham
Transaction Execution: Actions are executed through the EntryPoint contract, which processes the UserOperation bundle on the blockchain.
1 reply
0 recast
0 reaction