X-Original-To: pgsql-jdbc-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 138849FB2CE for ; Wed, 23 Aug 2006 03:32:01 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 52978-02 for ; Wed, 23 Aug 2006 03:31:56 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from yass.opencloud.co.nz (yass.opencloud.co.nz [131.203.101.226]) by postgresql.org (Postfix) with ESMTP id 640FD9FB26B for ; Wed, 23 Aug 2006 03:31:54 -0300 (ADT) Received: from 203-118-178-246.bliink.ihug.co.nz ([203.118.178.246] helo=[10.1.1.6]) by yass.opencloud.co.nz with asmtp (TLS-1.0:DHE_RSA_AES_128_CBC_SHA:16) (Exim 4.34) id 1GFmHH-0000Ss-Ji; Wed, 23 Aug 2006 18:31:51 +1200 Message-ID: <44EBF656.2000000@opencloud.com> Date: Wed, 23 Aug 2006 18:31:50 +1200 From: Oliver Jowett User-Agent: Thunderbird 1.5.0.5 (Windows/20060719) MIME-Version: 1.0 To: Justin Waddell CC: pgsql-jdbc@postgresql.org Subject: Re: Cannot use prepared statements with create user command References: <925094a20608222109s438a5b41g2886f41e9ddf7417@mail.gmail.com> In-Reply-To: <925094a20608222109s438a5b41g2886f41e9ddf7417@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.185 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200608/104 X-Sequence-Number: 15631 Justin Waddell wrote: >> From my research into this problem it seems like prepared statements > have been deliberately left out of the create user command as they use > a different type of parameter; this would be fine if the security hole > wasn't there! The JDBC driver can only put parameters in where the server-side grammar allows it (it does not interpolate parameter values into the actual query, it puts $1,$2,... placeholders in place of the ? placeholders and passes the actual parameter values out-of-line from the query itself). If you want to change the grammar, you need to take this up with the backend developers.. the JDBC driver can't do anything about it. -O