Nmap Development mailing list archives

netcat : program bug


From: "Julien Bouquillon [revolunet]" <julien () bouquillon com>
Date: Mon, 5 Apr 2010 17:54:49 +0200

Hi

First ,thanx for your ncat great code; broker/chat modes are really handy
;:)

I dont know if this is a bug or a bad use of ncat from me :

server# ncat -klvvv 30000

client1# telnet server 30000     # ok
client2# telnet server 30000     # ok
client3# telnet server 30000     # ok

if client2 closes the connexion, then client3 closes his connection, i get a
"program bug":

(i use windows telnet as client for my tests)

Ncat: Version 5.21 ( http://nmap.org/ncat )
Ncat: Listening on 0.0.0.0:30000
NCAT DEBUG: Initialized fdlist with 102 maxfds
NCAT DEBUG: Added fd 3 to list, nfds 1, maxfd 3
NCAT DEBUG: Added fd 0 to list, nfds 2, maxfd 3
NCAT DEBUG: Initialized fdlist with 100 maxfds
NCAT DEBUG: selecting, fdmax 3
NCAT DEBUG: select returned 1 fds ready
NCAT DEBUG: fd 3 is ready
Ncat: Connection from 93.0.2.144.
NCAT DEBUG: Added fd 4 to list, nfds 3, maxfd 4
NCAT DEBUG: Added fd 4 to list, nfds 1, maxfd 4
NCAT DEBUG: selecting, fdmax 4
NCAT DEBUG: select returned 1 fds ready
NCAT DEBUG: fd 3 is ready
Ncat: Connection from 93.0.2.144.
NCAT DEBUG: Added fd 5 to list, nfds 4, maxfd 5
NCAT DEBUG: Added fd 5 to list, nfds 2, maxfd 5
NCAT DEBUG: selecting, fdmax 5
NCAT DEBUG: select returned 1 fds ready
NCAT DEBUG: fd 3 is ready
Ncat: Connection from 93.0.2.144.
NCAT DEBUG: Added fd 6 to list, nfds 5, maxfd 6
NCAT DEBUG: Added fd 6 to list, nfds 3, maxfd 6
NCAT DEBUG: selecting, fdmax 6
NCAT DEBUG: select returned 1 fds ready
NCAT DEBUG: fd 5 is ready
NCAT DEBUG: Closing connection.
NCAT DEBUG: Swapping fd[3] (5) with fd[4] (6)
NCAT DEBUG: Removed fd 5 from list, nfds 4, maxfd 6
NCAT DEBUG: Swapping fd[2] (6) with fd[2] (6)
NCAT DEBUG: Removed fd 6 from list, nfds 2, maxfd 5
NCAT DEBUG: selecting, fdmax 6
NCAT DEBUG: select returned 1 fds ready
NCAT DEBUG: fd 6 is ready
NCAT DEBUG: Closing connection.
NCAT DEBUG: Swapping fd[3] (6) with fd[3] (6)
NCAT DEBUG: Removed fd 6 from list, nfds 3, maxfd 4
Ncat: Program bug: fd (6) not on list. QUITTING.

any idea how to prevent this  ?

Thanks


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


Current thread: