text
[RRG-proxmark3.git] / common / mbedtls / ecc_point_compression.h
blobfc691f8a4fe622244cca61544e1c118f43774621
1 /*
2 * Not original to the mbedtls library. Taken from
3 * https://github.com/mwarning/mbedtls_ecp_compression
4 * to solve mbedtls' lack of support for elliptic point
5 * compression and decompression
7 * Released under CC0 1.0 Universal License
8 */
11 * This is all about mbedtls_ecp_decompress() and mbedtls_ecp_compress()
13 * Perform X25519 / Curve25519 point compression and decompression for mbedtls.
14 * As of mbedtls 2.5.1, mbedtls does not support decompression yet.
18 #include <string.h>
20 #include "mbedtls/ecp.h"
22 int mbedtls_ecp_decompress(
23 const mbedtls_ecp_group *grp,
24 const unsigned char *input, size_t ilen,
25 unsigned char *output, size_t *olen, size_t osize
28 int mbedtls_ecp_compress(
29 const mbedtls_ecp_group *grp,
30 const unsigned char *input, size_t ilen,
31 unsigned char *output, size_t *olen, size_t osize