Re: [Full-disclosure] readdir_r considered harmful
From: Ben Hutchings (ben_at_decadentplace.org.uk)
Date: 11/01/05
- Previous message: Eric Auge: "[Full-disclosure] Re: RFID docs & tools ?"
- In reply to: 3APA3A: "Re: [Full-disclosure] readdir_r considered harmful"
- Next in thread: Ben Hutchings: "[Full-disclosure] Re: readdir_r considered harmful"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
To: 3APA3A <3APA3A@SECURITY.NNOV.RU> Date: Tue, 01 Nov 2005 13:02:45 +0000
3APA3A wrote:
> Dear Ben Hutchings,
>
>
> If someone uses pathconf to determine buffer size it's his own problem
> and he creates vulnerability by himself. You can list such applications
> as vulnerable to race conditions.
<snip>
> NAME_MAX is defined in limits.h and should be 255 according to latest
> POSIX extension. I see no problem with POSIX standard in this case.
>
> See:
> http://www.opengroup.org/onlinepubs/009695399/basedefs/limits.h.html
<snip>
If you had read the above page more carefully, you would have seen these
paragraphs:
"The values in the following list may be constants within an
implementation or may vary from one pathname to another. For example,
file systems or directories may have different characteristics.
"A definition of one of the values shall be omitted from the <limits.h>
header on specific implementations where the corresponding value is
equal to or greater than the stated minimum, but where the value can
vary depending on the file to which it is applied. The actual value
supported for a specific pathname shall be provided by the pathconf()
function."
-- Ben Hutchings When you say `I wrote a program that crashed Windows', people just stare ... and say `Hey, I got those with the system, *for free*'. - Linus Torvalds
_______________________________________________
Full-Disclosure - We believe in it.
Charter: http://lists.grok.org.uk/full-disclosure-charter.html
Hosted and sponsored by Secunia - http://secunia.com/
- application/pgp-signature attachment: This is a digitally signed message part
- Previous message: Eric Auge: "[Full-disclosure] Re: RFID docs & tools ?"
- In reply to: 3APA3A: "Re: [Full-disclosure] readdir_r considered harmful"
- Next in thread: Ben Hutchings: "[Full-disclosure] Re: readdir_r considered harmful"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]