Questions tagged [packet]

A packet is one unit of binary data capable of being routed through a computer network.

This is a small amount of computer data sent over a network. Any time you receive data from the Internet, it comes to your computer in the form of many little packets.

Each packet contains:

  • A label which uniquely identifies it
  • The IP address of its origin and destination
  • A sequence number (for sorting)
  • A checksum (for error checking

The process of sending and receiving packets is known as "packet-switching." Packets from many different locations can be sent on the same lines and be sorted and directed to different routes by various computers along the way, the packets are then sorted by their sequence number once they reach their destination. It works a lot like the post office, except billions of packets are transferred each day, and most packets take less than a few seconds to reach their destination. Even FedEx same-day delivery can't compete with that.

Packet Definition. 2013. Packet Definition. [ONLINE] Available at: http://www.techterms.com/definition/packet. [Accessed 30 April 2013].

1562 questions
0
votes
2 answers

DatagramPacket can receive data?

I'm reading through my textbook and I see this: The first constructor: public Datagrampacket (byte ibuf [], int ilength) constructs a DatagramPacket for receiving packets of length ilength. Is this just an odd wording, or do DatagramPacket's…
Hoser
  • 4,974
  • 9
  • 45
  • 66
0
votes
2 answers

Only 16 UDP 512 byte packets being received by server when I sent 7mb total

I break a 7mb file into 512b chunks and I send it with udp to a server. About 14000 packets get sent by the client but on the server side socket.receive(packet) blocks after receiving only 16 packets. Any ideas what's going on here?
csss
  • 1,937
  • 2
  • 14
  • 24
0
votes
1 answer

NSData Packet Interpretation

I have a fairly complex issue regarding the interpretation of packets in an app that I am making. A host app sends a packet to client apps with the following structure: [Header of 10 bytes][peerID of selected client of variable byte length][empty…
Hayden Evans
  • 5
  • 1
  • 4
0
votes
1 answer

Find first and last data packet receive time in android webview?

I want to find out the time at which the very first and the last data packets were received in my android WebView/webpage. Can anyone please suggest some way of doing this?
50EC07
  • 25
  • 6
0
votes
1 answer

Read DNS(mDNS) responses

For a project, I've to read mDNS responses. I read the IETF doc(and tcpguide, which contains a lot of schema) , and I think I'm respecting them, but I've an issue. Often I'm trying to read my stream, but the stream is too short for data I'm trying…
J4N
  • 19,480
  • 39
  • 187
  • 340
0
votes
1 answer

Parsing a text file of network packets in Java

I am having quite the difficult time parsing this .dat file using Java. The format of the .dat file which I am trying to parse is shown below. These are actually packets for a packet generator program I am working on. Each packet is delineated with…
0
votes
1 answer

C++ SFML tcp send and receive

I am making a game, I have 2 clients and a server. When I move in the game, I send data to server (1-left,2-up,3-right,4-down). The server sends forward to the other client. Here is the server : #include #include…
cylon
  • 735
  • 1
  • 11
  • 26
0
votes
1 answer

SFML TCP packet receive

I send a packet as client to server and I want to the server sends that packet forward to all client, here is the code: #include #include using namespace std; int main() { int fromID; // receive data from 'fromID' int…
cylon
  • 735
  • 1
  • 11
  • 26
0
votes
1 answer

How to determine number of concurrent session made by Individual IPs

I am working on an analyzer script. It is a simple bash script that apply some logic on tcpdump sniffed capture. My task is to find out number of concurrent sessions made by individual IPs. The logic I have applied is I have counted different…
Udit Gupta
  • 3,162
  • 11
  • 43
  • 71
0
votes
1 answer

C/C++ - How to send a video file in "packets" over a UDP socket?

For a project, I'm looking to simulate a communication protocol. I plan to add in my own simulated packet loss and what not. However, I'd like to build this simulation on top of a UDP socket. So that the UDP socket will actually be the one sending…
Jenny Shoars
  • 994
  • 3
  • 16
  • 40
0
votes
1 answer

MySQL Server - Set max_allowed_packet value permanently

I have a MySQL Server version 5.5.25 installed on CentOS server. I've increased *max_allowed_packet* size to 32M in /etc/my.cnf file in order to store it permanently (max_allowed_packet = 32M;), then I've restarted server with /etc/init.d/mysqld…
Andres7X
  • 165
  • 2
  • 4
  • 12
0
votes
2 answers

Python get packet data TCP

Hello I have python sniffer def receiveData(s): data = '' try: data = s.recvfrom(65565) #k = data.rstrip() except timeout: data = '' except: print "An Error Occurred." sys.exc_info() return…
Irakli Lekishvili
  • 33,492
  • 33
  • 111
  • 169
0
votes
3 answers

Accuracy of remote IP address retrieved from packet

If it were possible to retrieve the remote IP from a packet received by my Apache2 server (through a custom plugin perhaps), would it always be guaranteed to be accurate? Or is this value as easy to spoof as the referrer header? My intended use…
Matt Parkins
  • 24,208
  • 8
  • 50
  • 59
0
votes
1 answer

Why is my program hanging on a system.out.print of DatagramPacket.getData()

LinkedList queue = new LinkedList(); for (int i = 0; i < queue.size(); i++) { System.out.println("1: This prints."); System.out.println("2: This doesn't: " + new String(queue.get(i).getData())); int start…
user1848537
0
votes
1 answer

Getting AltQ working in pf.conf (limiting inbound Tor traffic)

I'm trying to learn the ropes on packet queuing, so I thought I'd set up a limitation on traffic coming into port 80 from known Tor Exit nodes. This is on FreeBSD 9, so OpenBSD-specific solutions might not apply (syntax/etc). # Snipped to mainly the…
KBeezie
  • 841
  • 6
  • 6