diff options
| author | Bruce Momjian <bruce@momjian.us> | 1997-08-25 19:41:52 +0000 |
|---|---|---|
| committer | Bruce Momjian <bruce@momjian.us> | 1997-08-25 19:41:52 +0000 |
| commit | f8fda03d12971361781546e3f74d1a703d1841c3 (patch) | |
| tree | 209bf2f4f47f623a4011f23ee5632cda2f4d6891 /README | |
| parent | 8d0e658d06bf73ae45db0a4e3912a355605b949a (diff) | |
| download | postgresql-f8fda03d12971361781546e3f74d1a703d1841c3.tar.gz | |
pg_password utility. Cleanup for psql passwords. New datetime contrib stuff for new version. Fix for strutils needing config.h.
Diffstat (limited to 'README')
| -rw-r--r-- | README | 69 |
1 files changed, 69 insertions, 0 deletions
@@ -1,3 +1,72 @@ +The pathces and a prototype tool to manipulate the ``flat password file +'' functionality of PostgreSQL6.1 +1. File +Makefile +pg_passwd.c the source file of the tool. +2. How to specify pasword files and their format. +Specify the password file in the same style of Ident authentication in +$PGDATA/pg_hba.conf +host unv 133.65.96.250 255.255.255.255 password passwd +The above line allows access from 133.65.96.250 using the passwords listed +in $PGDATA/passwd. +The format of the password files follows those of /etc/passwd and +/etc/shadow: the first field is the user name, and the second field +is the encrypted password. The rest is completely ignored. Thus +the following three sample lines specify the same user and password pair:. +pg_guest:/nB7.w5Auq.BY:10031:::::: +pg_guest:/nB7.w5Auq.BY:93001:930::/home/guest:/bin/tcsh +pg_guest:/nB7.w5Auq.BY:93001 +Note that the original src/backend/libpq/password.c has a bug, which +disallows the first and the second format. If you want to use these +formats, please make sure you've applied the patch accompanied with +this tool. +3. Usage of pg_passwd +Supply the password file to the pg_passwd command. In the case described +above, after ``cd'ing to $PGDATA, the following command execution specify +the new password for pg_guest: +% pg_passwd passwd +Username: pg_guest +Password: +Re-enter password: +where the Password: and Re-enter password: prompts require the same +password input which are not displayed on the terminal. +The original password file is renamed to ``passwd.bk''. +4. How to specify pasasword authentication +You can use the password authentication fro psq, perl, or pg{tcl,tk}sh. +4.1 psql +Use the -u option. Note that the original distribution includes a bug. +Please make sure you've applied the patch distributed with this tool. +The following lines show the sample usage of the option: +% psql -h hyalos -u unv +Username: pg_guest +Password: +Welcome to the POSTGRESQL interactive sql monitor: + Please read the file COPYRIGHT for copyright terms of POSTGRESQL + type \? for help on slash commands + type \q to quit + type \g or terminate with semicolon to execute query + You are currently connected to the database: unv +unv=> +4.2 perl5 +Use the new style of the Pg.pm like this +$conn = Pg::connectdb("host=hyalos authtype=password dbname=unv + user=pg_guest password=xxxxxxx"); +For more details, the users refer to to ``src/pgsql_perl5/Pg.pm''. +4.3 pg{tcl,tk}sh +Use the pg_connect comamnd with -conninfo option thus +% set conn [pg_connect -conninfo \ + "host=hyalos authtype=password dbname=unv \ + user=pg_guest password=xxxxxxx "] +Use can list all of the keys for the option by executing the following +command: +% puts [ pg_conndefaults] +5. Acknowledgment +Mr. Ishii, SRA, pointed out the original bugs in the tool. He also +supplied the Makefile for this distribution. +------------------------------------------------------------------------- +July 2, 1997 +Yoshihiko Ichikawa, Dept of Info Sci, Fac of Sci, Ochanomizu University +E-mail: ichikawa@is.ocha.ac.jp PostgreSQL Data Base Management System (formerly known as Postgres, then as Postgres95). |
