summaryrefslogtreecommitdiff
path: root/src/backend/libpq/auth.c
AgeCommit message (Collapse)Author
2002-09-04Guard against send-lots-and-lots-of-data DoS attack from unauthenticatedTom Lane
users, by limiting the length of string we will accept for a password. Patch by Serguei Mokhov, some editorializing by Tom Lane.
2002-09-04pgindent run.Bruce Momjian
2002-09-02Remove sys/types.h in files that include postgres.h, and hence c.h,Bruce Momjian
because c.h has sys/types.h.
2002-08-30Back out password packet length check.Bruce Momjian
Improve wording of pre-7.3 syntax mention.
2002-08-29Prevent problem with extra-long password packets from allocating lots ofBruce Momjian
memory. Neil Conway
2002-08-29Remove support for version-0 FE/BE protocol, per pghackers discussion.Tom Lane
This breaks support for 6.2 or older client libraries.
2002-08-27The attached patch implements the password packet length sanity checkBruce Momjian
(using an elog(LOG) ), as well as includes a few more comment fixes. Neil Conway
2002-08-27Add most of Neil Conway's cleanups.Bruce Momjian
2002-08-18Add db-local user names, per discussion on hackers.Bruce Momjian
2002-06-20Update copyright to 2002.Bruce Momjian
2002-05-05Create an internal semaphore API that is not tied to SysV semaphores.Tom Lane
As proof of concept, provide an alternate implementation based on POSIX semaphores. Also push the SysV shared-memory implementation into a separate file so that it can be replaced conveniently.
2002-04-04Authentication improvements:Bruce Momjian
A new pg_hba.conf column, USER Allow specifiction of lists of users separated by commas Allow group names specified by + Allow include files containing lists of users specified by @ Allow lists of databases, and database files Allow samegroup in database column to match group name matching dbname Removal of secondary password files Remove pg_passwd utility Lots of code cleanup in user.c and hba.c New data/global/pg_pwd format New data/global/pg_group file
2002-03-05 Prevent failed passwords from being echoed to server logs, for security.Bruce Momjian
2002-03-05Prevent failed passwords from being echoed to server logs, for security.Bruce Momjian
2002-03-04Further work on elog cleanup: fix some bogosities in elog's logic aboutTom Lane
when to send what to which, prevent recursion by introducing new COMMERROR elog level for client-communication problems, get rid of direct writes to stderr in backend/libpq files, prevent non-error elogs from going to client during the authentication cycle.
2002-03-02Commit to match discussed elog() changes. Only update is that LOG isBruce Momjian
now just below FATAL in server_min_messages. Added more text to highlight ordering difference between it and client_min_messages. --------------------------------------------------------------------------- REALLYFATAL => PANIC STOP => PANIC New INFO level the prints to client by default New LOG level the prints to server log by default Cause VACUUM information to print only to the client NOTICE => INFO where purely information messages are sent DEBUG => LOG for purely server status messages DEBUG removed, kept as backward compatible DEBUG5, DEBUG4, DEBUG3, DEBUG2, DEBUG1 added DebugLvl removed in favor of new DEBUG[1-5] symbols New server_min_messages GUC parameter with values: DEBUG[5-1], INFO, NOTICE, ERROR, LOG, FATAL, PANIC New client_min_messages GUC parameter with values: DEBUG[5-1], LOG, INFO, NOTICE, ERROR, FATAL, PANIC Server startup now logged with LOG instead of DEBUG Remove debug_level GUC parameter elog() numbers now start at 10 Add test to print error message if older elog() values are passed to elog() Bootstrap mode now has a -d that requires an argument, like postmaster
2002-02-25Fix for PAM error message display:Bruce Momjian
> and that the right fix is to make each of the subsequent calls be in > this same pattern, not to try to emulate their nonsensical style. Dominic J. Eidson
2002-02-23Heimdal support (Kerberos V implementation from KTH)Peter Eisentraut
2002-02-19Avoid calling pq_flush just after sending AUTH_REQ_OK; this saves oneTom Lane
send() and probable process context swap during backend startup.
2001-11-05New pgindent run with fixes suggested by Tom. Patch manually reviewed,Bruce Momjian
initdb/regression tests pass.
2001-10-28Another pgindent run. Fixes enum indenting, and improves #endifBruce Momjian
spacing. Also adds space for one-line comments.
2001-10-25pgindent run on all C files. Java run to follow. initdb/regressionBruce Momjian
tests pass.
2001-10-18Fix authentication so that it doesn't record an extra 'PasswordTom Lane
authentication failed' and a 'send() failed: Broken pipe' message on every connection from psql in password auth mode. Problem is that psql doesn't ask user for a password until it sees a password challenge failure, and libpq just closes the connection unceremoniously if it's challenged for a password when it hasn't got one to send. Accordingly, EOF from the client after asking for a password is normal behavior and should not result in postmaster log entries.
2001-09-26Disable local creds on OpenBSD because it doesn't support it. DocumentBruce Momjian
supported platforms in pg_hba.conf.
2001-09-21Code review for MD5 authorization patch. Clean up some breakageTom Lane
(salts were always zero!?), add much missing documentation.
2001-09-07Update SCM_CREDS for Net/Free/BSD-OS. Add configure checks.Bruce Momjian
2001-09-06PAM authentication:Bruce Momjian
> pam_strerror() should be used a few more times, rather than just saying > "Error!". Also, the configure.in snippet seems wrong. You add > -I$pam_prefix/include/security to $INCLUDES and then you #include > <security/pam_appl.h>. This whole thing is probably unnecessary, since > PAM is a system library on the systems where it exists, so the headers > and libraries are found automatically, unlike OpenSSL and > Kerberos. See attached revised patch. (I'm sure the configure.in stuff can be done right/better, I'm just not enough of a autoconf guru to know what to change it to.) Dominic J. Eidson
2001-08-21Add missing include for SCM_CREDS.Bruce Momjian
2001-08-21Add SCM_CREDS to get owner of unix-domain socket on BSD-like systems.Bruce Momjian
2001-08-17A little more code reorg for MD5/crypt.Bruce Momjian
2001-08-17Reorder MD5/crypt so MD5 comes first in the code.Bruce Momjian
2001-08-17Add 4-byte MD5 salt.Bruce Momjian
2001-08-16Add new MD5 pg_hba.conf keyword. Prevent fallback to crypt.Bruce Momjian
2001-08-16Remove protocol version change. Try MD5 first, then crypt() on all clients.Bruce Momjian
2001-08-15Use MD5 for wire protocol encryption for >= 7.2 client/server.Bruce Momjian
Allow pg_shadow to be MD5 encrypted. Add ENCRYPTED/UNENCRYPTED option to CREATE/ALTER user. Add password_encryption postgresql.conf option. Update wire protocol version to 2.1.
2001-08-07Add a check for end of client connection before expecting a passwordPeter Eisentraut
response, to avoid noise in the server log.
2001-08-01Support ident authentication on local (Unix) socket connections, if theTom Lane
system supports SO_PEERCRED requests for Unix sockets. This is an amalgamation of patches submitted by Helge Bahmann and Oliver Elphick, with some editorializing by yours truly.
2001-07-21Source formatting cleanup.Bruce Momjian
2001-06-20Handle reading of startup packet and authentication exchange after forkingPeter Eisentraut
a new postmaster child process. This should eliminate problems with authentication blocking (e.g., ident, SSL init) and also reduce problems with the accept queue filling up under heavy load. The option to send elog output to a different file per backend (postgres -o) has been disabled for now because the initialization would have to happen in a different order and it's not clear we want to keep this anyway.
2001-03-22pgindent run. Make it all clean.Bruce Momjian
2001-01-24Change Copyright from PostgreSQL, Inc to PostgreSQL Global Development Group.Bruce Momjian
2000-12-03Ensure that all uses of <ctype.h> functions are applied to unsigned-charTom Lane
values, whether the local char type is signed or not. This is necessary for portability. Per discussion on pghackers around 9/16/00.
2000-08-25Make the location of the Kerberos server key file run time configurablePeter Eisentraut
(rather than compile time). For libpq, even when Kerberos support is compiled in, the default user name should still fall back to geteuid() if it can't be determined via the Kerberos system. A couple of fixes for string type configuration parameters, now that there is one.
2000-07-04Expand secondary password file feature, so that you can use thesePeter Eisentraut
files to restrict the set of users that can connect to a database but can still use the pg_shadow password. (You just leave off the password field in the secondary file.)
2000-05-27Update kerberos patchBruce Momjian
2000-05-27Back out kerberos changes. Causes compile problems.Bruce Momjian
2000-05-27Patch for Kerberos V.Bruce Momjian
Most (nearly all) of the work was done by David Wragg <dpw@doc.ic.ac.uk> He patched 6.5.3. I've updated it for 7.0RC5. It works for MIT kerberos 1.1.1 (and previously for 1.0.6 as well). I've got the patch against 6.5.3, plus kerberized RPMS. Mike Wyer <mw@doc.ic.ac.uk> || "Woof?"
2000-04-12Ye-old pgindent run. Same 4-space tabs.Bruce Momjian
2000-01-26Add:Bruce Momjian
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc to all files copyright Regents of Berkeley. Man, that's a lot of files.
1999-10-23Look Ma, no MAX_PARSE_BUFFER! (At least not in the backend.Tom Lane
pg_dump and interfaces/odbc still need some work.)