-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Unexpected reset of DRBG reseed interval #2927
Comments
I agree, the library code should have been written in such a way that I recently fixed a similar bug for This applies to HMAC_DRBG as well. |
I'd like to work on this issue, but since this is my first time contributing to open source software, please be patient and let me know what my PR is missing. |
Hi @gacquroff, thank you for considering to contribute to Mbed TLS! Github automatically adds links to PRs that reference this issue. Since there is no such link added, there is no PR addressing this issue yet. |
Thanks @gacquroff ! If you haven't already done so, please read our coding standards. For this bug fix, here are a few things I can think of:
|
@yanesca Thanks! @gilles-peskine-arm Is a non-regression test equivalent to a regression test? I've seen conflicting information. |
I mean a test that fails before fixing the bug, and passes once the bug is fixed. I can't think of another meaning for either “regression test” or “non-regression test”. I've seen both expressions in common use. |
Thanks for clarifying! I've seen regression test meaning "a test that ensures there isnt a regression, i.e. passes before the patch and passes after", so that's why I was confused. |
Description
Enhancement\Feature Request
Consider the following scenario
From my point of view, this seems like a proper procedure and should result in the custom reseed interval being used. But currently mbedtls_ctr_drbg_seed resets the reseed interval to the default value.
I have found no indication in the API documentation informing a developer about this behavior.
Justification - why does the library need this feature?
Since reseed interval could be considered security critical, it should be hard to end up using another value than intended.
Suggested enhancement
Either avoid resetting reseed interval in the seed function or add proper documentation/instructions for the developer that integrates with mbedTLS.
The text was updated successfully, but these errors were encountered: