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

Authorization header uses non constant time password comparison. #11

Closed
Michel-de-Boer-dev opened this issue Aug 21, 2022 · 1 comment
Closed

Comments

@Michel-de-Boer-dev
Copy link

Authorization passwords are checked like: if auth != config['SERVER_PASSWORD']
https://github.com/C4T-BuT-S4D/S4DFarm/blob/master/server/app/auth.py#L16

An attacker could potential recover the password faster then guessing. A guessed password that has the first byte correct takes longer to check then a password that has the first byte wrong. Once the first byte is found, one can find the next byte and so on.

https://sqreen.github.io/DevelopersSecurityBestPractices/timing-attack/python

The attacker would need a lot of requests, as there can be quite some jitter and noise in the network, so it's not a very realistic attack, but might be feasable with enough samples.

@pomo-mondreganto
Copy link
Member

Non-viable attack in real life

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

No branches or pull requests

2 participants