Lines Matching refs:otstype

50 #define SIG_TYPE_OFFSET(otstype) (SIG_OTS_SIG_OFFSET   + \  argument
51 MBEDTLS_LMOTS_SIG_LEN(otstype))
52 #define SIG_PATH_OFFSET(otstype) (SIG_TYPE_OFFSET(otstype) + \ argument
128 MBEDTLS_LMOTS_N_HASH_LEN(params->otstype)); in create_merkle_leaf_value()
243 mbedtls_lmots_algorithm_type_t otstype; in mbedtls_lms_import_public_key() local
255 otstype = (mbedtls_lmots_algorithm_type_t) in mbedtls_lms_import_public_key()
257 if (otstype != MBEDTLS_LMOTS_SHA256_N32_W8) { in mbedtls_lms_import_public_key()
260 ctx->params.otstype = otstype; in mbedtls_lms_import_public_key()
286 MBEDTLS_PUT_UINT32_BE(ctx->params.otstype, key, PUBLIC_KEY_OTSTYPE_OFFSET); in mbedtls_lms_export_public_key()
325 if (ctx->params.otstype in mbedtls_lms_verify()
330 if (sig_size != MBEDTLS_LMS_SIG_LEN(ctx->params.type, ctx->params.otstype)) { in mbedtls_lms_verify()
343 if (sig_size < SIG_TYPE_OFFSET(ctx->params.otstype) + MBEDTLS_LMS_TYPE_LEN) { in mbedtls_lms_verify()
347 if (MBEDTLS_GET_UINT32_BE(sig, SIG_TYPE_OFFSET(ctx->params.otstype)) in mbedtls_lms_verify()
363 ots_params.type = ctx->params.otstype; in mbedtls_lms_verify()
369 MBEDTLS_LMOTS_SIG_LEN(ctx->params.otstype), in mbedtls_lms_verify()
392 left_node = sig + SIG_PATH_OFFSET(ctx->params.otstype) + in mbedtls_lms_verify()
397 right_node = sig + SIG_PATH_OFFSET(ctx->params.otstype) + in mbedtls_lms_verify()
564 mbedtls_lmots_algorithm_type_t otstype, in mbedtls_lms_generate_private_key() argument
576 if (otstype != MBEDTLS_LMOTS_SHA256_N32_W8) { in mbedtls_lms_generate_private_key()
585 ctx->params.otstype = otstype; in mbedtls_lms_generate_private_key()
621 otstype, in mbedtls_lms_generate_private_key()
661 if (priv_ctx->params.otstype in mbedtls_lms_calculate_public_key()
708 if (sig_size < MBEDTLS_LMS_SIG_LEN(ctx->params.type, ctx->params.otstype)) { in mbedtls_lms_sign()
716 if (ctx->params.otstype in mbedtls_lms_sign()
732 if (MBEDTLS_LMS_SIG_LEN(ctx->params.type, ctx->params.otstype) in mbedtls_lms_sign()
744 ctx->params.otstype) - SIG_OTS_SIG_OFFSET, in mbedtls_lms_sign()
750 MBEDTLS_PUT_UINT32_BE(ctx->params.type, sig, SIG_TYPE_OFFSET(ctx->params.otstype)); in mbedtls_lms_sign()
755 sig + SIG_PATH_OFFSET(ctx->params.otstype)); in mbedtls_lms_sign()
761 *sig_len = MBEDTLS_LMS_SIG_LEN(ctx->params.type, ctx->params.otstype); in mbedtls_lms_sign()