Commit e1b665e1 authored by Paul Bakker's avatar Paul Bakker
Browse files

Added POLARSSL_ECP_MAX_SIZE and POLARSSL_ECP_WINDOW_SIZE to config.h

parent fef3c5a6
......@@ -1784,6 +1784,11 @@
#define CTR_DRBG_MAX_REQUEST 1024 /**< Maximum number of requested bytes per call */
#define CTR_DRBG_MAX_SEED_INPUT 384 /**< Maximum size of (re)seed buffer */
// ECP options
//
#define POLARSSL_ECP_MAX_BITS 521 /**< Maximum bit size of groups */
#define POLARSSL_ECP_WINDOW_SIZE 6 /**< Maximum window size used */
// Entropy options
//
#define ENTROPY_MAX_SOURCES 20 /**< Maximum number of sources supported */
......
......@@ -161,13 +161,17 @@ typedef struct
}
ecp_keypair;
#if !defined(POLARSSL_CONFIG_OPTIONS)
/**
* Maximum size of the groups (that is, of N and P)
*/
#define POLARSSL_ECP_MAX_BITS 521
#define POLARSSL_ECP_MAX_BITS 521 /**< Maximum bit size of groups */
#endif
#define POLARSSL_ECP_MAX_BYTES ( ( POLARSSL_ECP_MAX_BITS + 7 ) / 8 )
#define POLARSSL_ECP_MAX_PT_LEN ( 2 * POLARSSL_ECP_MAX_BYTES + 1 )
#if !defined(POLARSSL_CONFIG_OPTIONS)
/*
* Maximum "window" size used for point multiplication.
* Default: 6.
......@@ -178,7 +182,8 @@ ecp_keypair;
*
* Reduction in size may reduce speed for big curves.
*/
#define POLARSSL_ECP_WINDOW_SIZE 6 /**< Maximum window size used. */
#define POLARSSL_ECP_WINDOW_SIZE 6 /**< Maximum window size used */
#endif
/*
* Point formats, from RFC 4492's enum ECPointFormat
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment