Questions tagged [tcp]
For questions about Transmission Control Protocol (TCP), a transport protocol used to encapsulate data across a network for reliable communication.
792
questions
0
votes
2
answers
347
views
Is the SYN packet the only packet that have the ACK flag not set?
Is the SYN packet the only packet that have the ACK flag not set, or are there other packets that have the ACK flag not set?
1
vote
1
answer
947
views
Does the TCP header have a "Padding" field?
I found one image of the TCP header that shows a field called "Padding", and I found another image of the TCP header that don't show the "Padding" field:
Which one of these two ...
0
votes
1
answer
141
views
Are encapsulation and decapsulation really happening inside an operating system?
I have read in many tutorials that Encapsulation is when the data go down the OSI model or the TCP/IP model and a header is added to it at each layer, and Decapsulation is when the data+headers go up ...
3
votes
1
answer
247
views
Does the MSS (Maximum Segment Size) prevent IP Fragmentation in all cases?
I have read that the MSS (Maximum Segment Size) is used to prevent IP Fragmentation.
Now if the two communicating devices exist on the same network, and this network have a MTU (Maximum Transmission ...
2
votes
1
answer
56
views
What does "direct-attached networks" mean?
This page says the following:
TCP controls this maximum size, known as Maximum Segment Size (MSS),
for each TCP connection. For direct-attached networks, TCP computes
the MSS by using the MTU size of ...
1
vote
2
answers
2k
views
How to calculate the Maximum Segment Size (MSS)?
This page says the following:
TCP controls this maximum size, known as Maximum Segment Size (MSS),
for each TCP connection. For direct-attached networks, TCP computes
the MSS by using the MTU size of ...
1
vote
2
answers
213
views
How does TCP knows the correct order of data?
TCP will re-order the data if they arrived in the wrong order, but how does TCP knows the correct order of data, does TCP knows the correct order of data by looking at the sequence numbers?
1
vote
1
answer
54
views
RFC 5681 Fast Retransmit/Fast Recovery algorithm
I am reading RFC 5681, in particular §3.2 on the Fast Retransmit/Fast Recovery algorithm.
I see that, in the event of the detection of a dropped packet, the receiver should send an immediate DUP ACK (...
2
votes
1
answer
332
views
What's the difference between MTU and MRU ? How come people talk so often about MTU and little consideration is given to MRU?
I don't understand why MRU isn't mentioned as frequently as its counterpart MTU. Are they always arranged to have the same value on a device ? A few days ago I noticed that my Windows machine accepted ...
0
votes
1
answer
154
views
Wireshark only shows single HTTP request instead of its constituent TCP packets and ACKs
To my understanding, in packet no.39, the post request actually consists of multiple tcp packets getting sent, and they all get acked once by no.40. The server has received it. Now, the server sends ...
0
votes
1
answer
55
views
Relation between the BACnet 4 layers and the TCP/IP 5 layers
How are the BACnet 4 layers (physical, data link, network, application),
related to the TCP/IP 5 layers (physical, data link, network, transport, application)?
Are they separate of them, or build on ...
1
vote
1
answer
2k
views
Why don't tcp sequence number start from 0?
In TCP, one purpose of 3-way-handshake is to exchange initial sequence number for both sides. So why not use 0 instead, and the exchange is not necessary.
That is to say, sequence numbers can be ...
0
votes
2
answers
357
views
IP packet expired by TTL generate an ICMP response in any case?
Acording to Wikipedia IPv4 article for TTL header field:
An eight-bit time to live field limits a datagram's lifetime to
prevent network failure in the event of a routing loop. It is
specified in ...
0
votes
1
answer
291
views
TCP RESET randomly between DB and Server
we have some customer complains regarding a flow between a DB and Server crossing our FW.
It involved 2 DB and several Servers, there are 2 VLANs connected to same FW.
When failover to FW-2, we ...
1
vote
2
answers
147
views
TCP Reno - Is a timeout guaranteed in this situation (loss of segment in fast retransmit)?
In this situation:
Is there a way for this situation to not end with a timeout? From my understanding, duplicate acks (Acks that require segment #1 to be sent) that are received during fast recovery ...
7
votes
2
answers
1k
views
TCP - Why do RST packets not require acknowledgements (and FIN packets do)?
From what I can tell, RST packets do not require acknowledgments.
My question is, what happens if a RST packet doesn't reach the other participant? How can the other participant tell something has ...
0
votes
1
answer
135
views
GNS3 - hosted or VM?
I know that there is a gns3 client that is installed in the operating system.
but i see there is a gns3 for vm
that gns3 for VM In a few words it is a virtual software to use it with a hypervisor
It's ...
1
vote
2
answers
367
views
For TCP, what is the justification that ACKs are Last Byte Received + 1 and not just Last Byte Received?
Intuitively, it makes more sense that the ACK be the last byte received. Essentially, the receiving end says.
I have received up to N bytes
Then, the sender will receive that ACK that says N and ...
2
votes
3
answers
59
views
QOS operation doubt
First of all, thanks for taking the time to read.
I have a doubt.
Does QOS marking in the IP header occur on every packet or does it need TCP segmentation established (TCP handshake)?
0
votes
2
answers
151
views
How to benchmark time a packet spend in each OSI layer?
I'm benchmarking latency of sending a TCP packet from a client to a server. The payload of the packet is the nanosecond timestamp (using clock_gettime() on Linux) right before the send() socket ...
1
vote
1
answer
1k
views
How does wireshark calculate the TCP length when there is no header indiciating such?
In wireshark, you have this field:
[TCP Segment Len: 1380] # How is this calculated?
My assumption is using the IP headers plus TCP's.
TCP Segment Len = IP Total Length - IHL - TCP Header Length
In ...
0
votes
2
answers
768
views
why TCP window size is restricted to 1GB even with TCP window-scaling option?
TCP window size = 16 bits , TCP scale factor size = 14 bits. So, overall the max TCP window size can be 2^30 = 1GB.
For networks where the latency is high like 500 milli-second. 1GB of TCP window ...
0
votes
1
answer
34
views
Constraint on length of message & segment to be integral number of bytes, as mentioned in Cerf & Kahn's Paper
I have a question about the below excerpt from Cerf, V.; Kahn, R. (1974). "A Protocol for Packet Network Intercommunication". IEEE Transactions on Communications. 22 (5): 637–648.
... ...
0
votes
1
answer
62
views
HTTP and TCP relationship
I always wondered how HTTP knows when it has enough TCP segments in order to process a request or response.
Can someone give me more information about the process?
Thanks.
0
votes
1
answer
618
views
TCP segment with flags ACK, PSH, URG
Can a TCP data segment with a 1 byte length have, at the same time, the flags ACK, PSH, URG set ? Is it conform or not to the TCP protocol ?
Thank you.
8
votes
6
answers
4k
views
How Does A Layer 2 Switch Differentiate Between Different Networks?
I know that different IP-based networks can be connected to the same layer-2 switch. and I know each network's nodes can communicate just fine, however, no normal traffic can occur between two nodes ...
1
vote
1
answer
297
views
How to change the source port without interrupt the TCP connection? [closed]
I use TCP socket to connect a client(source) and a server(destination), the connection has been established. Now the project need to change the source port without interrupt the connection. Both ...
0
votes
2
answers
743
views
UDP supports multicasting and broadcasting in transport layer or application layer?
We know that UDP does supports multicasting and broadcasting. My question is which layer "UDP supports multicasting and broadcasting"? Is it transport layer or application layer? We know ...
1
vote
1
answer
2k
views
What is difference between socket connection and TCP connection?
We know TCP socket is port numbers and IP addresses. Is TCP socket connection is 3-way handshake:the SYN packet, the SYN-ACK packet, and the ACK packet?
Is TCP socket connection follows TCP stack?
And ...
0
votes
1
answer
278
views
Inherent flaw in stateless firewalls?
I am but a lowly (software) developer dabbling with setting up a network in AWS and am having trouble understanding the fundamentals of stateless firewalls, or Network ACLs as they're also referred to ...
21
votes
5
answers
5k
views
Why is Packet Size Limited?
I was reading: this answer to "Maximum packet size for a TCP connection", where it says:
The absolute limitation on TCP packet size is 64K (65535 bytes), but
in practicality this is far ...
1
vote
1
answer
317
views
Why need Ack flag if we already have ack number in TCP
If we have ack number so from there we can trace that how many bytes are received and which byte is need next so then what is the use of Ack flag there?
0
votes
1
answer
102
views
Is there any other scenario of TCP segment window size equal 0?
Is there any other scenario of window size equal 0?
in my impression, if the window_size == 0, there have two cases:
1.the TCP acceptance area is full, then send window_size = 0
2.send RST package, ...
1
vote
1
answer
113
views
How n level come to know the n+1 level contents?
Suppose in application layer is running some application. And application has respective source port number and destination port number. And know that n layer has no authentication to know about n+1 ...
0
votes
2
answers
430
views
Does window size in tcp header include tcp header size?
Let's say a TCP segments has in the field of "window size" = 1400 bytes.
Does that mean that
we can send 1400 bytes counted in tcp segments = TCP headers + data
or
it does specify only ...
2
votes
2
answers
464
views
TCP behaviour when a ACK is never received
What is the behaviour of TCP if ACK is lost for ever. Will retransmission happen for ever or will the connection be reset ?
Lets say A is TCP-server and B is TCP-Client. If the Server, A, fails ...
0
votes
1
answer
444
views
What will be the sequence number consumed by FIN flag? [duplicate]
In the connection termination phase, suppose the FIN segment from the client-side contains data ranging from sequence no 100 to 200,
So will the ACK no from the server start from 201 or 202? Will the ...
-1
votes
2
answers
415
views
What will happen if a sender use TCP and receiver uses UDP?
I am new to networking and was studying about TCP and UDP. One question came to my mind that what will happen if a sender uses TCP and receiver uses UDP for the communication.
-1
votes
1
answer
45
views
Latency between a churn and congestion event triggered in the TCP code
I am analyzing the time it takes between a churn occurring in the network (e.x. that causes packet drops or delays) and when the congestion event handling codes are triggered in the TCP kernel in the ...
0
votes
1
answer
590
views
Can UDP traffic be transmitted over TCP ports on OpenVpn to avoid the TCP meltdown
I understand the TCP meltdown problem is associated with overcompensation from errors and incorrect sequencing when arriving the the receiver end. OpenVpn connections are recommended to use the UDP ...
1
vote
2
answers
178
views
How can I use scapy to make a port appear open-device behind NAT?
This has been asked in stack overflow like 7 years back. I don't see the correct answer there. Is there any way to do this?
While this packet keeps on being transmitting, doesn't the other end see the ...
0
votes
1
answer
117
views
TCP payload error handling at the application layer [closed]
How are errors in the payload of TCP packets handled by the receiving application? The packet is received but for various reasons (including sending erroneous packets on purpose) the payload of the ...
0
votes
1
answer
47
views
Hosting a website using dynamic public IP: What if the ISP did not assign any port forwarding? [closed]
Let's just say that I am a peasant that can only avail of a typical Dynamic Public IP address from my ISP.
Just for the sake of example, let's say have the following:
Domain Name: experiment626....
0
votes
1
answer
471
views
Why loss of first Syn + Ack from the server will not establish a connection? [duplicate]
In TCP 3-way handshake, 3 segments will be sent (SYN, SYN ACK, ACK). What if loss of syn+ack from the server will not establish a connection? What if the third segment(ACK) is lost? Is the sender ...
-1
votes
1
answer
749
views
Why sender window or congestion window size becomes 2^n mss after nRTT in slow start mechanism?
I seen everywhere in slow start mechanism if initial sender size denoted by cwnd= 1mss , then after 1 RTT cwnd becomes = 2 mss, and after 2 RTT cwnd becomes = 4 mss and so on. My question is why ...
0
votes
1
answer
1k
views
Is really TCP takes 3*RTT time to make a connection?
TCP takes 3 RTT time I have read from one stack overflow answer to make a connection with server. We know that TCP takes triple (Syn, Syn/Ack, Ack) to make a connection by 3-way handshake with server....
0
votes
2
answers
356
views
Why client will send a RESET when it is closed state?
Suppose I have an TCP state transition diagram. And assume that the last ACK is lost. Then, B will think that A did not receive the FIN and will retransmit the FIN. From B point of view this is the ...
0
votes
1
answer
81
views
How a single BGP-process establishes sessions with neighbours in different VRFs?
In VRF-lite solution scenario, when BGP session is established between CE connected to a VRF in PE. The BGP process or in other words TCP server, is listening on port 179(default) for incoming BGP ...
0
votes
2
answers
452
views
Why in the TCP/IP model the link & physical are one?
I'm currently learning about the OSI model and the TCP/IP models, and I was wondering: Why in the TCP/IP model the physical layer and the data link layer are combined?
I'll state how I understand the ...
-1
votes
1
answer
426
views
Why the pseudo-header is not transmitted with the UDP datagram?
I have read from E. Comer - Internetworking with TCP/IP 4th edition that "The purpose of using a pseudo-header is to verify that the UDP datagram has reached its correct destination. The key to ...