Re: Protecting a web app from Postgresql injection

Поиск
Список
Период
Сортировка
От Andres Ledesma
Тема Re: Protecting a web app from Postgresql injection
Дата
Msg-id 766490.5838.qm@web38012.mail.mud.yahoo.com
обсуждение исходный текст
Ответ на Protecting a web app from Postgresql injection  (Mary Anderson <maryfran@demog.berkeley.edu>)
Список pgsql-novice
Hi,

It my be interesting to read this : http://lwn.net/Articles/185813/

And, IMHO:
In a web app you can take advantage of the posibility of having several layers, the n-layers model, to validate and filter, even change at your need the users input when security of your apps is at risk.  In that sense avoiding undesired chars in the db tables start at the web pages in form of jsvascript validation, goes on on the middleware, and can be done last time in functions that inserts content in tables.

Personally I do prefer to use  functions ( stored procs ) for inserts and updates of table contents, never use SQL code neither in web pages, neither in middleware objects, always  there is a function that insert or modify the tables content. This allows me to have the db structure deep at the bottom layer of the app, and only people dealing with db knows the real structure of the tables, or db.

Hope this simple hints helps.

Andy

В списке pgsql-novice по дате отправления:

Предыдущее
От: Chander Ganesan
Дата:
Сообщение: Re: Group Roles are now Login Roles in pgAdmin?
Следующее
От: Robert Bernabe
Дата:
Сообщение: Re: Group Roles are now Login Roles in pgAdmin?