bitcoincashorg / spec

Technical specifications
112 stars 64 forks source link

an attempt to clarify the spec. #48

Closed avl42 closed 6 years ago

avl42 commented 6 years ago

I'm not a native English speaker, myself, so I can't vouch for the language, but I hope that the necessary bits for understanding the algorithm are now there...

avl42 commented 6 years ago

This is supposed to address Issue #47 .

deadalnix commented 6 years ago

Ether way, that's a much better description than the original write up so I'm merging.

RichyT commented 6 years ago

Good work, man. My major trip-up was not realizing that the output of the checksum with the zero padding could be used as the checksum to make it return 0. Your changes make that much more obvious.

RichyT commented 6 years ago

One issue I still see. You talk of padding the "payload" to a multiple of 5 bits then adding the template for the checksum yet earlier the checksum is defined as part of the payload. I think this use of the word "payload" needs to be normalized to avoid confusion.

I understand it enough for my needs right now so I'll bow out of any discussion but I might be back when I've worked with it a bit.

avl42 commented 6 years ago

You're right. "payload" has a kind of fluctuating meaning. for each step it's usually the most interesting ingredient.

Originally, that is just the hash, then it is the version byte plus the hash.

On decoding, it is originally the base32 part including the checksum but without prefix and colon. if stripping checksum, hexifying and stripping the version byte were described, too, then payload would shift meaning also along that path.

If you don't want to write the pr on github yourself, write the suggested changes here and either i will pr them, or some project collaborator may include it directly.

ps: in case you do write a pr, please also fix the missing extra line breaks of my last pr...

Am 17.01.2018 04:25 schrieb "RichyT" notifications@github.com:

One issue I still see. You talk of padding the "payload" to a multiple of 5 bits then adding the template for the checksum yet earlier the checksum is defined as part of the payload. I think this use of the word "payload" needs to be normalized to avoid confusion.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Bitcoin-UAHF/spec/pull/48#issuecomment-358185108, or mute the thread https://github.com/notifications/unsubscribe-auth/AFAwsoZg6sDElZnDMMuNW2nRmGxHN2Hlks5tLWgRgaJpZM4RgoWs .