Closed issackelly closed 1 year ago
Implementations MUST include appropriate pad characters at the end of encoded data unless the specification referring to this document explicitly states otherwise.
https://www.rfc-editor.org/rfc/rfc4648#section-3.2
Read together with that, it seems like the spec is clear. Padding is always required.
EDIT: lol - https://github.com/marshallpierce/rust-base64#i-want-canonical-base64-encodingdecoding
As change in the behavior was not intended, I consider this as regression.
Thank you! I had been meaning to get around to this but we have an upstream patch so it was not pressing.
In the upgrade from base64 from 0.13 to 0.21 the behavior was lost where both unpadded or correctly padded strings were accepted. I am using
dex
which is currently sending me unpadded strings. I have not checked if this behavior is allowed as per the spec or not.