Re: @(#)Mordred Labs advisory 0x0007: Remove DoS in PostgreSQL

Поиск
Список
Период
Сортировка
От Shridhar Daithankar
Тема Re: @(#)Mordred Labs advisory 0x0007: Remove DoS in PostgreSQL
Дата
Msg-id 3D6A8EAB.31690.244677E0@localhost
обсуждение исходный текст
Ответ на @(#)Mordred Labs advisory 0x0007: Remove DoS in PostgreSQL  (Sir Mordred The Traitor <mordred@s-mail.com>)
Список pgsql-hackers
On 26 Aug 2002 at 14:46, Sir Mordred The Traitor wrote:
> [snip]
> static int recv_and_check_password0(Port *port) {
>     int32 len;
>     char *buf;
>  
>     if (pq_getint(&len, 4) == EOF)
>         return STATUS_EOF;
>     len -= 4;
>     buf = palloc(len); /* len is taken from a packet */
> [snip]

So that should read,
buf=palloc((len>LENMAX?SAFELEN:len));

is what you want to say? 

sounds good to me.. But if it is taken from the packet, won't that be tripped 
to MTA size? Just a naïve question. Never saw much of postgres code myself..


ByeShridhar

--
Wilcox's Law:    A pat on the back is only a few centimeters from a kick in the 
pants.



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

Предыдущее
От: Sir Mordred The Traitor
Дата:
Сообщение: @(#)Mordred Labs advisory 0x0007: Remove DoS in PostgreSQL
Следующее
От: Tom Lane
Дата:
Сообщение: Re: @(#)Mordred Labs advisory 0x0007: Remove DoS in PostgreSQL