Solved

ICMP packets

Posted on 1998-10-28
13
486 Views
Last Modified: 2010-04-06
Hi,

I'm trying to make application to catch every ICMP
echo request (ping) ,before my kernel(?!?) echo reply on it or even right after that (i need source IPaddr,packet_len) , i've browsed 'icmp.dll' info and didn't understand how to recieve them from this way . i hope someone already found
solution or saw interesting source codes (deplhi,c).

Jecksom
0
Comment
Question by:jecksom
  • 6
  • 5
  • 2
13 Comments
 
LVL 4

Expert Comment

by:dwwang
ID: 1344722
Go to this site and you will get exactly what you want, there is a ping implementation in Delphi.

http://www.rtfm.be/fpiette/indexuk.htm
0
 
LVL 1

Author Comment

by:jecksom
ID: 1344723
Hi dwwang !

You gave me opposite answer that i asked (i already have ics) and it's only
receiving echo reply after i've post echo request to remote host. I need to
catch icmp packet then anyone pinging me ! O'coz if you'll show source how
to detect incoming ping in this way i'll rise points to 250 :).

Jecksom

PS: bytheway, icmp.pas from ics using 'icmp.dll' ;)

0
 
LVL 1

Author Comment

by:jecksom
ID: 1344724
Adjusted points to 230
0
 
LVL 4

Expert Comment

by:dwwang
ID: 1344725
Hi, I have a app run under linux/C, named ENDE. It has the ability processing incoming ICMP packets. How ever I wonder if it could help, due to the difference between network implementation in Linux and Win95.

If you think it may help, I can e-mail it to you.

Of course I will ask no points if it does not help.
0
 
LVL 1

Author Comment

by:jecksom
ID: 1344726
Hi ,
nope  , i don't think it could help, networking mechanisms too different (i know how to
do this under Linux :) ) .

Thanx you anyway .
Jecksom

PS : don't forget this question . If you'll find something looks like solution, even if it's far
from main point of question.
(Sorry for my bad English)

0
 
LVL 4

Expert Comment

by:dwwang
ID: 1344727
Well, how about this site?

http://www.sockets.com/ch16.htm
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 8

Expert Comment

by:ZifNab
ID: 1344728
euhm, what does ICMP means?
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1344729
this may come in handy :

"You can only listen on this port if you have the Microsoft network stuff disabled (there can only be one program listening to a socket at one time). If this is the case just create a listening socket on port 139, set it to asynchronous and each time you get data on this check with the ioctlsocket (command SIOCATMARK) if there's any OOB data on this port."

Zif.

0
 
LVL 1

Author Comment

by:jecksom
ID: 1344730
Hi Zif !

ICMP - Internet Control Message Protocol, ecupsulating into IP - Internet protocol, utilized
for some different tasks like echo request/reply (ping,traceroute) .

I'm tring to intercept every ping that my box receiving (from different interfaces in NT case).
ICMP doesn't using PORT's as is , so 139 - NBD port not an answer, bcoz it's TCP port
(btw 137,138 NB  UDP ports ).

I guess Dwwang showed my right direction to search , only problem SOCK_RAW , raw
sockets only suppurted from 2.0 versions of winsock.

Thanx ,
        Jecksom.

0
 
LVL 4

Expert Comment

by:dwwang
ID: 1344731
Hi, jecksom

Good luck.
0
 
LVL 4

Expert Comment

by:dwwang
ID: 1344732
How are things going?
0
 
LVL 4

Accepted Solution

by:
dwwang earned 230 total points
ID: 1344733
Hi, I finally find this site, talking about and showing full source code(C++) for programming RAW Socket. Hope this could be an answer. :)

http://www.cyberport.com/~tangent/programming/winsock/
0
 
LVL 1

Author Comment

by:jecksom
ID: 1344734
Hi dwwang!

So answer is : no , you can't do this , unless you'll write NDIS driver .
I accept , this answer, since it's correct , there no chance to do this using Delphi only.

Thanx ,
Jecksom

PS : the only question when Inprise would supply us with VXD coding stuff (at least TASM32
include files) :(
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Intraweb submit form as a POST request 4 263
Syntax Check Delphi Seattle IOS app without MAC ? 1 92
Delphi TcxGrid group footer summary 3 210
creating threads in delphi 1 82
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now