ssbc / bendy-butt-spec

6 stars 0 forks source link

Clarify that integers are bencode integers #21

Closed staltz closed 2 years ago

staltz commented 2 years ago

See this issue: https://github.com/ssb-ngi-pointer/bendy-butt-spec/issues/20

"Bencode integers" are unlimited, so in binary we have no limits, but when decoded to the runtime/language (e.g. JS) we have to make a sensible choice. Popular BitTorrent implementations seem to use signed 64 bit integers with bencode, which is larger than the range of unsigned 32 bit integers, so we should be very well future proof.