X-Original-To: pgsql-php-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.192]) by svr1.postgresql.org (Postfix) with ESMTP id 06A07CBFAE for ; Mon, 14 Jul 2003 19:07:39 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr4.postgresql.org [64.117.224.192]) (amavisd-new, port 10024) with ESMTP id 85455-06 for ; Mon, 14 Jul 2003 19:07:58 +0000 (GMT) Received: from ns.leals.com (215.Red-80-25-136.pooles.rima-tde.net [80.25.136.215]) by svr1.postgresql.org (Postfix) with ESMTP id E5916CADB8 for ; Mon, 14 Jul 2003 16:07:32 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by ns.leals.com (Postfix) with ESMTP id D92C69BD1; Mon, 14 Jul 2003 21:10:14 +0200 (CEST) From: Davi Leal To: pgsql-php@postgresql.org Subject: postgreSQL web form; Security Date: Mon, 14 Jul 2003 21:10:14 +0200 User-Agent: KMail/1.5.2 References: <200307132144.02772.davileal@terra.es> <20030713200102.GA15127@wilbur.25thandClement.com> In-Reply-To: <20030713200102.GA15127@wilbur.25thandClement.com> Cc: web-dev@gnuherds.org MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200307142110.14069.davileal@terra.es> X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/36 X-Sequence-Number: 2148 Hi, We are developing a web page: PHP & postgreSQL. We can transform the below (a) query to get the (b) query, if we add, "01001'); DELETE * FROM tbHosp; INSERT INTO tbRev (Id) VALUES ('01001" , as the value of Id in the web form. (a) INSERT INTO tbRev (Id) VALUES ('01001'); (b) INSERT INTO tbRev (Id) VALUES ('01001'); DELETE FROM tbHosp; INSERT INTO tbRev (Id) VALUES ('01001'); We are able to delete registers. We have checked and it works!. Microsoft Access 2000 does not allow me execute a composed query. It warns with something similar to "ERROR; -2147217900 [Microsoft][Microsoft Access ODBC Driver] Characters after the end of the first SQL query". How can we avoid this security risk using PHP & postgreSQL?. Regards, Davi