At 19:47 09/10/00 +0000, Hafida Fouta wrote:
>I need to know cause it is part of my TCP/IP project.

Then you'd need to get Stevens book "Unix Network Programming, second 
edition, vol1".
Chapter 25 explains how to write raw sockets code. I'm pretty sure your 
universty has
a copy.
The book source code should be available on http://www.noao.edu/~rstevens.

A good starting point may be the "ping" program. all it does is sending 
ICMP_ECHO and
receiving ICMP_ECHOREPLY. and you need to send ICMP_MASKREQ and receive
ICMP_MASKREPLY. so check the source code of ping.

Note however that systems do not necessarily reply to ICMP_MASKREQ packets. 
In particular,
by default BSD systems won't reply unles you "sysctl -w icmpmaskrepl=1". I 
suspect
other systems act similarly. so you'll need to make sure the target system 
replies to these
packets.


cheers,
mouss

-
[To unsubscribe, send mail to [EMAIL PROTECTED] with
"unsubscribe firewalls" in the body of the message.]

Reply via email to