pgsql: dict_int: Return NULL for zero-length tokens.

Поиск
Список
Период
Сортировка
Искать

pgsql: dict_int: Return NULL for zero-length tokens.

От:
Noah Misch <noah@leadboat.com>
Дата:
dict_int: Return NULL for zero-length tokens.

dintdict_lexize() does not check for zero-length tokens before
inspecting its input, so it can read past the end of the token.  In
some cases, the returned lexeme can even contain data from well
beyond it.  To fix, return NULL for a zero-length token, as
dict_ispell, dict_synonym, and dict_xsyn already do.

Reported-by: Nathan Bossart 
Reported-by: Anthropic OSS program
Author: Nathan Bossart 
Co-authored-by: Anthropic OSS program
Reviewed-by: Tom Lane 
Reviewed-by: Tatsuo Ishii 
Security: CVE-2026-116308
Backpatch-through: 14

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/fd0864aa0d5073d0960a5862935dd5711814074c
Author: Nathan Bossart 

Modified Files
--------------
contrib/dict_int/dict_int.c            | 6 +++++-
contrib/dict_int/expected/dict_int.out | 6 ++++++
contrib/dict_int/sql/dict_int.sql      | 1 +
3 files changed, 12 insertions(+), 1 deletion(-)

FAQ