14 lines
764 B
Diff
14 lines
764 B
Diff
diff -ur postgresql-8.0.15.orig/src/backend/libpq/be-secure.c postgresql-8.0.15/src/backend/libpq/be-secure.c
|
|
--- postgresql-8.0.15.orig/src/backend/libpq/be-secure.c 2008-02-21 04:06:04.334289203 +0100
|
|
+++ postgresql-8.0.15/src/backend/libpq/be-secure.c 2008-02-21 04:08:47.309426324 +0100
|
|
@@ -737,8 +737,8 @@
|
|
* data directory permission check in postmaster.c)
|
|
*/
|
|
#if !defined(WIN32) && !defined(__CYGWIN__)
|
|
- if (!S_ISREG(buf.st_mode) || (buf.st_mode & (S_IRWXG | S_IRWXO)) ||
|
|
- buf.st_uid != geteuid())
|
|
+ if (!S_ISREG(buf.st_mode) || (buf.st_mode & (S_IWGRP | S_IRWXO)) ||
|
|
+ (buf.st_uid != geteuid()) && buf.st_uid != 0)
|
|
ereport(FATAL,
|
|
(errcode(ERRCODE_CONFIG_FILE_ERROR),
|
|
errmsg("unsafe permissions on private key file \"%s\"",
|