Re: [BUGS] More SSL questions.. - Mailing list pgsql-hackers-win32

From Tom Lane
Subject Re: [BUGS] More SSL questions..
Date
Msg-id 9259.1105223199@sss.pgh.pa.us
Whole thread Raw
In response to Re: [BUGS] More SSL questions..  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers-win32
Andrew Dunstan <andrew@dunslane.net> writes:
> Tom Lane wrote:
>> Doh --- isn't fstat's st_ino a meaningless value on Windows?

> Pretty much, yes.

The minimum change to fix it would be to ifdef out the fstat call and
ino/dev test on WIN32.  However, I'm wondering why the code does it that
way in the first place.  The proper way to enforce the security check,
if we're worried about race conditions, is to apply the file
ownership/permissions test to the fstat result.  It's not clear to me
that the stat call before fopen is worth anything at all.  Thoughts?

            regards, tom lane

pgsql-hackers-win32 by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: [BUGS] More SSL questions..
Next
From: "Maricel Ciupitu"
Date:
Subject: Re: RC4 MSI is up...