Skip to content
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

binary content, non-paddability #495

Closed
bsdphk opened this issue Feb 17, 2018 · 4 comments
Closed

binary content, non-paddability #495

bsdphk opened this issue Feb 17, 2018 · 4 comments

Comments

@bsdphk
Copy link
Contributor

bsdphk commented Feb 17, 2018

I'm not sure I understand the ban on '=' in binary content, how can that confuse dictionaries, when the binary content doesn't end until the final '*' ?

@mnot
Copy link
Member

mnot commented Feb 18, 2018

It's from when there wasn't a final delimiter. I think you're right; we should accept =. I think we should also accept without.

mnot added a commit that referenced this issue Feb 19, 2018
@bsdphk
Copy link
Contributor Author

bsdphk commented Feb 19, 2018

I think we should just rely on whatever the B64 rfc says, without inventing anything new. (Postel Was Wrong and all that.)

@mnot
Copy link
Member

mnot commented Feb 19, 2018

It says:

Implementations MUST include appropriate pad characters at the end of encoded data unless the specification referring to this document explicitly states otherwise.

I think we want to make it easy to conform to whatever we require with shipping implementations of base64. Spot-checking Python and Node, it seems like Python enforces the requirement, whereas Node does not.

Given that, it seems like the sensible thing to do is to require the padding to be produced with a MUST, but only require parsers to reject content without padding as a SHOULD.

See also #473.

mnot added a commit that referenced this issue Feb 22, 2018
@bsdphk
Copy link
Contributor Author

bsdphk commented Feb 22, 2018

WFM

@mnot mnot closed this as completed Feb 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants