1
0
mirror of https://github.com/opencryptoki/opencryptoki.git synced 2026-10-24 05:39:17 +03:00

3137 Commits

Author SHA1 Message Date
Ingo Franzki
73d27be1ac ICSF: Fix Output buffer size check for CBC-PAD decryption
For CBC-PAD the output buffer size sent to ICSF was inflated to at least
cipher_text_len so the server does not send back RSN_TOO_SHORT for the
padded-then-unpadded output. Validate length against the inflated clear_len
(what we told the server) and bv_clear_data.bv_len against the caller's
real buffer. When the real buffer is too small for the unpadded result,
propagate CKR_BUFFER_TOO_SMALL so the caller can retry.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
e5cf411278 EP11: Return required output size on CKR_BUFFER_TOO_SMALL
The EP11 host library does not necessarily report the required output length
when an encrypt or decrypt update call fails with CKR_BUFFER_TOO_SMALL.

In this case, report an upper bound of the output length of the update
operation: Less than one block of data can be buffered by a previous update,
thus the output is at most the input length rounded up to a multiple of the
block size. A length already reported by the EP11 library (larger than the
passed one) is kept.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
5dcf5ef3d2 COMMON: Return required output size on CKR_BUFFER_TOO_SMALL
ECB, XTS encrypt and decrypt as well as CBC decrypt check that the buffer
is at least as large as the input and return CKR_BUFFER_TOO_SMALL if not,
but they do not update *out_data_len with the required buffer size.
This applies in the same way to to AES, DES, and DES3.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
6887ee91a4 COMMON: Cleanse output buffer in case of unpadding errors
In aes_key_wrap_decrypt() when the PKCS#7 unpadding fails, cleanse the
output buffer to not leak decrypted data in case of a failure.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
d5beecc9ca COMMON: Fix AES/DES/DES3-CBC-PAD PKCS#7 unpadding
As per PKCS#7, the pad bytes must all equal the padding value, i.e. the number
of bytes to pad. Every byte that could be padding is examined, so the time
taken does not depend on the padding. Also make sure that the padding
value is not larger than the block size.

Suggested-by: Alexandre Laroche <larochealexandre@hotmail.com>
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
f14f7a916f COMMON: Fix out-of-bounds access with AES/DES/DES3-CBC-PAD decryption
Fix the AES/DES/DES3-CBC-PAD decryption handling to not produce more output
than allowed as per output buffer length.

Also check for errors during strip_pkcs_padding() to detect padding errors
and fail the operation.

With the buffer size checking, the IV must be saved before the actual
operations and must be restored in case of a CKR_BUFFER_TOO_SMALL error.
The operation might update the running IV in the context. However, the
caller must be able to retry with the original IV intact using a large
enough output buffer.

Suggested-by: Alexandre Laroche <larochealexandre@hotmail.com>
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-22 12:53:13 +02:00
Ingo Franzki
595ca62ada COMMON: Fix BER encoding and decoding of Edwards and Montgomery private keys
For Edwards and Montgomery private keys RFC 8410 defines that the private
key is an OCTET-STRING, and not a SEQUENCE as for EC keys (RFC 5915).

Fix this by encoding and decoding the correct PKCS#8 format. For decoding,
Edwards and Montgomery private keys encoded using the wrong EC-key style are
still accepted for backward compatibility.

Fixes: 3fd5120a41

Reported-by: Alexandre Laroche <larochealexandre@hotmail.com>
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-20 14:31:37 +02:00
Alexandre Laroche
2345b3c7e9 COMMON: Honour CKA_SENSITIVE and CKA_EXTRACTABLE from the unwrap template
secret_key_unwrap() and priv_key_unwrap() set CKA_SENSITIVE to FALSE and
CKA_EXTRACTABLE to TRUE on every unwrapped key, after the caller's
template, and the unwrapping key's CKA_UNWRAP_TEMPLATE, had already been
validated and merged into the new object. Both were silently overwritten:

 - a template asking for CKA_SENSITIVE = TRUE and CKA_EXTRACTABLE = FALSE
   gave a key whose value could be read in clear with
   C_GetAttributeValue(CKA_VALUE) and wrapped out again;
 - an unwrapping key whose CKA_UNWRAP_TEMPLATE requires CKA_SENSITIVE =
   TRUE or CKA_EXTRACTABLE = FALSE did not get that policy applied to the
   keys unwrapped with it.

C_UnwrapKey returned CKR_OK in both cases.

Stop overwriting these two attributes. object_create_skel() already
starts the object from the class defaults (CKA_SENSITIVE = FALSE,
CKA_EXTRACTABLE = TRUE), lets the token's t_set_attrs_for_new_object()
supply its own defaults, and merges the template over them. CKA_LOCAL,
CKA_ALWAYS_SENSITIVE and CKA_NEVER_EXTRACTABLE are still set to FALSE, as
PKCS#11 requires for an unwrapped key.

For a template that does not specify the two attributes, under an
unwrapping key without a CKA_UNWRAP_TEMPLATE, tokens that keep the class
defaults give the same key as before. Tokens that default CKA_SENSITIVE
to TRUE (EP11 and CCA for private keys, and for secret keys when
FORCE_SENSITIVE is enabled) now apply that default to unwrapped keys
too, as they already do for generated and derived keys; until now the
unwrap path overwrote it with FALSE.

Signed-off-by: Alexandre Laroche <larochealexandre@hotmail.com>
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-19 13:52:53 +02:00
Ingo Franzki
0d2e914258 COMMON: NULLify pContext and ulContextLen in ML-DSA mechanism parameter copy
If the source has an empty context, then also set the context to empty on the
target before returning early. Any left over context pointers in the target
might otherwise be freed later when the copy is freed.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
ebab4b48e0 COMMON: Cleanup operation in init failure
In case *_mgr_init() fails, call *_mgr_cleanup() to free all already allocated
context buffers.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
2acb7a25bf EP11: Fix cleanup in case EC-AGGREGATE mechanism parameter deep-copy fails
When the deep-copy if the EC-AGGREGATE mechanism parameter fails, cleanup
the operation before returning.

The EC-AGGREGATE deep-copy function must NULLify the pAggrElements field
before attempting to copy. The destination starts as a shallow memcpy of
the source, so it held the caller's pointers. If a malloc failed partway
through, it would have freed those caller-owned buffers.

While at it, move the deep-copy case into the already existing switch
above inside the mechanism parameter guard. Also check the size of the
mechanism parameter to be the expected length before deep-copying it.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
350f61c775 COMMON: Fix error handling when deep-copy a mechanism parameter fails
In case deep-copying the ML-DSA mechanism parameter fails, don't continue,
but go to the done label.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
f9e05e3742 COMMON/EP11: Reject saving the state for mechanisms with deep-copied parameters
Saving the operation state via C_SetOperationState() only works for
mechanisms with mechanism parameters that can be serialized. Thus, mechanisms
that use a mechanism parameter that gets deep-copied into the context can
not be saved. Set the state_unsaveable flag for those mechanisms. This
will cause C_SetOperationState() to fail with with CKR_STATE_UNSAVEABLE.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
b663eaa8f3 COMMON: Fix memory leak of deep-copied mechanism parameters on session close
Some mechanisms keep a deep copy of its mechanism parameter in the operation
context. Normal operation cleanup deep-frees them properly, but session_free()
and session_mgr_close_session() do not deep-free them, but just free the outer
structure, leaking any inner allocations. This happens when a session is
closed that has a still active operation with such a mechanism.

Fix this by directing the cleanup to the regular operation cleanup helpers
that already do it right.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-14 16:56:25 +02:00
Ingo Franzki
137c741923 COMMON: Decoding EC public and private keys must check the OID
Functions der_decode_ECPrivateKey() and der_decode_ECPublicKey() can be called
to decode a EC, Edwards, or Montgomery key. For EC, the OID of the curve is
the param in the AlgorithmIdentifier, and for Edwards and Montgomery the OID
in the AlgorithmIdentifier specifies the curve OID directly. Check that the
OID is one of the known curves for EC, and one of the expected Edwards or
Montgomery OIDs for Edwards and Montgomery respectively.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-13 11:56:12 +02:00
Ingo Franzki
bab7e26028 COMMON: Fix ber_decode_SPKI to not assume a single byte OID length
Function ber_decode_SPKI() extracts the OID and the parameters from the
AlgorithmIdentifier. It assumes that the BER encoded OID has a single byte
length field. While this is the case for all used OIDs, an malformed
SPKI could have an AlgorithmIdentifier that has a multi-byte length
OID. Decode the field length and do not assume a single byte length.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-13 11:56:12 +02:00
Ingo Franzki
849d1363ac COMMON: Fix out-of-bounds read when decoding public or private keys
The decoding functions for public and private keys compare the decoded
AlgorithmIdentifier from the key material with constants to check for valid
key types. This check does not check the length of the decoded
AlgorithmIdentifier and thus might overrun the buffer producing an
out-of-bounds read for too short AlgorithmIdentifiers.

Reported-by: Stuart Thomas <stuart.thomas@triageforge.co.uk>
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-13 11:56:12 +02:00
Ingo Franzki
6fa1b5c03e ICSF: Correct key sizes and flags in the mechanism table
The min and max key sizes for DES, DES3 and HMAC mechanisms were zero.
Update this to the correct key sizes.

Some mechanism do not have the CKF_HW flag set where it should be set,
or vice versa. Fix that.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-08 12:38:18 +02:00
Ingo Franzki
73b2f41d77 P11KMIP: Fix NULL-check, wrong dereference, and rc ordering
Certain error situations are not handled correctly. Fix them.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
e1b16f4111 P11KMIP: Fix memory leak in kmip_encode_json()
If adding an array element, the not-added element must be freed before
returning an error.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
d6d5194712 P11KMIP: Fix hex representation of values >= 2^52
When producing the hex representation of values >= 2^52 make sure that
the value is in big endian format, so that the hex representation is
correct.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
a59d96cf69 P11KMIP: Fix hostname verification with IPv6 addresses
IPv6 brackets must be removed for hostname verification, otherwise the
verification will fail.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
7d0c7f126f P11KMIP: Structures must be a multiple of the TTLV block length
Add a check to ensure that structures are a multiple of the TTLV block
length. If thats not the case return an error early, and do not only
rely on parsing the structure elements to fail.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
277e098409 P11KMIP: Fix attributes with wrong KMIP tag
Correct the KMIP tags used for date and application specific information
attributes.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
345eec8904 P11KMIP: Load the system's default CA certs if no CA is specified
if field 'tls_ca' is NULL in the connection config structure, the system's
default CA certificates are supposed to be loaded and used. This is
currently not done, leaving it with an empty certificate store and
any peer or hostname verification will fail.

Call SSL_CTX_set_default_verify_paths() to load the system's default CA
certificates.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
b71487d962 P11KMIP: On any I/O failure tear down the connection completely
Just resetting the OpenSSL BIO via BIO_reset() leaves the BIO in a state
where the next attempt to use it will reconnect to the server and perform
a TLS handshake freshly. However, this reconnect omits the checks done
by kmip_connection_tls_verify_server().

In case of any I/O failure tear down the connection completely to
avoid any reconnects.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
7758e6e595 P11KMIP: Fix NULL pointer dereference on corrupted KMIP response
When a corrupted KMIP response contains KMIP nodes that are expected to
be of type TEXT-STRING, but they are of a different type, then function
kmip_node_get_text_string() returns NULL. Fix all callers to check
for such NULL returns and return -EBADMSG if so.

