summaryrefslogtreecommitdiffhomepage
path: root/lib/crypto-mbedtls.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/crypto-mbedtls.c')
-rw-r--r--lib/crypto-mbedtls.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/lib/crypto-mbedtls.c b/lib/crypto-mbedtls.c
index e4a3b1e..1cc9a99 100644
--- a/lib/crypto-mbedtls.c
+++ b/lib/crypto-mbedtls.c
@@ -42,35 +42,12 @@ md_digest(uc_vm_t *vm, size_t nargs)
return rv;
}
-#if 0
-
-static uc_value_t *
-ecsa_verify(uc_vm_t *vm, size_t nargs)
-{
- // Read key from 0x04 | x | y
- int mbedtls_ecp_point_read_binary(const mbedtls_ecp_group *grp,
- mbedtls_ecp_point *pt,
- const unsigned char *buf, size_t ilen);
-
- // Verify
- int mbedtls_ecdsa_verify(mbedtls_ecp_group *grp,
- const unsigned char *buf, size_t blen,
- const mbedtls_ecp_point *Q,
- const mbedtls_mpi *r,
- const mbedtls_mpi *s);
-}
-#endif
-
static uc_value_t *
pk_init(uc_vm_t *vm, size_t nargs)
{
- const mbedtls_pk_info_t *info = mbedtls_pk_info_from_type(MBEDTLS_PK_ECDSA);
mbedtls_pk_context *ctx = malloc(sizeof(mbedtls_pk_context));
mbedtls_pk_init(ctx);
- /* if (mbedtls_pk_setup(ctx, info)) */
- /* uc_vm_raise_exception(vm, EXCEPTION_RUNTIME, "ECDSA not available"); */
-
return uc_resource_new(pk_type, ctx);
}