diff options
author | Bodo Möller <bodo@openssl.org> | 2002-04-17 13:35:52 +0200 |
---|---|---|
committer | Bodo Möller <bodo@openssl.org> | 2002-04-17 13:35:52 +0200 |
commit | dde3e83129ecc3ca06a5c4d1698334c26ec4bd9e (patch) | |
tree | f617d1d2c51d649071fb5ca58d624207c949b8e8 /crypto/ecdsa/ecs_asn1.c | |
parent | 'version' is not optional in the encoding (diff) | |
download | openssl-dde3e83129ecc3ca06a5c4d1698334c26ec4bd9e.tar.xz openssl-dde3e83129ecc3ca06a5c4d1698334c26ec4bd9e.zip |
'version' is not optional in the encoding
Submitted by: Nils Larsch
Diffstat (limited to 'crypto/ecdsa/ecs_asn1.c')
-rw-r--r-- | crypto/ecdsa/ecs_asn1.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/crypto/ecdsa/ecs_asn1.c b/crypto/ecdsa/ecs_asn1.c index 0b2baf7219..07899150be 100644 --- a/crypto/ecdsa/ecs_asn1.c +++ b/crypto/ecdsa/ecs_asn1.c @@ -261,14 +261,9 @@ X9_62_EC_PARAMETERS *ECDSA_get_X9_62_EC_PARAMETERS(const ECDSA *ecdsa, X9_62_EC_ } else ret = param; - if (ecdsa->version == 1) - ret->version = NULL; - else - { - if (ret->version == NULL && (ret->version = ASN1_INTEGER_new()) == NULL) - OPENSSL_ECDSA_ABORT(ERR_R_MALLOC_FAILURE) - if (!ASN1_INTEGER_set(ret->version, (long)ecdsa->version)) goto err; - } + if (ret->version == NULL && (ret->version = ASN1_INTEGER_new()) == NULL) + OPENSSL_ECDSA_ABORT(ERR_R_MALLOC_FAILURE) + if (!ASN1_INTEGER_set(ret->version, (long)ecdsa->version)) goto err; if ((ret->fieldID = ECDSA_get_X9_62_FIELDID(ecdsa, ret->fieldID)) == NULL) OPENSSL_ECDSA_ABORT(ECDSA_R_ECDSA_GET_X9_62_FIELDID_FAILURE) if ((ret->curve = ECDSA_get_X9_62_CURVE(ecdsa, ret->curve)) == NULL) |