Not checking for NULL might cause NULL pointer dereferences in the
callers, or the callers further down the stack.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
83086fb742 API: Don't advertise interfaces with CKF_INTERFACE_FORK_SAFE
PKCS#11 states for flag CKF_INTERFACE_FORK_SAFE:

"The returned interface will have fork tolerant semantics. When the
application forks, each process will get its own copy of all session
objects, session states, login states, and encryption states. Each
process will also maintain access to token objects with their previously
supplied handles."

This is not how Opencryptoki behaves. The forked child starts as if
cryptoki has never been initialized, it needs to initialize the cryptoki
library freshly with C_Initialize if needed.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
f58f72d548 PKCSSLOTD: Fix potentially unterminated string usage
Although the fiends in 'sinfo[slot_no]' in question are usually NUL-terminated
(do_str() pads the string with NUL values), there is one case where it is not
NUL-terminated: when the string length matches the target field length.

Use the 'str' variable, which is always NUL-terminated for the checks.
Variable 'str' and the struct field are identical in value, using 'str'
is semantically equivalent, but eliminates the unterminated string usage.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
b1776832b6 PKCSICSF: Fix uninitialized variable
When writing the initial NVTOK.dat file fails before the file name is
set, the attempt to unlink the file uses an uninitialized variable name.
Initialize fname with zeros, and attempt the unlink only if the file name
was set before.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
997f633894 ICSF: Fix uninitialized variable
When the login mechanism is not ICSF_CFG_MECH_SIMPLE, then there is no
wrap key, and thus variable 'new_wrap_key' is never set, but is later
on copied to 'user_wrap_key' in 'tokdata' (which also is never used).
Initialize the variable with zeros to silence the warning.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
e93833f433 P11SAK: Fix assignment discards ‘const’ qualifier warning
Fix the following build warning:

usr/sbin/p11sak/p11sak.c:3979:8: warning: assignment discards ‘const’
        qualifier from pointer target type [-Wdiscarded-qualifiers]
 3979 |     ch = strchr(attrs, ':');
      |        ^

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-10-05 08:35:13 +02:00
Ingo Franzki
cb3c2e0a2c ICSF: Filter out CKA_EN/DECAPSULATE attributes, ICSF does not support them
The attributes CKA_ENCAPSULATE and CKA_DECAPSULATE have been introduced
with PKCS#11 v3.2, but ICSF does not support them. This cases failures
for various test cases (i.e. RSA key gen) when these attributes are in
the templates for the keys.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
22d88c2ea3 PKCSICSF: Allow to specify the SO PIN and RACF password as option
For better scripting capabilities, the SO PIN and the RACF password can
optionally be supplied via options -R and -S. If not specified you are
prompted for them.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
7f5c86a549 PKCSICSF: Allow to specify the slot number to create with '-a <token>'
If -slot is specified then create the new ICSF token at the given slot number.
Otherwise the next free slot is used.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
0daecd52ed PKCSICSF: Store absolute paths in ICSF token config for SASL method
If relative file names are specified for the SASL key and certificates,
store the absolute path of them into the ICSF token config file.
This makes it location independent.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
58d45b6ff1 ICSF: Support public session with SASL authentication
Since SASL authentication does not require unlocking the token master key
to obtain an RACF password, public sessions (sessions opened without a
prior User or SO login) are supported for accessing and operating on public
objects when using SASL. In contrast, Simple authentication requires a User
or SO login before token operations can be performed because the RACF
password must be decrypted from disk using the token master key.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
bc1fac364f ICSF: Allow NULL attrs if number of attrs is zero
The check for attrs being nun-NULL is too strict. If the number of attributes
is zero, then attrs  can be NULL.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
81385b50ac ICSF: Restrict key wrapping with CKM_RSA_PKCS to secret keys
As per PKCS#11 standard, mechanism CKM_RSA_PKCS can only wrap secret keys,
but not private keys. Reject this accordingly with CKR_KEY_NOT_WRAPPABLE
for wrapping, and CKR_ARGUMENTS_BAD for unwrapping, like common code
also does.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
b4b140a38c ICSF: Map CKR_DATA_LEN_RANGE to CKR_KEY_SIZE_RANGE in icsftok_wrap_key
When the key material is too large to be wrapped by a wrapping key, ICSF
returns 8 / 11000 which is translated into CKR_DATA_LEN_RANGE. For
key wrapping this is mapped to CKR_KEY_SIZE_RANGE which fits better.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
e7fc2734e9 ICSF: Convert compressed or raw EC points to uncompressed
ICSF only accepts uncompressed EC Points when creating an EC public key
object, as well as for ECDH derive as public data.

Convert compressed or raw EC points to the uncompressed form before passing
it to ICSF.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
4941461449 ICSF: Support newer KDF values
Newer KDF values might not fit into a single byte. Send them as 32 bit
big endian value instead of the single byte.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
fa54378614 ICSF: Adjust return code mapping
- Change ICSF return code 8/3034 to CKR_ACTION_PROHIBITED.
- Change ICSF return code 8/874 to CKR_CURVE_NOT_SUPPORTED
- Change ICSF return code 8/2116 to CKR_MECHANISM_PARAM_INVALID

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
9c05091d52 POLICY: Fix memory leak in policy_extract_key_data() for DH keys
Don't exit early when getting CKA_PRIME fails. This leaves attributes
retrieved before that failure leaking.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
6606505421 POLICY: Fix typo in trace message
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
e3fbb74ece ICSF: Fix memory leak icsftok_find_objects_init
Ignore the error on store_object_strength(), but when adding the mapping to
the tree fails, then free the mapping and report an error.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
ca7f1645a4 COMMON/EP11/ICSF: Make C_Login, C_Set/InitPIN, C_InitToken fully thread save
Make sure that C_Login, C_SetPIN, C_InitPIN, C_InitToken do not read or
update any token files or any field in the token shared memory without
holding the XProcLock.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
063621047a PKCSICSF: Add support for changing the RACF password
Use 'pkcsicsf -p <token-name>' to change the RACF password of an existing
ICSF token.

The pkcsicsf tool updates the RACF file under the XProcLock, so the ICSF
token must read the RACF file under the XProcLock. This prevents concurrent
reads on a RACF file that is currently modified.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
bf40a5fe9f ICSF: Introduce a FIPS-compliant token data store format
Similar to the FIPS-compliant token data store format of the other tokens,
define a new token data store format for the ICSF token.

The new data format is used when the ICSF token has 'tokversion = 3.28'
in the slot definition in opencryptoki.conf. Existing ICSF tokens continue
to work unchanged. New ICSF tokens added via the pkcsicsf tool will always
have 'tokversion = 3.28' and thus use the new data format.

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-23 13:25:13 +02:00
Ingo Franzki
5ebc3e7c04 EP11: Edwards/Montgomery mechanisms are EP11 version dependent
Only report CKM_EC_EDWARDS_KEY_PAIR_GEN, CKM_EC_MONTGOMERY_KEY_PAIR_GEN,
and CKM_EDDSA as available only if the EP11 version prerequisites are
fulfilled.

Mechanism CKM_EC_EDWARDS_KEY_PAIR_GEN and CKM_EC_MONTGOMERY_KEY_PAIR_GEN
are mapped to CKM_EC_KEY_PAIR_GEN. However, not only CKM_EC_KEY_PAIR_GEN
must be supported, but also the prerequisites for Edwards and Montgomery
support of EP11 must be fulfilled.

Mechanism CKM_EDDSA also requires that the prerequisites for Edwards
support of EP11 is fulfilled.

Fixes: a1156d179d

Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
2026-09-11 13:53:23 +02:00