Re: [patch] fix dblink security hole

Поиск
Список
Период
Сортировка
От Joe Conway
Тема Re: [patch] fix dblink security hole
Дата
Msg-id 48D7148B.6020806@joeconway.com
обсуждение исходный текст
Ответ на Re: [patch] fix dblink security hole  (Joe Conway <mail@joeconway.com>)
Ответы Re: [patch] fix dblink security hole
Список pgsql-hackers
Joe Conway wrote:
> Tom Lane wrote:
>> Refactoring doesn't seem like an easy way to fix this, because of the
>> problem that the behavior of pulling up defaults is part of the API
>> specification for PQconndefaults().
>>
>> Thoughts?
> 
> Hmm, I could have sworn I looked for that, and saw it elsewhere. Anyway, 
> you are obviously correct.
> 
> conninfo_parse() is presently only called from a few places -- maybe we 
> should have conninfo_parse() really just parse, and create a new 
> conninfo_get_missing() or some such that fills in missing values?

Maybe better:

static PQconninfoOption *
conninfo_parse(const char *conninfo, PQExpBuffer errorMessage,               bool fill_defaults, bool
*password_from_string)

There are only three call sites including the new one. The two originals 
could use fill_defaults == true, and PQconninfoParse could use false.

Joe


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [patch] fix dblink security hole
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [patch] fix dblink security hole