public inbox for [email protected]
help / color / mirror / Atom feedFrom: 王跃林 <[email protected]>
To: [email protected]
Subject: Fw:Re: Fw: ltree_compare in contrib/ltree/ltree_op.c overflows int32 on deep ltree comparisons, returning the wrong sign
Date: Sat, 13 Jun 2026 11:50:25 +0800 (GMT+08:00)
Message-ID: <AI6AnABgKW93Qbx1jVzi84r9.8.1781322625756.Hmail.3020001251@tju.edu.cn> (raw)
-------- 转发邮件信息 --------
发件人:Noah Misch <[email protected]>
发送日期:2026-06-13 08:31:47
收件人:"[email protected]" <[email protected]>
抄送人:[email protected]
主题:Re: Fw: ltree_compare in contrib/ltree/ltree_op.c overflows int32 on deep ltree comparisons, returning the wrong sign
On Mon, May 25, 2026 at 10:58:05PM +0800, [email protected] wrote:
> PoC
>
> File vuln_001.sql
>
> CREATE EXTENSION IF NOT EXISTS ltree;
> â
> WITH s AS (SELECT 'a'::ltree AS v),
> l AS (SELECT (repeat('a.', 19999) || 'a')::ltree AS v)
> SELECT (l.v > s.v) AS long_gt_short_expected_true,
> (l.v < s.v) AS long_lt_short_expected_false
> FROM s, l;
>
> Process
>
> psql -h /tmp -p 36265 -U postgres -f vuln_001.sql
>
> Results
>
> long_gt_short_expected_true | long_lt_short_expected_false
> -----------------------------+------------------------------
> f | t
>
> Both columns are inverted. long > short returned false, long < short
> returned true.
This is certainly a bug, but it's not a vuln. Please report the bug to
[email protected].
view thread (5+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: Fw:Re: Fw: ltree_compare in contrib/ltree/ltree_op.c overflows int32 on deep ltree comparisons, returning the wrong sign
In-Reply-To: <AI6AnABgKW93Qbx1jVzi84r9.8.1781322625756.Hmail.3020001251@tju.edu.cn>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox