postgres-protocol: raise SCRAM iteration limit to two million - #35
Merged
bosconi merged 4 commits intoSep 23, 2026
Merged
Conversation
jasonhernandez
approved these changes
Sep 23, 2026
bosconi
added a commit
to MaterializeInc/materialize
that referenced
this pull request
Sep 24, 2026
### Motivation Address [GHSA-5x78-73v4-xg6w](GHSA-5x78-73v4-xg6w), which allows a malicious PostgreSQL server to exhaust client CPU by supplying an unbounded SCRAM iteration count during authentication. ### Description Raise the workspace minimum for `postgres-protocol` from 0.6.9 to 0.6.12 and update the locked Materialize rust-postgres fork revision. The fork update imports the upstream protocol release, including the 2,000,000-iteration cap, while retaining the replication protocol extensions. Other fork crate versions remain unchanged. Unrelated dependency versions and resolution changes are excluded. Uses merged [rust-postgres#35](MaterializeInc/rust-postgres#35) at `fcca71c8`, with a 2,000,000-iteration SCRAM cap. ### Verification The dependency update includes upstream regression coverage for excessive SCRAM iterations, normal SCRAM authentication, and invalid hstore lengths. The fork's replication extension is unchanged from its previous implementation. ### Release notes * Prevent malicious PostgreSQL servers from causing excessive CPU consumption during SCRAM authentication by rejecting iteration counts above 2,000,000.
jdonelson
pushed a commit
to MaterializeInc/materialize
that referenced
this pull request
Sep 24, 2026
### Motivation Address [GHSA-5x78-73v4-xg6w](GHSA-5x78-73v4-xg6w), which allows a malicious PostgreSQL server to exhaust client CPU by supplying an unbounded SCRAM iteration count during authentication. ### Description Raise the workspace minimum for `postgres-protocol` from 0.6.9 to 0.6.12 and update the locked Materialize rust-postgres fork revision. The fork update imports the upstream protocol release, including the 2,000,000-iteration cap, while retaining the replication protocol extensions. Other fork crate versions remain unchanged. Unrelated dependency versions and resolution changes are excluded. Uses merged [rust-postgres#35](MaterializeInc/rust-postgres#35) at `fcca71c8`, with a 2,000,000-iteration SCRAM cap. ### Verification The dependency update includes upstream regression coverage for excessive SCRAM iterations, normal SCRAM authentication, and invalid hstore lengths. The fork's replication extension is unchanged from its previous implementation. ### Release notes * Prevent malicious PostgreSQL servers from causing excessive CPU consumption during SCRAM authentication by rejecting iteration counts above 2,000,000.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Raise the SCRAM iteration limit to 2,000,000 with boundary tests. Fix Wasm feature wiring, the CI toolchain, and Clippy warnings after the protocol upgrade.