mailing list archives
Re: Options to replace select in Nsock
From: David Fifield <david () bamsoftware com>
Date: Sat, 20 Jun 2009 17:28:26 -0600
On Sat, Jun 20, 2009 at 07:20:04PM -0400, Michael Pattrick wrote:
I agree with Doug, a statefull API should be used. He gives some
excellent reasons, as an additional reason, only the latest version of
windows supports Poll while CreateIoCompletionPort has been supported
since windows 2000, so going this route will acutely be more
The problem with the advanced APIs is that they are platform-specific.
So unless we are going to support (and debug, and maintain) all of them,
there still has to be a select/poll fallback. The stateful APIs should
be considered an addition to a select/poll compatibility implementation,
not a replacement for it.
And because select can't handle many descriptors and poll isn't
available everywhere select is, I think we'll need to base the
compatibility implementation on poll, with a fallback to a select-based
implementation of poll for systems without poll. Brandon found an
example of this poll-select fallback.
In the meantime, couldn't Nsock be quickly adapted to use multiple
calls to select with different FD_SET arrays when tracking >
I don't think you can use select that way. Each fd_set is indexed
starting at zero.
Sent through the nmap-dev mailing list
Archived at http://SecLists.Org