postgresql/src/test/regress/expected
Tom Lane edc0a8d82a Detect integer overflow while computing new array dimensions.
array_set_element() and related functions allow an array to be
enlarged by assigning to subscripts outside the current array bounds.
While these places were careful to check that the new bounds are
allowable, they neglected to consider the risk of integer overflow
in computing the new bounds.  In edge cases, we could compute new
bounds that are invalid but get past the subsequent checks,
allowing bad things to happen.  Memory stomps that are potentially
exploitable for arbitrary code execution are possible, and so is
disclosure of server memory.

To fix, perform the hazardous computations using overflow-detecting
arithmetic routines, which fortunately exist in all still-supported
branches.

The test cases added for this generate (after patching) errors that
mention the value of MaxArraySize, which is platform-dependent.
Rather than introduce multiple expected-files, use psql's VERBOSITY
parameter to suppress the printing of the message text.  v11 psql
lacks that parameter, so omit the tests in that branch.

Our thanks to Pedro Gallegos for reporting this problem.

Security: CVE-2023-5869
2023-11-06 10:56:43 -05:00
..
.gitignore Replace opr_sanity test's binary_coercible() function with C code. 2021-05-11 14:28:11 -04:00
advisory_lock.out
aggregates.out Fix failure to detect some cases of improperly-nested aggregates. 2023-03-13 12:40:28 -04:00
alter_generic.out Message fixes and style improvements 2020-09-14 06:42:30 +02:00
alter_operator.out Avoid unnecessary use of pg_strcasecmp for already-downcased identifiers. 2018-01-26 18:25:14 -05:00
alter_table.out Reject attempts to alter composite types used in indexes. 2023-03-27 15:04:02 -04:00
amutils.out Support INCLUDE'd columns in SP-GiST. 2021-04-05 18:41:21 -04:00
arrays.out Detect integer overflow while computing new array dimensions. 2023-11-06 10:56:43 -05:00
async.out
bit.out Add bit_count SQL function 2021-03-23 10:13:58 +01:00
bitmapops.out
boolean.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
box.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
brin.out Properly detoast data in brin_form_tuple 2020-11-07 00:39:19 +01:00
brin_bloom.out BRIN bloom indexes 2021-03-26 13:35:32 +01:00
brin_multi.out Fix minmax-multi distance for extreme interval values 2023-10-27 18:46:56 +02:00
btree_index.out Block ALTER INDEX/TABLE index_name ALTER COLUMN colname SET (options) 2021-10-19 11:04:00 +09:00
case.out Add support for NullIfExpr in eval_const_expressions 2021-04-02 11:01:49 +02:00
char.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
char_1.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
char_2.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
circle.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
cluster.out Fix CLUSTER tuplesorts on abbreviated expressions. 2022-04-20 17:17:41 -07:00
collate.icu.utf8.out Revert per-index collation version tracking feature. 2021-05-07 21:10:11 +12:00
collate.icu.utf8_1.out Run UTF8-requiring collation tests by default 2019-07-31 09:46:51 +02:00
collate.linux.utf8.out Revert per-index collation version tracking feature. 2021-05-07 21:10:11 +12:00
collate.linux.utf8_1.out Run UTF8-requiring collation tests by default 2019-07-31 09:46:51 +02:00
collate.out Fix old bug with coercing the result of a COLLATE expression. 2021-04-12 14:37:49 -04:00
combocid.out Sanitize the term "combo CID" in code comments 2021-03-25 16:08:03 +09:00
comments.out
compression.out Remove forced toast recompression in VACUUM FULL/CLUSTER 2021-06-14 09:25:50 +09:00
compression_1.out Message style improvements 2021-06-28 08:36:44 +02:00
conversion.out Replace opr_sanity test's binary_coercible() function with C code. 2021-05-11 14:28:11 -04:00
copy2.out Fix handling of redundant options with COPY for "freeze" and "header" 2020-10-05 09:43:17 +09:00
copydml.out Extend a test case a little 2021-02-26 09:11:15 +01:00
copyselect.out Revert "psql: Show all query results by default" 2021-04-15 19:42:55 +02:00
create_aggregate.out Introduce "anycompatible" family of polymorphic types. 2020-03-19 11:43:11 -04:00
create_am.out Remove deprecated containment operators for built-in types 2020-11-03 10:43:12 +01:00
create_cast.out
create_function_3.out Fix handling of R/W expanded datums that are passed to SQL functions. 2022-08-10 13:37:25 -04:00
create_index.out Fix memory leak in IndexScan node with reordering 2022-02-14 03:32:31 +03:00
create_index_spgist.out Support INCLUDE'd columns in SP-GiST. 2021-04-05 18:41:21 -04:00
create_misc.out Remove gratuitous uses of deprecated SELECT INTO 2021-01-28 14:28:41 +01:00
create_operator.out Remove support for postfix (right-unary) operators. 2020-09-17 19:38:05 -04:00
create_procedure.out Reconsider the handling of procedure OUT parameters. 2021-06-10 17:11:36 -04:00
create_schema.out Fix crashes with CREATE SCHEMA AUTHORIZATION and schema elements 2023-04-28 19:29:38 +09:00
create_table.out Avoid using ambiguous word "positive" in error message. 2021-08-25 11:47:43 +09:00
create_table_like.out Don't print extra parens around expressions in extended stats 2021-09-01 00:44:12 +02:00
create_type.out Allow ALTER TYPE to update an existing type's typsubscript value. 2020-12-11 18:58:21 -05:00
create_view.out Prevent pgstats from getting confused when relkind of a relation changes 2022-12-02 18:10:30 -08:00
date.out Change return type of EXTRACT to numeric 2021-04-06 07:20:42 +02:00
dbsize.out Fix incorrect return value in pg_size_pretty(bigint) 2021-07-09 14:04:40 +12:00
delete.out
dependency.out Multirange datatypes 2020-12-20 07:20:33 +03:00
domain.out Fix assignment to array of domain over composite, redux. 2023-04-15 12:01:39 -04:00
drop_if_exists.out Introduce the 'force' option for the Drop Database command. 2019-11-13 08:25:33 +05:30
drop_operator.out
enum.out Fix enum errdetail to mention bytes, not chars 2020-10-27 11:50:18 +01:00
equivclass.out Suppress unnecessary RelabelType nodes in more cases. 2020-02-26 18:14:12 -05:00
errors.out Reject SELECT ... GROUP BY GROUPING SETS (()) FOR UPDATE. 2021-06-01 11:12:56 -04:00
event_trigger.out Fix DDL deparse of CREATE OPERATOR CLASS 2022-05-20 18:52:55 +02:00
explain.out Fix regression test failure caused by commit 4f0b0966c8 2021-04-07 18:14:46 -04:00
expressions.out Fix typos in comments, code and documentation 2023-01-03 16:26:30 +09:00
fast_default.out Don't set a fast default for anything but a plain table 2021-06-18 06:51:12 -04:00
float4-misrounded-input.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
float4.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
float8.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
foreign_data.out Fix unexpected error messages for various flavors of ALTER TABLE 2021-07-14 17:15:01 +09:00
foreign_key.out Reject system columns as elements of foreign keys. 2023-03-31 11:18:49 -04:00
functional_deps.out
generated.out Fix some more cases of missed GENERATED-column updates. 2023-03-06 18:31:16 -05:00
geometry.out Fix NaN comparison in circle_same test 2022-09-12 12:59:06 +02:00
gin.out Improve test coverage of ginvacuum.c. 2020-09-01 18:40:43 -04:00
gist.out Don't use_physical_tlist for an IOS with non-returnable columns. 2022-02-11 15:23:52 -05:00
groupingsets.out Make pull_var_clause() handle GroupingFuncs exactly like Aggrefs. 2022-05-12 11:31:46 -04:00
guc.out Re-allow custom GUC names that have more than two components. 2021-06-02 18:50:23 -04:00
hash_func.out Fix portability issue in tests from commit ce773f230. 2021-09-03 10:01:02 -04:00
hash_index.out Add more tests for reloptions 2017-10-19 14:22:05 +02:00
hash_part.out Avoid using ambiguous word "non-negative" in error messages. 2021-07-28 01:21:35 +09:00
horology.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
hs_standby_allowed.out Allow UNLISTEN in hot-standby mode. 2019-01-25 21:14:49 -05:00
hs_standby_check.out
hs_standby_disallowed.out Correct standbycheck regression test output. 2020-05-12 13:56:19 +09:00
hs_standby_functions.out Introduce xid8-based functions to replace txid_XXX. 2020-04-07 12:04:32 +12:00
identity.out Forbid marking an identity column as nullable. 2021-03-12 11:08:42 -05:00
incremental_sort.out Add proper regression test for the recent SRFs-in-pathkeys problem. 2022-08-04 11:11:22 -04:00
index_including.out Support INCLUDE'd columns in SP-GiST. 2021-04-05 18:41:21 -04:00
index_including_gist.out Support for INCLUDE attributes in GiST indexes 2019-03-10 11:37:17 +03:00
indexing.out Fix updates of indisvalid for partitioned indexes 2023-07-14 10:13:17 +09:00
indirect_toast.out Fix portability issue in test indirect_toast 2021-06-07 18:12:29 +09:00
inet.out Add test case for abbrev(cidr) 2021-02-11 09:56:14 +01:00
infinite_recurse.out Paper over regression failures in infinite_recurse() on PPC64 Linux. 2020-10-13 17:44:56 -04:00
infinite_recurse_1.out Paper over regression failures in infinite_recurse() on PPC64 Linux. 2020-10-13 17:44:56 -04:00
inherit.out Fix problems when a plain-inheritance parent table is excluded. 2023-10-24 14:48:34 -04:00
init_privs.out
insert.out Accept slightly-filled pages for tuples larger than fillfactor. 2021-03-30 18:53:44 -07:00
insert_conflict.out Allow table-qualified variable names in ON CONFLICT ... WHERE. 2021-04-13 15:39:41 -04:00
int2.out Check column list length in XMLTABLE/JSON_TABLE alias 2022-05-18 20:28:31 +02:00
int4.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
int8.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
interval.out Fix extract epoch from interval calculation 2022-04-19 21:03:27 +02:00
join.out Don't use partial unique indexes for unique proofs in the planner 2023-06-19 13:01:58 +12:00
join_hash.out Fix hash join when inner hashkey expressions contain Params. 2023-06-20 17:47:36 -04:00
json.out Improve reporting for syntax errors in multi-line JSON data. 2021-03-01 16:44:17 -05:00
json_encoding.out Fix JSON error reporting for many cases of erroneous string values. 2023-03-13 15:19:00 -04:00
json_encoding_1.out Fix JSON error reporting for many cases of erroneous string values. 2023-03-13 15:19:00 -04:00
json_encoding_2.out Allow Unicode escapes in any server encoding, not only UTF-8. 2020-03-06 14:17:43 -05:00
jsonb.out Compute aggregate argument types correctly in transformAggregateCall(). 2023-11-06 10:38:00 -05:00
jsonb_jsonpath.out Accept fractional seconds in jsonpath's datetime() method. 2023-06-12 10:54:28 -04:00
jsonpath.out Remove %error-verbose directive from jsonpath parser 2022-07-03 17:16:11 -04:00
jsonpath_encoding.out Allow Unicode escapes in any server encoding, not only UTF-8. 2020-03-06 14:17:43 -05:00
jsonpath_encoding_1.out Allow Unicode escapes in any server encoding, not only UTF-8. 2020-03-06 14:17:43 -05:00
jsonpath_encoding_2.out Allow Unicode escapes in any server encoding, not only UTF-8. 2020-03-06 14:17:43 -05:00
limit.out Error out if SKIP LOCKED and WITH TIES are both specified 2021-10-01 18:29:18 -03:00
line.out Change floating-point output format for improved performance. 2019-02-13 15:20:33 +00:00
lock.out Revert "Accept relations of any kind in LOCK TABLE". 2020-11-06 16:17:56 -05:00
lseg.out Improve test coverage of geometric types 2018-09-26 10:45:21 +02:00
macaddr.out
macaddr8.out
matview.out Show 'AS "?column?"' explicitly when it's important. 2022-05-21 14:45:58 -04:00
memoize.out Use OFFSET 0 instead of ORDER BY to stop subquery pullup 2023-01-24 13:50:11 +13:00
misc_functions.out Add function to log the memory contexts of specified backend process. 2021-04-06 13:44:15 +09:00
misc_sanity.out Revert per-index collation version tracking feature. 2021-05-07 21:10:11 +12:00
money.out Fix loss of fractional digits for large values in cash_numeric(). 2019-07-26 11:59:00 -04:00
multirangetypes.out Fix alignment in multirange_get_range() function 2021-12-13 17:20:07 +03:00
mvcc.out Increment xactCompletionCount during subtransaction abort. 2021-04-06 09:24:50 -07:00
name.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
namespace.out Replace last PushOverrideSearchPath() call with set_config_option(). 2023-05-08 06:14:11 -07:00
numeric.out Fix corner case bug in numeric to_char() some more. 2023-03-14 19:17:31 -04:00
numeric_big.out Fix corner-case loss of precision in numeric ln(). 2020-03-01 14:49:25 +00:00
numerology.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
object_address.out Eliminate cache lookup errors in SQL functions for object addresses 2020-07-15 09:03:10 +09:00
oid.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
oidjoins.out Extended statistics on expressions 2021-03-27 00:01:11 +01:00
opr_sanity.out Dissociate btequalimage() from interval_ops, ending its deduplication. 2023-10-14 16:33:54 -07:00
partition_aggregate.out Move per-agg and per-trans duplicate finding to the planner. 2020-11-24 10:45:00 +02:00
partition_info.out Fix crash with pg_partition_root 2019-03-22 17:27:38 +09:00
partition_join.out Rework planning and execution of UPDATE and DELETE. 2021-03-31 11:52:37 -04:00
partition_prune.out Fix runtime partition pruning for HASH partitioned tables 2023-10-13 01:13:59 +13:00
password.out Change default of password_encryption to scram-sha-256 2020-06-10 16:42:55 +02:00
path.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
pg_lsn.out Add +(pg_lsn,numeric) and -(pg_lsn,numeric) operators. 2020-06-30 23:55:07 +09:00
plancache.out Add generic_plans and custom_plans fields into pg_prepared_statements. 2020-07-20 11:55:50 +09:00
plpgsql.out Fix checking of query type in plpgsql's RETURN QUERY command. 2021-10-03 13:21:20 -04:00
point.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
polygon.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
polymorphism.out Fix bugs in polymorphic-argument resolution for multiranges. 2021-07-27 15:01:49 -04:00
portals.out Fix some anomalies with NO SCROLL cursors. 2021-09-10 13:18:32 -04:00
portals_p2.out
prepare.out Add error position to an error message 2019-11-29 09:10:17 +01:00
prepared_xacts.out Fix check for conflicting session- vs transaction-level locks. 2021-07-24 18:35:52 -04:00
prepared_xacts_1.out Fix check for conflicting session- vs transaction-level locks. 2021-07-24 18:35:52 -04:00
privileges.out Ban role pg_signal_backend from more superuser backend types. 2023-11-06 06:14:17 -08:00
psql.out Avoid Assert failure when processing empty statement in aborted xact. 2023-06-21 11:07:11 -04:00
psql_crosstab.out Change return type of EXTRACT to numeric 2021-04-06 07:20:42 +02:00
publication.out Fix replica identity check for a partitioned table. 2022-08-16 14:51:42 +05:30
random.out Remove gratuitous uses of deprecated SELECT INTO 2021-01-28 14:28:41 +01:00
rangefuncs.out Fix planner error with pulling up subquery expressions into function RTEs. 2021-10-14 12:43:43 -04:00
rangetypes.out Fix alignment in multirange_get_range() function 2021-12-13 17:20:07 +03:00
regex.linux.utf8.out
regex.out Fix regexp misbehavior with capturing parens inside "{0}". 2021-08-24 16:37:27 -04:00
regproc.out Implement type regcollation 2020-03-18 21:21:00 +01:00
reindex_catalog.out Fix rd_firstRelfilenodeSubid for nailed relations, in parallel workers. 2020-09-09 18:50:24 -07:00
reloptions.out Try to stabilize reloptions test, again. 2022-01-20 23:27:24 +13:00
replica_identity.out Allow REPLICA IDENTITY to be set on an index that's not (yet) valid. 2023-01-21 13:10:29 -05:00
returning.out
roleattributes.out Remove WITH OIDS support, change oid catalog column visibility. 2018-11-20 16:00:17 -08:00
rowsecurity.out Handle RLS dependencies in inlined set-returning functions properly. 2023-05-08 10:12:44 -04:00
rowtypes.out Track nesting depth correctly when drilling down into RECORD Vars. 2023-09-15 17:01:26 -04:00
rules.out Fix mishandling of OLD/NEW references in subqueries in rule actions. 2023-02-25 14:44:49 +00:00
sanity_check.out Add table to regression tests for binary-compatibility checks in pg_upgrade 2021-11-18 10:37:25 +09:00
security_label.out
select.out Fix core dump in transformValuesClause when there are no columns. 2022-05-09 14:15:37 -04:00
select_distinct.out Disk-based Hash Aggregation. 2020-03-18 15:42:02 -07:00
select_distinct_on.out
select_having.out
select_having_1.out
select_having_2.out
select_implicit.out Remove gratuitous uses of deprecated SELECT INTO 2021-01-28 14:28:41 +01:00
select_implicit_1.out Remove gratuitous uses of deprecated SELECT INTO 2021-01-28 14:28:41 +01:00
select_implicit_2.out Remove gratuitous uses of deprecated SELECT INTO 2021-01-28 14:28:41 +01:00
select_into.out Sanitize IF NOT EXISTS in EXPLAIN for CTAS and matviews 2020-12-30 21:23:24 +09:00
select_parallel.out Add proper regression test for the recent SRFs-in-pathkeys problem. 2022-08-04 11:11:22 -04:00
select_views.out Add text-vs-name cross-type operators, and unify name_ops with text_ops. 2018-12-19 17:46:25 -05:00
sequence.out Added relation name in error messages for constraint checks. 2020-01-28 07:48:10 +05:30
spgist.out Fix SP-GiST scan initialization logic for binary-compatible cases. 2021-11-20 14:29:56 -05:00
stats.out Fix NULL input behaviour of pg_stat_get_replication_slot(). 2022-03-27 21:44:39 -07:00
stats_ext.out Fix handling of bare boolean expressions in mcv_get_match_bitmap. 2022-08-05 15:00:03 -04:00
strings.out Avoid fetching one past the end of translate()'s "to" parameter. 2023-03-01 11:30:17 -05:00
subscription.out Fix error handling in libpqrcv_connect() 2023-01-23 18:27:48 -08:00
subselect.out Teach hash_ok_operator() that record_eq is only sometimes hashable. 2022-01-16 16:39:26 -05:00
sysviews.out Fix memory overrun when querying pg_stat_slru 2021-11-12 21:50:04 +09:00
tablesample.out Further adjust EXPLAIN's choices of table alias names. 2019-12-11 17:05:18 -05:00
temp.out Ensure we have a snapshot while dropping ON COMMIT DROP temp tables. 2023-10-16 14:06:11 -04:00
text.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
tid.out Remove catalog function currtid() 2020-11-25 12:18:26 +09:00
tidrangescan.out Add TID Range Scans to support efficient scanning ranges of TIDs 2021-02-27 22:59:36 +13:00
tidscan.out Fix bug in Tid scan. 2020-02-07 22:06:31 +09:00
time.out Change return type of EXTRACT to numeric 2021-04-06 07:20:42 +02:00
timestamp.out Revert "Disallow infinite endpoints in generate_series() for timestamps." 2022-05-09 11:40:40 -04:00
timestamptz.out Revert "Disallow infinite endpoints in generate_series() for timestamps." 2022-05-09 11:40:40 -04:00
timetz.out Back-patch test cases for timetz_zone/timetz_izone. 2023-10-17 13:55:45 -04:00
transactions.out Fix COMMIT/ROLLBACK AND CHAIN in the presence of subtransactions. 2023-09-21 23:11:31 -04:00
triggers.out Fix another issue with ENABLE/DISABLE TRIGGER on partitioned tables. 2023-04-05 12:56:30 -04:00
truncate.out Fix TRUNCATE .. CASCADE on partitions 2020-02-07 17:09:36 -03:00
tsdicts.out Preserve integer and float values accurately in (de)serialize_deflist. 2020-03-10 12:30:02 -04:00
tsearch.out Stabilize just-added regression test cases. 2023-04-06 18:14:08 -04:00
tsrf.out Fix handling of targetlist SRFs when scan/join relation is known empty. 2019-03-07 14:22:13 -05:00
tstypes.out Fix assorted bugs by changing TS_execute's callback API to ternary logic. 2020-07-24 15:26:51 -04:00
tuplesort.out Fix some typos, grammar and style in docs and comments 2021-02-24 16:13:17 +09:00
txid.out Introduce xid8-based functions to replace txid_XXX. 2020-04-07 12:04:32 +12:00
type_sanity.out Fix quoting of ACL item in table for upgrade binary compatibility checks 2021-11-18 12:52:56 +09:00
typed_table.out Suppress less info in regression tests using DROP CASCADE. 2017-08-01 16:49:23 -04:00
unicode.out Fix buffer overrun in unicode string normalization with empty input 2021-11-11 15:01:45 +09:00
unicode_1.out Add SQL functions for Unicode normalization 2020-04-02 08:56:27 +02:00
union.out Disable anonymous record hash support except in special cases 2021-09-08 09:55:18 +02:00
updatable_views.out Correctly update hasSubLinks while mutating a rule action. 2023-06-13 15:58:37 -04:00
update.out Fix mishandling of resjunk columns in ON CONFLICT ... UPDATE tlists. 2021-05-10 11:02:29 -04:00
uuid.out Add gen_random_uuid function 2019-07-14 14:30:27 +02:00
vacuum.out Try to stabilize vacuum test. 2022-03-23 15:06:59 +13:00
vacuum_parallel.out Don't overlook indexes during parallel VACUUM. 2021-11-02 12:06:16 -07:00
varchar.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
varchar_1.out Clean up ancient test style 2020-12-15 22:03:39 +01:00
varchar_2.out Fix varchar_2.out to match reality in cs_CZ locale. 2020-12-15 21:42:08 -05:00
window.out Declare lead() and lag() using anycompatible not anyelement. 2020-11-04 15:08:37 -05:00
with.out Fix inability to reference CYCLE column from inside its CTE. 2022-12-16 13:07:42 -05:00
write_parallel.out Enable parallelism in REFRESH MATERIALIZED VIEW. 2021-03-17 15:04:17 +13:00
xid.out Introduce xid8-based functions to replace txid_XXX. 2020-04-07 12:04:32 +12:00
xml.out Check column list length in XMLTABLE/JSON_TABLE alias 2022-05-18 20:28:31 +02:00
xml_1.out Update xml_1.out and xml_2.out 2022-05-18 23:19:53 +02:00
xml_2.out Update xml_1.out and xml_2.out 2022-05-18 23:19:53 +02:00
xmlmap.out Fix incorrect xmlschema output for types timetz and timestamptz. 2022-03-18 16:01:42 -04:00
xmlmap_1.out Fix incorrect xmlschema output for types timetz and timestamptz. 2022-03-18 16:01:42 -04:00