Questions tagged [packet-capture]

is for questions about capturing packets of various protocols that are transmitted over a network.

A lot of computer network protocols transmit their contents in packets. Packet capture is the interception of these packets as they are moved over a network of some type.

A packet sniffer captures raw data traveling over a network segment and saves it to a file for analysis.

Software

A software sniffer can generally only capture network data either originating from or going to the computer running it, plus any "broadcast" messages, if the computer is connected to the network via a switch. If the computer is connected to the network via a router, it may be able to capture network data for any device on connected to the same router.

Hardware

A hardware packet sniffer is physically connected to the network by connecting it to a router or switch. Sometimes the router or switch has to be configured to allow the sniffer to capture traffic being routed through it; this is called port mirroring.

Analysis

The captured data can be analyzed by the software that captured it, or by a program specifically designed to analyze the network data.

See Also

  • Wikipedia Article on Packet Analyzers
  • The term packet sniffer is also common and can be considered a synonym.
659 questions
0
votes
0 answers

scapy - http header list over wlan

I'm trying to get a list of all http headers being visited on my wlan. The code I'm using is (not my own): #!/usr/bin/env python import sys sys.path.append("/usr/local/lib/python2.7/site-packages") import re from scapy.all import * import os import…
jaydh
  • 101
  • 1
  • 7
0
votes
1 answer

Modifying TCP packets on the fly

I'm currently writing a Java application where I'm running a primary sever along with a backup one (using VMs). In order to get the backup server to take over as the primary (if the primary crashes) while being completely transparent to the client,…
0
votes
0 answers

Python Scapy Intercept Packets before sending them on

I have three virtual machines all on Centos 6.5. The current setup is as follows: A ------(eth0) B (eth1)------- C Currently, when A pings C, it is routed through B as they are on different networks. I want to write a script using python and scapy…
0
votes
2 answers

Debug: How can i look at my browsers output?

I have this question https://stackoverflow.com/questions/2688464/ajax-request-from-net-give-me-unexpected-results and i am using tamper data but i am sure firefox is formatting the data in ways i dont understand. Is there a tool i can use to check…
user261192
  • 77
  • 5
0
votes
2 answers

Interpreting the Packets using sharppcap

Is it possible to interpret every coming packets using sharppcap?
Eyla
  • 5,751
  • 20
  • 71
  • 116
0
votes
3 answers

determining HTTP packets

Greeting, how is possible to determine from captured packets using sharppcap if the packet is http packet or not? and can we determine frpm TCP packets if the packet is HTTP or not?
Eyla
  • 5,751
  • 20
  • 71
  • 116
0
votes
1 answer

How to identify whether a received packet is IPPacket or ARPPacket in java using jpcap?

I am capturing IPPackets and Analyze the captured packet in java using Jpcap Library.But captured packet is ARPPacket my program shows following error. Blockquote Exception in thread "main" java.lang.ClassCastException: jpcap.packet.ARPPacket…
0
votes
1 answer

C# pcapdotnet ReceivePackets use device in callback

I am trying to make a program that will receive packets on multiple network devices and send them on other devices (something like software hub). I am using C# and pcapdotnet. This simple method captures communication on device: public void…
aron23
  • 293
  • 2
  • 3
  • 11
0
votes
3 answers

Sample application to read and inspect packets on a network?

I'm looking to write a quick program to read and inspect packets of a certain format and then blacklist ips with a certain style of packet-traffic (packet patterns of an attack against the network). Are there decent samples of reading and…
franz
  • 11
  • 1
  • 3
0
votes
2 answers

Dumpcap (Wireshark) - Trying to capture files and store in subdirectories

Does anyone have any idea on how to force dumpcap to create the directory before it writes in it? I am trying to capture packets for a year, and have a batch file that writes based on the year/month/day/hour, but unfortunately dumpcap doesn’t try…
uid500
  • 53
  • 8
0
votes
2 answers

SharpPcap - A Packet Capture getting messesge problem

I trying to capture packets using SharpPcap library. I'm able to return the packets details but I'm having problem to get what the message content inside the packet. the packet using .Data to return the message and when I use it it is returning…
Eyla
  • 5,751
  • 20
  • 71
  • 116
0
votes
1 answer

Dummy Packet Shown in pcap file

I am new to ns3. I want to send custom data from node 1 to node 2(say a string) in UDP Echo Application. I am creating the packet, adding header and trailer, and the tags. I have also enabled metadata. I have used the code provided in other threads…
Cam
  • 1
  • 1
0
votes
1 answer

Editcap input/output files

I'm trying to run editcap on a bunch of files in different folders, and I have no problems doing it using *. For example: editcap captures/*/*.gzip The problem is that when I also try to specify an output file, for example with: editcap…
gprivitera
  • 933
  • 1
  • 8
  • 22
0
votes
1 answer

printing sequence number of a sniffed packet

i am using pcap to create a packet sniffer. i have this tcp structure: typedef struct TSP_header{ unsigned short int sport; unsigned short int dport; unsigned int seqnum; unsigned int acknum; unsigned char …
scatman
  • 14,109
  • 22
  • 70
  • 93
0
votes
2 answers

How to capture HTTP response with C#?

How do I capture HTTP response when the request is made by web browser? Webpage retrieves data (with post) from a service. Service returns a json object. What I want is to capture that json and parse it in realtime. What would be the simplest way to…
Mike Koder
  • 1,898
  • 1
  • 17
  • 27