Skip to content

PKCS11/SoftHSM/RSA issue: Decryption with a different key to the one used for Encryption is allowed #761

Open
@tgonzalezorlandoarm

Description

@tgonzalezorlandoarm

When trying to update the docker image parsec-service-test-all, the asym_encrypt_decrypt_rsa_pkcs_different_keys test fails for the PKCS11 provider.

This (negative) test encrypts a message with an RSA key and tries to decrypt it with another RSA key.
The RSA padding should allow the PKCS11 provider to realize that an incorrect key is being used and fail accordingly. The latter should happen when calling decrypt for the PKCS11 session.

SoftHSMv2 is being used as the software backend for the PKCS11 provider. A similar issue has been reported in there, for RHEL9. We are using Ubuntu 22.04.

Unfortunately, development in SoftHSMv2 is currently dormant (since last month) so it does not seem likely that we'll get a solution from that end.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtestingTask related to testing

    Type

    No type

    Projects

    Status

    All issues

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions