-
Notifications
You must be signed in to change notification settings - Fork 63
Description
Overview
This feature request proposes integrating GPG signature signing/verification capabilities from the gpg-wallet project with the Modular Account framework. This integration would allow users to sign and verify transactions using GPG keys, providing enhanced security and flexibility for account owners.
Background
Currently, Modular Account supports validation modules such as SingleSigner validation (EOAs) and WebAuthn validation (passkeys). However, there is no support for GPG keys, which are widely used in cryptographic applications and offer strong security properties.
The gpg-wallet repository has built a complete implementation of a GPG-based wallet that leverages a custom precompile at address 0x696 to verify GPG signatures efficiently. By integrating this capability into Modular Account, we can offer users additional authentication options and enhance security.
Detailed Proposal
-
Create a new GPG Validation Module:
- Develop a new validation module that can verify GPG signatures
- Utilize the precompile from gpg-wallet at address
0x696for efficient verification - Support the same signature verification patterns as used in gpg-wallet
-
Implement GPG Key Management:
- Design storage for GPG public keys and key IDs within the validation module
- Support key registration, rotation, and revocation
- Allow multiple GPG keys for a single account
-
Create a GPG Verifier Library:
- Abstract the GPG signature verification logic into a reusable library
- Support the same interface as used in gpg-wallet
- Ensure gas efficiency in verification operations
-
Account Factory Integration:
- Add deployment options to create a Modular Account with GPG validation pre-installed
- Support embedding of GPG key information during account creation
-
ERC-4337 Integration:
- Implement UserOp validation for GPG signatures
- Ensure bundlers can properly process GPG-signed operations
-
Documentation and Examples:
- Create comprehensive documentation for users wanting to use GPG with their Modular Account
- Provide examples of how to generate appropriate signatures from GPG keys
- Document the security benefits and trade-offs
Benefits
- Enhanced security through GPG's robust cryptographic infrastructure
- Support for hardware security keys that use GPG
- Ability to leverage existing GPG infrastructure for identity and key management
- Broader authentication options for account owners
- Compatibility with existing tooling in the GPG ecosystem
Technical Considerations
- The GPG precompile (at address
0x696) needs to be supported by the chain - Need to ensure proper handling of gas costs for GPG signature verification
- Key management must be secure and user-friendly
- Standard testing approaches may need to be extended to verify GPG signature validation
Implementation Path
- Create a new GPG verification library based on gpg-wallet's implementation
- Develop a GPG validation module that conforms to ERC-6900 standards
- Implement integration with the account factory
- Add comprehensive tests for all GPG validation scenarios
- Optimize for gas efficiency
- Document the new functionality thoroughly