-
-
Save evelinad/1d1ebfeea77c0bc0c1f3 to your computer and use it in GitHub Desktop.
Revisions
-
perone created this gist
Oct 5, 2012 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,13 @@ $~ sudo scapy >>> from datetime import datetime >>> pkt = IP(dst="www.google.com", ttl=1) / ICMP() >>> ans,unans = sr(pkt*3) Begin emission: .**Finished to send 3 packets. * Received 4 packets, got 3 answers, remaining 0 packets >>> sent = datetime.fromtimestamp(ans[0][0].sent_time) >>> received = datetime.fromtimestamp(ans[0][1].time) >>> print (received-sent) 0:00:00.001820