Commit 59d37902 authored by Tomas Mraz's avatar Tomas Mraz Committed by Matt Caswell
Browse files

Ignore -named_curve auto value to improve backwards compatibility



Fixes #3490

Reviewed-by: default avatarRich Salz <rsalz@openssl.org>
Reviewed-by: default avatarMatt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3518)
(cherry picked from commit 1c7aa0db)
parent 2984afda
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -9,7 +9,9 @@
 Changes between 1.1.0f and 1.1.0g [xx XXX xxxx]
  *)
  *) Ignore the '-named_curve auto' value for compatibility of applications
     with OpenSSL 1.0.2.
     [Tomas Mraz <tmraz@fedoraproject.org>]
 Changes between 1.1.0e and 1.1.0f [25 May 2017]
+8 −0
Original line number Diff line number Diff line
@@ -221,6 +221,14 @@ static int cmd_ECDHParameters(SSL_CONF_CTX *cctx, const char *value)
    EC_KEY *ecdh;
    int nid;

    /* Ignore values supported by 1.0.2 for the automatic selection */
    if ((cctx->flags & SSL_CONF_FLAG_FILE) &&
        strcasecmp(value, "+automatic") == 0)
        return 1;
    if ((cctx->flags & SSL_CONF_FLAG_CMDLINE) &&
        strcmp(value, "auto") == 0)
        return 1;

    nid = EC_curve_nist2nid(value);
    if (nid == NID_undef)
        nid = OBJ_sn2nid(value);