Bitcoin Development Mailinglist
 help / color / mirror / Atom feed
* [bitcoindev] Convention for tagged hash tags in BIPs
@ 2026-09-22  9:07 'Fabian' via Bitcoin Development Mailing List
  0 siblings, 0 replies; only message in thread
From: 'Fabian' via Bitcoin Development Mailing List @ 2026-09-22  9:07 UTC (permalink / raw)
  To: Bitcoin Development Mailing List

[-- Attachment #1: Type: text/plain, Size: 2820 bytes --]

Hi all,

while reviewing BIP 459 (DahLIAS) theStack pointed out to me
that most recent cryptography BIPs put the BIP number into
their tagged hash tags but that some others use a
descriptive name instad. The same question came up on the
FROST signing BIP [1][2]. BIP 458 has used
"HalfAgg/randomizer" since long before it had a number and I
adopted the same style for BIP 459 ("FullAgg/...") when
writing the draft but I have now changed it to the BIP
number based on how the most recent cryptography BIPs have
handled it. But I have also received some offline feedback
that changing tags for this convention probably isn't good
enough reason to break the spec. This question would come
up for every new BIP that uses tagged hashes, because a spec
usually needs its tags defined before it is perceived ready
to receive a number. So I think it would be good to settle
on a convention if possible or at least document some
community opinions here, rather than to have a fresh debate
in each new BIP.

As far as I can tell there is no written rule and the
existing BIPs are inconsistent. BIP 324, 340, 352, 374 and
445 include the number. BIP 341 does not ("TapLeaf" etc.)
even though it was written by the same authors at the same
time as BIP 340 and BIP 327 does not either. One explanation
could be that authors who wrote the BIP before any
implementation existed used the number, while specs that
were implemented before or while the BIP was written kept
their original tag. That would seem to fit as an
explaination for most examples but it is a guess and doesn't
seem to fit 340 vs 341.

Arguments I could think of

...for including the number:
- The number is guaranteed to be unique within the BIPs
ecosystem.
- It makes the origin of a hash obvious when reading code or
test vectors.

...against including the number:
- The spec is broken at the time the number is assigned,
requiring extra work on all implementation sites that
already exist.
- Maybe tags don't need to be unique across BIPs and be
interpreted as more general domain separation.

I am curious to hear where people fall on this, and if
there should be some form of documentation of the
convention, where people think the right place for that
would be.
Fabian

[1] https://github.com/bitcoin/bips/pull/2210#discussion_r4010220690
[2] https://github.com/bitcoin/bips/pull/2070#discussion_r3253350748

-- 
You received this message because you are subscribed to the Google Groups "Bitcoin Development Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bitcoindev+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/dxapm4DOcrDL6_oCYSqBAdFP0fAQA9IHInRzzTuCeWVYD2Xd0ynPsTa8hYEcRFOYQPnvoQK15TtK6oAZBfa-4b5DbIuFemSFGVifxGTLOlc%3D%40protonmail.com.

[-- Attachment #2: Type: text/html, Size: 5112 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-09-22  9:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-22  9:07 [bitcoindev] Convention for tagged hash tags in BIPs 'Fabian' via Bitcoin Development Mailing List

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox