PK_MAX_RETRIES
This commit is contained in:
parent
0c115a162d
commit
b8f22157b3
@ -17,6 +17,9 @@ enum {
|
|||||||
/* Indicates standard output formats that can be read e.g. by OpenSSL or GnuTLS */
|
/* Indicates standard output formats that can be read e.g. by OpenSSL or GnuTLS */
|
||||||
#define PK_STD 0x1000
|
#define PK_STD 0x1000
|
||||||
|
|
||||||
|
/* iterations limit for retry-loops */
|
||||||
|
#define PK_MAX_RETRIES 20
|
||||||
|
|
||||||
int rand_prime(void *N, long len, prng_state *prng, int wprng);
|
int rand_prime(void *N, long len, prng_state *prng, int wprng);
|
||||||
int rand_bn_bits(void *N, int bits, prng_state *prng, int wprng);
|
int rand_bn_bits(void *N, int bits, prng_state *prng, int wprng);
|
||||||
int rand_bn_range(void *N, void *limit, prng_state *prng, int wprng);
|
int rand_bn_range(void *N, void *limit, prng_state *prng, int wprng);
|
||||||
|
@ -22,7 +22,7 @@ static int _ecc_sign_hash(const unsigned char *in, unsigned long inlen,
|
|||||||
{
|
{
|
||||||
ecc_key pubkey;
|
ecc_key pubkey;
|
||||||
void *r, *s, *e, *p;
|
void *r, *s, *e, *p;
|
||||||
int err, max_iterations = 20;
|
int err, max_iterations = PK_MAX_RETRIES;
|
||||||
unsigned long pbits, pbytes, i, shift_right;
|
unsigned long pbits, pbytes, i, shift_right;
|
||||||
unsigned char ch, buf[MAXBLOCKSIZE];
|
unsigned char ch, buf[MAXBLOCKSIZE];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user