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

api/sessions: document bcrypt implementation curiosity #1408

Merged
merged 5 commits into from
Feb 19, 2025

Conversation

alxndrsn
Copy link
Contributor

@alxndrsn alxndrsn commented Feb 17, 2025

This behaviour was noted by @sadiqkhoja, and seemed at least worth documenting if not fixing.

Closes #1409

What has been done to verify that this works as intended?

Added a test.

Why is this the best possible solution? Were any other approaches considered?

An alternative to this test would be to check for NUL characters in supplied passwords and reject them before passing the values to bcrypt.

How does this change affect users? Describe intentional changes to behavior and behavior that could have accidentally been affected by code changes. In other words, what are the regression risks?

No effect.

Does this change require updates to the API documentation? If so, please update docs/api.yaml as part of this PR.

No.

Before submitting this PR, please make sure you have:

  • run make test and confirmed all checks still pass OR confirm CircleCI build passes
  • verified that any code from external sources are properly credited in comments or that everything is internally sourced

@alxndrsn alxndrsn marked this pull request as draft February 17, 2025 11:48
@alxndrsn alxndrsn requested a review from sadiqkhoja February 18, 2025 08:55
@alxndrsn alxndrsn marked this pull request as ready for review February 18, 2025 09:08
Copy link
Contributor

@sadiqkhoja sadiqkhoja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We discussed this in the meeting and concluded that just documenting the behaviour is sufficient.

@alxndrsn alxndrsn merged commit c56a5d7 into getodk:master Feb 19, 2025
6 checks passed
@alxndrsn alxndrsn deleted the bcrypt-nulls branch February 19, 2025 05:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bcrypt implementation details are leaked through various APIs
2 participants