Re: doPickSplit stack buffer overflow in XLogInsert?

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: doPickSplit stack buffer overflow in XLogInsert?
Дата
Msg-id 20131126221949.GJ23284@alap2.anarazel.de
обсуждение исходный текст
Ответ на doPickSplit stack buffer overflow in XLogInsert?  (Kevin Grittner <kgrittn@ymail.com>)
Ответы Re: doPickSplit stack buffer overflow in XLogInsert?  (Kevin Grittner <kgrittn@ymail.com>)
Список pgsql-hackers
On 2013-11-26 14:14:38 -0800, Kevin Grittner wrote:
> I happened to build in a shell that was still set up for the clang
> address sanitizer, and got the attached report.  On a rerun it was
> repeatable.  XLogInsert() seems to read past the end of a variable
> allocated on the stack in doPickSplit(). I haven't tried to analyze
> it past that, since this part of the code is unfamiliar to me.

Yea, I've seen that one before as well and planned to report it at some
point. The reason is the MAXALIGN()s in ACCEPT_RDATA_DATA(). That rounds
up to 8byte boundaries, while we've e.g. only added 2bytes of slop to
toDelete.


Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



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

Предыдущее
От: Hannu Krosing
Дата:
Сообщение: Re: [PATCH] Add transforms feature
Следующее
От: Paul Ramsey
Дата:
Сообщение: Re: Traffic jams in fn_extra