Time to get rid of PQnoPasswordSupplied?

Поиск
Список
Период
Сортировка
От Craig Ringer
Тема Time to get rid of PQnoPasswordSupplied?
Дата
Msg-id CAMsr+YEWG22T6fGFc_9dPpcYRL13-h7AsUymzbzYFj0RgC35Og@mail.gmail.com
обсуждение исходный текст
Ответы Re: Time to get rid of PQnoPasswordSupplied?
Список pgsql-hackers
Hi all

I frequently see users confused by one of our more common and less
clear error messages:
   fe_sendauth: no password supplied

What this really means is that the server requested a password for md5
or cleartext authentication but no password was supplied to the client
and it cannot prompt for one in this context.

I'd like to get rid of it. It's clear others have wanted to in the
past, since it's a backward compat #define in libpq-fe.h :

/* Error when no password was given. */
/* Note: depending on this is deprecated; use PQconnectionNeedsPassword(). */
#define PQnoPasswordSupplied    "fe_sendauth: no password supplied\n"

but given the git blame for it:

4f9bf7fc (Tom Lane           2007-12-09 19:01:40 +0000 493) /* Note:
depending on this is deprecated; use PQconnectionNeedsPassword(). */

88fd162e (Bruce Momjian      2004-10-16 03:10:17 +0000 494) #define
PQnoPasswordSupplied        "fe_sendauth: no password supplied\n"

I'm wondering if it's time for this to go away, so we can have a
decent error message for this common error. It's been deprecated for
eight years.

How about:

"The server requested a password but no password was supplied to the client"

?

I'm sure it can be better than that, but ... well, it's not
"fe_sendauth: no password supplied".


-- Craig Ringer                   http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training & Services



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: creating extension including dependencies
Следующее
От: Craig Ringer
Дата:
Сообщение: Re: Moving Pivotal's Greenplum work upstream