Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1U2LRS-000514-De for pgsql-jdbc@arkaria.postgresql.org; Mon, 04 Feb 2013 12:46:34 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1U2LRR-0001Bp-5u for pgsql-jdbc@arkaria.postgresql.org; Mon, 04 Feb 2013 12:46:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1U2LRP-0001BI-B9; Mon, 04 Feb 2013 12:46:31 +0000 Received: from szxga02-in.huawei.com ([119.145.14.65]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1U2LRI-00075f-T7; Mon, 04 Feb 2013 12:46:30 +0000 Received: from 172.24.2.119 (EHLO szxeml213-edg.china.huawei.com) ([172.24.2.119]) by szxrg02-dlp.huawei.com (MOS 4.3.4-GA FastPath queued) with ESMTP id AWT23242; Mon, 04 Feb 2013 20:46:14 +0800 (CST) Received: from SZXEML406-HUB.china.huawei.com (10.82.67.93) by szxeml213-edg.china.huawei.com (172.24.2.30) with Microsoft SMTP Server (TLS) id 14.1.323.7; Mon, 4 Feb 2013 20:46:11 +0800 Received: from blrprnc07ns (10.18.96.96) by szxeml406-hub.china.huawei.com (10.82.67.93) with Microsoft SMTP Server id 14.1.323.7; Mon, 4 Feb 2013 20:46:08 +0800 From: Hari Babu To: "'Adrian Klaver'" CC: "'dmp'" , , References: <51068542.845c2b0a.7fd0.68b2SMTPIN_ADDED_BROKEN@mx.google.com> <00a401cdfdde$db9737e0$92c5a7a0$@kommi@huawei.com> <5107FBCA.3040107@ttc-cmc.net> <007601cdffb5$cc4834a0$64d89de0$@kommi@huawei.com> <510ABEC8.6030201@ttc-cmc.net> <510bcd82.c1b30e0a.076d.68e8SMTPIN_ADDED_BROKEN@mx.google.com> <510BCFC3.3040202@gmail.com> In-Reply-To: <510BCFC3.3040202@gmail.com> Subject: Re: [GENERAL] JDBC connection test with SSL on PG 9.2.1 server Date: Mon, 4 Feb 2013 18:16:07 +0530 Message-ID: <013601ce02d5$9adeb7e0$d09c27a0$@kommi@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: Ac4Ah6dvqXUY/zShSZKNJPu0Xr9+AACTSkIA Content-Language: en-us X-Originating-IP: [10.18.96.96] X-CFilter-Loop: Reflected X-Pg-Spam-Score: -0.9 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org On Friday, February 01, 2013 7:53 PM Adrian Klaver wrote: >On 02/01/2013 06:06 AM, Hari Babu wrote: >> >> We tried the approach as suggested by you but still it is not working as= shown in the below log (I had enabled logLevel as 1) >> keystore passowrd is qwerty >> 19:26:22.666 (1) PostgreSQL 9.2 JDBC4 (build 1002) >> 19:26:23.451 (1) Receive Buffer Size is 43808 >> 19:26:23.452 (1) Send Buffer Size is 25386 >> getConnection returning driver[className=3Dorg.postgresql.Driver,org.pos= tgresql.Driver@3f7fa65e] >> Connection1 successful! Conn1:org.postgresql.jdbc4.Jdbc4Connection@6baa9= f99 >> null >> wrongqwerty >> DriverManager.getConnection("jdbc:postgresql://127.0.0.1:15432/postgres") >> trying driver[className=3Dsun.jdbc.odbc.JdbcOdbcDriver,sun.jdbc.odb= c.JdbcOdbcDriver@3597a37c] >> *Driver.connect (jdbc:postgresql://127.0.0.1:15432/postgres) >> trying driver[className=3Dorg.postgresql.Driver,org.postgresql.Driv= er@3f7fa65e] >> 19:26:23.835 (2) PostgreSQL 9.2 JDBC4 (build 1002) >> 19:26:23.847 (2) Receive Buffer Size is 43808 >> 19:26:23.848 (2) Send Buffer Size is 25386 >> getConnection returning driver[className=3Dorg.postgresql.Driver,org.pos= tgresql.Driver@3f7fa65e] >> Connection2 successful! Conn2:org.postgresql.jdbc4.Jdbc4Connection@2e958= bb8 >> >> Connect OK >> >> There is function as SSL_CTX_SETSESSIONCACHEMODE(ctxt, mode) in C librar= y of SSL. >> Can you please let us know if there is some similar function in JSSE al= so. >Per a previous post, have you verified that pg_hba.conf is set up to=20 >properly handle SSL password connections? Yes, I have modified the pg_hba.conf as follows to handle the SSL connectio= ns. # IPv4 local connections:=20 hostssl all all 10.18.0.0/16 cert=20 please provide your suggestions. Regards, Hari babu. --=20 Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc