Skip to content

Fix SCRAM password SASLprep #4201

Open
var4yn wants to merge 1 commit intolaunchbadge:mainfrom
var4yn:main
Open

Fix SCRAM password SASLprep #4201
var4yn wants to merge 1 commit intolaunchbadge:mainfrom
var4yn:main

Conversation

@var4yn
Copy link
Copy Markdown

@var4yn var4yn commented Mar 28, 2026

Does your PR solve an issue?

fixes #4196

Is this a breaking change?

No.

Ok(v) => v,
// The behavior is similar to what was observed when using SASLprep for username.
// TODO: Remove panic when we have proper support for configuration errors
Err(_) => panic!("Failed to saslprep password"),
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is copying a panic from earlier in this file which is really, really old code. Can we avoid adding a new one? This could just return Error::Configuration.

In fact, if you'd like to go ahead and replace the other panic!() as well, that would be a solid improvement.

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.

Postgres: SCRAM authentication does not SASLprep passwords before computing SaltedPassword

2 participants