Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Generalize Signing Methods in the catalyst_cardano_serialization package. #855

Open
ilap opened this issue Sep 20, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@ilap
Copy link
Contributor

ilap commented Sep 20, 2024

Feature Title

Generalize Signing Methods and Support Custom Signing in catalyst_cardano_serialization

Feature Description

The current implementation of the catalyst_cardano_serialization package includes a hard-coded signing method that limits the flexibility for developers to use third-party signing implementations.
This constraint can be overcome by introducing abstract interfaces for signing-related functionality, such as public, private keys, and signature-s.

The proposal is to implement design patterns like the Adapter pattern to decouple the signing process from the package and allow custom implementations. This will improve the extensibility of the package by allowing developers to plug in their own signing logic without modifying the core library.

Proposed Enhancements:

Generalize Signing Methods:

Introduce similar interfaces for handling signing processes. For example:

abstract interface class Signature {
}

abstract interface class Signer {
  Signature sign(List<int> message);
}

abstract interface class Verifier {
  bool verify(Signature signature);
}

This will provide developers with the flexibility to implement custom signing methods for different use cases.

Maintain Compatibility with CBOR:

Ensure the generalized signing methods remain compatible with the existing CBOR encoding/decoding logic by continuing to use CborEncodable, which has been introduced in #696.

Use Case

The proposed changes will make the catalyst_cardano_serialization package more flexible and adaptable to different signing implementations, enabling developers, 3rd party wallet-integrators, etc. to use custom signing mechanisms alongside the current transaction encoding framework.

Is this a modification to an existing feature?

Yes

@ilap ilap added the enhancement New feature or request label Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant