BUG #18626: Using ampersand (&) in password fails installation.

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: tomnies(dot)conclusion(at)gmail(dot)com
Subject: BUG #18626: Using ampersand (&) in password fails installation.
Date: 2024-09-20 13:02:15
Message-ID: 18626-c7b1842bdd5debb1@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 18626
Logged by: Tom Nies
Email address: tomnies(dot)conclusion(at)gmail(dot)com
PostgreSQL version: 17rc1
Operating system: Windows
Description:

Hello. This week I installed Postgres 17.RC1 from this website
https://www.enterprisedb.com/downloads/postgres-postgresql-downloads.
During the installation I was asked for a password. I created a random
password with my password manager and used it. The installation failed.
I tried the installation of multiple postgres versions (17.RC1, 16.4 and
13.16) and every time during installation when a password was requested, I
entered the password I already generated in my password manager. The
installation failed every time.

Here are some of the error messages I got:
"Error stating service postgresql-x64-13"
"Failed to load SQL modules into the database cluster."
"Problem running post-install step. Installation may not complete correctly.
Error reading file C:/Program Files/PostgreSQL/13/data/postgresql.conf".

After a lot of searching online I found the following comment on
stackexchange:
"I know the one-click installer breaks (or used to break) with passwords
that have an ampersand in them."
https://dba.stackexchange.com/a/42677

I checked my password manager and my password indeed contained an ampersand
(&). I changed my password to a password with only letters and numbers.
Then, I reinstalled the last version I downloaded (13.16), used the new
password and the installation succeeded. Which leads me to believe the
comment on stackexchange was true and the ampersand resulted in a failed
installation.

I expected the installer to give me a warning or message that an ampersand
should not be used in the password if this results in a crash, but this was
not the case. If some characters are not allowed in passwords, it would be
great if the passwords were not accepted or at least a warning message is
shown.

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2024-09-20 14:16:32 Re: BUG #18625: user-created extensions change ownership to "postgres" after upgrade
Previous Message PG Bug reporting form 2024-09-20 12:42:37 BUG #18625: user-created extensions change ownership to "postgres" after upgrade