Nmap Development mailing list archives

Re: Nsock new engines


From: Rob Nicholls <robert () robnicholls co uk>
Date: Mon, 22 Oct 2012 14:58:38 +0100

On 22.10.2012 00:37, Henri Doreau wrote:
I've tested these new engines as much as possible, but I couldn't test all the platforms that benefit the changes. Testing and feedback would
be much appreciated.

Hi Henri,

I've just tried running TCP and UDP scans on Windows and this seems to work fine* with select, but dies with poll (which is the new Windows default engine, by the look of things):

UDP against one host:

Initiating UDP Scan at 14:31
Scanning xxx.xxxxxx.xxx (xxx.xxx.xxx.xxx) [101 ports]
Packet capture filter (device eth2): dst host 195.66.81.20 and (icmp or icmp6 or ((tcp or udp or sctp) and (src host xxx.xxx.xxx.xxx)))
Stats: 0:00:24 elapsed; 0 hosts completed (1 up), 1 undergoing UDP Scan
UDP Scan Timing: About 99.99% done; ETC: 14:32 (0:00:00 remaining)
Current sending rates: 6.74 packets / s, 178.57 bytes / s.
Completed UDP Scan at 14:32, 23.22s elapsed (101 total ports)
Overall sending rates: 8.70 packets / s, 261.27 bytes / s.
Fetchfile found C:\Program Files\Nmap/nmap-service-probes
Initiating Service scan at 14:32
Scanning 101 services on xxx.xxxxxx.xxx (xxx.xxx.xxx.xxx)
Service scan: Not probing some ports due to low intensity
Starting probes against new service: xxx.xxx.xxx.xxx:111 (udp)
Starting probes against new service: xxx.xxx.xxx.xxx:123 (udp)
Starting probes against new service: xxx.xxx.xxx.xxx:135 (udp)
Starting probes against new service: xxx.xxx.xxx.xxx:137 (udp)
Starting probes against new service: xxx.xxx.xxx.xxx:161 (udp)
Starting probes against new service: xxx.xxx.xxx.xxx:177 (udp)
NSOCK (-2001960.5670s) nsock_loop error 10022: An invalid argument was supplied.

TCP against a pair of hosts:

Initiating Service scan at 14:42
Scanning 9 services on 2 hosts
NSOCK (6.4850s) nsi_new (IOD #1)
Starting probes against new service: xxx.xxx.xxx.xxx:80 (tcp)
NSOCK (6.4870s) TCP connection requested to xxx.xxx.xxx.xxx:80 (IOD #1) EID 8
NSOCK (6.4870s) nsi_new (IOD #2)
Starting probes against new service: xxx.xxx.xxx.xxx:443 (tcp)
NSOCK (6.4890s) TCP connection requested to xxx.xxx.xxx.xxx:443 (IOD #2) EID 16
NSOCK (6.4890s) nsi_new (IOD #3)
Starting probes against new service: xxx.xxx.xxx.xxx:3389 (tcp)
NSOCK (6.4920s) TCP connection requested to xxx.xxx.xxx.xxx:3389 (IOD #3) EID 24
NSOCK (6.4920s) nsi_new (IOD #4)
Starting probes against new service: xxx.xxx.xxx.xxx:25 (tcp)
NSOCK (6.4950s) TCP connection requested to xxx.xxx.xxx.xxx:25 (IOD #4) EID 32
NSOCK (6.4950s) nsi_new (IOD #5)
Starting probes against new service: xxx.xxx.xxx.xxx:53 (tcp)
NSOCK (6.4990s) TCP connection requested to xxx.xxx.xxx.xxx:53 (IOD #5) EID 40
NSOCK (6.4990s) nsi_new (IOD #6)
Starting probes against new service: xxx.xxx.xxx.xxx:110 (tcp)
NSOCK (6.5020s) TCP connection requested to xxx.xxx.xxx.xxx:110 (IOD #6) EID 48
NSOCK (6.5020s) nsi_new (IOD #7)
Starting probes against new service: xxx.xxx.xxx.xxx:465 (tcp)
NSOCK (6.5050s) TCP connection requested to xxx.xxx.xxx.xxx:465 (IOD #7) EID 56
NSOCK (6.5050s) nsi_new (IOD #8)
Starting probes against new service: xxx.xxx.xxx.xxx:995 (tcp)
NSOCK (6.5090s) TCP connection requested to xxx.xxx.xxx.xxx:995 (IOD #8) EID 64
NSOCK (6.5090s) nsi_new (IOD #9)
Starting probes against new service: xxx.xxx.xxx.xxx:3389 (tcp)
NSOCK (6.5120s) TCP connection requested to xxx.xxx.xxx.xxx:3389 (IOD #9) EID 72 NSOCK (6.5140s) nsock_loop error 10022: An invalid argument was supplied.
Unexpected nsock_loop error.  Error code 10022 (Unknown error)
QUITTING!

It appears to die at the "Service scan sending probe" point.

Running the UDP scan with -d9 gives me:

Initiating Service scan at 14:36
Scanning 101 services on xxx.xxxxxx.xxx (xxx.xxx.xxx.xxx)
Service scan: Not probing some ports due to low intensity
NSOCK (25.0850s) nsi_new (IOD #1)
Starting probes against new service: xxx.xxx.xxx.xxx:111 (udp)
NSOCK (25.0980s) UDP connection requested to xxx.xxx.xxx.xxx:111 (IOD #1) EID 8
NSOCK (25.0980s) nsi_new (IOD #2)
Starting probes against new service: xxx.xxx.xxx.xxx:123 (udp)
NSOCK (25.1020s) UDP connection requested to xxx.xxx.xxx.xxx:123 (IOD #2) EID 16
NSOCK (25.1020s) nsi_new (IOD #3)
Starting probes against new service: xxx.xxx.xxx.xxx:135 (udp)
NSOCK (25.1050s) UDP connection requested to xxx.xxx.xxx.xxx:135 (IOD #3) EID 24
NSOCK (25.1050s) nsi_new (IOD #4)
Starting probes against new service: xxx.xxx.xxx.xxx:137 (udp)
NSOCK (25.1080s) UDP connection requested to xxx.xxx.xxx.xxx:137 (IOD #4) EID 32
NSOCK (25.1080s) nsi_new (IOD #5)
Starting probes against new service: xxx.xxx.xxx.xxx:161 (udp)
NSOCK (25.1120s) UDP connection requested to xxx.xxx.xxx.xxx:161 (IOD #5) EID 40
NSOCK (25.1120s) nsi_new (IOD #6)
Starting probes against new service: xxx.xxx.xxx.xxx:177 (udp)
NSOCK (25.1150s) UDP connection requested to xxx.xxx.xxx.xxx:177 (IOD #6) EID 48 NSOCK (25.1180s) nsock_loop error 10022: An invalid argument was supplied.
Unexpected nsock_loop error.  Error code 10022 (Unknown error)
QUITTING!

And for TCP I get:

Initiating Service scan at 14:56
Scanning 9 services on 2 hosts
NSOCK (4.9290s) nsi_new (IOD #1)
Starting probes against new service: xxx.xxx.xxx.xxx:80 (tcp)
NSOCK (4.9310s) TCP connection requested to xxx.xxx.xxx.xxx:80 (IOD #1) EID 8
NSOCK (4.9310s) nsi_new (IOD #2)
Starting probes against new service: xxx.xxx.xxx.xxx:443 (tcp)
NSOCK (4.9350s) TCP connection requested to xxx.xxx.xxx.xxx:443 (IOD #2) EID 16
NSOCK (4.9350s) nsi_new (IOD #3)
Starting probes against new service: xxx.xxx.xxx.xxx:3389 (tcp)
NSOCK (4.9390s) TCP connection requested to xxx.xxx.xxx.xxx:3389 (IOD #3) EID 24
NSOCK (4.9390s) nsi_new (IOD #4)
Starting probes against new service: xxx.xxx.xxx.xxx:25 (tcp)
NSOCK (4.9410s) TCP connection requested to xxx.xxx.xxx.xxx:25 (IOD #4) EID 32
NSOCK (4.9410s) nsi_new (IOD #5)
Starting probes against new service: xxx.xxx.xxx.xxx:53 (tcp)
NSOCK (4.9450s) TCP connection requested to xxx.xxx.xxx.xxx:53 (IOD #5) EID 40
NSOCK (4.9450s) nsi_new (IOD #6)
Starting probes against new service: xxx.xxx.xxx.xxx:110 (tcp)
NSOCK (4.9490s) TCP connection requested to xxx.xxx.xxx.xxx:110 (IOD #6) EID 48
NSOCK (4.9490s) nsi_new (IOD #7)
Starting probes against new service: xxx.xxx.xxx.xxx:465 (tcp)
NSOCK (4.9520s) TCP connection requested to xxx.xxx.xxx.xxx:465 (IOD #7) EID 56
NSOCK (4.9520s) nsi_new (IOD #8)
Starting probes against new service: xxx.xxx.xxx.xxx:995 (tcp)
NSOCK (4.9560s) TCP connection requested to xxx.xxx.xxx.xxx:995 (IOD #8) EID 64
NSOCK (4.9560s) nsi_new (IOD #9)
Starting probes against new service: xxx.xxx.xxx.xxx:3389 (tcp)
NSOCK (4.9590s) TCP connection requested to xxx.xxx.xxx.xxx:3389 (IOD #9) EID 72 NSOCK (4.9610s) nsock_loop error 10022: An invalid argument was supplied.
Unexpected nsock_loop error.  Error code 10022 (Unknown error)
QUITTING!

Hope that helps! If you need me to run anything specific, let me know.


*I'm ignoring an unrelated UDP issue that David and I are already aware of.

Rob

_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


Current thread: