mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2026-10-28 18:07:34 +08:00
Merge tag 'mbedtls-3.6.7' into mbedtls-3.6.7_mergeback-2
Mbed TLS mbedtls-3.6.7 Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
This commit is contained in:
commit
ab18cc38f1
12
3rdparty/everest/library/x25519.c
vendored
12
3rdparty/everest/library/x25519.c
vendored
@ -131,12 +131,16 @@ int mbedtls_x25519_calc_secret( mbedtls_x25519_context *ctx, size_t *olen,
|
||||
if( blen < *olen )
|
||||
return( MBEDTLS_ERR_ECP_BUFFER_TOO_SMALL );
|
||||
|
||||
Hacl_Curve25519_crypto_scalarmult( buf, ctx->our_secret, ctx->peer_point);
|
||||
/* scalarmult modifies this input, let's make a copy... */
|
||||
unsigned char secret[MBEDTLS_X25519_KEY_SIZE_BYTES];
|
||||
memcpy(secret, ctx->our_secret, sizeof(secret));
|
||||
|
||||
/* Wipe the DH secret and don't let the peer chose a small subgroup point */
|
||||
mbedtls_platform_zeroize( ctx->our_secret, MBEDTLS_X25519_KEY_SIZE_BYTES );
|
||||
Hacl_Curve25519_crypto_scalarmult( buf, secret, ctx->peer_point);
|
||||
|
||||
if( memcmp( buf, ctx->our_secret, MBEDTLS_X25519_KEY_SIZE_BYTES) == 0 )
|
||||
/* Wipe the copy and don't let the peer choose a small subgroup point */
|
||||
mbedtls_platform_zeroize( secret, MBEDTLS_X25519_KEY_SIZE_BYTES );
|
||||
|
||||
if( memcmp( buf, secret, MBEDTLS_X25519_KEY_SIZE_BYTES) == 0 )
|
||||
return MBEDTLS_ERR_ECP_RANDOM_FAILED;
|
||||
|
||||
return( 0 );
|
||||
|
||||
@ -108,9 +108,9 @@ The following branches are currently maintained:
|
||||
- [`development`](https://github.com/Mbed-TLS/mbedtls/)
|
||||
- [`mbedtls-3.6`](https://github.com/Mbed-TLS/mbedtls/tree/mbedtls-3.6)
|
||||
maintained until March 2027, see
|
||||
<https://github.com/Mbed-TLS/mbedtls/releases/tag/v3.6.6>.
|
||||
<https://github.com/Mbed-TLS/mbedtls/releases/tag/v3.6.7>.
|
||||
- [`mbedtls-4.1`](https://github.com/Mbed-TLS/mbedtls/tree/mbedtls-4.1)
|
||||
maintained until March 2029, see
|
||||
<https://github.com/Mbed-TLS/mbedtls/releases/tag/v4.1.0>.
|
||||
<https://github.com/Mbed-TLS/mbedtls/releases/tag/v4.1.1>.
|
||||
|
||||
Users are urged to always use the latest version of a maintained branch.
|
||||
|
||||
@ -40,12 +40,12 @@ cmake_policy(SET CMP0012 NEW)
|
||||
if(TEST_CPP)
|
||||
project("Mbed TLS"
|
||||
LANGUAGES C CXX
|
||||
VERSION 3.6.6
|
||||
VERSION 3.6.7
|
||||
)
|
||||
else()
|
||||
project("Mbed TLS"
|
||||
LANGUAGES C
|
||||
VERSION 3.6.6
|
||||
VERSION 3.6.7
|
||||
)
|
||||
endif()
|
||||
|
||||
@ -73,7 +73,7 @@ if(CMAKE_HOST_WIN32)
|
||||
# CMakeLists.txt.
|
||||
option(GEN_FILES "Generate the auto-generated files as needed" OFF) # off in development
|
||||
else()
|
||||
option(GEN_FILES "Generate the auto-generated files as needed" ON)
|
||||
option(GEN_FILES "Generate the auto-generated files as needed" OFF)
|
||||
endif()
|
||||
|
||||
option(DISABLE_PACKAGE_CONFIG_AND_INSTALL "Disable package configuration, target export and installation" ${MBEDTLS_AS_SUBPROJECT})
|
||||
@ -501,7 +501,7 @@ if(NOT DISABLE_PACKAGE_CONFIG_AND_INSTALL)
|
||||
write_basic_package_version_file(
|
||||
"cmake/MbedTLSConfigVersion.cmake"
|
||||
COMPATIBILITY SameMajorVersion
|
||||
VERSION 3.6.6)
|
||||
VERSION 3.6.7)
|
||||
|
||||
install(
|
||||
FILES "${CMAKE_CURRENT_BINARY_DIR}/cmake/MbedTLSConfig.cmake"
|
||||
|
||||
130
ChangeLog
130
ChangeLog
@ -1,5 +1,135 @@
|
||||
Mbed TLS ChangeLog (Sorted per branch, date)
|
||||
|
||||
= Mbed TLS 3.6.7 branch released 2026-07-07
|
||||
|
||||
Features
|
||||
* SHA3-256, SHA3-384 and SHA3-512 are now accepted in the default X.509
|
||||
certificate profile.
|
||||
|
||||
Security
|
||||
* Fix a side channel in RSA PKCS#1 v1.5 decryption: error handling in the
|
||||
library would reveal through timing the difference between success,
|
||||
invalid padding, or output too large for buffer, giving rise to a
|
||||
Bleichenbacher attack. Note that while the library now handles sensitive
|
||||
errors in constant-time, RSA PKCS#1 v1.5 decryption remains inherently
|
||||
dangerous, should be avoided when possible, and otherwise requires great
|
||||
care in application code. Found by zhengg. CVE-2026-50587
|
||||
* Added advice about compiler options in SECURITY.md.
|
||||
* Fix a bug where transcript-hash computation errors during TLS 1.2
|
||||
extended master secret calculation could be ignored instead of causing the
|
||||
handshake to fail. This could allow a handshake to continue with a master
|
||||
secret that was not correctly bound to the handshake transcript,
|
||||
undermining the security guarantees of the extended master secret
|
||||
extension. Report by Mathew Gretton-Dann. CVE-2026-50581
|
||||
* Fix a TLS 1.3 server-side error-handling bug affecting session ticket
|
||||
generation. Under rare conditions, such as memory allocation failures
|
||||
while computing the resumption master secret, the server could issue
|
||||
invalid session tickets instead of failing the handshake. Clients
|
||||
presented with such tickets would fail session resumption and fall back to
|
||||
a full handshake. In deployments relying on session resumption, repeated
|
||||
occurrences could increase the frequency of full handshakes and amplify
|
||||
resource consumption during periods of resource exhaustion or other
|
||||
transient failures. Reported by jjfz123.
|
||||
CVE-2026-50640
|
||||
* Fix renegotiation failing and potentially causing a buffer overflow
|
||||
in DTLS when badmac_limit is enabled. Reported by Haruki Oyama.
|
||||
CVE-2026-50713.
|
||||
* Reject ChaCha20 operations that would make the 32-bit block counter wrap
|
||||
around, which could otherwise reuse keystream and compromise
|
||||
confidentiality. Reported by jiliang. CVE-2026-50584
|
||||
* Fixed a TLS 1.3 record-boundary validation issue that could allow
|
||||
unauthenticated plaintext data to be processed across a key change. In
|
||||
servers with MBEDTLS_SSL_EARLY_DATA enabled, this could be exploited by a
|
||||
man-in-the-middle attacker to cause loss of 0-RTT early data.
|
||||
Reported by Ben Smyth.
|
||||
* Fix a possible buffer overflow in mbedtls_ecdh_calc_secret(): when the
|
||||
provided output buffer is too small, sometimes (depending on the value of
|
||||
the computed shared secret), the function would not return an error as it
|
||||
should, but instead write past the end of the buffer. Reported by Eva
|
||||
Crystal (0xiviel) from XSource Security. CVE-2026-35336.
|
||||
* Fix a remote buffer overflow in (D)TLS with ECDHE-PSK cipher suites when
|
||||
CBC is disabled. Reported by Karnakar Reddy. CVE-ID-50580
|
||||
* Fix a side channel in ECC computations that allows a powerful local
|
||||
attacker (typically, untrusted OS attacking a secure enclave) to fully
|
||||
recover long-term secret keys. Found and reported by Alejandro Cabrera
|
||||
Aldaya from Tampere University. CVE-2026-54435
|
||||
* Fix a potential information disclosure in TLS 1.2 servers using session
|
||||
tickets. If the session ticket write callback failed without setting the
|
||||
lifetime output parameter, Mbed TLS could send 4 bytes of uninitialized
|
||||
stack memory to the peer in the NewSessionTicket message. Fixes #1570.
|
||||
Reported by James Love. CVE-2026-50586.
|
||||
* Fix timing side channel in RSA key generation, prime generation and
|
||||
primality testing, on platforms where division is not constant-time. At
|
||||
this point this side channel is not known to be exploitable. Reported by
|
||||
Bhargava Shastry, Ethereum Foundation.
|
||||
* Fix a 1-byte buffer overread when parsing a malformed ECC public key
|
||||
in the PK module. CVE-2026-50583
|
||||
* Fix an out-of-bounds read when parsing TLS 1.2 ECJPAKE ServerKeyExchange
|
||||
messages. Reported-by Biniam Demissie.
|
||||
CVE-2026-50588
|
||||
* Fix a use-after-free/double-free risk in mbedtls_pkcs7_free() when reusing
|
||||
an mbedtls_pkcs7 context across parse -> free -> parse -> free cycles. The
|
||||
function now resets the context after freeing it, ensuring stale
|
||||
signed_data.signers.next pointers cannot be walked by a later free
|
||||
operation. CVE-2026-50579
|
||||
* PKCS7 now rejects weak hash algorithms (RIPEMD160, MD5, SHA-1, SHA-224,
|
||||
SHA3-224) on signature verification. The new configuration option
|
||||
MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES allows to keep using weak hash
|
||||
algorithms in PKCS7 for backward compatibility purposes.
|
||||
* Improved documentation of mbedtls_ssl_conf_sig_algs() to emphasize that
|
||||
this function only sets signature algorithms that are enforced during
|
||||
TLS key exchange and not on certificate verification. Reported by
|
||||
Xiangdong Li, Beijing University of Posts and Telecommunications (BUPT).
|
||||
CVE-2026-54441
|
||||
* Ensure 'dtls_srtp_info' field from 'mbedtls_ssl_context'
|
||||
is properly zeroized when mbedtls_ssl_session_reset() is called. This
|
||||
could cause incorrect DTLS-SRTP parameter inheritance for applications
|
||||
reusing an SSL context.
|
||||
Reported by jjfz123. CVE-2026-50585.
|
||||
* Fix a bug where mbedtls_ssl_read() and mbedtls_ssl_write() could return
|
||||
1 instead of an error code if the random generator failed when a server
|
||||
called these functions before the end of a TLS 1.3 handshake.
|
||||
Reported by Mohammad Seet (mhdsait101).
|
||||
* Fix TLS 1.3 clients to reject a HelloRetryRequest whose selected group was
|
||||
not advertised in the original ClientHello. Reported independently by
|
||||
Din Asotić / Xiangdong Li, Beijing University of Posts and
|
||||
Telecommunications (BUPT), and NVIDIA Project Vanessa.
|
||||
CVE-2026-25832.
|
||||
* Fix two bugs in the X.509 certificate parser that caused some inputs
|
||||
with a malformed basicConstraints extension to be accepted. This
|
||||
could have dangerous results, in particular causing some certificates
|
||||
to be parsed as CA certificates when other X.509 implementations would
|
||||
parse them as end-entity certificates. Reported by Mohammad Seet
|
||||
(mhdsait101), Pablo Ruiz García and NVIDIA Project Vanessa. CVE-2026-49300
|
||||
|
||||
Bugfix
|
||||
* Fix a TLS 1.2 regression that caused clients to reject valid
|
||||
ServerKeyExchange signatures using RSA-PSS signature algorithms.
|
||||
Fixes #10668.
|
||||
* Fix a problem in library/alignment.h where the Zephyr Project use
|
||||
a pre-defined macro '__packed' which collides with the IAR keyword
|
||||
'__packed', causing the typedefs of unaligned types to remain aligned.
|
||||
Fixes mbedtls issue #10334
|
||||
* Reject malformed TLS 1.3 serialized sessions instead of accepting
|
||||
unterminated strings or extra trailing data.
|
||||
* Reject serialized SSL contexts whose DTLS Connection ID length exceeds
|
||||
the maximum supported size, instead of overflowing the internal buffer.
|
||||
* Fix bug in configurations with MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED that
|
||||
prevented re-use of an mbedtls_ecdh_context for static ECDH: our secret key
|
||||
was wiped after its first use to compute a shared secret.
|
||||
* Fixed documentation of mbedtls_ssl_set_cid(): the set CID configuration
|
||||
is applied to all subsequent handshakes, not just to the next one.
|
||||
* Reject malformed X.509 CSRs where the extensionRequest attribute
|
||||
wrappers do not exactly contain the requested extensions.
|
||||
|
||||
Changes
|
||||
* X.509 certificates with a basicConstraints extension starting with an
|
||||
INTEGER field are no longer accepted. According to RFC 5280, such
|
||||
certificates are syntactically valid and the first field is the
|
||||
pathLenConstraint value, but certificate authorities must not emit such
|
||||
certificates. Mbed TLS interpreted it as a cA value, which was nonstandard
|
||||
and dangerous.
|
||||
|
||||
= Mbed TLS 3.6.6 branch released 2026-03-31
|
||||
|
||||
Features
|
||||
|
||||
@ -1,4 +0,0 @@
|
||||
Bugfix
|
||||
* Fix a TLS 1.2 regression that caused clients to reject valid
|
||||
ServerKeyExchange signatures using RSA-PSS signature algorithms.
|
||||
Fixes #10668.
|
||||
@ -1,6 +0,0 @@
|
||||
Bugfix
|
||||
* Fix a problem in library/alignment.h where the Zephyr Project use
|
||||
a pre-defined macro '__packed' which collides with the IAR keyword
|
||||
'__packed', causing the typedefs of unaligned types to remain aligned.
|
||||
Fixes mbedtls issue #10334
|
||||
|
||||
@ -1,2 +0,0 @@
|
||||
Security
|
||||
* Added advice about compiler options in SECURITY.md.
|
||||
@ -1,5 +0,0 @@
|
||||
Bugfix
|
||||
* Reject malformed TLS 1.3 serialized sessions instead of accepting
|
||||
unterminated strings or extra trailing data.
|
||||
* Reject serialized SSL contexts whose DTLS Connection ID length exceeds
|
||||
the maximum supported size, instead of overflowing the internal buffer.
|
||||
2
Makefile
2
Makefile
@ -71,7 +71,7 @@ generated_files: visualc_files
|
||||
# that lacks some of the necessary tools to re-generate the files.
|
||||
# If $(GEN_FILES) is non-empty, the generated source files' dependencies
|
||||
# are treated ordinarily, based on file timestamps.
|
||||
GEN_FILES ?= yes
|
||||
GEN_FILES ?=
|
||||
|
||||
# In dependencies where the target is a configuration-independent generated
|
||||
# file, use `TARGET: $(gen_file_dep) DEPENDENCY1 DEPENDENCY2 ...`
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
*/
|
||||
|
||||
/**
|
||||
* @mainpage Mbed TLS v3.6.6 API Documentation
|
||||
* @mainpage Mbed TLS v3.6.7 API Documentation
|
||||
*
|
||||
* This documentation describes the internal structure of Mbed TLS. It was
|
||||
* automatically generated from specially formatted comment blocks in
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
PROJECT_NAME = "Mbed TLS v3.6.6"
|
||||
PROJECT_NAME = "Mbed TLS v3.6.7"
|
||||
OUTPUT_DIRECTORY = ../apidoc/
|
||||
FULL_PATH_NAMES = NO
|
||||
OPTIMIZE_OUTPUT_FOR_C = YES
|
||||
|
||||
@ -1 +1 @@
|
||||
Subproject commit e79f4fdd4877e79a92e6b1e5965132ff0c5cc729
|
||||
Subproject commit dde0c4a0e448a0552f18817dcea633bb851fd288
|
||||
@ -26,16 +26,16 @@
|
||||
*/
|
||||
#define MBEDTLS_VERSION_MAJOR 3
|
||||
#define MBEDTLS_VERSION_MINOR 6
|
||||
#define MBEDTLS_VERSION_PATCH 6
|
||||
#define MBEDTLS_VERSION_PATCH 7
|
||||
|
||||
/**
|
||||
* The single version number has the following structure:
|
||||
* MMNNPP00
|
||||
* Major version | Minor version | Patch version
|
||||
*/
|
||||
#define MBEDTLS_VERSION_NUMBER 0x03060600
|
||||
#define MBEDTLS_VERSION_STRING "3.6.6"
|
||||
#define MBEDTLS_VERSION_STRING_FULL "Mbed TLS 3.6.6"
|
||||
#define MBEDTLS_VERSION_NUMBER 0x03060700
|
||||
#define MBEDTLS_VERSION_STRING "3.6.7"
|
||||
#define MBEDTLS_VERSION_STRING_FULL "Mbed TLS 3.6.7"
|
||||
|
||||
/* Macros for build-time platform detection */
|
||||
|
||||
|
||||
@ -38,7 +38,8 @@ extern "C" {
|
||||
typedef struct mbedtls_chacha20_context {
|
||||
uint32_t MBEDTLS_PRIVATE(state)[16]; /*! The state (before round operations). */
|
||||
uint8_t MBEDTLS_PRIVATE(keystream8)[64]; /*! Leftover keystream bytes. */
|
||||
size_t MBEDTLS_PRIVATE(keystream_bytes_used); /*! Number of keystream bytes already used. */
|
||||
size_t MBEDTLS_PRIVATE(keystream_bytes_used); /*! Number of keystream bytes already used,
|
||||
* or an internal sentinel value. */
|
||||
}
|
||||
mbedtls_chacha20_context;
|
||||
|
||||
@ -143,6 +144,9 @@ int mbedtls_chacha20_starts(mbedtls_chacha20_context *ctx,
|
||||
* This pointer can be \c NULL if `size == 0`.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA
|
||||
* if processing \p size bytes would make the 32-bit block
|
||||
* counter wrap.
|
||||
* \return A negative error code on failure.
|
||||
*/
|
||||
int mbedtls_chacha20_update(mbedtls_chacha20_context *ctx,
|
||||
@ -176,6 +180,9 @@ int mbedtls_chacha20_update(mbedtls_chacha20_context *ctx,
|
||||
* This pointer can be \c NULL if `size == 0`.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA
|
||||
* if processing \p size bytes would make the 32-bit block
|
||||
* counter wrap.
|
||||
* \return A negative error code on failure.
|
||||
*/
|
||||
int mbedtls_chacha20_crypt(const unsigned char key[32],
|
||||
|
||||
@ -227,6 +227,9 @@ int mbedtls_chachapoly_update_aad(mbedtls_chachapoly_context *ctx,
|
||||
* \return #MBEDTLS_ERR_CHACHAPOLY_BAD_STATE
|
||||
* if the operation has not been started or has been
|
||||
* finished.
|
||||
* \return #MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA
|
||||
* if processing \p len bytes would make the 32-bit block
|
||||
* counter wrap.
|
||||
* \return Another negative error code on other kinds of failure.
|
||||
*/
|
||||
int mbedtls_chachapoly_update(mbedtls_chachapoly_context *ctx,
|
||||
@ -280,6 +283,9 @@ int mbedtls_chachapoly_finish(mbedtls_chachapoly_context *ctx,
|
||||
* is written. This must not be \c NULL.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA
|
||||
* if processing \p length bytes would make the 32-bit block
|
||||
* counter wrap.
|
||||
* \return A negative error code on failure.
|
||||
*/
|
||||
int mbedtls_chachapoly_encrypt_and_tag(mbedtls_chachapoly_context *ctx,
|
||||
@ -314,6 +320,9 @@ int mbedtls_chachapoly_encrypt_and_tag(mbedtls_chachapoly_context *ctx,
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_CHACHAPOLY_AUTH_FAILED
|
||||
* if the data was not authentic.
|
||||
* \return #MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA
|
||||
* if processing \p length bytes would make the 32-bit block
|
||||
* counter wrap.
|
||||
* \return Another negative error code on other kinds of failure.
|
||||
*/
|
||||
int mbedtls_chachapoly_auth_decrypt(mbedtls_chachapoly_context *ctx,
|
||||
|
||||
@ -416,6 +416,7 @@ int mbedtls_ecdh_read_public(mbedtls_ecdh_context *ctx,
|
||||
* Bytes written on success. This must not be \c NULL.
|
||||
* \param buf The buffer to write the generated shared key to. This
|
||||
* must be a writable buffer of size \p blen Bytes.
|
||||
* A sufficient size is given by #MBEDTLS_ECP_MAX_BYTES.
|
||||
* \param blen The length of the destination buffer \p buf in Bytes.
|
||||
* \param f_rng The RNG function to use. This must not be \c NULL.
|
||||
* \param p_rng The RNG context. This may be \c NULL if \p f_rng
|
||||
|
||||
@ -213,22 +213,11 @@ mbedtls_ecp_point;
|
||||
*
|
||||
* If \p modp is NULL, reduction modulo \p P is done using a generic algorithm.
|
||||
* Otherwise, \p modp must point to a function that takes an \p mbedtls_mpi in the
|
||||
* range of <code>0..2^(2*pbits)-1</code>, and transforms it in-place to an integer
|
||||
* which is congruent mod \p P to the given MPI, and is close enough to \p pbits
|
||||
* in size, so that it may be efficiently brought in the 0..P-1 range by a few
|
||||
* additions or subtractions. Therefore, it is only an approximate modular
|
||||
* reduction. It must return 0 on success and non-zero on failure.
|
||||
*
|
||||
* \note Alternative implementations of the ECP module must obey the
|
||||
* following constraints.
|
||||
* * Group IDs must be distinct: if two group structures have
|
||||
* the same ID, then they must be identical.
|
||||
* * The fields \c id, \c P, \c A, \c B, \c G, \c N,
|
||||
* \c pbits and \c nbits must have the same type and semantics
|
||||
* as in the built-in implementation.
|
||||
* They must be available for reading, but direct modification
|
||||
* of these fields does not need to be supported.
|
||||
* They do not need to be at the same offset in the structure.
|
||||
* range of [0, 2^(2*pbits)), and transforms it in-place to an integer which is
|
||||
* congruent mod \p P to the given MPI, is in the range [0, 2P), and has no more
|
||||
* non-zero limbs than P, so that it may be efficiently brought into the range
|
||||
* [0, P) by a single constant-time conditional subtraction.
|
||||
* It must return 0 on success and non-zero on failure.
|
||||
*/
|
||||
typedef struct mbedtls_ecp_group {
|
||||
mbedtls_ecp_group_id id; /*!< An internal group identifier. */
|
||||
@ -248,7 +237,7 @@ typedef struct mbedtls_ecp_group {
|
||||
private keys. */
|
||||
/* End of public fields */
|
||||
|
||||
unsigned int MBEDTLS_PRIVATE(h); /*!< \internal 1 if the constants are static. */
|
||||
unsigned int MBEDTLS_PRIVATE(h); /*!< \internal 1 if all the constants are static, 2 if only N and P are static */
|
||||
int(*MBEDTLS_PRIVATE(modp))(mbedtls_mpi *); /*!< The function for fast pseudo-reduction
|
||||
mod \p P (see above).*/
|
||||
int(*MBEDTLS_PRIVATE(t_pre))(mbedtls_ecp_point *, void *); /*!< Unused. */
|
||||
|
||||
@ -3248,6 +3248,15 @@
|
||||
*/
|
||||
#define MBEDTLS_PKCS7_C
|
||||
|
||||
/**
|
||||
* \def MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
*
|
||||
* Allow weak signature algorithms (RIPEMD160, MD5, SHA-1) in PKCS#7.
|
||||
*
|
||||
* Requires: MBEDTLS_PKCS7_C
|
||||
*/
|
||||
// #define MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
|
||||
/**
|
||||
* \def MBEDTLS_PKCS12_C
|
||||
*
|
||||
|
||||
@ -930,6 +930,15 @@ int mbedtls_pk_sign_restartable(mbedtls_pk_context *ctx,
|
||||
/**
|
||||
* \brief Decrypt message (including padding if relevant).
|
||||
*
|
||||
* \warning When using PKCS#1 v1.5 (see note below), this is an
|
||||
* inherently dangerous function (CWE-242) and the return value
|
||||
* is sensitive, see mbedtls_rsa_rsaes_pkcs1_v15_decrypt().
|
||||
*
|
||||
* \note For keys of type #MBEDTLS_PK_RSA, the encryption algorithm is
|
||||
* either PKCS#1 v1.5 or OAEP, depending on the padding mode in
|
||||
* the underlying RSA context. For a pk object constructed by
|
||||
* parsing, this is PKCS#1 v1.5 by default.
|
||||
*
|
||||
* \param ctx The PK context to use. It must have been set up
|
||||
* with a private key.
|
||||
* \param input Input to decrypt
|
||||
@ -940,11 +949,6 @@ int mbedtls_pk_sign_restartable(mbedtls_pk_context *ctx,
|
||||
* \param f_rng RNG function, must not be \c NULL.
|
||||
* \param p_rng RNG parameter
|
||||
*
|
||||
* \note For keys of type #MBEDTLS_PK_RSA, the signature algorithm is
|
||||
* either PKCS#1 v1.5 or OAEP, depending on the padding mode in
|
||||
* the underlying RSA context. For a pk object constructed by
|
||||
* parsing, this is PKCS#1 v1.5 by default.
|
||||
*
|
||||
* \return 0 on success, or a specific error code.
|
||||
*/
|
||||
int mbedtls_pk_decrypt(mbedtls_pk_context *ctx,
|
||||
|
||||
@ -31,6 +31,12 @@
|
||||
* assumed these fields are empty.
|
||||
* - The RFC allows for the signed Data type to contain contentInfo. This
|
||||
* implementation assumes the type is DATA and the content is empty.
|
||||
* - The RFC doesn't put any constrain on the hash algorithm to be used, but
|
||||
* this implementation by default rejects weak hash algorithms (i.e. RIPEMD160,
|
||||
* MD5, SHA-1, SHA-224, SHA3-224). In general accepted hash algorithms
|
||||
* are the ones belonging to ::mbedtls_x509_crt_profile_default.
|
||||
* #MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES can be enabled to accept all
|
||||
* supported hash algorithms.
|
||||
*/
|
||||
|
||||
#ifndef MBEDTLS_PKCS7_H
|
||||
@ -190,6 +196,9 @@ int mbedtls_pkcs7_parse_der(mbedtls_pkcs7 *pkcs7, const unsigned char *buf,
|
||||
* \note This function internally calculates the hash on the supplied
|
||||
* plain data for signature verification.
|
||||
*
|
||||
* \note For limitation on the supported hash algorithms, please refer
|
||||
* to the note at the top of this document.
|
||||
*
|
||||
* \return 0 if the signature verifies, or a negative error code on failure.
|
||||
*/
|
||||
int mbedtls_pkcs7_signed_data_verify(mbedtls_pkcs7 *pkcs7,
|
||||
@ -219,6 +228,9 @@ int mbedtls_pkcs7_signed_data_verify(mbedtls_pkcs7 *pkcs7,
|
||||
* \note This function is different from mbedtls_pkcs7_signed_data_verify()
|
||||
* in that it is directly passed the hash of the data.
|
||||
*
|
||||
* \note For limitation on the supported hash algorithms, please refer
|
||||
* to the note at the top of this document.
|
||||
*
|
||||
* \return 0 if the signature verifies, or a negative error code on failure.
|
||||
*/
|
||||
int mbedtls_pkcs7_signed_hash_verify(mbedtls_pkcs7 *pkcs7,
|
||||
|
||||
@ -696,7 +696,9 @@ int mbedtls_rsa_rsaes_oaep_encrypt(mbedtls_rsa_context *ctx,
|
||||
*
|
||||
* \warning When \p ctx->padding is set to #MBEDTLS_RSA_PKCS_V15,
|
||||
* mbedtls_rsa_rsaes_pkcs1_v15_decrypt() is called, which is an
|
||||
* inherently dangerous function (CWE-242).
|
||||
* inherently dangerous function (CWE-242). In that case, the
|
||||
* return value of this function is sensitive, see the
|
||||
* documentation of mbedtls_rsa_rsaes_pkcs1_v15_decrypt().
|
||||
*
|
||||
* \note The output buffer length \c output_max_len should be
|
||||
* as large as the size \p ctx->len of \p ctx->N (for example,
|
||||
@ -735,9 +737,13 @@ int mbedtls_rsa_pkcs1_decrypt(mbedtls_rsa_context *ctx,
|
||||
* operation (RSAES-PKCS1-v1_5-DECRYPT).
|
||||
*
|
||||
* \warning This is an inherently dangerous function (CWE-242). Unless
|
||||
* it is used in a side channel free and safe way (eg.
|
||||
* implementing the TLS protocol as per 7.4.7.1 of RFC 5246),
|
||||
* it is used in a side channel free and safe way,
|
||||
* the calling code is vulnerable.
|
||||
* Specifically, callers need to ensure an adversary cannot
|
||||
* distinguish between success, MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
* and MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE. Also, in the latter two
|
||||
* cases, the values of the output bytes must be ignored, again
|
||||
* without revealing whether that's the case.
|
||||
*
|
||||
* \note The output buffer length \c output_max_len should be
|
||||
* as large as the size \p ctx->len of \p ctx->N, for example,
|
||||
|
||||
@ -2344,7 +2344,7 @@ void mbedtls_ssl_set_bio(mbedtls_ssl_context *ssl,
|
||||
|
||||
/**
|
||||
* \brief Configure the use of the Connection ID (CID)
|
||||
* extension in the next handshake.
|
||||
* extension in subsequent handshakes.
|
||||
*
|
||||
* Reference: RFC 9146 (or draft-ietf-tls-dtls-connection-id-05
|
||||
* https://tools.ietf.org/html/draft-ietf-tls-dtls-connection-id-05
|
||||
@ -2365,7 +2365,7 @@ void mbedtls_ssl_set_bio(mbedtls_ssl_context *ssl,
|
||||
* headers of outgoing messages.
|
||||
*
|
||||
* This API enables or disables the use of the CID extension
|
||||
* in the next handshake and sets the value of the CID to
|
||||
* in subsequent handshakes and sets the value of the CID to
|
||||
* be used for incoming messages.
|
||||
*
|
||||
* \param ssl The SSL context to configure. This must be initialized.
|
||||
@ -2396,11 +2396,11 @@ void mbedtls_ssl_set_bio(mbedtls_ssl_context *ssl,
|
||||
* successful call to this function to run the handshake.
|
||||
*
|
||||
* \note This call cannot guarantee that the use of the CID
|
||||
* will be successfully negotiated in the next handshake,
|
||||
* will be successfully negotiated in subsequent handshakes,
|
||||
* because the peer might not support it. Specifically:
|
||||
* - On the Client, enabling the use of the CID through
|
||||
* this call implies that the `ClientHello` in the next
|
||||
* handshake will include the CID extension, thereby
|
||||
* this call implies that the `ClientHello` in subsequent
|
||||
* handshakes will include the CID extension, thereby
|
||||
* offering the use of the CID to the server. Only if
|
||||
* the `ServerHello` contains the CID extension, too,
|
||||
* the CID extension will actually be put to use.
|
||||
@ -2423,7 +2423,7 @@ void mbedtls_ssl_set_bio(mbedtls_ssl_context *ssl,
|
||||
* Mbed TLS.
|
||||
*
|
||||
* \return \c 0 on success. In this case, the CID configuration
|
||||
* applies to the next handshake.
|
||||
* applies to subsequent handshakes.
|
||||
* \return A negative error code on failure.
|
||||
*/
|
||||
int mbedtls_ssl_set_cid(mbedtls_ssl_context *ssl,
|
||||
@ -3594,7 +3594,7 @@ int mbedtls_ssl_conf_cid(mbedtls_ssl_config *conf, size_t len,
|
||||
*
|
||||
* \note The restrictions are enforced for all certificates in the
|
||||
* chain. However, signatures in the handshake are not covered
|
||||
* by this setting but by \b mbedtls_ssl_conf_sig_hashes().
|
||||
* by this setting but by \c mbedtls_ssl_conf_sig_hashes().
|
||||
*
|
||||
* \param conf SSL configuration
|
||||
* \param profile Profile to use
|
||||
@ -4075,7 +4075,12 @@ void MBEDTLS_DEPRECATED mbedtls_ssl_conf_sig_hashes(mbedtls_ssl_config *conf,
|
||||
#endif /* !MBEDTLS_DEPRECATED_REMOVED && MBEDTLS_SSL_PROTO_TLS1_2 */
|
||||
|
||||
/**
|
||||
* \brief Configure allowed signature algorithms for use in TLS
|
||||
* \brief Configure allowed signature algorithms for use in TLS key
|
||||
* exchange.
|
||||
*
|
||||
* \note This only covers signature algorithms used in the key
|
||||
* exchange. To also enforce restrictions in certificate verification
|
||||
* refer to \c mbedtls_ssl_conf_cert_profile().
|
||||
*
|
||||
* \param conf The SSL configuration to use.
|
||||
* \param sig_algs List of allowed IANA values for TLS 1.3 signature algorithms,
|
||||
|
||||
@ -2073,6 +2073,8 @@ psa_status_t psa_cipher_abort(psa_cipher_operation_t *operation);
|
||||
* \param[in] plaintext Data that will be authenticated and
|
||||
* encrypted.
|
||||
* \param plaintext_length Size of \p plaintext in bytes.
|
||||
* For #PSA_ALG_CHACHA20_POLY1305, this must
|
||||
* not exceed `UINT32_MAX * 64` bytes.
|
||||
* \param[out] ciphertext Output buffer for the authenticated and
|
||||
* encrypted data. The additional data is not
|
||||
* part of this output. For algorithms where the
|
||||
@ -2099,7 +2101,8 @@ psa_status_t psa_cipher_abort(psa_cipher_operation_t *operation);
|
||||
* \retval #PSA_ERROR_INVALID_HANDLE \emptydescription
|
||||
* \retval #PSA_ERROR_NOT_PERMITTED \emptydescription
|
||||
* \retval #PSA_ERROR_INVALID_ARGUMENT
|
||||
* \p key is not compatible with \p alg.
|
||||
* \p key is not compatible with \p alg, or \p plaintext_length
|
||||
* is not acceptable for \p alg.
|
||||
* \retval #PSA_ERROR_NOT_SUPPORTED
|
||||
* \p alg is not supported or is not an AEAD algorithm.
|
||||
* \retval #PSA_ERROR_INSUFFICIENT_MEMORY \emptydescription
|
||||
@ -2150,6 +2153,10 @@ psa_status_t psa_aead_encrypt(mbedtls_svc_key_id_t key,
|
||||
* must contain the encrypted data followed
|
||||
* by the authentication tag.
|
||||
* \param ciphertext_length Size of \p ciphertext in bytes.
|
||||
* For #PSA_ALG_CHACHA20_POLY1305, the
|
||||
* encrypted data length, excluding the
|
||||
* authentication tag, must not exceed
|
||||
* `UINT32_MAX * 64` bytes.
|
||||
* \param[out] plaintext Output buffer for the decrypted data.
|
||||
* \param plaintext_size Size of the \p plaintext buffer in bytes.
|
||||
* This must be appropriate for the selected
|
||||
@ -2172,7 +2179,8 @@ psa_status_t psa_aead_encrypt(mbedtls_svc_key_id_t key,
|
||||
* The ciphertext is not authentic.
|
||||
* \retval #PSA_ERROR_NOT_PERMITTED \emptydescription
|
||||
* \retval #PSA_ERROR_INVALID_ARGUMENT
|
||||
* \p key is not compatible with \p alg.
|
||||
* \p key is not compatible with \p alg, or the encrypted data length
|
||||
* is not acceptable for \p alg.
|
||||
* \retval #PSA_ERROR_NOT_SUPPORTED
|
||||
* \p alg is not supported or is not an AEAD algorithm.
|
||||
* \retval #PSA_ERROR_INSUFFICIENT_MEMORY \emptydescription
|
||||
@ -2470,6 +2478,8 @@ psa_status_t psa_aead_set_nonce(psa_aead_operation_t *operation,
|
||||
* psa_aead_set_nonce() or psa_aead_generate_nonce().
|
||||
*
|
||||
* - For #PSA_ALG_CCM, calling this function is required.
|
||||
* - For #PSA_ALG_CHACHA20_POLY1305, the plaintext length must not
|
||||
* exceed `UINT32_MAX * 64` bytes.
|
||||
* - For the other AEAD algorithms defined in this specification, calling
|
||||
* this function is not required.
|
||||
* - For vendor-defined algorithm, refer to the vendor documentation.
|
||||
@ -2618,7 +2628,8 @@ psa_status_t psa_aead_update_ad(psa_aead_operation_t *operation,
|
||||
* less than the additional data length that was previously
|
||||
* specified with psa_aead_set_lengths(), or
|
||||
* the total input length overflows the plaintext length that
|
||||
* was previously specified with psa_aead_set_lengths().
|
||||
* was previously specified with psa_aead_set_lengths(), or
|
||||
* the total message length is not acceptable for the algorithm.
|
||||
* \retval #PSA_ERROR_INSUFFICIENT_MEMORY \emptydescription
|
||||
* \retval #PSA_ERROR_COMMUNICATION_FAILURE \emptydescription
|
||||
* \retval #PSA_ERROR_HARDWARE_FAILURE \emptydescription
|
||||
@ -3125,6 +3136,16 @@ psa_status_t psa_asymmetric_encrypt(mbedtls_svc_key_id_t key,
|
||||
/**
|
||||
* \brief Decrypt a short message with a private key.
|
||||
*
|
||||
* \warning When \p alg is #PSA_ALG_RSA_PKCS1V15_CRYPT, this is an
|
||||
* inherently dangerous function (CWE-242): unless it is used
|
||||
* in a side channel free and safe way, the calling code
|
||||
* is vulnerable.
|
||||
* Specifically, callers need to ensure an adversary cannot
|
||||
* distinguish between success, #PSA_ERROR_INVALID_PADDING and
|
||||
* #PSA_ERROR_BUFFER_TOO_SMALL. Also, in the latter two cases,
|
||||
* the values of the output bytes must be ignored, again
|
||||
* without revealing whether that's the case.
|
||||
*
|
||||
* \param key Identifier of the key to use for the operation.
|
||||
* It must be an asymmetric key pair. It must
|
||||
* allow the usage #PSA_KEY_USAGE_DECRYPT.
|
||||
|
||||
@ -1760,8 +1760,7 @@
|
||||
* \warning Calling psa_asymmetric_decrypt() with this algorithm as a
|
||||
* parameter is considered an inherently dangerous function
|
||||
* (CWE-242). Unless it is used in a side channel free and safe
|
||||
* way (eg. implementing the TLS protocol as per 7.4.7.1 of
|
||||
* RFC 5246), the calling code is vulnerable.
|
||||
* way, the calling code is vulnerable.
|
||||
*
|
||||
*/
|
||||
#define PSA_ALG_RSA_PKCS1V15_CRYPT ((psa_algorithm_t) 0x07000200)
|
||||
|
||||
14
library/.gitignore
vendored
14
library/.gitignore
vendored
@ -2,10 +2,10 @@ libmbed*
|
||||
*.sln
|
||||
*.vcxproj
|
||||
|
||||
###START_GENERATED_FILES###
|
||||
/error.c
|
||||
/version_features.c
|
||||
/ssl_debug_helpers_generated.c
|
||||
/psa_crypto_driver_wrappers.h
|
||||
/psa_crypto_driver_wrappers_no_static.c
|
||||
###END_GENERATED_FILES###
|
||||
####START_COMMENTED_GENERATED_FILES###
|
||||
#/error.c
|
||||
#/version_features.c
|
||||
#/ssl_debug_helpers_generated.c
|
||||
#/psa_crypto_driver_wrappers.h
|
||||
#/psa_crypto_driver_wrappers_no_static.c
|
||||
####END_COMMENTED_GENERATED_FILES###
|
||||
|
||||
@ -39,7 +39,6 @@ set(src_crypto
|
||||
ecjpake.c
|
||||
ecp.c
|
||||
ecp_curves.c
|
||||
ecp_curves_new.c
|
||||
entropy.c
|
||||
entropy_poll.c
|
||||
error.c
|
||||
@ -314,7 +313,7 @@ endif(USE_STATIC_MBEDTLS_LIBRARY)
|
||||
if(USE_SHARED_MBEDTLS_LIBRARY)
|
||||
set(CMAKE_LIBRARY_PATH ${CMAKE_CURRENT_BINARY_DIR})
|
||||
add_library(${mbedcrypto_target} SHARED ${src_crypto})
|
||||
set_target_properties(${mbedcrypto_target} PROPERTIES VERSION 3.6.6 SOVERSION 16)
|
||||
set_target_properties(${mbedcrypto_target} PROPERTIES VERSION 3.6.7 SOVERSION 16)
|
||||
target_link_libraries(${mbedcrypto_target} PUBLIC ${libs})
|
||||
|
||||
if(TARGET ${everest_target})
|
||||
@ -326,11 +325,11 @@ if(USE_SHARED_MBEDTLS_LIBRARY)
|
||||
endif()
|
||||
|
||||
add_library(${mbedx509_target} SHARED ${src_x509})
|
||||
set_target_properties(${mbedx509_target} PROPERTIES VERSION 3.6.6 SOVERSION 7)
|
||||
set_target_properties(${mbedx509_target} PROPERTIES VERSION 3.6.7 SOVERSION 7)
|
||||
target_link_libraries(${mbedx509_target} PUBLIC ${libs} ${mbedcrypto_target})
|
||||
|
||||
add_library(${mbedtls_target} SHARED ${src_tls})
|
||||
set_target_properties(${mbedtls_target} PROPERTIES VERSION 3.6.6 SOVERSION 21)
|
||||
set_target_properties(${mbedtls_target} PROPERTIES VERSION 3.6.7 SOVERSION 21)
|
||||
target_link_libraries(${mbedtls_target} PUBLIC ${libs} ${mbedx509_target})
|
||||
|
||||
if(GEN_FILES)
|
||||
|
||||
@ -131,7 +131,6 @@ OBJS_CRYPTO= \
|
||||
ecjpake.o \
|
||||
ecp.o \
|
||||
ecp_curves.o \
|
||||
ecp_curves_new.o \
|
||||
entropy.o \
|
||||
entropy_poll.o \
|
||||
error.o \
|
||||
@ -346,7 +345,7 @@ libmbedcrypto.dll: $(OBJS_CRYPTO)
|
||||
generated_files: $(GENERATED_FILES)
|
||||
|
||||
# See root Makefile
|
||||
GEN_FILES ?= yes
|
||||
GEN_FILES ?=
|
||||
ifdef GEN_FILES
|
||||
gen_file_dep =
|
||||
else
|
||||
|
||||
@ -2059,30 +2059,38 @@ int mbedtls_mpi_inv_mod(mbedtls_mpi *X, const mbedtls_mpi *A, const mbedtls_mpi
|
||||
|
||||
#if defined(MBEDTLS_GENPRIME)
|
||||
|
||||
/* Gaps between primes, starting at 3. https://oeis.org/A001223 */
|
||||
static const unsigned char small_prime_gaps[] = {
|
||||
2, 2, 4, 2, 4, 2, 4, 6,
|
||||
2, 6, 4, 2, 4, 6, 6, 2,
|
||||
6, 4, 2, 6, 4, 6, 8, 4,
|
||||
2, 4, 2, 4, 14, 4, 6, 2,
|
||||
10, 2, 6, 6, 4, 6, 6, 2,
|
||||
10, 2, 4, 2, 12, 12, 4, 2,
|
||||
4, 6, 2, 10, 6, 6, 6, 2,
|
||||
6, 4, 2, 10, 14, 4, 2, 4,
|
||||
14, 6, 10, 2, 4, 6, 8, 6,
|
||||
6, 4, 6, 8, 4, 8, 10, 2,
|
||||
10, 2, 6, 4, 6, 8, 4, 2,
|
||||
4, 12, 8, 4, 8, 4, 6, 12,
|
||||
2, 18, 6, 10, 6, 6, 2, 6,
|
||||
10, 6, 6, 2, 6, 6, 4, 2,
|
||||
12, 10, 2, 4, 6, 6, 2, 12,
|
||||
4, 6, 8, 10, 8, 10, 8, 6,
|
||||
6, 4, 8, 6, 4, 8, 4, 14,
|
||||
10, 12, 2, 10, 2, 4, 2, 10,
|
||||
14, 4, 2, 4, 14, 4, 2, 4,
|
||||
20, 4, 8, 10, 8, 4, 6, 6,
|
||||
14, 4, 6, 6, 8, 6, /*reaches 997*/
|
||||
0 /* the last entry is effectively unused */
|
||||
static const mbedtls_mpi_sint small_primes_limit = 997;
|
||||
/* Product of small primes up to small_primes_limit included */
|
||||
static const mbedtls_mpi_uint small_primes_product_limbs[] = {
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x4b, 0x13, 0x6a, 0x97, 0xbb, 0xd0, 0xdf, 0x95),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xa7, 0x2c, 0x10, 0xa4, 0x20, 0xa4, 0x9f, 0x7b),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x9d, 0x18, 0xd6, 0xdf, 0xc0, 0xf5, 0x61, 0x65),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xfc, 0x35, 0x79, 0xfb, 0x30, 0xa8, 0xd5, 0xbf),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xdb, 0x37, 0xba, 0x2c, 0xfb, 0xbb, 0x89, 0xfb),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xad, 0xc2, 0x8c, 0x1d, 0x99, 0x18, 0xe8, 0xe5),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x8d, 0x77, 0xc9, 0x5d, 0x96, 0x8a, 0x61, 0x9d),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x39, 0x41, 0x3e, 0xf4, 0x34, 0x07, 0x57, 0xe0),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x4a, 0xf1, 0x54, 0x3a, 0x43, 0x67, 0x46, 0xa2),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x83, 0x0c, 0xe5, 0x31, 0xa2, 0xfc, 0x05, 0x45),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xf0, 0x1d, 0x66, 0xfc, 0x7a, 0x85, 0x37, 0xe1),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x17, 0xe0, 0x80, 0x62, 0x0d, 0xa2, 0xbc, 0x32),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x6d, 0xce, 0x84, 0x68, 0x00, 0xb5, 0xe3, 0x35),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x14, 0x19, 0x0d, 0xe4, 0x92, 0xd5, 0xd8, 0xdf),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x20, 0x1c, 0x7d, 0x38, 0x3b, 0xe8, 0xd9, 0xa8),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xf6, 0xac, 0x11, 0xe6, 0xb4, 0x03, 0xf7, 0x6c),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x78, 0x3d, 0xf2, 0x3a, 0x8f, 0xf9, 0x2f, 0x6a),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x7b, 0x72, 0x66, 0xa9, 0x48, 0xe4, 0x6d, 0x02),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x69, 0xc7, 0x32, 0xcb, 0xf2, 0xf7, 0xa9, 0x0b),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xd3, 0x52, 0x72, 0x9d, 0xbf, 0x54, 0xea, 0xc7),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0xf5, 0xf3, 0x8a, 0xc5, 0xf0, 0xe1, 0x21, 0x81),
|
||||
MBEDTLS_BYTES_TO_T_UINT_8(0x8e, 0x61, 0x78, 0xf0, 0x05, 0x00, 0x00, 0x00),
|
||||
};
|
||||
/* Could make ECP_MPI_INIT_ARRAY() available outside ecp, but not doing it now
|
||||
* as it would lead to conflicts with other in-flight PRs. */
|
||||
static const mbedtls_mpi small_primes_product = {
|
||||
.p = (mbedtls_mpi_uint *) small_primes_product_limbs,
|
||||
.s = 1,
|
||||
.n = sizeof(small_primes_product_limbs) / sizeof(mbedtls_mpi_uint),
|
||||
};
|
||||
|
||||
/*
|
||||
@ -2097,26 +2105,43 @@ static const unsigned char small_prime_gaps[] = {
|
||||
static int mpi_check_small_factors(const mbedtls_mpi *X)
|
||||
{
|
||||
int ret = 0;
|
||||
size_t i;
|
||||
mbedtls_mpi_uint r;
|
||||
unsigned p = 3; /* The first odd prime */
|
||||
mbedtls_mpi g;
|
||||
|
||||
mbedtls_mpi_init(&g);
|
||||
|
||||
if ((X->p[0] & 1) == 0) {
|
||||
return MBEDTLS_ERR_MPI_NOT_ACCEPTABLE;
|
||||
}
|
||||
|
||||
for (i = 0; i < sizeof(small_prime_gaps); p += small_prime_gaps[i], i++) {
|
||||
MBEDTLS_MPI_CHK(mbedtls_mpi_mod_int(&r, X, p));
|
||||
if (r == 0) {
|
||||
if (mbedtls_mpi_cmp_int(X, p) == 0) {
|
||||
return 1;
|
||||
} else {
|
||||
return MBEDTLS_ERR_MPI_NOT_ACCEPTABLE;
|
||||
}
|
||||
/* The GCD test below only works if X > small_primes_limit.
|
||||
* Below this limit, use trial division: numbers that small are of no
|
||||
* interest for cryptography, so we don't care about performance or side
|
||||
* channels. We're supporting them only for backwards compatibility, so
|
||||
* let's not waste code size on those. */
|
||||
if (mbedtls_mpi_cmp_int(X, small_primes_limit) <= 0) {
|
||||
mbedtls_mpi_uint x = X->p[0];
|
||||
mbedtls_mpi_uint d = 2;
|
||||
while (x % d != 0) {
|
||||
++d;
|
||||
}
|
||||
return x == d ? 1 : MBEDTLS_ERR_MPI_NOT_ACCEPTABLE;
|
||||
}
|
||||
|
||||
/* We can't directly use mbedtls_mpi_gcd_modinv_odd() because we don't know
|
||||
* if X is larger than prod or not (prod is 1380 bits). So, use this generic
|
||||
* wrapper - it does a bit more than what we need (handles even inputs as
|
||||
* well, while we know our inputs are both odd), but that's OK. */
|
||||
MBEDTLS_MPI_CHK(mbedtls_mpi_gcd(&g, &small_primes_product, X));
|
||||
|
||||
if (mbedtls_mpi_cmp_int(&g, 1) == 0) {
|
||||
/* X is not divisible by a small prime */
|
||||
ret = 0;
|
||||
} else {
|
||||
ret = MBEDTLS_ERR_MPI_NOT_ACCEPTABLE;
|
||||
}
|
||||
|
||||
cleanup:
|
||||
mbedtls_mpi_free(&g);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
@ -4,7 +4,13 @@
|
||||
* This interface should only be used by the legacy bignum module (bignum.h)
|
||||
* and the modular bignum modules (bignum_mod.c, bignum_mod_raw.c). All other
|
||||
* modules should use the high-level modular bignum interface (bignum_mod.h)
|
||||
* or the legacy bignum interface (bignum.h).
|
||||
* or the legacy bignum interface (bignum.h). The only exceptions are:
|
||||
* 1. In ecp_curves.c, some mbedtls_ecp_mod_pXXX_raw() functions are using
|
||||
* bignum_core functions. That's because those functions are implementing a
|
||||
* part of bignum_mod: the optimized reduction in mbedtls_mpi_mod_modulus.
|
||||
* 2. In ecp.c, ecp_modp() is currently using bignum_core, while the rest of
|
||||
* the module is using legacy bignum. That's transitional; eventually ecp.c is
|
||||
* going to use bignum_mod_raw.
|
||||
*
|
||||
* This module is about processing non-negative integers with a fixed upper
|
||||
* bound that's of the form 2^n-1 where n is a multiple of #biL.
|
||||
|
||||
@ -20,6 +20,8 @@
|
||||
#include <stddef.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "chacha20_internal.h"
|
||||
|
||||
#include "mbedtls/platform.h"
|
||||
|
||||
#if !defined(MBEDTLS_CHACHA20_ALT)
|
||||
@ -31,6 +33,10 @@
|
||||
|
||||
#define CHACHA20_BLOCK_SIZE_BYTES (4U * 16U)
|
||||
|
||||
#define CHACHA20_MAX_BLOCKS UINT32_MAX
|
||||
|
||||
#define CHACHA20_COUNTER_EXHAUSTED (CHACHA20_BLOCK_SIZE_BYTES + 1U)
|
||||
|
||||
/**
|
||||
* \brief ChaCha20 quarter round operation.
|
||||
*
|
||||
@ -183,7 +189,7 @@ int mbedtls_chacha20_starts(mbedtls_chacha20_context *ctx,
|
||||
uint32_t counter)
|
||||
{
|
||||
/* Counter */
|
||||
ctx->state[12] = counter;
|
||||
ctx->state[CHACHA20_CTR_INDEX] = counter;
|
||||
|
||||
/* Nonce */
|
||||
ctx->state[13] = MBEDTLS_GET_UINT32_LE(nonce, 0);
|
||||
@ -198,12 +204,63 @@ int mbedtls_chacha20_starts(mbedtls_chacha20_context *ctx,
|
||||
return 0;
|
||||
}
|
||||
|
||||
int mbedtls_chacha20_check_counter_wrap(const mbedtls_chacha20_context *ctx,
|
||||
size_t size)
|
||||
{
|
||||
size_t available_keystream = 0;
|
||||
uint64_t needed_blocks = 0;
|
||||
|
||||
if (ctx->keystream_bytes_used >= CHACHA20_COUNTER_EXHAUSTED) {
|
||||
return size == 0U ? 0 : MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA;
|
||||
}
|
||||
|
||||
#if SIZE_MAX >= UINT64_MAX
|
||||
if (size > UINT64_MAX / 2) {
|
||||
return MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (ctx->keystream_bytes_used < CHACHA20_BLOCK_SIZE_BYTES) {
|
||||
available_keystream =
|
||||
CHACHA20_BLOCK_SIZE_BYTES - ctx->keystream_bytes_used;
|
||||
|
||||
if (size <= available_keystream) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (ctx->state[CHACHA20_CTR_INDEX] == 0U) {
|
||||
return MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA;
|
||||
}
|
||||
|
||||
size -= available_keystream;
|
||||
}
|
||||
|
||||
needed_blocks = (size / CHACHA20_BLOCK_SIZE_BYTES);
|
||||
|
||||
if (size % CHACHA20_BLOCK_SIZE_BYTES != 0U) {
|
||||
needed_blocks++;
|
||||
}
|
||||
|
||||
if (needed_blocks >
|
||||
(uint64_t) CHACHA20_MAX_BLOCKS + 1U - ctx->state[CHACHA20_CTR_INDEX]) {
|
||||
return MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int mbedtls_chacha20_update(mbedtls_chacha20_context *ctx,
|
||||
size_t size,
|
||||
const unsigned char *input,
|
||||
unsigned char *output)
|
||||
{
|
||||
size_t offset = 0U;
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
|
||||
ret = mbedtls_chacha20_check_counter_wrap(ctx, size);
|
||||
if (ret != 0) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* Use leftover keystream bytes, if available */
|
||||
while (size > 0U && ctx->keystream_bytes_used < CHACHA20_BLOCK_SIZE_BYTES) {
|
||||
@ -213,6 +270,11 @@ int mbedtls_chacha20_update(mbedtls_chacha20_context *ctx,
|
||||
ctx->keystream_bytes_used++;
|
||||
offset++;
|
||||
size--;
|
||||
|
||||
if (ctx->keystream_bytes_used == CHACHA20_BLOCK_SIZE_BYTES &&
|
||||
ctx->state[CHACHA20_CTR_INDEX] == 0U) {
|
||||
ctx->keystream_bytes_used = CHACHA20_COUNTER_EXHAUSTED;
|
||||
}
|
||||
}
|
||||
|
||||
/* Process full blocks */
|
||||
@ -225,6 +287,10 @@ int mbedtls_chacha20_update(mbedtls_chacha20_context *ctx,
|
||||
|
||||
offset += CHACHA20_BLOCK_SIZE_BYTES;
|
||||
size -= CHACHA20_BLOCK_SIZE_BYTES;
|
||||
|
||||
if (ctx->state[CHACHA20_CTR_INDEX] == 0U) {
|
||||
ctx->keystream_bytes_used = CHACHA20_COUNTER_EXHAUSTED;
|
||||
}
|
||||
}
|
||||
|
||||
/* Last (partial) block */
|
||||
|
||||
23
library/chacha20_internal.h
Normal file
23
library/chacha20_internal.h
Normal file
@ -0,0 +1,23 @@
|
||||
/**
|
||||
* \file chacha20_internal.h
|
||||
*
|
||||
* \brief Internal declarations for ChaCha20.
|
||||
*/
|
||||
/*
|
||||
* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#ifndef MBEDTLS_CHACHA20_INTERNAL_H
|
||||
#define MBEDTLS_CHACHA20_INTERNAL_H
|
||||
|
||||
#include "common.h"
|
||||
|
||||
#include "mbedtls/chacha20.h"
|
||||
|
||||
#if !defined(MBEDTLS_CHACHA20_ALT)
|
||||
int mbedtls_chacha20_check_counter_wrap(const mbedtls_chacha20_context *ctx,
|
||||
size_t size);
|
||||
#endif /* !MBEDTLS_CHACHA20_ALT */
|
||||
|
||||
#endif /* MBEDTLS_CHACHA20_INTERNAL_H */
|
||||
@ -17,6 +17,8 @@
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "chacha20_internal.h"
|
||||
|
||||
#include "mbedtls/platform.h"
|
||||
|
||||
#if !defined(MBEDTLS_CHACHAPOLY_ALT)
|
||||
@ -165,6 +167,13 @@ int mbedtls_chachapoly_update(mbedtls_chachapoly_context *ctx,
|
||||
return MBEDTLS_ERR_CHACHAPOLY_BAD_STATE;
|
||||
}
|
||||
|
||||
#if !defined(MBEDTLS_CHACHA20_ALT)
|
||||
ret = mbedtls_chacha20_check_counter_wrap(&ctx->chacha20_ctx, len);
|
||||
if (ret != 0) {
|
||||
return ret;
|
||||
}
|
||||
#endif /* !MBEDTLS_CHACHA20_ALT */
|
||||
|
||||
if (ctx->state == CHACHAPOLY_STATE_AAD) {
|
||||
ctx->state = CHACHAPOLY_STATE_CIPHERTEXT;
|
||||
|
||||
|
||||
@ -646,11 +646,13 @@ static int ecdh_calc_secret_internal(mbedtls_ecdh_context_mbed *ctx,
|
||||
}
|
||||
#endif /* MBEDTLS_ECP_RESTARTABLE */
|
||||
|
||||
if (mbedtls_mpi_size(&ctx->z) > blen) {
|
||||
return MBEDTLS_ERR_ECP_BAD_INPUT_DATA;
|
||||
size_t p_bytes = ctx->grp.pbits / 8 + ((ctx->grp.pbits % 8) != 0);
|
||||
|
||||
if (p_bytes > blen) {
|
||||
return MBEDTLS_ERR_ECP_BUFFER_TOO_SMALL;
|
||||
}
|
||||
|
||||
*olen = ctx->grp.pbits / 8 + ((ctx->grp.pbits % 8) != 0);
|
||||
*olen = p_bytes;
|
||||
|
||||
if (mbedtls_ecp_get_type(&ctx->grp) == MBEDTLS_ECP_TYPE_MONTGOMERY) {
|
||||
return mbedtls_mpi_write_binary_le(&ctx->z, buf, *olen);
|
||||
|
||||
@ -69,6 +69,7 @@
|
||||
|
||||
#include "bn_mul.h"
|
||||
#include "bignum_internal.h"
|
||||
#include "bignum_core.h"
|
||||
#include "ecp_invasive.h"
|
||||
|
||||
#include <string.h>
|
||||
@ -582,10 +583,10 @@ void mbedtls_ecp_group_free(mbedtls_ecp_group *grp)
|
||||
mbedtls_mpi_free(&grp->B);
|
||||
mbedtls_ecp_point_free(&grp->G);
|
||||
|
||||
#if !defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
mbedtls_mpi_free(&grp->N);
|
||||
mbedtls_mpi_free(&grp->P);
|
||||
#endif
|
||||
if (grp->h != 2) {
|
||||
mbedtls_mpi_free(&grp->N);
|
||||
mbedtls_mpi_free(&grp->P);
|
||||
}
|
||||
}
|
||||
|
||||
if (!ecp_group_is_static_comb_table(grp) && grp->T != NULL) {
|
||||
@ -1013,15 +1014,11 @@ static int ecp_modp(mbedtls_mpi *N, const mbedtls_ecp_group *grp)
|
||||
|
||||
MBEDTLS_MPI_CHK(grp->modp(N));
|
||||
|
||||
/* N->s < 0 is a much faster test, which fails only if N is 0 */
|
||||
while (N->s < 0 && mbedtls_mpi_cmp_int(N, 0) != 0) {
|
||||
MBEDTLS_MPI_CHK(mbedtls_mpi_add_mpi(N, N, &grp->P));
|
||||
}
|
||||
|
||||
while (mbedtls_mpi_cmp_mpi(N, &grp->P) >= 0) {
|
||||
/* we known P, N and the result are positive */
|
||||
MBEDTLS_MPI_CHK(mbedtls_mpi_sub_abs(N, N, &grp->P));
|
||||
}
|
||||
/* The previous call left N in the range [0, 2P) with no more limbs than P
|
||||
* (see documentation of mbedtls_ecp_mod_pXXX_raw() in ecp_invasive.h),
|
||||
* so we can bring it into the range [0, P) in constant time. */
|
||||
mbedtls_mpi_uint c = mbedtls_mpi_core_sub(N->p, N->p, grp->P.p, grp->P.n);
|
||||
(void) mbedtls_mpi_core_add_if(N->p, grp->P.p, grp->P.n, (unsigned) c);
|
||||
|
||||
cleanup:
|
||||
return ret;
|
||||
|
||||
1573
library/ecp_curves.c
1573
library/ecp_curves.c
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -28,21 +28,8 @@ typedef enum {
|
||||
MBEDTLS_ECP_MOD_SCALAR
|
||||
} mbedtls_ecp_modulus_type;
|
||||
|
||||
typedef enum {
|
||||
MBEDTLS_ECP_VARIANT_NONE = 0,
|
||||
MBEDTLS_ECP_VARIANT_WITH_MPI_STRUCT,
|
||||
MBEDTLS_ECP_VARIANT_WITH_MPI_UINT
|
||||
} mbedtls_ecp_variant;
|
||||
|
||||
#if defined(MBEDTLS_TEST_HOOKS) && defined(MBEDTLS_ECP_LIGHT)
|
||||
|
||||
/** Queries the ecp variant.
|
||||
*
|
||||
* \return The id of the ecp variant.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
mbedtls_ecp_variant mbedtls_ecp_get_variant(void);
|
||||
|
||||
#if defined(MBEDTLS_ECP_MONTGOMERY_ENABLED)
|
||||
/** Generate a private key on a Montgomery curve (Curve25519 or Curve448).
|
||||
*
|
||||
@ -74,7 +61,7 @@ int mbedtls_ecp_gen_privkey_mx(size_t high_bit,
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p192 (FIPS 186-3 D.2.1)
|
||||
/** Fast quasi-reduction modulo p192
|
||||
*
|
||||
* This operation expects a 384 bit MPI and the result of the reduction
|
||||
* is a 192 bit MPI.
|
||||
@ -93,7 +80,7 @@ int mbedtls_ecp_mod_p192_raw(mbedtls_mpi_uint *Np, size_t Nn);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP224R1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p224 (FIPS 186-3 D.2.2)
|
||||
/** Fast quasi-reduction modulo p224
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 448-bit MPI
|
||||
@ -115,7 +102,7 @@ int mbedtls_ecp_mod_p224_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP256R1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p256 (FIPS 186-3 D.2.3)
|
||||
/** Fast quasi-reduction modulo p256
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 512-bit MPI
|
||||
@ -137,7 +124,7 @@ int mbedtls_ecp_mod_p256_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP521R1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p521 = 2^521 - 1 (FIPS 186-3 D.2.5)
|
||||
/** Fast quasi-reduction modulo p521 = 2^521 - 1
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have twice as many limbs as the modulus
|
||||
@ -159,7 +146,7 @@ int mbedtls_ecp_mod_p521_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP384R1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p384 (FIPS 186-3 D.2.4)
|
||||
/** Fast quasi-reduction modulo p384
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 768-bit MPI
|
||||
@ -181,8 +168,7 @@ int mbedtls_ecp_mod_p384_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP192K1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p192k1 = 2^192 - R,
|
||||
* with R = 2^32 + 2^12 + 2^8 + 2^7 + 2^6 + 2^3 + 1 = 0x01000011C9
|
||||
/** Fast quasi-reduction modulo p192k1 = 2^192 - 0x01000011C9
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 384-bit MPI
|
||||
@ -196,7 +182,6 @@ int mbedtls_ecp_mod_p384_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_ECP_BAD_INPUT_DATA if \p X does not have
|
||||
* twice as many limbs as the modulus.
|
||||
* \return #MBEDTLS_ERR_ECP_ALLOC_FAILED if memory allocation failed.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_mod_p192k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
@ -205,8 +190,7 @@ int mbedtls_ecp_mod_p192k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP224K1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p224k1 = 2^224 - R,
|
||||
* with R = 2^32 + 2^12 + 2^11 + 2^9 + 2^7 + 2^4 + 2 + 1 = 0x0100001A93
|
||||
/** Fast quasi-reduction modulo p224k1 = 2^224 - 0x0100001A93
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 448-bit MPI
|
||||
@ -220,7 +204,6 @@ int mbedtls_ecp_mod_p192k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_ECP_BAD_INPUT_DATA if \p X does not have
|
||||
* twice as many limbs as the modulus.
|
||||
* \return #MBEDTLS_ERR_ECP_ALLOC_FAILED if memory allocation failed.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_mod_p224k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
@ -229,8 +212,7 @@ int mbedtls_ecp_mod_p224k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_DP_SECP256K1_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p256k1 = 2^256 - R,
|
||||
* with R = 2^32 + 2^9 + 2^8 + 2^7 + 2^6 + 2^4 + 1 = 0x01000003D1
|
||||
/** Fast quasi-reduction modulo p256k1 = 2^256 - 0x01000003D1
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 512-bit MPI
|
||||
@ -244,7 +226,6 @@ int mbedtls_ecp_mod_p224k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_ECP_BAD_INPUT_DATA if \p X does not have
|
||||
* twice as many limbs as the modulus.
|
||||
* \return #MBEDTLS_ERR_ECP_ALLOC_FAILED if memory allocation failed.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_mod_p256k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
@ -260,12 +241,13 @@ int mbedtls_ecp_mod_p256k1_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
* (double the bitlength of the modulus).
|
||||
* Upon return holds the reduced value which is
|
||||
* in range `0 <= X < 2 * N` (where N is the modulus).
|
||||
* The bitlength of the reduced value is at most 256
|
||||
* (that is, 1 more than that of the modulus).
|
||||
* \param[in] X_limbs The length of \p X in limbs.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_ECP_BAD_INPUT_DATA if \p X does not have
|
||||
* twice as many limbs as the modulus.
|
||||
* \return #MBEDTLS_ERR_ECP_ALLOC_FAILED if memory allocation failed.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_mod_p255_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
@ -275,29 +257,26 @@ int mbedtls_ecp_mod_p255_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
#if defined(MBEDTLS_ECP_DP_CURVE448_ENABLED)
|
||||
|
||||
/** Fast quasi-reduction modulo p448 = 2^448 - 2^224 - 1
|
||||
* Write X as A0 + 2^448 A1 and A1 as B0 + 2^224 B1, and return A0 + A1 + B1 +
|
||||
* (B0 + B1) * 2^224.
|
||||
*
|
||||
* \param[in,out] X The address of the MPI to be converted.
|
||||
* Must have exact limb size that stores a 896-bit MPI
|
||||
* (double the bitlength of the modulus). Upon return
|
||||
* holds the reduced value which is in range `0 <= X <
|
||||
* N` (where N is the modulus). The bitlength of the
|
||||
* reduced value is the same as that of the modulus
|
||||
* (448 bits).
|
||||
* (double the bitlength of the modulus).
|
||||
* Upon return holds the reduced value which is in
|
||||
* range `0 <= X < 2 * N` (where N is the modulus).
|
||||
* The bitlength of the reduced value is the same as
|
||||
* that of the modulus (448 bits).
|
||||
* \param[in] X_limbs The length of \p X in limbs.
|
||||
*
|
||||
* \return \c 0 on Success.
|
||||
* \return #MBEDTLS_ERR_ECP_BAD_INPUT_DATA if \p X does not have
|
||||
* twice as many limbs as the modulus.
|
||||
* \return #MBEDTLS_ERR_ECP_ALLOC_FAILED if memory allocation
|
||||
* failed.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_mod_p448_raw(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#endif /* MBEDTLS_ECP_DP_CURVE448_ENABLED */
|
||||
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
/** Initialise a modulus with hard-coded const curve data.
|
||||
*
|
||||
* \note The caller is responsible for the \p N modulus' memory.
|
||||
@ -319,7 +298,8 @@ MBEDTLS_STATIC_TESTABLE
|
||||
int mbedtls_ecp_modulus_setup(mbedtls_mpi_mod_modulus *N,
|
||||
const mbedtls_ecp_group_id id,
|
||||
const mbedtls_ecp_modulus_type ctype);
|
||||
#endif /* MBEDTLS_ECP_WITH_MPI_UINT */
|
||||
|
||||
#endif /* MBEDTLS_TEST_HOOKS && MBEDTLS_ECP_C */
|
||||
#endif /* MBEDTLS_TEST_HOOKS && MBEDTLS_ECP_LIGHT */
|
||||
|
||||
#endif /* MBEDTLS_ECP_INVASIVE_H */
|
||||
|
||||
878
library/error.c
Normal file
878
library/error.c
Normal file
@ -0,0 +1,878 @@
|
||||
/*
|
||||
* Error message information
|
||||
*
|
||||
* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "common.h"
|
||||
|
||||
#include "mbedtls/error.h"
|
||||
|
||||
#if defined(MBEDTLS_ERROR_C) || defined(MBEDTLS_ERROR_STRERROR_DUMMY)
|
||||
|
||||
#if defined(MBEDTLS_ERROR_C)
|
||||
|
||||
#include "mbedtls/platform.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#if defined(MBEDTLS_AES_C)
|
||||
#include "mbedtls/aes.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_ARIA_C)
|
||||
#include "mbedtls/aria.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_ASN1_PARSE_C)
|
||||
#include "mbedtls/asn1.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_BASE64_C)
|
||||
#include "mbedtls/base64.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_BIGNUM_C)
|
||||
#include "mbedtls/bignum.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CAMELLIA_C)
|
||||
#include "mbedtls/camellia.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CCM_C)
|
||||
#include "mbedtls/ccm.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CHACHA20_C)
|
||||
#include "mbedtls/chacha20.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CHACHAPOLY_C)
|
||||
#include "mbedtls/chachapoly.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CIPHER_C)
|
||||
#include "mbedtls/cipher.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_CTR_DRBG_C)
|
||||
#include "mbedtls/ctr_drbg.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_DES_C)
|
||||
#include "mbedtls/des.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_DHM_C)
|
||||
#include "mbedtls/dhm.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_ECP_C)
|
||||
#include "mbedtls/ecp.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_ENTROPY_C)
|
||||
#include "mbedtls/entropy.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_ERROR_C)
|
||||
#include "mbedtls/error.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PLATFORM_C)
|
||||
#include "mbedtls/platform.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_GCM_C)
|
||||
#include "mbedtls/gcm.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_HKDF_C)
|
||||
#include "mbedtls/hkdf.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_HMAC_DRBG_C)
|
||||
#include "mbedtls/hmac_drbg.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_LMS_C)
|
||||
#include "mbedtls/lms.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_MD_C)
|
||||
#include "mbedtls/md.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_NET_C)
|
||||
#include "mbedtls/net_sockets.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_OID_C)
|
||||
#include "mbedtls/oid.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PEM_PARSE_C) || defined(MBEDTLS_PEM_WRITE_C)
|
||||
#include "mbedtls/pem.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PK_C)
|
||||
#include "mbedtls/pk.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PKCS12_C)
|
||||
#include "mbedtls/pkcs12.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PKCS5_C)
|
||||
#include "mbedtls/pkcs5.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PKCS7_C)
|
||||
#include "mbedtls/pkcs7.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_POLY1305_C)
|
||||
#include "mbedtls/poly1305.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_RSA_C)
|
||||
#include "mbedtls/rsa.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SHA1_C)
|
||||
#include "mbedtls/sha1.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SHA256_C)
|
||||
#include "mbedtls/sha256.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SHA3_C)
|
||||
#include "mbedtls/sha3.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SHA512_C)
|
||||
#include "mbedtls/sha512.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SSL_TLS_C)
|
||||
#include "mbedtls/ssl.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_THREADING_C)
|
||||
#include "mbedtls/threading.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_X509_USE_C) || defined(MBEDTLS_X509_CREATE_C)
|
||||
#include "mbedtls/x509.h"
|
||||
#endif
|
||||
|
||||
|
||||
const char *mbedtls_high_level_strerr(int error_code)
|
||||
{
|
||||
int high_level_error_code;
|
||||
|
||||
if (error_code < 0) {
|
||||
error_code = -error_code;
|
||||
}
|
||||
|
||||
/* Extract the high-level part from the error code. */
|
||||
high_level_error_code = error_code & 0xFF80;
|
||||
|
||||
switch (high_level_error_code) {
|
||||
/* Begin Auto-Generated Code. */
|
||||
#if defined(MBEDTLS_CIPHER_C)
|
||||
case -(MBEDTLS_ERR_CIPHER_FEATURE_UNAVAILABLE):
|
||||
return( "CIPHER - The selected feature is not available" );
|
||||
case -(MBEDTLS_ERR_CIPHER_BAD_INPUT_DATA):
|
||||
return( "CIPHER - Bad input parameters" );
|
||||
case -(MBEDTLS_ERR_CIPHER_ALLOC_FAILED):
|
||||
return( "CIPHER - Failed to allocate memory" );
|
||||
case -(MBEDTLS_ERR_CIPHER_INVALID_PADDING):
|
||||
return( "CIPHER - Input data contains invalid padding and is rejected" );
|
||||
case -(MBEDTLS_ERR_CIPHER_FULL_BLOCK_EXPECTED):
|
||||
return( "CIPHER - Decryption of block requires a full block" );
|
||||
case -(MBEDTLS_ERR_CIPHER_AUTH_FAILED):
|
||||
return( "CIPHER - Authentication failed (for AEAD modes)" );
|
||||
case -(MBEDTLS_ERR_CIPHER_INVALID_CONTEXT):
|
||||
return( "CIPHER - The context is invalid. For example, because it was freed" );
|
||||
#endif /* MBEDTLS_CIPHER_C */
|
||||
|
||||
#if defined(MBEDTLS_DHM_C)
|
||||
case -(MBEDTLS_ERR_DHM_BAD_INPUT_DATA):
|
||||
return( "DHM - Bad input parameters" );
|
||||
case -(MBEDTLS_ERR_DHM_READ_PARAMS_FAILED):
|
||||
return( "DHM - Reading of the DHM parameters failed" );
|
||||
case -(MBEDTLS_ERR_DHM_MAKE_PARAMS_FAILED):
|
||||
return( "DHM - Making of the DHM parameters failed" );
|
||||
case -(MBEDTLS_ERR_DHM_READ_PUBLIC_FAILED):
|
||||
return( "DHM - Reading of the public values failed" );
|
||||
case -(MBEDTLS_ERR_DHM_MAKE_PUBLIC_FAILED):
|
||||
return( "DHM - Making of the public value failed" );
|
||||
case -(MBEDTLS_ERR_DHM_CALC_SECRET_FAILED):
|
||||
return( "DHM - Calculation of the DHM secret failed" );
|
||||
case -(MBEDTLS_ERR_DHM_INVALID_FORMAT):
|
||||
return( "DHM - The ASN.1 data is not formatted correctly" );
|
||||
case -(MBEDTLS_ERR_DHM_ALLOC_FAILED):
|
||||
return( "DHM - Allocation of memory failed" );
|
||||
case -(MBEDTLS_ERR_DHM_FILE_IO_ERROR):
|
||||
return( "DHM - Read or write of file failed" );
|
||||
case -(MBEDTLS_ERR_DHM_SET_GROUP_FAILED):
|
||||
return( "DHM - Setting the modulus and generator failed" );
|
||||
#endif /* MBEDTLS_DHM_C */
|
||||
|
||||
#if defined(MBEDTLS_ECP_C)
|
||||
case -(MBEDTLS_ERR_ECP_BAD_INPUT_DATA):
|
||||
return( "ECP - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_ECP_BUFFER_TOO_SMALL):
|
||||
return( "ECP - The buffer is too small to write to" );
|
||||
case -(MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE):
|
||||
return( "ECP - The requested feature is not available, for example, the requested curve is not supported" );
|
||||
case -(MBEDTLS_ERR_ECP_VERIFY_FAILED):
|
||||
return( "ECP - The signature is not valid" );
|
||||
case -(MBEDTLS_ERR_ECP_ALLOC_FAILED):
|
||||
return( "ECP - Memory allocation failed" );
|
||||
case -(MBEDTLS_ERR_ECP_RANDOM_FAILED):
|
||||
return( "ECP - Generation of random value, such as ephemeral key, failed" );
|
||||
case -(MBEDTLS_ERR_ECP_INVALID_KEY):
|
||||
return( "ECP - Invalid private or public key" );
|
||||
case -(MBEDTLS_ERR_ECP_SIG_LEN_MISMATCH):
|
||||
return( "ECP - The buffer contains a valid signature followed by more data" );
|
||||
case -(MBEDTLS_ERR_ECP_IN_PROGRESS):
|
||||
return( "ECP - Operation in progress, call again with the same parameters to continue" );
|
||||
#endif /* MBEDTLS_ECP_C */
|
||||
|
||||
#if defined(MBEDTLS_MD_C)
|
||||
case -(MBEDTLS_ERR_MD_FEATURE_UNAVAILABLE):
|
||||
return( "MD - The selected feature is not available" );
|
||||
case -(MBEDTLS_ERR_MD_BAD_INPUT_DATA):
|
||||
return( "MD - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_MD_ALLOC_FAILED):
|
||||
return( "MD - Failed to allocate memory" );
|
||||
case -(MBEDTLS_ERR_MD_FILE_IO_ERROR):
|
||||
return( "MD - Opening or reading of file failed" );
|
||||
#endif /* MBEDTLS_MD_C */
|
||||
|
||||
#if defined(MBEDTLS_PEM_PARSE_C) || defined(MBEDTLS_PEM_WRITE_C)
|
||||
case -(MBEDTLS_ERR_PEM_NO_HEADER_FOOTER_PRESENT):
|
||||
return( "PEM - No PEM header or footer found" );
|
||||
case -(MBEDTLS_ERR_PEM_INVALID_DATA):
|
||||
return( "PEM - PEM string is not as expected" );
|
||||
case -(MBEDTLS_ERR_PEM_ALLOC_FAILED):
|
||||
return( "PEM - Failed to allocate memory" );
|
||||
case -(MBEDTLS_ERR_PEM_INVALID_ENC_IV):
|
||||
return( "PEM - RSA IV is not in hex-format" );
|
||||
case -(MBEDTLS_ERR_PEM_UNKNOWN_ENC_ALG):
|
||||
return( "PEM - Unsupported key encryption algorithm" );
|
||||
case -(MBEDTLS_ERR_PEM_PASSWORD_REQUIRED):
|
||||
return( "PEM - Private key password can't be empty" );
|
||||
case -(MBEDTLS_ERR_PEM_PASSWORD_MISMATCH):
|
||||
return( "PEM - Given private key password does not allow for correct decryption" );
|
||||
case -(MBEDTLS_ERR_PEM_FEATURE_UNAVAILABLE):
|
||||
return( "PEM - Unavailable feature, e.g. hashing/encryption combination" );
|
||||
case -(MBEDTLS_ERR_PEM_BAD_INPUT_DATA):
|
||||
return( "PEM - Bad input parameters to function" );
|
||||
#endif /* MBEDTLS_PEM_PARSE_C || MBEDTLS_PEM_WRITE_C */
|
||||
|
||||
#if defined(MBEDTLS_PK_C)
|
||||
case -(MBEDTLS_ERR_PK_ALLOC_FAILED):
|
||||
return( "PK - Memory allocation failed" );
|
||||
case -(MBEDTLS_ERR_PK_TYPE_MISMATCH):
|
||||
return( "PK - Type mismatch, eg attempt to encrypt with an ECDSA key" );
|
||||
case -(MBEDTLS_ERR_PK_BAD_INPUT_DATA):
|
||||
return( "PK - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_PK_FILE_IO_ERROR):
|
||||
return( "PK - Read/write of file failed" );
|
||||
case -(MBEDTLS_ERR_PK_KEY_INVALID_VERSION):
|
||||
return( "PK - Unsupported key version" );
|
||||
case -(MBEDTLS_ERR_PK_KEY_INVALID_FORMAT):
|
||||
return( "PK - Invalid key tag or value" );
|
||||
case -(MBEDTLS_ERR_PK_UNKNOWN_PK_ALG):
|
||||
return( "PK - Key algorithm is unsupported (only RSA and EC are supported)" );
|
||||
case -(MBEDTLS_ERR_PK_PASSWORD_REQUIRED):
|
||||
return( "PK - Private key password can't be empty" );
|
||||
case -(MBEDTLS_ERR_PK_PASSWORD_MISMATCH):
|
||||
return( "PK - Given private key password does not allow for correct decryption" );
|
||||
case -(MBEDTLS_ERR_PK_INVALID_PUBKEY):
|
||||
return( "PK - The pubkey tag or value is invalid (only RSA and EC are supported)" );
|
||||
case -(MBEDTLS_ERR_PK_INVALID_ALG):
|
||||
return( "PK - The algorithm tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_PK_UNKNOWN_NAMED_CURVE):
|
||||
return( "PK - Elliptic curve is unsupported (only NIST curves are supported)" );
|
||||
case -(MBEDTLS_ERR_PK_FEATURE_UNAVAILABLE):
|
||||
return( "PK - Unavailable feature, e.g. RSA disabled for RSA key" );
|
||||
case -(MBEDTLS_ERR_PK_SIG_LEN_MISMATCH):
|
||||
return( "PK - The buffer contains a valid signature followed by more data" );
|
||||
case -(MBEDTLS_ERR_PK_BUFFER_TOO_SMALL):
|
||||
return( "PK - The output buffer is too small" );
|
||||
#endif /* MBEDTLS_PK_C */
|
||||
|
||||
#if defined(MBEDTLS_PKCS12_C)
|
||||
case -(MBEDTLS_ERR_PKCS12_BAD_INPUT_DATA):
|
||||
return( "PKCS12 - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_PKCS12_FEATURE_UNAVAILABLE):
|
||||
return( "PKCS12 - Feature not available, e.g. unsupported encryption scheme" );
|
||||
case -(MBEDTLS_ERR_PKCS12_PBE_INVALID_FORMAT):
|
||||
return( "PKCS12 - PBE ASN.1 data not as expected" );
|
||||
case -(MBEDTLS_ERR_PKCS12_PASSWORD_MISMATCH):
|
||||
return( "PKCS12 - Given private key password does not allow for correct decryption" );
|
||||
#endif /* MBEDTLS_PKCS12_C */
|
||||
|
||||
#if defined(MBEDTLS_PKCS5_C)
|
||||
case -(MBEDTLS_ERR_PKCS5_BAD_INPUT_DATA):
|
||||
return( "PKCS5 - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_PKCS5_INVALID_FORMAT):
|
||||
return( "PKCS5 - Unexpected ASN.1 data" );
|
||||
case -(MBEDTLS_ERR_PKCS5_FEATURE_UNAVAILABLE):
|
||||
return( "PKCS5 - Requested encryption or digest alg not available" );
|
||||
case -(MBEDTLS_ERR_PKCS5_PASSWORD_MISMATCH):
|
||||
return( "PKCS5 - Given private key password does not allow for correct decryption" );
|
||||
#endif /* MBEDTLS_PKCS5_C */
|
||||
|
||||
#if defined(MBEDTLS_PKCS7_C)
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_FORMAT):
|
||||
return( "PKCS7 - The format is invalid, e.g. different type expected" );
|
||||
case -(MBEDTLS_ERR_PKCS7_FEATURE_UNAVAILABLE):
|
||||
return( "PKCS7 - Unavailable feature, e.g. anything other than signed data" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_VERSION):
|
||||
return( "PKCS7 - The PKCS #7 version element is invalid or cannot be parsed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_CONTENT_INFO):
|
||||
return( "PKCS7 - The PKCS #7 content info is invalid or cannot be parsed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_ALG):
|
||||
return( "PKCS7 - The algorithm tag or value is invalid or cannot be parsed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_CERT):
|
||||
return( "PKCS7 - The certificate tag or value is invalid or cannot be parsed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_SIGNATURE):
|
||||
return( "PKCS7 - Error parsing the signature" );
|
||||
case -(MBEDTLS_ERR_PKCS7_INVALID_SIGNER_INFO):
|
||||
return( "PKCS7 - Error parsing the signer's info" );
|
||||
case -(MBEDTLS_ERR_PKCS7_BAD_INPUT_DATA):
|
||||
return( "PKCS7 - Input invalid" );
|
||||
case -(MBEDTLS_ERR_PKCS7_ALLOC_FAILED):
|
||||
return( "PKCS7 - Allocation of memory failed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_VERIFY_FAIL):
|
||||
return( "PKCS7 - Verification Failed" );
|
||||
case -(MBEDTLS_ERR_PKCS7_CERT_DATE_INVALID):
|
||||
return( "PKCS7 - The PKCS #7 date issued/expired dates are invalid" );
|
||||
#endif /* MBEDTLS_PKCS7_C */
|
||||
|
||||
#if defined(MBEDTLS_RSA_C)
|
||||
case -(MBEDTLS_ERR_RSA_BAD_INPUT_DATA):
|
||||
return( "RSA - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_RSA_INVALID_PADDING):
|
||||
return( "RSA - Input data contains invalid padding and is rejected" );
|
||||
case -(MBEDTLS_ERR_RSA_KEY_GEN_FAILED):
|
||||
return( "RSA - Something failed during generation of a key" );
|
||||
case -(MBEDTLS_ERR_RSA_KEY_CHECK_FAILED):
|
||||
return( "RSA - Key failed to pass the validity check of the library" );
|
||||
case -(MBEDTLS_ERR_RSA_PUBLIC_FAILED):
|
||||
return( "RSA - The public key operation failed" );
|
||||
case -(MBEDTLS_ERR_RSA_PRIVATE_FAILED):
|
||||
return( "RSA - The private key operation failed" );
|
||||
case -(MBEDTLS_ERR_RSA_VERIFY_FAILED):
|
||||
return( "RSA - The PKCS#1 verification failed" );
|
||||
case -(MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE):
|
||||
return( "RSA - The output buffer for decryption is not large enough" );
|
||||
case -(MBEDTLS_ERR_RSA_RNG_FAILED):
|
||||
return( "RSA - The random generator failed to generate non-zeros" );
|
||||
#endif /* MBEDTLS_RSA_C */
|
||||
|
||||
#if defined(MBEDTLS_SSL_TLS_C)
|
||||
case -(MBEDTLS_ERR_SSL_CRYPTO_IN_PROGRESS):
|
||||
return( "SSL - A cryptographic operation is in progress. Try again later" );
|
||||
case -(MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE):
|
||||
return( "SSL - The requested feature is not available" );
|
||||
case -(MBEDTLS_ERR_SSL_BAD_INPUT_DATA):
|
||||
return( "SSL - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_SSL_INVALID_MAC):
|
||||
return( "SSL - Verification of the message MAC failed" );
|
||||
case -(MBEDTLS_ERR_SSL_INVALID_RECORD):
|
||||
return( "SSL - An invalid SSL record was received" );
|
||||
case -(MBEDTLS_ERR_SSL_CONN_EOF):
|
||||
return( "SSL - The connection indicated an EOF" );
|
||||
case -(MBEDTLS_ERR_SSL_DECODE_ERROR):
|
||||
return( "SSL - A message could not be parsed due to a syntactic error" );
|
||||
case -(MBEDTLS_ERR_SSL_NO_RNG):
|
||||
return( "SSL - No RNG was provided to the SSL module" );
|
||||
case -(MBEDTLS_ERR_SSL_NO_CLIENT_CERTIFICATE):
|
||||
return( "SSL - No client certification received from the client, but required by the authentication mode" );
|
||||
case -(MBEDTLS_ERR_SSL_UNSUPPORTED_EXTENSION):
|
||||
return( "SSL - Client received an extended server hello containing an unsupported extension" );
|
||||
case -(MBEDTLS_ERR_SSL_NO_APPLICATION_PROTOCOL):
|
||||
return( "SSL - No ALPN protocols supported that the client advertises" );
|
||||
case -(MBEDTLS_ERR_SSL_PRIVATE_KEY_REQUIRED):
|
||||
return( "SSL - The own private key or pre-shared key is not set, but needed" );
|
||||
case -(MBEDTLS_ERR_SSL_CA_CHAIN_REQUIRED):
|
||||
return( "SSL - No CA Chain is set, but required to operate" );
|
||||
case -(MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE):
|
||||
return( "SSL - An unexpected message was received from our peer" );
|
||||
case -(MBEDTLS_ERR_SSL_FATAL_ALERT_MESSAGE):
|
||||
return( "SSL - A fatal alert message was received from our peer" );
|
||||
case -(MBEDTLS_ERR_SSL_UNRECOGNIZED_NAME):
|
||||
return( "SSL - No server could be identified matching the client's SNI" );
|
||||
case -(MBEDTLS_ERR_SSL_PEER_CLOSE_NOTIFY):
|
||||
return( "SSL - The peer notified us that the connection is going to be closed" );
|
||||
case -(MBEDTLS_ERR_SSL_BAD_CERTIFICATE):
|
||||
return( "SSL - Processing of the Certificate handshake message failed" );
|
||||
case -(MBEDTLS_ERR_SSL_RECEIVED_NEW_SESSION_TICKET):
|
||||
return( "SSL - A TLS 1.3 NewSessionTicket message has been received" );
|
||||
case -(MBEDTLS_ERR_SSL_CANNOT_READ_EARLY_DATA):
|
||||
return( "SSL - Not possible to read early data" );
|
||||
case -(MBEDTLS_ERR_SSL_RECEIVED_EARLY_DATA):
|
||||
return( "SSL - * Early data has been received as part of an on-going handshake. This error code can be returned only on server side if and only if early data has been enabled by means of the mbedtls_ssl_conf_early_data() API. This error code can then be returned by mbedtls_ssl_handshake(), mbedtls_ssl_handshake_step(), mbedtls_ssl_read() or mbedtls_ssl_write() if early data has been received as part of the handshake sequence they triggered. To read the early data, call mbedtls_ssl_read_early_data()" );
|
||||
case -(MBEDTLS_ERR_SSL_CANNOT_WRITE_EARLY_DATA):
|
||||
return( "SSL - Not possible to write early data" );
|
||||
case -(MBEDTLS_ERR_SSL_CACHE_ENTRY_NOT_FOUND):
|
||||
return( "SSL - Cache entry not found" );
|
||||
case -(MBEDTLS_ERR_SSL_ALLOC_FAILED):
|
||||
return( "SSL - Memory allocation failed" );
|
||||
case -(MBEDTLS_ERR_SSL_HW_ACCEL_FAILED):
|
||||
return( "SSL - Hardware acceleration function returned with error" );
|
||||
case -(MBEDTLS_ERR_SSL_HW_ACCEL_FALLTHROUGH):
|
||||
return( "SSL - Hardware acceleration function skipped / left alone data" );
|
||||
case -(MBEDTLS_ERR_SSL_BAD_PROTOCOL_VERSION):
|
||||
return( "SSL - Handshake protocol not within min/max boundaries" );
|
||||
case -(MBEDTLS_ERR_SSL_HANDSHAKE_FAILURE):
|
||||
return( "SSL - The handshake negotiation failed" );
|
||||
case -(MBEDTLS_ERR_SSL_SESSION_TICKET_EXPIRED):
|
||||
return( "SSL - Session ticket has expired" );
|
||||
case -(MBEDTLS_ERR_SSL_PK_TYPE_MISMATCH):
|
||||
return( "SSL - Public key type mismatch (eg, asked for RSA key exchange and presented EC key)" );
|
||||
case -(MBEDTLS_ERR_SSL_UNKNOWN_IDENTITY):
|
||||
return( "SSL - Unknown identity received (eg, PSK identity)" );
|
||||
case -(MBEDTLS_ERR_SSL_INTERNAL_ERROR):
|
||||
return( "SSL - Internal error (eg, unexpected failure in lower-level module)" );
|
||||
case -(MBEDTLS_ERR_SSL_COUNTER_WRAPPING):
|
||||
return( "SSL - A counter would wrap (eg, too many messages exchanged)" );
|
||||
case -(MBEDTLS_ERR_SSL_WAITING_SERVER_HELLO_RENEGO):
|
||||
return( "SSL - Unexpected message at ServerHello in renegotiation" );
|
||||
case -(MBEDTLS_ERR_SSL_HELLO_VERIFY_REQUIRED):
|
||||
return( "SSL - DTLS client must retry for hello verification" );
|
||||
case -(MBEDTLS_ERR_SSL_BUFFER_TOO_SMALL):
|
||||
return( "SSL - A buffer is too small to receive or write a message" );
|
||||
case -(MBEDTLS_ERR_SSL_WANT_READ):
|
||||
return( "SSL - No data of requested type currently available on underlying transport" );
|
||||
case -(MBEDTLS_ERR_SSL_WANT_WRITE):
|
||||
return( "SSL - Connection requires a write call" );
|
||||
case -(MBEDTLS_ERR_SSL_TIMEOUT):
|
||||
return( "SSL - The operation timed out" );
|
||||
case -(MBEDTLS_ERR_SSL_CLIENT_RECONNECT):
|
||||
return( "SSL - The client initiated a reconnect from the same port" );
|
||||
case -(MBEDTLS_ERR_SSL_UNEXPECTED_RECORD):
|
||||
return( "SSL - Record header looks valid but is not expected" );
|
||||
case -(MBEDTLS_ERR_SSL_NON_FATAL):
|
||||
return( "SSL - The alert message received indicates a non-fatal error" );
|
||||
case -(MBEDTLS_ERR_SSL_ILLEGAL_PARAMETER):
|
||||
return( "SSL - A field in a message was incorrect or inconsistent with other fields" );
|
||||
case -(MBEDTLS_ERR_SSL_CONTINUE_PROCESSING):
|
||||
return( "SSL - Internal-only message signaling that further message-processing should be done" );
|
||||
case -(MBEDTLS_ERR_SSL_ASYNC_IN_PROGRESS):
|
||||
return( "SSL - The asynchronous operation is not completed yet" );
|
||||
case -(MBEDTLS_ERR_SSL_EARLY_MESSAGE):
|
||||
return( "SSL - Internal-only message signaling that a message arrived early" );
|
||||
case -(MBEDTLS_ERR_SSL_UNEXPECTED_CID):
|
||||
return( "SSL - An encrypted DTLS-frame with an unexpected CID was received" );
|
||||
case -(MBEDTLS_ERR_SSL_VERSION_MISMATCH):
|
||||
return( "SSL - An operation failed due to an unexpected version or configuration" );
|
||||
case -(MBEDTLS_ERR_SSL_BAD_CONFIG):
|
||||
return( "SSL - Invalid value in SSL config" );
|
||||
case -(MBEDTLS_ERR_SSL_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME):
|
||||
return( "SSL - Attempt to verify a certificate without an expected hostname. This is usually insecure. In TLS clients, when a client authenticates a server through its certificate, the client normally checks three things: - the certificate chain must be valid; - the chain must start from a trusted CA; - the certificate must cover the server name that is expected by the client. Omitting any of these checks is generally insecure, and can allow a malicious server to impersonate a legitimate server. The third check may be safely skipped in some unusual scenarios, such as networks where eavesdropping is a risk but not active attacks, or a private PKI where the client equally trusts all servers that are accredited by the root CA. You should call mbedtls_ssl_set_hostname() with the expected server name before starting a TLS handshake on a client (unless the client is set up to only use PSK-based authentication, which does not rely on the host name). If you have determined that server name verification is not required for security in your scenario, call mbedtls_ssl_set_hostname() with \\p NULL as the server name. This error is raised if all of the following conditions are met: - A TLS client is configured with the authentication mode #MBEDTLS_SSL_VERIFY_REQUIRED (default). - Certificate authentication is enabled. - The client does not call mbedtls_ssl_set_hostname(). - The configuration option #MBEDTLS_SSL_CLI_ALLOW_WEAK_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME is not enabled" );
|
||||
#endif /* MBEDTLS_SSL_TLS_C */
|
||||
|
||||
#if defined(MBEDTLS_X509_USE_C) || defined(MBEDTLS_X509_CREATE_C)
|
||||
case -(MBEDTLS_ERR_X509_FEATURE_UNAVAILABLE):
|
||||
return( "X509 - Unavailable feature, e.g. RSA hashing/encryption combination" );
|
||||
case -(MBEDTLS_ERR_X509_UNKNOWN_OID):
|
||||
return( "X509 - Requested OID is unknown" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_FORMAT):
|
||||
return( "X509 - The CRT/CRL/CSR format is invalid, e.g. different type expected" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_VERSION):
|
||||
return( "X509 - The CRT/CRL/CSR version element is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_SERIAL):
|
||||
return( "X509 - The serial tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_ALG):
|
||||
return( "X509 - The algorithm tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_NAME):
|
||||
return( "X509 - The name tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_DATE):
|
||||
return( "X509 - The date tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_SIGNATURE):
|
||||
return( "X509 - The signature tag or value invalid" );
|
||||
case -(MBEDTLS_ERR_X509_INVALID_EXTENSIONS):
|
||||
return( "X509 - The extension tag or value is invalid" );
|
||||
case -(MBEDTLS_ERR_X509_UNKNOWN_VERSION):
|
||||
return( "X509 - CRT/CRL/CSR has an unsupported version number" );
|
||||
case -(MBEDTLS_ERR_X509_UNKNOWN_SIG_ALG):
|
||||
return( "X509 - Signature algorithm (oid) is unsupported" );
|
||||
case -(MBEDTLS_ERR_X509_SIG_MISMATCH):
|
||||
return( "X509 - Signature algorithms do not match. (see \\c ::mbedtls_x509_crt sig_oid)" );
|
||||
case -(MBEDTLS_ERR_X509_CERT_VERIFY_FAILED):
|
||||
return( "X509 - Certificate verification failed, e.g. CRL, CA or signature check failed" );
|
||||
case -(MBEDTLS_ERR_X509_CERT_UNKNOWN_FORMAT):
|
||||
return( "X509 - Format not recognized as DER or PEM" );
|
||||
case -(MBEDTLS_ERR_X509_BAD_INPUT_DATA):
|
||||
return( "X509 - Input invalid" );
|
||||
case -(MBEDTLS_ERR_X509_ALLOC_FAILED):
|
||||
return( "X509 - Allocation of memory failed" );
|
||||
case -(MBEDTLS_ERR_X509_FILE_IO_ERROR):
|
||||
return( "X509 - Read/write of file failed" );
|
||||
case -(MBEDTLS_ERR_X509_BUFFER_TOO_SMALL):
|
||||
return( "X509 - Destination buffer is too small" );
|
||||
case -(MBEDTLS_ERR_X509_FATAL_ERROR):
|
||||
return( "X509 - A fatal error occurred, eg the chain is too long or the vrfy callback failed" );
|
||||
#endif /* MBEDTLS_X509_USE_C || MBEDTLS_X509_CREATE_C */
|
||||
/* End Auto-Generated Code. */
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
const char *mbedtls_low_level_strerr(int error_code)
|
||||
{
|
||||
int low_level_error_code;
|
||||
|
||||
if (error_code < 0) {
|
||||
error_code = -error_code;
|
||||
}
|
||||
|
||||
/* Extract the low-level part from the error code. */
|
||||
low_level_error_code = error_code & ~0xFF80;
|
||||
|
||||
switch (low_level_error_code) {
|
||||
/* Begin Auto-Generated Code. */
|
||||
#if defined(MBEDTLS_AES_C)
|
||||
case -(MBEDTLS_ERR_AES_INVALID_KEY_LENGTH):
|
||||
return( "AES - Invalid key length" );
|
||||
case -(MBEDTLS_ERR_AES_INVALID_INPUT_LENGTH):
|
||||
return( "AES - Invalid data input length" );
|
||||
case -(MBEDTLS_ERR_AES_BAD_INPUT_DATA):
|
||||
return( "AES - Invalid input data" );
|
||||
#endif /* MBEDTLS_AES_C */
|
||||
|
||||
#if defined(MBEDTLS_ARIA_C)
|
||||
case -(MBEDTLS_ERR_ARIA_BAD_INPUT_DATA):
|
||||
return( "ARIA - Bad input data" );
|
||||
case -(MBEDTLS_ERR_ARIA_INVALID_INPUT_LENGTH):
|
||||
return( "ARIA - Invalid data input length" );
|
||||
#endif /* MBEDTLS_ARIA_C */
|
||||
|
||||
#if defined(MBEDTLS_ASN1_PARSE_C)
|
||||
case -(MBEDTLS_ERR_ASN1_OUT_OF_DATA):
|
||||
return( "ASN1 - Out of data when parsing an ASN1 data structure" );
|
||||
case -(MBEDTLS_ERR_ASN1_UNEXPECTED_TAG):
|
||||
return( "ASN1 - ASN1 tag was of an unexpected value" );
|
||||
case -(MBEDTLS_ERR_ASN1_INVALID_LENGTH):
|
||||
return( "ASN1 - Error when trying to determine the length or invalid length" );
|
||||
case -(MBEDTLS_ERR_ASN1_LENGTH_MISMATCH):
|
||||
return( "ASN1 - Actual length differs from expected length" );
|
||||
case -(MBEDTLS_ERR_ASN1_INVALID_DATA):
|
||||
return( "ASN1 - Data is invalid" );
|
||||
case -(MBEDTLS_ERR_ASN1_ALLOC_FAILED):
|
||||
return( "ASN1 - Memory allocation failed" );
|
||||
case -(MBEDTLS_ERR_ASN1_BUF_TOO_SMALL):
|
||||
return( "ASN1 - Buffer too small when writing ASN.1 data structure" );
|
||||
#endif /* MBEDTLS_ASN1_PARSE_C */
|
||||
|
||||
#if defined(MBEDTLS_BASE64_C)
|
||||
case -(MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL):
|
||||
return( "BASE64 - Output buffer too small" );
|
||||
case -(MBEDTLS_ERR_BASE64_INVALID_CHARACTER):
|
||||
return( "BASE64 - Invalid character in input" );
|
||||
#endif /* MBEDTLS_BASE64_C */
|
||||
|
||||
#if defined(MBEDTLS_BIGNUM_C)
|
||||
case -(MBEDTLS_ERR_MPI_FILE_IO_ERROR):
|
||||
return( "BIGNUM - An error occurred while reading from or writing to a file" );
|
||||
case -(MBEDTLS_ERR_MPI_BAD_INPUT_DATA):
|
||||
return( "BIGNUM - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_MPI_INVALID_CHARACTER):
|
||||
return( "BIGNUM - There is an invalid character in the digit string" );
|
||||
case -(MBEDTLS_ERR_MPI_BUFFER_TOO_SMALL):
|
||||
return( "BIGNUM - The buffer is too small to write to" );
|
||||
case -(MBEDTLS_ERR_MPI_NEGATIVE_VALUE):
|
||||
return( "BIGNUM - The input arguments are negative or result in illegal output" );
|
||||
case -(MBEDTLS_ERR_MPI_DIVISION_BY_ZERO):
|
||||
return( "BIGNUM - The input argument for division is zero, which is not allowed" );
|
||||
case -(MBEDTLS_ERR_MPI_NOT_ACCEPTABLE):
|
||||
return( "BIGNUM - The input arguments are not acceptable" );
|
||||
case -(MBEDTLS_ERR_MPI_ALLOC_FAILED):
|
||||
return( "BIGNUM - Memory allocation failed" );
|
||||
#endif /* MBEDTLS_BIGNUM_C */
|
||||
|
||||
#if defined(MBEDTLS_CAMELLIA_C)
|
||||
case -(MBEDTLS_ERR_CAMELLIA_BAD_INPUT_DATA):
|
||||
return( "CAMELLIA - Bad input data" );
|
||||
case -(MBEDTLS_ERR_CAMELLIA_INVALID_INPUT_LENGTH):
|
||||
return( "CAMELLIA - Invalid data input length" );
|
||||
#endif /* MBEDTLS_CAMELLIA_C */
|
||||
|
||||
#if defined(MBEDTLS_CCM_C)
|
||||
case -(MBEDTLS_ERR_CCM_BAD_INPUT):
|
||||
return( "CCM - Bad input parameters to the function" );
|
||||
case -(MBEDTLS_ERR_CCM_AUTH_FAILED):
|
||||
return( "CCM - Authenticated decryption failed" );
|
||||
#endif /* MBEDTLS_CCM_C */
|
||||
|
||||
#if defined(MBEDTLS_CHACHA20_C)
|
||||
case -(MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA):
|
||||
return( "CHACHA20 - Invalid input parameter(s)" );
|
||||
#endif /* MBEDTLS_CHACHA20_C */
|
||||
|
||||
#if defined(MBEDTLS_CHACHAPOLY_C)
|
||||
case -(MBEDTLS_ERR_CHACHAPOLY_BAD_STATE):
|
||||
return( "CHACHAPOLY - The requested operation is not permitted in the current state" );
|
||||
case -(MBEDTLS_ERR_CHACHAPOLY_AUTH_FAILED):
|
||||
return( "CHACHAPOLY - Authenticated decryption failed: data was not authentic" );
|
||||
#endif /* MBEDTLS_CHACHAPOLY_C */
|
||||
|
||||
#if defined(MBEDTLS_CTR_DRBG_C)
|
||||
case -(MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED):
|
||||
return( "CTR_DRBG - The entropy source failed" );
|
||||
case -(MBEDTLS_ERR_CTR_DRBG_REQUEST_TOO_BIG):
|
||||
return( "CTR_DRBG - The requested random buffer length is too big" );
|
||||
case -(MBEDTLS_ERR_CTR_DRBG_INPUT_TOO_BIG):
|
||||
return( "CTR_DRBG - The input (entropy + additional data) is too large" );
|
||||
case -(MBEDTLS_ERR_CTR_DRBG_FILE_IO_ERROR):
|
||||
return( "CTR_DRBG - Read or write error in file" );
|
||||
#endif /* MBEDTLS_CTR_DRBG_C */
|
||||
|
||||
#if defined(MBEDTLS_DES_C)
|
||||
case -(MBEDTLS_ERR_DES_INVALID_INPUT_LENGTH):
|
||||
return( "DES - The data input has an invalid length" );
|
||||
#endif /* MBEDTLS_DES_C */
|
||||
|
||||
#if defined(MBEDTLS_ENTROPY_C)
|
||||
case -(MBEDTLS_ERR_ENTROPY_SOURCE_FAILED):
|
||||
return( "ENTROPY - Critical entropy source failure" );
|
||||
case -(MBEDTLS_ERR_ENTROPY_MAX_SOURCES):
|
||||
return( "ENTROPY - No more sources can be added" );
|
||||
case -(MBEDTLS_ERR_ENTROPY_NO_SOURCES_DEFINED):
|
||||
return( "ENTROPY - No sources have been added to poll" );
|
||||
case -(MBEDTLS_ERR_ENTROPY_NO_STRONG_SOURCE):
|
||||
return( "ENTROPY - No strong sources have been added to poll" );
|
||||
case -(MBEDTLS_ERR_ENTROPY_FILE_IO_ERROR):
|
||||
return( "ENTROPY - Read/write error in file" );
|
||||
#endif /* MBEDTLS_ENTROPY_C */
|
||||
|
||||
#if defined(MBEDTLS_ERROR_C)
|
||||
case -(MBEDTLS_ERR_ERROR_GENERIC_ERROR):
|
||||
return( "ERROR - Generic error" );
|
||||
case -(MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED):
|
||||
return( "ERROR - This is a bug in the library" );
|
||||
#endif /* MBEDTLS_ERROR_C */
|
||||
|
||||
#if defined(MBEDTLS_PLATFORM_C)
|
||||
case -(MBEDTLS_ERR_PLATFORM_HW_ACCEL_FAILED):
|
||||
return( "PLATFORM - Hardware accelerator failed" );
|
||||
case -(MBEDTLS_ERR_PLATFORM_FEATURE_UNSUPPORTED):
|
||||
return( "PLATFORM - The requested feature is not supported by the platform" );
|
||||
#endif /* MBEDTLS_PLATFORM_C */
|
||||
|
||||
#if defined(MBEDTLS_GCM_C)
|
||||
case -(MBEDTLS_ERR_GCM_AUTH_FAILED):
|
||||
return( "GCM - Authenticated decryption failed" );
|
||||
case -(MBEDTLS_ERR_GCM_BAD_INPUT):
|
||||
return( "GCM - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_GCM_BUFFER_TOO_SMALL):
|
||||
return( "GCM - An output buffer is too small" );
|
||||
#endif /* MBEDTLS_GCM_C */
|
||||
|
||||
#if defined(MBEDTLS_HKDF_C)
|
||||
case -(MBEDTLS_ERR_HKDF_BAD_INPUT_DATA):
|
||||
return( "HKDF - Bad input parameters to function" );
|
||||
#endif /* MBEDTLS_HKDF_C */
|
||||
|
||||
#if defined(MBEDTLS_HMAC_DRBG_C)
|
||||
case -(MBEDTLS_ERR_HMAC_DRBG_REQUEST_TOO_BIG):
|
||||
return( "HMAC_DRBG - Too many random requested in single call" );
|
||||
case -(MBEDTLS_ERR_HMAC_DRBG_INPUT_TOO_BIG):
|
||||
return( "HMAC_DRBG - Input too large (Entropy + additional)" );
|
||||
case -(MBEDTLS_ERR_HMAC_DRBG_FILE_IO_ERROR):
|
||||
return( "HMAC_DRBG - Read/write error in file" );
|
||||
case -(MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED):
|
||||
return( "HMAC_DRBG - The entropy source failed" );
|
||||
#endif /* MBEDTLS_HMAC_DRBG_C */
|
||||
|
||||
#if defined(MBEDTLS_LMS_C)
|
||||
case -(MBEDTLS_ERR_LMS_BAD_INPUT_DATA):
|
||||
return( "LMS - Bad data has been input to an LMS function" );
|
||||
case -(MBEDTLS_ERR_LMS_OUT_OF_PRIVATE_KEYS):
|
||||
return( "LMS - Specified LMS key has utilised all of its private keys" );
|
||||
case -(MBEDTLS_ERR_LMS_VERIFY_FAILED):
|
||||
return( "LMS - LMS signature verification failed" );
|
||||
case -(MBEDTLS_ERR_LMS_ALLOC_FAILED):
|
||||
return( "LMS - LMS failed to allocate space for a private key" );
|
||||
case -(MBEDTLS_ERR_LMS_BUFFER_TOO_SMALL):
|
||||
return( "LMS - Input/output buffer is too small to contain requited data" );
|
||||
#endif /* MBEDTLS_LMS_C */
|
||||
|
||||
#if defined(MBEDTLS_NET_C)
|
||||
case -(MBEDTLS_ERR_NET_SOCKET_FAILED):
|
||||
return( "NET - Failed to open a socket" );
|
||||
case -(MBEDTLS_ERR_NET_CONNECT_FAILED):
|
||||
return( "NET - The connection to the given server / port failed" );
|
||||
case -(MBEDTLS_ERR_NET_BIND_FAILED):
|
||||
return( "NET - Binding of the socket failed" );
|
||||
case -(MBEDTLS_ERR_NET_LISTEN_FAILED):
|
||||
return( "NET - Could not listen on the socket" );
|
||||
case -(MBEDTLS_ERR_NET_ACCEPT_FAILED):
|
||||
return( "NET - Could not accept the incoming connection" );
|
||||
case -(MBEDTLS_ERR_NET_RECV_FAILED):
|
||||
return( "NET - Reading information from the socket failed" );
|
||||
case -(MBEDTLS_ERR_NET_SEND_FAILED):
|
||||
return( "NET - Sending information through the socket failed" );
|
||||
case -(MBEDTLS_ERR_NET_CONN_RESET):
|
||||
return( "NET - Connection was reset by peer" );
|
||||
case -(MBEDTLS_ERR_NET_UNKNOWN_HOST):
|
||||
return( "NET - Failed to get an IP address for the given hostname" );
|
||||
case -(MBEDTLS_ERR_NET_BUFFER_TOO_SMALL):
|
||||
return( "NET - Buffer is too small to hold the data" );
|
||||
case -(MBEDTLS_ERR_NET_INVALID_CONTEXT):
|
||||
return( "NET - The context is invalid, eg because it was free()ed" );
|
||||
case -(MBEDTLS_ERR_NET_POLL_FAILED):
|
||||
return( "NET - Polling the net context failed" );
|
||||
case -(MBEDTLS_ERR_NET_BAD_INPUT_DATA):
|
||||
return( "NET - Input invalid" );
|
||||
#endif /* MBEDTLS_NET_C */
|
||||
|
||||
#if defined(MBEDTLS_OID_C)
|
||||
case -(MBEDTLS_ERR_OID_NOT_FOUND):
|
||||
return( "OID - OID is not found" );
|
||||
case -(MBEDTLS_ERR_OID_BUF_TOO_SMALL):
|
||||
return( "OID - output buffer is too small" );
|
||||
#endif /* MBEDTLS_OID_C */
|
||||
|
||||
#if defined(MBEDTLS_POLY1305_C)
|
||||
case -(MBEDTLS_ERR_POLY1305_BAD_INPUT_DATA):
|
||||
return( "POLY1305 - Invalid input parameter(s)" );
|
||||
#endif /* MBEDTLS_POLY1305_C */
|
||||
|
||||
#if defined(MBEDTLS_SHA1_C)
|
||||
case -(MBEDTLS_ERR_SHA1_BAD_INPUT_DATA):
|
||||
return( "SHA1 - SHA-1 input data was malformed" );
|
||||
#endif /* MBEDTLS_SHA1_C */
|
||||
|
||||
#if defined(MBEDTLS_SHA256_C)
|
||||
case -(MBEDTLS_ERR_SHA256_BAD_INPUT_DATA):
|
||||
return( "SHA256 - SHA-256 input data was malformed" );
|
||||
#endif /* MBEDTLS_SHA256_C */
|
||||
|
||||
#if defined(MBEDTLS_SHA3_C)
|
||||
case -(MBEDTLS_ERR_SHA3_BAD_INPUT_DATA):
|
||||
return( "SHA3 - SHA-3 input data was malformed" );
|
||||
#endif /* MBEDTLS_SHA3_C */
|
||||
|
||||
#if defined(MBEDTLS_SHA512_C)
|
||||
case -(MBEDTLS_ERR_SHA512_BAD_INPUT_DATA):
|
||||
return( "SHA512 - SHA-512 input data was malformed" );
|
||||
#endif /* MBEDTLS_SHA512_C */
|
||||
|
||||
#if defined(MBEDTLS_THREADING_C)
|
||||
case -(MBEDTLS_ERR_THREADING_BAD_INPUT_DATA):
|
||||
return( "THREADING - Bad input parameters to function" );
|
||||
case -(MBEDTLS_ERR_THREADING_MUTEX_ERROR):
|
||||
return( "THREADING - Locking / unlocking / free failed with error code" );
|
||||
#endif /* MBEDTLS_THREADING_C */
|
||||
/* End Auto-Generated Code. */
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void mbedtls_strerror(int ret, char *buf, size_t buflen)
|
||||
{
|
||||
size_t len;
|
||||
int use_ret;
|
||||
const char *high_level_error_description = NULL;
|
||||
const char *low_level_error_description = NULL;
|
||||
|
||||
if (buflen == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
memset(buf, 0x00, buflen);
|
||||
|
||||
if (ret < 0) {
|
||||
ret = -ret;
|
||||
}
|
||||
|
||||
if (ret & 0xFF80) {
|
||||
use_ret = ret & 0xFF80;
|
||||
|
||||
// Translate high level error code.
|
||||
high_level_error_description = mbedtls_high_level_strerr(ret);
|
||||
|
||||
if (high_level_error_description == NULL) {
|
||||
mbedtls_snprintf(buf, buflen, "UNKNOWN ERROR CODE (%04X)", (unsigned int) use_ret);
|
||||
} else {
|
||||
mbedtls_snprintf(buf, buflen, "%s", high_level_error_description);
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_TLS_C)
|
||||
// Early return in case of a fatal error - do not try to translate low
|
||||
// level code.
|
||||
if (use_ret == -(MBEDTLS_ERR_SSL_FATAL_ALERT_MESSAGE)) {
|
||||
return;
|
||||
}
|
||||
#endif /* MBEDTLS_SSL_TLS_C */
|
||||
}
|
||||
|
||||
use_ret = ret & ~0xFF80;
|
||||
|
||||
if (use_ret == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
// If high level code is present, make a concatenation between both
|
||||
// error strings.
|
||||
//
|
||||
len = strlen(buf);
|
||||
|
||||
if (len > 0) {
|
||||
if (buflen - len < 5) {
|
||||
return;
|
||||
}
|
||||
|
||||
mbedtls_snprintf(buf + len, buflen - len, " : ");
|
||||
|
||||
buf += len + 3;
|
||||
buflen -= len + 3;
|
||||
}
|
||||
|
||||
// Translate low level error code.
|
||||
low_level_error_description = mbedtls_low_level_strerr(ret);
|
||||
|
||||
if (low_level_error_description == NULL) {
|
||||
mbedtls_snprintf(buf, buflen, "UNKNOWN ERROR CODE (%04X)", (unsigned int) use_ret);
|
||||
} else {
|
||||
mbedtls_snprintf(buf, buflen, "%s", low_level_error_description);
|
||||
}
|
||||
}
|
||||
|
||||
#else /* MBEDTLS_ERROR_C */
|
||||
|
||||
/*
|
||||
* Provide a dummy implementation when MBEDTLS_ERROR_C is not defined
|
||||
*/
|
||||
void mbedtls_strerror(int ret, char *buf, size_t buflen)
|
||||
{
|
||||
((void) ret);
|
||||
|
||||
if (buflen > 0) {
|
||||
buf[0] = '\0';
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* MBEDTLS_ERROR_C */
|
||||
|
||||
#endif /* MBEDTLS_ERROR_C || MBEDTLS_ERROR_STRERROR_DUMMY */
|
||||
@ -205,13 +205,19 @@ int mbedtls_pk_ecc_set_pubkey(mbedtls_pk_context *pk, const unsigned char *pub,
|
||||
{
|
||||
#if defined(MBEDTLS_PK_USE_PSA_EC_DATA)
|
||||
|
||||
/* We need to read the first byte to determine the format (compressed,
|
||||
* uncompressed or 0). */
|
||||
if (pub_len == 0) {
|
||||
return MBEDTLS_ERR_PK_INVALID_PUBKEY;
|
||||
}
|
||||
|
||||
/* Load the key */
|
||||
if (!PSA_ECC_FAMILY_IS_WEIERSTRASS(pk->ec_family) || *pub == 0x04) {
|
||||
/* Format directly supported by PSA:
|
||||
* - non-Weierstrass curves that only have one format;
|
||||
* - uncompressed format for Weierstrass curves. */
|
||||
if (pub_len > sizeof(pk->pub_raw)) {
|
||||
return MBEDTLS_ERR_PK_BUFFER_TOO_SMALL;
|
||||
return MBEDTLS_ERR_PK_INVALID_PUBKEY;
|
||||
}
|
||||
memcpy(pk->pub_raw, pub, pub_len);
|
||||
pk->pub_raw_len = pub_len;
|
||||
|
||||
@ -34,6 +34,7 @@
|
||||
#if defined(MBEDTLS_RSA_C)
|
||||
#include "pkwrite.h"
|
||||
#include "rsa_internal.h"
|
||||
#include "constant_time_internal.h"
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_PK_CAN_ECDSA_SOME)
|
||||
@ -329,21 +330,33 @@ static int rsa_decrypt_wrap(mbedtls_pk_context *pk,
|
||||
input, ilen,
|
||||
NULL, 0,
|
||||
output, osize, olen);
|
||||
if (status != PSA_SUCCESS) {
|
||||
ret = PSA_PK_RSA_TO_MBEDTLS_ERR(status);
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
ret = 0;
|
||||
#if defined(MBEDTLS_PKCS1_V15)
|
||||
/* Translate error codes from PSA to legacy
|
||||
* Success vs INVALID_PADDING vs BUFFER_TOO_SMALL is sensitive
|
||||
* (padding oracle attack), so we take care to translate that
|
||||
* part in constant time.
|
||||
*/
|
||||
int problem;
|
||||
status = mbedtls_rsa_decrypt_decompose_ret(
|
||||
PSA_ERROR_INVALID_PADDING, MBEDTLS_ERR_RSA_INVALID_PADDING,
|
||||
PSA_ERROR_BUFFER_TOO_SMALL, MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE,
|
||||
status, &problem);
|
||||
ret = PSA_PK_RSA_TO_MBEDTLS_ERR(status);
|
||||
ret |= problem;
|
||||
#else
|
||||
ret = PSA_PK_RSA_TO_MBEDTLS_ERR(status);
|
||||
#endif
|
||||
|
||||
cleanup:
|
||||
mbedtls_zeroize_and_free(buf, buf_size);
|
||||
status = psa_destroy_key(key_id);
|
||||
if (ret == 0 && status != PSA_SUCCESS) {
|
||||
ret = PSA_PK_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
|
||||
return ret;
|
||||
/* Don't branch on ret as it is a sensitive value
|
||||
* (it reveals whether padding was valid).
|
||||
* Instead branch on status. That means when both ret and
|
||||
* status were errors, we'll return the unlock status while we would
|
||||
* normally return the first error, but that's better than leaking info. */
|
||||
return (status != PSA_SUCCESS) ? PSA_PK_TO_MBEDTLS_ERR(status) : ret;
|
||||
}
|
||||
#else /* MBEDTLS_USE_PSA_CRYPTO */
|
||||
static int rsa_decrypt_wrap(mbedtls_pk_context *pk,
|
||||
@ -1503,11 +1516,21 @@ static int rsa_opaque_decrypt(mbedtls_pk_context *pk,
|
||||
}
|
||||
|
||||
status = psa_asymmetric_decrypt(pk->priv_id, alg, input, ilen, NULL, 0, output, osize, olen);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return PSA_PK_RSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
|
||||
return 0;
|
||||
#if defined(MBEDTLS_PKCS1_V15)
|
||||
/* Translate error codes from PSA to legacy
|
||||
* Success vs INVALID_PADDING vs BUFFER_TOO_SMALL is sensitive
|
||||
* (padding oracle attack), so we take care to translate that
|
||||
* part in constant time.
|
||||
*/
|
||||
int problem;
|
||||
status = mbedtls_rsa_decrypt_decompose_ret(
|
||||
PSA_ERROR_INVALID_PADDING, MBEDTLS_ERR_RSA_INVALID_PADDING,
|
||||
PSA_ERROR_BUFFER_TOO_SMALL, MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE,
|
||||
status, &problem);
|
||||
return PSA_PK_RSA_TO_MBEDTLS_ERR(status) | problem;
|
||||
#else
|
||||
return PSA_PK_RSA_TO_MBEDTLS_ERR(status);
|
||||
#endif
|
||||
}
|
||||
#endif /* PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC */
|
||||
|
||||
|
||||
@ -666,6 +666,20 @@ static int mbedtls_pkcs7_data_or_hash_verify(mbedtls_pkcs7 *pkcs7,
|
||||
return ret;
|
||||
}
|
||||
|
||||
#if !defined(MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES)
|
||||
/* Ensure the MD alg from the PKCS#7 context and signature algorithm from
|
||||
* the certificate belong to the list of secure algorithms
|
||||
* (i.e. mbedtls_x509_crt_profile_default). */
|
||||
ret = mbedtls_x509_profile_check_md_alg(&mbedtls_x509_crt_profile_default, md_alg);
|
||||
if (ret != 0) {
|
||||
return MBEDTLS_ERR_PKCS7_INVALID_ALG;
|
||||
}
|
||||
ret = mbedtls_x509_profile_check_pk_alg(&mbedtls_x509_crt_profile_default, cert->sig_pk);
|
||||
if (ret != 0) {
|
||||
return MBEDTLS_ERR_PKCS7_INVALID_ALG;
|
||||
}
|
||||
#endif /* MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES */
|
||||
|
||||
md_info = mbedtls_md_info_from_type(md_alg);
|
||||
if (md_info == NULL) {
|
||||
return MBEDTLS_ERR_PKCS7_VERIFY_FAIL;
|
||||
@ -767,7 +781,7 @@ void mbedtls_pkcs7_free(mbedtls_pkcs7 *pkcs7)
|
||||
mbedtls_free(signer_prev);
|
||||
}
|
||||
|
||||
pkcs7->raw.p = NULL;
|
||||
mbedtls_platform_zeroize(pkcs7, sizeof(*pkcs7));
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@ -3568,7 +3568,12 @@ exit:
|
||||
LOCAL_INPUT_FREE(salt_external, salt);
|
||||
LOCAL_OUTPUT_FREE(output_external, output);
|
||||
|
||||
return (status == PSA_SUCCESS) ? unlock_status : status;
|
||||
/* Don't branch on status as it is a sensitive value
|
||||
* (it reveals whether padding was valid).
|
||||
* Instead branch on unlock_status. That means when both status and
|
||||
* unlock_status were errors, we'll return the unlock error while we would
|
||||
* normally return the first error, but that's better than leaking info. */
|
||||
return (unlock_status != PSA_SUCCESS) ? unlock_status : status;
|
||||
}
|
||||
|
||||
/****************************************************************/
|
||||
@ -5357,7 +5362,13 @@ psa_status_t psa_aead_set_lengths(psa_aead_operation_t *operation,
|
||||
#endif /* PSA_WANT_ALG_CCM */
|
||||
#if defined(PSA_WANT_ALG_CHACHA20_POLY1305)
|
||||
case PSA_ALG_CHACHA20_POLY1305:
|
||||
/* No length restrictions for ChaChaPoly. */
|
||||
#if SIZE_MAX > UINT32_MAX
|
||||
if (plaintext_length > (size_t) UINT32_MAX *
|
||||
64U) {
|
||||
status = PSA_ERROR_INVALID_ARGUMENT;
|
||||
goto exit;
|
||||
}
|
||||
#endif
|
||||
break;
|
||||
#endif /* PSA_WANT_ALG_CHACHA20_POLY1305 */
|
||||
default:
|
||||
|
||||
2896
library/psa_crypto_driver_wrappers.h
Normal file
2896
library/psa_crypto_driver_wrappers.h
Normal file
File diff suppressed because it is too large
Load Diff
256
library/psa_crypto_driver_wrappers_no_static.c
Normal file
256
library/psa_crypto_driver_wrappers_no_static.c
Normal file
@ -0,0 +1,256 @@
|
||||
/*
|
||||
* Functions to delegate cryptographic operations to an available
|
||||
* and appropriate accelerator.
|
||||
* Warning: This file is now auto-generated.
|
||||
*/
|
||||
/* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
|
||||
/* BEGIN-common headers */
|
||||
#include "common.h"
|
||||
#include "psa_crypto_aead.h"
|
||||
#include "psa_crypto_cipher.h"
|
||||
#include "psa_crypto_core.h"
|
||||
#include "psa_crypto_driver_wrappers_no_static.h"
|
||||
#include "psa_crypto_hash.h"
|
||||
#include "psa_crypto_mac.h"
|
||||
#include "psa_crypto_pake.h"
|
||||
#include "psa_crypto_rsa.h"
|
||||
|
||||
#include "mbedtls/platform.h"
|
||||
/* END-common headers */
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C)
|
||||
|
||||
/* BEGIN-driver headers */
|
||||
/* Headers for mbedtls_test opaque driver */
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
#include "test/drivers/test_driver.h"
|
||||
|
||||
#endif
|
||||
/* Headers for mbedtls_test transparent driver */
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
#include "test/drivers/test_driver.h"
|
||||
|
||||
#endif
|
||||
/* Headers for p256 transparent driver */
|
||||
#if defined(MBEDTLS_PSA_P256M_DRIVER_ENABLED)
|
||||
#include "../3rdparty/p256-m/p256-m_driver_entrypoints.h"
|
||||
|
||||
#endif
|
||||
|
||||
/* END-driver headers */
|
||||
|
||||
/* Auto-generated values depending on which drivers are registered.
|
||||
* ID 0 is reserved for unallocated operations.
|
||||
* ID 1 is reserved for the Mbed TLS software driver. */
|
||||
/* BEGIN-driver id definition */
|
||||
#define PSA_CRYPTO_MBED_TLS_DRIVER_ID (1)
|
||||
#define MBEDTLS_TEST_OPAQUE_DRIVER_ID (2)
|
||||
#define MBEDTLS_TEST_TRANSPARENT_DRIVER_ID (3)
|
||||
#define P256_TRANSPARENT_DRIVER_ID (4)
|
||||
|
||||
/* END-driver id */
|
||||
|
||||
/* BEGIN-Common Macro definitions */
|
||||
|
||||
/* END-Common Macro definitions */
|
||||
|
||||
/* Support the 'old' SE interface when asked to */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SE_C)
|
||||
/* PSA_CRYPTO_DRIVER_PRESENT is defined when either a new-style or old-style
|
||||
* SE driver is present, to avoid unused argument errors at compile time. */
|
||||
#ifndef PSA_CRYPTO_DRIVER_PRESENT
|
||||
#define PSA_CRYPTO_DRIVER_PRESENT
|
||||
#endif
|
||||
#include "psa_crypto_se.h"
|
||||
#endif
|
||||
|
||||
/** Get the key buffer size required to store the key material of a key
|
||||
* associated with an opaque driver.
|
||||
*
|
||||
* \param[in] attributes The key attributes.
|
||||
* \param[out] key_buffer_size Minimum buffer size to contain the key material
|
||||
*
|
||||
* \retval #PSA_SUCCESS
|
||||
* The minimum size for a buffer to contain the key material has been
|
||||
* returned successfully.
|
||||
* \retval #PSA_ERROR_NOT_SUPPORTED
|
||||
* The type and/or the size in bits of the key or the combination of
|
||||
* the two is not supported.
|
||||
* \retval #PSA_ERROR_INVALID_ARGUMENT
|
||||
* The key is declared with a lifetime not known to us.
|
||||
*/
|
||||
psa_status_t psa_driver_wrapper_get_key_buffer_size(
|
||||
const psa_key_attributes_t *attributes,
|
||||
size_t *key_buffer_size )
|
||||
{
|
||||
psa_key_location_t location = PSA_KEY_LIFETIME_GET_LOCATION( psa_get_key_lifetime(attributes) );
|
||||
psa_key_type_t key_type = psa_get_key_type(attributes);
|
||||
size_t key_bits = psa_get_key_bits(attributes);
|
||||
|
||||
*key_buffer_size = 0;
|
||||
switch( location )
|
||||
{
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
case PSA_CRYPTO_TEST_DRIVER_LOCATION:
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS)
|
||||
/* Emulate property 'builtin_key_size' */
|
||||
if( psa_key_id_is_builtin(
|
||||
MBEDTLS_SVC_KEY_ID_GET_KEY_ID(
|
||||
psa_get_key_id( attributes ) ) ) )
|
||||
{
|
||||
*key_buffer_size = sizeof( psa_drv_slot_number_t );
|
||||
return( PSA_SUCCESS );
|
||||
}
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS */
|
||||
*key_buffer_size = mbedtls_test_opaque_size_function( key_type,
|
||||
key_bits );
|
||||
return( ( *key_buffer_size != 0 ) ?
|
||||
PSA_SUCCESS : PSA_ERROR_NOT_SUPPORTED );
|
||||
#endif /* PSA_CRYPTO_DRIVER_TEST */
|
||||
|
||||
default:
|
||||
(void)key_type;
|
||||
(void)key_bits;
|
||||
return( PSA_ERROR_INVALID_ARGUMENT );
|
||||
}
|
||||
}
|
||||
|
||||
psa_status_t psa_driver_wrapper_export_public_key(
|
||||
const psa_key_attributes_t *attributes,
|
||||
const uint8_t *key_buffer, size_t key_buffer_size,
|
||||
uint8_t *data, size_t data_size, size_t *data_length )
|
||||
|
||||
{
|
||||
|
||||
psa_status_t status = PSA_ERROR_INVALID_ARGUMENT;
|
||||
psa_key_location_t location = PSA_KEY_LIFETIME_GET_LOCATION(
|
||||
psa_get_key_lifetime( attributes ) );
|
||||
|
||||
/* Try dynamically-registered SE interface first */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SE_C)
|
||||
const psa_drv_se_t *drv;
|
||||
psa_drv_se_context_t *drv_context;
|
||||
|
||||
if( psa_get_se_driver( psa_get_key_lifetime(attributes), &drv, &drv_context ) )
|
||||
{
|
||||
if( ( drv->key_management == NULL ) ||
|
||||
( drv->key_management->p_export_public == NULL ) )
|
||||
{
|
||||
return( PSA_ERROR_NOT_SUPPORTED );
|
||||
}
|
||||
|
||||
return( drv->key_management->p_export_public(
|
||||
drv_context,
|
||||
*( (psa_key_slot_number_t *)key_buffer ),
|
||||
data, data_size, data_length ) );
|
||||
}
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_SE_C */
|
||||
|
||||
switch( location )
|
||||
{
|
||||
case PSA_KEY_LOCATION_LOCAL_STORAGE:
|
||||
/* Key is stored in the slot in export representation, so
|
||||
* cycle through all known transparent accelerators */
|
||||
#if defined(PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT)
|
||||
|
||||
#if (defined(PSA_CRYPTO_DRIVER_TEST) )
|
||||
status = mbedtls_test_transparent_export_public_key
|
||||
(attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
data,
|
||||
data_size,
|
||||
data_length
|
||||
);
|
||||
|
||||
if( status != PSA_ERROR_NOT_SUPPORTED )
|
||||
return( status );
|
||||
#endif
|
||||
|
||||
#if (defined(MBEDTLS_PSA_P256M_DRIVER_ENABLED) )
|
||||
status = p256_transparent_export_public_key
|
||||
(attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
data,
|
||||
data_size,
|
||||
data_length
|
||||
);
|
||||
|
||||
if( status != PSA_ERROR_NOT_SUPPORTED )
|
||||
return( status );
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT */
|
||||
/* Fell through, meaning no accelerator supports this operation */
|
||||
return( psa_export_public_key_internal( attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
data,
|
||||
data_size,
|
||||
data_length ) );
|
||||
|
||||
/* Add cases for opaque driver here */
|
||||
#if defined(PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT)
|
||||
|
||||
#if (defined(PSA_CRYPTO_DRIVER_TEST) )
|
||||
case 0x7fffff:
|
||||
return( mbedtls_test_opaque_export_public_key
|
||||
(attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
data,
|
||||
data_size,
|
||||
data_length
|
||||
));
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT */
|
||||
default:
|
||||
/* Key is declared with a lifetime not known to us */
|
||||
return( status );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
psa_status_t psa_driver_wrapper_get_builtin_key(
|
||||
psa_drv_slot_number_t slot_number,
|
||||
psa_key_attributes_t *attributes,
|
||||
uint8_t *key_buffer, size_t key_buffer_size, size_t *key_buffer_length )
|
||||
{
|
||||
|
||||
psa_key_location_t location = PSA_KEY_LIFETIME_GET_LOCATION( psa_get_key_lifetime(attributes) );
|
||||
switch( location )
|
||||
{
|
||||
#if defined(PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT)
|
||||
|
||||
#if (defined(PSA_CRYPTO_DRIVER_TEST) )
|
||||
case 0x7fffff:
|
||||
return( mbedtls_test_opaque_get_builtin_key
|
||||
(slot_number,
|
||||
attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
key_buffer_length
|
||||
));
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* PSA_CRYPTO_ACCELERATOR_DRIVER_PRESENT */
|
||||
default:
|
||||
(void) slot_number;
|
||||
(void) key_buffer;
|
||||
(void) key_buffer_size;
|
||||
(void) key_buffer_length;
|
||||
return( PSA_ERROR_DOES_NOT_EXIST );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_C */
|
||||
@ -25,6 +25,7 @@
|
||||
#include <mbedtls/rsa.h>
|
||||
#include <mbedtls/error.h>
|
||||
#include "rsa_internal.h"
|
||||
#include "constant_time_internal.h"
|
||||
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_ALG_RSA_PKCS1V15_CRYPT) || \
|
||||
defined(MBEDTLS_PSA_BUILTIN_ALG_RSA_OAEP) || \
|
||||
@ -652,14 +653,22 @@ psa_status_t mbedtls_psa_asymmetric_decrypt(const psa_key_attributes_t *attribut
|
||||
|
||||
if (alg == PSA_ALG_RSA_PKCS1V15_CRYPT) {
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_ALG_RSA_PKCS1V15_CRYPT)
|
||||
status = mbedtls_to_psa_error(
|
||||
mbedtls_rsa_pkcs1_decrypt(rsa,
|
||||
mbedtls_psa_get_random,
|
||||
MBEDTLS_PSA_RANDOM_STATE,
|
||||
output_length,
|
||||
input,
|
||||
output,
|
||||
output_size));
|
||||
int combined_ret = mbedtls_rsa_rsaes_pkcs1_v15_decrypt(
|
||||
rsa, mbedtls_psa_get_random, MBEDTLS_PSA_RANDOM_STATE,
|
||||
output_length, input, output, output_size);
|
||||
|
||||
/* Translate error codes from legacy to PSA.
|
||||
* Success vs INVALID_PADDING vs OUTPUT_TOO_LARGE is sensitive
|
||||
* (padding oracle attack), so we take care to translate that
|
||||
* part in constant time.
|
||||
*/
|
||||
int problem;
|
||||
int public_ret = mbedtls_rsa_decrypt_decompose_ret(
|
||||
MBEDTLS_ERR_RSA_INVALID_PADDING, PSA_ERROR_INVALID_PADDING,
|
||||
MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE, PSA_ERROR_BUFFER_TOO_SMALL,
|
||||
combined_ret, &problem);
|
||||
status = mbedtls_to_psa_error(public_ret);
|
||||
status |= problem;
|
||||
#else
|
||||
status = PSA_ERROR_NOT_SUPPORTED;
|
||||
#endif /* MBEDTLS_PSA_BUILTIN_ALG_RSA_PKCS1V15_CRYPT */
|
||||
|
||||
@ -414,37 +414,12 @@ end_of_export:
|
||||
|
||||
#if defined(MBEDTLS_PKCS1_V15) && defined(MBEDTLS_RSA_C) && !defined(MBEDTLS_RSA_ALT)
|
||||
|
||||
/** This function performs the unpadding part of a PKCS#1 v1.5 decryption
|
||||
* operation (EME-PKCS1-v1_5 decoding).
|
||||
*
|
||||
* \note The return value from this function is a sensitive value
|
||||
* (this is unusual). #MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE shouldn't happen
|
||||
* in a well-written application, but 0 vs #MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
* is often a situation that an attacker can provoke and leaking which
|
||||
* one is the result is precisely the information the attacker wants.
|
||||
*
|
||||
* \param input The input buffer which is the payload inside PKCS#1v1.5
|
||||
* encryption padding, called the "encoded message EM"
|
||||
* by the terminology.
|
||||
* \param ilen The length of the payload in the \p input buffer.
|
||||
* \param output The buffer for the payload, called "message M" by the
|
||||
* PKCS#1 terminology. This must be a writable buffer of
|
||||
* length \p output_max_len bytes.
|
||||
* \param olen The address at which to store the length of
|
||||
* the payload. This must not be \c NULL.
|
||||
* \param output_max_len The length in bytes of the output buffer \p output.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
* The output buffer is too small for the unpadded payload.
|
||||
* \return #MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
* The input doesn't contain properly formatted padding.
|
||||
/*
|
||||
* EME-PKCS1-v1_5 decoding, see documentation in rsa_internal.h
|
||||
*/
|
||||
static int mbedtls_ct_rsaes_pkcs1_v15_unpadding(unsigned char *input,
|
||||
size_t ilen,
|
||||
unsigned char *output,
|
||||
size_t output_max_len,
|
||||
size_t *olen)
|
||||
MBEDTLS_STATIC_TESTABLE int mbedtls_ct_rsaes_pkcs1_v15_unpadding(
|
||||
unsigned char *input, size_t ilen,
|
||||
unsigned char *output, size_t output_max_len, size_t *olen)
|
||||
{
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
size_t i, plaintext_max_size;
|
||||
@ -567,6 +542,32 @@ static int mbedtls_ct_rsaes_pkcs1_v15_unpadding(unsigned char *input,
|
||||
|
||||
#endif /* MBEDTLS_PKCS1_V15 && MBEDTLS_RSA_C && ! MBEDTLS_RSA_ALT */
|
||||
|
||||
#if defined(MBEDTLS_PKCS1_V15) && defined(MBEDTLS_RSA_C)
|
||||
int mbedtls_rsa_decrypt_decompose_ret(
|
||||
int invalid_padding_in, int invalid_padding_out,
|
||||
int output_too_large_in, int output_too_large_out,
|
||||
int combined_ret,
|
||||
int *problem)
|
||||
{
|
||||
*problem = 0;
|
||||
int ret = combined_ret;
|
||||
|
||||
const mbedtls_ct_condition_t invalid_padding_cond =
|
||||
mbedtls_ct_uint_eq((mbedtls_ct_uint_t) ret,
|
||||
(mbedtls_ct_uint_t) invalid_padding_in);
|
||||
*problem = mbedtls_ct_error_if(invalid_padding_cond, invalid_padding_out, *problem);
|
||||
ret = mbedtls_ct_error_if(invalid_padding_cond, 0, ret);
|
||||
|
||||
const mbedtls_ct_condition_t output_too_large_cond =
|
||||
mbedtls_ct_uint_eq((mbedtls_ct_uint_t) ret,
|
||||
(mbedtls_ct_uint_t) output_too_large_in);
|
||||
*problem = mbedtls_ct_error_if(output_too_large_cond, output_too_large_out, *problem);
|
||||
ret = mbedtls_ct_error_if(output_too_large_cond, 0, ret);
|
||||
|
||||
return ret;
|
||||
}
|
||||
#endif /* MBEDTLS_PKCS1_V15 && MBEDTLS_RSA_C */
|
||||
|
||||
#if !defined(MBEDTLS_RSA_ALT)
|
||||
|
||||
int mbedtls_rsa_import(mbedtls_rsa_context *ctx,
|
||||
|
||||
@ -118,4 +118,71 @@ int mbedtls_rsa_rsassa_pss_sign_no_mode_check(mbedtls_rsa_context *ctx,
|
||||
unsigned char *sig);
|
||||
#endif /* MBEDTLS_PKCS1_V21 */
|
||||
|
||||
/* This would normally be in rsa_invasive.h but it didn't exist before 3.6
|
||||
* became an LTS, and I'd rather not add files in LTS if it can be avoided. */
|
||||
#if defined(MBEDTLS_TEST_HOOKS)
|
||||
#if defined(MBEDTLS_PKCS1_V15) && defined(MBEDTLS_RSA_C) && !defined(MBEDTLS_RSA_ALT)
|
||||
|
||||
/** This function performs the unpadding part of a PKCS#1 v1.5 decryption
|
||||
* operation (EME-PKCS1-v1_5 decoding).
|
||||
*
|
||||
* \note The return value from this function is a sensitive value
|
||||
* (this is unusual). #MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE shouldn't happen
|
||||
* in a well-written application, but 0 vs #MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
* is often a situation that an attacker can provoke and leaking which
|
||||
* one is the result is precisely the information the attacker wants.
|
||||
*
|
||||
* \param input The input buffer which is the payload inside PKCS#1v1.5
|
||||
* encryption padding, called the "encoded message EM"
|
||||
* by the terminology.
|
||||
* \param ilen The length of the payload in the \p input buffer.
|
||||
* \param output The buffer for the payload, called "message M" by the
|
||||
* PKCS#1 terminology. This must be a writable buffer of
|
||||
* length \p output_max_len bytes.
|
||||
* \param olen The address at which to store the length of
|
||||
* the payload. This must not be \c NULL.
|
||||
* \param output_max_len The length in bytes of the output buffer \p output.
|
||||
*
|
||||
* \return \c 0 on success.
|
||||
* \return #MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
* The output buffer is too small for the unpadded payload.
|
||||
* \return #MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
* The input doesn't contain properly formatted padding.
|
||||
*/
|
||||
MBEDTLS_STATIC_TESTABLE int mbedtls_ct_rsaes_pkcs1_v15_unpadding(
|
||||
unsigned char *input, size_t ilen,
|
||||
unsigned char *output, size_t output_max_len, size_t *olen);
|
||||
#endif /* MBEDTLS_PKCS1_V15 && MBEDTLS_RSA_C && ! MBEDTLS_RSA_ALT */
|
||||
#endif /* MBEDTLS_TEST_HOOKS */
|
||||
|
||||
#if defined(MBEDTLS_PKCS1_V15) && defined(MBEDTLS_RSA_C)
|
||||
/** Decompose sensitive return values out of a return code, in constant time.
|
||||
*
|
||||
* \param invalid_padding_in The value of \p combined_ret that indicates
|
||||
* invalid padding.
|
||||
* \param invalid_padding_out The value to set \p problem to in case of
|
||||
* invalid padding.
|
||||
* \param output_too_large_in The value of \p combined_ret that indicates
|
||||
* an insufficient output buffer size.
|
||||
* \param output_too_large_out The value to set \p problem to in case of
|
||||
* an insufficient output buffer size.
|
||||
* \param combined_ret The value to decompose.
|
||||
* \param[out] problem On output:
|
||||
* - \p invalid_padding_out,
|
||||
* if \p combined_ret = \p invalid_padding_in;
|
||||
* - \p output_too_large_out,
|
||||
* if \p combined_ret = \p output_too_large_in;
|
||||
* - otherwise \c 0.
|
||||
*
|
||||
* \return - \c 0 if \p combined_ret = \p invalid_padding_in
|
||||
* or \p combined_ret = \p output_too_large_in;
|
||||
* - otherwise \c combined_ret.
|
||||
*/
|
||||
int mbedtls_rsa_decrypt_decompose_ret(
|
||||
int invalid_padding_in, int invalid_padding_out,
|
||||
int output_too_large_in, int output_too_large_out,
|
||||
int combined_ret,
|
||||
int *problem);
|
||||
#endif
|
||||
|
||||
#endif /* rsa_internal.h */
|
||||
|
||||
@ -210,6 +210,10 @@ static int ssl_write_alpn_ext(mbedtls_ssl_context *ssl,
|
||||
* generalization of the TLS 1.2 supported elliptic curves extension. They both
|
||||
* share the same extension identifier.
|
||||
*
|
||||
* If the TLS 1.3 logic for selecting proposed groups changes, the TLS 1.3
|
||||
* group filtering in the function `ssl_tls13_parse_hrr_key_share_ext()` must
|
||||
* be updated accordingly.
|
||||
*
|
||||
*/
|
||||
#define SSL_WRITE_SUPPORTED_GROUPS_EXT_TLS1_2_FLAG 1
|
||||
#define SSL_WRITE_SUPPORTED_GROUPS_EXT_TLS1_3_FLAG 2
|
||||
@ -253,8 +257,8 @@ static int ssl_write_supported_groups_ext(mbedtls_ssl_context *ssl,
|
||||
if (flags & SSL_WRITE_SUPPORTED_GROUPS_EXT_TLS1_3_FLAG) {
|
||||
#if defined(PSA_WANT_ALG_ECDH)
|
||||
if (mbedtls_ssl_tls13_named_group_is_ecdhe(*group_list) &&
|
||||
(mbedtls_ssl_get_ecp_group_id_from_tls_id(*group_list) !=
|
||||
MBEDTLS_ECP_DP_NONE)) {
|
||||
mbedtls_ssl_get_psa_curve_info_from_tls_id(
|
||||
*group_list, NULL, NULL) == PSA_SUCCESS) {
|
||||
propose_group = 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
251
library/ssl_debug_helpers_generated.c
Normal file
251
library/ssl_debug_helpers_generated.c
Normal file
@ -0,0 +1,251 @@
|
||||
/* Automatically generated by generate_ssl_debug_helpers.py. DO NOT EDIT. */
|
||||
|
||||
/**
|
||||
* \file ssl_debug_helpers_generated.c
|
||||
*
|
||||
* \brief Automatically generated helper functions for debugging
|
||||
*/
|
||||
/*
|
||||
* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*
|
||||
*/
|
||||
|
||||
#include "ssl_misc.h"
|
||||
|
||||
#if defined(MBEDTLS_DEBUG_C)
|
||||
|
||||
#include "ssl_debug_helpers.h"
|
||||
|
||||
|
||||
const char *mbedtls_ssl_named_group_to_str( uint16_t in )
|
||||
{
|
||||
switch( in )
|
||||
{
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP192K1:
|
||||
return "secp192k1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP192R1:
|
||||
return "secp192r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP224K1:
|
||||
return "secp224k1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP224R1:
|
||||
return "secp224r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP256K1:
|
||||
return "secp256k1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP256R1:
|
||||
return "secp256r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP384R1:
|
||||
return "secp384r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_SECP521R1:
|
||||
return "secp521r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_BP256R1:
|
||||
return "bp256r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_BP384R1:
|
||||
return "bp384r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_BP512R1:
|
||||
return "bp512r1";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_X25519:
|
||||
return "x25519";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_X448:
|
||||
return "x448";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_FFDHE2048:
|
||||
return "ffdhe2048";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_FFDHE3072:
|
||||
return "ffdhe3072";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_FFDHE4096:
|
||||
return "ffdhe4096";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_FFDHE6144:
|
||||
return "ffdhe6144";
|
||||
case MBEDTLS_SSL_IANA_TLS_GROUP_FFDHE8192:
|
||||
return "ffdhe8192";
|
||||
};
|
||||
|
||||
return "UNKNOWN";
|
||||
}
|
||||
const char *mbedtls_ssl_sig_alg_to_str( uint16_t in )
|
||||
{
|
||||
switch( in )
|
||||
{
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PKCS1_SHA256:
|
||||
return "rsa_pkcs1_sha256";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PKCS1_SHA384:
|
||||
return "rsa_pkcs1_sha384";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PKCS1_SHA512:
|
||||
return "rsa_pkcs1_sha512";
|
||||
case MBEDTLS_TLS1_3_SIG_ECDSA_SECP256R1_SHA256:
|
||||
return "ecdsa_secp256r1_sha256";
|
||||
case MBEDTLS_TLS1_3_SIG_ECDSA_SECP384R1_SHA384:
|
||||
return "ecdsa_secp384r1_sha384";
|
||||
case MBEDTLS_TLS1_3_SIG_ECDSA_SECP521R1_SHA512:
|
||||
return "ecdsa_secp521r1_sha512";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_RSAE_SHA256:
|
||||
return "rsa_pss_rsae_sha256";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_RSAE_SHA384:
|
||||
return "rsa_pss_rsae_sha384";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_RSAE_SHA512:
|
||||
return "rsa_pss_rsae_sha512";
|
||||
case MBEDTLS_TLS1_3_SIG_ED25519:
|
||||
return "ed25519";
|
||||
case MBEDTLS_TLS1_3_SIG_ED448:
|
||||
return "ed448";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_PSS_SHA256:
|
||||
return "rsa_pss_pss_sha256";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_PSS_SHA384:
|
||||
return "rsa_pss_pss_sha384";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PSS_PSS_SHA512:
|
||||
return "rsa_pss_pss_sha512";
|
||||
case MBEDTLS_TLS1_3_SIG_RSA_PKCS1_SHA1:
|
||||
return "rsa_pkcs1_sha1";
|
||||
case MBEDTLS_TLS1_3_SIG_ECDSA_SHA1:
|
||||
return "ecdsa_sha1";
|
||||
case MBEDTLS_TLS1_3_SIG_NONE:
|
||||
return "none";
|
||||
};
|
||||
|
||||
return "UNKNOWN";
|
||||
}
|
||||
const char *mbedtls_ssl_states_str( mbedtls_ssl_states in )
|
||||
{
|
||||
switch (in) {
|
||||
case MBEDTLS_SSL_HELLO_REQUEST:
|
||||
return "MBEDTLS_SSL_HELLO_REQUEST";
|
||||
case MBEDTLS_SSL_CLIENT_HELLO:
|
||||
return "MBEDTLS_SSL_CLIENT_HELLO";
|
||||
case MBEDTLS_SSL_SERVER_HELLO:
|
||||
return "MBEDTLS_SSL_SERVER_HELLO";
|
||||
case MBEDTLS_SSL_SERVER_CERTIFICATE:
|
||||
return "MBEDTLS_SSL_SERVER_CERTIFICATE";
|
||||
case MBEDTLS_SSL_SERVER_KEY_EXCHANGE:
|
||||
return "MBEDTLS_SSL_SERVER_KEY_EXCHANGE";
|
||||
case MBEDTLS_SSL_CERTIFICATE_REQUEST:
|
||||
return "MBEDTLS_SSL_CERTIFICATE_REQUEST";
|
||||
case MBEDTLS_SSL_SERVER_HELLO_DONE:
|
||||
return "MBEDTLS_SSL_SERVER_HELLO_DONE";
|
||||
case MBEDTLS_SSL_CLIENT_CERTIFICATE:
|
||||
return "MBEDTLS_SSL_CLIENT_CERTIFICATE";
|
||||
case MBEDTLS_SSL_CLIENT_KEY_EXCHANGE:
|
||||
return "MBEDTLS_SSL_CLIENT_KEY_EXCHANGE";
|
||||
case MBEDTLS_SSL_CERTIFICATE_VERIFY:
|
||||
return "MBEDTLS_SSL_CERTIFICATE_VERIFY";
|
||||
case MBEDTLS_SSL_CLIENT_CHANGE_CIPHER_SPEC:
|
||||
return "MBEDTLS_SSL_CLIENT_CHANGE_CIPHER_SPEC";
|
||||
case MBEDTLS_SSL_CLIENT_FINISHED:
|
||||
return "MBEDTLS_SSL_CLIENT_FINISHED";
|
||||
case MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC:
|
||||
return "MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC";
|
||||
case MBEDTLS_SSL_SERVER_FINISHED:
|
||||
return "MBEDTLS_SSL_SERVER_FINISHED";
|
||||
case MBEDTLS_SSL_FLUSH_BUFFERS:
|
||||
return "MBEDTLS_SSL_FLUSH_BUFFERS";
|
||||
case MBEDTLS_SSL_HANDSHAKE_WRAPUP:
|
||||
return "MBEDTLS_SSL_HANDSHAKE_WRAPUP";
|
||||
case MBEDTLS_SSL_NEW_SESSION_TICKET:
|
||||
return "MBEDTLS_SSL_NEW_SESSION_TICKET";
|
||||
case MBEDTLS_SSL_SERVER_HELLO_VERIFY_REQUEST_SENT:
|
||||
return "MBEDTLS_SSL_SERVER_HELLO_VERIFY_REQUEST_SENT";
|
||||
case MBEDTLS_SSL_HELLO_RETRY_REQUEST:
|
||||
return "MBEDTLS_SSL_HELLO_RETRY_REQUEST";
|
||||
case MBEDTLS_SSL_ENCRYPTED_EXTENSIONS:
|
||||
return "MBEDTLS_SSL_ENCRYPTED_EXTENSIONS";
|
||||
case MBEDTLS_SSL_END_OF_EARLY_DATA:
|
||||
return "MBEDTLS_SSL_END_OF_EARLY_DATA";
|
||||
case MBEDTLS_SSL_CLIENT_CERTIFICATE_VERIFY:
|
||||
return "MBEDTLS_SSL_CLIENT_CERTIFICATE_VERIFY";
|
||||
case MBEDTLS_SSL_CLIENT_CCS_AFTER_SERVER_FINISHED:
|
||||
return "MBEDTLS_SSL_CLIENT_CCS_AFTER_SERVER_FINISHED";
|
||||
case MBEDTLS_SSL_CLIENT_CCS_BEFORE_2ND_CLIENT_HELLO:
|
||||
return "MBEDTLS_SSL_CLIENT_CCS_BEFORE_2ND_CLIENT_HELLO";
|
||||
case MBEDTLS_SSL_SERVER_CCS_AFTER_SERVER_HELLO:
|
||||
return "MBEDTLS_SSL_SERVER_CCS_AFTER_SERVER_HELLO";
|
||||
case MBEDTLS_SSL_CLIENT_CCS_AFTER_CLIENT_HELLO:
|
||||
return "MBEDTLS_SSL_CLIENT_CCS_AFTER_CLIENT_HELLO";
|
||||
case MBEDTLS_SSL_SERVER_CCS_AFTER_HELLO_RETRY_REQUEST:
|
||||
return "MBEDTLS_SSL_SERVER_CCS_AFTER_HELLO_RETRY_REQUEST";
|
||||
case MBEDTLS_SSL_HANDSHAKE_OVER:
|
||||
return "MBEDTLS_SSL_HANDSHAKE_OVER";
|
||||
case MBEDTLS_SSL_TLS1_3_NEW_SESSION_TICKET:
|
||||
return "MBEDTLS_SSL_TLS1_3_NEW_SESSION_TICKET";
|
||||
case MBEDTLS_SSL_TLS1_3_NEW_SESSION_TICKET_FLUSH:
|
||||
return "MBEDTLS_SSL_TLS1_3_NEW_SESSION_TICKET_FLUSH";
|
||||
default:
|
||||
return "UNKNOWN_VALUE";
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_EARLY_DATA) && defined(MBEDTLS_SSL_CLI_C)
|
||||
const char *mbedtls_ssl_early_data_status_str( mbedtls_ssl_early_data_status in )
|
||||
{
|
||||
switch (in) {
|
||||
case MBEDTLS_SSL_EARLY_DATA_STATUS_NOT_INDICATED:
|
||||
return "MBEDTLS_SSL_EARLY_DATA_STATUS_NOT_INDICATED";
|
||||
case MBEDTLS_SSL_EARLY_DATA_STATUS_ACCEPTED:
|
||||
return "MBEDTLS_SSL_EARLY_DATA_STATUS_ACCEPTED";
|
||||
case MBEDTLS_SSL_EARLY_DATA_STATUS_REJECTED:
|
||||
return "MBEDTLS_SSL_EARLY_DATA_STATUS_REJECTED";
|
||||
default:
|
||||
return "UNKNOWN_VALUE";
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* defined(MBEDTLS_SSL_EARLY_DATA) && defined(MBEDTLS_SSL_CLI_C) */
|
||||
const char *mbedtls_ssl_protocol_version_str( mbedtls_ssl_protocol_version in )
|
||||
{
|
||||
switch (in) {
|
||||
case MBEDTLS_SSL_VERSION_UNKNOWN:
|
||||
return "MBEDTLS_SSL_VERSION_UNKNOWN";
|
||||
case MBEDTLS_SSL_VERSION_TLS1_2:
|
||||
return "MBEDTLS_SSL_VERSION_TLS1_2";
|
||||
case MBEDTLS_SSL_VERSION_TLS1_3:
|
||||
return "MBEDTLS_SSL_VERSION_TLS1_3";
|
||||
default:
|
||||
return "UNKNOWN_VALUE";
|
||||
}
|
||||
}
|
||||
|
||||
const char *mbedtls_tls_prf_types_str( mbedtls_tls_prf_types in )
|
||||
{
|
||||
switch (in) {
|
||||
case MBEDTLS_SSL_TLS_PRF_NONE:
|
||||
return "MBEDTLS_SSL_TLS_PRF_NONE";
|
||||
case MBEDTLS_SSL_TLS_PRF_SHA384:
|
||||
return "MBEDTLS_SSL_TLS_PRF_SHA384";
|
||||
case MBEDTLS_SSL_TLS_PRF_SHA256:
|
||||
return "MBEDTLS_SSL_TLS_PRF_SHA256";
|
||||
case MBEDTLS_SSL_HKDF_EXPAND_SHA384:
|
||||
return "MBEDTLS_SSL_HKDF_EXPAND_SHA384";
|
||||
case MBEDTLS_SSL_HKDF_EXPAND_SHA256:
|
||||
return "MBEDTLS_SSL_HKDF_EXPAND_SHA256";
|
||||
default:
|
||||
return "UNKNOWN_VALUE";
|
||||
}
|
||||
}
|
||||
|
||||
const char *mbedtls_ssl_key_export_type_str( mbedtls_ssl_key_export_type in )
|
||||
{
|
||||
switch (in) {
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS12_MASTER_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS12_MASTER_SECRET";
|
||||
#if defined(MBEDTLS_SSL_PROTO_TLS1_3)
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_EARLY_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_EARLY_SECRET";
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_EARLY_EXPORTER_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_EARLY_EXPORTER_SECRET";
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_HANDSHAKE_TRAFFIC_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_HANDSHAKE_TRAFFIC_SECRET";
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_SERVER_HANDSHAKE_TRAFFIC_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_SERVER_HANDSHAKE_TRAFFIC_SECRET";
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_APPLICATION_TRAFFIC_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_CLIENT_APPLICATION_TRAFFIC_SECRET";
|
||||
case MBEDTLS_SSL_KEY_EXPORT_TLS1_3_SERVER_APPLICATION_TRAFFIC_SECRET:
|
||||
return "MBEDTLS_SSL_KEY_EXPORT_TLS1_3_SERVER_APPLICATION_TRAFFIC_SECRET";
|
||||
#endif
|
||||
default:
|
||||
return "UNKNOWN_VALUE";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif /* MBEDTLS_DEBUG_C */
|
||||
/* End of automatically generated file. */
|
||||
|
||||
@ -484,6 +484,99 @@ static inline size_t mbedtls_ssl_get_input_buflen(const mbedtls_ssl_context *ctx
|
||||
}
|
||||
#endif
|
||||
|
||||
/** Get `ssl->badmac_seen`. This field is encoded as
|
||||
* mbedtls_ssl_context::badmac_seen_or_in_hsfraglen in DTLS contexts,
|
||||
* and doesn't exist in TLS contexts.
|
||||
*
|
||||
* \param[in] ssl The SSL context to read.
|
||||
*
|
||||
* \return In DTLS, the value of `badmac_seen`. In TLS, 0 (there can't have
|
||||
* been a record with a bad MAC in TLS, since those abort the
|
||||
* connection immediately).
|
||||
*/
|
||||
static inline unsigned mbedtls_ssl_get_badmac_seen(const mbedtls_ssl_context *ssl)
|
||||
{
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
if (ssl->conf->transport == MBEDTLS_SSL_TRANSPORT_DATAGRAM) {
|
||||
return ssl->badmac_seen_or_in_hsfraglen;
|
||||
}
|
||||
#endif
|
||||
(void) ssl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
/* We shouldn't be trying to set badmac_seen if DTLS support is disabled
|
||||
* at compile time. If this is called from a code block that checks for the
|
||||
* DTLS protocol at run time, it should be guarded by
|
||||
* defined(MBEDTLS_SSL_PROTO_DTLS). */
|
||||
/** Set `ssl->badmac_seen`. This field is encoded as
|
||||
* mbedtls_ssl_context::badmac_seen_or_in_hsfraglen in DTLS contexts,
|
||||
* and doesn't exist in TLS contexts.
|
||||
*
|
||||
* \param[in,out] ssl The SSL context to modify.
|
||||
* \param badmac_seen The new value of `badmac_seen`.
|
||||
*
|
||||
* \return 0 in DTLS, #MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED in TLS.
|
||||
*/
|
||||
MBEDTLS_CHECK_RETURN_CRITICAL
|
||||
static inline int mbedtls_ssl_set_badmac_seen(mbedtls_ssl_context *ssl,
|
||||
unsigned badmac_seen)
|
||||
{
|
||||
if ((ssl)->conf->transport != MBEDTLS_SSL_TRANSPORT_DATAGRAM) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, ("Internal error: trying to set badmac_seen in TLS"),
|
||||
MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED);
|
||||
return MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
}
|
||||
ssl->badmac_seen_or_in_hsfraglen = badmac_seen;
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
/** Get `ssl->in_hsfraglen`. This field is encoded as
|
||||
* mbedtls_ssl_context::badmac_seen_or_in_hsfraglen in TLS contexts,
|
||||
* and doesn't exist in DTLS contexts.
|
||||
*
|
||||
* \param[in] ssl The SSL context to read.
|
||||
*
|
||||
* \return In TLS, the value of `in_hsfraglen`. In DTLS, 0 (handshake
|
||||
* message defragmentation is handled different in DTLS, and
|
||||
* does not use this field).
|
||||
*/
|
||||
static inline unsigned mbedtls_ssl_get_in_hsfraglen(const mbedtls_ssl_context *ssl)
|
||||
{
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
if (ssl->conf->transport == MBEDTLS_SSL_TRANSPORT_DATAGRAM) {
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
return ssl->badmac_seen_or_in_hsfraglen;
|
||||
}
|
||||
|
||||
/** Set `ssl->in_hsfraglen`. This field is encoded as
|
||||
* mbedtls_ssl_context::badmac_seen_or_in_hsfraglen in TLS contexts,
|
||||
* and doesn't exist in DTLS contexts.
|
||||
*
|
||||
* \param[in,out] ssl The SSL context to modify.
|
||||
* \param in_hsfraglen The new value of `in_hsfraglen`.
|
||||
*
|
||||
* \return 0 in TLS, #MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED in DTLS.
|
||||
*/
|
||||
MBEDTLS_CHECK_RETURN_CRITICAL
|
||||
static inline int mbedtls_ssl_set_in_hsfraglen(mbedtls_ssl_context *ssl,
|
||||
unsigned in_hsfraglen)
|
||||
{
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
if ((ssl)->conf->transport == MBEDTLS_SSL_TRANSPORT_DATAGRAM) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, ("Internal error: trying to set in_hsfraglen in DTLS"),
|
||||
MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED);
|
||||
return MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
}
|
||||
#endif
|
||||
ssl->badmac_seen_or_in_hsfraglen = in_hsfraglen;
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* TLS extension flags (for extensions with outgoing ServerHello content
|
||||
* that need it (e.g. for RENEGOTIATION_INFO the server already knows because
|
||||
|
||||
@ -3224,7 +3224,10 @@ static uint32_t ssl_get_hs_total_len(mbedtls_ssl_context const *ssl)
|
||||
|
||||
int mbedtls_ssl_prepare_handshake_record(mbedtls_ssl_context *ssl)
|
||||
{
|
||||
if (ssl->badmac_seen_or_in_hsfraglen == 0) {
|
||||
/* Set handshake record length if this is the first fragment.
|
||||
* Do it unconditionally for DTLS, for which handshake fragmentation
|
||||
* is handled completely differently. */
|
||||
if (mbedtls_ssl_get_in_hsfraglen(ssl) == 0) {
|
||||
/* The handshake message must at least include the header.
|
||||
* We may not have the full message yet in case of fragmentation.
|
||||
* To simplify the code, we insist on having the header (and in
|
||||
@ -3364,9 +3367,10 @@ int mbedtls_ssl_prepare_handshake_record(mbedtls_ssl_context *ssl)
|
||||
ssl->in_buf + MBEDTLS_SSL_SEQUENCE_NUMBER_LEN;
|
||||
unsigned char *const payload_start =
|
||||
reassembled_record_start + mbedtls_ssl_in_hdr_len(ssl);
|
||||
unsigned char *payload_end = payload_start + ssl->badmac_seen_or_in_hsfraglen;
|
||||
unsigned in_hsfraglen = mbedtls_ssl_get_in_hsfraglen(ssl);
|
||||
unsigned char *payload_end = payload_start + in_hsfraglen;
|
||||
/* How many more bytes we want to have a complete handshake message. */
|
||||
const size_t hs_remain = ssl->in_hslen - ssl->badmac_seen_or_in_hsfraglen;
|
||||
const size_t hs_remain = ssl->in_hslen - in_hsfraglen;
|
||||
/* How many bytes of the current record are part of the first
|
||||
* handshake message. There may be more handshake messages (possibly
|
||||
* incomplete) in the same record; if so, we leave them after the
|
||||
@ -3379,15 +3383,12 @@ int mbedtls_ssl_prepare_handshake_record(mbedtls_ssl_context *ssl)
|
||||
MBEDTLS_SSL_DEBUG_MSG(3,
|
||||
("%s handshake fragment: %" MBEDTLS_PRINTF_SIZET
|
||||
", %u..%u of %" MBEDTLS_PRINTF_SIZET,
|
||||
(ssl->badmac_seen_or_in_hsfraglen != 0 ?
|
||||
"subsequent" :
|
||||
hs_this_fragment_len == ssl->in_hslen ?
|
||||
"sole" :
|
||||
(in_hsfraglen != 0 ? "subsequent" :
|
||||
hs_this_fragment_len == ssl->in_hslen ? "sole" :
|
||||
"initial"),
|
||||
ssl->in_msglen,
|
||||
ssl->badmac_seen_or_in_hsfraglen,
|
||||
ssl->badmac_seen_or_in_hsfraglen +
|
||||
(unsigned) hs_this_fragment_len,
|
||||
in_hsfraglen,
|
||||
in_hsfraglen + (unsigned) hs_this_fragment_len,
|
||||
ssl->in_hslen));
|
||||
|
||||
/* Move the received handshake fragment to have the whole message
|
||||
@ -3417,20 +3418,25 @@ int mbedtls_ssl_prepare_handshake_record(mbedtls_ssl_context *ssl)
|
||||
}
|
||||
memmove(payload_end, ssl->in_msg, ssl->in_msglen);
|
||||
|
||||
ssl->badmac_seen_or_in_hsfraglen += (unsigned) ssl->in_msglen;
|
||||
in_hsfraglen += (unsigned) ssl->in_msglen;
|
||||
payload_end += ssl->in_msglen;
|
||||
|
||||
if (ssl->badmac_seen_or_in_hsfraglen < ssl->in_hslen) {
|
||||
if (in_hsfraglen < ssl->in_hslen) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(3, ("Prepare: waiting for more handshake fragments "
|
||||
"%u/%" MBEDTLS_PRINTF_SIZET,
|
||||
ssl->badmac_seen_or_in_hsfraglen, ssl->in_hslen));
|
||||
in_hsfraglen, ssl->in_hslen));
|
||||
ssl->in_hdr = payload_end;
|
||||
ssl->in_msglen = 0;
|
||||
if (mbedtls_ssl_set_in_hsfraglen(ssl, in_hsfraglen) != 0) {
|
||||
return MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
}
|
||||
mbedtls_ssl_update_in_pointers(ssl);
|
||||
return MBEDTLS_ERR_SSL_CONTINUE_PROCESSING;
|
||||
} else {
|
||||
ssl->in_msglen = ssl->badmac_seen_or_in_hsfraglen;
|
||||
ssl->badmac_seen_or_in_hsfraglen = 0;
|
||||
ssl->in_msglen = in_hsfraglen;
|
||||
if (mbedtls_ssl_set_in_hsfraglen(ssl, 0) != 0) {
|
||||
return MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
}
|
||||
ssl->in_hdr = reassembled_record_start;
|
||||
mbedtls_ssl_update_in_pointers(ssl);
|
||||
|
||||
@ -4785,11 +4791,11 @@ static int ssl_consume_current_message(mbedtls_ssl_context *ssl)
|
||||
return MBEDTLS_ERR_SSL_INTERNAL_ERROR;
|
||||
}
|
||||
|
||||
if (ssl->badmac_seen_or_in_hsfraglen != 0) {
|
||||
if (mbedtls_ssl_get_in_hsfraglen(ssl) != 0) {
|
||||
/* Not all handshake fragments have arrived, do not consume. */
|
||||
MBEDTLS_SSL_DEBUG_MSG(3, ("Consume: waiting for more handshake fragments "
|
||||
"%u/%" MBEDTLS_PRINTF_SIZET,
|
||||
ssl->badmac_seen_or_in_hsfraglen, ssl->in_hslen));
|
||||
mbedtls_ssl_get_in_hsfraglen(ssl), ssl->in_hslen));
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -5147,8 +5153,11 @@ static int ssl_get_next_record(mbedtls_ssl_context *ssl)
|
||||
}
|
||||
|
||||
if (ssl->conf->badmac_limit != 0) {
|
||||
++ssl->badmac_seen_or_in_hsfraglen;
|
||||
if (ssl->badmac_seen_or_in_hsfraglen >= ssl->conf->badmac_limit) {
|
||||
unsigned badmac_seen = mbedtls_ssl_get_badmac_seen(ssl) + 1;
|
||||
if (mbedtls_ssl_set_badmac_seen(ssl, badmac_seen) != 0) {
|
||||
return MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
}
|
||||
if (badmac_seen >= ssl->conf->badmac_limit) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("too many records with bad MAC"));
|
||||
return MBEDTLS_ERR_SSL_INVALID_MAC;
|
||||
}
|
||||
@ -5208,8 +5217,7 @@ int mbedtls_ssl_handle_message_type(mbedtls_ssl_context *ssl)
|
||||
* we don't accept any other message type. For TLS 1.3, the spec forbids
|
||||
* interleaving other message types between handshake fragments. For TLS
|
||||
* 1.2, the spec does not forbid it but we do. */
|
||||
if (ssl->conf->transport == MBEDTLS_SSL_TRANSPORT_STREAM &&
|
||||
ssl->badmac_seen_or_in_hsfraglen != 0 &&
|
||||
if (mbedtls_ssl_get_in_hsfraglen(ssl) != 0 &&
|
||||
ssl->in_msgtype != MBEDTLS_SSL_MSG_HANDSHAKE) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("non-handshake message in the middle"
|
||||
" of a fragmented handshake message"));
|
||||
|
||||
@ -31,8 +31,6 @@
|
||||
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
#include "mbedtls/psa_util.h"
|
||||
#include "md_psa.h"
|
||||
#include "psa_util_internal.h"
|
||||
#include "psa/crypto.h"
|
||||
#endif
|
||||
|
||||
@ -857,11 +855,11 @@ int mbedtls_ssl_reset_checksum(mbedtls_ssl_context *ssl)
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
status = psa_hash_abort(&ssl->handshake->fin_sha256_psa);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
status = psa_hash_setup(&ssl->handshake->fin_sha256_psa, PSA_ALG_SHA_256);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
#else
|
||||
mbedtls_md_free(&ssl->handshake->fin_sha256);
|
||||
@ -882,11 +880,11 @@ int mbedtls_ssl_reset_checksum(mbedtls_ssl_context *ssl)
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
status = psa_hash_abort(&ssl->handshake->fin_sha384_psa);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
status = psa_hash_setup(&ssl->handshake->fin_sha384_psa, PSA_ALG_SHA_384);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
#else
|
||||
mbedtls_md_free(&ssl->handshake->fin_sha384);
|
||||
@ -924,7 +922,7 @@ static int ssl_update_checksum_start(mbedtls_ssl_context *ssl,
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
status = psa_hash_update(&ssl->handshake->fin_sha256_psa, buf, len);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
#else
|
||||
ret = mbedtls_md_update(&ssl->handshake->fin_sha256, buf, len);
|
||||
@ -937,7 +935,7 @@ static int ssl_update_checksum_start(mbedtls_ssl_context *ssl,
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
status = psa_hash_update(&ssl->handshake->fin_sha384_psa, buf, len);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
#else
|
||||
ret = mbedtls_md_update(&ssl->handshake->fin_sha384, buf, len);
|
||||
@ -954,8 +952,8 @@ static int ssl_update_checksum_sha256(mbedtls_ssl_context *ssl,
|
||||
const unsigned char *buf, size_t len)
|
||||
{
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
return mbedtls_md_error_from_psa(psa_hash_update(
|
||||
&ssl->handshake->fin_sha256_psa, buf, len));
|
||||
return PSA_TO_MBEDTLS_ERR(psa_hash_update(
|
||||
&ssl->handshake->fin_sha256_psa, buf, len));
|
||||
#else
|
||||
return mbedtls_md_update(&ssl->handshake->fin_sha256, buf, len);
|
||||
#endif
|
||||
@ -967,8 +965,8 @@ static int ssl_update_checksum_sha384(mbedtls_ssl_context *ssl,
|
||||
const unsigned char *buf, size_t len)
|
||||
{
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
return mbedtls_md_error_from_psa(psa_hash_update(
|
||||
&ssl->handshake->fin_sha384_psa, buf, len));
|
||||
return PSA_TO_MBEDTLS_ERR(psa_hash_update(
|
||||
&ssl->handshake->fin_sha384_psa, buf, len));
|
||||
#else
|
||||
return mbedtls_md_update(&ssl->handshake->fin_sha384, buf, len);
|
||||
#endif
|
||||
@ -1520,6 +1518,8 @@ void mbedtls_ssl_session_reset_msg_layer(mbedtls_ssl_context *ssl,
|
||||
}
|
||||
|
||||
ssl->send_alert = 0;
|
||||
ssl->alert_reason = 0;
|
||||
ssl->alert_type = 0;
|
||||
|
||||
/* Reset outgoing message writing */
|
||||
ssl->out_msgtype = 0;
|
||||
@ -1593,6 +1593,10 @@ int mbedtls_ssl_session_reset_int(mbedtls_ssl_context *ssl, int partial)
|
||||
ssl->alpn_chosen = NULL;
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_SSL_DTLS_SRTP)
|
||||
memset(&ssl->dtls_srtp_info, 0, sizeof(ssl->dtls_srtp_info));
|
||||
#endif /* MBEDTLS_SSL_DTLS_SRTP */
|
||||
|
||||
#if defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY) && defined(MBEDTLS_SSL_SRV_C)
|
||||
int free_cli_id = 1;
|
||||
#if defined(MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE)
|
||||
@ -7111,11 +7115,16 @@ static int ssl_compute_master(mbedtls_ssl_handshake_params *handshake,
|
||||
#if defined(MBEDTLS_SSL_EXTENDED_MASTER_SECRET)
|
||||
if (handshake->extended_ms == MBEDTLS_SSL_EXTENDED_MS_ENABLED) {
|
||||
lbl = "extended master secret";
|
||||
seed = session_hash;
|
||||
ret = handshake->calc_verify(ssl, session_hash, &seed_len);
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "calc_verify", ret);
|
||||
return ret;
|
||||
}
|
||||
if (seed_len > sizeof(session_hash)) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("bad session hash length"));
|
||||
return MBEDTLS_ERR_SSL_INTERNAL_ERROR;
|
||||
}
|
||||
seed = session_hash;
|
||||
|
||||
MBEDTLS_SSL_DEBUG_BUF(3, "session hash for extended master secret",
|
||||
session_hash, seed_len);
|
||||
@ -7371,7 +7380,7 @@ static int ssl_calc_verify_tls_psa(const mbedtls_ssl_context *ssl,
|
||||
|
||||
exit:
|
||||
psa_hash_abort(&cloned_op);
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
}
|
||||
#else
|
||||
static int ssl_calc_verify_tls_legacy(const mbedtls_ssl_context *ssl,
|
||||
@ -8270,7 +8279,7 @@ static int ssl_calc_finished_tls_generic(mbedtls_ssl_context *ssl, void *ctx,
|
||||
exit:
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
psa_hash_abort(&cloned_op);
|
||||
return mbedtls_md_error_from_psa(status);
|
||||
return PSA_TO_MBEDTLS_ERR(status);
|
||||
#else
|
||||
mbedtls_md_free(&cloned_ctx);
|
||||
return ret;
|
||||
|
||||
@ -2325,6 +2325,8 @@ start_processing:
|
||||
* However since we only support secp256r1 for now, we check only
|
||||
* that TLS ID here
|
||||
*/
|
||||
MBEDTLS_SSL_CHK_BUF_READ_PTR(p, end, 3);
|
||||
|
||||
uint16_t read_tls_id = MBEDTLS_GET_UINT16_BE(p, 1);
|
||||
uint16_t exp_tls_id = mbedtls_ssl_get_tls_id_from_ecp_group_id(
|
||||
MBEDTLS_ECP_DP_SECP256R1);
|
||||
@ -2952,7 +2954,7 @@ ecdh_calc_secret:
|
||||
if ((ret = mbedtls_ecdh_calc_secret(&ssl->handshake->ecdh_ctx,
|
||||
&ssl->handshake->pmslen,
|
||||
ssl->handshake->premaster,
|
||||
MBEDTLS_MPI_MAX_SIZE,
|
||||
MBEDTLS_PREMASTER_SIZE,
|
||||
ssl->conf->f_rng, ssl->conf->p_rng)) != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ecdh_calc_secret", ret);
|
||||
#if defined(MBEDTLS_SSL_ECP_RESTARTABLE_ENABLED)
|
||||
@ -2992,11 +2994,16 @@ ecdh_calc_secret:
|
||||
|
||||
/* uint16 to store content length */
|
||||
const size_t content_len_size = 2;
|
||||
const size_t ecpoint_len_size = 1;
|
||||
const size_t ecpoint_max_len =
|
||||
PSA_EXPORT_PUBLIC_KEY_OUTPUT_SIZE(handshake->xxdh_psa_type,
|
||||
handshake->xxdh_psa_bits);
|
||||
|
||||
header_len = 4;
|
||||
|
||||
if (header_len + content_len_size + ssl->conf->psk_identity_len
|
||||
> MBEDTLS_SSL_OUT_CONTENT_LEN) {
|
||||
if (ecpoint_max_len > MBEDTLS_SSL_OUT_CONTENT_LEN - ecpoint_len_size ||
|
||||
header_len + content_len_size + ssl->conf->psk_identity_len
|
||||
> MBEDTLS_SSL_OUT_CONTENT_LEN - ecpoint_len_size - ecpoint_max_len) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1,
|
||||
("psk identity too long or SSL buffer too short"));
|
||||
return MBEDTLS_ERR_SSL_BUFFER_TOO_SMALL;
|
||||
|
||||
@ -1790,9 +1790,9 @@ static void ssl_write_supported_point_formats_ext(mbedtls_ssl_context *ssl,
|
||||
MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED */
|
||||
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED)
|
||||
static void ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
unsigned char *buf,
|
||||
size_t *olen)
|
||||
static int ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
unsigned char *buf,
|
||||
size_t *olen)
|
||||
{
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
unsigned char *p = buf;
|
||||
@ -1804,14 +1804,14 @@ static void ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
/* Skip costly computation if not needed */
|
||||
if (ssl->handshake->ciphersuite_info->key_exchange !=
|
||||
MBEDTLS_KEY_EXCHANGE_ECJPAKE) {
|
||||
return;
|
||||
return 0;
|
||||
}
|
||||
|
||||
MBEDTLS_SSL_DEBUG_MSG(3, ("server hello, ecjpake kkpp extension"));
|
||||
|
||||
if (end - p < 4) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("buffer too small"));
|
||||
return;
|
||||
return MBEDTLS_ERR_SSL_BUFFER_TOO_SMALL;
|
||||
}
|
||||
|
||||
MBEDTLS_PUT_UINT16_BE(MBEDTLS_TLS_EXT_ECJPAKE_KKPP, p, 0);
|
||||
@ -1825,7 +1825,7 @@ static void ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
psa_destroy_key(ssl->handshake->psa_pake_password);
|
||||
psa_pake_abort(&ssl->handshake->psa_pake_ctx);
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "psa_pake_output", ret);
|
||||
return;
|
||||
return ret;
|
||||
}
|
||||
#else
|
||||
ret = mbedtls_ecjpake_write_round_one(&ssl->handshake->ecjpake_ctx,
|
||||
@ -1833,7 +1833,7 @@ static void ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
ssl->conf->f_rng, ssl->conf->p_rng);
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ecjpake_write_round_one", ret);
|
||||
return;
|
||||
return ret;
|
||||
}
|
||||
#endif /* MBEDTLS_USE_PSA_CRYPTO */
|
||||
|
||||
@ -1841,6 +1841,7 @@ static void ssl_write_ecjpake_kkpp_ext(mbedtls_ssl_context *ssl,
|
||||
p += 2;
|
||||
|
||||
*olen = kkpp_len + 4;
|
||||
return 0;
|
||||
}
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED */
|
||||
|
||||
@ -2223,7 +2224,11 @@ static int ssl_write_server_hello(mbedtls_ssl_context *ssl)
|
||||
#endif
|
||||
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED)
|
||||
ssl_write_ecjpake_kkpp_ext(ssl, p + 2 + ext_len, &olen);
|
||||
ret = ssl_write_ecjpake_kkpp_ext(ssl, p + 2 + ext_len, &olen);
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "ssl_write_ecjpake_kkpp_ext", ret);
|
||||
return ret;
|
||||
}
|
||||
ext_len += olen;
|
||||
#endif
|
||||
|
||||
@ -3675,7 +3680,7 @@ static int ssl_parse_client_key_exchange(mbedtls_ssl_context *ssl)
|
||||
if ((ret = mbedtls_ecdh_calc_secret(&ssl->handshake->ecdh_ctx,
|
||||
&ssl->handshake->pmslen,
|
||||
ssl->handshake->premaster,
|
||||
MBEDTLS_MPI_MAX_SIZE,
|
||||
MBEDTLS_PREMASTER_SIZE,
|
||||
ssl->conf->f_rng, ssl->conf->p_rng)) != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ecdh_calc_secret", ret);
|
||||
return MBEDTLS_ERR_SSL_DECODE_ERROR;
|
||||
@ -4132,8 +4137,8 @@ MBEDTLS_CHECK_RETURN_CRITICAL
|
||||
static int ssl_write_new_session_ticket(mbedtls_ssl_context *ssl)
|
||||
{
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
size_t tlen;
|
||||
uint32_t lifetime;
|
||||
size_t tlen = 0;
|
||||
uint32_t lifetime = 0;
|
||||
|
||||
MBEDTLS_SSL_DEBUG_MSG(2, ("=> write new session ticket"));
|
||||
|
||||
@ -4160,7 +4165,6 @@ static int ssl_write_new_session_ticket(mbedtls_ssl_context *ssl)
|
||||
ssl->out_msg + MBEDTLS_SSL_OUT_CONTENT_LEN,
|
||||
&tlen, &lifetime)) != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ssl_ticket_write", ret);
|
||||
tlen = 0;
|
||||
}
|
||||
|
||||
MBEDTLS_PUT_UINT32_BE(lifetime, ssl->out_msg, 4);
|
||||
|
||||
@ -405,14 +405,18 @@ static int ssl_tls13_parse_hrr_key_share_ext(mbedtls_ssl_context *ssl,
|
||||
* then the client MUST abort the handshake with an "illegal_parameter" alert.
|
||||
*/
|
||||
for (; *group_list != 0; group_list++) {
|
||||
if (*group_list != selected_group) {
|
||||
continue;
|
||||
}
|
||||
#if defined(PSA_WANT_ALG_ECDH)
|
||||
if (mbedtls_ssl_tls13_named_group_is_ecdhe(*group_list)) {
|
||||
if ((mbedtls_ssl_get_psa_curve_info_from_tls_id(
|
||||
*group_list, NULL, NULL) == PSA_ERROR_NOT_SUPPORTED) ||
|
||||
*group_list != selected_group) {
|
||||
found = 1;
|
||||
break;
|
||||
if (mbedtls_ssl_get_psa_curve_info_from_tls_id(
|
||||
*group_list, NULL, NULL) == PSA_ERROR_NOT_SUPPORTED) {
|
||||
continue;
|
||||
}
|
||||
/* Found only if psa_curve is supported and group_list == selected_group */
|
||||
found = 1;
|
||||
break;
|
||||
}
|
||||
#endif /* PSA_WANT_ALG_ECDH */
|
||||
#if defined(PSA_WANT_ALG_FFDH)
|
||||
@ -2018,6 +2022,19 @@ static int ssl_tls13_process_server_hello(mbedtls_ssl_context *ssl)
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
/*
|
||||
* TLS 1.3 is negotiated. Check that ServerHello/HRR ends at a record
|
||||
* boundary. For HRR, which does not trigger a key update, this checks
|
||||
* that HRR terminates the server flight.
|
||||
*/
|
||||
if (ssl->in_hslen != ssl->in_msglen) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("ServerHello end not aligned with a record boundary"));
|
||||
ret = MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE;
|
||||
MBEDTLS_SSL_PEND_FATAL_ALERT(MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE,
|
||||
MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE);
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
MBEDTLS_SSL_PROC_CHK(ssl_tls13_parse_server_hello(ssl, buf,
|
||||
buf + buf_len,
|
||||
is_hrr));
|
||||
@ -2806,6 +2823,7 @@ static int ssl_tls13_parse_new_session_ticket_exts(mbedtls_ssl_context *ssl,
|
||||
MBEDTLS_SSL_DEBUG_RET(
|
||||
1, "ssl_tls13_parse_new_session_ticket_early_data_ext",
|
||||
ret);
|
||||
return ret;
|
||||
}
|
||||
break;
|
||||
#endif /* MBEDTLS_SSL_EARLY_DATA */
|
||||
|
||||
@ -59,20 +59,55 @@ int mbedtls_ssl_tls13_fetch_handshake_msg(mbedtls_ssl_context *ssl,
|
||||
unsigned char **buf,
|
||||
size_t *buf_len)
|
||||
{
|
||||
int ret;
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
int require_record_boundary;
|
||||
|
||||
if ((ret = mbedtls_ssl_read_record(ssl, 0)) != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ssl_read_record", ret);
|
||||
goto cleanup;
|
||||
/* Require record-boundary alignment by default. The exceptions below are
|
||||
* handshake messages that may legitimately be followed by additional
|
||||
* handshake messages in the same record. Using the default behaviour for a
|
||||
* message that should be exempt is an interoperability bug; exempting a
|
||||
* message that should not be exempt may have security implications.
|
||||
*/
|
||||
switch (hs_type) {
|
||||
case MBEDTLS_SSL_HS_NEW_SESSION_TICKET:
|
||||
case MBEDTLS_SSL_HS_ENCRYPTED_EXTENSIONS:
|
||||
case MBEDTLS_SSL_HS_CERTIFICATE:
|
||||
case MBEDTLS_SSL_HS_CERTIFICATE_REQUEST:
|
||||
case MBEDTLS_SSL_HS_CERTIFICATE_VERIFY:
|
||||
/*
|
||||
* For TLS 1.3, ServerHello (including HelloRetryRequest) must end at a
|
||||
* record boundary, but not for TLS 1.2. At this point the ServerHello
|
||||
* has not yet been processed, so we do not know whether it negotiates
|
||||
* TLS 1.3 or TLS 1.2. Defer the boundary check until the protocol
|
||||
* version is known to be TLS 1.3.
|
||||
*/
|
||||
case MBEDTLS_SSL_HS_SERVER_HELLO:
|
||||
require_record_boundary = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
/* ClientHello, EndOfEarlyData, Finished, and KeyUpdate.
|
||||
*/
|
||||
require_record_boundary = 1;
|
||||
}
|
||||
|
||||
ret = mbedtls_ssl_read_record(ssl, 0);
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ssl_read_record", ret);
|
||||
goto error;
|
||||
}
|
||||
|
||||
ret = MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE;
|
||||
if (ssl->in_msgtype != MBEDTLS_SSL_MSG_HANDSHAKE ||
|
||||
ssl->in_msg[0] != hs_type) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("Receive unexpected handshake message."));
|
||||
MBEDTLS_SSL_PEND_FATAL_ALERT(MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE,
|
||||
MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE);
|
||||
ret = MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE;
|
||||
goto cleanup;
|
||||
goto error;
|
||||
}
|
||||
|
||||
if (require_record_boundary && (ssl->in_hslen != ssl->in_msglen)) {
|
||||
MBEDTLS_SSL_DEBUG_MSG(1, ("Handshake message %s end not aligned with a record boundary",
|
||||
mbedtls_ssl_get_hs_msg_name(hs_type)));
|
||||
goto error;
|
||||
}
|
||||
|
||||
/*
|
||||
@ -82,11 +117,15 @@ int mbedtls_ssl_tls13_fetch_handshake_msg(mbedtls_ssl_context *ssl,
|
||||
* uint24 length;
|
||||
* ...
|
||||
*/
|
||||
*buf = ssl->in_msg + 4;
|
||||
*buf = ssl->in_msg + 4;
|
||||
*buf_len = ssl->in_hslen - 4;
|
||||
return 0;
|
||||
|
||||
cleanup:
|
||||
|
||||
error:
|
||||
if (ret == MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE) {
|
||||
MBEDTLS_SSL_PEND_FATAL_ALERT(MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE,
|
||||
MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
@ -3098,6 +3098,7 @@ static int ssl_tls13_process_client_finished(mbedtls_ssl_context *ssl)
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(
|
||||
1, "mbedtls_ssl_tls13_compute_resumption_master_secret", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
mbedtls_ssl_handshake_set_state(ssl, MBEDTLS_SSL_HANDSHAKE_WRAPUP);
|
||||
@ -3204,9 +3205,10 @@ static int ssl_tls13_prepare_new_session_ticket(mbedtls_ssl_context *ssl,
|
||||
#endif
|
||||
|
||||
/* Generate ticket_age_add */
|
||||
if ((ret = ssl->conf->f_rng(ssl->conf->p_rng,
|
||||
(unsigned char *) &session->ticket_age_add,
|
||||
sizeof(session->ticket_age_add)) != 0)) {
|
||||
ret = ssl->conf->f_rng(ssl->conf->p_rng,
|
||||
(unsigned char *) &session->ticket_age_add,
|
||||
sizeof(session->ticket_age_add));
|
||||
if (ret != 0) {
|
||||
MBEDTLS_SSL_DEBUG_RET(1, "generate_ticket_age_add", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
856
library/version_features.c
Normal file
856
library/version_features.c
Normal file
@ -0,0 +1,856 @@
|
||||
/*
|
||||
* Version feature information
|
||||
*
|
||||
* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "common.h"
|
||||
|
||||
#if defined(MBEDTLS_VERSION_C)
|
||||
|
||||
#include "mbedtls/version.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
static const char * const features[] = {
|
||||
#if defined(MBEDTLS_VERSION_FEATURES)
|
||||
#if defined(MBEDTLS_HAVE_ASM)
|
||||
"HAVE_ASM", //no-check-names
|
||||
#endif /* MBEDTLS_HAVE_ASM */
|
||||
#if defined(MBEDTLS_NO_UDBL_DIVISION)
|
||||
"NO_UDBL_DIVISION", //no-check-names
|
||||
#endif /* MBEDTLS_NO_UDBL_DIVISION */
|
||||
#if defined(MBEDTLS_NO_64BIT_MULTIPLICATION)
|
||||
"NO_64BIT_MULTIPLICATION", //no-check-names
|
||||
#endif /* MBEDTLS_NO_64BIT_MULTIPLICATION */
|
||||
#if defined(MBEDTLS_HAVE_SSE2)
|
||||
"HAVE_SSE2", //no-check-names
|
||||
#endif /* MBEDTLS_HAVE_SSE2 */
|
||||
#if defined(MBEDTLS_HAVE_TIME)
|
||||
"HAVE_TIME", //no-check-names
|
||||
#endif /* MBEDTLS_HAVE_TIME */
|
||||
#if defined(MBEDTLS_HAVE_TIME_DATE)
|
||||
"HAVE_TIME_DATE", //no-check-names
|
||||
#endif /* MBEDTLS_HAVE_TIME_DATE */
|
||||
#if defined(MBEDTLS_PLATFORM_MEMORY)
|
||||
"PLATFORM_MEMORY", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_MEMORY */
|
||||
#if defined(MBEDTLS_PLATFORM_NO_STD_FUNCTIONS)
|
||||
"PLATFORM_NO_STD_FUNCTIONS", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_NO_STD_FUNCTIONS */
|
||||
#if defined(MBEDTLS_PLATFORM_SETBUF_ALT)
|
||||
"PLATFORM_SETBUF_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_SETBUF_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_EXIT_ALT)
|
||||
"PLATFORM_EXIT_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_EXIT_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_TIME_ALT)
|
||||
"PLATFORM_TIME_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_TIME_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_FPRINTF_ALT)
|
||||
"PLATFORM_FPRINTF_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_FPRINTF_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_PRINTF_ALT)
|
||||
"PLATFORM_PRINTF_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_PRINTF_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_SNPRINTF_ALT)
|
||||
"PLATFORM_SNPRINTF_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_SNPRINTF_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_VSNPRINTF_ALT)
|
||||
"PLATFORM_VSNPRINTF_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_VSNPRINTF_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_NV_SEED_ALT)
|
||||
"PLATFORM_NV_SEED_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_NV_SEED_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT)
|
||||
"PLATFORM_SETUP_TEARDOWN_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_SETUP_TEARDOWN_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_MS_TIME_ALT)
|
||||
"PLATFORM_MS_TIME_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_MS_TIME_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_GMTIME_R_ALT)
|
||||
"PLATFORM_GMTIME_R_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_GMTIME_R_ALT */
|
||||
#if defined(MBEDTLS_PLATFORM_ZEROIZE_ALT)
|
||||
"PLATFORM_ZEROIZE_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_ZEROIZE_ALT */
|
||||
#if defined(MBEDTLS_DEPRECATED_WARNING)
|
||||
"DEPRECATED_WARNING", //no-check-names
|
||||
#endif /* MBEDTLS_DEPRECATED_WARNING */
|
||||
#if defined(MBEDTLS_DEPRECATED_REMOVED)
|
||||
"DEPRECATED_REMOVED", //no-check-names
|
||||
#endif /* MBEDTLS_DEPRECATED_REMOVED */
|
||||
#if defined(MBEDTLS_TIMING_ALT)
|
||||
"TIMING_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_TIMING_ALT */
|
||||
#if defined(MBEDTLS_AES_ALT)
|
||||
"AES_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_AES_ALT */
|
||||
#if defined(MBEDTLS_ARIA_ALT)
|
||||
"ARIA_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ARIA_ALT */
|
||||
#if defined(MBEDTLS_CAMELLIA_ALT)
|
||||
"CAMELLIA_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_CAMELLIA_ALT */
|
||||
#if defined(MBEDTLS_CCM_ALT)
|
||||
"CCM_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_CCM_ALT */
|
||||
#if defined(MBEDTLS_CHACHA20_ALT)
|
||||
"CHACHA20_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_CHACHA20_ALT */
|
||||
#if defined(MBEDTLS_CHACHAPOLY_ALT)
|
||||
"CHACHAPOLY_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_CHACHAPOLY_ALT */
|
||||
#if defined(MBEDTLS_CMAC_ALT)
|
||||
"CMAC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_CMAC_ALT */
|
||||
#if defined(MBEDTLS_DES_ALT)
|
||||
"DES_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_DES_ALT */
|
||||
#if defined(MBEDTLS_DHM_ALT)
|
||||
"DHM_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_DHM_ALT */
|
||||
#if defined(MBEDTLS_ECJPAKE_ALT)
|
||||
"ECJPAKE_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECJPAKE_ALT */
|
||||
#if defined(MBEDTLS_GCM_ALT)
|
||||
"GCM_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_GCM_ALT */
|
||||
#if defined(MBEDTLS_NIST_KW_ALT)
|
||||
"NIST_KW_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_NIST_KW_ALT */
|
||||
#if defined(MBEDTLS_MD5_ALT)
|
||||
"MD5_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_MD5_ALT */
|
||||
#if defined(MBEDTLS_POLY1305_ALT)
|
||||
"POLY1305_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_POLY1305_ALT */
|
||||
#if defined(MBEDTLS_RIPEMD160_ALT)
|
||||
"RIPEMD160_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_RIPEMD160_ALT */
|
||||
#if defined(MBEDTLS_RSA_ALT)
|
||||
"RSA_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_RSA_ALT */
|
||||
#if defined(MBEDTLS_SHA1_ALT)
|
||||
"SHA1_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA1_ALT */
|
||||
#if defined(MBEDTLS_SHA256_ALT)
|
||||
"SHA256_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_ALT */
|
||||
#if defined(MBEDTLS_SHA512_ALT)
|
||||
"SHA512_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_ALT */
|
||||
#if defined(MBEDTLS_ECP_ALT)
|
||||
"ECP_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_ALT */
|
||||
#if defined(MBEDTLS_MD5_PROCESS_ALT)
|
||||
"MD5_PROCESS_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_MD5_PROCESS_ALT */
|
||||
#if defined(MBEDTLS_RIPEMD160_PROCESS_ALT)
|
||||
"RIPEMD160_PROCESS_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_RIPEMD160_PROCESS_ALT */
|
||||
#if defined(MBEDTLS_SHA1_PROCESS_ALT)
|
||||
"SHA1_PROCESS_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA1_PROCESS_ALT */
|
||||
#if defined(MBEDTLS_SHA256_PROCESS_ALT)
|
||||
"SHA256_PROCESS_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_PROCESS_ALT */
|
||||
#if defined(MBEDTLS_SHA512_PROCESS_ALT)
|
||||
"SHA512_PROCESS_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_PROCESS_ALT */
|
||||
#if defined(MBEDTLS_DES_SETKEY_ALT)
|
||||
"DES_SETKEY_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_DES_SETKEY_ALT */
|
||||
#if defined(MBEDTLS_DES_CRYPT_ECB_ALT)
|
||||
"DES_CRYPT_ECB_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_DES_CRYPT_ECB_ALT */
|
||||
#if defined(MBEDTLS_DES3_CRYPT_ECB_ALT)
|
||||
"DES3_CRYPT_ECB_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_DES3_CRYPT_ECB_ALT */
|
||||
#if defined(MBEDTLS_AES_SETKEY_ENC_ALT)
|
||||
"AES_SETKEY_ENC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_AES_SETKEY_ENC_ALT */
|
||||
#if defined(MBEDTLS_AES_SETKEY_DEC_ALT)
|
||||
"AES_SETKEY_DEC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_AES_SETKEY_DEC_ALT */
|
||||
#if defined(MBEDTLS_AES_ENCRYPT_ALT)
|
||||
"AES_ENCRYPT_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_AES_ENCRYPT_ALT */
|
||||
#if defined(MBEDTLS_AES_DECRYPT_ALT)
|
||||
"AES_DECRYPT_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_AES_DECRYPT_ALT */
|
||||
#if defined(MBEDTLS_ECDH_GEN_PUBLIC_ALT)
|
||||
"ECDH_GEN_PUBLIC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECDH_GEN_PUBLIC_ALT */
|
||||
#if defined(MBEDTLS_ECDH_COMPUTE_SHARED_ALT)
|
||||
"ECDH_COMPUTE_SHARED_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECDH_COMPUTE_SHARED_ALT */
|
||||
#if defined(MBEDTLS_ECDSA_VERIFY_ALT)
|
||||
"ECDSA_VERIFY_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECDSA_VERIFY_ALT */
|
||||
#if defined(MBEDTLS_ECDSA_SIGN_ALT)
|
||||
"ECDSA_SIGN_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECDSA_SIGN_ALT */
|
||||
#if defined(MBEDTLS_ECDSA_GENKEY_ALT)
|
||||
"ECDSA_GENKEY_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECDSA_GENKEY_ALT */
|
||||
#if defined(MBEDTLS_ECP_INTERNAL_ALT)
|
||||
"ECP_INTERNAL_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_INTERNAL_ALT */
|
||||
#if defined(MBEDTLS_ECP_NO_FALLBACK)
|
||||
"ECP_NO_FALLBACK", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_NO_FALLBACK */
|
||||
#if defined(MBEDTLS_ECP_RANDOMIZE_JAC_ALT)
|
||||
"ECP_RANDOMIZE_JAC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_RANDOMIZE_JAC_ALT */
|
||||
#if defined(MBEDTLS_ECP_ADD_MIXED_ALT)
|
||||
"ECP_ADD_MIXED_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_ADD_MIXED_ALT */
|
||||
#if defined(MBEDTLS_ECP_DOUBLE_JAC_ALT)
|
||||
"ECP_DOUBLE_JAC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DOUBLE_JAC_ALT */
|
||||
#if defined(MBEDTLS_ECP_NORMALIZE_JAC_MANY_ALT)
|
||||
"ECP_NORMALIZE_JAC_MANY_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_NORMALIZE_JAC_MANY_ALT */
|
||||
#if defined(MBEDTLS_ECP_NORMALIZE_JAC_ALT)
|
||||
"ECP_NORMALIZE_JAC_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_NORMALIZE_JAC_ALT */
|
||||
#if defined(MBEDTLS_ECP_DOUBLE_ADD_MXZ_ALT)
|
||||
"ECP_DOUBLE_ADD_MXZ_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DOUBLE_ADD_MXZ_ALT */
|
||||
#if defined(MBEDTLS_ECP_RANDOMIZE_MXZ_ALT)
|
||||
"ECP_RANDOMIZE_MXZ_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_RANDOMIZE_MXZ_ALT */
|
||||
#if defined(MBEDTLS_ECP_NORMALIZE_MXZ_ALT)
|
||||
"ECP_NORMALIZE_MXZ_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_NORMALIZE_MXZ_ALT */
|
||||
#if defined(MBEDTLS_ENTROPY_HARDWARE_ALT)
|
||||
"ENTROPY_HARDWARE_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_ENTROPY_HARDWARE_ALT */
|
||||
#if defined(MBEDTLS_AES_ROM_TABLES)
|
||||
"AES_ROM_TABLES", //no-check-names
|
||||
#endif /* MBEDTLS_AES_ROM_TABLES */
|
||||
#if defined(MBEDTLS_AES_FEWER_TABLES)
|
||||
"AES_FEWER_TABLES", //no-check-names
|
||||
#endif /* MBEDTLS_AES_FEWER_TABLES */
|
||||
#if defined(MBEDTLS_AES_ONLY_128_BIT_KEY_LENGTH)
|
||||
"AES_ONLY_128_BIT_KEY_LENGTH", //no-check-names
|
||||
#endif /* MBEDTLS_AES_ONLY_128_BIT_KEY_LENGTH */
|
||||
#if defined(MBEDTLS_AES_USE_HARDWARE_ONLY)
|
||||
"AES_USE_HARDWARE_ONLY", //no-check-names
|
||||
#endif /* MBEDTLS_AES_USE_HARDWARE_ONLY */
|
||||
#if defined(MBEDTLS_CAMELLIA_SMALL_MEMORY)
|
||||
"CAMELLIA_SMALL_MEMORY", //no-check-names
|
||||
#endif /* MBEDTLS_CAMELLIA_SMALL_MEMORY */
|
||||
#if defined(MBEDTLS_CHECK_RETURN_WARNING)
|
||||
"CHECK_RETURN_WARNING", //no-check-names
|
||||
#endif /* MBEDTLS_CHECK_RETURN_WARNING */
|
||||
#if defined(MBEDTLS_CIPHER_MODE_CBC)
|
||||
"CIPHER_MODE_CBC", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_MODE_CBC */
|
||||
#if defined(MBEDTLS_CIPHER_MODE_CFB)
|
||||
"CIPHER_MODE_CFB", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_MODE_CFB */
|
||||
#if defined(MBEDTLS_CIPHER_MODE_CTR)
|
||||
"CIPHER_MODE_CTR", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_MODE_CTR */
|
||||
#if defined(MBEDTLS_CIPHER_MODE_OFB)
|
||||
"CIPHER_MODE_OFB", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_MODE_OFB */
|
||||
#if defined(MBEDTLS_CIPHER_MODE_XTS)
|
||||
"CIPHER_MODE_XTS", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_MODE_XTS */
|
||||
#if defined(MBEDTLS_CIPHER_NULL_CIPHER)
|
||||
"CIPHER_NULL_CIPHER", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_NULL_CIPHER */
|
||||
#if defined(MBEDTLS_CIPHER_PADDING_PKCS7)
|
||||
"CIPHER_PADDING_PKCS7", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_PADDING_PKCS7 */
|
||||
#if defined(MBEDTLS_CIPHER_PADDING_ONE_AND_ZEROS)
|
||||
"CIPHER_PADDING_ONE_AND_ZEROS", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_PADDING_ONE_AND_ZEROS */
|
||||
#if defined(MBEDTLS_CIPHER_PADDING_ZEROS_AND_LEN)
|
||||
"CIPHER_PADDING_ZEROS_AND_LEN", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_PADDING_ZEROS_AND_LEN */
|
||||
#if defined(MBEDTLS_CIPHER_PADDING_ZEROS)
|
||||
"CIPHER_PADDING_ZEROS", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_PADDING_ZEROS */
|
||||
#if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY)
|
||||
"CTR_DRBG_USE_128_BIT_KEY", //no-check-names
|
||||
#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */
|
||||
#if defined(MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED)
|
||||
"ECDH_VARIANT_EVEREST_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP192R1_ENABLED)
|
||||
"ECP_DP_SECP192R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP192R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP224R1_ENABLED)
|
||||
"ECP_DP_SECP224R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP224R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP256R1_ENABLED)
|
||||
"ECP_DP_SECP256R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP256R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP384R1_ENABLED)
|
||||
"ECP_DP_SECP384R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP384R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP521R1_ENABLED)
|
||||
"ECP_DP_SECP521R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP521R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP192K1_ENABLED)
|
||||
"ECP_DP_SECP192K1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP192K1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP224K1_ENABLED)
|
||||
"ECP_DP_SECP224K1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP224K1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_SECP256K1_ENABLED)
|
||||
"ECP_DP_SECP256K1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_SECP256K1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_BP256R1_ENABLED)
|
||||
"ECP_DP_BP256R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_BP256R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_BP384R1_ENABLED)
|
||||
"ECP_DP_BP384R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_BP384R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_BP512R1_ENABLED)
|
||||
"ECP_DP_BP512R1_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_BP512R1_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_CURVE25519_ENABLED)
|
||||
"ECP_DP_CURVE25519_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_CURVE25519_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_DP_CURVE448_ENABLED)
|
||||
"ECP_DP_CURVE448_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_DP_CURVE448_ENABLED */
|
||||
#if defined(MBEDTLS_ECP_NIST_OPTIM)
|
||||
"ECP_NIST_OPTIM", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_NIST_OPTIM */
|
||||
#if defined(MBEDTLS_ECP_RESTARTABLE)
|
||||
"ECP_RESTARTABLE", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_RESTARTABLE */
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
"ECP_WITH_MPI_UINT", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_WITH_MPI_UINT */
|
||||
#if defined(MBEDTLS_ECDSA_DETERMINISTIC)
|
||||
"ECDSA_DETERMINISTIC", //no-check-names
|
||||
#endif /* MBEDTLS_ECDSA_DETERMINISTIC */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_PSK_ENABLED)
|
||||
"KEY_EXCHANGE_PSK_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_PSK_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED)
|
||||
"KEY_EXCHANGE_DHE_PSK_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED)
|
||||
"KEY_EXCHANGE_ECDHE_PSK_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED)
|
||||
"KEY_EXCHANGE_RSA_PSK_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_ENABLED)
|
||||
"KEY_EXCHANGE_RSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_RSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED)
|
||||
"KEY_EXCHANGE_DHE_RSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED)
|
||||
"KEY_EXCHANGE_ECDHE_RSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED)
|
||||
"KEY_EXCHANGE_ECDHE_ECDSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED)
|
||||
"KEY_EXCHANGE_ECDH_ECDSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED)
|
||||
"KEY_EXCHANGE_ECDH_RSA_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED */
|
||||
#if defined(MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED)
|
||||
"KEY_EXCHANGE_ECJPAKE_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED */
|
||||
#if defined(MBEDTLS_PK_PARSE_EC_EXTENDED)
|
||||
"PK_PARSE_EC_EXTENDED", //no-check-names
|
||||
#endif /* MBEDTLS_PK_PARSE_EC_EXTENDED */
|
||||
#if defined(MBEDTLS_PK_PARSE_EC_COMPRESSED)
|
||||
"PK_PARSE_EC_COMPRESSED", //no-check-names
|
||||
#endif /* MBEDTLS_PK_PARSE_EC_COMPRESSED */
|
||||
#if defined(MBEDTLS_ERROR_STRERROR_DUMMY)
|
||||
"ERROR_STRERROR_DUMMY", //no-check-names
|
||||
#endif /* MBEDTLS_ERROR_STRERROR_DUMMY */
|
||||
#if defined(MBEDTLS_GENPRIME)
|
||||
"GENPRIME", //no-check-names
|
||||
#endif /* MBEDTLS_GENPRIME */
|
||||
#if defined(MBEDTLS_FS_IO)
|
||||
"FS_IO", //no-check-names
|
||||
#endif /* MBEDTLS_FS_IO */
|
||||
#if defined(MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES)
|
||||
"NO_DEFAULT_ENTROPY_SOURCES", //no-check-names
|
||||
#endif /* MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES */
|
||||
#if defined(MBEDTLS_NO_PLATFORM_ENTROPY)
|
||||
"NO_PLATFORM_ENTROPY", //no-check-names
|
||||
#endif /* MBEDTLS_NO_PLATFORM_ENTROPY */
|
||||
#if defined(MBEDTLS_ENTROPY_FORCE_SHA256)
|
||||
"ENTROPY_FORCE_SHA256", //no-check-names
|
||||
#endif /* MBEDTLS_ENTROPY_FORCE_SHA256 */
|
||||
#if defined(MBEDTLS_ENTROPY_NV_SEED)
|
||||
"ENTROPY_NV_SEED", //no-check-names
|
||||
#endif /* MBEDTLS_ENTROPY_NV_SEED */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER)
|
||||
"PSA_CRYPTO_KEY_ID_ENCODES_OWNER", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_KEY_ID_ENCODES_OWNER */
|
||||
#if defined(MBEDTLS_MEMORY_DEBUG)
|
||||
"MEMORY_DEBUG", //no-check-names
|
||||
#endif /* MBEDTLS_MEMORY_DEBUG */
|
||||
#if defined(MBEDTLS_MEMORY_BACKTRACE)
|
||||
"MEMORY_BACKTRACE", //no-check-names
|
||||
#endif /* MBEDTLS_MEMORY_BACKTRACE */
|
||||
#if defined(MBEDTLS_PK_RSA_ALT_SUPPORT)
|
||||
"PK_RSA_ALT_SUPPORT", //no-check-names
|
||||
#endif /* MBEDTLS_PK_RSA_ALT_SUPPORT */
|
||||
#if defined(MBEDTLS_PKCS1_V15)
|
||||
"PKCS1_V15", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS1_V15 */
|
||||
#if defined(MBEDTLS_PKCS1_V21)
|
||||
"PKCS1_V21", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS1_V21 */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS)
|
||||
"PSA_CRYPTO_BUILTIN_KEYS", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_CLIENT)
|
||||
"PSA_CRYPTO_CLIENT", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_CLIENT */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG)
|
||||
"PSA_CRYPTO_EXTERNAL_RNG", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SPM)
|
||||
"PSA_CRYPTO_SPM", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_SPM */
|
||||
#if defined(MBEDTLS_PSA_KEY_STORE_DYNAMIC)
|
||||
"PSA_KEY_STORE_DYNAMIC", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_KEY_STORE_DYNAMIC */
|
||||
#if defined(MBEDTLS_PSA_P256M_DRIVER_ENABLED)
|
||||
"PSA_P256M_DRIVER_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_P256M_DRIVER_ENABLED */
|
||||
#if defined(MBEDTLS_PSA_INJECT_ENTROPY)
|
||||
"PSA_INJECT_ENTROPY", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_INJECT_ENTROPY */
|
||||
#if defined(MBEDTLS_PSA_ASSUME_EXCLUSIVE_BUFFERS)
|
||||
"PSA_ASSUME_EXCLUSIVE_BUFFERS", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_ASSUME_EXCLUSIVE_BUFFERS */
|
||||
#if defined(MBEDTLS_RSA_NO_CRT)
|
||||
"RSA_NO_CRT", //no-check-names
|
||||
#endif /* MBEDTLS_RSA_NO_CRT */
|
||||
#if defined(MBEDTLS_SELF_TEST)
|
||||
"SELF_TEST", //no-check-names
|
||||
#endif /* MBEDTLS_SELF_TEST */
|
||||
#if defined(MBEDTLS_SHA256_SMALLER)
|
||||
"SHA256_SMALLER", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_SMALLER */
|
||||
#if defined(MBEDTLS_SHA512_SMALLER)
|
||||
"SHA512_SMALLER", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_SMALLER */
|
||||
#if defined(MBEDTLS_SSL_ALL_ALERT_MESSAGES)
|
||||
"SSL_ALL_ALERT_MESSAGES", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_ALL_ALERT_MESSAGES */
|
||||
#if defined(MBEDTLS_SSL_DTLS_CONNECTION_ID)
|
||||
"SSL_DTLS_CONNECTION_ID", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_CONNECTION_ID */
|
||||
#if defined(MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT)
|
||||
"SSL_DTLS_CONNECTION_ID_COMPAT", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT */
|
||||
#if defined(MBEDTLS_SSL_ASYNC_PRIVATE)
|
||||
"SSL_ASYNC_PRIVATE", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_ASYNC_PRIVATE */
|
||||
#if defined(MBEDTLS_SSL_CLI_ALLOW_WEAK_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME)
|
||||
"SSL_CLI_ALLOW_WEAK_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_CLI_ALLOW_WEAK_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME */
|
||||
#if defined(MBEDTLS_SSL_CONTEXT_SERIALIZATION)
|
||||
"SSL_CONTEXT_SERIALIZATION", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_CONTEXT_SERIALIZATION */
|
||||
#if defined(MBEDTLS_SSL_DEBUG_ALL)
|
||||
"SSL_DEBUG_ALL", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DEBUG_ALL */
|
||||
#if defined(MBEDTLS_SSL_ENCRYPT_THEN_MAC)
|
||||
"SSL_ENCRYPT_THEN_MAC", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_ENCRYPT_THEN_MAC */
|
||||
#if defined(MBEDTLS_SSL_EXTENDED_MASTER_SECRET)
|
||||
"SSL_EXTENDED_MASTER_SECRET", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_EXTENDED_MASTER_SECRET */
|
||||
#if defined(MBEDTLS_SSL_KEEP_PEER_CERTIFICATE)
|
||||
"SSL_KEEP_PEER_CERTIFICATE", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_KEEP_PEER_CERTIFICATE */
|
||||
#if defined(MBEDTLS_SSL_KEYING_MATERIAL_EXPORT)
|
||||
"SSL_KEYING_MATERIAL_EXPORT", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_KEYING_MATERIAL_EXPORT */
|
||||
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||
"SSL_RENEGOTIATION", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||
#if defined(MBEDTLS_SSL_MAX_FRAGMENT_LENGTH)
|
||||
"SSL_MAX_FRAGMENT_LENGTH", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_MAX_FRAGMENT_LENGTH */
|
||||
#if defined(MBEDTLS_SSL_RECORD_SIZE_LIMIT)
|
||||
"SSL_RECORD_SIZE_LIMIT", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_RECORD_SIZE_LIMIT */
|
||||
#if defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||
"SSL_PROTO_TLS1_2", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_PROTO_TLS1_2 */
|
||||
#if defined(MBEDTLS_SSL_PROTO_TLS1_3)
|
||||
"SSL_PROTO_TLS1_3", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_PROTO_TLS1_3 */
|
||||
#if defined(MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE)
|
||||
"SSL_TLS1_3_COMPATIBILITY_MODE", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TLS1_3_COMPATIBILITY_MODE */
|
||||
#if defined(MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED)
|
||||
"SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_ENABLED */
|
||||
#if defined(MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED)
|
||||
"SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_EPHEMERAL_ENABLED */
|
||||
#if defined(MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED)
|
||||
"SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TLS1_3_KEY_EXCHANGE_MODE_PSK_EPHEMERAL_ENABLED */
|
||||
#if defined(MBEDTLS_SSL_EARLY_DATA)
|
||||
"SSL_EARLY_DATA", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_EARLY_DATA */
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
"SSL_PROTO_DTLS", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_PROTO_DTLS */
|
||||
#if defined(MBEDTLS_SSL_ALPN)
|
||||
"SSL_ALPN", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_ALPN */
|
||||
#if defined(MBEDTLS_SSL_DTLS_ANTI_REPLAY)
|
||||
"SSL_DTLS_ANTI_REPLAY", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_ANTI_REPLAY */
|
||||
#if defined(MBEDTLS_SSL_DTLS_HELLO_VERIFY)
|
||||
"SSL_DTLS_HELLO_VERIFY", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_HELLO_VERIFY */
|
||||
#if defined(MBEDTLS_SSL_DTLS_SRTP)
|
||||
"SSL_DTLS_SRTP", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_SRTP */
|
||||
#if defined(MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE)
|
||||
"SSL_DTLS_CLIENT_PORT_REUSE", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE */
|
||||
#if defined(MBEDTLS_SSL_SESSION_TICKETS)
|
||||
"SSL_SESSION_TICKETS", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_SESSION_TICKETS */
|
||||
#if defined(MBEDTLS_SSL_SERVER_NAME_INDICATION)
|
||||
"SSL_SERVER_NAME_INDICATION", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_SERVER_NAME_INDICATION */
|
||||
#if defined(MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH)
|
||||
"SSL_VARIABLE_BUFFER_LENGTH", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH */
|
||||
#if defined(MBEDTLS_TEST_CONSTANT_FLOW_MEMSAN)
|
||||
"TEST_CONSTANT_FLOW_MEMSAN", //no-check-names
|
||||
#endif /* MBEDTLS_TEST_CONSTANT_FLOW_MEMSAN */
|
||||
#if defined(MBEDTLS_TEST_CONSTANT_FLOW_VALGRIND)
|
||||
"TEST_CONSTANT_FLOW_VALGRIND", //no-check-names
|
||||
#endif /* MBEDTLS_TEST_CONSTANT_FLOW_VALGRIND */
|
||||
#if defined(MBEDTLS_TEST_HOOKS)
|
||||
"TEST_HOOKS", //no-check-names
|
||||
#endif /* MBEDTLS_TEST_HOOKS */
|
||||
#if defined(MBEDTLS_THREADING_ALT)
|
||||
"THREADING_ALT", //no-check-names
|
||||
#endif /* MBEDTLS_THREADING_ALT */
|
||||
#if defined(MBEDTLS_THREADING_PTHREAD)
|
||||
"THREADING_PTHREAD", //no-check-names
|
||||
#endif /* MBEDTLS_THREADING_PTHREAD */
|
||||
#if defined(MBEDTLS_USE_PSA_CRYPTO)
|
||||
"USE_PSA_CRYPTO", //no-check-names
|
||||
#endif /* MBEDTLS_USE_PSA_CRYPTO */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_CONFIG)
|
||||
"PSA_CRYPTO_CONFIG", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_CONFIG */
|
||||
#if defined(MBEDTLS_VERSION_FEATURES)
|
||||
"VERSION_FEATURES", //no-check-names
|
||||
#endif /* MBEDTLS_VERSION_FEATURES */
|
||||
#if defined(MBEDTLS_X509_TRUSTED_CERTIFICATE_CALLBACK)
|
||||
"X509_TRUSTED_CERTIFICATE_CALLBACK", //no-check-names
|
||||
#endif /* MBEDTLS_X509_TRUSTED_CERTIFICATE_CALLBACK */
|
||||
#if defined(MBEDTLS_X509_REMOVE_INFO)
|
||||
"X509_REMOVE_INFO", //no-check-names
|
||||
#endif /* MBEDTLS_X509_REMOVE_INFO */
|
||||
#if defined(MBEDTLS_X509_RSASSA_PSS_SUPPORT)
|
||||
"X509_RSASSA_PSS_SUPPORT", //no-check-names
|
||||
#endif /* MBEDTLS_X509_RSASSA_PSS_SUPPORT */
|
||||
#if defined(MBEDTLS_AESNI_C)
|
||||
"AESNI_C", //no-check-names
|
||||
#endif /* MBEDTLS_AESNI_C */
|
||||
#if defined(MBEDTLS_AESCE_C)
|
||||
"AESCE_C", //no-check-names
|
||||
#endif /* MBEDTLS_AESCE_C */
|
||||
#if defined(MBEDTLS_AES_C)
|
||||
"AES_C", //no-check-names
|
||||
#endif /* MBEDTLS_AES_C */
|
||||
#if defined(MBEDTLS_ASN1_PARSE_C)
|
||||
"ASN1_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_ASN1_PARSE_C */
|
||||
#if defined(MBEDTLS_ASN1_WRITE_C)
|
||||
"ASN1_WRITE_C", //no-check-names
|
||||
#endif /* MBEDTLS_ASN1_WRITE_C */
|
||||
#if defined(MBEDTLS_BASE64_C)
|
||||
"BASE64_C", //no-check-names
|
||||
#endif /* MBEDTLS_BASE64_C */
|
||||
#if defined(MBEDTLS_BLOCK_CIPHER_NO_DECRYPT)
|
||||
"BLOCK_CIPHER_NO_DECRYPT", //no-check-names
|
||||
#endif /* MBEDTLS_BLOCK_CIPHER_NO_DECRYPT */
|
||||
#if defined(MBEDTLS_BIGNUM_C)
|
||||
"BIGNUM_C", //no-check-names
|
||||
#endif /* MBEDTLS_BIGNUM_C */
|
||||
#if defined(MBEDTLS_CAMELLIA_C)
|
||||
"CAMELLIA_C", //no-check-names
|
||||
#endif /* MBEDTLS_CAMELLIA_C */
|
||||
#if defined(MBEDTLS_ARIA_C)
|
||||
"ARIA_C", //no-check-names
|
||||
#endif /* MBEDTLS_ARIA_C */
|
||||
#if defined(MBEDTLS_CCM_C)
|
||||
"CCM_C", //no-check-names
|
||||
#endif /* MBEDTLS_CCM_C */
|
||||
#if defined(MBEDTLS_CHACHA20_C)
|
||||
"CHACHA20_C", //no-check-names
|
||||
#endif /* MBEDTLS_CHACHA20_C */
|
||||
#if defined(MBEDTLS_CHACHAPOLY_C)
|
||||
"CHACHAPOLY_C", //no-check-names
|
||||
#endif /* MBEDTLS_CHACHAPOLY_C */
|
||||
#if defined(MBEDTLS_CIPHER_C)
|
||||
"CIPHER_C", //no-check-names
|
||||
#endif /* MBEDTLS_CIPHER_C */
|
||||
#if defined(MBEDTLS_CMAC_C)
|
||||
"CMAC_C", //no-check-names
|
||||
#endif /* MBEDTLS_CMAC_C */
|
||||
#if defined(MBEDTLS_CTR_DRBG_C)
|
||||
"CTR_DRBG_C", //no-check-names
|
||||
#endif /* MBEDTLS_CTR_DRBG_C */
|
||||
#if defined(MBEDTLS_DEBUG_C)
|
||||
"DEBUG_C", //no-check-names
|
||||
#endif /* MBEDTLS_DEBUG_C */
|
||||
#if defined(MBEDTLS_DES_C)
|
||||
"DES_C", //no-check-names
|
||||
#endif /* MBEDTLS_DES_C */
|
||||
#if defined(MBEDTLS_DHM_C)
|
||||
"DHM_C", //no-check-names
|
||||
#endif /* MBEDTLS_DHM_C */
|
||||
#if defined(MBEDTLS_ECDH_C)
|
||||
"ECDH_C", //no-check-names
|
||||
#endif /* MBEDTLS_ECDH_C */
|
||||
#if defined(MBEDTLS_ECDSA_C)
|
||||
"ECDSA_C", //no-check-names
|
||||
#endif /* MBEDTLS_ECDSA_C */
|
||||
#if defined(MBEDTLS_ECJPAKE_C)
|
||||
"ECJPAKE_C", //no-check-names
|
||||
#endif /* MBEDTLS_ECJPAKE_C */
|
||||
#if defined(MBEDTLS_ECP_C)
|
||||
"ECP_C", //no-check-names
|
||||
#endif /* MBEDTLS_ECP_C */
|
||||
#if defined(MBEDTLS_ENTROPY_C)
|
||||
"ENTROPY_C", //no-check-names
|
||||
#endif /* MBEDTLS_ENTROPY_C */
|
||||
#if defined(MBEDTLS_ERROR_C)
|
||||
"ERROR_C", //no-check-names
|
||||
#endif /* MBEDTLS_ERROR_C */
|
||||
#if defined(MBEDTLS_GCM_C)
|
||||
"GCM_C", //no-check-names
|
||||
#endif /* MBEDTLS_GCM_C */
|
||||
#if defined(MBEDTLS_GCM_LARGE_TABLE)
|
||||
"GCM_LARGE_TABLE", //no-check-names
|
||||
#endif /* MBEDTLS_GCM_LARGE_TABLE */
|
||||
#if defined(MBEDTLS_HKDF_C)
|
||||
"HKDF_C", //no-check-names
|
||||
#endif /* MBEDTLS_HKDF_C */
|
||||
#if defined(MBEDTLS_HMAC_DRBG_C)
|
||||
"HMAC_DRBG_C", //no-check-names
|
||||
#endif /* MBEDTLS_HMAC_DRBG_C */
|
||||
#if defined(MBEDTLS_LMS_C)
|
||||
"LMS_C", //no-check-names
|
||||
#endif /* MBEDTLS_LMS_C */
|
||||
#if defined(MBEDTLS_LMS_PRIVATE)
|
||||
"LMS_PRIVATE", //no-check-names
|
||||
#endif /* MBEDTLS_LMS_PRIVATE */
|
||||
#if defined(MBEDTLS_NIST_KW_C)
|
||||
"NIST_KW_C", //no-check-names
|
||||
#endif /* MBEDTLS_NIST_KW_C */
|
||||
#if defined(MBEDTLS_MD_C)
|
||||
"MD_C", //no-check-names
|
||||
#endif /* MBEDTLS_MD_C */
|
||||
#if defined(MBEDTLS_MD5_C)
|
||||
"MD5_C", //no-check-names
|
||||
#endif /* MBEDTLS_MD5_C */
|
||||
#if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C)
|
||||
"MEMORY_BUFFER_ALLOC_C", //no-check-names
|
||||
#endif /* MBEDTLS_MEMORY_BUFFER_ALLOC_C */
|
||||
#if defined(MBEDTLS_NET_C)
|
||||
"NET_C", //no-check-names
|
||||
#endif /* MBEDTLS_NET_C */
|
||||
#if defined(MBEDTLS_OID_C)
|
||||
"OID_C", //no-check-names
|
||||
#endif /* MBEDTLS_OID_C */
|
||||
#if defined(MBEDTLS_PADLOCK_C)
|
||||
"PADLOCK_C", //no-check-names
|
||||
#endif /* MBEDTLS_PADLOCK_C */
|
||||
#if defined(MBEDTLS_PEM_PARSE_C)
|
||||
"PEM_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PEM_PARSE_C */
|
||||
#if defined(MBEDTLS_PEM_WRITE_C)
|
||||
"PEM_WRITE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PEM_WRITE_C */
|
||||
#if defined(MBEDTLS_PK_C)
|
||||
"PK_C", //no-check-names
|
||||
#endif /* MBEDTLS_PK_C */
|
||||
#if defined(MBEDTLS_PK_PARSE_C)
|
||||
"PK_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PK_PARSE_C */
|
||||
#if defined(MBEDTLS_PK_WRITE_C)
|
||||
"PK_WRITE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PK_WRITE_C */
|
||||
#if defined(MBEDTLS_PKCS5_C)
|
||||
"PKCS5_C", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS5_C */
|
||||
#if defined(MBEDTLS_PKCS7_C)
|
||||
"PKCS7_C", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS7_C */
|
||||
#if defined(MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES)
|
||||
"PKCS7_ALLOW_WEAK_SIGNATURES", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES */
|
||||
#if defined(MBEDTLS_PKCS12_C)
|
||||
"PKCS12_C", //no-check-names
|
||||
#endif /* MBEDTLS_PKCS12_C */
|
||||
#if defined(MBEDTLS_PLATFORM_C)
|
||||
"PLATFORM_C", //no-check-names
|
||||
#endif /* MBEDTLS_PLATFORM_C */
|
||||
#if defined(MBEDTLS_POLY1305_C)
|
||||
"POLY1305_C", //no-check-names
|
||||
#endif /* MBEDTLS_POLY1305_C */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C)
|
||||
"PSA_CRYPTO_C", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_C */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SE_C)
|
||||
"PSA_CRYPTO_SE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_SE_C */
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_STORAGE_C)
|
||||
"PSA_CRYPTO_STORAGE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_CRYPTO_STORAGE_C */
|
||||
#if defined(MBEDTLS_PSA_ITS_FILE_C)
|
||||
"PSA_ITS_FILE_C", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_ITS_FILE_C */
|
||||
#if defined(MBEDTLS_PSA_STATIC_KEY_SLOTS)
|
||||
"PSA_STATIC_KEY_SLOTS", //no-check-names
|
||||
#endif /* MBEDTLS_PSA_STATIC_KEY_SLOTS */
|
||||
#if defined(MBEDTLS_RIPEMD160_C)
|
||||
"RIPEMD160_C", //no-check-names
|
||||
#endif /* MBEDTLS_RIPEMD160_C */
|
||||
#if defined(MBEDTLS_RSA_C)
|
||||
"RSA_C", //no-check-names
|
||||
#endif /* MBEDTLS_RSA_C */
|
||||
#if defined(MBEDTLS_SHA1_C)
|
||||
"SHA1_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA1_C */
|
||||
#if defined(MBEDTLS_SHA224_C)
|
||||
"SHA224_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA224_C */
|
||||
#if defined(MBEDTLS_SHA256_C)
|
||||
"SHA256_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_C */
|
||||
#if defined(MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT)
|
||||
"SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT */
|
||||
#if defined(MBEDTLS_SHA256_USE_A64_CRYPTO_IF_PRESENT)
|
||||
"SHA256_USE_A64_CRYPTO_IF_PRESENT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_USE_A64_CRYPTO_IF_PRESENT */
|
||||
#if defined(MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY)
|
||||
"SHA256_USE_ARMV8_A_CRYPTO_ONLY", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY */
|
||||
#if defined(MBEDTLS_SHA256_USE_A64_CRYPTO_ONLY)
|
||||
"SHA256_USE_A64_CRYPTO_ONLY", //no-check-names
|
||||
#endif /* MBEDTLS_SHA256_USE_A64_CRYPTO_ONLY */
|
||||
#if defined(MBEDTLS_SHA384_C)
|
||||
"SHA384_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA384_C */
|
||||
#if defined(MBEDTLS_SHA512_C)
|
||||
"SHA512_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_C */
|
||||
#if defined(MBEDTLS_SHA3_C)
|
||||
"SHA3_C", //no-check-names
|
||||
#endif /* MBEDTLS_SHA3_C */
|
||||
#if defined(MBEDTLS_SHA512_USE_A64_CRYPTO_IF_PRESENT)
|
||||
"SHA512_USE_A64_CRYPTO_IF_PRESENT", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_USE_A64_CRYPTO_IF_PRESENT */
|
||||
#if defined(MBEDTLS_SHA512_USE_A64_CRYPTO_ONLY)
|
||||
"SHA512_USE_A64_CRYPTO_ONLY", //no-check-names
|
||||
#endif /* MBEDTLS_SHA512_USE_A64_CRYPTO_ONLY */
|
||||
#if defined(MBEDTLS_SSL_CACHE_C)
|
||||
"SSL_CACHE_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_CACHE_C */
|
||||
#if defined(MBEDTLS_SSL_COOKIE_C)
|
||||
"SSL_COOKIE_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_COOKIE_C */
|
||||
#if defined(MBEDTLS_SSL_TICKET_C)
|
||||
"SSL_TICKET_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TICKET_C */
|
||||
#if defined(MBEDTLS_SSL_CLI_C)
|
||||
"SSL_CLI_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_CLI_C */
|
||||
#if defined(MBEDTLS_SSL_SRV_C)
|
||||
"SSL_SRV_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_SRV_C */
|
||||
#if defined(MBEDTLS_SSL_TLS_C)
|
||||
"SSL_TLS_C", //no-check-names
|
||||
#endif /* MBEDTLS_SSL_TLS_C */
|
||||
#if defined(MBEDTLS_THREADING_C)
|
||||
"THREADING_C", //no-check-names
|
||||
#endif /* MBEDTLS_THREADING_C */
|
||||
#if defined(MBEDTLS_TIMING_C)
|
||||
"TIMING_C", //no-check-names
|
||||
#endif /* MBEDTLS_TIMING_C */
|
||||
#if defined(MBEDTLS_VERSION_C)
|
||||
"VERSION_C", //no-check-names
|
||||
#endif /* MBEDTLS_VERSION_C */
|
||||
#if defined(MBEDTLS_X509_USE_C)
|
||||
"X509_USE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_USE_C */
|
||||
#if defined(MBEDTLS_X509_CRT_PARSE_C)
|
||||
"X509_CRT_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CRT_PARSE_C */
|
||||
#if defined(MBEDTLS_X509_CRL_PARSE_C)
|
||||
"X509_CRL_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CRL_PARSE_C */
|
||||
#if defined(MBEDTLS_X509_CSR_PARSE_C)
|
||||
"X509_CSR_PARSE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CSR_PARSE_C */
|
||||
#if defined(MBEDTLS_X509_CREATE_C)
|
||||
"X509_CREATE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CREATE_C */
|
||||
#if defined(MBEDTLS_X509_CRT_WRITE_C)
|
||||
"X509_CRT_WRITE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CRT_WRITE_C */
|
||||
#if defined(MBEDTLS_X509_CSR_WRITE_C)
|
||||
"X509_CSR_WRITE_C", //no-check-names
|
||||
#endif /* MBEDTLS_X509_CSR_WRITE_C */
|
||||
#endif /* MBEDTLS_VERSION_FEATURES */
|
||||
NULL
|
||||
};
|
||||
|
||||
int mbedtls_version_check_feature(const char *feature)
|
||||
{
|
||||
const char * const *idx = features;
|
||||
|
||||
if (*idx == NULL) {
|
||||
return -2;
|
||||
}
|
||||
|
||||
if (feature == NULL) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (strncmp(feature, "MBEDTLS_", 8)) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
feature += 8;
|
||||
|
||||
while (*idx != NULL) {
|
||||
if (!strcmp(*idx, feature)) {
|
||||
return 0;
|
||||
}
|
||||
idx++;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
#endif /* MBEDTLS_VERSION_C */
|
||||
@ -88,11 +88,13 @@ typedef struct {
|
||||
* concerns. */
|
||||
const mbedtls_x509_crt_profile mbedtls_x509_crt_profile_default =
|
||||
{
|
||||
/* Hashes from SHA-256 and above. Note that this selection
|
||||
* should be aligned with ssl_preset_default_hashes in ssl_tls.c. */
|
||||
/* Hashes from SHA-256 and above. */
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA256) |
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA384) |
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA512),
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA512) |
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA3_256) |
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA3_384) |
|
||||
MBEDTLS_X509_ID_FLAG(MBEDTLS_MD_SHA3_512),
|
||||
0xFFFFFFF, /* Any PK alg */
|
||||
#if defined(MBEDTLS_PK_HAVE_ECC_KEYS)
|
||||
/* Curves at or above 128-bit security level. Note that this selection
|
||||
@ -166,12 +168,8 @@ const mbedtls_x509_crt_profile mbedtls_x509_crt_profile_none =
|
||||
(uint32_t) -1,
|
||||
};
|
||||
|
||||
/*
|
||||
* Check md_alg against profile
|
||||
* Return 0 if md_alg is acceptable for this profile, -1 otherwise
|
||||
*/
|
||||
static int x509_profile_check_md_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_md_type_t md_alg)
|
||||
int mbedtls_x509_profile_check_md_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_md_type_t md_alg)
|
||||
{
|
||||
if (md_alg == MBEDTLS_MD_NONE) {
|
||||
return -1;
|
||||
@ -184,12 +182,8 @@ static int x509_profile_check_md_alg(const mbedtls_x509_crt_profile *profile,
|
||||
return -1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Check pk_alg against profile
|
||||
* Return 0 if pk_alg is acceptable for this profile, -1 otherwise
|
||||
*/
|
||||
static int x509_profile_check_pk_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_pk_type_t pk_alg)
|
||||
int mbedtls_x509_profile_check_pk_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_pk_type_t pk_alg)
|
||||
{
|
||||
if (pk_alg == MBEDTLS_PK_NONE) {
|
||||
return -1;
|
||||
@ -513,23 +507,34 @@ static int x509_get_basic_constraints(unsigned char **p,
|
||||
}
|
||||
|
||||
if (*p == end) {
|
||||
/* Empty basicConstraints: valid, not a CA. */
|
||||
return 0;
|
||||
}
|
||||
|
||||
if ((ret = mbedtls_asn1_get_bool(p, end, ca_istrue)) != 0) {
|
||||
if (ret == MBEDTLS_ERR_ASN1_UNEXPECTED_TAG) {
|
||||
ret = mbedtls_asn1_get_int(p, end, ca_istrue);
|
||||
}
|
||||
|
||||
if (ret != 0) {
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS, ret);
|
||||
}
|
||||
|
||||
if (*ca_istrue != 0) {
|
||||
*ca_istrue = 1;
|
||||
}
|
||||
if ((size_t) (end - *p) != len) {
|
||||
/* Reject junk after the SEQUENCE inside the extension (which is
|
||||
* probably benign), and reject a SEQUENCE that extends beyond
|
||||
* the extension (could be very dangerous). */
|
||||
return MBEDTLS_ERR_X509_INVALID_EXTENSIONS;
|
||||
}
|
||||
|
||||
if ((ret = mbedtls_asn1_get_bool(p, end, ca_istrue)) != 0) {
|
||||
/* If the SEQUENCE starts with an INTEGER and not a BOOLEAN,
|
||||
* according to RFC 5280, it's syntactically valid, but it's
|
||||
* something that a CA MUST NOT produce. So we reject it.
|
||||
*
|
||||
* Note: historically, from XySSL 0.9 to Mbed TLS 3.6.6/4.1.0,
|
||||
* `SEQUENCE { INTEGER n }` was interpreted as cA=FALSE if n == 0
|
||||
* and cA=TRUE if n != 0. This was dangerous since
|
||||
* `SEQUENCE { INTEGER n }` should be parsed as cA=FALSE
|
||||
* according to RFC 5280, so we stopped doing it.
|
||||
*/
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS, ret);
|
||||
}
|
||||
/* `SEQUENCE { BOOLEAN FALSE }` is not DER since default-value fields
|
||||
* must be omitted in DER. But it seems harmless, and Mbed TLS has
|
||||
* always accepted it, so we continue to accept it. */
|
||||
|
||||
if (*p == end) {
|
||||
return 0;
|
||||
}
|
||||
@ -2044,11 +2049,11 @@ static int x509_crt_verifycrl(mbedtls_x509_crt *crt, mbedtls_x509_crt *ca,
|
||||
/*
|
||||
* Check if CRL is correctly signed by the trusted CA
|
||||
*/
|
||||
if (x509_profile_check_md_alg(profile, crl_list->sig_md) != 0) {
|
||||
if (mbedtls_x509_profile_check_md_alg(profile, crl_list->sig_md) != 0) {
|
||||
flags |= MBEDTLS_X509_BADCRL_BAD_MD;
|
||||
}
|
||||
|
||||
if (x509_profile_check_pk_alg(profile, crl_list->sig_pk) != 0) {
|
||||
if (mbedtls_x509_profile_check_pk_alg(profile, crl_list->sig_pk) != 0) {
|
||||
flags |= MBEDTLS_X509_BADCRL_BAD_PK;
|
||||
}
|
||||
|
||||
@ -2579,11 +2584,11 @@ static int x509_crt_verify_chain(
|
||||
}
|
||||
|
||||
/* Check signature algorithm: MD & PK algs */
|
||||
if (x509_profile_check_md_alg(profile, child->sig_md) != 0) {
|
||||
if (mbedtls_x509_profile_check_md_alg(profile, child->sig_md) != 0) {
|
||||
*flags |= MBEDTLS_X509_BADCERT_BAD_MD;
|
||||
}
|
||||
|
||||
if (x509_profile_check_pk_alg(profile, child->sig_pk) != 0) {
|
||||
if (mbedtls_x509_profile_check_pk_alg(profile, child->sig_pk) != 0) {
|
||||
*flags |= MBEDTLS_X509_BADCERT_BAD_PK;
|
||||
}
|
||||
|
||||
@ -3091,7 +3096,7 @@ static int x509_crt_verify_restartable_ca_cb(mbedtls_x509_crt *crt,
|
||||
/* Check the type and size of the key */
|
||||
pk_type = mbedtls_pk_get_type(&crt->pk);
|
||||
|
||||
if (x509_profile_check_pk_alg(profile, pk_type) != 0) {
|
||||
if (mbedtls_x509_profile_check_pk_alg(profile, pk_type) != 0) {
|
||||
ee_flags |= MBEDTLS_X509_BADCERT_BAD_PK;
|
||||
}
|
||||
|
||||
|
||||
@ -227,25 +227,34 @@ static int x509_csr_parse_attributes(mbedtls_x509_csr *csr,
|
||||
|
||||
/* Check that this is an extension-request attribute */
|
||||
if (MBEDTLS_OID_CMP(MBEDTLS_OID_PKCS9_CSR_EXT_REQ, &attr_oid) == 0) {
|
||||
if ((ret = mbedtls_asn1_get_tag(p, end, &len,
|
||||
if ((ret = mbedtls_asn1_get_tag(p, end_attr_data, &len,
|
||||
MBEDTLS_ASN1_CONSTRUCTED | MBEDTLS_ASN1_SET)) != 0) {
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS, ret);
|
||||
}
|
||||
|
||||
if ((ret = mbedtls_asn1_get_tag(p, end, &len,
|
||||
const unsigned char *end_set = *p + len;
|
||||
if (end_set != end_attr_data) {
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS,
|
||||
MBEDTLS_ERR_ASN1_LENGTH_MISMATCH);
|
||||
}
|
||||
|
||||
if ((ret = mbedtls_asn1_get_tag(p, end_set, &len,
|
||||
MBEDTLS_ASN1_CONSTRUCTED | MBEDTLS_ASN1_SEQUENCE)) !=
|
||||
0) {
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS, ret);
|
||||
}
|
||||
|
||||
if ((ret = x509_csr_parse_extensions(csr, p, *p + len, cb, p_ctx)) != 0) {
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (*p != end_attr_data) {
|
||||
const unsigned char *end_exts = *p + len;
|
||||
if (end_exts != end_set) {
|
||||
return MBEDTLS_ERROR_ADD(MBEDTLS_ERR_X509_INVALID_EXTENSIONS,
|
||||
MBEDTLS_ERR_ASN1_LENGTH_MISMATCH);
|
||||
}
|
||||
|
||||
if ((ret = x509_csr_parse_extensions(csr, p, end_exts, cb, p_ctx)) != 0) {
|
||||
return ret;
|
||||
}
|
||||
/* x509_csr_parse_extensions() guarantees *p == end_exts
|
||||
* on success */
|
||||
}
|
||||
|
||||
*p = end_attr_data;
|
||||
|
||||
@ -14,6 +14,7 @@
|
||||
#include "mbedtls/build_info.h"
|
||||
|
||||
#include "mbedtls/x509.h"
|
||||
#include "mbedtls/x509_crt.h"
|
||||
#include "mbedtls/asn1.h"
|
||||
#include "pk_internal.h"
|
||||
|
||||
@ -83,4 +84,18 @@ int mbedtls_x509_info_key_usage(char **buf, size_t *size,
|
||||
int mbedtls_x509_write_set_san_common(mbedtls_asn1_named_data **extensions,
|
||||
const mbedtls_x509_san_list *san_list);
|
||||
|
||||
/*
|
||||
* Check md_alg against profile
|
||||
* Return 0 if md_alg is acceptable for this profile, -1 otherwise
|
||||
*/
|
||||
int mbedtls_x509_profile_check_md_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_md_type_t md_alg);
|
||||
|
||||
/*
|
||||
* Check pk_alg against profile
|
||||
* Return 0 if pk_alg is acceptable for this profile, -1 otherwise
|
||||
*/
|
||||
int mbedtls_x509_profile_check_pk_alg(const mbedtls_x509_crt_profile *profile,
|
||||
mbedtls_pk_type_t pk_alg);
|
||||
|
||||
#endif /* MBEDTLS_X509_INTERNAL_H */
|
||||
|
||||
16
programs/.gitignore
vendored
16
programs/.gitignore
vendored
@ -73,11 +73,11 @@ x509/crl_app
|
||||
x509/load_roots
|
||||
x509/req_app
|
||||
|
||||
###START_GENERATED_FILES###
|
||||
# Generated source files
|
||||
/psa/psa_constant_names_generated.c
|
||||
/test/query_config.c
|
||||
|
||||
# Generated data files
|
||||
pkey/keyfile.key
|
||||
###END_GENERATED_FILES###
|
||||
####START_COMMENTED_GENERATED_FILES###
|
||||
## Generated source files
|
||||
#/psa/psa_constant_names_generated.c
|
||||
#/test/query_config.c
|
||||
#
|
||||
## Generated data files
|
||||
#pkey/keyfile.key
|
||||
####END_COMMENTED_GENERATED_FILES###
|
||||
|
||||
474
programs/psa/psa_constant_names_generated.c
Normal file
474
programs/psa/psa_constant_names_generated.c
Normal file
@ -0,0 +1,474 @@
|
||||
/* Automatically generated by generate_psa_constant.py. DO NOT EDIT. */
|
||||
|
||||
static const char *psa_strerror(psa_status_t status)
|
||||
{
|
||||
switch (status) {
|
||||
case PSA_ERROR_ALREADY_EXISTS: return "PSA_ERROR_ALREADY_EXISTS";
|
||||
case PSA_ERROR_BAD_STATE: return "PSA_ERROR_BAD_STATE";
|
||||
case PSA_ERROR_BUFFER_TOO_SMALL: return "PSA_ERROR_BUFFER_TOO_SMALL";
|
||||
case PSA_ERROR_COMMUNICATION_FAILURE: return "PSA_ERROR_COMMUNICATION_FAILURE";
|
||||
case PSA_ERROR_CORRUPTION_DETECTED: return "PSA_ERROR_CORRUPTION_DETECTED";
|
||||
case PSA_ERROR_DATA_CORRUPT: return "PSA_ERROR_DATA_CORRUPT";
|
||||
case PSA_ERROR_DATA_INVALID: return "PSA_ERROR_DATA_INVALID";
|
||||
case PSA_ERROR_DOES_NOT_EXIST: return "PSA_ERROR_DOES_NOT_EXIST";
|
||||
case PSA_ERROR_GENERIC_ERROR: return "PSA_ERROR_GENERIC_ERROR";
|
||||
case PSA_ERROR_HARDWARE_FAILURE: return "PSA_ERROR_HARDWARE_FAILURE";
|
||||
case PSA_ERROR_INSUFFICIENT_DATA: return "PSA_ERROR_INSUFFICIENT_DATA";
|
||||
case PSA_ERROR_INSUFFICIENT_ENTROPY: return "PSA_ERROR_INSUFFICIENT_ENTROPY";
|
||||
case PSA_ERROR_INSUFFICIENT_MEMORY: return "PSA_ERROR_INSUFFICIENT_MEMORY";
|
||||
case PSA_ERROR_INSUFFICIENT_STORAGE: return "PSA_ERROR_INSUFFICIENT_STORAGE";
|
||||
case PSA_ERROR_INVALID_ARGUMENT: return "PSA_ERROR_INVALID_ARGUMENT";
|
||||
case PSA_ERROR_INVALID_HANDLE: return "PSA_ERROR_INVALID_HANDLE";
|
||||
case PSA_ERROR_INVALID_PADDING: return "PSA_ERROR_INVALID_PADDING";
|
||||
case PSA_ERROR_INVALID_SIGNATURE: return "PSA_ERROR_INVALID_SIGNATURE";
|
||||
case PSA_ERROR_NOT_PERMITTED: return "PSA_ERROR_NOT_PERMITTED";
|
||||
case PSA_ERROR_NOT_SUPPORTED: return "PSA_ERROR_NOT_SUPPORTED";
|
||||
case PSA_ERROR_SERVICE_FAILURE: return "PSA_ERROR_SERVICE_FAILURE";
|
||||
case PSA_ERROR_STORAGE_FAILURE: return "PSA_ERROR_STORAGE_FAILURE";
|
||||
case PSA_SUCCESS: return "PSA_SUCCESS";
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
static const char *psa_ecc_family_name(psa_ecc_family_t curve)
|
||||
{
|
||||
switch (curve) {
|
||||
case PSA_ECC_FAMILY_BRAINPOOL_P_R1: return "PSA_ECC_FAMILY_BRAINPOOL_P_R1";
|
||||
case PSA_ECC_FAMILY_MONTGOMERY: return "PSA_ECC_FAMILY_MONTGOMERY";
|
||||
case PSA_ECC_FAMILY_SECP_K1: return "PSA_ECC_FAMILY_SECP_K1";
|
||||
case PSA_ECC_FAMILY_SECP_R1: return "PSA_ECC_FAMILY_SECP_R1";
|
||||
case PSA_ECC_FAMILY_SECP_R2: return "PSA_ECC_FAMILY_SECP_R2";
|
||||
case PSA_ECC_FAMILY_SECT_K1: return "PSA_ECC_FAMILY_SECT_K1";
|
||||
case PSA_ECC_FAMILY_SECT_R1: return "PSA_ECC_FAMILY_SECT_R1";
|
||||
case PSA_ECC_FAMILY_SECT_R2: return "PSA_ECC_FAMILY_SECT_R2";
|
||||
case PSA_ECC_FAMILY_TWISTED_EDWARDS: return "PSA_ECC_FAMILY_TWISTED_EDWARDS";
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
static const char *psa_dh_family_name(psa_dh_family_t group)
|
||||
{
|
||||
switch (group) {
|
||||
case PSA_DH_FAMILY_RFC7919: return "PSA_DH_FAMILY_RFC7919";
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
static const char *psa_hash_algorithm_name(psa_algorithm_t hash_alg)
|
||||
{
|
||||
switch (hash_alg) {
|
||||
case PSA_ALG_ANY_HASH: return "PSA_ALG_ANY_HASH";
|
||||
case PSA_ALG_CATEGORY_HASH: return "PSA_ALG_CATEGORY_HASH";
|
||||
case PSA_ALG_MD5: return "PSA_ALG_MD5";
|
||||
case PSA_ALG_RIPEMD160: return "PSA_ALG_RIPEMD160";
|
||||
case PSA_ALG_SHA3_224: return "PSA_ALG_SHA3_224";
|
||||
case PSA_ALG_SHA3_256: return "PSA_ALG_SHA3_256";
|
||||
case PSA_ALG_SHA3_384: return "PSA_ALG_SHA3_384";
|
||||
case PSA_ALG_SHA3_512: return "PSA_ALG_SHA3_512";
|
||||
case PSA_ALG_SHAKE256_512: return "PSA_ALG_SHAKE256_512";
|
||||
case PSA_ALG_SHA_1: return "PSA_ALG_SHA_1";
|
||||
case PSA_ALG_SHA_224: return "PSA_ALG_SHA_224";
|
||||
case PSA_ALG_SHA_256: return "PSA_ALG_SHA_256";
|
||||
case PSA_ALG_SHA_384: return "PSA_ALG_SHA_384";
|
||||
case PSA_ALG_SHA_512: return "PSA_ALG_SHA_512";
|
||||
case PSA_ALG_SHA_512_224: return "PSA_ALG_SHA_512_224";
|
||||
case PSA_ALG_SHA_512_256: return "PSA_ALG_SHA_512_256";
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
static const char *psa_ka_algorithm_name(psa_algorithm_t ka_alg)
|
||||
{
|
||||
switch (ka_alg) {
|
||||
case PSA_ALG_CATEGORY_KEY_AGREEMENT: return "PSA_ALG_CATEGORY_KEY_AGREEMENT";
|
||||
case PSA_ALG_ECDH: return "PSA_ALG_ECDH";
|
||||
case PSA_ALG_FFDH: return "PSA_ALG_FFDH";
|
||||
default: return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
static int psa_snprint_key_type(char *buffer, size_t buffer_size,
|
||||
psa_key_type_t type)
|
||||
{
|
||||
size_t required_size = 0;
|
||||
switch (type) {
|
||||
case PSA_KEY_TYPE_AES: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_AES", 16); break;
|
||||
case PSA_KEY_TYPE_ARIA: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_ARIA", 17); break;
|
||||
case PSA_KEY_TYPE_CAMELLIA: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CAMELLIA", 21); break;
|
||||
case PSA_KEY_TYPE_CATEGORY_FLAG_PAIR: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CATEGORY_FLAG_PAIR", 31); break;
|
||||
case PSA_KEY_TYPE_CATEGORY_KEY_PAIR: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CATEGORY_KEY_PAIR", 30); break;
|
||||
case PSA_KEY_TYPE_CATEGORY_PUBLIC_KEY: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CATEGORY_PUBLIC_KEY", 32); break;
|
||||
case PSA_KEY_TYPE_CATEGORY_RAW: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CATEGORY_RAW", 25); break;
|
||||
case PSA_KEY_TYPE_CATEGORY_SYMMETRIC: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CATEGORY_SYMMETRIC", 31); break;
|
||||
case PSA_KEY_TYPE_CHACHA20: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_CHACHA20", 21); break;
|
||||
case PSA_KEY_TYPE_DERIVE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DERIVE", 19); break;
|
||||
case PSA_KEY_TYPE_DES: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DES", 16); break;
|
||||
case PSA_KEY_TYPE_DH_KEY_PAIR_BASE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DH_KEY_PAIR_BASE", 29); break;
|
||||
case PSA_KEY_TYPE_DH_PUBLIC_KEY_BASE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DH_PUBLIC_KEY_BASE", 31); break;
|
||||
case PSA_KEY_TYPE_DSA_KEY_PAIR: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DSA_KEY_PAIR", 25); break;
|
||||
case PSA_KEY_TYPE_DSA_PUBLIC_KEY: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_DSA_PUBLIC_KEY", 27); break;
|
||||
case PSA_KEY_TYPE_ECC_KEY_PAIR_BASE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_ECC_KEY_PAIR_BASE", 30); break;
|
||||
case PSA_KEY_TYPE_ECC_PUBLIC_KEY_BASE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_ECC_PUBLIC_KEY_BASE", 32); break;
|
||||
case PSA_KEY_TYPE_HMAC: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_HMAC", 17); break;
|
||||
case PSA_KEY_TYPE_NONE: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_NONE", 17); break;
|
||||
case PSA_KEY_TYPE_PASSWORD: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_PASSWORD", 21); break;
|
||||
case PSA_KEY_TYPE_PASSWORD_HASH: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_PASSWORD_HASH", 26); break;
|
||||
case PSA_KEY_TYPE_PEPPER: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_PEPPER", 19); break;
|
||||
case PSA_KEY_TYPE_RAW_DATA: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_RAW_DATA", 21); break;
|
||||
case PSA_KEY_TYPE_RSA_KEY_PAIR: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_RSA_KEY_PAIR", 25); break;
|
||||
case PSA_KEY_TYPE_RSA_PUBLIC_KEY: append(&buffer, buffer_size, &required_size, "PSA_KEY_TYPE_RSA_PUBLIC_KEY", 27); break;
|
||||
default:
|
||||
if (PSA_KEY_TYPE_IS_ECC_KEY_PAIR(type)) {
|
||||
append_with_curve(&buffer, buffer_size, &required_size,
|
||||
"PSA_KEY_TYPE_ECC_KEY_PAIR", 25,
|
||||
PSA_KEY_TYPE_ECC_GET_FAMILY(type));
|
||||
} else if (PSA_KEY_TYPE_IS_ECC_PUBLIC_KEY(type)) {
|
||||
append_with_curve(&buffer, buffer_size, &required_size,
|
||||
"PSA_KEY_TYPE_ECC_PUBLIC_KEY", 27,
|
||||
PSA_KEY_TYPE_ECC_GET_FAMILY(type));
|
||||
} else if (PSA_KEY_TYPE_IS_DH_KEY_PAIR(type)) {
|
||||
append_with_group(&buffer, buffer_size, &required_size,
|
||||
"PSA_KEY_TYPE_DH_KEY_PAIR", 24,
|
||||
PSA_KEY_TYPE_DH_GET_FAMILY(type));
|
||||
} else if (PSA_KEY_TYPE_IS_DH_PUBLIC_KEY(type)) {
|
||||
append_with_group(&buffer, buffer_size, &required_size,
|
||||
"PSA_KEY_TYPE_DH_PUBLIC_KEY", 26,
|
||||
PSA_KEY_TYPE_DH_GET_FAMILY(type));
|
||||
} else {
|
||||
return snprintf(buffer, buffer_size,
|
||||
"0x%04x", (unsigned) type);
|
||||
}
|
||||
break;
|
||||
}
|
||||
buffer[0] = 0;
|
||||
return (int) required_size;
|
||||
}
|
||||
|
||||
#define NO_LENGTH_MODIFIER 0xfffffffflu
|
||||
static int psa_snprint_algorithm(char *buffer, size_t buffer_size,
|
||||
psa_algorithm_t alg)
|
||||
{
|
||||
size_t required_size = 0;
|
||||
psa_algorithm_t core_alg = alg;
|
||||
unsigned long length_modifier = NO_LENGTH_MODIFIER;
|
||||
if (PSA_ALG_IS_MAC(alg)) {
|
||||
core_alg = PSA_ALG_TRUNCATED_MAC(alg, 0);
|
||||
if (alg & PSA_ALG_MAC_AT_LEAST_THIS_LENGTH_FLAG) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_AT_LEAST_THIS_LENGTH_MAC(", 33);
|
||||
length_modifier = PSA_MAC_TRUNCATED_LENGTH(alg);
|
||||
} else if (core_alg != alg) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_TRUNCATED_MAC(", 22);
|
||||
length_modifier = PSA_MAC_TRUNCATED_LENGTH(alg);
|
||||
}
|
||||
} else if (PSA_ALG_IS_AEAD(alg)) {
|
||||
core_alg = PSA_ALG_AEAD_WITH_DEFAULT_LENGTH_TAG(alg);
|
||||
if (core_alg == 0) {
|
||||
/* For unknown AEAD algorithms, there is no "default tag length". */
|
||||
core_alg = alg;
|
||||
} else if (alg & PSA_ALG_AEAD_AT_LEAST_THIS_LENGTH_FLAG) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_AEAD_WITH_AT_LEAST_THIS_LENGTH_TAG(", 43);
|
||||
length_modifier = PSA_ALG_AEAD_GET_TAG_LENGTH(alg);
|
||||
} else if (core_alg != alg) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_AEAD_WITH_SHORTENED_TAG(", 32);
|
||||
length_modifier = PSA_ALG_AEAD_GET_TAG_LENGTH(alg);
|
||||
}
|
||||
} else if (PSA_ALG_IS_KEY_AGREEMENT(alg) &&
|
||||
!PSA_ALG_IS_RAW_KEY_AGREEMENT(alg)) {
|
||||
core_alg = PSA_ALG_KEY_AGREEMENT_GET_KDF(alg);
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_KEY_AGREEMENT(", 22);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_ka_algorithm_name,
|
||||
PSA_ALG_KEY_AGREEMENT_GET_BASE(alg));
|
||||
append(&buffer, buffer_size, &required_size, ", ", 2);
|
||||
}
|
||||
switch (core_alg) {
|
||||
case PSA_ALG_ANY_HASH: append(&buffer, buffer_size, &required_size, "PSA_ALG_ANY_HASH", 16); break;
|
||||
case PSA_ALG_CATEGORY_AEAD: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_AEAD", 21); break;
|
||||
case PSA_ALG_CATEGORY_ASYMMETRIC_ENCRYPTION: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_ASYMMETRIC_ENCRYPTION", 38); break;
|
||||
case PSA_ALG_CATEGORY_CIPHER: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_CIPHER", 23); break;
|
||||
case PSA_ALG_CATEGORY_HASH: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_HASH", 21); break;
|
||||
case PSA_ALG_CATEGORY_KEY_AGREEMENT: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_KEY_AGREEMENT", 30); break;
|
||||
case PSA_ALG_CATEGORY_KEY_DERIVATION: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_KEY_DERIVATION", 31); break;
|
||||
case PSA_ALG_CATEGORY_MAC: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_MAC", 20); break;
|
||||
case PSA_ALG_CATEGORY_PAKE: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_PAKE", 21); break;
|
||||
case PSA_ALG_CATEGORY_SIGN: append(&buffer, buffer_size, &required_size, "PSA_ALG_CATEGORY_SIGN", 21); break;
|
||||
case PSA_ALG_CBC_MAC: append(&buffer, buffer_size, &required_size, "PSA_ALG_CBC_MAC", 15); break;
|
||||
case PSA_ALG_CBC_NO_PADDING: append(&buffer, buffer_size, &required_size, "PSA_ALG_CBC_NO_PADDING", 22); break;
|
||||
case PSA_ALG_CBC_PKCS7: append(&buffer, buffer_size, &required_size, "PSA_ALG_CBC_PKCS7", 17); break;
|
||||
case PSA_ALG_CCM: append(&buffer, buffer_size, &required_size, "PSA_ALG_CCM", 11); break;
|
||||
case PSA_ALG_CCM_STAR_NO_TAG: append(&buffer, buffer_size, &required_size, "PSA_ALG_CCM_STAR_NO_TAG", 23); break;
|
||||
case PSA_ALG_CFB: append(&buffer, buffer_size, &required_size, "PSA_ALG_CFB", 11); break;
|
||||
case PSA_ALG_CHACHA20_POLY1305: append(&buffer, buffer_size, &required_size, "PSA_ALG_CHACHA20_POLY1305", 25); break;
|
||||
case PSA_ALG_CIPHER_MAC_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_CIPHER_MAC_BASE", 23); break;
|
||||
case PSA_ALG_CMAC: append(&buffer, buffer_size, &required_size, "PSA_ALG_CMAC", 12); break;
|
||||
case PSA_ALG_CTR: append(&buffer, buffer_size, &required_size, "PSA_ALG_CTR", 11); break;
|
||||
case PSA_ALG_DETERMINISTIC_DSA_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_DETERMINISTIC_DSA_BASE", 30); break;
|
||||
case PSA_ALG_DETERMINISTIC_ECDSA_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_DETERMINISTIC_ECDSA_BASE", 32); break;
|
||||
case PSA_ALG_DSA_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_DSA_BASE", 16); break;
|
||||
case PSA_ALG_ECB_NO_PADDING: append(&buffer, buffer_size, &required_size, "PSA_ALG_ECB_NO_PADDING", 22); break;
|
||||
case PSA_ALG_ECDH: append(&buffer, buffer_size, &required_size, "PSA_ALG_ECDH", 12); break;
|
||||
case PSA_ALG_ECDSA_ANY: append(&buffer, buffer_size, &required_size, "PSA_ALG_ECDSA_ANY", 17); break;
|
||||
case PSA_ALG_ED25519PH: append(&buffer, buffer_size, &required_size, "PSA_ALG_ED25519PH", 17); break;
|
||||
case PSA_ALG_ED448PH: append(&buffer, buffer_size, &required_size, "PSA_ALG_ED448PH", 15); break;
|
||||
case PSA_ALG_FFDH: append(&buffer, buffer_size, &required_size, "PSA_ALG_FFDH", 12); break;
|
||||
case PSA_ALG_GCM: append(&buffer, buffer_size, &required_size, "PSA_ALG_GCM", 11); break;
|
||||
case PSA_ALG_HASH_EDDSA_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_HASH_EDDSA_BASE", 23); break;
|
||||
case PSA_ALG_HKDF_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_HKDF_BASE", 17); break;
|
||||
case PSA_ALG_HKDF_EXPAND_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_HKDF_EXPAND_BASE", 24); break;
|
||||
case PSA_ALG_HKDF_EXTRACT_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_HKDF_EXTRACT_BASE", 25); break;
|
||||
case PSA_ALG_HMAC_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_HMAC_BASE", 17); break;
|
||||
case PSA_ALG_JPAKE: append(&buffer, buffer_size, &required_size, "PSA_ALG_JPAKE", 13); break;
|
||||
case PSA_ALG_MD5: append(&buffer, buffer_size, &required_size, "PSA_ALG_MD5", 11); break;
|
||||
case PSA_ALG_NONE: append(&buffer, buffer_size, &required_size, "PSA_ALG_NONE", 12); break;
|
||||
case PSA_ALG_OFB: append(&buffer, buffer_size, &required_size, "PSA_ALG_OFB", 11); break;
|
||||
case PSA_ALG_PBKDF2_AES_CMAC_PRF_128: append(&buffer, buffer_size, &required_size, "PSA_ALG_PBKDF2_AES_CMAC_PRF_128", 31); break;
|
||||
case PSA_ALG_PBKDF2_HMAC_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_PBKDF2_HMAC_BASE", 24); break;
|
||||
case PSA_ALG_PURE_EDDSA: append(&buffer, buffer_size, &required_size, "PSA_ALG_PURE_EDDSA", 18); break;
|
||||
case PSA_ALG_RIPEMD160: append(&buffer, buffer_size, &required_size, "PSA_ALG_RIPEMD160", 17); break;
|
||||
case PSA_ALG_RSA_OAEP_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_RSA_OAEP_BASE", 21); break;
|
||||
case PSA_ALG_RSA_PKCS1V15_CRYPT: append(&buffer, buffer_size, &required_size, "PSA_ALG_RSA_PKCS1V15_CRYPT", 26); break;
|
||||
case PSA_ALG_RSA_PKCS1V15_SIGN_RAW: append(&buffer, buffer_size, &required_size, "PSA_ALG_RSA_PKCS1V15_SIGN_RAW", 29); break;
|
||||
case PSA_ALG_RSA_PSS_ANY_SALT_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_RSA_PSS_ANY_SALT_BASE", 29); break;
|
||||
case PSA_ALG_RSA_PSS_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_RSA_PSS_BASE", 20); break;
|
||||
case PSA_ALG_SHA3_224: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA3_224", 16); break;
|
||||
case PSA_ALG_SHA3_256: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA3_256", 16); break;
|
||||
case PSA_ALG_SHA3_384: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA3_384", 16); break;
|
||||
case PSA_ALG_SHA3_512: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA3_512", 16); break;
|
||||
case PSA_ALG_SHAKE256_512: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHAKE256_512", 20); break;
|
||||
case PSA_ALG_SHA_1: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_1", 13); break;
|
||||
case PSA_ALG_SHA_224: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_224", 15); break;
|
||||
case PSA_ALG_SHA_256: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_256", 15); break;
|
||||
case PSA_ALG_SHA_384: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_384", 15); break;
|
||||
case PSA_ALG_SHA_512: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_512", 15); break;
|
||||
case PSA_ALG_SHA_512_224: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_512_224", 19); break;
|
||||
case PSA_ALG_SHA_512_256: append(&buffer, buffer_size, &required_size, "PSA_ALG_SHA_512_256", 19); break;
|
||||
case PSA_ALG_STREAM_CIPHER: append(&buffer, buffer_size, &required_size, "PSA_ALG_STREAM_CIPHER", 21); break;
|
||||
case PSA_ALG_TLS12_ECJPAKE_TO_PMS: append(&buffer, buffer_size, &required_size, "PSA_ALG_TLS12_ECJPAKE_TO_PMS", 28); break;
|
||||
case PSA_ALG_TLS12_PRF_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_TLS12_PRF_BASE", 22); break;
|
||||
case PSA_ALG_TLS12_PSK_TO_MS_BASE: append(&buffer, buffer_size, &required_size, "PSA_ALG_TLS12_PSK_TO_MS_BASE", 28); break;
|
||||
case PSA_ALG_XTS: append(&buffer, buffer_size, &required_size, "PSA_ALG_XTS", 11); break;
|
||||
default:
|
||||
if (PSA_ALG_IS_DETERMINISTIC_DSA(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_DETERMINISTIC_DSA(", 25 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_DETERMINISTIC_ECDSA(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_DETERMINISTIC_ECDSA(", 27 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RANDOMIZED_DSA(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_DSA(", 11 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RANDOMIZED_ECDSA(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_ECDSA(", 13 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_HKDF(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_HKDF(", 12 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_HKDF_EXPAND(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_HKDF_EXPAND(", 19 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_HKDF_EXTRACT(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_HKDF_EXTRACT(", 20 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_HMAC(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_HMAC(", 12 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_PBKDF2_HMAC(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_PBKDF2_HMAC(", 19 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RSA_OAEP(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_RSA_OAEP(", 16 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RSA_PKCS1V15_SIGN(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_RSA_PKCS1V15_SIGN(", 25 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RSA_PSS_STANDARD_SALT(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_RSA_PSS(", 15 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_RSA_PSS_ANY_SALT(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_RSA_PSS_ANY_SALT(", 24 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_TLS12_PRF(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_TLS12_PRF(", 17 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else if (PSA_ALG_IS_TLS12_PSK_TO_MS(core_alg)) {
|
||||
append(&buffer, buffer_size, &required_size,
|
||||
"PSA_ALG_TLS12_PSK_TO_MS(", 23 + 1);
|
||||
append_with_alg(&buffer, buffer_size, &required_size,
|
||||
psa_hash_algorithm_name,
|
||||
PSA_ALG_GET_HASH(core_alg));
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
} else {
|
||||
append_integer(&buffer, buffer_size, &required_size,
|
||||
"0x%08lx", (unsigned long) core_alg);
|
||||
}
|
||||
break;
|
||||
}
|
||||
if (core_alg != alg) {
|
||||
if (length_modifier != NO_LENGTH_MODIFIER) {
|
||||
append(&buffer, buffer_size, &required_size, ", ", 2);
|
||||
append_integer(&buffer, buffer_size, &required_size,
|
||||
"%lu", length_modifier);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, ")", 1);
|
||||
}
|
||||
buffer[0] = 0;
|
||||
return (int) required_size;
|
||||
}
|
||||
|
||||
static int psa_snprint_key_usage(char *buffer, size_t buffer_size,
|
||||
psa_key_usage_t usage)
|
||||
{
|
||||
size_t required_size = 0;
|
||||
if (usage == 0) {
|
||||
if (buffer_size > 1) {
|
||||
buffer[0] = '0';
|
||||
buffer[1] = 0;
|
||||
} else if (buffer_size == 1) {
|
||||
buffer[0] = 0;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_COPY) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_COPY", 18);
|
||||
usage ^= PSA_KEY_USAGE_COPY;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_DECRYPT) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_DECRYPT", 21);
|
||||
usage ^= PSA_KEY_USAGE_DECRYPT;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_DERIVE) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_DERIVE", 20);
|
||||
usage ^= PSA_KEY_USAGE_DERIVE;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_ENCRYPT) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_ENCRYPT", 21);
|
||||
usage ^= PSA_KEY_USAGE_ENCRYPT;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_EXPORT) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_EXPORT", 20);
|
||||
usage ^= PSA_KEY_USAGE_EXPORT;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_SIGN_HASH) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_SIGN_HASH", 23);
|
||||
usage ^= PSA_KEY_USAGE_SIGN_HASH;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_SIGN_MESSAGE) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_SIGN_MESSAGE", 26);
|
||||
usage ^= PSA_KEY_USAGE_SIGN_MESSAGE;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_VERIFY_DERIVATION) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_VERIFY_DERIVATION", 31);
|
||||
usage ^= PSA_KEY_USAGE_VERIFY_DERIVATION;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_VERIFY_HASH) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_VERIFY_HASH", 25);
|
||||
usage ^= PSA_KEY_USAGE_VERIFY_HASH;
|
||||
}
|
||||
if (usage & PSA_KEY_USAGE_VERIFY_MESSAGE) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append(&buffer, buffer_size, &required_size, "PSA_KEY_USAGE_VERIFY_MESSAGE", 28);
|
||||
usage ^= PSA_KEY_USAGE_VERIFY_MESSAGE;
|
||||
}
|
||||
if (usage != 0) {
|
||||
if (required_size != 0) {
|
||||
append(&buffer, buffer_size, &required_size, " | ", 3);
|
||||
}
|
||||
append_integer(&buffer, buffer_size, &required_size,
|
||||
"0x%08lx", (unsigned long) usage);
|
||||
} else {
|
||||
buffer[0] = 0;
|
||||
}
|
||||
return (int) required_size;
|
||||
}
|
||||
|
||||
/* End of automatically generated file. */
|
||||
@ -92,6 +92,7 @@ int main(void)
|
||||
#define DFL_HS_TO_MIN 0
|
||||
#define DFL_HS_TO_MAX 0
|
||||
#define DFL_DTLS_MTU -1
|
||||
#define DFL_BADMAC_LIMIT -1
|
||||
#define DFL_DGRAM_PACKING 1
|
||||
#define DFL_FALLBACK -1
|
||||
#define DFL_EXTENDED_MS -1
|
||||
@ -287,7 +288,8 @@ int main(void)
|
||||
" mtu=%%d default: (library default: unlimited)\n" \
|
||||
" dgram_packing=%%d default: 1 (allowed)\n" \
|
||||
" allow or forbid packing of multiple\n" \
|
||||
" records within a single datgram.\n"
|
||||
" records within a single datagram.\n" \
|
||||
" badmac_limit=%%d default: (library default: disabled)\n"
|
||||
#else
|
||||
#define USAGE_DTLS ""
|
||||
#endif
|
||||
@ -312,7 +314,7 @@ int main(void)
|
||||
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||
#define USAGE_RENEGO \
|
||||
" renegotiation=%%d default: 0 (disabled)\n" \
|
||||
" renegotiate=%%d default: 0 (disabled)\n" \
|
||||
" renegotiate=%%d default: 0 (disabled), 1 immediately, 2 after first exchange\n" \
|
||||
" renego_delay=%%d default: -2 (library default)\n"
|
||||
#else
|
||||
#define USAGE_RENEGO ""
|
||||
@ -519,7 +521,7 @@ struct options {
|
||||
#endif /* MBEDTLS_SSL_PROTO_TLS1_3 */
|
||||
int renegotiation; /* enable / disable renegotiation */
|
||||
int allow_legacy; /* allow legacy renegotiation */
|
||||
int renegotiate; /* attempt renegotiation? */
|
||||
int renegotiate; /* attempt renegotiation? 1: before data, 2: after first exchange */
|
||||
int renego_delay; /* delay before enforcing renegotiation */
|
||||
int exchanges; /* number of data exchanges */
|
||||
int min_version; /* minimum protocol version accepted */
|
||||
@ -548,6 +550,7 @@ struct options {
|
||||
int dtls_mtu; /* UDP Maximum transport unit for DTLS */
|
||||
int fallback; /* is this a fallback connection? */
|
||||
int dgram_packing; /* allow/forbid datagram packing */
|
||||
int badmac_limit; /* Limit of records with bad MAC */
|
||||
int extended_ms; /* negotiate extended master secret? */
|
||||
int etm; /* negotiate encrypt then mac? */
|
||||
int context_crt_cb; /* use context-specific CRT verify callback */
|
||||
@ -1012,6 +1015,7 @@ int main(int argc, char *argv[])
|
||||
opt.extended_ms = DFL_EXTENDED_MS;
|
||||
opt.etm = DFL_ETM;
|
||||
opt.dgram_packing = DFL_DGRAM_PACKING;
|
||||
opt.badmac_limit = DFL_BADMAC_LIMIT;
|
||||
opt.serialize = DFL_SERIALIZE;
|
||||
opt.context_file = DFL_CONTEXT_FILE;
|
||||
opt.eap_tls = DFL_EAP_TLS;
|
||||
@ -1224,7 +1228,7 @@ usage:
|
||||
opt.renego_delay = (atoi(q));
|
||||
} else if (strcmp(p, "renegotiate") == 0) {
|
||||
opt.renegotiate = atoi(q);
|
||||
if (opt.renegotiate < 0 || opt.renegotiate > 1) {
|
||||
if (opt.renegotiate < 0 || opt.renegotiate > 2) {
|
||||
goto usage;
|
||||
}
|
||||
} else if (strcmp(p, "exchanges") == 0) {
|
||||
@ -1437,6 +1441,11 @@ usage:
|
||||
opt.dgram_packing != 1) {
|
||||
goto usage;
|
||||
}
|
||||
} else if (strcmp(p, "badmac_limit") == 0) {
|
||||
opt.badmac_limit = atoi(q);
|
||||
if (opt.badmac_limit < 0) {
|
||||
goto usage;
|
||||
}
|
||||
} else if (strcmp(p, "recsplit") == 0) {
|
||||
opt.recsplit = atoi(q);
|
||||
if (opt.recsplit < 0 || opt.recsplit > 1) {
|
||||
@ -1911,6 +1920,10 @@ usage:
|
||||
if (opt.dgram_packing != DFL_DGRAM_PACKING) {
|
||||
mbedtls_ssl_set_datagram_packing(&ssl, opt.dgram_packing);
|
||||
}
|
||||
|
||||
if (opt.badmac_limit != DFL_BADMAC_LIMIT) {
|
||||
mbedtls_ssl_conf_dtls_badmac_limit(&conf, opt.badmac_limit);
|
||||
}
|
||||
#endif /* MBEDTLS_SSL_PROTO_DTLS */
|
||||
|
||||
#if defined(MBEDTLS_SSL_MAX_FRAGMENT_LENGTH)
|
||||
@ -2536,7 +2549,7 @@ usage:
|
||||
#endif /* MBEDTLS_SSL_DTLS_CONNECTION_ID */
|
||||
|
||||
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||
if (opt.renegotiate) {
|
||||
if (opt.renegotiate == 1) {
|
||||
/*
|
||||
* Perform renegotiation (this must be done when the server is waiting
|
||||
* for input from our side).
|
||||
@ -2911,6 +2924,44 @@ send_request:
|
||||
goto send_request;
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_RENEGOTIATION)
|
||||
if (opt.renegotiate == 2) {
|
||||
/* Perform renegotiation after the first data exchange.
|
||||
* This is a one-time thing, we won't renegotiate even if there are
|
||||
* more data exchanges that cause a `goto send_request` later.
|
||||
*/
|
||||
opt.renegotiate = 0;
|
||||
|
||||
mbedtls_printf(" . Performing renegotiation...");
|
||||
fflush(stdout);
|
||||
while ((ret = mbedtls_ssl_renegotiate(&ssl)) != 0) {
|
||||
if (ret != MBEDTLS_ERR_SSL_WANT_READ &&
|
||||
ret != MBEDTLS_ERR_SSL_WANT_WRITE &&
|
||||
ret != MBEDTLS_ERR_SSL_CRYPTO_IN_PROGRESS) {
|
||||
mbedtls_printf(" failed\n ! mbedtls_ssl_renegotiate returned %d\n\n",
|
||||
ret);
|
||||
goto exit;
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_ECP_RESTARTABLE)
|
||||
if (ret == MBEDTLS_ERR_SSL_CRYPTO_IN_PROGRESS) {
|
||||
continue;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* For event-driven IO, wait for socket to become available */
|
||||
if (opt.event == 1 /* level triggered IO */) {
|
||||
#if defined(MBEDTLS_TIMING_C)
|
||||
idle(&server_fd, &timer, ret);
|
||||
#else
|
||||
idle(&server_fd, ret);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
mbedtls_printf(" ok\n");
|
||||
}
|
||||
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||
|
||||
/*
|
||||
* 7c. Simulate serialize/deserialize and go back to data exchange
|
||||
*/
|
||||
|
||||
@ -374,9 +374,6 @@ int main(void)
|
||||
#define USAGE_ANTI_REPLAY ""
|
||||
#endif
|
||||
|
||||
#define USAGE_BADMAC_LIMIT \
|
||||
" badmac_limit=%%d default: (library default: disabled)\n"
|
||||
|
||||
#if defined(MBEDTLS_SSL_PROTO_DTLS)
|
||||
#define USAGE_DTLS \
|
||||
" dtls=%%d default: 0 (TLS)\n" \
|
||||
@ -385,7 +382,8 @@ int main(void)
|
||||
" mtu=%%d default: (library default: unlimited)\n" \
|
||||
" dgram_packing=%%d default: 1 (allowed)\n" \
|
||||
" allow or forbid packing of multiple\n" \
|
||||
" records within a single datgram.\n"
|
||||
" records within a single datagram.\n" \
|
||||
" badmac_limit=%%d default: (library default: disabled)\n"
|
||||
#else
|
||||
#define USAGE_DTLS ""
|
||||
#endif
|
||||
@ -536,7 +534,6 @@ int main(void)
|
||||
USAGE_SRTP \
|
||||
USAGE_COOKIES \
|
||||
USAGE_ANTI_REPLAY \
|
||||
USAGE_BADMAC_LIMIT \
|
||||
"\n"
|
||||
#define USAGE2 \
|
||||
" auth_mode=%%s default: (library default: none)\n" \
|
||||
|
||||
5305
programs/test/query_config.c
Normal file
5305
programs/test/query_config.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -108,6 +108,12 @@ int main(void)
|
||||
" May be used multiple times, even for the same\n" \
|
||||
" message, in which case the respective message\n" \
|
||||
" gets delayed multiple times.\n" \
|
||||
" delay_encrypted_hs_cli=%%d default: 0 (don't delay)\n" \
|
||||
" delay the Nth encrypted handshake message from\n" \
|
||||
" client to server.\n" \
|
||||
" delay_encrypted_hs_srv=%%d default: 0 (don't delay)\n" \
|
||||
" delay the Nth encrypted handshake message from\n" \
|
||||
" server to client.\n" \
|
||||
" delay_srv=%%s Handshake message from server that should be\n" \
|
||||
" delayed. Possible values are 'HelloRequest',\n" \
|
||||
" 'ServerHello', 'ServerHelloDone', 'Certificate'\n" \
|
||||
@ -121,6 +127,12 @@ int main(void)
|
||||
" mtu=%%d default: 0 (unlimited)\n" \
|
||||
" drop packets larger than N bytes\n" \
|
||||
" bad_ad=0/1 default: 0 (don't add bad ApplicationData)\n" \
|
||||
" bad_ad_cli_once=%%d default: 0 (don't add bad ApplicationData)\n" \
|
||||
" add bad ApplicationData before the Nth\n" \
|
||||
" ApplicationData from client to server.\n" \
|
||||
" bad_ad_srv_once=%%d default: 0 (don't add bad ApplicationData)\n" \
|
||||
" add bad ApplicationData before the Nth\n" \
|
||||
" ApplicationData from server to client.\n" \
|
||||
" bad_cid=%%d default: 0 (don't corrupt Connection IDs)\n" \
|
||||
" duplicate 1:N packets containing a CID,\n" \
|
||||
" modifying CID in first instance of the packet.\n" \
|
||||
@ -153,9 +165,13 @@ static struct options {
|
||||
char *delay_srv[MAX_DELAYED_HS]; /* handshake types of messages from
|
||||
* server that should be delayed. */
|
||||
uint8_t delay_srv_cnt; /* Number of entries in delay_srv. */
|
||||
int delay_encrypted_hs_cli; /* Delay Nth encrypted HS from client. */
|
||||
int delay_encrypted_hs_srv; /* Delay Nth encrypted HS from server. */
|
||||
int drop; /* drop 1 packet in N (none if 0) */
|
||||
int mtu; /* drop packets larger than this */
|
||||
int bad_ad; /* inject corrupted ApplicationData record */
|
||||
int bad_ad_cli_once; /* Inject corrupted Nth AD from client. */
|
||||
int bad_ad_srv_once; /* Inject corrupted Nth AD from server. */
|
||||
unsigned bad_cid; /* inject corrupted CID record */
|
||||
int protect_hvr; /* never drop or delay HelloVerifyRequest */
|
||||
int protect_len; /* never drop/delay packet of the given size*/
|
||||
@ -224,6 +240,16 @@ static void get_options(int argc, char *argv[])
|
||||
if (opt.delay_ccs < 0 || opt.delay_ccs > 1) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
} else if (strcmp(p, "delay_encrypted_hs_cli") == 0) {
|
||||
opt.delay_encrypted_hs_cli = atoi(q);
|
||||
if (opt.delay_encrypted_hs_cli < 0) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
} else if (strcmp(p, "delay_encrypted_hs_srv") == 0) {
|
||||
opt.delay_encrypted_hs_srv = atoi(q);
|
||||
if (opt.delay_encrypted_hs_srv < 0) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
} else if (strcmp(p, "delay_cli") == 0 ||
|
||||
strcmp(p, "delay_srv") == 0) {
|
||||
uint8_t *delay_cnt;
|
||||
@ -276,6 +302,16 @@ static void get_options(int argc, char *argv[])
|
||||
if (opt.bad_ad < 0 || opt.bad_ad > 1) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
} else if (strcmp(p, "bad_ad_cli_once") == 0) {
|
||||
opt.bad_ad_cli_once = atoi(q);
|
||||
if (opt.bad_ad_cli_once < 0) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
} else if (strcmp(p, "bad_ad_srv_once") == 0) {
|
||||
opt.bad_ad_srv_once = atoi(q);
|
||||
if (opt.bad_ad_srv_once < 0) {
|
||||
exit_usage(p, q);
|
||||
}
|
||||
}
|
||||
#if defined(MBEDTLS_SSL_DTLS_CONNECTION_ID)
|
||||
else if (strcmp(p, "bad_cid") == 0) {
|
||||
@ -531,6 +567,35 @@ typedef enum {
|
||||
static inject_clihlo_state_t inject_clihlo_state;
|
||||
static packet initial_clihlo;
|
||||
|
||||
static unsigned bad_ad_cli_seen;
|
||||
static unsigned bad_ad_srv_seen;
|
||||
|
||||
static int bad_ad_once(const packet *p)
|
||||
{
|
||||
unsigned *seen;
|
||||
int bad_ad_at;
|
||||
|
||||
if (strcmp(p->type, "ApplicationData") != 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (strcmp(p->way, "S <- C") == 0) {
|
||||
seen = &bad_ad_cli_seen;
|
||||
bad_ad_at = opt.bad_ad_cli_once;
|
||||
} else {
|
||||
seen = &bad_ad_srv_seen;
|
||||
bad_ad_at = opt.bad_ad_srv_once;
|
||||
}
|
||||
|
||||
if (bad_ad_at <= 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
++*seen;
|
||||
|
||||
return *seen == (unsigned) bad_ad_at;
|
||||
}
|
||||
|
||||
static int send_packet(const packet *p, const char *why)
|
||||
{
|
||||
int ret;
|
||||
@ -562,7 +627,7 @@ static int send_packet(const packet *p, const char *why)
|
||||
}
|
||||
|
||||
/* insert corrupted ApplicationData record? */
|
||||
if (opt.bad_ad &&
|
||||
if ((bad_ad_once(p) || opt.bad_ad) &&
|
||||
strcmp(p->type, "ApplicationData") == 0) {
|
||||
unsigned char buf[MAX_MSG_SIZE];
|
||||
memcpy(buf, p->buf, p->len);
|
||||
@ -667,6 +732,31 @@ static int send_delayed(void)
|
||||
static unsigned char held[2048] = { 0 };
|
||||
#define HOLD_MAX 2
|
||||
|
||||
static unsigned encrypted_hs_cli_seen;
|
||||
static unsigned encrypted_hs_srv_seen;
|
||||
|
||||
static int delay_encrypted_hs(const packet *p)
|
||||
{
|
||||
unsigned *seen;
|
||||
int delay_at;
|
||||
|
||||
if (strcmp(p->type, "Encrypted handshake") != 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (strcmp(p->way, "S <- C") == 0) {
|
||||
seen = &encrypted_hs_cli_seen;
|
||||
delay_at = opt.delay_encrypted_hs_cli;
|
||||
} else {
|
||||
seen = &encrypted_hs_srv_seen;
|
||||
delay_at = opt.delay_encrypted_hs_srv;
|
||||
}
|
||||
|
||||
++*seen;
|
||||
|
||||
return delay_at > 0 && *seen == (unsigned) delay_at;
|
||||
}
|
||||
|
||||
static int handle_message(const char *way,
|
||||
mbedtls_net_context *dst,
|
||||
mbedtls_net_context *src)
|
||||
@ -720,6 +810,11 @@ static int handle_message(const char *way,
|
||||
}
|
||||
}
|
||||
|
||||
if (delay_encrypted_hs(&cur)) {
|
||||
delay_packet(&cur);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* do we want to drop, delay, or forward it? */
|
||||
if ((opt.mtu != 0 &&
|
||||
cur.len > (unsigned) opt.mtu) ||
|
||||
@ -854,6 +949,10 @@ accept:
|
||||
*/
|
||||
clear_pending();
|
||||
memset(held, 0, sizeof(held));
|
||||
encrypted_hs_cli_seen = 0;
|
||||
encrypted_hs_srv_seen = 0;
|
||||
bad_ad_cli_seen = 0;
|
||||
bad_ad_srv_seen = 0;
|
||||
|
||||
nb_fds = client_fd.fd;
|
||||
if (nb_fds < server_fd.fd) {
|
||||
|
||||
28
tests/.gitignore
vendored
28
tests/.gitignore
vendored
@ -16,17 +16,17 @@
|
||||
|
||||
/libtestdriver1/*
|
||||
|
||||
###START_GENERATED_FILES###
|
||||
# Generated source files
|
||||
/opt-testcases/handshake-generated.sh
|
||||
/opt-testcases/tls13-compat.sh
|
||||
/src/psa_test_wrappers.c
|
||||
/suites/*.generated.data
|
||||
/suites/test_suite_config.mbedtls_boolean.data
|
||||
/suites/test_suite_config.psa_boolean.data
|
||||
/suites/test_suite_psa_crypto_storage_format.v[0-9]*.data
|
||||
/suites/test_suite_psa_crypto_storage_format.current.data
|
||||
/include/test/psa_test_wrappers.h
|
||||
/include/test/test_keys.h
|
||||
/include/test/test_certs.h
|
||||
###END_GENERATED_FILES###
|
||||
####START_COMMENTED_GENERATED_FILES###
|
||||
## Generated source files
|
||||
#/opt-testcases/handshake-generated.sh
|
||||
#/opt-testcases/tls13-compat.sh
|
||||
#/src/psa_test_wrappers.c
|
||||
#/suites/*.generated.data
|
||||
#/suites/test_suite_config.mbedtls_boolean.data
|
||||
#/suites/test_suite_config.psa_boolean.data
|
||||
#/suites/test_suite_psa_crypto_storage_format.v[0-9]*.data
|
||||
#/suites/test_suite_psa_crypto_storage_format.current.data
|
||||
#/include/test/psa_test_wrappers.h
|
||||
#/include/test/test_keys.h
|
||||
#/include/test/test_certs.h
|
||||
####END_COMMENTED_GENERATED_FILES###
|
||||
|
||||
804
tests/include/test/psa_test_wrappers.h
Normal file
804
tests/include/test/psa_test_wrappers.h
Normal file
@ -0,0 +1,804 @@
|
||||
/* Automatically generated by generate_psa_wrappers.py, do not edit! */
|
||||
|
||||
/* Copyright The Mbed TLS Contributors
|
||||
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#ifndef TEST_PSA_TEST_WRAPPERS_H
|
||||
#define TEST_PSA_TEST_WRAPPERS_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <mbedtls/build_info.h>
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG)
|
||||
|
||||
#include <psa/crypto.h>
|
||||
#include <test/memory.h>
|
||||
#include <test/psa_crypto_helpers.h>
|
||||
#include <test/psa_test_wrappers.h>
|
||||
|
||||
#if defined(MBEDTLS_PSA_INJECT_ENTROPY)
|
||||
psa_status_t mbedtls_test_wrap_mbedtls_psa_inject_entropy(
|
||||
const uint8_t *arg0_seed,
|
||||
size_t arg1_seed_size);
|
||||
#define mbedtls_psa_inject_entropy(arg0_seed, arg1_seed_size) \
|
||||
mbedtls_test_wrap_mbedtls_psa_inject_entropy(arg0_seed, arg1_seed_size)
|
||||
#endif /* defined(MBEDTLS_PSA_INJECT_ENTROPY) */
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS)
|
||||
psa_status_t mbedtls_test_wrap_mbedtls_psa_platform_get_builtin_key(
|
||||
mbedtls_svc_key_id_t arg0_key_id,
|
||||
psa_key_lifetime_t *arg1_lifetime,
|
||||
psa_drv_slot_number_t *arg2_slot_number);
|
||||
#define mbedtls_psa_platform_get_builtin_key(arg0_key_id, arg1_lifetime, arg2_slot_number) \
|
||||
mbedtls_test_wrap_mbedtls_psa_platform_get_builtin_key(arg0_key_id, arg1_lifetime, arg2_slot_number)
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_BUILTIN_KEYS) */
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SE_C)
|
||||
psa_status_t mbedtls_test_wrap_mbedtls_psa_register_se_key(
|
||||
const psa_key_attributes_t *arg0_attributes);
|
||||
#define mbedtls_psa_register_se_key(arg0_attributes) \
|
||||
mbedtls_test_wrap_mbedtls_psa_register_se_key(arg0_attributes)
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_SE_C) */
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_abort(
|
||||
psa_aead_operation_t *arg0_operation);
|
||||
#define psa_aead_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_aead_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_decrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_nonce,
|
||||
size_t arg3_nonce_length,
|
||||
const uint8_t *arg4_additional_data,
|
||||
size_t arg5_additional_data_length,
|
||||
const uint8_t *arg6_ciphertext,
|
||||
size_t arg7_ciphertext_length,
|
||||
uint8_t *arg8_plaintext,
|
||||
size_t arg9_plaintext_size,
|
||||
size_t *arg10_plaintext_length);
|
||||
#define psa_aead_decrypt(arg0_key, arg1_alg, arg2_nonce, arg3_nonce_length, arg4_additional_data, arg5_additional_data_length, arg6_ciphertext, arg7_ciphertext_length, arg8_plaintext, arg9_plaintext_size, arg10_plaintext_length) \
|
||||
mbedtls_test_wrap_psa_aead_decrypt(arg0_key, arg1_alg, arg2_nonce, arg3_nonce_length, arg4_additional_data, arg5_additional_data_length, arg6_ciphertext, arg7_ciphertext_length, arg8_plaintext, arg9_plaintext_size, arg10_plaintext_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_decrypt_setup(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_aead_decrypt_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_aead_decrypt_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_encrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_nonce,
|
||||
size_t arg3_nonce_length,
|
||||
const uint8_t *arg4_additional_data,
|
||||
size_t arg5_additional_data_length,
|
||||
const uint8_t *arg6_plaintext,
|
||||
size_t arg7_plaintext_length,
|
||||
uint8_t *arg8_ciphertext,
|
||||
size_t arg9_ciphertext_size,
|
||||
size_t *arg10_ciphertext_length);
|
||||
#define psa_aead_encrypt(arg0_key, arg1_alg, arg2_nonce, arg3_nonce_length, arg4_additional_data, arg5_additional_data_length, arg6_plaintext, arg7_plaintext_length, arg8_ciphertext, arg9_ciphertext_size, arg10_ciphertext_length) \
|
||||
mbedtls_test_wrap_psa_aead_encrypt(arg0_key, arg1_alg, arg2_nonce, arg3_nonce_length, arg4_additional_data, arg5_additional_data_length, arg6_plaintext, arg7_plaintext_length, arg8_ciphertext, arg9_ciphertext_size, arg10_ciphertext_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_encrypt_setup(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_aead_encrypt_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_aead_encrypt_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_finish(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
uint8_t *arg1_ciphertext,
|
||||
size_t arg2_ciphertext_size,
|
||||
size_t *arg3_ciphertext_length,
|
||||
uint8_t *arg4_tag,
|
||||
size_t arg5_tag_size,
|
||||
size_t *arg6_tag_length);
|
||||
#define psa_aead_finish(arg0_operation, arg1_ciphertext, arg2_ciphertext_size, arg3_ciphertext_length, arg4_tag, arg5_tag_size, arg6_tag_length) \
|
||||
mbedtls_test_wrap_psa_aead_finish(arg0_operation, arg1_ciphertext, arg2_ciphertext_size, arg3_ciphertext_length, arg4_tag, arg5_tag_size, arg6_tag_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_generate_nonce(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
uint8_t *arg1_nonce,
|
||||
size_t arg2_nonce_size,
|
||||
size_t *arg3_nonce_length);
|
||||
#define psa_aead_generate_nonce(arg0_operation, arg1_nonce, arg2_nonce_size, arg3_nonce_length) \
|
||||
mbedtls_test_wrap_psa_aead_generate_nonce(arg0_operation, arg1_nonce, arg2_nonce_size, arg3_nonce_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_set_lengths(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
size_t arg1_ad_length,
|
||||
size_t arg2_plaintext_length);
|
||||
#define psa_aead_set_lengths(arg0_operation, arg1_ad_length, arg2_plaintext_length) \
|
||||
mbedtls_test_wrap_psa_aead_set_lengths(arg0_operation, arg1_ad_length, arg2_plaintext_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_set_nonce(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_nonce,
|
||||
size_t arg2_nonce_length);
|
||||
#define psa_aead_set_nonce(arg0_operation, arg1_nonce, arg2_nonce_length) \
|
||||
mbedtls_test_wrap_psa_aead_set_nonce(arg0_operation, arg1_nonce, arg2_nonce_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_update(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length,
|
||||
uint8_t *arg3_output,
|
||||
size_t arg4_output_size,
|
||||
size_t *arg5_output_length);
|
||||
#define psa_aead_update(arg0_operation, arg1_input, arg2_input_length, arg3_output, arg4_output_size, arg5_output_length) \
|
||||
mbedtls_test_wrap_psa_aead_update(arg0_operation, arg1_input, arg2_input_length, arg3_output, arg4_output_size, arg5_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_update_ad(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length);
|
||||
#define psa_aead_update_ad(arg0_operation, arg1_input, arg2_input_length) \
|
||||
mbedtls_test_wrap_psa_aead_update_ad(arg0_operation, arg1_input, arg2_input_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_aead_verify(
|
||||
psa_aead_operation_t *arg0_operation,
|
||||
uint8_t *arg1_plaintext,
|
||||
size_t arg2_plaintext_size,
|
||||
size_t *arg3_plaintext_length,
|
||||
const uint8_t *arg4_tag,
|
||||
size_t arg5_tag_length);
|
||||
#define psa_aead_verify(arg0_operation, arg1_plaintext, arg2_plaintext_size, arg3_plaintext_length, arg4_tag, arg5_tag_length) \
|
||||
mbedtls_test_wrap_psa_aead_verify(arg0_operation, arg1_plaintext, arg2_plaintext_size, arg3_plaintext_length, arg4_tag, arg5_tag_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_asymmetric_decrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
const uint8_t *arg4_salt,
|
||||
size_t arg5_salt_length,
|
||||
uint8_t *arg6_output,
|
||||
size_t arg7_output_size,
|
||||
size_t *arg8_output_length);
|
||||
#define psa_asymmetric_decrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_salt, arg5_salt_length, arg6_output, arg7_output_size, arg8_output_length) \
|
||||
mbedtls_test_wrap_psa_asymmetric_decrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_salt, arg5_salt_length, arg6_output, arg7_output_size, arg8_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_asymmetric_encrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
const uint8_t *arg4_salt,
|
||||
size_t arg5_salt_length,
|
||||
uint8_t *arg6_output,
|
||||
size_t arg7_output_size,
|
||||
size_t *arg8_output_length);
|
||||
#define psa_asymmetric_encrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_salt, arg5_salt_length, arg6_output, arg7_output_size, arg8_output_length) \
|
||||
mbedtls_test_wrap_psa_asymmetric_encrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_salt, arg5_salt_length, arg6_output, arg7_output_size, arg8_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_abort(
|
||||
psa_cipher_operation_t *arg0_operation);
|
||||
#define psa_cipher_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_cipher_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_decrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
uint8_t *arg4_output,
|
||||
size_t arg5_output_size,
|
||||
size_t *arg6_output_length);
|
||||
#define psa_cipher_decrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_output, arg5_output_size, arg6_output_length) \
|
||||
mbedtls_test_wrap_psa_cipher_decrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_output, arg5_output_size, arg6_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_decrypt_setup(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_cipher_decrypt_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_cipher_decrypt_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_encrypt(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
uint8_t *arg4_output,
|
||||
size_t arg5_output_size,
|
||||
size_t *arg6_output_length);
|
||||
#define psa_cipher_encrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_output, arg5_output_size, arg6_output_length) \
|
||||
mbedtls_test_wrap_psa_cipher_encrypt(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_output, arg5_output_size, arg6_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_encrypt_setup(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_cipher_encrypt_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_cipher_encrypt_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_finish(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
uint8_t *arg1_output,
|
||||
size_t arg2_output_size,
|
||||
size_t *arg3_output_length);
|
||||
#define psa_cipher_finish(arg0_operation, arg1_output, arg2_output_size, arg3_output_length) \
|
||||
mbedtls_test_wrap_psa_cipher_finish(arg0_operation, arg1_output, arg2_output_size, arg3_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_generate_iv(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
uint8_t *arg1_iv,
|
||||
size_t arg2_iv_size,
|
||||
size_t *arg3_iv_length);
|
||||
#define psa_cipher_generate_iv(arg0_operation, arg1_iv, arg2_iv_size, arg3_iv_length) \
|
||||
mbedtls_test_wrap_psa_cipher_generate_iv(arg0_operation, arg1_iv, arg2_iv_size, arg3_iv_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_set_iv(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_iv,
|
||||
size_t arg2_iv_length);
|
||||
#define psa_cipher_set_iv(arg0_operation, arg1_iv, arg2_iv_length) \
|
||||
mbedtls_test_wrap_psa_cipher_set_iv(arg0_operation, arg1_iv, arg2_iv_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_cipher_update(
|
||||
psa_cipher_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length,
|
||||
uint8_t *arg3_output,
|
||||
size_t arg4_output_size,
|
||||
size_t *arg5_output_length);
|
||||
#define psa_cipher_update(arg0_operation, arg1_input, arg2_input_length, arg3_output, arg4_output_size, arg5_output_length) \
|
||||
mbedtls_test_wrap_psa_cipher_update(arg0_operation, arg1_input, arg2_input_length, arg3_output, arg4_output_size, arg5_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_copy_key(
|
||||
mbedtls_svc_key_id_t arg0_source_key,
|
||||
const psa_key_attributes_t *arg1_attributes,
|
||||
mbedtls_svc_key_id_t *arg2_target_key);
|
||||
#define psa_copy_key(arg0_source_key, arg1_attributes, arg2_target_key) \
|
||||
mbedtls_test_wrap_psa_copy_key(arg0_source_key, arg1_attributes, arg2_target_key)
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_cipher_suite(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
psa_pake_cipher_suite_t *arg1_cipher_suite);
|
||||
#define psa_crypto_driver_pake_get_cipher_suite(arg0_inputs, arg1_cipher_suite) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_cipher_suite(arg0_inputs, arg1_cipher_suite)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_password(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
uint8_t *arg1_buffer,
|
||||
size_t arg2_buffer_size,
|
||||
size_t *arg3_buffer_length);
|
||||
#define psa_crypto_driver_pake_get_password(arg0_inputs, arg1_buffer, arg2_buffer_size, arg3_buffer_length) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_password(arg0_inputs, arg1_buffer, arg2_buffer_size, arg3_buffer_length)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_password_len(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
size_t *arg1_password_len);
|
||||
#define psa_crypto_driver_pake_get_password_len(arg0_inputs, arg1_password_len) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_password_len(arg0_inputs, arg1_password_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_peer(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
uint8_t *arg1_peer_id,
|
||||
size_t arg2_peer_id_size,
|
||||
size_t *arg3_peer_id_length);
|
||||
#define psa_crypto_driver_pake_get_peer(arg0_inputs, arg1_peer_id, arg2_peer_id_size, arg3_peer_id_length) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_peer(arg0_inputs, arg1_peer_id, arg2_peer_id_size, arg3_peer_id_length)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_peer_len(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
size_t *arg1_peer_len);
|
||||
#define psa_crypto_driver_pake_get_peer_len(arg0_inputs, arg1_peer_len) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_peer_len(arg0_inputs, arg1_peer_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_user(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
uint8_t *arg1_user_id,
|
||||
size_t arg2_user_id_size,
|
||||
size_t *arg3_user_id_len);
|
||||
#define psa_crypto_driver_pake_get_user(arg0_inputs, arg1_user_id, arg2_user_id_size, arg3_user_id_len) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_user(arg0_inputs, arg1_user_id, arg2_user_id_size, arg3_user_id_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_driver_pake_get_user_len(
|
||||
const psa_crypto_driver_pake_inputs_t *arg0_inputs,
|
||||
size_t *arg1_user_len);
|
||||
#define psa_crypto_driver_pake_get_user_len(arg0_inputs, arg1_user_len) \
|
||||
mbedtls_test_wrap_psa_crypto_driver_pake_get_user_len(arg0_inputs, arg1_user_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_crypto_init(void);
|
||||
#define psa_crypto_init() \
|
||||
mbedtls_test_wrap_psa_crypto_init()
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_destroy_key(
|
||||
mbedtls_svc_key_id_t arg0_key);
|
||||
#define psa_destroy_key(arg0_key) \
|
||||
mbedtls_test_wrap_psa_destroy_key(arg0_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_export_key(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
uint8_t *arg1_data,
|
||||
size_t arg2_data_size,
|
||||
size_t *arg3_data_length);
|
||||
#define psa_export_key(arg0_key, arg1_data, arg2_data_size, arg3_data_length) \
|
||||
mbedtls_test_wrap_psa_export_key(arg0_key, arg1_data, arg2_data_size, arg3_data_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_export_public_key(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
uint8_t *arg1_data,
|
||||
size_t arg2_data_size,
|
||||
size_t *arg3_data_length);
|
||||
#define psa_export_public_key(arg0_key, arg1_data, arg2_data_size, arg3_data_length) \
|
||||
mbedtls_test_wrap_psa_export_public_key(arg0_key, arg1_data, arg2_data_size, arg3_data_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_generate_key(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
mbedtls_svc_key_id_t *arg1_key);
|
||||
#define psa_generate_key(arg0_attributes, arg1_key) \
|
||||
mbedtls_test_wrap_psa_generate_key(arg0_attributes, arg1_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_generate_key_custom(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
const psa_custom_key_parameters_t *arg1_custom,
|
||||
const uint8_t *arg2_custom_data,
|
||||
size_t arg3_custom_data_length,
|
||||
mbedtls_svc_key_id_t *arg4_key);
|
||||
#define psa_generate_key_custom(arg0_attributes, arg1_custom, arg2_custom_data, arg3_custom_data_length, arg4_key) \
|
||||
mbedtls_test_wrap_psa_generate_key_custom(arg0_attributes, arg1_custom, arg2_custom_data, arg3_custom_data_length, arg4_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_generate_key_ext(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
const psa_key_production_parameters_t *arg1_params,
|
||||
size_t arg2_params_data_length,
|
||||
mbedtls_svc_key_id_t *arg3_key);
|
||||
#define psa_generate_key_ext(arg0_attributes, arg1_params, arg2_params_data_length, arg3_key) \
|
||||
mbedtls_test_wrap_psa_generate_key_ext(arg0_attributes, arg1_params, arg2_params_data_length, arg3_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_generate_random(
|
||||
uint8_t *arg0_output,
|
||||
size_t arg1_output_size);
|
||||
#define psa_generate_random(arg0_output, arg1_output_size) \
|
||||
mbedtls_test_wrap_psa_generate_random(arg0_output, arg1_output_size)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_get_key_attributes(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_key_attributes_t *arg1_attributes);
|
||||
#define psa_get_key_attributes(arg0_key, arg1_attributes) \
|
||||
mbedtls_test_wrap_psa_get_key_attributes(arg0_key, arg1_attributes)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_abort(
|
||||
psa_hash_operation_t *arg0_operation);
|
||||
#define psa_hash_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_hash_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_clone(
|
||||
const psa_hash_operation_t *arg0_source_operation,
|
||||
psa_hash_operation_t *arg1_target_operation);
|
||||
#define psa_hash_clone(arg0_source_operation, arg1_target_operation) \
|
||||
mbedtls_test_wrap_psa_hash_clone(arg0_source_operation, arg1_target_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_compare(
|
||||
psa_algorithm_t arg0_alg,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length,
|
||||
const uint8_t *arg3_hash,
|
||||
size_t arg4_hash_length);
|
||||
#define psa_hash_compare(arg0_alg, arg1_input, arg2_input_length, arg3_hash, arg4_hash_length) \
|
||||
mbedtls_test_wrap_psa_hash_compare(arg0_alg, arg1_input, arg2_input_length, arg3_hash, arg4_hash_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_compute(
|
||||
psa_algorithm_t arg0_alg,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length,
|
||||
uint8_t *arg3_hash,
|
||||
size_t arg4_hash_size,
|
||||
size_t *arg5_hash_length);
|
||||
#define psa_hash_compute(arg0_alg, arg1_input, arg2_input_length, arg3_hash, arg4_hash_size, arg5_hash_length) \
|
||||
mbedtls_test_wrap_psa_hash_compute(arg0_alg, arg1_input, arg2_input_length, arg3_hash, arg4_hash_size, arg5_hash_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_finish(
|
||||
psa_hash_operation_t *arg0_operation,
|
||||
uint8_t *arg1_hash,
|
||||
size_t arg2_hash_size,
|
||||
size_t *arg3_hash_length);
|
||||
#define psa_hash_finish(arg0_operation, arg1_hash, arg2_hash_size, arg3_hash_length) \
|
||||
mbedtls_test_wrap_psa_hash_finish(arg0_operation, arg1_hash, arg2_hash_size, arg3_hash_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_setup(
|
||||
psa_hash_operation_t *arg0_operation,
|
||||
psa_algorithm_t arg1_alg);
|
||||
#define psa_hash_setup(arg0_operation, arg1_alg) \
|
||||
mbedtls_test_wrap_psa_hash_setup(arg0_operation, arg1_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_update(
|
||||
psa_hash_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length);
|
||||
#define psa_hash_update(arg0_operation, arg1_input, arg2_input_length) \
|
||||
mbedtls_test_wrap_psa_hash_update(arg0_operation, arg1_input, arg2_input_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_hash_verify(
|
||||
psa_hash_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_hash,
|
||||
size_t arg2_hash_length);
|
||||
#define psa_hash_verify(arg0_operation, arg1_hash, arg2_hash_length) \
|
||||
mbedtls_test_wrap_psa_hash_verify(arg0_operation, arg1_hash, arg2_hash_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_import_key(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
const uint8_t *arg1_data,
|
||||
size_t arg2_data_length,
|
||||
mbedtls_svc_key_id_t *arg3_key);
|
||||
#define psa_import_key(arg0_attributes, arg1_data, arg2_data_length, arg3_key) \
|
||||
mbedtls_test_wrap_psa_import_key(arg0_attributes, arg1_data, arg2_data_length, arg3_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_abort(
|
||||
psa_key_derivation_operation_t *arg0_operation);
|
||||
#define psa_key_derivation_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_key_derivation_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_get_capacity(
|
||||
const psa_key_derivation_operation_t *arg0_operation,
|
||||
size_t *arg1_capacity);
|
||||
#define psa_key_derivation_get_capacity(arg0_operation, arg1_capacity) \
|
||||
mbedtls_test_wrap_psa_key_derivation_get_capacity(arg0_operation, arg1_capacity)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_input_bytes(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
psa_key_derivation_step_t arg1_step,
|
||||
const uint8_t *arg2_data,
|
||||
size_t arg3_data_length);
|
||||
#define psa_key_derivation_input_bytes(arg0_operation, arg1_step, arg2_data, arg3_data_length) \
|
||||
mbedtls_test_wrap_psa_key_derivation_input_bytes(arg0_operation, arg1_step, arg2_data, arg3_data_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_input_integer(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
psa_key_derivation_step_t arg1_step,
|
||||
uint64_t arg2_value);
|
||||
#define psa_key_derivation_input_integer(arg0_operation, arg1_step, arg2_value) \
|
||||
mbedtls_test_wrap_psa_key_derivation_input_integer(arg0_operation, arg1_step, arg2_value)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_input_key(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
psa_key_derivation_step_t arg1_step,
|
||||
mbedtls_svc_key_id_t arg2_key);
|
||||
#define psa_key_derivation_input_key(arg0_operation, arg1_step, arg2_key) \
|
||||
mbedtls_test_wrap_psa_key_derivation_input_key(arg0_operation, arg1_step, arg2_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_key_agreement(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
psa_key_derivation_step_t arg1_step,
|
||||
mbedtls_svc_key_id_t arg2_private_key,
|
||||
const uint8_t *arg3_peer_key,
|
||||
size_t arg4_peer_key_length);
|
||||
#define psa_key_derivation_key_agreement(arg0_operation, arg1_step, arg2_private_key, arg3_peer_key, arg4_peer_key_length) \
|
||||
mbedtls_test_wrap_psa_key_derivation_key_agreement(arg0_operation, arg1_step, arg2_private_key, arg3_peer_key, arg4_peer_key_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_output_bytes(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
uint8_t *arg1_output,
|
||||
size_t arg2_output_length);
|
||||
#define psa_key_derivation_output_bytes(arg0_operation, arg1_output, arg2_output_length) \
|
||||
mbedtls_test_wrap_psa_key_derivation_output_bytes(arg0_operation, arg1_output, arg2_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_output_key(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
psa_key_derivation_operation_t *arg1_operation,
|
||||
mbedtls_svc_key_id_t *arg2_key);
|
||||
#define psa_key_derivation_output_key(arg0_attributes, arg1_operation, arg2_key) \
|
||||
mbedtls_test_wrap_psa_key_derivation_output_key(arg0_attributes, arg1_operation, arg2_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_output_key_custom(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
psa_key_derivation_operation_t *arg1_operation,
|
||||
const psa_custom_key_parameters_t *arg2_custom,
|
||||
const uint8_t *arg3_custom_data,
|
||||
size_t arg4_custom_data_length,
|
||||
mbedtls_svc_key_id_t *arg5_key);
|
||||
#define psa_key_derivation_output_key_custom(arg0_attributes, arg1_operation, arg2_custom, arg3_custom_data, arg4_custom_data_length, arg5_key) \
|
||||
mbedtls_test_wrap_psa_key_derivation_output_key_custom(arg0_attributes, arg1_operation, arg2_custom, arg3_custom_data, arg4_custom_data_length, arg5_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_output_key_ext(
|
||||
const psa_key_attributes_t *arg0_attributes,
|
||||
psa_key_derivation_operation_t *arg1_operation,
|
||||
const psa_key_production_parameters_t *arg2_params,
|
||||
size_t arg3_params_data_length,
|
||||
mbedtls_svc_key_id_t *arg4_key);
|
||||
#define psa_key_derivation_output_key_ext(arg0_attributes, arg1_operation, arg2_params, arg3_params_data_length, arg4_key) \
|
||||
mbedtls_test_wrap_psa_key_derivation_output_key_ext(arg0_attributes, arg1_operation, arg2_params, arg3_params_data_length, arg4_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_set_capacity(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
size_t arg1_capacity);
|
||||
#define psa_key_derivation_set_capacity(arg0_operation, arg1_capacity) \
|
||||
mbedtls_test_wrap_psa_key_derivation_set_capacity(arg0_operation, arg1_capacity)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_key_derivation_setup(
|
||||
psa_key_derivation_operation_t *arg0_operation,
|
||||
psa_algorithm_t arg1_alg);
|
||||
#define psa_key_derivation_setup(arg0_operation, arg1_alg) \
|
||||
mbedtls_test_wrap_psa_key_derivation_setup(arg0_operation, arg1_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_abort(
|
||||
psa_mac_operation_t *arg0_operation);
|
||||
#define psa_mac_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_mac_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_compute(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
uint8_t *arg4_mac,
|
||||
size_t arg5_mac_size,
|
||||
size_t *arg6_mac_length);
|
||||
#define psa_mac_compute(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_mac, arg5_mac_size, arg6_mac_length) \
|
||||
mbedtls_test_wrap_psa_mac_compute(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_mac, arg5_mac_size, arg6_mac_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_sign_finish(
|
||||
psa_mac_operation_t *arg0_operation,
|
||||
uint8_t *arg1_mac,
|
||||
size_t arg2_mac_size,
|
||||
size_t *arg3_mac_length);
|
||||
#define psa_mac_sign_finish(arg0_operation, arg1_mac, arg2_mac_size, arg3_mac_length) \
|
||||
mbedtls_test_wrap_psa_mac_sign_finish(arg0_operation, arg1_mac, arg2_mac_size, arg3_mac_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_sign_setup(
|
||||
psa_mac_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_mac_sign_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_mac_sign_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_update(
|
||||
psa_mac_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_input,
|
||||
size_t arg2_input_length);
|
||||
#define psa_mac_update(arg0_operation, arg1_input, arg2_input_length) \
|
||||
mbedtls_test_wrap_psa_mac_update(arg0_operation, arg1_input, arg2_input_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_verify(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
const uint8_t *arg4_mac,
|
||||
size_t arg5_mac_length);
|
||||
#define psa_mac_verify(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_mac, arg5_mac_length) \
|
||||
mbedtls_test_wrap_psa_mac_verify(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_mac, arg5_mac_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_verify_finish(
|
||||
psa_mac_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_mac,
|
||||
size_t arg2_mac_length);
|
||||
#define psa_mac_verify_finish(arg0_operation, arg1_mac, arg2_mac_length) \
|
||||
mbedtls_test_wrap_psa_mac_verify_finish(arg0_operation, arg1_mac, arg2_mac_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_mac_verify_setup(
|
||||
psa_mac_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg);
|
||||
#define psa_mac_verify_setup(arg0_operation, arg1_key, arg2_alg) \
|
||||
mbedtls_test_wrap_psa_mac_verify_setup(arg0_operation, arg1_key, arg2_alg)
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_abort(
|
||||
psa_pake_operation_t *arg0_operation);
|
||||
#define psa_pake_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_pake_abort(arg0_operation)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_get_implicit_key(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
psa_key_derivation_operation_t *arg1_output);
|
||||
#define psa_pake_get_implicit_key(arg0_operation, arg1_output) \
|
||||
mbedtls_test_wrap_psa_pake_get_implicit_key(arg0_operation, arg1_output)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_input(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
psa_pake_step_t arg1_step,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length);
|
||||
#define psa_pake_input(arg0_operation, arg1_step, arg2_input, arg3_input_length) \
|
||||
mbedtls_test_wrap_psa_pake_input(arg0_operation, arg1_step, arg2_input, arg3_input_length)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_output(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
psa_pake_step_t arg1_step,
|
||||
uint8_t *arg2_output,
|
||||
size_t arg3_output_size,
|
||||
size_t *arg4_output_length);
|
||||
#define psa_pake_output(arg0_operation, arg1_step, arg2_output, arg3_output_size, arg4_output_length) \
|
||||
mbedtls_test_wrap_psa_pake_output(arg0_operation, arg1_step, arg2_output, arg3_output_size, arg4_output_length)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_set_password_key(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_password);
|
||||
#define psa_pake_set_password_key(arg0_operation, arg1_password) \
|
||||
mbedtls_test_wrap_psa_pake_set_password_key(arg0_operation, arg1_password)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_set_peer(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_peer_id,
|
||||
size_t arg2_peer_id_len);
|
||||
#define psa_pake_set_peer(arg0_operation, arg1_peer_id, arg2_peer_id_len) \
|
||||
mbedtls_test_wrap_psa_pake_set_peer(arg0_operation, arg1_peer_id, arg2_peer_id_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_set_role(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
psa_pake_role_t arg1_role);
|
||||
#define psa_pake_set_role(arg0_operation, arg1_role) \
|
||||
mbedtls_test_wrap_psa_pake_set_role(arg0_operation, arg1_role)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_set_user(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
const uint8_t *arg1_user_id,
|
||||
size_t arg2_user_id_len);
|
||||
#define psa_pake_set_user(arg0_operation, arg1_user_id, arg2_user_id_len) \
|
||||
mbedtls_test_wrap_psa_pake_set_user(arg0_operation, arg1_user_id, arg2_user_id_len)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
#if defined(PSA_WANT_ALG_SOME_PAKE)
|
||||
psa_status_t mbedtls_test_wrap_psa_pake_setup(
|
||||
psa_pake_operation_t *arg0_operation,
|
||||
const psa_pake_cipher_suite_t *arg1_cipher_suite);
|
||||
#define psa_pake_setup(arg0_operation, arg1_cipher_suite) \
|
||||
mbedtls_test_wrap_psa_pake_setup(arg0_operation, arg1_cipher_suite)
|
||||
#endif /* defined(PSA_WANT_ALG_SOME_PAKE) */
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_purge_key(
|
||||
mbedtls_svc_key_id_t arg0_key);
|
||||
#define psa_purge_key(arg0_key) \
|
||||
mbedtls_test_wrap_psa_purge_key(arg0_key)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_random_deplete(void);
|
||||
#define psa_random_deplete() \
|
||||
mbedtls_test_wrap_psa_random_deplete()
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_random_reseed(
|
||||
const uint8_t *arg0_perso,
|
||||
size_t arg1_perso_size);
|
||||
#define psa_random_reseed(arg0_perso, arg1_perso_size) \
|
||||
mbedtls_test_wrap_psa_random_reseed(arg0_perso, arg1_perso_size)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_random_set_prediction_resistance(
|
||||
unsigned arg0_enabled);
|
||||
#define psa_random_set_prediction_resistance(arg0_enabled) \
|
||||
mbedtls_test_wrap_psa_random_set_prediction_resistance(arg0_enabled)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_raw_key_agreement(
|
||||
psa_algorithm_t arg0_alg,
|
||||
mbedtls_svc_key_id_t arg1_private_key,
|
||||
const uint8_t *arg2_peer_key,
|
||||
size_t arg3_peer_key_length,
|
||||
uint8_t *arg4_output,
|
||||
size_t arg5_output_size,
|
||||
size_t *arg6_output_length);
|
||||
#define psa_raw_key_agreement(arg0_alg, arg1_private_key, arg2_peer_key, arg3_peer_key_length, arg4_output, arg5_output_size, arg6_output_length) \
|
||||
mbedtls_test_wrap_psa_raw_key_agreement(arg0_alg, arg1_private_key, arg2_peer_key, arg3_peer_key_length, arg4_output, arg5_output_size, arg6_output_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_sign_hash(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_hash,
|
||||
size_t arg3_hash_length,
|
||||
uint8_t *arg4_signature,
|
||||
size_t arg5_signature_size,
|
||||
size_t *arg6_signature_length);
|
||||
#define psa_sign_hash(arg0_key, arg1_alg, arg2_hash, arg3_hash_length, arg4_signature, arg5_signature_size, arg6_signature_length) \
|
||||
mbedtls_test_wrap_psa_sign_hash(arg0_key, arg1_alg, arg2_hash, arg3_hash_length, arg4_signature, arg5_signature_size, arg6_signature_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_sign_hash_abort(
|
||||
psa_sign_hash_interruptible_operation_t *arg0_operation);
|
||||
#define psa_sign_hash_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_sign_hash_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_sign_hash_complete(
|
||||
psa_sign_hash_interruptible_operation_t *arg0_operation,
|
||||
uint8_t *arg1_signature,
|
||||
size_t arg2_signature_size,
|
||||
size_t *arg3_signature_length);
|
||||
#define psa_sign_hash_complete(arg0_operation, arg1_signature, arg2_signature_size, arg3_signature_length) \
|
||||
mbedtls_test_wrap_psa_sign_hash_complete(arg0_operation, arg1_signature, arg2_signature_size, arg3_signature_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_sign_hash_start(
|
||||
psa_sign_hash_interruptible_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg,
|
||||
const uint8_t *arg3_hash,
|
||||
size_t arg4_hash_length);
|
||||
#define psa_sign_hash_start(arg0_operation, arg1_key, arg2_alg, arg3_hash, arg4_hash_length) \
|
||||
mbedtls_test_wrap_psa_sign_hash_start(arg0_operation, arg1_key, arg2_alg, arg3_hash, arg4_hash_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_sign_message(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
uint8_t *arg4_signature,
|
||||
size_t arg5_signature_size,
|
||||
size_t *arg6_signature_length);
|
||||
#define psa_sign_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_size, arg6_signature_length) \
|
||||
mbedtls_test_wrap_psa_sign_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_size, arg6_signature_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_verify_hash(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_hash,
|
||||
size_t arg3_hash_length,
|
||||
const uint8_t *arg4_signature,
|
||||
size_t arg5_signature_length);
|
||||
#define psa_verify_hash(arg0_key, arg1_alg, arg2_hash, arg3_hash_length, arg4_signature, arg5_signature_length) \
|
||||
mbedtls_test_wrap_psa_verify_hash(arg0_key, arg1_alg, arg2_hash, arg3_hash_length, arg4_signature, arg5_signature_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_verify_hash_abort(
|
||||
psa_verify_hash_interruptible_operation_t *arg0_operation);
|
||||
#define psa_verify_hash_abort(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_verify_hash_abort(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_verify_hash_complete(
|
||||
psa_verify_hash_interruptible_operation_t *arg0_operation);
|
||||
#define psa_verify_hash_complete(arg0_operation) \
|
||||
mbedtls_test_wrap_psa_verify_hash_complete(arg0_operation)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_verify_hash_start(
|
||||
psa_verify_hash_interruptible_operation_t *arg0_operation,
|
||||
mbedtls_svc_key_id_t arg1_key,
|
||||
psa_algorithm_t arg2_alg,
|
||||
const uint8_t *arg3_hash,
|
||||
size_t arg4_hash_length,
|
||||
const uint8_t *arg5_signature,
|
||||
size_t arg6_signature_length);
|
||||
#define psa_verify_hash_start(arg0_operation, arg1_key, arg2_alg, arg3_hash, arg4_hash_length, arg5_signature, arg6_signature_length) \
|
||||
mbedtls_test_wrap_psa_verify_hash_start(arg0_operation, arg1_key, arg2_alg, arg3_hash, arg4_hash_length, arg5_signature, arg6_signature_length)
|
||||
|
||||
psa_status_t mbedtls_test_wrap_psa_verify_message(
|
||||
mbedtls_svc_key_id_t arg0_key,
|
||||
psa_algorithm_t arg1_alg,
|
||||
const uint8_t *arg2_input,
|
||||
size_t arg3_input_length,
|
||||
const uint8_t *arg4_signature,
|
||||
size_t arg5_signature_length);
|
||||
#define psa_verify_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_length) \
|
||||
mbedtls_test_wrap_psa_verify_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_length)
|
||||
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG) */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* TEST_PSA_TEST_WRAPPERS_H */
|
||||
|
||||
/* End of automatically generated file. */
|
||||
@ -115,6 +115,9 @@ enum {
|
||||
#define MBEDTLS_TEST_MAX_ALPN_LIST_SIZE 10
|
||||
#endif
|
||||
|
||||
/* Forward declaration. Defined below. */
|
||||
struct mbedtls_test_ssl_endpoint;
|
||||
|
||||
typedef struct mbedtls_test_ssl_log_pattern {
|
||||
const char *pattern;
|
||||
size_t counter;
|
||||
@ -145,6 +148,35 @@ typedef struct mbedtls_test_handshake_test_options {
|
||||
int expected_srv_fragments;
|
||||
int renegotiate;
|
||||
int legacy_renegotiation;
|
||||
/** Hook that mbedtls_test_ssl_perform_handshake() runs just before
|
||||
* the initial handshake. */
|
||||
void (*pre_handshake_fun)(struct mbedtls_test_ssl_endpoint *client,
|
||||
struct mbedtls_test_ssl_endpoint *server,
|
||||
void *param);
|
||||
/** Value passed to ::pre_handshake_fun. */
|
||||
void *pre_handshake_param;
|
||||
/** Hook that mbedtls_test_ssl_perform_handshake() runs after
|
||||
* the initial handshake succeeds. */
|
||||
void (*post_handshake_fun)(struct mbedtls_test_ssl_endpoint *client,
|
||||
struct mbedtls_test_ssl_endpoint *server,
|
||||
void *param);
|
||||
/** Value passed to ::post_handshake_fun. */
|
||||
void *post_handshake_param;
|
||||
/** Hook that mbedtls_test_ssl_perform_handshake() runs after
|
||||
* exchanging some data, before testing additional features such as
|
||||
* serialization and renegotiation. */
|
||||
void (*post_data_fun)(struct mbedtls_test_ssl_endpoint *client,
|
||||
struct mbedtls_test_ssl_endpoint *server,
|
||||
void *param);
|
||||
/** Value passed to ::post_data_fun. */
|
||||
void *post_data_param;
|
||||
/** Hook that mbedtls_test_ssl_perform_handshake() runs after a successful
|
||||
* connection, just before closing down. */
|
||||
void (*pre_shutdown_fun)(struct mbedtls_test_ssl_endpoint *client,
|
||||
struct mbedtls_test_ssl_endpoint *server,
|
||||
void *param);
|
||||
/** Value passed to ::pre_shutdown_fun. */
|
||||
void *pre_shutdown_param;
|
||||
void *srv_log_obj;
|
||||
void *cli_log_obj;
|
||||
void (*srv_log_fun)(void *, int, const char *, int, const char *);
|
||||
|
||||
1227
tests/include/test/test_certs.h
Normal file
1227
tests/include/test/test_certs.h
Normal file
File diff suppressed because it is too large
Load Diff
1713
tests/include/test/test_keys.h
Normal file
1713
tests/include/test/test_keys.h
Normal file
File diff suppressed because it is too large
Load Diff
730
tests/opt-testcases/handshake-generated.sh
Normal file
730
tests/opt-testcases/handshake-generated.sh
Normal file
@ -0,0 +1,730 @@
|
||||
# Miscellaneous tests related to the TLS handshake layer.
|
||||
#
|
||||
# Automatically generated by generate_tls_handshake_tests.py. Do not edit!
|
||||
|
||||
# Copyright The Mbed TLS Contributors
|
||||
# SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
|
||||
|
||||
run_test "Handshake defragmentation on client: no fragmentation, for reference" \
|
||||
"$O_NEXT_SRV -allow_no_dhe_kex" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-C "waiting for more fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=512, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 512" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 512, 0\\.\\.512 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 512\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 512/" \
|
||||
-c "Consume: waiting for more handshake fragments 512/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=512, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 512" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 512, 0\\.\\.512 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 512\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 512/" \
|
||||
-c "Consume: waiting for more handshake fragments 512/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=513, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 513" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 513, 0\\.\\.513 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 513\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 513/" \
|
||||
-c "Consume: waiting for more handshake fragments 513/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=513, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 513" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 513, 0\\.\\.513 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 513\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 513/" \
|
||||
-c "Consume: waiting for more handshake fragments 513/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=256, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 256" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 256, 0\\.\\.256 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 256\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 256/" \
|
||||
-c "Consume: waiting for more handshake fragments 256/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=256, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 256" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 256, 0\\.\\.256 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 256\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 256/" \
|
||||
-c "Consume: waiting for more handshake fragments 256/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=128, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 128" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 128, 0\\.\\.128 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 128\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 128/" \
|
||||
-c "Consume: waiting for more handshake fragments 128/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=128, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 128" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 128, 0\\.\\.128 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 128\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 128/" \
|
||||
-c "Consume: waiting for more handshake fragments 128/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=64, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 64" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 64, 0\\.\\.64 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 64\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 64/" \
|
||||
-c "Consume: waiting for more handshake fragments 64/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=64, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 64" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 64, 0\\.\\.64 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 64\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 64/" \
|
||||
-c "Consume: waiting for more handshake fragments 64/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=36, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 36" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 36, 0\\.\\.36 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 36\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 36/" \
|
||||
-c "Consume: waiting for more handshake fragments 36/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=36, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 36" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 36, 0\\.\\.36 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 36\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 36/" \
|
||||
-c "Consume: waiting for more handshake fragments 36/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=32, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 32" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 32, 0\\.\\.32 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 32\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 32/" \
|
||||
-c "Consume: waiting for more handshake fragments 32/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=32, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 32" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 32, 0\\.\\.32 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 32\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 32/" \
|
||||
-c "Consume: waiting for more handshake fragments 32/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=16, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 16" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 16, 0\\.\\.16 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 16\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 16/" \
|
||||
-c "Consume: waiting for more handshake fragments 16/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=16, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 16" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 16, 0\\.\\.16 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 16\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 16/" \
|
||||
-c "Consume: waiting for more handshake fragments 16/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=13, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 13" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 13, 0\\.\\.13 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 13\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 13/" \
|
||||
-c "Consume: waiting for more handshake fragments 13/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=13, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 13" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 13, 0\\.\\.13 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 13\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 13/" \
|
||||
-c "Consume: waiting for more handshake fragments 13/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=5, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 5" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 5, 0\\.\\.5 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 5\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 5/" \
|
||||
-c "Consume: waiting for more handshake fragments 5/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=5, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 5" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 5, 0\\.\\.5 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 5\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 5/" \
|
||||
-c "Consume: waiting for more handshake fragments 5/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, default" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, null" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4 -cipher ALL@SECLEVEL=0:COMPLEMENTOFALL@SECLEVEL=0" \
|
||||
"$P_CLI debug_level=4 force_ciphersuite=TLS-ECDHE-ECDSA-WITH-NULL-SHA" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, ChachaPoly" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4 force_ciphersuite=TLS-ECDHE-ECDSA-WITH-CHACHA20-POLY1305-SHA256" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, GCM" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4 force_ciphersuite=TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, CBC, etm=n" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4 force_ciphersuite=TLS-ECDHE-ECDSA-WITH-AES-128-CBC-SHA256 etm=0" \
|
||||
0 \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/" \
|
||||
-C "using encrypt then mac"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_config_enabled MBEDTLS_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
|
||||
requires_config_enabled MBEDTLS_SSL_ENCRYPT_THEN_MAC
|
||||
run_test "Handshake defragmentation on client: len=4, TLS 1.2, CBC, etm=y" \
|
||||
"$O_NEXT_SRV -tls1_2 -split_send_frag 4" \
|
||||
"$P_CLI debug_level=4 force_ciphersuite=TLS-ECDHE-ECDSA-WITH-AES-128-CBC-SHA256 etm=1" \
|
||||
0 \
|
||||
-c "using encrypt then mac" \
|
||||
-c "reassembled record" \
|
||||
-c "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-c "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-c "Prepare: waiting for more handshake fragments 4/" \
|
||||
-c "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
run_test "Handshake defragmentation on client: len=3, TLS 1.3" \
|
||||
"$O_NEXT_SRV -tls1_3 -allow_no_dhe_kex -split_send_frag 3" \
|
||||
"$P_CLI debug_level=4" \
|
||||
1 \
|
||||
-c "=> ssl_tls13_process_server_hello" \
|
||||
-c "handshake message too short: 3" \
|
||||
-c "SSL - An invalid SSL record was received"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
run_test "Handshake defragmentation on client: len=3, TLS 1.2" \
|
||||
"$O_NEXT_SRV -tls1_2 -allow_no_dhe_kex -split_send_frag 3" \
|
||||
"$P_CLI debug_level=4" \
|
||||
1 \
|
||||
-c "handshake message too short: 3" \
|
||||
-c "SSL - An invalid SSL record was received"
|
||||
|
||||
run_test "Handshake defragmentation on server: no fragmentation, for reference" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -allow_no_dhe_kex -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-S "waiting for more fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=512, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 512 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 512, 0\\.\\.512 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 512\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 512/" \
|
||||
-s "Consume: waiting for more handshake fragments 512/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=512, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 512 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 512, 0\\.\\.512 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 512\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 512/" \
|
||||
-s "Consume: waiting for more handshake fragments 512/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=513, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 513 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 513, 0\\.\\.513 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 513\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 513/" \
|
||||
-s "Consume: waiting for more handshake fragments 513/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=513, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 513 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 513, 0\\.\\.513 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 513\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 513/" \
|
||||
-s "Consume: waiting for more handshake fragments 513/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=256, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 256 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 256, 0\\.\\.256 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 256\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 256/" \
|
||||
-s "Consume: waiting for more handshake fragments 256/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=256, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 256 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 256, 0\\.\\.256 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 256\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 256/" \
|
||||
-s "Consume: waiting for more handshake fragments 256/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=128, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 128 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 128, 0\\.\\.128 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 128\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 128/" \
|
||||
-s "Consume: waiting for more handshake fragments 128/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=128, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 128 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 128, 0\\.\\.128 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 128\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 128/" \
|
||||
-s "Consume: waiting for more handshake fragments 128/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=64, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 64 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 64, 0\\.\\.64 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 64\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 64/" \
|
||||
-s "Consume: waiting for more handshake fragments 64/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=64, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 64 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 64, 0\\.\\.64 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 64\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 64/" \
|
||||
-s "Consume: waiting for more handshake fragments 64/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=36, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 36 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 36, 0\\.\\.36 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 36\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 36/" \
|
||||
-s "Consume: waiting for more handshake fragments 36/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=36, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 36 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 36, 0\\.\\.36 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 36\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 36/" \
|
||||
-s "Consume: waiting for more handshake fragments 36/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=32, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 32 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 32, 0\\.\\.32 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 32\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 32/" \
|
||||
-s "Consume: waiting for more handshake fragments 32/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=32, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 32 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 32, 0\\.\\.32 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 32\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 32/" \
|
||||
-s "Consume: waiting for more handshake fragments 32/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=16, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 16 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 16, 0\\.\\.16 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 16\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 16/" \
|
||||
-s "Consume: waiting for more handshake fragments 16/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=16, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 16 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 16, 0\\.\\.16 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 16\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 16/" \
|
||||
-s "Consume: waiting for more handshake fragments 16/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=13, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 13 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 13, 0\\.\\.13 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 13\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 13/" \
|
||||
-s "Consume: waiting for more handshake fragments 13/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=13, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 13 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 13, 0\\.\\.13 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 13\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 13/" \
|
||||
-s "Consume: waiting for more handshake fragments 13/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=5, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 5 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 5, 0\\.\\.5 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 5\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 5/" \
|
||||
-s "Consume: waiting for more handshake fragments 5/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=5, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 5 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 5, 0\\.\\.5 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 5\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 5/" \
|
||||
-s "Consume: waiting for more handshake fragments 5/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -split_send_frag 4 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, default" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_ciphersuite_enabled TLS-ECDHE-ECDSA-WITH-NULL-SHA
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, null" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cipher ECDHE-ECDSA-NULL-SHA@SECLEVEL=0 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_ciphersuite_enabled TLS-ECDHE-ECDSA-WITH-CHACHA20-POLY1305-SHA256
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, ChachaPoly" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cipher ECDHE-ECDSA-CHACHA20-POLY1305 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_ciphersuite_enabled TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, GCM" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cipher ECDHE-ECDSA-AES128-GCM-SHA256 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_ciphersuite_enabled TLS-ECDHE-ECDSA-WITH-AES-128-CBC-SHA256
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, CBC, etm=n" \
|
||||
"$P_SRV debug_level=4 etm=0 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cipher ECDHE-ECDSA-AES128-SHA256 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/" \
|
||||
-S "using encrypt then mac"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
requires_certificate_authentication
|
||||
requires_ciphersuite_enabled TLS-ECDHE-ECDSA-WITH-AES-128-CBC-SHA256
|
||||
requires_config_enabled MBEDTLS_SSL_ENCRYPT_THEN_MAC
|
||||
run_test "Handshake defragmentation on server: len=4, TLS 1.2, CBC, etm=y" \
|
||||
"$P_SRV debug_level=4 etm=1 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -split_send_frag 4 -cipher ECDHE-ECDSA-AES128-SHA256 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
0 \
|
||||
-s "using encrypt then mac" \
|
||||
-s "reassembled record" \
|
||||
-s "initial handshake fragment: 4, 0\\.\\.4 of [0-9]\\+" \
|
||||
-s "subsequent handshake fragment: [0-9]\\+, 4\\.\\." \
|
||||
-s "Prepare: waiting for more handshake fragments 4/" \
|
||||
-s "Consume: waiting for more handshake fragments 4/"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_3
|
||||
run_test "Handshake defragmentation on server: len=3, TLS 1.3" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_3 -allow_no_dhe_kex -split_send_frag 3 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
1 \
|
||||
-s "=> parse client hello" \
|
||||
-s "handshake message too short: 3" \
|
||||
-s "SSL - An invalid SSL record was received"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
run_test "Handshake defragmentation on server: len=3, TLS 1.2" \
|
||||
"$P_SRV debug_level=4 auth_mode=required" \
|
||||
"$O_NEXT_CLI -tls1_2 -allow_no_dhe_kex -split_send_frag 3 -cert $DATA_FILES_PATH/server5.crt -key $DATA_FILES_PATH/server5.key" \
|
||||
1 \
|
||||
-s "=> parse client hello" \
|
||||
-s "handshake message too short: 3" \
|
||||
-s "SSL - An invalid SSL record was received"
|
||||
|
||||
# End of automatically generated file.
|
||||
14032
tests/opt-testcases/tls13-compat.sh
Normal file
14032
tests/opt-testcases/tls13-compat.sh
Normal file
File diff suppressed because it is too large
Load Diff
@ -449,8 +449,8 @@ class DriverVSReference_no_ecp_at_all(outcome_analysis.DriverVSReference):
|
||||
# consequence compressed points are supported in the reference
|
||||
# component but not in the accelerated one, so they should be skipped
|
||||
# while checking driver's coverage.
|
||||
re.compile(r'Parse EC Key .*compressed\)'),
|
||||
re.compile(r'Parse Public EC Key .*compressed\)'),
|
||||
re.compile(r'Parse EC Key .*(?<!un)compressed\)'),
|
||||
re.compile(r'Parse Public EC Key.*(?<!un)compressed.*'),
|
||||
],
|
||||
# See ecp_light_only
|
||||
'test_suite_ssl': [
|
||||
@ -487,8 +487,8 @@ class DriverVSReference_ecc_no_bignum(outcome_analysis.DriverVSReference):
|
||||
],
|
||||
# See no_ecp_at_all
|
||||
'test_suite_pkparse': [
|
||||
re.compile(r'Parse EC Key .*compressed\)'),
|
||||
re.compile(r'Parse Public EC Key .*compressed\)'),
|
||||
re.compile(r'Parse EC Key .*(?<!un)compressed\)'),
|
||||
re.compile(r'Parse Public EC Key.*(?<!un)compressed.*'),
|
||||
],
|
||||
'test_suite_asn1parse': [
|
||||
'INTEGER too large for mpi',
|
||||
@ -542,8 +542,8 @@ class DriverVSReference_ecc_ffdh_no_bignum(outcome_analysis.DriverVSReference):
|
||||
],
|
||||
# See no_ecp_at_all
|
||||
'test_suite_pkparse': [
|
||||
re.compile(r'Parse EC Key .*compressed\)'),
|
||||
re.compile(r'Parse Public EC Key .*compressed\)'),
|
||||
re.compile(r'Parse EC Key .*(?<!un)compressed\)'),
|
||||
re.compile(r'Parse Public EC Key.*(?<!un)compressed.*'),
|
||||
],
|
||||
'test_suite_asn1parse': [
|
||||
'INTEGER too large for mpi',
|
||||
|
||||
1423
tests/src/psa_test_wrappers.c
Normal file
1423
tests/src/psa_test_wrappers.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -2252,6 +2252,10 @@ void mbedtls_test_ssl_perform_handshake(
|
||||
expected_handshake_result = MBEDTLS_ERR_SSL_BAD_PROTOCOL_VERSION;
|
||||
}
|
||||
|
||||
if (options->pre_handshake_fun != NULL) {
|
||||
options->pre_handshake_fun(&client, &server, options->pre_handshake_param);
|
||||
}
|
||||
|
||||
TEST_ASSERT(mbedtls_test_move_handshake_to_state(&(client.ssl),
|
||||
&(server.ssl),
|
||||
MBEDTLS_SSL_HANDSHAKE_OVER)
|
||||
@ -2289,6 +2293,10 @@ void mbedtls_test_ssl_perform_handshake(
|
||||
options->expected_ciphersuite);
|
||||
}
|
||||
|
||||
if (options->post_handshake_fun != NULL) {
|
||||
options->post_handshake_fun(&client, &server, options->post_handshake_param);
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_VARIABLE_BUFFER_LENGTH)
|
||||
if (options->resize_buffers != 0) {
|
||||
/* A server, when using DTLS, might delay a buffer resize to happen
|
||||
@ -2315,6 +2323,11 @@ void mbedtls_test_ssl_perform_handshake(
|
||||
options->expected_srv_fragments)
|
||||
== 0);
|
||||
}
|
||||
|
||||
if (options->post_data_fun != NULL) {
|
||||
options->post_data_fun(&client, &server, options->post_data_param);
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_SSL_CONTEXT_SERIALIZATION)
|
||||
if (options->serialize == 1) {
|
||||
TEST_ASSERT(options->dtls == 1);
|
||||
@ -2449,6 +2462,10 @@ void mbedtls_test_ssl_perform_handshake(
|
||||
TEST_ASSERT(mbedtls_ssl_conf_get_user_data_p(&server.conf) == &server);
|
||||
TEST_ASSERT(mbedtls_ssl_get_user_data_p(&server.ssl) == &server);
|
||||
|
||||
if (options->pre_shutdown_fun != NULL) {
|
||||
options->pre_shutdown_fun(&client, &server, options->pre_shutdown_param);
|
||||
}
|
||||
|
||||
exit:
|
||||
mbedtls_test_ssl_endpoint_free(&client,
|
||||
options->dtls != 0 ? &client_context : NULL);
|
||||
|
||||
178
tests/ssl-opt.sh
178
tests/ssl-opt.sh
@ -5568,6 +5568,7 @@ run_test "Renegotiation: client-initiated, server-rejected" \
|
||||
-c "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-S "write hello request" \
|
||||
-s "refusing renegotiation" \
|
||||
-c "SSL - Unexpected message at ServerHello in renegotiation" \
|
||||
-c "failed"
|
||||
|
||||
@ -5584,6 +5585,7 @@ run_test "Renegotiation: server-initiated, client-rejected, default" \
|
||||
-C "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-S "SSL - An unexpected message was received from our peer" \
|
||||
-S "failed"
|
||||
|
||||
@ -5601,6 +5603,7 @@ run_test "Renegotiation: server-initiated, client-rejected, not enforced" \
|
||||
-C "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-S "SSL - An unexpected message was received from our peer" \
|
||||
-S "failed"
|
||||
|
||||
@ -5619,6 +5622,7 @@ run_test "Renegotiation: server-initiated, client-rejected, delay 2" \
|
||||
-C "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-S "SSL - An unexpected message was received from our peer" \
|
||||
-S "failed"
|
||||
|
||||
@ -5636,6 +5640,7 @@ run_test "Renegotiation: server-initiated, client-rejected, delay 0" \
|
||||
-C "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-s "SSL - An unexpected message was received from our peer"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
@ -5652,6 +5657,7 @@ run_test "Renegotiation: server-initiated, client-accepted, delay 0" \
|
||||
-c "=> renegotiate" \
|
||||
-s "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-C "refusing renegotiation" \
|
||||
-S "SSL - An unexpected message was received from our peer" \
|
||||
-S "failed"
|
||||
|
||||
@ -8922,6 +8928,37 @@ run_test "DHM size: server default, client 2049, rejected" \
|
||||
1 \
|
||||
-c "DHM prime too short:"
|
||||
|
||||
# Miscellaneous PSK-related tests
|
||||
|
||||
psk_identity_max_minus_10=a$(printf "%$((MAX_OUT_LEN - 11))s" z | tr ' ' .)
|
||||
|
||||
run_test "Large PSK identity (MBEDTLS_SSL_OUT_CONTENT_LEN - 7)" \
|
||||
"$P_SRV debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}987 psk=73776f726466697368" \
|
||||
"$P_CLI force_ciphersuite=TLS-ECDHE-PSK-WITH-AES-128-CBC-SHA256 debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}987 psk=73776f726466697368" \
|
||||
1 \
|
||||
-s "! mbedtls_ssl_handshake returned" \
|
||||
-c "! mbedtls_ssl_handshake returned"
|
||||
|
||||
run_test "Large PSK identity (MBEDTLS_SSL_OUT_CONTENT_LEN - 6)" \
|
||||
"$P_SRV debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}9876 psk=73776f726466697368" \
|
||||
"$P_CLI force_ciphersuite=TLS-ECDHE-PSK-WITH-AES-128-CBC-SHA256 debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}9876 psk=73776f726466697368" \
|
||||
1 \
|
||||
-s "! mbedtls_ssl_handshake returned" \
|
||||
-c "! mbedtls_ssl_handshake returned"
|
||||
|
||||
run_test "Large PSK identity (MBEDTLS_SSL_OUT_CONTENT_LEN - 5)" \
|
||||
"$P_SRV debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}98765 psk=73776f726466697368" \
|
||||
"$P_CLI force_ciphersuite=TLS-ECDHE-PSK-WITH-AES-128-CBC-SHA256 debug_level=3 \
|
||||
psk_identity=${psk_identity_max_minus_10}98765 psk=73776f726466697368" \
|
||||
1 \
|
||||
-s "! mbedtls_ssl_handshake returned" \
|
||||
-c "! mbedtls_ssl_handshake returned"
|
||||
|
||||
# Tests for PSK callback
|
||||
|
||||
run_test "PSK callback: psk, no callback" \
|
||||
@ -12763,6 +12800,147 @@ run_test "DTLS proxy: inject invalid AD record, badmac_limit 2, exchanges 2"\
|
||||
-s "too many records with bad MAC" \
|
||||
-s "Verification of the message MAC failed"
|
||||
|
||||
# The next few tests exercise renegotiation in DTLS when `ssl->badmac_seen != 0`.
|
||||
#
|
||||
# This seems unrelated, but was the location of a bug in Mbed TLS 3.6.3 to
|
||||
# 3.6.6 (CVE-2026-50713) due to `ssl->badmac_seen` being unified with
|
||||
# `ssl->in_hsfraglen` (to preserve the ABI when adding support for handshake
|
||||
# defragmentation in TLS in 3.6.3), with some mistakes in using the unified
|
||||
# field that were fixed in 3.6.7.
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: client: get invalid AD record then reject renego" \
|
||||
-p "$P_PXY bad_ad_srv_once=1" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiate=1 renegotiation=1 exchanges=4 \
|
||||
debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
exchanges=4 badmac_limit=99 debug_level=3" \
|
||||
0 \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-S "=> renegotiate" \
|
||||
-C "=> renegotiate" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-c "discarding invalid record (mac)" \
|
||||
-C "too many records with bad MAC" \
|
||||
-C "Verification of the message MAC failed" \
|
||||
-C "Consume: waiting for more handshake fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: server: get invalid AD record then reject renego" \
|
||||
-p "$P_PXY bad_ad_cli_once=1" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=0 exchanges=4 \
|
||||
badmac_limit=99 debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=1 renegotiate=2 exchanges=4 debug_level=3" \
|
||||
1 \
|
||||
-s "discarding invalid record (mac)" \
|
||||
-c "=> renegotiate" \
|
||||
-S "=> renegotiate" \
|
||||
-s "refusing renegotiation" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-S "too many records with bad MAC" \
|
||||
-S "Verification of the message MAC failed" \
|
||||
-S "Consume: waiting for more handshake fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: client: get invalid AD record then accept renego" \
|
||||
-p "$P_PXY bad_ad_srv_once=1" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiate=1 renegotiation=1 exchanges=4 \
|
||||
debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=1 exchanges=4 badmac_limit=99 debug_level=3" \
|
||||
0 \
|
||||
-s "=> renegotiate" \
|
||||
-c "=> renegotiate" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-c "discarding invalid record (mac)" \
|
||||
-C "too many records with bad MAC" \
|
||||
-C "Verification of the message MAC failed" \
|
||||
-C "Consume: waiting for more handshake fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: server: get invalid AD record then accept renego" \
|
||||
-p "$P_PXY bad_ad_cli_once=1" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=1 exchanges=4 \
|
||||
badmac_limit=99 debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=1 renegotiate=2 exchanges=4 debug_level=3" \
|
||||
0 \
|
||||
-s "discarding invalid record (mac)" \
|
||||
-c "=> renegotiate" \
|
||||
-s "=> renegotiate" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-S "too many records with bad MAC" \
|
||||
-S "Verification of the message MAC failed" \
|
||||
-S "Consume: waiting for more handshake fragments"
|
||||
|
||||
# The next few tests have "early renego". A DTLS handshake message is delayed
|
||||
# past another handshake message. From the perspective of the recipient,
|
||||
# this means that a DTLS handshake arrives early (its epoch number is still
|
||||
# in the future) and needs to be queued.
|
||||
#
|
||||
# In Mbed TLS 3.6.3 through 3.6.6, due to the fields `ssl->badmac_seen`
|
||||
# and `ssl->in_hsfraglen` being unified, the early message was parsed
|
||||
# incorrectly, leading to heap corruption.
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: client: get invalid AD record then reject early renego" \
|
||||
-p "$P_PXY bad_ad_srv_once=1 delay_encrypted_hs_srv=3" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiate=1 renegotiation=1 exchanges=4 \
|
||||
debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
exchanges=4 badmac_limit=99 debug_level=3" \
|
||||
0 \
|
||||
-S "=> renegotiate" \
|
||||
-C "=> renegotiate" \
|
||||
-s "write hello request" \
|
||||
-c "refusing renegotiation" \
|
||||
-C "=> ssl_buffer_message" \
|
||||
-C "initialize reassembly, total length = 0" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-c "discarding invalid record (mac)" \
|
||||
-C "too many records with bad MAC" \
|
||||
-C "Verification of the message MAC failed" \
|
||||
-C "Consume: waiting for more handshake fragments"
|
||||
|
||||
# Delay the third encrypted handshake message from the server:
|
||||
# 1. Finished message of the initial handshake.
|
||||
# 2. HelloRequest to request renegotiation.
|
||||
# 3. ServerHello of renegotiation, delayed.
|
||||
# 4. Subsequent handshake message, which the client receives and enqueues.
|
||||
#
|
||||
# In Mbed TLS 3.6.3 though 3.6.6, the processing of (4) caused heap corruption.
|
||||
requires_config_enabled MBEDTLS_SSL_RENEGOTIATION
|
||||
run_test "DTLS proxy: client: get invalid AD record then accept early renego" \
|
||||
-p "$P_PXY bad_ad_srv_once=1 delay_encrypted_hs_srv=3" \
|
||||
"$P_SRV dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiate=1 renegotiation=1 exchanges=4 \
|
||||
debug_level=3" \
|
||||
"$P_CLI dtls=1 dgram_packing=0 hs_timeout=500-10000 \
|
||||
renegotiation=1 exchanges=4 badmac_limit=99 debug_level=3" \
|
||||
0 \
|
||||
-s "=> renegotiate" \
|
||||
-c "=> renegotiate" \
|
||||
-c "=> ssl_buffer_message" \
|
||||
-C "initialize reassembly, total length = 0" \
|
||||
-s "Extra-header:" \
|
||||
-c "HTTP/1.0 200 OK" \
|
||||
-c "discarding invalid record (mac)" \
|
||||
-C "too many records with bad MAC" \
|
||||
-C "Verification of the message MAC failed" \
|
||||
-C "Consume: waiting for more handshake fragments"
|
||||
|
||||
requires_config_enabled MBEDTLS_SSL_PROTO_TLS1_2
|
||||
run_test "DTLS proxy: delay ChangeCipherSpec" \
|
||||
-p "$P_PXY delay_ccs=1" \
|
||||
|
||||
5361
tests/suites/test_suite_bignum.generated.data
Normal file
5361
tests/suites/test_suite_bignum.generated.data
Normal file
File diff suppressed because it is too large
Load Diff
34178
tests/suites/test_suite_bignum_core.generated.data
Normal file
34178
tests/suites/test_suite_bignum_core.generated.data
Normal file
File diff suppressed because it is too large
Load Diff
6781
tests/suites/test_suite_bignum_mod.generated.data
Normal file
6781
tests/suites/test_suite_bignum_mod.generated.data
Normal file
File diff suppressed because it is too large
Load Diff
9226
tests/suites/test_suite_bignum_mod_raw.generated.data
Normal file
9226
tests/suites/test_suite_bignum_mod_raw.generated.data
Normal file
File diff suppressed because it is too large
Load Diff
@ -22,5 +22,8 @@ chacha20_crypt:"1c9240a5eb55d38af333888604f6b5f0473917c1402b80099dca5cbc207075c0
|
||||
ChaCha20 RFC 7539 Test Vector #3 (Decrypt)
|
||||
chacha20_crypt:"1c9240a5eb55d38af333888604f6b5f0473917c1402b80099dca5cbc207075c0":"000000000000000000000002":42:"62e6347f95ed87a45ffae7426f27a1df5fb69110044c0d73118effa95b01e5cf166d3df2d721caf9b21e5fb14c616871fd84c54f9d65b283196c7fe4f60553ebf39c6402c42234e32a356b3e764312a61a5532055716ead6962568f87d3f3f7704c6a8d1bcd1bf4d50d6154b6da731b187b58dfd728afa36757a797ac188d1":"2754776173206272696c6c69672c20616e642074686520736c6974687920746f7665730a446964206779726520616e642067696d626c6520696e2074686520776162653a0a416c6c206d696d737920776572652074686520626f726f676f7665732c0a416e6420746865206d6f6d65207261746873206f757467726162652e"
|
||||
|
||||
ChaCha20 Counter Overflow
|
||||
chacha20_input_len_too_long:
|
||||
|
||||
ChaCha20 Selftest
|
||||
chacha20_self_test:
|
||||
|
||||
@ -67,6 +67,52 @@ void chacha20_crypt(data_t *key_str,
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void chacha20_input_len_too_long(void)
|
||||
{
|
||||
mbedtls_chacha20_context ctx;
|
||||
unsigned char key[32] = { 0 };
|
||||
unsigned char nonce[12] = { 0 };
|
||||
unsigned char input[65] = { 0 };
|
||||
unsigned char output[65] = { 0 };
|
||||
size_t i;
|
||||
|
||||
mbedtls_chacha20_init(&ctx);
|
||||
|
||||
TEST_ASSERT(mbedtls_chacha20_setkey(&ctx, key) == 0);
|
||||
TEST_ASSERT(mbedtls_chacha20_starts(&ctx, nonce, UINT32_MAX) == 0);
|
||||
|
||||
/*
|
||||
* An overlong call must fail before consuming buffered keystream bytes,
|
||||
* writing partial output, or advancing the context.
|
||||
*/
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 1, input, output), 0);
|
||||
memset(output, 0x2a, sizeof(output));
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 64, input, output),
|
||||
MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA);
|
||||
for (i = 0; i < sizeof(output); i++) {
|
||||
TEST_EQUAL(output[i], 0x2a);
|
||||
}
|
||||
|
||||
/* Consume the rest of the final counter block, then reject more input. */
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 63, input, output), 0);
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 0, NULL, NULL), 0);
|
||||
/*Test that zero length update does not break an exhausted context */
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 0, NULL, NULL), 0);
|
||||
TEST_EQUAL(mbedtls_chacha20_update(&ctx, 1, input, output),
|
||||
MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA);
|
||||
|
||||
/* The final counter block is valid, but generating another block is not. */
|
||||
TEST_EQUAL(mbedtls_chacha20_crypt(key, nonce, UINT32_MAX,
|
||||
64U, input, output), 0);
|
||||
TEST_EQUAL(mbedtls_chacha20_crypt(key, nonce, UINT32_MAX,
|
||||
sizeof(input), input, output),
|
||||
MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA);
|
||||
|
||||
mbedtls_chacha20_free(&ctx);
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_SELF_TEST */
|
||||
void chacha20_self_test()
|
||||
{
|
||||
|
||||
@ -19,6 +19,9 @@ mbedtls_chachapoly_dec:"1c9240a5eb55d38af333888604f6b5f0473917c1402b80099dca5cbc
|
||||
ChaCha20-Poly1305 State Flow
|
||||
chachapoly_state:
|
||||
|
||||
ChaCha20-Poly1305 overlong generates the appropriate error
|
||||
chachapoly_update_too_long:
|
||||
|
||||
ChaCha20-Poly1305 Selftest
|
||||
depends_on:MBEDTLS_SELF_TEST
|
||||
chachapoly_selftest:
|
||||
|
||||
@ -76,6 +76,39 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void chachapoly_update_too_long()
|
||||
{
|
||||
unsigned char key[32] = { 0 };
|
||||
unsigned char nonce[12] = { 0 };
|
||||
unsigned char input[65] = { 0 };
|
||||
unsigned char output[65] = { 0 };
|
||||
mbedtls_chachapoly_context ctx;
|
||||
size_t i;
|
||||
|
||||
mbedtls_chachapoly_init(&ctx);
|
||||
|
||||
TEST_EQUAL(mbedtls_chachapoly_setkey(&ctx, key), 0);
|
||||
TEST_EQUAL(mbedtls_chachapoly_starts(&ctx, nonce,
|
||||
MBEDTLS_CHACHAPOLY_ENCRYPT), 0);
|
||||
|
||||
/* Force the next update to be too long without processing a huge buffer. */
|
||||
ctx.chacha20_ctx.state[12] = UINT32_MAX;
|
||||
/* Test that the failed update does not modify the output. This is a
|
||||
* defense in depth assertion, however is not currently gauranteed by
|
||||
* the API */
|
||||
memset(output, 0x2a, sizeof(output));
|
||||
TEST_EQUAL(mbedtls_chachapoly_update(&ctx, sizeof(input), input, output),
|
||||
MBEDTLS_ERR_CHACHA20_BAD_INPUT_DATA);
|
||||
for (i = 0; i < sizeof(output); i++) {
|
||||
TEST_EQUAL(output[i], 0x2a);
|
||||
}
|
||||
|
||||
exit:
|
||||
mbedtls_chachapoly_free(&ctx);
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void chachapoly_state()
|
||||
{
|
||||
|
||||
1723
tests/suites/test_suite_config.mbedtls_boolean.data
Normal file
1723
tests/suites/test_suite_config.mbedtls_boolean.data
Normal file
File diff suppressed because it is too large
Load Diff
707
tests/suites/test_suite_config.psa_boolean.data
Normal file
707
tests/suites/test_suite_config.psa_boolean.data
Normal file
@ -0,0 +1,707 @@
|
||||
# Automatically generated by generate_config_tests.py. Do not edit!
|
||||
|
||||
Config: PSA_WANT_ALG_CBC_NO_PADDING
|
||||
depends_on:PSA_WANT_ALG_CBC_NO_PADDING:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CBC_NO_PADDING
|
||||
depends_on:!PSA_WANT_ALG_CBC_NO_PADDING:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CBC_PKCS7
|
||||
depends_on:PSA_WANT_ALG_CBC_PKCS7:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CBC_PKCS7
|
||||
depends_on:!PSA_WANT_ALG_CBC_PKCS7:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CCM
|
||||
depends_on:PSA_WANT_ALG_CCM:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CCM
|
||||
depends_on:!PSA_WANT_ALG_CCM:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CCM_STAR_NO_TAG
|
||||
depends_on:PSA_WANT_ALG_CCM_STAR_NO_TAG:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CCM_STAR_NO_TAG
|
||||
depends_on:!PSA_WANT_ALG_CCM_STAR_NO_TAG:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CFB
|
||||
depends_on:PSA_WANT_ALG_CFB:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CFB
|
||||
depends_on:!PSA_WANT_ALG_CFB:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CHACHA20_POLY1305
|
||||
depends_on:PSA_WANT_ALG_CHACHA20_POLY1305:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CHACHA20_POLY1305
|
||||
depends_on:!PSA_WANT_ALG_CHACHA20_POLY1305:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CMAC
|
||||
depends_on:PSA_WANT_ALG_CMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CMAC
|
||||
depends_on:!PSA_WANT_ALG_CMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_CTR
|
||||
depends_on:PSA_WANT_ALG_CTR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_CTR
|
||||
depends_on:!PSA_WANT_ALG_CTR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_DETERMINISTIC_ECDSA
|
||||
depends_on:PSA_WANT_ALG_DETERMINISTIC_ECDSA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_DETERMINISTIC_ECDSA
|
||||
depends_on:!PSA_WANT_ALG_DETERMINISTIC_ECDSA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_ECB_NO_PADDING
|
||||
depends_on:PSA_WANT_ALG_ECB_NO_PADDING:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_ECB_NO_PADDING
|
||||
depends_on:!PSA_WANT_ALG_ECB_NO_PADDING:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_ECDH
|
||||
depends_on:PSA_WANT_ALG_ECDH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_ECDH
|
||||
depends_on:!PSA_WANT_ALG_ECDH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_ECDSA
|
||||
depends_on:PSA_WANT_ALG_ECDSA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_ECDSA
|
||||
depends_on:!PSA_WANT_ALG_ECDSA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_FFDH
|
||||
depends_on:PSA_WANT_ALG_FFDH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_FFDH
|
||||
depends_on:!PSA_WANT_ALG_FFDH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_GCM
|
||||
depends_on:PSA_WANT_ALG_GCM:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_GCM
|
||||
depends_on:!PSA_WANT_ALG_GCM:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_HKDF
|
||||
depends_on:PSA_WANT_ALG_HKDF:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_HKDF
|
||||
depends_on:!PSA_WANT_ALG_HKDF:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_HKDF_EXPAND
|
||||
depends_on:PSA_WANT_ALG_HKDF_EXPAND:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_HKDF_EXPAND
|
||||
depends_on:!PSA_WANT_ALG_HKDF_EXPAND:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_HKDF_EXTRACT
|
||||
depends_on:PSA_WANT_ALG_HKDF_EXTRACT:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_HKDF_EXTRACT
|
||||
depends_on:!PSA_WANT_ALG_HKDF_EXTRACT:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_HMAC
|
||||
depends_on:PSA_WANT_ALG_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_HMAC
|
||||
depends_on:!PSA_WANT_ALG_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_JPAKE
|
||||
depends_on:PSA_WANT_ALG_JPAKE:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_JPAKE
|
||||
depends_on:!PSA_WANT_ALG_JPAKE:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_MD5
|
||||
depends_on:PSA_WANT_ALG_MD5:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_MD5
|
||||
depends_on:!PSA_WANT_ALG_MD5:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_OFB
|
||||
depends_on:PSA_WANT_ALG_OFB:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_OFB
|
||||
depends_on:!PSA_WANT_ALG_OFB:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128
|
||||
depends_on:PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128
|
||||
depends_on:!PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_PBKDF2_HMAC
|
||||
depends_on:PSA_WANT_ALG_PBKDF2_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_PBKDF2_HMAC
|
||||
depends_on:!PSA_WANT_ALG_PBKDF2_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_RIPEMD160
|
||||
depends_on:PSA_WANT_ALG_RIPEMD160:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_RIPEMD160
|
||||
depends_on:!PSA_WANT_ALG_RIPEMD160:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_RSA_OAEP
|
||||
depends_on:PSA_WANT_ALG_RSA_OAEP:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_RSA_OAEP
|
||||
depends_on:!PSA_WANT_ALG_RSA_OAEP:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_RSA_PKCS1V15_CRYPT
|
||||
depends_on:PSA_WANT_ALG_RSA_PKCS1V15_CRYPT:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_RSA_PKCS1V15_CRYPT
|
||||
depends_on:!PSA_WANT_ALG_RSA_PKCS1V15_CRYPT:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_RSA_PKCS1V15_SIGN
|
||||
depends_on:PSA_WANT_ALG_RSA_PKCS1V15_SIGN:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_RSA_PKCS1V15_SIGN
|
||||
depends_on:!PSA_WANT_ALG_RSA_PKCS1V15_SIGN:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_RSA_PSS
|
||||
depends_on:PSA_WANT_ALG_RSA_PSS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_RSA_PSS
|
||||
depends_on:!PSA_WANT_ALG_RSA_PSS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA3_224
|
||||
depends_on:PSA_WANT_ALG_SHA3_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA3_224
|
||||
depends_on:!PSA_WANT_ALG_SHA3_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA3_256
|
||||
depends_on:PSA_WANT_ALG_SHA3_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA3_256
|
||||
depends_on:!PSA_WANT_ALG_SHA3_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA3_384
|
||||
depends_on:PSA_WANT_ALG_SHA3_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA3_384
|
||||
depends_on:!PSA_WANT_ALG_SHA3_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA3_512
|
||||
depends_on:PSA_WANT_ALG_SHA3_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA3_512
|
||||
depends_on:!PSA_WANT_ALG_SHA3_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA_1
|
||||
depends_on:PSA_WANT_ALG_SHA_1:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA_1
|
||||
depends_on:!PSA_WANT_ALG_SHA_1:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA_224
|
||||
depends_on:PSA_WANT_ALG_SHA_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA_224
|
||||
depends_on:!PSA_WANT_ALG_SHA_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA_256
|
||||
depends_on:PSA_WANT_ALG_SHA_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA_256
|
||||
depends_on:!PSA_WANT_ALG_SHA_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA_384
|
||||
depends_on:PSA_WANT_ALG_SHA_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA_384
|
||||
depends_on:!PSA_WANT_ALG_SHA_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_SHA_512
|
||||
depends_on:PSA_WANT_ALG_SHA_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_SHA_512
|
||||
depends_on:!PSA_WANT_ALG_SHA_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_STREAM_CIPHER
|
||||
depends_on:PSA_WANT_ALG_STREAM_CIPHER:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_STREAM_CIPHER
|
||||
depends_on:!PSA_WANT_ALG_STREAM_CIPHER:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_TLS12_ECJPAKE_TO_PMS
|
||||
depends_on:PSA_WANT_ALG_TLS12_ECJPAKE_TO_PMS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_TLS12_ECJPAKE_TO_PMS
|
||||
depends_on:!PSA_WANT_ALG_TLS12_ECJPAKE_TO_PMS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_TLS12_PRF
|
||||
depends_on:PSA_WANT_ALG_TLS12_PRF:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_TLS12_PRF
|
||||
depends_on:!PSA_WANT_ALG_TLS12_PRF:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ALG_TLS12_PSK_TO_MS
|
||||
depends_on:PSA_WANT_ALG_TLS12_PSK_TO_MS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ALG_TLS12_PSK_TO_MS
|
||||
depends_on:!PSA_WANT_ALG_TLS12_PSK_TO_MS:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_DH_RFC7919_2048
|
||||
depends_on:PSA_WANT_DH_RFC7919_2048:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_DH_RFC7919_2048
|
||||
depends_on:!PSA_WANT_DH_RFC7919_2048:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_DH_RFC7919_3072
|
||||
depends_on:PSA_WANT_DH_RFC7919_3072:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_DH_RFC7919_3072
|
||||
depends_on:!PSA_WANT_DH_RFC7919_3072:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_DH_RFC7919_4096
|
||||
depends_on:PSA_WANT_DH_RFC7919_4096:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_DH_RFC7919_4096
|
||||
depends_on:!PSA_WANT_DH_RFC7919_4096:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_DH_RFC7919_6144
|
||||
depends_on:PSA_WANT_DH_RFC7919_6144:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_DH_RFC7919_6144
|
||||
depends_on:!PSA_WANT_DH_RFC7919_6144:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_DH_RFC7919_8192
|
||||
depends_on:PSA_WANT_DH_RFC7919_8192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_DH_RFC7919_8192
|
||||
depends_on:!PSA_WANT_DH_RFC7919_8192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_BRAINPOOL_P_R1_256
|
||||
depends_on:PSA_WANT_ECC_BRAINPOOL_P_R1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_BRAINPOOL_P_R1_256
|
||||
depends_on:!PSA_WANT_ECC_BRAINPOOL_P_R1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_BRAINPOOL_P_R1_384
|
||||
depends_on:PSA_WANT_ECC_BRAINPOOL_P_R1_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_BRAINPOOL_P_R1_384
|
||||
depends_on:!PSA_WANT_ECC_BRAINPOOL_P_R1_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_BRAINPOOL_P_R1_512
|
||||
depends_on:PSA_WANT_ECC_BRAINPOOL_P_R1_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_BRAINPOOL_P_R1_512
|
||||
depends_on:!PSA_WANT_ECC_BRAINPOOL_P_R1_512:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_MONTGOMERY_255
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_MONTGOMERY_255
|
||||
depends_on:!PSA_WANT_ECC_MONTGOMERY_255:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_MONTGOMERY_448
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_448:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_MONTGOMERY_448
|
||||
depends_on:!PSA_WANT_ECC_MONTGOMERY_448:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_K1_192
|
||||
depends_on:PSA_WANT_ECC_SECP_K1_192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_K1_192
|
||||
depends_on:!PSA_WANT_ECC_SECP_K1_192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_K1_256
|
||||
depends_on:PSA_WANT_ECC_SECP_K1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_K1_256
|
||||
depends_on:!PSA_WANT_ECC_SECP_K1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_R1_192
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_R1_192
|
||||
depends_on:!PSA_WANT_ECC_SECP_R1_192:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_R1_224
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_R1_224
|
||||
depends_on:!PSA_WANT_ECC_SECP_R1_224:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_R1_256
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_R1_256
|
||||
depends_on:!PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_R1_384
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_R1_384
|
||||
depends_on:!PSA_WANT_ECC_SECP_R1_384:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_ECC_SECP_R1_521
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_521:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_ECC_SECP_R1_521
|
||||
depends_on:!PSA_WANT_ECC_SECP_R1_521:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_AES
|
||||
depends_on:PSA_WANT_KEY_TYPE_AES:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_AES
|
||||
depends_on:!PSA_WANT_KEY_TYPE_AES:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ARIA
|
||||
depends_on:PSA_WANT_KEY_TYPE_ARIA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ARIA
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ARIA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_CAMELLIA
|
||||
depends_on:PSA_WANT_KEY_TYPE_CAMELLIA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_CAMELLIA
|
||||
depends_on:!PSA_WANT_KEY_TYPE_CAMELLIA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_CHACHA20
|
||||
depends_on:PSA_WANT_KEY_TYPE_CHACHA20:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_CHACHA20
|
||||
depends_on:!PSA_WANT_KEY_TYPE_CHACHA20:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DERIVE
|
||||
depends_on:PSA_WANT_KEY_TYPE_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DERIVE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DES
|
||||
depends_on:PSA_WANT_KEY_TYPE_DES:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DES
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DES:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_KEY_PAIR_DERIVE
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_KEY_PAIR_DERIVE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_KEY_PAIR_EXPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_KEY_PAIR_EXPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_KEY_PAIR_GENERATE
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_KEY_PAIR_GENERATE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_KEY_PAIR_IMPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_KEY_PAIR_IMPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_DH_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_DH_PUBLIC_KEY
|
||||
depends_on:PSA_WANT_KEY_TYPE_DH_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_DH_PUBLIC_KEY
|
||||
depends_on:!PSA_WANT_KEY_TYPE_DH_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_DERIVE
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_DERIVE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_EXPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_EXPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_GENERATE
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_GENERATE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_IMPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_IMPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_ECC_PUBLIC_KEY
|
||||
depends_on:PSA_WANT_KEY_TYPE_ECC_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_ECC_PUBLIC_KEY
|
||||
depends_on:!PSA_WANT_KEY_TYPE_ECC_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_HMAC
|
||||
depends_on:PSA_WANT_KEY_TYPE_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_HMAC
|
||||
depends_on:!PSA_WANT_KEY_TYPE_HMAC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_PASSWORD
|
||||
depends_on:PSA_WANT_KEY_TYPE_PASSWORD:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_PASSWORD
|
||||
depends_on:!PSA_WANT_KEY_TYPE_PASSWORD:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_PASSWORD_HASH
|
||||
depends_on:PSA_WANT_KEY_TYPE_PASSWORD_HASH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_PASSWORD_HASH
|
||||
depends_on:!PSA_WANT_KEY_TYPE_PASSWORD_HASH:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RAW_DATA
|
||||
depends_on:PSA_WANT_KEY_TYPE_RAW_DATA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RAW_DATA
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RAW_DATA:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_DERIVE
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_DERIVE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_DERIVE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_IMPORT
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_IMPORT
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_IMPORT:MBEDTLS_PSA_CRYPTO_CLIENT:PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC
|
||||
pass:
|
||||
|
||||
Config: PSA_WANT_KEY_TYPE_RSA_PUBLIC_KEY
|
||||
depends_on:PSA_WANT_KEY_TYPE_RSA_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
Config: !PSA_WANT_KEY_TYPE_RSA_PUBLIC_KEY
|
||||
depends_on:!PSA_WANT_KEY_TYPE_RSA_PUBLIC_KEY:MBEDTLS_PSA_CRYPTO_CLIENT
|
||||
pass:
|
||||
|
||||
# End of automatically generated file.
|
||||
@ -81,6 +81,16 @@ ECDH calc_secret: theirs first, SECP256R1 (RFC 5903)
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_SECP256R1:"c6ef9c5d78ae012a011164acb397ce2088685d8f06bf9be0b283ab46476bee53":"04dad0b65394221cf9b051e1feca5787d098dfe637fc90b9ef945d0c37725811805271a0461cdb8252d61f1c456fa3e59ab1f45b33accf5f58389e0577b8990bb3":1:"d6840f6b42f6edafd13116e0e12565202fef8e9ece7dce03812464d04b9442de"
|
||||
|
||||
# see generating script in previous commit message
|
||||
ECDH calc_secret: leading zero, SECP256R1
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_SECP256R1:"800000000000000000000000000000000000000000000000000000000000000e":"046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2964fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5":0:"0054fe92ec56ef5ad8bf4d9c46d2ca773af76c2e8c8b00e20ab772cf8b34348f"
|
||||
|
||||
# see generating script in previous commit message
|
||||
ECDH calc_secret: leading zero, SECP521R1
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_SECP521R1:"010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0400c6858e06b70404e9cd9e3ecb662395b4429c648139053fb521f828af606b4d3dbaa14b5e77efe75928fe1dc127a2ffa8de3348b3c1856a429bf97e7e31c2e5bd66011839296a789a3bc0045c8a5fb42c7d1bd998f54449579b446817afbd17273e662c97ee72995ef42640c550b9013fad0761353c7086a272c24088be94769fd16650":0:"002da7db02840f023a36e1fffeaee16d3c47bb435bec6a231d4aab1ec5412f56fb90fcc4eaab9fd8571084cb9da252466c052d21913ce0fda47e61829972ce8f9a17"
|
||||
|
||||
ecdh calc_secret: ours first (Alice), curve25519 (rfc 7748)
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_CURVE25519:"77076d0a7318a57d3c16c17251b26645df4c2f87ebc0992ab177fba51db92c2a":"de9edb7d7b7dc1b4d35b61c2ece435373f8343c85b78674dadfc7e146f882b4f":0:"4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742"
|
||||
@ -93,6 +103,32 @@ ecdh calc_secret: ours first (Bob), curve25519 (rfc 7748)
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_CURVE25519:"5dab087e624a8a4b79e17f8b83800ee66f3bb1292618b6fd1c2f8b27ff88e0eb":"8520f0098930a754748b7ddcb43ef75a0dbf3a0d26381af4eba4a98eaa9b4e6a":0:"4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742"
|
||||
|
||||
# see generating script in previous commit message
|
||||
ecdh calc_secret: MSB zero, curve25519
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_CURVE25519:"8813000000000000000000000000000000000000000000000000000000000040":"0900000000000000000000000000000000000000000000000000000000000000":0:"9ec15224edbe326c5b40fa30311421f1fb309fdd0fcaf472b5d0ad2067b7db00"
|
||||
|
||||
# see generating script in previous commit message
|
||||
ecdh calc_secret: MSB zero, curve448
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecdh_exchange_calc_secret:MBEDTLS_ECP_DP_CURVE448:"d805000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080":"0500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":0:"517b6be2c2edd157319082d4ddc688add71297284b6da74b050170035d764c19b8a14da4600715b18d8a3320a8e18a1d80fc9e6f7ea85600"
|
||||
|
||||
ECDH context re-use: secp256r1
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED
|
||||
ecdh_context_reuse:MBEDTLS_ECP_DP_SECP256R1:"8000000000000000000000000000000000000000000000000000000000000000":"046b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c2964fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5":"77b20a912e6b23135066e911891524bc4efe3560e3e92350b52dec8f375f2b54":"047cf27b188d034f7e8a52380304b51ac3c08969e277f21b35a60b48fc4766997807775510db8ed040293d9ac69f7430dbba7dade63ce982299e04b79d227873d1":"0b197a2e1e67a44b5afb62de48adde6400b60867487cab5739912513c420924a"
|
||||
|
||||
ECDH context re-use: secp521r1
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED
|
||||
ecdh_context_reuse:MBEDTLS_ECP_DP_SECP521R1:"010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0400c6858e06b70404e9cd9e3ecb662395b4429c648139053fb521f828af606b4d3dbaa14b5e77efe75928fe1dc127a2ffa8de3348b3c1856a429bf97e7e31c2e5bd66011839296a789a3bc0045c8a5fb42c7d1bd998f54449579b446817afbd17273e662c97ee72995ef42640c550b9013fad0761353c7086a272c24088be94769fd16650":"002da7db02840f023a36e1fffeaee16d3c47bb435bec6a231d4aab1ec5412f56fb90fcc4eaab9fd8571084cb9da252466c052d21913ce0fda47e61829972ce8f9a17":"0400433c219024277e7e682fcb288148c282747403279b1ccc06352c6e5505d769be97b3b204da6ef55507aa104a3a35c5af41cf2fa364d60fd967f43e3933ba6d783d00f4bb8cc7f86db26700a7f3eceeeed3f0b5c6b5107c4da97740ab21a29906c42dbbb3e377de9f251f6b93937fa99a3248f4eafcbe95edc0f4f71be356d661f41b02":"0033ffb964e05d5f6799c7865c906e2a0bd0c9b131eef6bf6453c960bca9bf06dea4650bd0df069416992b17027d972d1c60830492593fc3431582e051426b4c3f67"
|
||||
|
||||
ECDH context re-use: x25519
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecdh_context_reuse:MBEDTLS_ECP_DP_CURVE25519:"0000000000000000000000000000000000000000000000000000000000000040":"0900000000000000000000000000000000000000000000000000000000000000":"2fe57da347cd62431528daac5fbb290730fff684afc4cfc2ed90995f58cb3b74":"fb4e68dd9c46ae5c5c0b351eed5c3f8f1471157d680c75d9b7f17318d542d320":"9d8e35e77dfa6c16ed6df587251ee0d6379bd2556344aecf8f85d83fb6fa6476"
|
||||
|
||||
ECDH context re-use: x448
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecdh_context_reuse:MBEDTLS_ECP_DP_CURVE448:"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080":"0500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"e9b820a44dba3bc569bee7214b62b09ee239b50978a7a1c69a9ade46858cc37c48eb03fd88c289badd708fc635c7d863cc40e4dfdd6d5d40":"b63c741cbca4327d0808125a25f0e82571ed00daf14737bfc16f261666763c5fd7831e51fbbe9aaccc5cbdd86546ef9ad4e3ca5722329163":"b23511da3c119e32b7b146122b59d1f122f22008f02715326e62d6ca162b4f20188a95a52dd9e40cb5b729f1f153da0d51c3acfc4c81944c"
|
||||
|
||||
ECDH get_params with mismatched groups: our BP256R1, their SECP256R1
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_DP_BP256R1_ENABLED
|
||||
ecdh_exchange_get_params_fail:MBEDTLS_ECP_DP_BP256R1:"1234567812345678123456781234567812345678123456781234567812345678":MBEDTLS_ECP_DP_SECP256R1:"04dad0b65394221cf9b051e1feca5787d098dfe637fc90b9ef945d0c37725811805271a0461cdb8252d61f1c456fa3e59ab1f45b33accf5f58389e0577b8990bb3":0:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
@ -363,6 +363,79 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void ecdh_context_reuse(int grp_id, data_t *our_private_key,
|
||||
data_t *their_point1, data_t *shared1,
|
||||
data_t *their_point2, data_t *shared2)
|
||||
{
|
||||
/* This test exercises re-using the context for static ECDH */
|
||||
mbedtls_test_rnd_pseudo_info rnd_info;
|
||||
mbedtls_ecp_keypair our_key;
|
||||
mbedtls_ecp_keypair their_key1;
|
||||
mbedtls_ecp_keypair their_key2;
|
||||
mbedtls_ecdh_context ecdh;
|
||||
unsigned char *buf = NULL;
|
||||
size_t min_buf_size = 0;
|
||||
size_t shared_secret_length = 0;
|
||||
|
||||
memset(&rnd_info, 0x00, sizeof(mbedtls_test_rnd_pseudo_info));
|
||||
mbedtls_ecdh_init(&ecdh);
|
||||
mbedtls_ecp_keypair_init(&our_key);
|
||||
mbedtls_ecp_keypair_init(&their_key1);
|
||||
mbedtls_ecp_keypair_init(&their_key2);
|
||||
|
||||
if (!load_private_key(grp_id, our_private_key, &our_key, &rnd_info)) {
|
||||
goto exit;
|
||||
}
|
||||
if (!load_public_key(grp_id, their_point1, &their_key1)) {
|
||||
goto exit;
|
||||
}
|
||||
if (!load_public_key(grp_id, their_point2, &their_key2)) {
|
||||
goto exit;
|
||||
}
|
||||
|
||||
/* Import our long-term private key */
|
||||
TEST_ASSERT(mbedtls_ecdh_get_params(
|
||||
&ecdh, &our_key, MBEDTLS_ECDH_OURS) == 0);
|
||||
|
||||
/* Allocate output buffer of minimal size */
|
||||
min_buf_size = (our_key.grp.pbits + 7) / 8;
|
||||
TEST_LE_U(min_buf_size, MBEDTLS_ECP_MAX_BYTES);
|
||||
TEST_CALLOC(buf, min_buf_size);
|
||||
|
||||
/* Import first peer key and perform first ECDH calculation */
|
||||
TEST_ASSERT(mbedtls_ecdh_get_params(
|
||||
&ecdh, &their_key1, MBEDTLS_ECDH_THEIRS) == 0);
|
||||
TEST_EQUAL(0,
|
||||
mbedtls_ecdh_calc_secret(
|
||||
&ecdh, &shared_secret_length,
|
||||
buf, min_buf_size,
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info));
|
||||
TEST_MEMORY_COMPARE(shared1->x, shared1->len,
|
||||
buf, shared_secret_length);
|
||||
|
||||
shared_secret_length = 0;
|
||||
|
||||
/* Import 2nd peer key and perform 2nd ECDH calculation */
|
||||
TEST_ASSERT(mbedtls_ecdh_get_params(
|
||||
&ecdh, &their_key2, MBEDTLS_ECDH_THEIRS) == 0);
|
||||
TEST_EQUAL(0,
|
||||
mbedtls_ecdh_calc_secret(
|
||||
&ecdh, &shared_secret_length,
|
||||
buf, min_buf_size,
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info));
|
||||
TEST_MEMORY_COMPARE(shared2->x, shared2->len,
|
||||
buf, shared_secret_length);
|
||||
|
||||
exit:
|
||||
mbedtls_free(buf);
|
||||
mbedtls_ecdh_free(&ecdh);
|
||||
mbedtls_ecp_keypair_free(&our_key);
|
||||
mbedtls_ecp_keypair_free(&their_key1);
|
||||
mbedtls_ecp_keypair_free(&their_key2);
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void ecdh_exchange_calc_secret(int grp_id,
|
||||
data_t *our_private_key,
|
||||
@ -374,7 +447,8 @@ void ecdh_exchange_calc_secret(int grp_id,
|
||||
mbedtls_ecp_keypair our_key;
|
||||
mbedtls_ecp_keypair their_key;
|
||||
mbedtls_ecdh_context ecdh;
|
||||
unsigned char shared_secret[MBEDTLS_ECP_MAX_BYTES];
|
||||
unsigned char *buf = NULL;
|
||||
size_t min_buf_size = 0;
|
||||
size_t shared_secret_length = 0;
|
||||
|
||||
memset(&rnd_info, 0x00, sizeof(mbedtls_test_rnd_pseudo_info));
|
||||
@ -402,17 +476,50 @@ void ecdh_exchange_calc_secret(int grp_id,
|
||||
&ecdh, &our_key, MBEDTLS_ECDH_OURS) == 0);
|
||||
}
|
||||
|
||||
/* Perform the ECDH calculation. */
|
||||
TEST_ASSERT(mbedtls_ecdh_calc_secret(
|
||||
&ecdh,
|
||||
&shared_secret_length,
|
||||
shared_secret, sizeof(shared_secret),
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info) == 0);
|
||||
TEST_ASSERT(shared_secret_length == expected->len);
|
||||
TEST_ASSERT(memcmp(expected->x, shared_secret,
|
||||
shared_secret_length) == 0);
|
||||
/* Compute minimal size of output buffer */
|
||||
min_buf_size = (our_key.grp.pbits + 7) / 8;
|
||||
TEST_LE_U(min_buf_size, MBEDTLS_ECP_MAX_BYTES);
|
||||
|
||||
/* Perform the ECDH calculation with exact size output buffer */
|
||||
TEST_CALLOC(buf, min_buf_size);
|
||||
TEST_EQUAL(0,
|
||||
mbedtls_ecdh_calc_secret(
|
||||
&ecdh, &shared_secret_length,
|
||||
buf, min_buf_size,
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info));
|
||||
TEST_MEMORY_COMPARE(expected->x, expected->len,
|
||||
buf, shared_secret_length);
|
||||
|
||||
mbedtls_free(buf);
|
||||
buf = NULL;
|
||||
shared_secret_length = 0;
|
||||
|
||||
/* Try again with an output buffer that's larger. */
|
||||
/* Note: this doubles as a weak test for re-using a context.
|
||||
* For a proper test, see ecdh_context_reuse(). */
|
||||
TEST_CALLOC(buf, min_buf_size + 1);
|
||||
TEST_EQUAL(0,
|
||||
mbedtls_ecdh_calc_secret(
|
||||
&ecdh, &shared_secret_length,
|
||||
buf, min_buf_size + 1,
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info));
|
||||
TEST_MEMORY_COMPARE(expected->x, expected->len,
|
||||
buf, shared_secret_length);
|
||||
|
||||
mbedtls_free(buf);
|
||||
buf = NULL;
|
||||
shared_secret_length = 0;
|
||||
|
||||
/* Try again with an output buffer that's too short. */
|
||||
TEST_CALLOC(buf, min_buf_size - 1);
|
||||
TEST_EQUAL(MBEDTLS_ERR_ECP_BUFFER_TOO_SMALL,
|
||||
mbedtls_ecdh_calc_secret(
|
||||
&ecdh, &shared_secret_length,
|
||||
buf, min_buf_size - 1,
|
||||
&mbedtls_test_rnd_pseudo_rand, &rnd_info));
|
||||
|
||||
exit:
|
||||
mbedtls_free(buf);
|
||||
mbedtls_ecdh_free(&ecdh);
|
||||
mbedtls_ecp_keypair_free(&our_key);
|
||||
mbedtls_ecp_keypair_free(&their_key);
|
||||
|
||||
@ -2268,6 +2268,3 @@ ecp_mod_random:MBEDTLS_ECP_DP_SECP256K1:MBEDTLS_ECP_MOD_SCALAR
|
||||
ecp_random #25 MBEDTLS_ECP_MOD_COORDINATE(MBEDTLS_ECP_DP_CURVE448)
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_random:MBEDTLS_ECP_DP_CURVE448:MBEDTLS_ECP_MOD_COORDINATE
|
||||
|
||||
ecp variant check
|
||||
check_variant:
|
||||
|
||||
@ -1551,7 +1551,7 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_TEST_HOOKS:MBEDTLS_ECP_WITH_MPI_UINT */
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_TEST_HOOKS */
|
||||
void ecp_mod_p_generic_raw(int curve_id,
|
||||
char *input_N,
|
||||
char *input_X,
|
||||
@ -1569,8 +1569,10 @@ void ecp_mod_p_generic_raw(int curve_id,
|
||||
size_t curve_bits;
|
||||
int (*curve_func)(mbedtls_mpi_uint *X, size_t X_limbs);
|
||||
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
mbedtls_mpi_mod_modulus m;
|
||||
mbedtls_mpi_mod_modulus_init(&m);
|
||||
#endif
|
||||
|
||||
TEST_EQUAL(mbedtls_test_read_mpi_core(&X, &limbs_X, input_X), 0);
|
||||
TEST_EQUAL(mbedtls_test_read_mpi_core(&N, &limbs_N, input_N), 0);
|
||||
@ -1656,20 +1658,34 @@ void ecp_mod_p_generic_raw(int curve_id,
|
||||
TEST_EQUAL(limbs_X, limbs);
|
||||
TEST_EQUAL(limbs_res, limbs_N);
|
||||
|
||||
TEST_EQUAL(mbedtls_mpi_mod_modulus_setup(
|
||||
&m, N, limbs_N), 0);
|
||||
|
||||
TEST_EQUAL((*curve_func)(X, limbs_X), 0);
|
||||
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
/* This is what we'll do in the future, based on bignum_mod_raw */
|
||||
TEST_EQUAL(mbedtls_mpi_mod_modulus_setup(&m, N, limbs_N), 0);
|
||||
mbedtls_mpi_mod_raw_fix_quasi_reduction(X, &m);
|
||||
#else
|
||||
/* This is what we're doing now, based on bignum_core,
|
||||
* see ecp_modp() in ecp.c */
|
||||
mbedtls_mpi_uint c = mbedtls_mpi_core_sub(X, X, N, limbs_N);
|
||||
(void) mbedtls_mpi_core_add_if(X, N, limbs_N, (unsigned) c);
|
||||
#endif
|
||||
/* Checking that the result is equal to the expected value is enough,
|
||||
* but in case of failures, it's useful to know if the incorrect result
|
||||
* had the correct bitlength or not / was in the correct range or not. */
|
||||
TEST_LE_U(mbedtls_mpi_core_bitlen(X, limbs_X), curve_bits);
|
||||
/* This only works because we know from above the top limbs of X are 0. */
|
||||
TEST_EQUAL(MBEDTLS_CT_TRUE, mbedtls_mpi_core_lt_ct(X, N, limbs_N));
|
||||
TEST_MEMORY_COMPARE(X, bytes, res, bytes);
|
||||
|
||||
exit:
|
||||
mbedtls_free(X);
|
||||
mbedtls_free(res);
|
||||
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
mbedtls_mpi_mod_modulus_free(&m);
|
||||
#endif
|
||||
mbedtls_free(N);
|
||||
}
|
||||
/* END_CASE */
|
||||
@ -1914,16 +1930,3 @@ exit:
|
||||
mbedtls_free(rX_raw);
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_TEST_HOOKS:MBEDTLS_ECP_LIGHT */
|
||||
void check_variant()
|
||||
{
|
||||
mbedtls_ecp_variant variant = mbedtls_ecp_get_variant();
|
||||
|
||||
#if defined(MBEDTLS_ECP_WITH_MPI_UINT)
|
||||
TEST_EQUAL(variant, MBEDTLS_ECP_VARIANT_WITH_MPI_UINT);
|
||||
#else
|
||||
TEST_EQUAL(variant, MBEDTLS_ECP_VARIANT_WITH_MPI_STRUCT);
|
||||
#endif
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
919
tests/suites/test_suite_ecp.generated.data
Normal file
919
tests/suites/test_suite_ecp.generated.data
Normal file
@ -0,0 +1,919 @@
|
||||
# Automatically generated by generate_ecp_tests.py. Do not edit!
|
||||
|
||||
ecp_mod_p192k1_raw #1 - 0 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p192k1_raw #2 - 1 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192k1_raw #3 - fffffffffffffffffffffffffffffffffffffffeffffee36 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffeffffee36":"fffffffffffffffffffffffffffffffffffffffeffffee36"
|
||||
|
||||
ecp_mod_p192k1_raw #4 - fffffffffffffffffffffffffffffffffffffffeffffee38 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffeffffee38":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192k1_raw #5 - ffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000001000011c8"
|
||||
|
||||
ecp_mod_p192k1_raw #6 - fffffffffffffffffffffffffffffffffffffffdffffdc6c0000000000000000000000000000000100002394013c7364 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"fffffffffffffffffffffffffffffffffffffffdffffdc6c0000000000000000000000000000000100002394013c7364":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192k1_raw #7 - 7ffff71b809e27dd832cfd5e04d9d2dbb9f8da2170000000000000000000000000000000000000000520834f0 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"00000007ffff71b809e27dd832cfd5e04d9d2dbb9f8da2170000000000000000000000000000000000000000520834f0":"000000000000000000000000000000000000000800008e47"
|
||||
|
||||
ecp_mod_p192k1_raw #8 - cf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"cf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"0821179918d48f1e85b1492d55d4a563a6d095ee961b20b3"
|
||||
|
||||
ecp_mod_p192k1_raw #9 - ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738f mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738f":"171d13cd6784900a8bf38ddb90d54ce128c6135d299cfa4d"
|
||||
|
||||
ecp_mod_p192k1_raw #10 - ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93":"b32163aabbaeffedbe5b9033800d5a295a64578924db3df1"
|
||||
|
||||
ecp_mod_p192k1_raw #11 - e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2":"2cfde069f0823ce5103efcbd4b4225a1cb82d26864547e18"
|
||||
|
||||
ecp_mod_p192k1_raw #12 - 2d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"2d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"cb5f52a861d7ec7e0ddde31a239d20350769c963fd9a6529"
|
||||
|
||||
ecp_mod_p192k1_raw #13 - fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c9135 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c9135":"95e0a09c00e783ce5d82102f8e77731536bc8b2b6151ee84"
|
||||
|
||||
ecp_mod_p192k1_raw #14 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2":"74718861d1d54568a207dfec1f743c273f137beac1cd43a6"
|
||||
|
||||
ecp_mod_p192k1_raw #15 - bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"f6524cb1719c5d8f31037903ea9cc2441277b34f08474b89"
|
||||
|
||||
ecp_mod_p192k1_raw #16 - 47733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"00000000000000000000000000000000000000000000000047733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"47733e847d718d733ff98ff387c56473a7a83ee0761ebfd2"
|
||||
|
||||
ecp_mod_p192k1_raw #17 - cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63 mod fffffffffffffffffffffffffffffffffffffffeffffee37
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192K1:"fffffffffffffffffffffffffffffffffffffffeffffee37":"000000000000000000000000000000000000000000000000cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63":"cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63"
|
||||
|
||||
ecp_mod_p192_raw #1 - 0 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p192_raw #2 - 1 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192_raw #3 - fffffffffffffffffffffffffffffffefffffffffffffffe mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffefffffffffffffffe":"fffffffffffffffffffffffffffffffefffffffffffffffe"
|
||||
|
||||
ecp_mod_p192_raw #4 - ffffffffffffffffffffffffffffffff0000000000000000 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffff0000000000000000":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192_raw #5 - ffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000010000000000000000"
|
||||
|
||||
ecp_mod_p192_raw #6 - fffffffffffffffffffffffffffffffdfffffffffffffffc000000000000000100000000000000040000000000000004 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"fffffffffffffffffffffffffffffffdfffffffffffffffc000000000000000100000000000000040000000000000004":"000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p192_raw #7 - 1ffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"00000000000000000000000000000001ffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000":"000000000000000200000000000000010000000000000000"
|
||||
|
||||
ecp_mod_p192_raw #8 - ffffffffffffffff00000000000000010000000000000000fffffffffffffffeffffffffffffffff0000000000000000 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"ffffffffffffffff00000000000000010000000000000000fffffffffffffffeffffffffffffffff0000000000000000":"000000000000000000000000000000020000000000000001"
|
||||
|
||||
ecp_mod_p192_raw #9 - cf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"cf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"11d34d17a0c5ef3d302b26449aaac6f7087b21d0c6e15cc9"
|
||||
|
||||
ecp_mod_p192_raw #10 - ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738f mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738f":"e4a7b1885874b900f7e16077a78ef49ce3a85a926f5696e2"
|
||||
|
||||
ecp_mod_p192_raw #11 - ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93":"2b031a18377216979ed9ab58e1c5c3bf154fe728f83c0c0d"
|
||||
|
||||
ecp_mod_p192_raw #12 - e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2":"b5ebd2ded1bc8cfb1ad56935143c43e8c619d7d3ca6f854b"
|
||||
|
||||
ecp_mod_p192_raw #13 - 2d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"2d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"926235fec925e1797804d3e4b6581175c71bc373f6e1d417"
|
||||
|
||||
ecp_mod_p192_raw #14 - fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c9135 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c9135":"ea2dabcc5dd606da94378396fde052bdaeb89212817396b1"
|
||||
|
||||
ecp_mod_p192_raw #15 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2":"7bace2fe497b1d2b47e86aab41885802f295febe970486d0"
|
||||
|
||||
ecp_mod_p192_raw #16 - bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"958f9e1b6e59ae10f3cd72d09c7f37d20e2f54ca3ae94f5a"
|
||||
|
||||
ecp_mod_p192_raw #17 - 47733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"00000000000000000000000000000000000000000000000047733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"47733e847d718d733ff98ff387c56473a7a83ee0761ebfd2"
|
||||
|
||||
ecp_mod_p192_raw #18 - cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63 mod fffffffffffffffffffffffffffffffeffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP192R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP192R1:"fffffffffffffffffffffffffffffffeffffffffffffffff":"000000000000000000000000000000000000000000000000cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63":"cbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb63"
|
||||
|
||||
ecp_mod_p224k1_raw #1 - 0 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"00000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p224k1_raw #2 - 0 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p224k1_raw #3 - 1 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #4 - 1 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #5 - fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c":"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c"
|
||||
|
||||
ecp_mod_p224k1_raw #6 - fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c":"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56c"
|
||||
|
||||
ecp_mod_p224k1_raw #7 - fffffffffffffffffffffffffffffffffffffffffffffffeffffe56e mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56e":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #8 - fffffffffffffffffffffffffffffffffffffffffffffffeffffe56e mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56e":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #9 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000100001a92"
|
||||
|
||||
ecp_mod_p224k1_raw #10 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000100001a92"
|
||||
|
||||
ecp_mod_p224k1_raw #11 - fffffffffffffffffffffffffffffffffffffffffffffffdffffcad800000000000000000000000000000000000000010000352802c26590 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"fffffffffffffffffffffffffffffffffffffffffffffffdffffcad800000000000000000000000000000000000000010000352802c26590":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #12 - fffffffffffffffffffffffffffffffffffffffffffffffdffffcad800000000000000000000000000000000000000010000352802c26590 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000fffffffffffffffffffffffffffffffffffffffffffffffdffffcad800000000000000000000000000000000000000010000352802c26590":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224k1_raw #13 - 7ffff2b68161180fd8cd92e1a109be158a19a99b1809db80320000000000000000000000000000000000000000000000000bf04f49 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000007ffff2b68161180fd8cd92e1a109be158a19a99b1809db80320000000000000000000000000000000000000000000000000bf04f49":"000000000000000000000000000000000000000000000080000d497f"
|
||||
|
||||
ecp_mod_p224k1_raw #14 - 7ffff2b68161180fd8cd92e1a109be158a19a99b1809db80320000000000000000000000000000000000000000000000000bf04f49 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000007ffff2b68161180fd8cd92e1a109be158a19a99b1809db80320000000000000000000000000000000000000000000000000bf04f49":"00000000000000000000000000000000000000000000000000000080000d497f"
|
||||
|
||||
ecp_mod_p224k1_raw #15 - da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"63d21f711392336f294cc013d26cbe740f2368e0fa14295edfe247e3"
|
||||
|
||||
ecp_mod_p224k1_raw #16 - da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"0000000063d21f711392336f294cc013d26cbe740f2368e0fa14295edfe247e3"
|
||||
|
||||
ecp_mod_p224k1_raw #17 - cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8":"56840037df03e4e68ed85df40eb84f0cd9ef4a553712178532a54724"
|
||||
|
||||
ecp_mod_p224k1_raw #18 - cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8":"0000000056840037df03e4e68ed85df40eb84f0cd9ef4a553712178532a54724"
|
||||
|
||||
ecp_mod_p224k1_raw #19 - defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da":"37a7815aaa9c51982260fa8eda562d9800e3a81b02921c35042c0880"
|
||||
|
||||
ecp_mod_p224k1_raw #20 - defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da":"0000000037a7815aaa9c51982260fa8eda562d9800e3a81b02921c35042c0880"
|
||||
|
||||
ecp_mod_p224k1_raw #21 - 2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045":"0a66fcba3968b3bfdbe4cab383139d0ba5df05f1cf09225df471772c"
|
||||
|
||||
ecp_mod_p224k1_raw #22 - 2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000002d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045":"000000000a66fcba3968b3bfdbe4cab383139d0ba5df05f1cf09225df471772c"
|
||||
|
||||
ecp_mod_p224k1_raw #23 - 8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578":"beb929772c37d8c047821b7094aa8a8a83c147ee5a7e7de5d70b1eb1"
|
||||
|
||||
ecp_mod_p224k1_raw #24 - 8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000008f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578":"00000000beb929772c37d8c047821b7094aa8a8a83c147ee5a7e7de5d70b1eb1"
|
||||
|
||||
ecp_mod_p224k1_raw #25 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a":"01a34df36e9f5a0597063463439baecb2d2f79f2abab9e61bbc34b4a"
|
||||
|
||||
ecp_mod_p224k1_raw #26 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000097eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a":"0000000001a34df36e9f5a0597063463439baecb2d2f79f2abab9e61bbc34b4a"
|
||||
|
||||
ecp_mod_p224k1_raw #27 - a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"fb610c682255b71c4e6b0fe96e2cf085019ee18b76210be52153f632"
|
||||
|
||||
ecp_mod_p224k1_raw #28 - a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"0000000000000000a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"00000000fb610c682255b71c4e6b0fe96e2cf085019ee18b76210be52153f632"
|
||||
|
||||
ecp_mod_p224k1_raw #29 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473":"a1aad43a31cf9b44b9d22b34d25ae509fb0b0c4214c12a5aff08dd4c"
|
||||
|
||||
ecp_mod_p224k1_raw #30 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000074667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473":"00000000a1aad43a31cf9b44b9d22b34d25ae509fb0b0c4214c12a5aff08dd4c"
|
||||
|
||||
ecp_mod_p224k1_raw #31 - eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a"
|
||||
|
||||
ecp_mod_p224k1_raw #32 - eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000000000000000000000000000000000000000000000000000000000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"00000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a"
|
||||
|
||||
ecp_mod_p224k1_raw #33 - f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"00000000000000000000000000000000000000000000000000000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3":"f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3"
|
||||
|
||||
ecp_mod_p224k1_raw #34 - f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3 mod fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224K1_ENABLED:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224K1:"00000000fffffffffffffffffffffffffffffffffffffffffffffffeffffe56d":"000000000000000000000000000000000000000000000000000000000000000000000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3":"00000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3"
|
||||
|
||||
ecp_mod_p224_raw #1 - 0 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"00000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p224_raw #2 - 0 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p224_raw #3 - 1 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #4 - 1 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #5 - ffffffffffffffffffffffffffffffff000000000000000000000000 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffff000000000000000000000000":"ffffffffffffffffffffffffffffffff000000000000000000000000"
|
||||
|
||||
ecp_mod_p224_raw #6 - ffffffffffffffffffffffffffffffff000000000000000000000000 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffff000000000000000000000000":"00000000ffffffffffffffffffffffffffffffff000000000000000000000000"
|
||||
|
||||
ecp_mod_p224_raw #7 - ffffffffffffffffffffffffffffffff000000000000000000000002 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffff000000000000000000000002":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #8 - ffffffffffffffffffffffffffffffff000000000000000000000002 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffff000000000000000000000002":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #9 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000fffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p224_raw #10 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000fffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p224_raw #11 - fffffffffffffffffffffffffffffffe00000000000000000000000000000001000000000000000000000000000000000000000000000000 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"fffffffffffffffffffffffffffffffe00000000000000000000000000000001000000000000000000000000000000000000000000000000":"00000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #12 - fffffffffffffffffffffffffffffffe00000000000000000000000000000001000000000000000000000000000000000000000000000000 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000fffffffffffffffffffffffffffffffe00000000000000000000000000000001000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p224_raw #13 - 10000000070000000002000001000ffffffffffff9fffffffffe00000efff000070000000002000001003 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000010000000070000000002000001000ffffffffffff9fffffffffe00000efff000070000000002000001003":"00010000000010000000000000000000000000000000000000000002"
|
||||
|
||||
ecp_mod_p224_raw #14 - 10000000070000000002000001000ffffffffffff9fffffffffe00000efff000070000000002000001003 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000010000000070000000002000001000ffffffffffff9fffffffffe00000efff000070000000002000001003":"0000000000010000000010000000000000000000000000000000000000000002"
|
||||
|
||||
ecp_mod_p224_raw #15 - 100000000000000000000000000000000000000000000000000000000000dc0000000000000000001000000010000000100000003 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000100000000000000000000000000000000000000000000000000000000000dc0000000000000000001000000010000000100000003":"ffffffff000dc0010000000000000000000000000000000100000004"
|
||||
|
||||
ecp_mod_p224_raw #16 - 100000000000000000000000000000000000000000000000000000000000dc0000000000000000001000000010000000100000003 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000100000000000000000000000000000000000000000000000000000000000dc0000000000000000001000000010000000100000003":"00000000ffffffff000dc0010000000000000000000000000000000100000004"
|
||||
|
||||
ecp_mod_p224_raw #17 - da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"f78dcf6d71dc9a70c0b8b85448798e84ecc6de4e5b9e06e5c938433e"
|
||||
|
||||
ecp_mod_p224_raw #18 - da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"00000000f78dcf6d71dc9a70c0b8b85448798e84ecc6de4e5b9e06e5c938433e"
|
||||
|
||||
ecp_mod_p224_raw #19 - cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8":"354cdf1172123e33852ec80d19ec9d4ccd744e25b31d7b8cfd0905f4"
|
||||
|
||||
ecp_mod_p224_raw #20 - cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000cdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8":"00000000354cdf1172123e33852ec80d19ec9d4ccd744e25b31d7b8cfd0905f4"
|
||||
|
||||
ecp_mod_p224_raw #21 - defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da":"f0fe9846b590817e876a540d13e72caf9f28fefe6124a81fe2d6f6e2"
|
||||
|
||||
ecp_mod_p224_raw #22 - defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751da":"00000000f0fe9846b590817e876a540d13e72caf9f28fefe6124a81fe2d6f6e2"
|
||||
|
||||
ecp_mod_p224_raw #23 - 2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045":"ba73eac168a33be69b34f032fe83718b6744c0ece96620eb7078f1d2"
|
||||
|
||||
ecp_mod_p224_raw #24 - 2d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000002d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045":"00000000ba73eac168a33be69b34f032fe83718b6744c0ece96620eb7078f1d2"
|
||||
|
||||
ecp_mod_p224_raw #25 - 8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578":"93535ac56b2f5198ff01014333b25f701ab1db170bc00b9436540164"
|
||||
|
||||
ecp_mod_p224_raw #26 - 8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000008f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578":"0000000093535ac56b2f5198ff01014333b25f701ab1db170bc00b9436540164"
|
||||
|
||||
ecp_mod_p224_raw #27 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a":"e75f8b0a207baa6b20fc07de92870f6e64406a6b4c808a954acf13f2"
|
||||
|
||||
ecp_mod_p224_raw #28 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000097eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a":"00000000e75f8b0a207baa6b20fc07de92870f6e64406a6b4c808a954acf13f2"
|
||||
|
||||
ecp_mod_p224_raw #29 - a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"38af47df0a04dd7f70500d2cd65bdd8ced1b94c9257f6cf4a90709cc"
|
||||
|
||||
ecp_mod_p224_raw #30 - a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"0000000000000000a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"0000000038af47df0a04dd7f70500d2cd65bdd8ced1b94c9257f6cf4a90709cc"
|
||||
|
||||
ecp_mod_p224_raw #31 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473":"666b6998ddba02a3fa3edfc71a2d701c3d363d90891841665a706bfc"
|
||||
|
||||
ecp_mod_p224_raw #32 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000074667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473":"00000000666b6998ddba02a3fa3edfc71a2d701c3d363d90891841665a706bfc"
|
||||
|
||||
ecp_mod_p224_raw #33 - eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a"
|
||||
|
||||
ecp_mod_p224_raw #34 - eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"00000000eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a"
|
||||
|
||||
ecp_mod_p224_raw #35 - f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"ffffffffffffffffffffffffffffffff000000000000000000000001":"00000000000000000000000000000000000000000000000000000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3":"f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3"
|
||||
|
||||
ecp_mod_p224_raw #36 - f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3 mod ffffffffffffffffffffffffffffffff000000000000000000000001
|
||||
depends_on:MBEDTLS_ECP_DP_SECP224R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP224R1:"00000000ffffffffffffffffffffffffffffffff000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3":"00000000f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #1 - 0 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #2 - 1 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #3 - 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec":"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #4 - 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffee":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #5 - 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000012"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #6 - 3fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec0000000000000000000000000000000000000000000000000000000000000190 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"3fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffec0000000000000000000000000000000000000000000000000000000000000190":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #7 - 1019f0d64ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"1019f0d64ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"40480306cb475acd898bee5c819d4df896f0e1beea28ee5249cd25d1b47a552a"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #8 - 20948fa1feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"20948fa1feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e":"55fae440f62696cc5eda88470e3fefca933e8dd58f9e66bf79609027f8ad0cd1"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #9 - 3a1893ea5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"3a1893ea5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa":"065b82af5eb2c85de98852171c5ebea0c4acb089964afa2078a7fae950846007"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #10 - 20a6923522fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"20a6923522fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"06262d62c148698ac2c7ce4de19549b59973d7c8cc63b77e2fbf4a615a4ad8fd"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #11 - 3a248138e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"3a248138e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0":"202f2525a1e518048616f00894ed2c42456fac79468b221a4b3e61f07747ff85"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #12 - 2f450feab714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"2f450feab714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f":"60259ca2281e2fb68e83d5f50185662be1858b0eea2dff394db09e6a50abc89c"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #13 - 1d199effe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"1d199effe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"514ed15a79217aca6c53e0a7f06b12858191039f20d75e013d647e877e4d4ff3"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #14 - 3423c6ec531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"3423c6ec531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"4c0d46f841f7acec77f31472ff1c28eb636f4195f3bf456e408adef5672fc7c8"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #15 - 62f1243644a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"000000000000000000000000000000000000000000000000000000000000000062f1243644a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062":"62f1243644a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062"
|
||||
|
||||
mbedtls_ecp_mod_p255_raw #16 - 6a606e54b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9 mod 7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE25519_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE25519:"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed":"00000000000000000000000000000000000000000000000000000000000000006a606e54b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9":"6a606e54b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9"
|
||||
|
||||
ecp_mod_p256k1_raw #1 - 0 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p256k1_raw #2 - 1 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256k1_raw #3 - fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2e mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2e":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2e"
|
||||
|
||||
ecp_mod_p256k1_raw #4 - fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc30 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc30":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256k1_raw #5 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000001000003d0"
|
||||
|
||||
ecp_mod_p256k1_raw #6 - fffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffff85c000000000000000000000000000000000000000000000001000007a4000e9844 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffff85c000000000000000000000000000000000000000000000001000007a4000e9844":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256k1_raw #7 - fffffc2f000e90a0c86a0a63234e5ba641f43a7e4aecc4040e67ec85056200000000000000000000000000000000000000000000000000000000585674fd mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000fffffc2f000e90a0c86a0a63234e5ba641f43a7e4aecc4040e67ec85056200000000000000000000000000000000000000000000000000000000585674fd":"0000000000000000000000000000000000000000000000000001000003d0ffff"
|
||||
|
||||
ecp_mod_p256k1_raw #8 - fffffc2f000e90a0c86a0a63234e5ba641f43a7e4aecc4040e67ec85056200000000000000000000000000000000000000000000000000000000585674fd mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000fffffc2f000e90a0c86a0a63234e5ba641f43a7e4aecc4040e67ec85056200000000000000000000000000000000000000000000000000000000585674fd":"0000000000000000000000000000000000000000000000000001000003d0ffff"
|
||||
|
||||
ecp_mod_p256k1_raw #9 - 4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"7750cf34fcef7c7ff51f5859312e5174f0e1c93f28dae45e2516d8b6090e7185"
|
||||
|
||||
ecp_mod_p256k1_raw #10 - 82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e":"5a7ab21ef514584adcdcdf7bc486752e9d438281b9d1d069f03e873ebaac53fa"
|
||||
|
||||
ecp_mod_p256k1_raw #11 - e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa":"176e88ec572bfc18618c1d0f029a2f8f9af1fb7c3a94deb450a06338eb65a493"
|
||||
|
||||
ecp_mod_p256k1_raw #12 - 829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"bf3b04bb49963f8215fa3ebe5dfb6d1090375d296e865f4a77fdb010816c750d"
|
||||
|
||||
ecp_mod_p256k1_raw #13 - e89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"e89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0":"7c1f220c72feb2d2939bc98f997f974171adf69ee0f692a08cb8568e1ce6cc4d"
|
||||
|
||||
ecp_mod_p256k1_raw #14 - bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f":"2d40578b1550dc67c8538052f87fc338b96d51bab681eefe94be31782495deab"
|
||||
|
||||
ecp_mod_p256k1_raw #15 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"9ca2f78a21c22340198ffd3611f7599dfc14fe9171f6cdd9260c26a903a0da57"
|
||||
|
||||
ecp_mod_p256k1_raw #16 - d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"d403d7d40f91cb6fe9161acbef9a36d1917dd0ec558916b97df8768ef8d4437d"
|
||||
|
||||
ecp_mod_p256k1_raw #17 - c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000000000000000000000000000000000000000000000000000000000000000c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062":"c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062"
|
||||
|
||||
ecp_mod_p256k1_raw #18 - d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256K1_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256K1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f":"0000000000000000000000000000000000000000000000000000000000000000d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9":"d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9"
|
||||
|
||||
ecp_mod_p256_raw #1 - 0 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p256_raw #2 - 1 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256_raw #3 - ffffffff00000001000000000000000000000000fffffffffffffffffffffffe mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000ffffffff00000001000000000000000000000000fffffffffffffffffffffffe":"ffffffff00000001000000000000000000000000fffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p256_raw #4 - ffffffff00000001000000000000000000000001000000000000000000000000 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000ffffffff00000001000000000000000000000001000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256_raw #5 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000fffffffeffffffffffffffffffffffff000000000000000000000000"
|
||||
|
||||
ecp_mod_p256_raw #6 - fffffffe00000002fffffffe0000000100000001fffffffe00000001fffffffc00000003fffffffcfffffffffffffffffffffffc000000000000000000000004 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"fffffffe00000002fffffffe0000000100000001fffffffe00000001fffffffc00000003fffffffcfffffffffffffffffffffffc000000000000000000000004":"0000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p256_raw #7 - 1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffff mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffff":"fffffffe00000002000000020000000200000001fffffffefffffffffffffffd"
|
||||
|
||||
ecp_mod_p256_raw #8 - 10ffffffff00000000000000000000000000000000000000000000000000000000 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000010ffffffff00000000000000000000000000000000000000000000000000000000":"0000000fffffffeeffffffffffffffffffffffef000000000000000000000011"
|
||||
|
||||
ecp_mod_p256_raw #9 - aaaaaaaa0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000aaaaaaacaaaaaaaaaaaaaaaa00000000 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"aaaaaaaa0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000aaaaaaacaaaaaaaaaaaaaaaa00000000":"0000000155555552aaaaaaaa0000000000000000000000000000000000000002"
|
||||
|
||||
ecp_mod_p256_raw #10 - 1ffffffff000000000000000000000000000000000000000000000000000000000000000000000002000000020000000100000002 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"000000000000000000000001ffffffff000000000000000000000000000000000000000000000000000000000000000000000002000000020000000100000002":"fffffffe00000003000000040000000200000003000000000000000000000000"
|
||||
|
||||
ecp_mod_p256_raw #11 - 4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"e1ffcc745c985cf81f470a7681bb45cc6773ac0f1446cdb9af54308d51e8786b"
|
||||
|
||||
ecp_mod_p256_raw #12 - 82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e":"2d589c4ef3bb7cacb4078482b5e57a175f02953e709b7195283650834b1853d3"
|
||||
|
||||
ecp_mod_p256_raw #13 - e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa":"df475e8b1063fb3584dbf854a887cf88b5ee4c8fc70f1ff7a5c7f713c6f22cf7"
|
||||
|
||||
ecp_mod_p256_raw #14 - 829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"3ea7f2a4b2a2edc9183af0a467cbc10615a0e627459c333e885057f008db0488"
|
||||
|
||||
ecp_mod_p256_raw #15 - e89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"e89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0":"249aac0ae79cda5f1ef06e7bdbb3b10c16ed7ca2dea327ba86f9d7dd44b5ecb7"
|
||||
|
||||
ecp_mod_p256_raw #16 - bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769f":"c443605a9886908036e21b4fc50c548a43d4a2940d60f6a85d14eb5358bb0712"
|
||||
|
||||
ecp_mod_p256_raw #17 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"b8392b3f20d2ae5d31f39a400ea28be2bdaea69728abc77ea60fc578c8704352"
|
||||
|
||||
ecp_mod_p256_raw #18 - d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"6ae1a20b48b2622fecf4492f4626adae0ec91cb586cc8ba08b69750def1edb4e"
|
||||
|
||||
ecp_mod_p256_raw #19 - c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062":"c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062"
|
||||
|
||||
ecp_mod_p256_raw #20 - d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9 mod ffffffff00000001000000000000000000000000ffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP256R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP256R1:"ffffffff00000001000000000000000000000000ffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9":"d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9"
|
||||
|
||||
ecp_mod_p384_raw #1 0 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p384_raw #2 1 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p384_raw #3 fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000fffffffe mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000fffffffe":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000fffffffe"
|
||||
|
||||
ecp_mod_p384_raw #4 fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff000000000000000100000000 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff000000000000000100000000":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p384_raw #5 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000100000000ffffffffffffffff00000000"
|
||||
|
||||
ecp_mod_p384_raw #6 fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffffffe0000000000000001fffffffc000000000000000000000000000000010000000200000000fffffffe000000020000000400000000fffffffc00000004 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffffffe0000000000000001fffffffc000000000000000000000000000000010000000200000000fffffffe000000020000000400000000fffffffc00000004":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p384_raw #7 497811378624857a2c2af60d70583376545484cfae5c812fe2999fc1abb51d18b559e8ca3b50aaf263fdf8f24bdfb98fffffffff20e65bf9099e4e73a5e8b517cf4fbeb8fd1750fdae6d43f2e53f82d5ffffffffffffffffcc6f1e06111c62e0 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"497811378624857a2c2af60d70583376545484cfae5c812fe2999fc1abb51d18b559e8ca3b50aaf263fdf8f24bdfb98fffffffff20e65bf9099e4e73a5e8b517cf4fbeb8fd1750fdae6d43f2e53f82d5ffffffffffffffffcc6f1e06111c62e0":"880044027d90f165566731fc503b20991fced973d2996e12068c7cb9475aec4292cf8a39f49fcd2a43d1c0a3b00734bc"
|
||||
|
||||
ecp_mod_p384_raw #8 dfdd25e96777406b3c04b8c7b406f5fcf287e1e576003a092852a6fbe517f2712b68abef41dbd35183a0614fb7222606ffffffff84396eee542f18a9189d94396c784059c17a9f18f807214ef32f2f10ffffffff8a77fac20000000000000000 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"dfdd25e96777406b3c04b8c7b406f5fcf287e1e576003a092852a6fbe517f2712b68abef41dbd35183a0614fb7222606ffffffff84396eee542f18a9189d94396c784059c17a9f18f807214ef32f2f10ffffffff8a77fac20000000000000000":"1ef4bd60183412807a7fbc78e78741bed95dac81a39e3da5eb8e6a00bb6e590e49664715ec8bd9e65fcbab9ec750aee3"
|
||||
|
||||
ecp_mod_p384_raw #9 783753f8a5afba6c1862eead1deb2fcdd907272be3ffd18542b24a71ee8b26cab0aa33513610ff973042bbe1637cc9fc99ad36c7f703514572cf4f5c3044469a8f5be6312c19e5d3f8fc1ac6ffffffffffffffff8c86252400000000ffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"783753f8a5afba6c1862eead1deb2fcdd907272be3ffd18542b24a71ee8b26cab0aa33513610ff973042bbe1637cc9fc99ad36c7f703514572cf4f5c3044469a8f5be6312c19e5d3f8fc1ac6ffffffffffffffff8c86252400000000ffffffff":"6327274e415715b593f92a32a665c0799bcfe9ed4a41022d8f70b163d59298f9f67d0dccf228ce25ccc1d07c2193947e"
|
||||
|
||||
ecp_mod_p384_raw #10 65e1d2362fce922663b7fd517586e88842a9b4bd092e93e6251c9c69f278cbf8285d99ae3b53da5ba36e56701e2b17c225f1239556c5f00117fa140218b46ebd8e34f50d0018701fa8a0a5cc00000000000000004410bcb4ffffffff00000000 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"65e1d2362fce922663b7fd517586e88842a9b4bd092e93e6251c9c69f278cbf8285d99ae3b53da5ba36e56701e2b17c225f1239556c5f00117fa140218b46ebd8e34f50d0018701fa8a0a5cc00000000000000004410bcb4ffffffff00000000":"143500ea6eb4cd793476591b63270aeb48684dc1436e1238e33d9add2cb671614ec35892de201585a56cba8091882b66"
|
||||
|
||||
ecp_mod_p384_raw #11 ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000000000000000000000000ffffffff00000000000000000000000100000000000000000000000000000000ffffffff00000001 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000000000000000000000000ffffffff00000000000000000000000100000000000000000000000000000000ffffffff00000001":"000000000000000000000000000000000000000000000000000000000000000200000001fffffffeffffffff00000002"
|
||||
|
||||
ecp_mod_p384_raw #12 ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"44699b77db0b68ca1690c21932fa470ca5b14998326e460edb891e1009809c40910b74c8b879624c9fc5bc57e3747a94"
|
||||
|
||||
ecp_mod_p384_raw #13 e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"e8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57ebf30b94fa82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93":"5a9983e4527f4c09bccc32c4f50d2b53b0c5deb57463a2f3f1333673a2de21ac0d50e96c22b7426b74fe55685d50cc45"
|
||||
|
||||
ecp_mod_p384_raw #14 fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86f":"2da32f562881e81e7971824f444bc1d1b543520904c0b4873e350ebd02a25f60a3d8b8cc4a4997bec64c122cf1c0ef5f"
|
||||
|
||||
ecp_mod_p384_raw #15 bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2":"536bb25b389d786b9df83474f8396eba42fdc19da77f28e2ebbcf851583ef5c158b91e1ac12bf29e274a1357a9a2810d"
|
||||
|
||||
ecp_mod_p384_raw #16 8ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"8ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2":"5a194c71d677391409aab70f854939694cbfb65adb0f6142f384b5b3c678786dfdc88315954dd201df751a148d24821a"
|
||||
|
||||
ecp_mod_p384_raw #17 d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f25 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f25":"4320a17caf9599d4775c58dabea9f0c052e7a306905d89886fab3ef07c0452874a803d532b92d056beafb6058ea8ff44"
|
||||
|
||||
ecp_mod_p384_raw #18 227eeb7b9d7d01f5769da05d205bbfcc8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"0227eeb7b9d7d01f5769da05d205bbfcc8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346":"6045643273b3eacb359d72a1da71cf6b6e765f9c247644f8fa262631ae6dad80326260b8c0948e2554b3a9112b696f8b"
|
||||
|
||||
ecp_mod_p384_raw #19 d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd":"297caee1e9343871bccf79133b22154b091068e8832d5cc7e479b754d344856b50720251f17d96237c8f01986de70dc3"
|
||||
|
||||
ecp_mod_p384_raw #20 5c3747465cc36c270e8a35b10828d569c268a20eb78ac332e5e138e26c4454b90f756132e16dce72f18e859835e1f291 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005c3747465cc36c270e8a35b10828d569c268a20eb78ac332e5e138e26c4454b90f756132e16dce72f18e859835e1f291":"5c3747465cc36c270e8a35b10828d569c268a20eb78ac332e5e138e26c4454b90f756132e16dce72f18e859835e1f291"
|
||||
|
||||
ecp_mod_p384_raw #21 eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c006497 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP384R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP384R1:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c006497":"eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c006497"
|
||||
|
||||
ecp_mod_p448_raw #1 - 0 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p448_raw #2 - 1 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p448_raw #3 - fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffffffffffffffffffffffffffffffffffffffffffffffffffffe mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffffffffffffffffffffffffffffffffffffffffffffffffffffe":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffffffffffffffffffffffffffffffffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p448_raw #4 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000000000000000000000000000000000000000000000000 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p448_raw #5 - ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p448_raw #6 - fffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffffffffffffffffffffffffffffffffffffffffffffffffffffffd0000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000004 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"fffffffffffffffffffffffffffffffffffffffffffffffffffffffdfffffffffffffffffffffffffffffffffffffffffffffffffffffffd0000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000004":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p448_raw #7 - 74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff387c56473a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b":"10ac5599b9a5006cfc9e7f5fb3bced4e7b78a96eaabd8d05841d60381de1006bd3a1a6388c65295d7df3452e4467a935717cefdd6647eb5e"
|
||||
|
||||
ecp_mod_p448_raw #8 - 4da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"4da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6e06f291b2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a":"74836e8db7b6d342c8d428c224f6c8beb3bc39e513219cc51d6cdad721ae6b3ae9824d5d36aa9dd618e0b9c9eefe4d83fc6a5a6cd73906c4"
|
||||
|
||||
ecp_mod_p448_raw #9 - bc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332e5e138e26c4454b9 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"bc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332e5e138e26c4454b9":"9b1f044050d649e19ff2aec05721191887c9a624c02fb0e90f9c12361e482d1921ee73abb27fc1179d1761d2debe6944389b9dd9c025d201"
|
||||
|
||||
ecp_mod_p448_raw #10 - 8d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec0b0c995e96e6bc4d62b47204007ee4fab105d83e85e951862f0981ae mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"8d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec0b0c995e96e6bc4d62b47204007ee4fab105d83e85e951862f0981ae":"3866bd37ae66a82a547e0848d73e8b28d730cf7f9a573404b5dd92bab5310508c92987076fb8a376a916bff9cba59f3fcc7c2353d0601ad7"
|
||||
|
||||
ecp_mod_p448_raw #11 - 84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e32748dd1db4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b14 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e32748dd1db4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b14":"18ef8ecc90f603615daee5e0246b96bcdbf74d7cd9febb1aad00859b60415d1c3ad96b9f2a9a85da9ba15cfe306e651e257c87aa040500bd"
|
||||
|
||||
ecp_mod_p448_raw #12 - 2bb3b36f29421c4021b7379f0897246a40c270b00e893302aba9e7b823fc5ad2f58105748ed5d1b7b310b730049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f3860895bfa813 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"2bb3b36f29421c4021b7379f0897246a40c270b00e893302aba9e7b823fc5ad2f58105748ed5d1b7b310b730049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f3860895bfa813":"73e27a51e32d2a66154c0782069324a5dd71d380ba02f824a2a46c717482102872b85f1d34572567384ec2a0a9f8cda37dbc59bdacdea938"
|
||||
|
||||
ecp_mod_p448_raw #13 - af3f5d7841b1256d5c1dc12fb5a1ae519fb8883accda6559caa538a09fc9370d3a6b86a7975b54a31497024640332b0612d4050771d7b14eb6c004cc3b8367dc3f2bb31efe9934ad0809eae3ef232a32b5459d83fbc46f1aea990e94821d46063b4dbf2ca294523d74115c86188b1044 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"af3f5d7841b1256d5c1dc12fb5a1ae519fb8883accda6559caa538a09fc9370d3a6b86a7975b54a31497024640332b0612d4050771d7b14eb6c004cc3b8367dc3f2bb31efe9934ad0809eae3ef232a32b5459d83fbc46f1aea990e94821d46063b4dbf2ca294523d74115c86188b1044":"b507f6c9f951395e8ec28a217e73939687ae265f9babf9edbc67c0154acd03a066b5baa975965bd905866fc48280057e53bfc6e75507fa34"
|
||||
|
||||
ecp_mod_p448_raw #14 - 7430051376e31f5aab63ad02854efa600641b4fa37a47ce41aeffafc3b45402ac02659fe2e87d4150511baeb198ababb1a16daff3da95cd2167b75dfb948f82a8317cba01c75f67e290535d868a24b7f627f285509167d4126af8090013c3273c02c6b9586b4625b475b51096c4ad652 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"7430051376e31f5aab63ad02854efa600641b4fa37a47ce41aeffafc3b45402ac02659fe2e87d4150511baeb198ababb1a16daff3da95cd2167b75dfb948f82a8317cba01c75f67e290535d868a24b7f627f285509167d4126af8090013c3273c02c6b9586b4625b475b51096c4ad652":"3a20c031673590de0866f9ba2c25a6294f135a87f2022046d6087b20b88bc27f5db8f9e8db27b38b4a8d20e0a680d2109916a8ecc4e42e21"
|
||||
|
||||
ecp_mod_p448_raw #15 - f4ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccd0b519a16df59c53e0d49b209200f878f362ace518d5b8bfcf9cdc725e5e01c06295e8605af06932b5006d9e556d3f190e8136bf9c643d332 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"f4ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccd0b519a16df59c53e0d49b209200f878f362ace518d5b8bfcf9cdc725e5e01c06295e8605af06932b5006d9e556d3f190e8136bf9c643d332":"0ece49e2f747b4bc43afbacb8fe99e8b7301401d8a9108093fee65a9f4ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238db"
|
||||
|
||||
ecp_mod_p448_raw #16 - 8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578 mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578":"8f54f8ceacaab39e83844b40ffa9b9f15c14bc4a829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c729578"
|
||||
|
||||
ecp_mod_p448_raw #17 - 97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a mod fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_CURVE448_ENABLED
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_CURVE448:"fffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000097eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a":"97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a"
|
||||
|
||||
ecp_mod_p521_raw #1 0 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p521_raw #2 0 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
|
||||
|
||||
ecp_mod_p521_raw #3 1 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #4 1 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #5 1fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe":"000001fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p521_raw #6 1fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe":"00000000000001fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe"
|
||||
|
||||
ecp_mod_p521_raw #7 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #8 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #9 3fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000003fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #10 3fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000003fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001"
|
||||
|
||||
ecp_mod_p521_raw #11 1efffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000001ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f000000 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000001efffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000001ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f000000":"000000e70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e800001"
|
||||
|
||||
ecp_mod_p521_raw #12 1efffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000001ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f000000 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000001efffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000001ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f000000":"00000000000000e70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e800001"
|
||||
|
||||
ecp_mod_p521_raw #13 3cc2e82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000003cc2e82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"0000001457a8ec7792615e3836830063384fff38bc7f01a3a61ae6b8501ac9b29d9a6153266e3a00304e71c0d8494ce649448b84816042bb2cf27e29c58fe596638c3908"
|
||||
|
||||
ecp_mod_p521_raw #14 3cc2e82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000003cc2e82523e86feac7eb7dc38f519b91751dacdbd47d364be8049a372db8f6e405d93ffed9235288bc781ae66267594c9c9500925e4749b575bd13653f8dd9b1f282e4067c3584ee207f8da94e3e8ab73738fcf1822ffbc6887782b491044d5e341245c6e433715ba2bdd177219d30e7a269fd95bafc8f2a4d27bdcf4bb99f4bea973":"000000000000001457a8ec7792615e3836830063384fff38bc7f01a3a61ae6b8501ac9b29d9a6153266e3a00304e71c0d8494ce649448b84816042bb2cf27e29c58fe596638c3908"
|
||||
|
||||
ecp_mod_p521_raw #15 17052829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57eb mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000017052829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57eb":"0000015e8a89f773c0a39ccfbb986d7fbfa3b711862ce6e8f7c6ab7bae09ae0df71988ad7ad08f71a2cc442404732b9c3c9c896458a542b0d7fbf619a54155e989f590cd"
|
||||
|
||||
ecp_mod_p521_raw #16 17052829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57eb mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000017052829e07b0829a48d422fe99a22c70501e533c91352d3d854e061b90303b08c6e33c7295782d6c797f8f7d9b782a1be9cd8697bbd0e2520e33e44c50556c71c4a66148a86fe8624fab5186ee32ee8d7ee9770348a05d300cb90706a045defc044a09325626e6b58de744ab6cce80877b6f71e1f6d2ef8acd128b4f2fc15f3f57eb":"000000000000015e8a89f773c0a39ccfbb986d7fbfa3b711862ce6e8f7c6ab7bae09ae0df71988ad7ad08f71a2cc442404732b9c3c9c896458a542b0d7fbf619a54155e989f590cd"
|
||||
|
||||
ecp_mod_p521_raw #17 21f15a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f1 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000021f15a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f1":"000001cbe813ada3338785ffd1f08f02bcf20f720cb18ccfd6e2430303a21c1f5f0d16f74b4e5d6c02bc3a44e731e953140adc2e7f034b19a9d7fc82d1504296b20ed064"
|
||||
|
||||
ecp_mod_p521_raw #18 21f15a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f1 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000021f15a7a83ee0761ebfd2bd143fa9b714210c665d7435c1066932f4767f26294365b2721dea3bf63f23d0dbe53fcafb2147df5ca495fa5a91c89b97eeab64ca2ce6bc5d3fd983c34c769fe89204e2e8168561867e5e15bc01bfce6a27e0dfcbf8754472154e76e4c11ab2fec3f6b32e8d4b8a8f54f8ceacaab39e83844b40ffa9b9f1":"00000000000001cbe813ada3338785ffd1f08f02bcf20f720cb18ccfd6e2430303a21c1f5f0d16f74b4e5d6c02bc3a44e731e953140adc2e7f034b19a9d7fc82d1504296b20ed064"
|
||||
|
||||
ecp_mod_p521_raw #19 381bc2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff3 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000381bc2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff3":"00000072541a267a63a177e90dac52aaa5cec38dbb2c134fd9dc9fa0d2b72b2c68292a3d5e9d131ff22b2e92d513c3511248963edeb798c68bd02852e2ba380281267624"
|
||||
|
||||
ecp_mod_p521_raw #20 381bc2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff3 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000381bc2a838af8d5c44a4eb3172062d08f1bb2531d6460f0caeef038c89b38a8acb5137c9260dc74e088a9b9492f258ebdbfe3eb9ac688b9d39cca91551e8259cc60b17604e4b4e73695c3e652c71a74667bffe202849da9643a295a9ac6decbd4d3e2d4dec9ef83f0be4e80371eb97f81375eecc1cb6347733e847d718d733ff98ff3":"0000000000000072541a267a63a177e90dac52aaa5cec38dbb2c134fd9dc9fa0d2b72b2c68292a3d5e9d131ff22b2e92d513c3511248963edeb798c68bd02852e2ba380281267624"
|
||||
|
||||
ecp_mod_p521_raw #21 34816c8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000034816c8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6":"000001c08d468427b914c3ddf9dc80f22d663a6d451871913fc179b47dcb278de8572dcdcae36f67e95a2143352f83771f77f94d95165633f0efeabc5917ae16a2c22b52"
|
||||
|
||||
ecp_mod_p521_raw #22 34816c8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000034816c8c69069134bccd3e1cf4f589f8e4ce0af29d115ef24bd625dd961e6830b54fa7d28f93435339774bb1e386c4fd5079e681b8f5896838b769da59b74a6c3181c81e220df848b1df78feb994a81167346d4c0dca8b4c9e755cc9c3adcf515a8234da4daeb4f3f87777ad1f45ae9500ec9c5e2486c44a4a8f69dc8db48e86ec9c6":"00000000000001c08d468427b914c3ddf9dc80f22d663a6d451871913fc179b47dcb278de8572dcdcae36f67e95a2143352f83771f77f94d95165633f0efeabc5917ae16a2c22b52"
|
||||
|
||||
ecp_mod_p521_raw #23 397846c4454b90f756132e16dce72f18e859835e1f291d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd0227eeb7b9d7d01f5769da05 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000397846c4454b90f756132e16dce72f18e859835e1f291d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd0227eeb7b9d7d01f5769da05":"000000f7fc39ac9af40166cfdf5a941945fe272273400be9dbf66d26a9aa294f9a4f20b8669762a92c515bfe49c2a1b680884c35576996fcab9d28fe96c7e03794c13573"
|
||||
|
||||
ecp_mod_p521_raw #24 397846c4454b90f756132e16dce72f18e859835e1f291d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd0227eeb7b9d7d01f5769da05 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000397846c4454b90f756132e16dce72f18e859835e1f291d322a7353ead4efe440e2b4fda9c025a22f1a83185b98f5fc11e60de1b343f52ea748db9e020307aaeb6db2c3a038a709779ac1f45e9dd320c855fdfa7251af0930cdbd30f0ad2a81b2d19a2beaa14a7ff3fe32a30ffc4eed0a7bd04e85bfcdd0227eeb7b9d7d01f5769da05":"00000000000000f7fc39ac9af40166cfdf5a941945fe272273400be9dbf66d26a9aa294f9a4f20b8669762a92c515bfe49c2a1b680884c35576996fcab9d28fe96c7e03794c13573"
|
||||
|
||||
ecp_mod_p521_raw #25 2c3296e6bc4d62b47204007ee4fab105d83e85e951862f0981aebc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000002c3296e6bc4d62b47204007ee4fab105d83e85e951862f0981aebc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332":"000001d123c234f42d2e58041345bd0f71b6b28c3cc2371dd850a940dd5e64a018ce7799f3572583256880967347a29a7fe4269abbb9f757dbab8a49cede37ba016820f1"
|
||||
|
||||
ecp_mod_p521_raw #26 2c3296e6bc4d62b47204007ee4fab105d83e85e951862f0981aebc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000002c3296e6bc4d62b47204007ee4fab105d83e85e951862f0981aebc1b00d92838e766ef9b6bf2d037fe2e20b6a8464174e75a5f834da70569c018eb2b5693babb7fbb0a76c196067cfdcb11457d9cf45e2fa01d7f4275153924800600571fac3a5b263fdf57cd2c0064975c3747465cc36c270e8a35b10828d569c268a20eb78ac332":"00000000000001d123c234f42d2e58041345bd0f71b6b28c3cc2371dd850a940dd5e64a018ce7799f3572583256880967347a29a7fe4269abbb9f757dbab8a49cede37ba016820f1"
|
||||
|
||||
ecp_mod_p521_raw #27 9d23b4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b148d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000009d23b4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b148d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec":"000001a5e82ded1c29889b12f5637dcb469b4a0849f28ef53d566b720ef3cb0f77c50950917c4515816074ced9aaf81882ce127865fce5399219105500f4af76ff8c7ea4"
|
||||
|
||||
ecp_mod_p521_raw #28 9d23b4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b148d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000009d23b4917fc09f20dbb0dcc93f0e66dfe717c17313394391b6e2e6eacb0f0bb7be72bd6d25009aeb7fa0c4169b148d2f527e72daf0a54ef25c0707e338687d1f71575653a45c49390aa51cf5192bbf67da14be11d56ba0b4a2969d8055a9f03f2d71581d8e830112ff0f0948eccaf8877acf26c377c13f719726fd70bddacb4deeec":"00000000000001a5e82ded1c29889b12f5637dcb469b4a0849f28ef53d566b720ef3cb0f77c50950917c4515816074ced9aaf81882ce127865fce5399219105500f4af76ff8c7ea4"
|
||||
|
||||
ecp_mod_p521_raw #29 12b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3":"0000012b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3"
|
||||
|
||||
ecp_mod_p521_raw #30 12b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3":"000000000000012b84ae65e920a63ac1f2b64df6dff07870c9d531ae72a47403063238da1a1fe3f9d6a179fa50f96cd4aff9261aa92c0e6f17ec940639bc2ccdf572df00790813e3"
|
||||
|
||||
ecp_mod_p521_raw #31 166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT32
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608":"00000166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608"
|
||||
|
||||
ecp_mod_p521_raw #32 166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608 mod 1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
||||
depends_on:MBEDTLS_ECP_DP_SECP521R1_ENABLED:MBEDTLS_ECP_NIST_OPTIM:MBEDTLS_HAVE_INT64
|
||||
ecp_mod_p_generic_raw:MBEDTLS_ECP_DP_SECP521R1:"00000000000001ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":"0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608":"0000000000000166049dd332a73fa0b26b75196cf87eb8a09b27ec714307c68c425424a1574f1eedf5b0f16cdfdb839424d201e653f53d6883ca1c107ca6e706649889c0c7f38608"
|
||||
|
||||
# End of automatically generated file.
|
||||
@ -1546,6 +1546,14 @@ void pk_rsa_decrypt_test_vec(data_t *cipher, int mod, int padding, int md_alg,
|
||||
if (ret == 0) {
|
||||
TEST_ASSERT(olen == clear->len);
|
||||
TEST_ASSERT(memcmp(output, clear->x, olen) == 0);
|
||||
|
||||
if (clear->len != 0) {
|
||||
/* Try again with an output buffer that's too small */
|
||||
TEST_EQUAL(mbedtls_pk_decrypt(&pk, cipher->x, cipher->len,
|
||||
output, &olen, clear->len - 1,
|
||||
mbedtls_test_rnd_pseudo_rand, &rnd_info),
|
||||
MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE);
|
||||
}
|
||||
}
|
||||
|
||||
exit:
|
||||
@ -1618,6 +1626,14 @@ void pk_wrap_rsa_decrypt_test_vec(data_t *cipher, int mod,
|
||||
if (ret == 0) {
|
||||
TEST_EQUAL(olen, clear->len);
|
||||
TEST_EQUAL(memcmp(output, clear->x, olen), 0);
|
||||
|
||||
if (clear->len != 0) {
|
||||
/* Try again with an output buffer that's too small */
|
||||
TEST_EQUAL(mbedtls_pk_decrypt(&pk, cipher->x, cipher->len,
|
||||
output, &olen, clear->len - 1,
|
||||
mbedtls_test_rnd_pseudo_rand, &rnd_info),
|
||||
MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE);
|
||||
}
|
||||
}
|
||||
|
||||
TEST_EQUAL(PSA_SUCCESS, psa_destroy_key(key_id));
|
||||
@ -1789,6 +1805,13 @@ void pk_rsa_alt()
|
||||
TEST_ASSERT(test_len == sizeof(msg));
|
||||
TEST_ASSERT(memcmp(test, msg, test_len) == 0);
|
||||
|
||||
|
||||
/* Try again with an output buffer that's too small */
|
||||
TEST_EQUAL(mbedtls_pk_decrypt(&alt, ciph, ciph_len,
|
||||
test, &test_len, sizeof(msg) - 1,
|
||||
mbedtls_test_rnd_std_rand, NULL),
|
||||
MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE);
|
||||
|
||||
/* Test forbidden operations */
|
||||
TEST_ASSERT(mbedtls_pk_encrypt(&alt, msg, sizeof(msg),
|
||||
ciph, &ciph_len, sizeof(ciph),
|
||||
|
||||
53
tests/suites/test_suite_pkcs1_v15.constant_time.data
Normal file
53
tests/suites/test_suite_pkcs1_v15.constant_time.data
Normal file
@ -0,0 +1,53 @@
|
||||
RSA sensitive ret: 0
|
||||
rsa_decrypt_decompose_ret:0:0:0
|
||||
|
||||
RSA sensitive ret: sensitive 1
|
||||
rsa_decrypt_decompose_ret:-1:0:-11
|
||||
|
||||
RSA sensitive ret: sensitive 2
|
||||
rsa_decrypt_decompose_ret:-2:0:-12
|
||||
|
||||
RSA sensitive ret: public
|
||||
rsa_decrypt_decompose_ret:-3:-3:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max, tight output buffer
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:117:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max, larger output buffer
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:128:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max-1, tight output buffer
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:116:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max-1, larger output buffer
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:117:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=1
|
||||
pkcs1_v15_decode:"00025050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505000":1:1:0
|
||||
|
||||
RSAES-V15 decoding: good, empty payload
|
||||
pkcs1_v15_decode:"0002505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505000":0:0:0
|
||||
|
||||
RSAES-V15 decoding: payload=max, output too large
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:116:MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
|
||||
RSAES-V15 decoding: payload=max-1, output too large
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:115:MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
|
||||
RSAES-V15 decoding: bad first byte
|
||||
pkcs1_v15_decode:"0102505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: bad second byte (0 instead of 2)
|
||||
pkcs1_v15_decode:"0000505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: bad second byte (1 instead of 2)
|
||||
pkcs1_v15_decode:"0001505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: padding too short (0)
|
||||
pkcs1_v15_decode:"000200":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: padding too short (7)
|
||||
pkcs1_v15_decode:"0002505050505050500000ffffffffffffffffff00":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: unfinished padding
|
||||
pkcs1_v15_decode:"0002505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
@ -51,45 +51,3 @@ pkcs1_rsassa_v15_sign:1024:"d17f655bf27c8b16d35462c905cc04a26f37e2a67fa9c0ce0dce
|
||||
RSASSA-V15 Verification Test Vector Int
|
||||
depends_on:MBEDTLS_MD_CAN_SHA1
|
||||
pkcs1_rsassa_v15_verify:1024:"a2ba40ee07e3b2bd2f02ce227f36a195024486e49c19cb41bbbdfbba98b22b0e577c2eeaffa20d883a76e65e394c69d4b3c05a1e8fadda27edb2a42bc000fe888b9b32c22d15add0cd76b3e7936e19955b220dd17d4ea904b1ec102b2e4de7751222aa99151024c7cb41cc5ea21d00eeb41f7c800834d2c6e06bce3bce7ea9a5":"010001":MBEDTLS_MD_SHA1:MBEDTLS_MD_SHA1:"37b66ae0445843353d47ecb0b4fd14c110e62d6a":"e3b5d5d002c1bce50c2b65ef88a188d83bce7e61":"2154f928615e5101fcdeb57bc08fc2f35c3d5996403861ae3efb1d0712f8bb05cc21f7f5f11f62e5b6ea9f0f2b62180e5cbe7ba535032d6ac8068fff7f362f73d2c3bf5eca6062a1723d7cfd5abb6dcf7e405f2dc560ffe6fc37d38bee4dc9e24fe2bece3e3b4a3f032701d3f0947b42930083dd4ad241b3309b514595482d42":0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max, tight output buffer
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:117:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max, larger output buffer
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:128:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max-1, tight output buffer
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:116:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=max-1, larger output buffer
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:117:0
|
||||
|
||||
RSAES-V15 decoding: good, payload=1
|
||||
pkcs1_v15_decode:"00025050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505000":1:1:0
|
||||
|
||||
RSAES-V15 decoding: good, empty payload
|
||||
pkcs1_v15_decode:"0002505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505000":0:0:0
|
||||
|
||||
RSAES-V15 decoding: payload=max, output too large
|
||||
pkcs1_v15_decode:"0002505152535455565700":117:116:MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
|
||||
RSAES-V15 decoding: payload=max-1, output too large
|
||||
pkcs1_v15_decode:"000250515253545556575800":116:115:MBEDTLS_ERR_RSA_OUTPUT_TOO_LARGE
|
||||
|
||||
RSAES-V15 decoding: bad first byte
|
||||
pkcs1_v15_decode:"0102505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: bad second byte (0 instead of 2)
|
||||
pkcs1_v15_decode:"0000505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: bad second byte (1 instead of 2)
|
||||
pkcs1_v15_decode:"0001505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: padding too short (0)
|
||||
pkcs1_v15_decode:"000200":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: padding too short (7)
|
||||
pkcs1_v15_decode:"0002505050505050500000ffffffffffffffffff00":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
RSAES-V15 decoding: unfinished padding
|
||||
pkcs1_v15_decode:"0002505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050505050":0:42:MBEDTLS_ERR_RSA_INVALID_PADDING
|
||||
|
||||
@ -1,6 +1,39 @@
|
||||
/* BEGIN_HEADER */
|
||||
#include "mbedtls/rsa.h"
|
||||
#include "mbedtls/md.h"
|
||||
#include "rsa_internal.h"
|
||||
#include <test/constant_flow.h>
|
||||
|
||||
#if defined(MBEDTLS_TEST_HOOKS) && !defined(MBEDTLS_RSA_ALT)
|
||||
static void pkcs1_v15_decode_raw(const unsigned char *input,
|
||||
size_t input_size,
|
||||
size_t output_size,
|
||||
int expected_result,
|
||||
size_t expected_plaintext_length)
|
||||
{
|
||||
unsigned char *input_buf = NULL;
|
||||
unsigned char *output_buf = NULL;
|
||||
size_t olen = 0;
|
||||
|
||||
TEST_CALLOC(output_buf, output_size);
|
||||
|
||||
TEST_CALLOC(input_buf, input_size);
|
||||
memcpy(input_buf, input, input_size);
|
||||
|
||||
TEST_CF_SECRET(input_buf, input_size);
|
||||
TEST_EQUAL(expected_result,
|
||||
mbedtls_ct_rsaes_pkcs1_v15_unpadding(
|
||||
input_buf, input_size,
|
||||
output_buf, output_size, &olen));
|
||||
if (expected_result == 0) {
|
||||
TEST_EQUAL(expected_plaintext_length, olen);
|
||||
}
|
||||
|
||||
exit:
|
||||
mbedtls_free(input_buf);
|
||||
mbedtls_free(output_buf);
|
||||
}
|
||||
#endif /* MBEDTLS_TEST_HOOKS && !MBEDTLS_RSA_ALT */
|
||||
/* END_HEADER */
|
||||
|
||||
/* BEGIN_DEPENDENCIES
|
||||
@ -124,6 +157,47 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void rsa_decrypt_decompose_ret(int input,
|
||||
int expected_ret, int expected_problem)
|
||||
{
|
||||
const int sensitive_in_1 = -1;
|
||||
const int sensitive_in_2 = -2;
|
||||
const int problem_1 = -11;
|
||||
const int problem_2 = -12;
|
||||
|
||||
int combined_ret = input;
|
||||
TEST_CF_SECRET(&combined_ret, sizeof(combined_ret));
|
||||
int actual_problem = 42;
|
||||
TEST_CF_SECRET(&actual_problem, sizeof(actual_problem));
|
||||
|
||||
int actual_ret = mbedtls_rsa_decrypt_decompose_ret(sensitive_in_1, problem_1,
|
||||
sensitive_in_2, problem_2,
|
||||
combined_ret,
|
||||
&actual_problem);
|
||||
|
||||
TEST_EQUAL(actual_problem, expected_problem);
|
||||
TEST_EQUAL(actual_ret, expected_ret);
|
||||
|
||||
/* Check invariant when there's no translation, only separation */
|
||||
actual_ret = mbedtls_rsa_decrypt_decompose_ret(sensitive_in_1, sensitive_in_1,
|
||||
sensitive_in_2, sensitive_in_2,
|
||||
combined_ret,
|
||||
&actual_problem);
|
||||
TEST_EQUAL(actual_ret, expected_ret);
|
||||
if (expected_problem == problem_1) {
|
||||
TEST_EQUAL(actual_problem, sensitive_in_1);
|
||||
} else if (expected_problem == problem_2) {
|
||||
TEST_EQUAL(actual_problem, sensitive_in_2);
|
||||
} else {
|
||||
TEST_EQUAL(actual_problem, 0);
|
||||
}
|
||||
TEST_CF_PUBLIC(&actual_problem, sizeof(actual_problem));
|
||||
TEST_CF_PUBLIC(&combined_ret, sizeof(combined_ret));
|
||||
TEST_EQUAL(actual_problem | actual_ret, combined_ret);
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void pkcs1_v15_decode(data_t *input,
|
||||
int expected_plaintext_length_arg,
|
||||
@ -257,6 +331,11 @@ void pkcs1_v15_decode(data_t *input,
|
||||
TEST_ASSERT(count < 16);
|
||||
}
|
||||
|
||||
#if defined(MBEDTLS_TEST_HOOKS) && !defined(MBEDTLS_RSA_ALT)
|
||||
pkcs1_v15_decode_raw(original, sizeof(original), output_size,
|
||||
expected_result, expected_plaintext_length);
|
||||
#endif
|
||||
|
||||
exit:
|
||||
mbedtls_mpi_free(&Nmpi); mbedtls_mpi_free(&Empi);
|
||||
mbedtls_mpi_free(&Pmpi); mbedtls_mpi_free(&Qmpi);
|
||||
@ -264,6 +343,7 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void pkcs1_rsassa_v15_sign(int mod, char *input_P,
|
||||
char *input_Q, char *input_N,
|
||||
|
||||
@ -14,6 +14,14 @@ PKCS7 Signed Data Parse with zero signers
|
||||
depends_on:MBEDTLS_MD_CAN_SHA256
|
||||
pkcs7_parse:"../framework/data_files/pkcs7_data_no_signers.der":MBEDTLS_PKCS7_SIGNED_DATA
|
||||
|
||||
PKCS7 Signed Data Parse reused object after multiple signers
|
||||
depends_on:MBEDTLS_MD_CAN_SHA256:MBEDTLS_RSA_C
|
||||
pkcs7_parse_reuse:"../framework/data_files/pkcs7_data_multiple_signed.der":"../framework/data_files/pkcs7_data_no_signers.der":MBEDTLS_PKCS7_SIGNED_DATA
|
||||
|
||||
PKCS7 Signed Data Parse reused object from multiple signers to one signer
|
||||
depends_on:MBEDTLS_MD_CAN_SHA256:MBEDTLS_RSA_C
|
||||
pkcs7_parse_reuse:"../framework/data_files/pkcs7_data_multiple_signed.der":"../framework/data_files/pkcs7_data_cert_signed_sha256.der":MBEDTLS_PKCS7_SIGNED_DATA
|
||||
|
||||
PKCS7 Signed Data Parse Fail with multiple certs #4
|
||||
depends_on:MBEDTLS_MD_CAN_SHA256:MBEDTLS_RSA_C
|
||||
pkcs7_parse:"../framework/data_files/pkcs7_data_multiple_certs_signed.der":MBEDTLS_ERR_PKCS7_FEATURE_UNAVAILABLE
|
||||
@ -86,10 +94,30 @@ PKCS7 Signed Data Verification Pass SHA256 #9.1
|
||||
depends_on:MBEDTLS_MD_CAN_SHA256
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_sha256.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":MBEDTLS_MD_SHA256:0
|
||||
|
||||
PKCS7 Signed Data Verification Fail SHA1 #10
|
||||
depends_on:MBEDTLS_MD_CAN_SHA1:MBEDTLS_MD_CAN_SHA256:!MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_sha1.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:MBEDTLS_ERR_PKCS7_INVALID_ALG
|
||||
|
||||
PKCS7 Signed Data Verification Pass SHA1 #10
|
||||
depends_on:MBEDTLS_MD_CAN_SHA1:MBEDTLS_MD_CAN_SHA256
|
||||
depends_on:MBEDTLS_MD_CAN_SHA1:MBEDTLS_MD_CAN_SHA256:MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_sha1.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:0
|
||||
|
||||
PKCS7 Signed Data Verification Fail MD5 #10.1
|
||||
depends_on:MBEDTLS_MD_CAN_MD5:MBEDTLS_MD_CAN_SHA256:!MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_md5.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:MBEDTLS_ERR_PKCS7_INVALID_ALG
|
||||
|
||||
PKCS7 Signed Data Verification Pass MD5 #10.1
|
||||
depends_on:MBEDTLS_MD_CAN_MD5:MBEDTLS_MD_CAN_SHA256:MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_md5.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:0
|
||||
|
||||
PKCS7 Signed Data Verification Fail RIPEMD160 #10.2
|
||||
depends_on:MBEDTLS_MD_CAN_RIPEMD160:MBEDTLS_MD_CAN_SHA256:!MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_ripemd160.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:MBEDTLS_ERR_PKCS7_INVALID_ALG
|
||||
|
||||
PKCS7 Signed Data Verification Pass RIPEMD160 #10.2
|
||||
depends_on:MBEDTLS_MD_CAN_RIPEMD160:MBEDTLS_MD_CAN_SHA256:MBEDTLS_PKCS7_ALLOW_WEAK_SIGNATURES
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_ripemd160.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:0
|
||||
|
||||
PKCS7 Signed Data Verification Pass SHA512 #11
|
||||
depends_on:MBEDTLS_MD_CAN_SHA512:MBEDTLS_MD_CAN_SHA256
|
||||
pkcs7_verify:"../framework/data_files/pkcs7_data_cert_signed_sha512.der":"../framework/data_files/pkcs7-rsa-sha256-1.der":"../framework/data_files/pkcs7_data.bin":0:0
|
||||
|
||||
@ -25,8 +25,10 @@ static int pkcs7_parse_buffer(unsigned char *pkcs7_buf, int buflen)
|
||||
mbedtls_pkcs7_init(&pkcs7);
|
||||
res = mbedtls_pkcs7_parse_der(&pkcs7, pkcs7_buf, buflen);
|
||||
mbedtls_pkcs7_free(&pkcs7);
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/* END_SUITE_HELPERS */
|
||||
|
||||
/* BEGIN_CASE */
|
||||
@ -57,6 +59,48 @@ exit:
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_FS_IO */
|
||||
void pkcs7_parse_reuse(char *first_pkcs7_file, char *second_pkcs7_file,
|
||||
int res_expect)
|
||||
{
|
||||
unsigned char *first_pkcs7_buf = NULL;
|
||||
unsigned char *second_pkcs7_buf = NULL;
|
||||
mbedtls_pkcs7 pkcs7;
|
||||
size_t first_buflen;
|
||||
size_t second_buflen;
|
||||
|
||||
mbedtls_pkcs7_init(&pkcs7);
|
||||
|
||||
/* PKCS7 uses X509 which itself relies on PK under the hood and the latter
|
||||
* can use PSA to store keys and perform operations so psa_crypto_init()
|
||||
* must be called before. */
|
||||
USE_PSA_INIT();
|
||||
|
||||
TEST_EQUAL(mbedtls_pk_load_file(first_pkcs7_file, &first_pkcs7_buf,
|
||||
&first_buflen), 0);
|
||||
|
||||
TEST_EQUAL(mbedtls_pk_load_file(second_pkcs7_file, &second_pkcs7_buf,
|
||||
&second_buflen), 0);
|
||||
|
||||
TEST_EQUAL(mbedtls_pkcs7_parse_der(&pkcs7, first_pkcs7_buf,
|
||||
first_buflen),
|
||||
MBEDTLS_PKCS7_SIGNED_DATA);
|
||||
|
||||
mbedtls_pkcs7_free(&pkcs7);
|
||||
TEST_ASSERT(pkcs7.raw.p == NULL);
|
||||
TEST_ASSERT(pkcs7.signed_data.signers.next == NULL);
|
||||
TEST_EQUAL(mbedtls_pkcs7_parse_der(&pkcs7, second_pkcs7_buf,
|
||||
second_buflen),
|
||||
res_expect);
|
||||
|
||||
exit:
|
||||
mbedtls_free(first_pkcs7_buf);
|
||||
mbedtls_free(second_pkcs7_buf);
|
||||
mbedtls_pkcs7_free(&pkcs7);
|
||||
USE_PSA_DONE();
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_FS_IO:MBEDTLS_X509_CRT_PARSE_C:MBEDTLS_PKCS1_V15:MBEDTLS_RSA_C */
|
||||
void pkcs7_verify(char *pkcs7_file,
|
||||
char *crt_files,
|
||||
|
||||
@ -2002,6 +2002,115 @@ pk_parse_public_keyfile_rsa:"../framework/data_files/rsa_pkcs1_2048_public.pem":
|
||||
Parse Public RSA Key #4 (PKCS#1 wrapped, DER)
|
||||
pk_parse_public_keyfile_rsa:"../framework/data_files/rsa_pkcs1_2048_public.der":0
|
||||
|
||||
Parse Public EC Key: secp256r1, nominal, DER (RFC 5480)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3059301306072a8648ce3d020106082a8648ce3d030107034200047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de45":0:0
|
||||
|
||||
Parse Public EC Key: secp256r1, compressed (supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3039301306072a8648ce3d020106082a8648ce3d030107032200037772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b57":0:0
|
||||
|
||||
Parse Public EC Key: secp256r1, compressed (not supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:!MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3039301306072a8648ce3d020106082a8648ce3d030107032200037772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b57":MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE:MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE
|
||||
|
||||
# Odd length of (x,y) coordinate pair
|
||||
Parse Public EC Key: secp256r1, truncated BIT STRING (-1, uncompressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3058301306072a8648ce3d020106082a8648ce3d030107034100047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
# Even length of (x,y) coordinate pair
|
||||
Parse Public EC Key: secp256r1, truncated BIT STRING (-2, uncompressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_RSA_C
|
||||
pk_parse_public_key_ec:"3057301306072a8648ce3d020106082a8648ce3d030107034000047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de":MBEDTLS_ERR_RSA_BAD_INPUT_DATA:MBEDTLS_ERR_RSA_BAD_INPUT_DATA
|
||||
|
||||
# Single coordinate too short
|
||||
Parse Public EC Key: secp256r1, truncated BIT STRING (-1, compressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3038301306072a8648ce3d020106082a8648ce3d030107032100037772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b":MBEDTLS_ERR_ECP_BAD_INPUT_DATA:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (00, compressed supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020000":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_INVALID_KEY
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (01, compressed supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020001":MBEDTLS_ERR_ECP_BAD_INPUT_DATA:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (02, compressed supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020002":MBEDTLS_ERR_ECP_BAD_INPUT_DATA:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (03, compressed supported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020003":MBEDTLS_ERR_ECP_BAD_INPUT_DATA:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (04)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020004":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, 1-byte BIT STRING (00, unsupported)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:!MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3019301306072a8648ce3d020106082a8648ce3d03010703020000":MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE:MBEDTLS_ERR_ECP_FEATURE_UNAVAILABLE
|
||||
|
||||
Parse Public EC Key: secp256r1, empty BIT STRING
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3018301306072a8648ce3d020106082a8648ce3d030107030100":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
# Odd length of (x,y) coordinate pair
|
||||
Parse Public EC Key: secp256r1, overly long BIT STRING (+1, uncompressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"305a301306072a8648ce3d020106082a8648ce3d030107034300047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de4543":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
# Even length of (x,y) coordinate pair
|
||||
Parse Public EC Key: secp256r1, overly long BIT STRING (+2, uncompressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"305b301306072a8648ce3d020106082a8648ce3d030107034400047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de454343":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, extremely long BIT STRING (uncompressed)
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3081da301306072a8648ce3d020106082a8648ce3d0301070381c20004787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878787878797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979797979":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: secp256r1, uncompressed, X out of range
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3059301306072a8648ce3d020106082a8648ce3d03010703420004ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de45":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_INVALID_KEY
|
||||
|
||||
Parse Public EC Key: secp256r1, uncompressed, Y out of range
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3059301306072a8648ce3d020106082a8648ce3d030107034200047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b57ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_INVALID_KEY
|
||||
|
||||
Parse Public EC Key: secp256r1, uncompressed, not on curve
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256
|
||||
pk_parse_public_key_ec:"3059301306072a8648ce3d020106082a8648ce3d030107034200047772656f814b399279d5e1f1781fac6f099a3c5ca1b0e35351834b08b65e0b572590cdaf8f769361bcf34acfc11e5e074e8426bdde04be6e653945449617de46":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_INVALID_KEY
|
||||
|
||||
Parse Public EC Key: secp256r1, compressed, X out of range
|
||||
depends_on:PSA_WANT_ECC_SECP_R1_256:MBEDTLS_PK_PARSE_EC_COMPRESSED
|
||||
pk_parse_public_key_ec:"3039301306072a8648ce3d020106082a8648ce3d03010703220003ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_INVALID_KEY
|
||||
|
||||
Parse Public EC Key: X25519, nominal, DER (RFC 8410)
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"302a300506032b656e0321009bc3b0e93d8233fe6a8ba6138948cc12a91362d5c2ed81584db05ab5419c9d11":0:0
|
||||
|
||||
Parse Public EC Key: X25519, truncated BIT STRING (-1)
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"3029300506032b656e0320009bc3b0e93d8233fe6a8ba6138948cc12a91362d5c2ed81584db05ab5419c9d":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: X25519, 1-byte BIT STRING
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"300b300506032b656e0302009b":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: X25519, empty BIT STRING
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"300a300506032b656e030100":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: X25519, overly long BIT STRING (+1)
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"302b300506032b656e0322009bc3b0e93d8233fe6a8ba6138948cc12a91362d5c2ed81584db05ab5419c9d1143":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key: X25519, extremely long BIT STRING
|
||||
depends_on:PSA_WANT_ECC_MONTGOMERY_255
|
||||
pk_parse_public_key_ec:"3081cc300506032b656e0381c20065656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565656565":MBEDTLS_ERR_PK_INVALID_PUBKEY:MBEDTLS_ERR_ECP_BAD_INPUT_DATA
|
||||
|
||||
Parse Public EC Key #1 (RFC 5480, DER)
|
||||
depends_on:MBEDTLS_ECP_HAVE_SECP192R1
|
||||
pk_parse_public_keyfile_ec:"../framework/data_files/ec_pub.der":0
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user