Move private pk interfaces to mbedtls/private/pk.h #344

Closed
opened 2025-07-01 14:23:42 -05:00 by gilles-peskine-arm · 3 comments
gilles-peskine-arm commented 2025-07-01 14:23:42 -05:00 (Migrated from github.com)

Depends: https://github.com/Mbed-TLS/TF-PSA-Crypto/issues/343, https://github.com/Mbed-TLS/mbedtls-framework/issues/178, https://github.com/Mbed-TLS/mbedtls/issues/10263

Move all private API elements to mbedtls/private/pk_private.h, guarded by MBEDTLS_DECLARE_PRIVATE_IDENTIFIERS:

mbedtls_pk_type_t
mbedtls_pk_rsassa_pss_options
mbedtls_pk_debug_type
mbedtls_pk_debug_item
MBEDTLS_PK_DEBUG_MAX_ITEMS
mbedtls_pk_info_from_type()
mbedtls_pk_setup()
mbedtls_pk_get_len()
mbedtls_pk_can_do()
mbedtls_pk_can_do_ext()
mbedtls_pk_debug()
mbedtls_pk_get_name()
mbedtls_pk_get_type()
mbedtls_pk_rsa()
mbedtls_pk_ec()
mbedtls_pk_parse_subpubkey()
mbedtls_pk_write_pubkey()

Also mbedtls_pk_verify_new() if it exists.

Depends: https://github.com/Mbed-TLS/TF-PSA-Crypto/issues/343, https://github.com/Mbed-TLS/mbedtls-framework/issues/178, https://github.com/Mbed-TLS/mbedtls/issues/10263 Move all private API elements to `mbedtls/private/pk_private.h`, guarded by `MBEDTLS_DECLARE_PRIVATE_IDENTIFIERS`: ``` mbedtls_pk_type_t mbedtls_pk_rsassa_pss_options mbedtls_pk_debug_type mbedtls_pk_debug_item MBEDTLS_PK_DEBUG_MAX_ITEMS mbedtls_pk_info_from_type() mbedtls_pk_setup() mbedtls_pk_get_len() mbedtls_pk_can_do() mbedtls_pk_can_do_ext() mbedtls_pk_debug() mbedtls_pk_get_name() mbedtls_pk_get_type() mbedtls_pk_rsa() mbedtls_pk_ec() mbedtls_pk_parse_subpubkey() mbedtls_pk_write_pubkey() ``` Also `mbedtls_pk_verify_new()` if it exists.
bjwtaylor commented 2025-07-07 03:23:34 -05:00 (Migrated from github.com)

Did an initial investigation of this and it causes issues with mbedtls_pk_verify_ext, so I'm assuming it has dependencies on other tasks not listed and am setting it back to blocked.

Did an initial investigation of this and it causes issues with mbedtls_pk_verify_ext, so I'm assuming it has dependencies on other tasks not listed and am setting it back to blocked.
gilles-peskine-arm commented 2025-07-07 03:54:06 -05:00 (Migrated from github.com)

@bjwtaylor This doesn't directly interfere with mbedtls_pk_verify_ext, which is staying public. But it does interfere with mbedtls_pk_verify_new, which is private (but meant to be removed before the release anyway).

@bjwtaylor This doesn't directly interfere with `mbedtls_pk_verify_ext`, which is staying public. But it does interfere with `mbedtls_pk_verify_new`, which is private (but meant to be removed before the release anyway).
bjwtaylor commented 2025-07-11 05:11:30 -05:00 (Migrated from github.com)

mbedtls_pk_rsassa_pss_options was removed as part of github.com/Mbed-TLS/TF-PSA-Crypto@593b2a32fd, so I'm assuming this is out of scope. Let me know if this it not the case.

mbedtls_pk_rsassa_pss_options was removed as part of https://github.com/Mbed-TLS/TF-PSA-Crypto/commit/593b2a32fd4c9e4a36a7c44aa520530053994e18, so I'm assuming this is out of scope. Let me know if this it not the case.
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#344
No description provided.