1 /* LibTomCrypt, modular cryptographic library -- Tom St Denis */ 2 /* SPDX-License-Identifier: Unlicense */ 3 4 #include "tomcrypt_private.h" 5 6 #ifdef LTC_MECC 7 8 /** Extract OID as a string from ECC key 9 @param out [out] destination buffer 10 @param outlen [in/out] Length of destination buffer and final output size (without terminating NUL byte) 11 @param key The ECC key 12 Return CRYPT_OK on success 13 */ 14 ecc_get_oid_str(char * out,unsigned long * outlen,const ecc_key * key)15int ecc_get_oid_str(char *out, unsigned long *outlen, const ecc_key *key) 16 { 17 LTC_ARGCHK(key != NULL); 18 19 return pk_oid_num_to_str(key->dp.oid, key->dp.oidlen, out, outlen); 20 } 21 22 #endif 23