• FIN vs RST in TCP connections different


    question:

    The way I understand this, there are 2 ways to close TCP connection:

    • send FIN flag
    • send RST flag

    RST causes immediate connection termination, while in FIN you get a confirmation.

    Do I understand this right, and are there any other distinctions between the two? Can those 2 flags be used together?

    answer:

    • FIN says: "I finished talking to you, but I'll still listen to everything you have to say until you say that you're done."

    • RST says: "There is no conversation. I won't say anything and I won't listen to anything you say."

      RST is useful if you have long lasting TCP connection with little traffic. If one of the computers is restarted, it forgets about the connection, and the other computer gets RST, as soon as it sends another packet.

  • 相关阅读:
    字串变换
    重建道路
    poj3278 Catch That Cow
    机器人搬重物
    [HNOI2004]打鼹鼠
    曼哈顿距离
    邮票面值设计
    poj1101 The Game
    解决了一个堆破坏问题
    模型资源从无到有一条龙式体验
  • 原文地址:https://www.cnblogs.com/ricks/p/9753102.html
Copyright © 2020-2023  润新知