Kanmai 2020
Kanmai 2020
Zhi Kanmai
School of Engineering and Technology,
Xi'an Fanyi University,
Xi'an 710105, Shaanxi, China
Authorized licensed use limited to: UNIVERSITY OF WESTERN ONTARIO. Downloaded on May 26,2021 at 14:03:06 UTC from IEEE Xplore. Restrictions apply.
• Serve A responds a data segment labeled with ACK,
sequence number b, and confirmation sequence
number a+1 for confirmation of host A ’s FIN
report.Host A intends to terminate the connection, so it
sends a data segment labeled with FIN, ACK, sequence
number b, and confirmation sequence number a+1.
• Serve A responds a data segment labeled with ACK,
sequence number a+1, and confirmation sequence
number b+1 for confirmation of host A’s FIN message.
TCP supports full duplex mode to transmit data, which A. Safety issues o f TCP Protocol
means that data can be transmitted in both directions TCP establish a connection through a three-way handshake.
concurrently. Before data is transmitted, TCP actually It involves the exchanges of three packets of messages. The
establishes a connection in both directions through the three- first is a SYN packet; the second is a SYN/ACK packet,
way handshake. Therefore, after the transmission is completed, indicating that it responds to the first SYN packet while
the connection in both directions must be closed. The continuing the handshake process; the third is just a response,
establishment of a TCP connection is a three-way handshake shown as an ACK packet If Party A is the client (active
process. But the termination process of TCP connection is a participant) and Party B is the recipient, the likely threat will
four-way handshake. probably include the following:
As shown in the figure: • A hacker may ear-drop Party B’s SYN/ACK message.
• Host A intends to terminate the connection, so it sends • The hacker sends RST packet to Party B, followed by
a data segment labeled with FIN, ACT and sequence SYN to fake Party A to establish a new connection.
number a, and confirmation sequence number b.
118
Authorized licensed use limited to: UNIVERSITY OF WESTERN ONTARIO. Downloaded on May 26,2021 at 14:03:06 UTC from IEEE Xplore. Restrictions apply.
• Party B responds to the new connection with III. D e f e n s e o f TCP/IP p r o t o c o l s e c u r it y is s u e s
SYN/ACK.
A. Defense o f TCP protocol security issues
• The hacker fakes Party A once again to send ACK to
Party B. It is rather hard to defend against SYN Flood attacks.
However, the measures can be taken from the following aspects
In this way, the hacker has successfully destroyed the for prevention:
connection. If he takes the opportunity to inject harmful data
packets, it will cause more serious consequences. The data • Set the corresponding kernel parameters to the system
transmitted through the connection by TCP Protocol is seen as to force the system to reset the timeout SYN request
segments with indicated sequence number of 32 32-bit integers. connection packet. At the same time, the system can
The initial sequence number (ISN) is generated at TCP quickly process the invalid SYN request packet by
handshake. The generation mechanism is relevant with the reducing the timeout constant and lengthening the
protocol. The hacker can obtain ISN of the earlier connection waiting queue.
by sending a connection request to the target host. He can
measure the round-trip time between the attacking host and the OSI T C P / IP PD U
target host. Once ISN and RTT of the last connection is known, A p p lic a tio n
E x p re s s io n A p p lic a tio n M e ssag e
it is easy to predict ISN of the next connection. If the attacker D ia lo g u e
pretends to be a trusted host to send a TCP connection to the T ra n sp o rt T ra n sp o rt Segm ent
119
Authorized licensed use limited to: UNIVERSITY OF WESTERN ONTARIO. Downloaded on May 26,2021 at 14:03:06 UTC from IEEE Xplore. Restrictions apply.
frontier knowledge of computer network technology with him, Once again, I would like to thank all the teachers who have
which made me learn a lot of knowledge. helped me in the process of completing this thesis.
Secondly, I would like to thank Miss Zhou wanna for her
rich mathematical knowledge and her great contribution to the References
completion of TCP connection algorithm in computer network [1] Lei Zhenjia. Network Engineer Course [M]. Beijing: Tsinghua
technology. University Press, 2010
[2] Chen Yingming. "Computer Network and Application" [M].
Host a wants to terminate the connection, so it sends a data Metallurgical Industry Press, 2011
segment marked with fin and ACK with sequence number of a [3] Chen Xiren. "Computer Network (2nd Edition)" [M]. Beijing:
and confirmation sequence number of B; server a responds to Metallurgical Industry Press, 2010
a data segment marked with ACK, with sequence number B [4] Lin, Zhou."Computer Network Engineering" [M]. People's Posts and
and confirmation sequence number a + 1, as confirmation of Telecommunications Press, 2013
host a's fin message; server a wants to terminate the [5] Zhang ,Cao. Computer Network Engineering [M]. Dalian University of
connection, so it sends a data segment identifying fin and Technology Press, 2012
ACK with sequence number of B, yes Recognize the sequence [6] (America) Frum, (America) Sivasa Bramanian, (America) Flam. Build a
number as a + 1; host a responds to a data segment marked Cisco Multilayer Switching Network [M]. People's Posts and
Telecommunications Press, 2010.
with ACK, the sequence number is a + 1, and the confirmation
sequence number is B + 1, as the confirmation of the fin
message of server a.
120
Authorized licensed use limited to: UNIVERSITY OF WESTERN ONTARIO. Downloaded on May 26,2021 at 14:03:06 UTC from IEEE Xplore. Restrictions apply.