Remove RNG from x509 and PK #194

Merged
bjwtaylor merged 1 commit from remove-rng-from-pk into development 2025-03-25 04:57:30 -05:00
bjwtaylor commented 2025-03-10 02:55:31 -05:00 (Migrated from github.com)

Description

remove the f_rng and p_rng parameter from x509 and PK.

resolves https://github.com/Mbed-TLS/TF-PSA-Crypto/issues/169

Cross-depends on the associated mbedtls PR for a clean CI.

PR checklist

  • changelog not required because: it will be provided under a later issue
  • framework PR not required
  • mbedtls development PR provided https://github.com/Mbed-TLS/mbedtls/pull/10037
  • mbedtls 3.6 PR not required because: No backports (API break)
  • mbedtls 2.28 PR not required because: No backports (API break)
  • tests covered by existing tests
## Description remove the f_rng and p_rng parameter from x509 and PK. resolves https://github.com/Mbed-TLS/TF-PSA-Crypto/issues/169 Cross-depends on the associated mbedtls PR for a clean CI. ## PR checklist - [x] **changelog** not required because: it will be provided under a later issue - [x] **framework PR** not required - [x] **mbedtls development PR** provided https://github.com/Mbed-TLS/mbedtls/pull/10037 - [x] **mbedtls 3.6 PR** not required because: No backports (API break) - [x] **mbedtls 2.28 PR** not required because: No backports (API break) - **tests** covered by existing tests
mpg (Migrated from github.com) requested changes 2025-03-20 03:59:48 -05:00
mpg (Migrated from github.com) left a comment

Looks pretty good to me, just two occurrences of a minor point.

Since this PR is a single commit (which makes sense), feel free to just amend it to remove the superfluous changes - and fix the commit message while at it.

Looks pretty good to me, just two occurrences of a minor point. Since this PR is a single commit (which makes sense), feel free to just amend it to remove the superfluous changes - and fix the commit message while at it.
@ -285,4 +285,2 @@
typedef int (*mbedtls_pk_rsa_alt_sign_func)(void *ctx,
int (*f_rng)(void *, unsigned char *, size_t),
void *p_rng,
mbedtls_md_type_t md_alg, unsigned int hashlen,
mpg (Migrated from github.com) commented 2025-03-20 03:39:15 -05:00

[about the commit message] Minor: this is only about PK, we don't have any x509 in this repo.

[about the commit message] Minor: this is only about PK, we don't have any x509 in this repo.
mpg (Migrated from github.com) commented 2025-03-20 03:46:01 -05:00

Looks like a leftover from debugging, can you revert to return ctx->...?

Looks like a leftover from debugging, can you revert to `return ctx->...`?
@ -1303,20 +1260,16 @@ static int rsa_alt_sign_wrap(mbedtls_pk_context *pk, mbedtls_md_type_t md_alg,
return MBEDTLS_ERR_PK_BUFFER_TOO_SMALL;
mpg (Migrated from github.com) commented 2025-03-20 03:51:31 -05:00

Same.

Same.
mpg (Migrated from github.com) approved these changes 2025-03-20 06:06:34 -05:00
mpg (Migrated from github.com) left a comment

LGTM, thanks!

LGTM, thanks!
valeriosetti (Migrated from github.com) approved these changes 2025-03-20 06:07:55 -05:00
mpg commented 2025-03-25 04:57:07 -05:00 (Migrated from github.com)

CI is green in the companion PR https://github.com/Mbed-TLS/mbedtls/pull/10037 which is also approved, so this can be merged.

CI is green in the companion PR https://github.com/Mbed-TLS/mbedtls/pull/10037 which is also approved, so this can be merged.
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-Mbed-TLS/TF-PSA-Crypto!194
No description provided.