Added ecp_write_binary().

This commit is contained in:
Manuel Pégourié-Gonnard 2012-11-24 14:10:14 +01:00 committed by Paul Bakker
parent 1c33057a63
commit e19feb5b46
4 changed files with 96 additions and 0 deletions
include/polarssl

View file

@ -209,6 +209,20 @@ int ecp_group_read_string( ecp_group *grp, int radix,
const char *p, const char *b,
const char *gx, const char *gy, const char *n);
/**
* \brief Export a point into unsigned binary data, uncompressed
*
* \param grp Group the point belongs to
* \param P Point to export
* \param olen Length of the actual ouput
* \param buf Output buffer
* \param buflen Length of the output buffer
*
* \return 0 if successful, or POLARSSL_ERR_ECP_GENERIC
*/
int ecp_write_binary( const ecp_group *grp, const ecp_point *P,
size_t *olen, unsigned char *buf, size_t buflen );
/**
* \brief Set a group using well-known domain parameters
*