<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Sep 11, 2017 at 12:05 PM, Tatsuo Ishii <span dir="ltr">&lt;<a href="mailto:ishii@sraoss.co.jp" target="_blank">ishii@sraoss.co.jp</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I have tested the patch on Fedora 26 box and confirmed it works.<br>
<br>
$ openssl version<br>
OpenSSL 1.1.0f-fips  25 May 2017<br>
<br>
$ psql -h localhost -p 11000 test<br>
psql (9.6.3)<br>
SSL connection (protocol: TLSv1.2, cipher: ECDHE-RSA-AES256-GCM-SHA384, bits: 256, compression: off)<br>
<br>
It also works on Ubuntu 16 box which still uses OpenSSL 1.0.<br>
<br>
$ openssl version<br>
OpenSSL 1.0.2g  1 Mar 2016<br>
<br>
$ psql -p 11000 -h localhost test<br>
psql (9.6.5)<br>
SSL connection (protocol: TLSv1.2, cipher: AES256-GCM-SHA384, bits: 256, compression: off)<br>
<br>
Currently the patch is pushed to master, 3.6 stable and 3.5 stable<br>
branches. For 3.4 and 3.3, it&#39;s not straight forward because of the<br>
watchdog changes.<br>
<br>
Usama,<br>
<br>
Can you please take care of 3.4 and 3.3 branches?<br>
(3.2 is not needed because it&#39;s EOL).<br></blockquote><div><br></div><div>Sure I will do that.</div><div><br></div><div>Thanks</div><div>Best regards</div><div>Muhammad Usama</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class="im HOEnZb"><br>
Best regards,<br>
--<br>
Tatsuo Ishii<br>
SRA OSS, Inc. Japan<br>
English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_<wbr>en.php</a><br>
Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.<wbr>jp</a><br>
<br>
</span><div class="HOEnZb"><div class="h5">&gt; Hi Ishii-San<br>
&gt;<br>
&gt; I don&#39;t have the proper setup with openssl 1.1 at the moment so couldn&#39;t<br>
&gt; test the changes.<br>
&gt; But I have made the required changes as per the changelog of openssl 1.1<br>
&gt; Can you please check the attached patch if it works.<br>
&gt;<br>
&gt; Please note that the patch is generated over your patch.<br>
&gt;<br>
&gt;<br>
&gt; Thanks<br>
&gt; Best Regards<br>
&gt; Muhammad Usama<br>
&gt;<br>
&gt; On Fri, Jul 28, 2017 at 11:55 AM, Muhammad Usama &lt;<a href="mailto:m.usama@gmail.com">m.usama@gmail.com</a>&gt; wrote:<br>
&gt;<br>
&gt;&gt; Hi Ishii-San,<br>
&gt;&gt;<br>
&gt;&gt; Apparently HMAC_CTX_init and HMAC_CTX_cleanup are also removed from new<br>
&gt;&gt; openssl API. I am looking into the replacements for these functions will<br>
&gt;&gt; update on this thread.<br>
&gt;&gt;<br>
&gt;&gt; Thanks<br>
&gt;&gt; Best Regards<br>
&gt;&gt; Muhammad Usama<br>
&gt;&gt;<br>
&gt;&gt; On Fri, Jul 28, 2017 at 7:29 AM, Tatsuo Ishii &lt;<a href="mailto:ishii@sraoss.co.jp">ishii@sraoss.co.jp</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt;&gt; Hi Usama,<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; While working on $subject, I get compile errors while compiling<br>
&gt;&gt;&gt; watchdog:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; make[2]: Entering directory &#39;/home/t-ishii/src/pgpool2/<wbr>src/watchdog&#39;<br>
&gt;&gt;&gt; depbase=`echo wd_utils.o | sed &#39;s|[^/]*$|.deps/&amp;|;s|\.o$||&#39;`;<wbr>\<br>
&gt;&gt;&gt; gcc -DHAVE_CONFIG_H -I. -I../../src/include  -D_GNU_SOURCE -I<br>
&gt;&gt;&gt; /usr/include   -g -O2 -Wall -Wmissing-prototypes -Wmissing-declarations<br>
&gt;&gt;&gt; -fno-strict-aliasing -MT wd_utils.o -MD -MP -MF $depbase.Tpo -c -o<br>
&gt;&gt;&gt; wd_utils.o wd_utils.c &amp;&amp;\<br>
&gt;&gt;&gt; mv -f $depbase.Tpo $depbase.Po<br>
&gt;&gt;&gt; wd_utils.c: In function &#39;calculate_hmac_sha256&#39;:<br>
&gt;&gt;&gt; wd_utils.c:157:11: error: storage size of &#39;ctx&#39; isn&#39;t known<br>
&gt;&gt;&gt;   HMAC_CTX ctx;<br>
&gt;&gt;&gt;            ^~~<br>
&gt;&gt;&gt; wd_utils.c:158:2: warning: implicit declaration of function<br>
&gt;&gt;&gt; &#39;HMAC_CTX_init&#39;; did you mean &#39;HMAC_CTX_new&#39;? [-Wimplicit-function-declarati<br>
&gt;&gt;&gt; on]<br>
&gt;&gt;&gt;   HMAC_CTX_init(&amp;ctx);<br>
&gt;&gt;&gt;   ^~~~~~~~~~~~~<br>
&gt;&gt;&gt;   HMAC_CTX_new<br>
&gt;&gt;&gt; wd_utils.c:162:2: warning: implicit declaration of function<br>
&gt;&gt;&gt; &#39;HMAC_CTX_cleanup&#39;; did you mean &#39;HMAC_CTX_get_md&#39;?<br>
&gt;&gt;&gt; [-Wimplicit-function-<wbr>declaration]<br>
&gt;&gt;&gt;   HMAC_CTX_cleanup(&amp;ctx);<br>
&gt;&gt;&gt;   ^~~~~~~~~~~~~~~~<br>
&gt;&gt;&gt;   HMAC_CTX_get_md<br>
&gt;&gt;&gt; wd_utils.c:157:11: warning: unused variable &#39;ctx&#39; [-Wunused-variable]<br>
&gt;&gt;&gt;   HMAC_CTX ctx;<br>
&gt;&gt;&gt;            ^~~<br>
&gt;&gt;&gt; make[2]: *** [Makefile:400: wd_utils.o] Error 1<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Any idea how to fix them?<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; This is Fedora 26. Attached is the patch I&#39;m working on.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Best regards,<br>
&gt;&gt;&gt; --<br>
&gt;&gt;&gt; Tatsuo Ishii<br>
&gt;&gt;&gt; SRA OSS, Inc. Japan<br>
&gt;&gt;&gt; English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_<wbr>en.php</a><br>
&gt;&gt;&gt; Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.<wbr>jp</a><br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; diff --git a/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a> b/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
&gt;&gt;&gt; index 38c8611..1b7fb4a 100644<br>
&gt;&gt;&gt; --- a/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
&gt;&gt;&gt; +++ b/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
&gt;&gt;&gt; @@ -325,7 +325,7 @@ if test &quot;$with_openssl&quot; = yes || test &quot;$with_openssl&quot;<br>
&gt;&gt;&gt; = auto; then<br>
&gt;&gt;&gt;          ])<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;     AC_CHECK_LIB(crypto, CRYPTO_new_ex_data, [], [AC_MSG_ERROR([library<br>
&gt;&gt;&gt; &#39;crypto&#39; is required for OpenSSL])])<br>
&gt;&gt;&gt; -   AC_CHECK_LIB(ssl,    SSL_library_init, [], [AC_MSG_ERROR([library<br>
&gt;&gt;&gt; &#39;ssl&#39; is required for OpenSSL])])<br>
&gt;&gt;&gt; +   AC_CHECK_LIB(ssl,    SSL_new, [], [AC_MSG_ERROR([library &#39;ssl&#39; is<br>
&gt;&gt;&gt; required for OpenSSL])])<br>
&gt;&gt;&gt;  fi<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;  AC_ARG_WITH(pam,<br>
&gt;&gt;&gt; diff --git a/src/main/main.c b/src/main/main.c<br>
&gt;&gt;&gt; index 9dd0cc3..f33eec5 100644<br>
&gt;&gt;&gt; --- a/src/main/main.c<br>
&gt;&gt;&gt; +++ b/src/main/main.c<br>
&gt;&gt;&gt; @@ -5,7 +5,7 @@<br>
&gt;&gt;&gt;   * pgpool: a language independent connection pool server for PostgreSQL<br>
&gt;&gt;&gt;   * written by Tatsuo Ishii<br>
&gt;&gt;&gt;   *<br>
&gt;&gt;&gt; - * Copyright (c) 2003-2016     PgPool Global Development Group<br>
&gt;&gt;&gt; + * Copyright (c) 2003-2017     PgPool Global Development Group<br>
&gt;&gt;&gt;   *<br>
&gt;&gt;&gt;   * Permission to use, copy, modify, and distribute this software and<br>
&gt;&gt;&gt;   * its documentation for any purpose and without fee is hereby<br>
&gt;&gt;&gt; @@ -185,7 +185,11 @@ int main(int argc, char **argv)<br>
&gt;&gt;&gt;         }<br>
&gt;&gt;&gt;  #ifdef USE_SSL<br>
&gt;&gt;&gt;         /* global ssl init */<br>
&gt;&gt;&gt; +#if (OPENSSL_VERSION_NUMBER &gt;= 0x10100000L)<br>
&gt;&gt;&gt; +       OPENSSL_init_ssl(0, NULL);<br>
&gt;&gt;&gt; +#else<br>
&gt;&gt;&gt;         SSL_library_init();<br>
&gt;&gt;&gt; +#endif<br>
&gt;&gt;&gt;         SSL_load_error_strings();<br>
&gt;&gt;&gt;  #endif /* USE_SSL */<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; ______________________________<wbr>_________________<br>
&gt;&gt;&gt; pgpool-hackers mailing list<br>
&gt;&gt;&gt; <a href="mailto:pgpool-hackers@pgpool.net">pgpool-hackers@pgpool.net</a><br>
&gt;&gt;&gt; <a href="http://www.pgpool.net/mailman/listinfo/pgpool-hackers" rel="noreferrer" target="_blank">http://www.pgpool.net/mailman/<wbr>listinfo/pgpool-hackers</a><br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;<br>
</div></div></blockquote></div><br></div></div>