In message <[EMAIL PROTECTED]> Marc Slemko 
writes:
: Why does FreeBSD let you create paths longer than MAXPATHLEN?  

Because this is allowed.

: I often have various trees that are as deep as possible for testing various
: programs for holes, and I finally figured out why locate wasn't updating its
: database properly; it was choking as soon as it saw a path length 
: >MAXPATHLEN long.  The question, however, is why can it see a path length
: longer than MAXPATHLEN?

MAXPATHLEN is the longest pathname that the kernel system calls can
handle, but it isn't the longest pathname that can exist especially
due to symbolic links.

: I would also wonder if there aren't some security issues resulting
: from this.  From what gdb shows, locate seems to trash its stack
: before spitting out the error about the path being too long...

That is an error in the program in question.  I do know that the
shells on FreeBSD haven't been well audited for buffer overflows.

Warner


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to