View Issue Details

IDProjectCategoryView StatusLast Update
0000427Pgpool-IIBugpublic2018-09-11 13:26
Reportert-ishiiAssigned ToMuhammad Usama 
Status resolvedResolutionopen 
Product Version4.0 alpha1 
Target Version4.0 alpha2Fixed in Version4.0 alpha2 
Summary0000427: pg_enc emits wrong warnings
DescriptionFollowing message emitted even if .pgpoolkey is a regular text file.
pg_enc WARNING: pid 22664: pool key file "/home/t-ishii/.pgpoolkey" is not a text file

This is due to the wrong coding in pool_passwd.c:

    /* If password file is insecure, alert the user. */
    if (stat_buf.st_mode & (S_IRWXG | S_IRWXO))
                (errmsg("pool key file \"%s\" is not a text file\n", key_file_path))); <--- not necessary

                (errmsg("pool key file \"%s\" has group or world access; permissions should be u=rw (0600) or less\n",
        /* do we want to allow unsecure pool key file ? */
        /* return NULL; */

Also I think the message in:
    if (!S_ISREG(stat_buf.st_mode))
                (errmsg("pool key file \"%s\" is not a text file\n", key_file_path)));
        return NULL;

is not correct since S_ISREG checks whether given file is a *regular* file, rather than a text file.
TagsNo tags attached.


There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2018-08-21 16:53 t-ishii New Issue
2018-08-27 15:30 t-ishii Note Added: 0002176
2018-08-27 18:05 t-ishii Note Edited: 0002176 View Revisions
2018-08-27 18:05 t-ishii Assigned To => Muhammad Usama
2018-08-27 18:05 t-ishii Status new => assigned
2018-08-27 18:07 t-ishii Target Version => 4.0 alpha2
2018-09-11 13:26 t-ishii Status assigned => resolved
2018-09-11 13:26 t-ishii Fixed in Version => 4.0 alpha2