Skip to content

test/evp_test.c: Check too big output buffer sizes in PKEYKDF tests - #18536

Closed
levitte wants to merge 1 commit into
openssl:openssl-3.0from
levitte:test-18517
Closed

levitte wants to merge 1 commit into
openssl:openssl-3.0from
levitte:test-18517

Conversation

@levitte

@levitte levitte commented Jun 12, 2022

Copy link
Copy Markdown
Member

EVP_PKEY_derive() should be able to cope with a too big buffer for fixed
size outputs. However, we don't test that.

This change modifies the PKEYKDF tests to ask EVP_PKEY_derive() what the
desired output buffer size is, and as long as the returned value isn't
absurd (indicating that anything goes), the output buffer is made to be
twice as big as what is expected.

Tests #18517

EVP_PKEY_derive() should be able to cope with a too big buffer for fixed
size outputs.  However, we don't test that.

This change modifies the PKEYKDF tests to ask EVP_PKEY_derive() what the
desired output buffer size is, and as long as the returned value isn't
absurd (indicating that anything goes), the output buffer is made to be
twice as big as what is expected.

Tests openssl#18517
@levitte levitte added branch: 3.0 Applies to openssl-3.0 branch (EOL) branch: master Applies to master branch labels Jun 12, 2022
@levitte

levitte commented Jun 12, 2022

Copy link
Copy Markdown
Member Author

This is expected to fail until #18533 is merged

@levitte

levitte commented Jun 15, 2022

Copy link
Copy Markdown
Member Author

This got merged with #18533

@levitte levitte closed this Jun 15, 2022
@levitte
levitte deleted the test-18517 branch June 15, 2022 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

branch: master Applies to master branch branch: 3.0 Applies to openssl-3.0 branch (EOL)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant