Skip to content
This repository was archived by the owner on Feb 24, 2025. It is now read-only.

Feature Request: Public Key Derivation Function for BLS12381G2 #196

Description

@Dtitkaio

Hi MATTR team! 👋

First, thank you for maintaining this fantastic library. The BBS+ signature implementation has been incredibly valuable for our SSI projects.

Context:
We're building a key management system using your library, and we've found ourselves in an interesting situation. While generateBls12381G2KeyPair() works great for new keys, we're looking for a way to handle key import scenarios where we need to derive public keys from existing private keys.

Current Workflow:

// This works great for new keys!
const keyPair = await generateBls12381G2KeyPair();

Desired Enhancement:
Would it be possible to add a utility function for deriving public keys from private keys? Something like:

// Potential API
const publicKey = await derivePublicKeyFromPrivate(existingPrivateKey);

Use Cases:

  • Key recovery scenarios where only the private key is available
  • Integration with existing key management systems
  • Supporting key import/export functionality in SSI wallets

We'd love to contribute to this effort if you're open to it! Let us know if you'd like us to:

  • Draft a proposal for the API design
  • Help with implementation
  • Write tests
  • Provide additional use cases or requirements

Thanks for considering this request! Let us know if you need any clarification or additional information.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions