Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id DA1AB9F9EC9 for ; Fri, 17 Nov 2006 13:17:48 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 37139-02 for ; Fri, 17 Nov 2006 13:17:45 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 472999F9B3F for ; Fri, 17 Nov 2006 13:17:45 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.6/8.13.6) with ESMTP id kAHHHgxw015196; Fri, 17 Nov 2006 12:17:42 -0500 (EST) To: "sergio.cinos@info3.com (IMAP)" cc: pgsql-admin@postgresql.org Subject: Re: Client SSL validation using root.crt In-reply-to: <298705741.20061117113737@info3.com> References: <298705741.20061117113737@info3.com> Comments: In-reply-to "sergio.cinos@info3.com (IMAP)" message dated "Fri, 17 Nov 2006 11:37:37 +0100" Date: Fri, 17 Nov 2006 12:17:42 -0500 Message-ID: <15195.1163783862@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200611/171 X-Sequence-Number: 23698 "sergio.cinos@info3.com (IMAP)" writes: > I see a strange behaviour using root.crt. PostgreSQL always waits a > client certificate to check agains root.crt. But I set up a > 'hostnossl' auth line un pg_hba.conf, PostgreSQL still wants a client > certificate. If your client first tries to connect with SSL, it seems likely that the certificate check would occur before we examine pg_hba.conf and decide to reject the connection on that basis. But your client should then retry without SSL. See libpq's "sslmode" parameter and PGSSLMODE environment variable if you want it to try in the other order. regards, tom lane