Lines Matching refs:sc_ctx

82     memset(&ctx->sc_ctx, 0, sizeof(sc_rsa_context_t));  in mbedtls_rsa_init()
294 ctx->sc_ctx.key_bits = ctx->len * 8; in mbedtls_rsa_pkcs1_encrypt()
295 ctx->sc_ctx.padding_type = SC_RSA_PADDING_MODE_PKCS1; in mbedtls_rsa_pkcs1_encrypt()
296 ctx->sc_ctx.n = key; in mbedtls_rsa_pkcs1_encrypt()
297 ctx->sc_ctx.e = key + key_size; in mbedtls_rsa_pkcs1_encrypt()
298 ret = sc_rsa_encrypt(&ctx->sc_rsa, &ctx->sc_ctx, (void *)input, ilen, new_output); in mbedtls_rsa_pkcs1_encrypt()
360 ctx->sc_ctx.key_bits = ctx->len * 8; in mbedtls_rsa_pkcs1_decrypt()
361 ctx->sc_ctx.padding_type = SC_RSA_PADDING_MODE_PKCS1; in mbedtls_rsa_pkcs1_decrypt()
362 ctx->sc_ctx.n = key; in mbedtls_rsa_pkcs1_decrypt()
363 ctx->sc_ctx.e = key + key_size; in mbedtls_rsa_pkcs1_decrypt()
364 ctx->sc_ctx.d = key + key_size + key_size; in mbedtls_rsa_pkcs1_decrypt()
365 ret = sc_rsa_decrypt(&ctx->sc_rsa, &ctx->sc_ctx, (void *)input, ctx->len, output, olen); in mbedtls_rsa_pkcs1_decrypt()
448 ctx->sc_ctx.key_bits = ctx->len * 8; in mbedtls_rsa_pkcs1_sign()
449 ctx->sc_ctx.padding_type = SC_RSA_PADDING_MODE_PKCS1; in mbedtls_rsa_pkcs1_sign()
450 ctx->sc_ctx.n = key; in mbedtls_rsa_pkcs1_sign()
451 ctx->sc_ctx.e = key + key_size; in mbedtls_rsa_pkcs1_sign()
452 ctx->sc_ctx.d = key + key_size + key_size; in mbedtls_rsa_pkcs1_sign()
453 ret = sc_rsa_sign(&ctx->sc_rsa, &ctx->sc_ctx, (void *)hash, hashlen, sig, type); in mbedtls_rsa_pkcs1_sign()
538 ctx->sc_ctx.key_bits = ctx->len * 8; in mbedtls_rsa_pkcs1_verify()
539 ctx->sc_ctx.padding_type = SC_RSA_PADDING_MODE_PKCS1; in mbedtls_rsa_pkcs1_verify()
540 ctx->sc_ctx.n = key; in mbedtls_rsa_pkcs1_verify()
541 ctx->sc_ctx.e = key + key_size; in mbedtls_rsa_pkcs1_verify()
542 ret = sc_rsa_verify(&ctx->sc_rsa, &ctx->sc_ctx, (void *)hash, hashlen, new_sig, in mbedtls_rsa_pkcs1_verify()
643 memset(&ctx->sc_ctx, 0, sizeof(sc_rsa_context_t)); in mbedtls_rsa_free()