Remove |EC_KEY_precompute_mult|.

This function only does per-group precomputation, not key-specific
precomputation, so using it is no better than using
|EC_GROUP_precompute_mult|. Worse, an unsuspecting caller may not
realize that this is modifying a possibly-shared |EC_GROUP|, so it
seems dangerous.
This commit is contained in:
Brian Smith 2015-10-07 20:32:26 -10:00
parent f3dc192d5f
commit 92e8bb51f7
2 changed files with 0 additions and 13 deletions

View File

@ -136,13 +136,6 @@ int EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key) {
return (key->pub_key == NULL) ? 0 : 1;
}
int EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx) {
if (key->group == NULL) {
return 0;
}
return EC_GROUP_precompute_mult(key->group, ctx);
}
int EC_KEY_check_key(const EC_KEY *eckey) {
int ok = 0;
BN_CTX *ctx = NULL;

View File

@ -109,12 +109,6 @@ OPENSSL_EXPORT const EC_POINT *EC_KEY_get0_public_key(const EC_KEY *key);
* It returns one on success and zero otherwise. */
OPENSSL_EXPORT int EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub);
/* EC_KEY_precompute_mult precomputes multiplies of the generator of the
* underlying group in order to speed up operations that calculate generator
* multiples. If |ctx| is not NULL, it may be used. It returns one on success
* and zero otherwise. */
OPENSSL_EXPORT int EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx);
/* EC_KEY_check_key performs several checks on |key| (possibly including an
* expensive check that the public key is in the primary subgroup). It returns
* one if all checks pass and zero otherwise. If it returns zero then detail