From: Richard Levitte Date: Thu, 7 Sep 2023 03:57:36 +0000 (+0200) Subject: BIO_set_accept_name(): To accept from any interface, use * X-Git-Tag: openssl-3.2.0-alpha2~128 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b0da24bd2dc64e3a01df24e01aba37fe4c269230;p=thirdparty%2Fopenssl.git BIO_set_accept_name(): To accept from any interface, use * Using "*:{port}" is preferred to "[::]:{port}", because it won't break on IPv4-only machines. This fixes test failures in 79-test_http.t and 80-test_ssl_new.t on machines without IPv6. Reviewed-by: Paul Dale Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/21989) --- diff --git a/apps/lib/http_server.c b/apps/lib/http_server.c index f406bb06287..bca2e7110d4 100644 --- a/apps/lib/http_server.c +++ b/apps/lib/http_server.c @@ -200,7 +200,7 @@ BIO *http_server_init(const char *prog, const char *port, int verb) int port_num; char name[40]; - snprintf(name, sizeof(name), "[::]:%s", port); /* port may be "0" */ + snprintf(name, sizeof(name), "*:%s", port); /* port may be "0" */ if (verb >= 0 && !log_set_verbosity(prog, verb)) return NULL; bufbio = BIO_new(BIO_f_buffer());