Re: [Exim] RLIMIT_NOFILE problem (should be FD_SETSIZE not 1…

Top Page
Delete this message
Reply to this message
Author: J. Nick Koston
Date:  
To: exim-users
CC: michael
Subject: Re: [Exim] RLIMIT_NOFILE problem (should be FD_SETSIZE not 1000)
>> exim 4.20 sets RLIMIT_NOFILE to 1000 in src/exim.c line 2371
>> This can cause problems if exim is spawned from a webserver running php> which has > 1000 fds open (log files etc).   This is pretty common on> machines running lots of virtual hosts.    This really should be set to> FD_SETSIZE and not 1000.
>Note that FD_SETSIZE is specific to select().  PHP allows access to its
>logs by spawned programs? Shouldn't it close those descriptors?

Yes, it should, but thats another problem which I've already taken up with php, and yes I was able to write a nice little exploit for this.
>
>I would like Exim only to increase the set of descriptors, though.
>If the available descriptors are >1000, why lower them?

I think the idea was to make the env sane if its not. But it really doesn't check if its already sane, it just sets it.

>
>Michael

--
J. Nick Koston <nick@???>
cPanel, Inc.