Re: Buffer overflow in SerializeLibraryState() found by Address Sanitizer

From: David Geier <geidav(dot)pg(at)gmail(dot)com>
To: Daniel Gustafsson <daniel(at)yesql(dot)se>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Buffer overflow in SerializeLibraryState() found by Address Sanitizer
Date: 2025-06-10 14:30:09
Message-ID: 3f032ae2-d6b3-482b-bda4-26a9f674dea9@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

But just seeing now that size in EstimateLibraryState() is initialized
to 1. So that total size should actually be fine. Weird that the patch
makes the sanitizer error disappear.

On 6/10/2025 4:21 PM, David Geier wrote:
> The loop advances the pointer via start_address += len.
>
--
David Geier
(ServiceNow)

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Johnson 2025-06-10 14:40:23 [PATCH v1] Add pg_stat_multixact view for multixact membership usage monitoring
Previous Message Konstantin Knizhnik 2025-06-10 14:28:11 Re: Non-reproducible AIO failure