Re: Better auth errors from libpq - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Better auth errors from libpq
Date
Msg-id 23264.1221188380@sss.pgh.pa.us
Whole thread Raw
In response to Better auth errors from libpq  (David Fetter <david@fetter.org>)
Responses Re: Better auth errors from libpq  (Joshua Drake <jd@commandprompt.com>)
List pgsql-hackers
David Fetter <david@fetter.org> writes:
> This isn't exactly informative to newbies, so I'm proposing a patch
> like that attached for such failures.  Instead of seeing that
> mysterious message, they'd get something like this:

>     psql: FATAL:  Ident authentication failed for user "root"
>     HINT:  Is pg_hba.conf set properly on the server?

Seems pretty useless.  What does "set properly" mean?  There isn't even
any good reason to think that the solution to most auth failures is to
change pg_hba.conf, so I'd bet that this hint is wrong far more often
than it's right.

You have to recall also that we deliberately suppress details in auth
failure messages sent to the client, since they might provide useful
clues to someone trying to break in.  Admittedly, the above is so
content-free that it gives no aid or comfort to an attacker, but
I don't see that it provides any to a novice DBA either.
        regards, tom lane


pgsql-hackers by date:

Previous
From: David Fetter
Date:
Subject: Better auth errors from libpq
Next
From: Joshua Drake
Date:
Subject: Re: Better auth errors from libpq