-
Notifications
You must be signed in to change notification settings - Fork 9
Specify MinSig variant and clarify non-aggregation of eligibility proofs in specification.md #648
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
Open
hjeljeli32
wants to merge
6
commits into
curiecrypt/leios-design-votes-certs
Choose a base branch
from
hjeljeli32/update-specification-md
base: curiecrypt/leios-design-votes-certs
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
b5d84b7
Leios design: document choice of BLS minSIG variant
hjeljeli32 16be43d
Update docs/leios-design/README.md
hjeljeli32 e28a5d3
Update docs/leios-design/README.md
hjeljeli32 6ee7170
Clarify the impact of PoP size on bandwidth and and storage
hjeljeli32 2bf9842
Leios design: quantify MinPK vs MinSig trade-off
hjeljeli32 1d3ea49
Specification.md: clarify choice of MinSig variant for BLS
hjeljeli32 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -8,6 +8,8 @@ author: | |||||
| - Thomas Vellekoop <[email protected]> | ||||||
| - Michael Karg <[email protected]> | ||||||
| - Martin Kourim <[email protected]> | ||||||
| - Gamze Orhon Kılıç <[email protected]> | ||||||
| - Hamza Jeljeli <[email protected]> | ||||||
| --- | ||||||
|
|
||||||
| # Introduction | ||||||
|
|
@@ -702,6 +704,65 @@ The BLS voting mechanism relies on a pairing-based signature scheme defined over | |||||
| This approach is advantageous because it enables the aggregation of public keys and signatures, allowing large groups of participants to collectively signal approval through a single compact artifact. | ||||||
| Beyond Leios, the BLS mechanism is also relevant to other Cardano subsystems; Mithril already employs BLS-based aggregation, and Peras is expected to adopt a similar approach in future implementations. | ||||||
|
|
||||||
| #### Choice of BLS Variant | ||||||
|
|
||||||
| BLS12-381 signatures can be instantiated in two variants that differ only in which group is used for public keys and which is used for signatures. Both variants are equivalent in security and share the same API surface; they differ only in the size of the encoded artifacts: | ||||||
| - **MinPk variant**: public keys are 48 bytes, signatures are 96 bytes, and a proof of possesion is 2 times 96 bytes. | ||||||
| - **MinSig variant**: signatures are 48 bytes, public keys are 96 bytes, and a proof of possesion is 2 times 48 bytes. | ||||||
| This creates a straightforward trade-off: either public keys are smaller (MinPk) or signatures are smaller (MinSig). | ||||||
|
|
||||||
| For Leios, this choice affects the size of voting certificates, which in turn impacts bandwidth, storage, and block propagation. Note that proofs of possession are only used at key registration time, so their size has negligible impact on steady-state bandwidth, storage, or verification costs. They therefore do not weigh into the choice between the two variants. | ||||||
|
|
||||||
| The certificate scheme we use follows the one defined in CIP-0164 together with the more detailed description in | ||||||
| [Specification.md](https://github.com/input-output-hk/ouroboros-leios/blob/main/crypto-benchmarks.rs/Specification.md) (section *“BLS certificate scheme”*). At a high level, a certificate records: | ||||||
|
|
||||||
| - the **election identifier** (8 bytes) and **EB hash** (32 bytes), | ||||||
| - a **bitset of persistent voters**, of size \(m / 8\) bytes, | ||||||
| - for each **non-persistent voter**: | ||||||
| - the Pool ID (28 bytes), | ||||||
| - its **eligibility proof**, an individual BLS signature of size S_sig, | ||||||
| - one **aggregate vote signature** on the EB (a single BLS signature of size S_sig). | ||||||
|
|
||||||
| A key point is that **eligibility proofs remain non-aggregated**: the block producer must be able to verify each proof individually against the Fait-Accompli sortition condition. Only the vote signatures on the EB are aggregated. | ||||||
|
|
||||||
| Under these assumptions, the total certificate size (ignoring small CBOR overhead) is | ||||||
|
|
||||||
| \[ | ||||||
| certificate_bytes = 40 + 2 * S_sig + m / 8 + (28 + S_sig) * (n - m). | ||||||
| \] | ||||||
|
|
||||||
| Current sortition simulations tune the number of non-persistent seats to roughly 100 across the committee sizes we care about. Concretely, we assume: | ||||||
| - for n = 500, we have m ≈ 400 persistent voters, | ||||||
| - for n = 1000, we have m ≈ 900 persistent voters, | ||||||
|
|
||||||
| so in both cases (n - m) ≈ 100 non-persistent voters, and the term (28 + S_sig) * (n-m) dominates. | ||||||
|
|
||||||
| **Quantitative comparison** | ||||||
|
|
||||||
| For a 1000-seat committee with m ≈ 900 persistent voters: | ||||||
|
|
||||||
| - **MinSig**: | ||||||
|
|
||||||
| \[ certificate_bytes = 40 + 2 * 48 + 113 + (28 + 48) * 100 = 136 + 113 + 7600 = 7849 bytes. | ||||||
| \] | ||||||
|
|
||||||
| - **MinPk**: | ||||||
|
|
||||||
| \[ certificate_bytes = 40 + 2 * 96 + 113 + (28 + 96) * 100 = 232 + 113 + 12400 = 12745 bytes. | ||||||
| \] | ||||||
|
|
||||||
| So, for n = 1000 and \(n - m ≈ 100\), MinPk certificates are about 4.9 kB larger, which is roughly a **60% increase** over MinSig. | ||||||
|
|
||||||
| We also evaluated the 500-seat case. The percentage increase from MinSig to MinPk is essentially the same (~60%). | ||||||
|
|
||||||
| **Interpretation for Leios** | ||||||
|
|
||||||
| - With MinSig, certificates stay comfortably below **8 kB** and keeps certificate propagation and storage lightweight. | ||||||
| - With MinPk, certificates grow to around **12.7 kB**, still within Praos limits but significantly heavier for bandwidth, storage, and diffusion—especially given the number of certificates the system will handle over time. | ||||||
| - Since Leios produces far more **signatures** (votes and eligibility proofs) than public keys, the overall cost is driven by signature size rather than key size. | ||||||
|
|
||||||
| In summary, the Leios cryptography design therefore **fixes MinSig as the BLS12-381 variant**. | ||||||
|
|
||||||
| ### Implementation Plan | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
It's not really a plan but how the concrete functionality is to be implemented in |
||||||
|
|
||||||
| To implement the linear Leios design, efficient BLS signature functionality is essential for achieving fast and compact certificate generation. | ||||||
|
|
||||||
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.
Uh oh!
There was an error while loading. Please reload this page.