summaryrefslogtreecommitdiffstats
path: root/crypto/rsa/rsa.h
diff options
context:
space:
mode:
authorGeoff Thorpe <geoff@openssl.org>2004-03-25 02:52:04 +0000
committerGeoff Thorpe <geoff@openssl.org>2004-03-25 02:52:04 +0000
commit46ef873f0b3c04b6415cddac5d4a7b27b53cc482 (patch)
treed045819aeac3f9d4665713eb6917a5f351ca9bf9 /crypto/rsa/rsa.h
parent2d2a5ba32a6da293bbe290529293c485d36e1c19 (diff)
By adding a BN_CTX parameter to the 'rsa_mod_exp' callback, private key
operations no longer require two distinct BN_CTX structures. This may put more "strain" on the current BN_CTX implementation (which has a fixed limit to the number of variables it will hold), but so far this limit is not triggered by any of the tests pass and I will be changing BN_CTX in the near future to avoid this problem anyway. This also changes the default RSA implementation code to use the BN_CTX in favour of initialising some of its variables locally in each function.
Diffstat (limited to 'crypto/rsa/rsa.h')
-rw-r--r--crypto/rsa/rsa.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/rsa/rsa.h b/crypto/rsa/rsa.h
index 12689fc22d..b3ed1edd3f 100644
--- a/crypto/rsa/rsa.h
+++ b/crypto/rsa/rsa.h
@@ -93,7 +93,7 @@ typedef struct rsa_meth_st
int (*rsa_priv_dec)(int flen,const unsigned char *from,
unsigned char *to,
RSA *rsa,int padding);
- int (*rsa_mod_exp)(BIGNUM *r0,const BIGNUM *I,RSA *rsa); /* Can be null */
+ int (*rsa_mod_exp)(BIGNUM *r0,const BIGNUM *I,RSA *rsa,BN_CTX *ctx); /* Can be null */
int (*bn_mod_exp)(BIGNUM *r, const BIGNUM *a, const BIGNUM *p,
const BIGNUM *m, BN_CTX *ctx,
BN_MONT_CTX *m_ctx); /* Can be null */