From: Oliver Jowett <oliver@opencloud.com>
To: Minal <minalac@yes2etl.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: postgresql.stat.result
Date: Wed, 03 Aug 2005 19:01:20 +1200
Message-ID: <42F06BC0.8080405@opencloud.com> (raw)
In-Reply-To: <42F05EA7.4000102@yes2etl.com>
References: <42F05EA7.4000102@yes2etl.com>
Minal wrote:
> sql="SELECT sp_login ('INSERT','admin','"+username+"','"+password+"')";
> //sql="INSERT INTO USERS (USERTYPE,USERNAME,PASSWORD) VALUES
> ('admin','"+username+"','"+password+"')";
> pStat=conn.prepareStatement(sql);
On another topic, either you need to ensure that username/password are
correctly escaped, or you should use '?' placeholders and use
setString() to set them. Otherwise you have a SQL injection hole there.
-O
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: oliver@opencloud.com, minalac@yes2etl.com
Subject: Re: postgresql.stat.result
In-Reply-To: <42F06BC0.8080405@opencloud.com>
References: <42F05EA7.4000102@yes2etl.com> <42F06BC0.8080405@opencloud.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox