Skip to content

Make Verifier trait instance-based #1511

@vaporif

Description

@vaporif

Description

Convert the Verifier trait from static methods to instance methods to enable stateful signature verification.

Use case: In Solana's IBC v2 implementation, transaction verification must be offloaded outside the main transaction context. An instance-based verifier allows referencing an accessor that checks verification results asynchronously.

Definition of "done"

Change:
// Before
fn verify(pubkey: PublicKey, msg: &[u8], signature: &Signature) -> Result<(), Error>;

// After

fn verify(&self, pubkey: PublicKey, msg: &[u8], signature: &Signature) -> Result<(), Error>;

Implementation is already complete and tested in our Solana IBC implementation. Awaiting approval to submit PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions