Re: Ncat -w -i options bugfixing

Daniel Miller <[email protected]>
Newsgroups gmane.comp.security.nmap.devel
Message-ID <CABmvJnMBbT-=ROEB-UoOpWTnex3WeKQmpqXf_Ay9qFBanVuHag@mail.gmail.com>
Carlos,

Thanks for your interest. There may be something here to work on, but I
think that there may be some confusion over the intent of the options:

--idle-timeout is used for closing the connection *after it has been
established* if both sides stop responding. It works in both connect and
listen mode, but only on established connections (i.e. not while waiting
for a connection to be established).

-w is used for the connect timeout in connect mode, but has no effect in
listen mode.

The functionality here is complete. If anything needs to be done, it might
be to go through the documentation and make sure that it shows what is
really implemented.

Dan

On Sun, Mar 26, 2017 at 1:28 PM, Carlos Manso <[email protected]>
wrote:

> Hello, I'm Carlos Manso, a GSoC aspirant. I applied for bugfixing and
> developing new features. Right now I'm trying to solve a bug to get my
> hands a little dirty (https://github.com/nmap/nmap/issues/798).
> The problem is that -w options doesn't do the same as good ol' nc. As far
> as I know nc -w just waits in listen mode for the seconds you want and if
> no connection is done it ends. In ncat the -w option as no effect at all,
> it is passed between some functions but get lost at the end, when trying to
> make a connection, as I could grasp from reading the code.
>
> From the docs we have:
>
> The --idle-timeout option and it synonym -i allow setting a timeout for
> reads and writes in connect mode. If the client fails to read or write for
> the given time period, the connection is dropped. These options do not work
> in listen mode.
>
> The --wait (or -w for short) option sets how long Ncat will wait for a
> connection to be established in connect mode. The default is 10 seconds.
> if I'm right, -w option should be implemented, and should work only in
> listen mode, not in connect mode(as nc does, so the doc should be changed).
> Also -i option does work in listening mode in ncat, and this should be
> fixed as well, being only valid in connection mode, as the doc says, or
> change the doc.
>
> Thanks for reading, and sorry if I'm wrong.
>
> _______________________________________________
> Sent through the dev mailing list
> https://nmap.org/mailman/listinfo/dev
> Archived at http://seclists.org/nmap-dev/
>

_______________________________________________
Sent through the dev mailing list
https://nmap.org/mailman/listinfo/dev
Archived at http://seclists.org/nmap-dev/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.