add DSA raw params import export, raw key export functions

This commit is contained in:
Chris Conlon
2018-01-08 09:58:03 -07:00
parent 61f6b9ce0f
commit fc563550c6
7 changed files with 183 additions and 11 deletions

View File

@@ -4729,15 +4729,16 @@ LBL_U:mp_clear (&v);
#endif /* WOLFSSL_KEY_GEN */
#if defined(HAVE_ECC) || defined(WOLFSSL_KEY_GEN) || defined(HAVE_COMP_KEY) || \
defined(WOLFSSL_DEBUG_MATH) || defined(DEBUG_WOLFSSL)
#if !defined(NO_DSA) || defined(HAVE_ECC) || defined(WOLFSSL_KEY_GEN) || \
defined(HAVE_COMP_KEY) || defined(WOLFSSL_DEBUG_MATH) || \
defined(DEBUG_WOLFSSL)
/* chars used in radix conversions */
const char *mp_s_rmap = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ\
abcdefghijklmnopqrstuvwxyz+/";
#endif
#ifdef HAVE_ECC
#if !defined(NO_DSA) || defined(HAVE_ECC)
/* read a string [ASCII] in a given radix */
int mp_read_radix (mp_int * a, const char *str, int radix)
{
@@ -4807,7 +4808,7 @@ int mp_read_radix (mp_int * a, const char *str, int radix)
}
return MP_OKAY;
}
#endif /* HAVE_ECC */
#endif /* !defined(NO_DSA) || defined(HAVE_ECC) */
#if defined(WOLFSSL_KEY_GEN) || defined(HAVE_COMP_KEY) || \
defined(WOLFSSL_DEBUG_MATH) || defined(DEBUG_WOLFSSL)