| От | David Fetter |
|---|---|
| Тема | Schema-qualify function calls in information_schema |
| Дата | |
| Msg-id | 20171220172122.GF10102@fetter.org обсуждение исходный текст |
| Ответы |
Re: Schema-qualify function calls in information_schema
|
| Список | pgsql-hackers |
Folks, It's possible to arrange for schemas to precede pg_catalog and information_schema in a search_path setting, and when that's done, hilarity can ensue, especially when someone has created functions with identical signatures but non-identical behavior. People who do that should probably be presumed to be attackers, but it's conceivable that such hilarity could merely be poor judgement combined with buggy code. Please find attached a patch against master to do $Subject, which tones down the hilarity, at least in information_schema. I did not attempt to go through and make sure that functions calls are schema-qualified all through the back-end, but that seems like a worthwhile project on grounds of reducing the search_path attack surface. Another way to fix this, which I know will be controversial, is simply to mandate that pg_catalog (and possibly information_schema) be non-changeably first in the search_path. What say? Best, David. -- David Fetter <david(at)fetter(dot)org> http://fetter.org/ Phone: +1 415 235 3778 Remember to vote! Consider donating to Postgres: http://www.postgresql.org/about/donate
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера