Conversation
3 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
Adds BLS12-381 (MinSig) key support to cardano-api so downstream tooling (e.g., cardano-cli) can generate, serialise, and hash BLS keys.
Changes:
- Introduces a new internal
BlsKeytype withKey, Bech32, raw-bytes, CBOR, and text-envelope instances. - Extends
SomeAddressVerificationKeyto include BLS verification keys in rendering/mapping/deserialisation. - Exposes
BlsKey(andAsBlsKey) viaCardano.Api.Keyand wires the new module into the Cabal library.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| cardano-api/src/Cardano/Api/Key/Internal/SomeAddressVerificationKey.hs | Adds a BLS constructor and includes it in Bech32 rendering/mapping/deserialisation. |
| cardano-api/src/Cardano/Api/Key/Internal/Leios.hs | New module defining BlsKey and associated instances for serialisation and hashing. |
| cardano-api/src/Cardano/Api/Key.hs | Re-exports BlsKey and AsBlsKey in the public API. |
| cardano-api/cardano-api.cabal | Exposes the new Cardano.Api.Key.Internal.Leios module. |
Jimbo4350
approved these changes
Mar 23, 2026
Contributor
Jimbo4350
left a comment
There was a problem hiding this comment.
Can you add some haddocks describing what this key is for?
1d8c253 to
7d1acd8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog
Context
This works towards addressing the first part of: input-output-hk/ouroboros-leios#776
It adds a new kind of key (BLS), in order to be able to support key generation and hashing for this kind of key in
cardano-cli. See PR: IntersectMBO/cardano-cli#1355How to trust this PR
This follows the pattern for other keys, the only major decision is the usage of
BLS12381MinSigDSIGNcurve, instead of the other one. Also, you can test this code by using the CLI PR that is based in this PR: IntersectMBO/cardano-cli#1355Checklist