Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:96639 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 76759 invoked from network); 30 Oct 2016 00:22:59 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 30 Oct 2016 00:22:59 -0000 Authentication-Results: pb1.pair.com header.from=alice@librelamp.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=alice@librelamp.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain librelamp.com designates 45.79.96.192 as permitted sender) X-PHP-List-Original-Sender: alice@librelamp.com X-Host-Fingerprint: 45.79.96.192 librelamp.com Received: from [45.79.96.192] ([45.79.96.192:53402] helo=librelamp.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A6/FB-25911-26D35185 for ; Sat, 29 Oct 2016 20:22:59 -0400 Received: from localhost.localdomain (c-50-184-37-123.hsd1.ca.comcast.net [50.184.37.123]) by librelamp.com (Postfix) with ESMTPSA id BEFDF71A for ; Sun, 30 Oct 2016 00:22:54 +0000 (UTC) To: internals@lists.php.net Message-ID: <6b228f52-5ad6-0295-62ac-7c1b4b60484a@librelamp.com> Date: Sat, 29 Oct 2016 17:22:54 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------AE42913668D684EF2BBC2AE1" Subject: 7.1.0RC5 patch From: alice@librelamp.com (Alice Wonder) --------------AE42913668D684EF2BBC2AE1 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Hi, first post to list. LibreSSL user. PHP 7.1.0RC5 just needs one minor patch to work with LibreSSL, attached Justification - X509_get_signature_nid() was introduced in OpenSSL 1.0.2 but LibreSSL fork is prior to that. However (and I don't like this) LibreSSL uses a OPENSSL_VERSION_NUMBER defined as 0x20000000L So have to check for presence of LIBRESSL_VERSION_NUMBER when using functions introduced to OpenSSL after the fork (1.0.1h I think) Tested building against LibreSSL 2.4.3 on a CentOS 7 system (where OpenSSL has been completely removed) - 7.1.0RC5 compiles and works with that line changed. --------------AE42913668D684EF2BBC2AE1 Content-Type: text/x-patch; name="php-7.1.0RC5-libressl.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="php-7.1.0RC5-libressl.patch" diff -ur php-7.1.0RC5.orig/ext/openssl/openssl.c php-7.1.0RC5/ext/openssl/openssl.c --- php-7.1.0RC5.orig/ext/openssl/openssl.c 2016-10-25 08:23:21.000000000 -0700 +++ php-7.1.0RC5/ext/openssl/openssl.c 2016-10-29 17:02:33.549137954 -0700 @@ -669,7 +669,7 @@ return 1; } -#if OPENSSL_VERSION_NUMBER < 0x10002000L +#if OPENSSL_VERSION_NUMBER < 0x10002000L || defined (LIBRESSL_VERSION_NUMBER) static int X509_get_signature_nid(const X509 *x) { --------------AE42913668D684EF2BBC2AE1--