pg.ddx.io GitHub: postgresql-interfaces/psqlodbc (issues + PRs as email threads)help / color / mirror / Atom feed
[postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) 4+ messages / 2 participants [nested] [flat]
* [postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) @ 2026-04-22 11:05 "davecramer (@davecramer)" <noreply+davecramer@github.com> 0 siblings, 0 replies; 4+ messages in thread From: davecramer (@davecramer) @ 2026-04-22 11:05 UTC (permalink / raw) To: postgresql-interfaces/psqlodbc <noreply+postgresql-interfaces-psqlodbc@github.com> Clamp precision to the buffer size (9) before writing the NUL terminator in getPrecisionPart(). Previously, a precision value > 9 would write past the end of the local fraction[] buffer, corrupting the stack. Also fix SQLSetDescField for ARD records: setting SQL_DESC_PRECISION, SQL_DESC_SCALE, or SQL_DESC_OCTET_LENGTH no longer nulls the data buffer. The unbind logic was incorrectly applied to these metadata fields, causing any descriptor precision override to silently unbind the column. Add interval-overflow regression test that exercises both fixes by fetching an interval with fractional seconds using precision=20 via the ARD. Fixes Issue #173 Reported by [@jarvis24young](https://github.com/jarvis24young) in [#173](https://github.com/postgresql-interfaces/psqlodbc/issues/173) ^ permalink raw [nested|flat] 4+ messages in thread
* Re: [postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) @ 2026-04-23 02:53 "davecramer (@davecramer)" <noreply+davecramer@github.com> 2 siblings, 0 replies; 4+ messages in thread From: davecramer (@davecramer) @ 2026-04-23 02:53 UTC (permalink / raw) To: postgresql-interfaces/psqlodbc <noreply+postgresql-interfaces-psqlodbc@github.com> @davecramer closed this. ^ permalink raw [nested|flat] 4+ messages in thread
* Re: [postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) @ 2026-04-23 02:53 "davecramer (@davecramer)" <noreply+davecramer@github.com> 2 siblings, 0 replies; 4+ messages in thread From: davecramer (@davecramer) @ 2026-04-23 02:53 UTC (permalink / raw) To: postgresql-interfaces/psqlodbc <noreply+postgresql-interfaces-psqlodbc@github.com> @davecramer merged this (commit baa7b49fcd9d). ^ permalink raw [nested|flat] 4+ messages in thread
* Re: [postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) @ 2026-04-23 03:48 "jarvis24young (@jarvis24young)" <noreply+jarvis24young@github.com> 2 siblings, 0 replies; 4+ messages in thread From: jarvis24young (@jarvis24young) @ 2026-04-23 03:48 UTC (permalink / raw) To: postgresql-interfaces/psqlodbc <noreply+postgresql-interfaces-psqlodbc@github.com> thx @davecramer ^ permalink raw [nested|flat] 4+ messages in thread
end of thread, other threads:[~2026-04-23 03:48 UTC | newest] Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2026-04-22 11:05 [postgresql-interfaces/psqlodbc] PR #174: Fix stack buffer overflow in getPrecisionPart() (GitHub #173) "davecramer (@davecramer)" <noreply+davecramer@github.com> 2026-04-23 02:53 ` "davecramer (@davecramer)" <noreply+davecramer@github.com> 2026-04-23 02:53 ` "davecramer (@davecramer)" <noreply+davecramer@github.com> 2026-04-23 03:48 ` "jarvis24young (@jarvis24young)" <noreply+jarvis24young@github.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox