1 // SPDX-License-Identifier: BSD-2-Clause
2 /* LibTomCrypt, modular cryptographic library -- Tom St Denis
3  *
4  * LibTomCrypt is a library that provides various cryptographic
5  * algorithms in a highly modular and flexible manner.
6  *
7  * The library is free for all purposes without any express
8  * guarantee it works.
9  */
10 
11 #include "tomcrypt_private.h"
12 
13 /**
14   @file ecc_ansi_x963_export.c
15   ECC Crypto, Tom St Denis
16 */
17 
18 #ifdef LTC_MECC
19 
20 /** ECC X9.63 (Sec. 4.3.6) uncompressed export
21   @param key     Key to export
22   @param out     [out] destination of export
23   @param outlen  [in/out]  Length of destination and final output size
24   Return CRYPT_OK on success
25 */
ecc_ansi_x963_export(const ecc_key * key,unsigned char * out,unsigned long * outlen)26 int ecc_ansi_x963_export(const ecc_key *key, unsigned char *out, unsigned long *outlen)
27 {
28    return ecc_get_key(out, outlen, PK_PUBLIC, key);
29 }
30 
31 #endif
32 
33 /* ref:         $Format:%D$ */
34 /* git commit:  $Format:%H$ */
35 /* commit time: $Format:%ai$ */
36