Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1XJmBp-0002tz-L1 for pgsql-hackers@arkaria.postgresql.org; Tue, 19 Aug 2014 16:23:17 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XJmBo-0008Hq-G8 for pgsql-hackers@arkaria.postgresql.org; Tue, 19 Aug 2014 16:23:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XJmBm-0008Hh-Tl for pgsql-hackers@postgreSQL.org; Tue, 19 Aug 2014 16:23:14 +0000 Received: from smtp-outbound-1.vmware.com ([208.91.2.12]) by magus.postgresql.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1XJmBg-0005mb-2h for pgsql-hackers@postgreSQL.org; Tue, 19 Aug 2014 16:23:12 +0000 Received: from sc9-mailhost2.vmware.com (sc9-mailhost2.vmware.com [10.113.161.72]) by smtp-outbound-1.vmware.com (Postfix) with ESMTP id 2626E29EBA; Tue, 19 Aug 2014 09:23:02 -0700 (PDT) Received: from EX13-CAS-006.vmware.com (EX13-CAS-006.vmware.com [10.113.191.56]) by sc9-mailhost2.vmware.com (Postfix) with ESMTP id 1CBDEB16AC; Tue, 19 Aug 2014 09:23:02 -0700 (PDT) Received: from EX13-MBX-024.vmware.com (10.113.191.44) by EX13-MBX-010.vmware.com (10.113.191.30) with Microsoft SMTP Server (TLS) id 15.0.775.38; Tue, 19 Aug 2014 09:22:55 -0700 Received: from [192.168.1.90] (10.113.160.246) by EX13-MBX-024.vmware.com (10.113.191.44) with Microsoft SMTP Server (TLS) id 15.0.775.38; Tue, 19 Aug 2014 09:22:54 -0700 Message-ID: <53F379CF.5090100@vmware.com> Date: Tue, 19 Aug 2014 19:22:39 +0300 From: Heikki Linnakangas Organization: VMware User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Icedove/24.5.0 MIME-Version: 1.0 To: Alvaro Herrera , Stephen Frost CC: PostgreSQL-development Subject: Re: PQgetssl() and alternative SSL implementations References: <53F1E989.8020609@vmware.com> <20140819144841.GA16422@tamriel.snowman.net> <53F36B6E.6040105@vmware.com> <20140819154436.GD16422@tamriel.snowman.net> <20140819161000.GF6817@eldon.alvh.no-ip.org> In-Reply-To: <20140819161000.GF6817@eldon.alvh.no-ip.org> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.113.160.246] X-ClientProxiedBy: EX13-CAS-013.vmware.com (10.113.191.65) To EX13-MBX-024.vmware.com (10.113.191.44) X-Pg-Spam-Score: -7.6 (-------) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 08/19/2014 07:10 PM, Alvaro Herrera wrote: > Stephen Frost wrote: >> * Heikki Linnakangas (hlinnakangas@vmware.com) wrote: >> >>> Indeed, the ODBC driver only uses libpq for authentication, then >>> calls PQgetssl(), and takes over the whole show calling SSL_read() >>> and SSL_write() itself. Ideally, we'd modify psqlodbc to stop doing >>> that, but that's not an easy job. In the short-term, I think we need >>> to export pqsecure_read() and pqsecure_write() functions in libpq, >>> so that the ODBC driver can use those instead of SSL_read() and >>> SSL_write(). >> >> Yeah, that's what I remembered. There was an attempt to make that >> change at one point, but it was reverted due to the lack of batching >> ability in libpq (without resorting to cursors, as I recall...), >> requiring double the memory usage. Still, if pqsecure_read and >> pqsecure_write are sufficient to make the ODBC driver work, that's good >> news. I had been worried it did other things with the OpenSSL struct >> beyond just using those. > > Um, libpq has recently gained the ability to return result fragments, > right? Those didn't exist when libpq-ification of odbc was attempted, > as I recall -- perhaps it's possible now. IIRC the thing that psqlodbc does that libpq doesn't support is sending multiple queries to the backend, and then wait for *all* the replies to arrive, in a single round-trip. The closest thing is using PQexec("foo; bar;"), but that's quite limited. - Heikki -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers