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

[Backport jb-v7.12.x] fix: define all base64 characters #6841

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

sourcegraph-release-bot
Copy link
Collaborator

Discovered a bug related to serialization of @ mention prompts. With this PR I explicitly list all base64 characters, and properly handle the trailing equal signs.

Essentially we extend the regex [a-zA-Z0-9]+ to [A-Za-z0-9+/]+={0,2} following https://datatracker.ietf.org/doc/html/rfc4648#section-4.

Test plan

More unit tests

Backport deb3fa2 from #6837

Discovered a bug related to serialization of @ mention prompts. With
this PR I explicitly list all base64 characters, and properly handle the
trailing equal signs.

Essentially we extend the regex `[a-zA-Z0-9]+` to `[A-Za-z0-9+/]+={0,2}`
following https://datatracker.ietf.org/doc/html/rfc4648#section-4.

## Test plan

More unit tests

(cherry picked from commit deb3fa2)
@bahrmichael
Copy link
Contributor

bahrmichael commented Jan 28, 2025

Notifying @beyang @ErikaRS about this backport. It's a fix for missing characters in a regex and might not need a full approval. Assuming pre-approved for bugfixes.

@thenamankumar thenamankumar merged commit faf32cf into jb-v7.12.x Jan 28, 2025
22 of 23 checks passed
@thenamankumar thenamankumar deleted the backport-6837-to-jb-v7.12.x branch January 28, 2025 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants