You are here: Home | NetKnife
 
Internet
Monitoring
NetKnife is an application that brings many classic network client utilities into an easy-to-use JAVA environment. As consequence, all Internet users (UNIX , Windows, Macintosh) can access traditional services like Ping, Traceroute, Finger, Whois, DNS, Time, Quote or advanced services like PopAbstract, PopPasswd, Network Scan, Network PerfMeter and TCPterm.
 
NetKnife was born from the simple idea to give to all internet users access to a lot of services available in UNIX® environment. As time passed new services were added and so NetKnife becomes a sort of Swiss Knife for network monitoring. This document describes briefly the architecture behind NetKnife and the way to use it.

Note: Because of many requests i put the code free, even if it is not well commented. Take a look at the ending part of this page. Please, if you download the source spend a bit of time to drop an email to me. I'm looking for a group of people to maintain and improve the code, always in the spirit of free software. I need your help as coders or reviewer. (Antonio Gulli)

How to use NetKnife ?

First at all you need to have JAVA 1.1.X (or 1.2) installed in your system, next you can download NetKnife. You can use NetKnife without any limitation: this is a free software at all (Stallman-Vanilla mode :). To launch NetKnife just type "java NetKnife" if you have the sun jdk1.1 or consult your local documentation, if you use another jvm.

Where is the GUI?

Here. As soon as you start NetKnife you'll see something like this GUI:


  
The GUI is divided in two different part:

How it works ? MultiThread !

Every tool is implemented in a separated thread, so it is possible to use all the tools belonging to NetKnife in a parallel fashion. The rest of this paragraph shows how works every single tool:

PopAbstract:

Let's start with PopAbstract. The main idea is not to build yet another mail client cause there are to many out of there. In UNIX® environment there is a service called BIFF that informs user when new mails are incoming, giving their subject. Well, think about PopAbstract as an advanced BIFF. PopAbstract check for every incoming mail and gives you following field: This is a new service that I developed to take a continuos and quick look at my mailbox and to decide what mail to delete basing on the given abstract. This is my way to reduce noise in my mailbox. Note that PopAbstract minimises the network delay cause it downloads only the part of the message that it needs for giving an abstract. Here is an example of session:

You can see a deleted message marked with a "[D]" symbol. To delete effectively all marked messages just click on the update button. Using the mouse and clicking on a message, you can obtain a short abstract of the message. NetKnife uses object serialisation to save in a configuration file the user and host field.

PopPass

PopPass is a tool that allows you to change your email password from remote. PopPass communicate with a pop_passwd daemon, so be sure that your provider have this daemon running before using PopPass. Here is an example session:

NetKnife uses object serialisation to save in a configuration file the user and host field.

Network Scan

Network scan has a double function. First at all, it allows you to check what ports are open in a given machine. For each open port a brief description of the daemon running is returned. This description is fetched through the reading of an ASCII file that follows the Unix "/etc/service" format. Here is an example:

Another function that is exploited through Network Scan is the discovery of all machine, in an IP range, that run a daemon in a given port. Here is an example:

PerfMeter

PerfMeter is a network performance analyser. It sends a packet of chosen format to the server and computes the round trip time (i.e. how much it needs to send the message to the server and to have an "echo" replay back). Here is an example:

TCPterm

TCPterm is a simple client that allows you to exploit commands in a remote server. Here is an example session in which I contacted sendmail on port 25 and asked to verify the existence of an email address. You can use TCPterm to contact every kind of TCP daemon:

Ping and Traceroute

Java doesn't handle ICMP message, so it is impossible to implement directly a ping or traceroute client in Java. There are two solution: the first one is to write an interface to C socket API (using java native method), the second is to define a wrapper thread to a specified command presents in the machine in which NetKnife is executed. I followed the second solution that seems the simplest and most portable. Here is an example:

NetKnife uses object serialisation to save in a configuration file the path in which ping or traceroute command are.

Finger

Finger is a common tool that allows you to know what users are working on a given machine. For more information on finger protocol see RFC 1288. Here is an example of using this services in NetKnife:

Whois

Whois is a tool that allows you to query the InterNIC database and the database of others Network Internet Center (NIC) all around the net. For more information about whois see RFC 0954. Here is an example of using this tool in NetKnife:

DNS

DNS allows you to perform a query to your name server for direct or reverse address resolution. For more information about DNS please read " DNS and Bind, O'Reilly". Here is an example of use:

Time

The time tool allows you to ask to local time in a given machine. For more information on time protocol see RFC 0867. Here is an example of time at a cool place:

Quote

Quote is a simple service that allows you to get a fortune message from remote. For more information about quote protocol see RFC 0865. You can use www.rmm.com as quote server thought is not up all he time.

What they think about ?


Antonio,

Per your very kind offer, I would like to request a peek at the source
code for your NetKnife Java program(s).  I am attempting to learn Java
and especially as it is useful in networking and Internetworking.  The
source code to NetKnife would be a treasure for my learning process.
Thank you very much.

Richard Whiting MIS FFRC ffrc-mis@worldnet.att.net


Hi.

I appreciate offering Netknife.
I am a graduate student of Kyungpook National Univ.
in Republic of Korea.
I found NetKnife in gamelan, and I downloaded class
files and excuted it.
It's so useful to manage personal information remotely
I am participating in network managment proect. If you
offer the source code of NetKnife, It will helpful to me.
Thanks for your reading.

Have  nice days.

parkbs parkbs@woorisol.kyungpook.ac.kr

Got it, Thanks!

I was getting ready to write something very similiar  to solve
a problem at a client side. It was quite  a reilef  to find 
your application  (I can code, but I'd rather not). I hope
to give it a test tomorrow!

Later, 

Michel gastrig@midspring.com

Howard Owen wrote:

> Hi there. I'd 
like to have

 a look at your NetKnife source code. I was > hunting for free networking Java
 Beans when I came across your listing. > I'd like to offer
 you part time help in getting the source code in shape > for public release.
 I think that a toolkit of freeware Java networking > beans would
 be a Real Good Thing. > >

 Ciao.

This is a Very Cool Idea. After submitting the code to JARS
i received a lot of mail asking me for source. So i decided to put
it as free software (yep, Stallman-Vanilla mode:), even if it is not
well commented. I really appreciate any help coming from out
of there. I'm a very busy guy and my problem is to keep in touch
with the whole activities i hold ... If you can help me in any way
please do so. You can modify/improve the source, put your own
code and name in every place. The idea to build a Beans was in
my mind but very deep situated. I ask you only two things:
1) keep me updated with your own work
2) Mantain the original name "NetKnife" and my signature.
(You can add your own)


Howard Owen hbo@egbok.com

Dear Antonio Gulli,

I'd like to examine the source code of NetKnife. In particular,
I am interested in the performance-monitoring code.

Hope to read from you soon.

Sincerely,


Jonathan BenDor jbendor@electriciti.com

Hi, there, 

I am a computer engineering graduate student at Wayne State University,
USA. I am very interested in your Program: NetKnife. Is it possible that
you can send me the program's source code? 

Thank you very much!



Jiang Yin jy5@mundania.eng.wayne.edu

Mr. Gulli:
I saw the NetKnife on the www.developer.com.
I am very interested in your app.
I want to have one copy with source.
If you send me one, I am really appreciated.
Thanks a lot.

lizhiping@usa.net 

I downloaded your NetKnife and was impressed.  I would like to look at
your source code - I am working on an application that needs to interact
with DNS servers and thought that maybe how you perform DNS would be a
good start.

Thanks,
Randy Layman rlayman@cc.gatech.edu

Hello Antonio,

Could I have a look at the source code for the Java Ping?

Many thanks,
John


John G. K. j*ohngk@primenet.com

     
Greetings from Hawaii,

Thanks for NetKnife. Very nice application. Can I get a copy of the source
code?

Mahalo, Olin      olin@worldpoint.com

     
Hi,

Your application is very impressive.

I would like to obtain a copy of the source code.


Thanks
Newton B  Brown  nbrown@tricity.wsu.edu

      
Please email me a copy of the current source for netknife.

Thanks in advance.

Jim Patterson        jpatterson@msa.com

Hi,

I downloaded and tried NetKnife.  Pretty cool little kit.

Could you send me the source?

Thanks very much, and good coding.

Phil Brown
http://www.sysimpact.com/Phil  

gophil@mindspring.com


  
You mentioned  
in your web site that the source is available. I would very much appreciate
it if you'd send it to me, as I would like to see how some features of
the program have been implemented. I'm going

to make an email client which is supposed to be very light, and currently I
have no idea how these things are done. So now I need to find specs for
the protocols (SMTP, POP3, IMAP etc), but I really don't know where to
start looking :) sami.jarvinen@pp2.inet.fi >  

Yout

 have to start from RFC That

much I figured and yesterday I fetched the RFCs from a Finnish mirror. >

 , why not to develope something AND intragrate NetKnife with it ?     

Perhaps :)

Btw, the source wasn't all that bad. Actually, it was quite well organized
compared to other Java apps I've seen.      


 
Hi

Thank you for the program, but I have some trouble running it.

I have set up the eviroment as described in the README.TXT file and I
start the program by typing "java netknife.class" in the commandprompt.
Then I get the message "Can' t find class netknife/class"

what do I do wrong ?


Jesper            j-denck@pip.dknet.dk

No one report this kind of problem. I dont know haow expert are you.
So let me do a simple question. Do you ever have run a java program
before or this is the first time ? Excuse me if i could be crude,
but i need to know this to help yu .   

Hi again

I've have solved my problem running netknife. After reading the README in JDK1.1
.5 I find out what I had done wrong. The classpath setting was wrong,  didnt use the default settings as described in the documentation.
Now I have tried out netknife and I think its a really cool program !

Thank you for your quick replies...

Jesper                         


         
Well...
It's quite surprisin'...
I'd like to see the source, especially Traceroute.
How long it takes to make program like this?
So, many thanks for source i'll get.
Keep going...
mesak1@hotmail.com      

  
Hi,
Your program is very cool and I want to get a copy of the your source code.
Thank and Best regards,
H.Ali EGERCI
egerci@comnet.net.tr        


Subject: Thank you...

...for NetKnife

Gene Gaines
Montreal, Canada
ggaines@generation.net    

   
Hello Antonio,

Your program is very cool ,I would like to obtain a copy of the source
code.

Many thanks.


Palomar. fpalomar@hotmail.com 


 
Hello Antonio;

I downloaded your netknife application and played a little bit with it.
It is nice but I think it could be improved a little bit (e.g. dns
queries with types (MX,ALL)).
You wrote that you will send the source on request.
Could you please send me the source code?

Thank you & Best regards,     

blacksnake@parlinkom.gv.at

I'm having a hard time getting your NetKnife program from
www.di.unipi.it.  Is there an alternate place i can get this software?

Thanks,

jim burnell jburnell@east.orincon.com 

I'll send you in attach

 
Hi,
Your program is good and I would like to get a copy of the the source
code.
Thank you,

SushilA staneja@Bear.COM


Hello..

Im a novice java programmer and I'm currently working
on a network application. I'd really appreciate if you could
send me the source code of NetKnife. For learning purposes
only of course... And if ever I come across a bug or something
I'll drop you an email (for free!)  ;-)

Thanks and keep going!

Mat
mathieu@labs.microcell.ca
barry@info.polymtl.ca

 
your program is great, can you send me the source code for it...

thanks

MLR    
               Chortik@aol.com

  
Hi,
I'd like to get the source code of your Java program NetKnife. May
you email me with the source code, please? Why when i tried the ping
function i got "I cant open  host" for all hosts.

Any help will be appreciated.

Ahmed       
               Ahmed Moustafa ahmedmos@idsc1.gov.eg

   
I am highly impressed.
Would it be possible for you to send me a copy of the 
source files?
I will be teaching a new second year University module from 
September to January.  It is in the Computer Science 
Department.  It is on Communications and Networks.  I have 
made the decision to use Java as much as possible in the 
teaching of this new module.  I am still getting the 
material into shape and I can see that your work would 
help.  The use of NetKnife will be instructive. 
Best wishes and thanks,
Don

Antonio:
I forgot to say yesterday,  I've been around OOPS since the 
early 1980's and I do like your style of programming.
Don

Don Fay d.fay@qub.ac.uk

       
Hi Dr. Antonia Gulli..

I am wondering is it possible that I can have the source code of
NetKnife or Jamming the Net or any Java related code that you wrote?? I
am a beginner in Java Programming. I learn to program thru tutorial and
shareware/freeware that comes with code on the net.. Your work look very
interesting. It would be great if I can see the code so I can learn from
it.. Thank you..

Regards,
Duc


Duc Duong duong@americasttv.com

   
> 
> Antonio,
> 
> Where can I get access to the source code for NetKnife?   
 
 >
 
 I'm personally working on a network simulation project > for the
 university (Johns Hopkins Univ.) and am > interest
 on how you handled the communication threads >
 in Java. > > Thanks > > --
 > John
 
 Peng
 
 > 
 jpeng@acm.org >
 jpeng@virtc.com
 >
 jpeng@apl.jhu.edu

   
> Hi,
>     I would like to request   
 the
     source code for NetKnife. I've spent the > last month  trying to learn
 to program internet protocols with little luck. > The RFCs I've found
 are quite terse and don't give any real help writing > code. > >
 Thanks
 
 in advance, >
 amory
 
        amory@hawaii.rr.com


Antonio Gullì
gulli@di.unipi.it