When reviewing the details for the admin user in pgAdmin, an expiration date was set on the user, that was in the past, in this case January 1st 1970.
Logged into the database as the postgres user, this expiry could be seen:
In your database connection, select Login Roles > admin
In the SQL pane, you may see something like this
CREATE ROLE admin LOGIN
ENCRYPTED PASSWORD 'md57f5ae921aecd378486da929310909c8c'
NOSUPERUSER INHERIT NOCREATEDB NOCREATEROLE NOREPLICATION VALID UNTIL '1970-01-01 00:00:00';
Note the VALID UNTIL restriction with a past date, this is causing the connection failure.
In Login Roles > admin, right-click on Properties and in the Definition tab, the Account expires value will be checked with a date.
2) psql command line
Login - psql -u postgres -d cemdb
cemdb=# SELECT rolname,rolvaliduntil from pg_roles;
rolname | rolvaliduntil
admin | 1970-01-01 00:00:00+01
Note that admin user has a date in the past in rolvaliduntil