Nmap Development mailing list archives

Ncat patch: --color-input


From: Jacek Wielemborek <wielemborekj1 () gmail com>
Date: Mon, 16 Sep 2013 19:47:12 +0200

Hi,

I just wrote a fun Ncat feature, called --color-input, inspired by
Wireshark's "follow TCP stream" and one Wikipedia image
(https://en.wikipedia.org/wiki/File:Http_request_telnet_ubuntu.png).
The new feature colors all incoming network data with red color, so
you can easily tell terminal and network input apart. This might be
useful for example when chatting using Ncat or for educational
purposes. Invocation:

ncat --color-input scanme.nmap.org 80

The attachments contain the patch and a screenshot you could use in
the documentation. The patch includes both POSIX and Windows code,
which turns off when the standard output is redirected (to make it
consistent with Windows). I also updated the manual page and
changelog. The patch should apply against the latest SVN trunk.

Here's a diffstat:
 ChangeLog      |    3 +++
 docs/ncat.xml  |   13 +++++++++++++
 ncat_connect.c |    6 +++---
 ncat_core.c    |    1 +
 ncat_core.h    |    3 +++
 ncat_listen.c  |    4 ++--
 ncat_main.c    |   10 ++++++++++
 ncat_posix.c   |   18 ++++++++++++++++++
 ncat_win.c     |   21 +++++++++++++++++++++
 9 files changed, 74 insertions(+), 5 deletions(-)

Hope you like it! Let me know if you're interested in a parameter
(optional?) to the switch that lets user specify the color.

Yours,
Jacek Wielemborek

Attachment: color-input.diff
Description:

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

Current thread: