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

[ELY-2147] Harden ScramServer against timing attacks #1549

Merged
merged 1 commit into from Jul 14, 2021
Merged

[ELY-2147] Harden ScramServer against timing attacks #1549

merged 1 commit into from Jul 14, 2021

Conversation

Syquel
Copy link
Contributor

@Syquel Syquel commented Jun 30, 2021

Currently org.wildfly.security.mechanism.scram.ScramServer uses simple byte comparison to verify the message nonce and client proof.
Simple byte comparison returns on the first mismatch and is therefore susceptible to timing attacks.

MessageDigest#isEqual(byte[],byte[]) should be used to compare message nonces and client proofs in constant time.

@wildfly-ci
Copy link

Hello, Syquel. I'm waiting for one of the admins to verify this patch with /ok-to-test in a comment.

@fjuma fjuma added the +1 FJ label Jul 13, 2021
@fjuma
Copy link
Contributor

fjuma commented Jul 13, 2021

Thanks for the PR, @Syquel.

@Skyllarr Skyllarr merged commit 07e29be into wildfly-security:1.x Jul 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants