The label is written as one line of the backup_label file. A label with a newline added extra lines to the file, and recovery could read those as other fields, failing on them. Characters could also be injected to make recovery behave in inconsistent ways. Trying to use such characters in label names is now rejected, for both pg_backup_start() and BASE_BACKUP. As this is arguably a behavior change, no backpatch is done. I also seriously doubt that anybody is relying on the behavior of pushing some arbitrary data to backup_label files, and even if they do, it would be a very bad idea to contradict what the backend decides to generate. Reported-by: Shallow <theshallow27@gmail.com> Author: Shihao Zhong <zhong950419@gmail.com> Discussion: https://postgr.es/m/19730-85a6044c9e72774a@postgresql.org
PostgreSQL Database Management System
This directory contains the source code distribution of the PostgreSQL database management system.
PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, user-defined types and functions. This distribution also contains C language bindings.
Copyright and license information can be found in the file COPYRIGHT.
General documentation about this version of PostgreSQL can be found at https://www.postgresql.org/docs/devel/. In particular, information about building PostgreSQL from the source code can be found at https://www.postgresql.org/docs/devel/installation.html.
The latest version of this software, and related software, may be obtained at https://www.postgresql.org/download/. For more information look at our web site located at https://www.postgresql.org/.