From: Marc G. Fournier Date: Mon, 23 Feb 1998 20:32:40 +0000 (+0000) Subject: Create a RULE wrapper around pg_user for the password entry X-Git-Tag: REL6_3~78 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=04e3fd770dac22ff5a0d315611d5f1cb246e4ee1;p=thirdparty%2Fpostgresql.git Create a RULE wrapper around pg_user for the password entry --- diff --git a/src/bin/initdb/initdb.sh b/src/bin/initdb/initdb.sh index 9cd1457d2b5..c75a090b487 100644 --- a/src/bin/initdb/initdb.sh +++ b/src/bin/initdb/initdb.sh @@ -26,7 +26,7 @@ # # # IDENTIFICATION -# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.35 1998/02/23 19:26:32 scrappy Exp $ +# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.36 1998/02/23 20:32:40 scrappy Exp $ # #------------------------------------------------------------------------- @@ -358,7 +358,11 @@ echo "COPY pg_user TO '$PGDATA/pg_pwd' USING DELIMITERS '\\t'" |\ echo "GRANT SELECT ON pg_class TO PUBLIC" |\ postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\ -echo "create view db_user as select usename,usesysid from pg_user;" |\ +echo "CREATE RULE pg_user_hide_pw as on SELECT to pg_user.passwd DO INSTEAD SELECT '********' as passwd;" | \ + postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\ + grep -v "'DEBUG:" + +echo "create view db_user as select * from pg_user;" |\ postgres -F -Q -D$PGDATA template1 2>&1 > /dev/null |\ grep -v "'DEBUG:" echo "grant select on db_user to public" |\