network-protocols Computer Science

11 个科学问题 · 计算机 Computer Science

本页目录

TCP 的慢启动阶段是如何逐步扩大拥塞窗口的?

How does TCP's slow-start phase gradually grow the congestion window?

连接初始拥塞窗口很小,每当接收到一个确认就把拥塞窗口增加一个报文段,使窗口随往返次数呈指数增长。当窗口达到慢启动阈值或检测到丢包时,算法转入拥塞避免阶段改为线性增长。
The connection starts with a small congestion window and increments it by one segment for each acknowledgment received, so the window grows exponentially with each round trip. Once the window reaches the slow-start threshold or loss is detected, the algorithm switches to congestion avoidance and grows linearly.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-11-03
来源 · Source

RFC 5681 (TCP Congestion Control) 与 Kurose《计算机网络》第3章

RFC 5681 (TCP Congestion Control) and J. Kurose, K. Ross, Computer Networking, 7th ed., Chapter 3

#TCP #拥塞控制 #慢启动

当 IP 数据包超过链路 MTU 时,网络层如何处理分片与重组?

When an IP packet exceeds the link MTU, how does the network layer handle fragmentation and reassembly?

发送方或中间路由器按 MTU 把大数据报切分为多个分片,每个分片携带相同的标识字段、各自的片偏移与标志位。只有目的主机依据标识、偏移和标志把属于同一数据报的分片重新组装成原始报文,中间路由器不做重组。
The sender or an intermediate router splits a large datagram into fragments sized to the MTU, each carrying the same identification field with its own fragment offset and flags. Only the destination host reassembles the original datagram from fragments using the identification, offset, and flags; intermediate routers do not reassemble.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-11-05
来源 · Source

互联网工程任务组(IETF),《Internet Protocol》,RFC 791,1981 (DOI: 10.17487/rfc791)

IETF, 'Internet Protocol', RFC 791, 1981, DOI: 10.17487/rfc791

#IP #分片 #MTU

UDP 与 TCP 在传输特性上的关键差异是什么?

What are the key differences in transport characteristics between UDP and TCP?

TCP 提供面向连接、可靠有序且带流量与拥塞控制的字节流服务;UDP 是无连接、尽力交付的数据报协议,不保证到达顺序也不重传丢失报文。因此 UDP 开销更低、延迟更小,适合实时音视频等对时延敏感的场景。
TCP offers a connection-oriented, reliable, ordered byte stream with flow and congestion control, whereas UDP is a connectionless, best-effort datagram protocol that gives no ordering or retransmission guarantees. UDP therefore has lower overhead and latency, suiting delay-sensitive uses like real-time audio and video.
难度 进阶 · 适合 初中(12-15) CC BY 4.0 · 已核验 · Verified 2026-11-02
来源 · Source

Kurose《计算机网络:自顶向下方法》第3章 (机械工业出版社)

J. Kurose, K. Ross, Computer Networking: A Top-Down Approach, 7th ed., Chapter 3 (Transport Layer)

#UDP #TCP #传输层

为什么 TCP 建立连接需要三次握手而不是两次?

Why does TCP require a three-way handshake to establish a connection rather than two?

三次握手让客户端和服务器各自确认对方的发送与接收能力都正常:客户端发 SYN,服务器回 SYN-ACK,客户端再回 ACK。若只用两次握手,服务器无法确认客户端的接收能力,可能建立无效连接并浪费资源。
The three-way handshake lets both client and server confirm each other's send and receive capability: the client sends SYN, the server replies SYN-ACK, and the client returns ACK. With only two steps the server cannot confirm the client's receive ability, risking a wasted half-open connection.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-11-02
来源 · Source

Kurose《计算机网络:自顶向下方法》第3章 (机械工业出版社)

J. Kurose, K. Ross, Computer Networking: A Top-Down Approach, 7th ed., Chapter 3 (Transport Layer)

#TCP #三次握手 #连接

HTTP 状态码的五大类别各自代表什么含义?

What do the five classes of HTTP status codes represent?

状态码由三位数字组成:1xx 表示信息提示,2xx 表示成功,3xx 表示重定向,4xx 表示客户端错误,5xx 表示服务器错误。通过首位数字即可快速判断请求的处理结果属于哪一类。
A status code is a three-digit number: 1xx indicates informational, 2xx success, 3xx redirection, 4xx client error, and 5xx server error. The leading digit alone tells you which broad class the outcome belongs to.
难度 进阶 · 适合 初中(12-15) CC BY 4.0 · 来源待核验 · Source pending review
来源 · Source

出处备注:此条未指向带版次的可引用著作(通识性内容、机构文件或未展开的英文书名),本库不提供独立书目出处;如需精确引用,需由编辑补全具体篇目与版次。

RFC 7231 (HTTP/1.1 Semantics) 第6章

RFC 7231 (HTTP/1.1 Semantics and Content), Section 6 (Response Status Codes)

#HTTP #状态码 #REST

在浏览器地址栏输入网址并回车后,大致会经历哪些步骤?

What are the rough steps after you type a URL into a browser and press enter?

浏览器先通过 DNS 把域名解析成 IP,再与服务器建立 TCP 连接(HTTPS 还需 TLS 握手),随后发送 HTTP 请求并接收响应。浏览器解析返回的内容(HTML/CSS/JS)并渲染成页面,期间可能并行加载更多资源。
The browser first resolves the domain to an IP via DNS, then establishes a TCP connection with the server (and a TLS handshake for HTTPS), and sends an HTTP request to receive a response. It parses the returned HTML/CSS/JS and renders the page, often fetching additional resources in parallel.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-11-02
来源 · Source

Kurose《计算机网络:自顶向下方法》第1章 (机械工业出版社)

J. Kurose, K. Ross, Computer Networking: A Top-Down Approach, 7th ed., Chapter 1 (Computer Networks and the Internet)

#浏览器 #DNS #HTTP #渲染

NAT 是什么,为什么需要它?

What is NAT and why is it needed?

NAT(网络地址转换)把内网私有 IP 映射成公网 IP,让多台设备共用一个出口地址,既缓解 IPv4 地址短缺又对外部隐藏内网结构。
NAT maps private internal IPs to a public IP so many devices share one outbound address, easing IPv4 shortage and hiding the internal network from outside.
难度 进阶 · 适合 大众 CC BY 4.0 · 来源待核验 · Source pending review
来源 · Source

出处备注:此条未指向带版次的可引用著作(通识性内容、机构文件或未展开的英文书名),本库不提供独立书目出处;如需精确引用,需由编辑补全具体篇目与版次。

RFC 3022

RFC 3022

#网络 #IP

建立 TCP 连接为什么需要三次握手而不是两次?省略最后一次 ACK 会带来什么问题?

Why does establishing a TCP connection take a three-way handshake instead of two messages, and what goes wrong if the final ACK is omitted?

三次握手的本质是让双方各自确认对方的初始序列号:客户端发送携带自身 ISN 的 SYN,服务器以 SYN+ACK 回应并给出自己的 ISN,客户端最后再补一个 ACK。如果只有两次报文,服务器无法确认客户端收到了自己的序列号,在网络中滞留的旧连接请求一旦迟到就会建立起半开连接,白白占用缓冲区甚至扰乱字节流顺序。因此第三个 ACK 正是过滤历史重复请求、保证双向序列号同步的关键。
The point of the three-way handshake is for both ends to confirm each other's initial sequence number: the client sends a SYN carrying its ISN, the server answers with SYN+ACK supplying its own ISN, and the client closes the loop with an ACK. With only two messages the server can never learn whether the client received its sequence number, so a delayed duplicate connection request arriving late would open a half-open connection that wastes buffer space or scrambles byte-stream ordering. The third ACK is thus the filter against stale duplicates and the guarantee that both directions agree on sequence numbers.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-11-04
来源 · Source

IETF,《Transmission Control Protocol (TCP)》,IETF RFC 9293,2022 (DOI: 10.17487/rfc9293)

IETF, 'Transmission Control Protocol (TCP)', IETF RFC 9293, 2022, DOI: 10.17487/rfc9293

#计算机网络 #TCP 握手

TCP 为何选择加性增、乘性减(AIMD)作为拥塞控制骨架?快速重传相对等待 RTO 超时解决了什么问题?

Why does TCP build its congestion control on additive-increase multiplicative-decrease (AIMD), and what problem does fast retransmit solve compared with waiting for an RTO timeout?

AIMD 探测带宽时线性增大窗口,一旦丢包即减半,该策略可收敛到公平且高效的带宽共享,是分布式优化的经典结论。快速重传依据三个重复 ACK 立刻补发缺失报文,无需等 RTO 超时,避免连接跌回慢启动。CUBIC 与 BBR 又分别用三次增长曲线和带宽-RTT 显式建模进一步优化了 Reno 式调节。
AIMD raises the window linearly while probing for bandwidth and halves it upon loss, a policy proven to converge to fair and efficient sharing — a classic result in distributed optimization. Fast retransmit resends the missing segment immediately after three duplicate ACKs rather than waiting out the RTO, sparing the connection a collapse back into slow start. CUBIC and BBR later refined Reno-style dynamics with cubic growth curves and explicit bandwidth-RTT modeling respectively.
难度 进阶 · 适合 初中(12-15) CC BY 4.0 · 已核验 · Verified 2026-10-03 · 2 条独立证据
来源 · Source

Kurose 与 Ross《Computer Networking: A Top-Down Approach》传输层章节;Allman、Paxson 与 Blanton,RFC 5681《TCP Congestion Control》

Kurose & Ross, Computer Networking: A Top-Down Approach, transport-layer chapter; Allman, Paxson & Blanton, RFC 5681, TCP Congestion Control

#TCP/IP 协议栈 #拥塞控制

TCP 靠哪些机制保证可靠传输?四次挥手为什么需要四个报文,主动关闭方为何还要在 TIME_WAIT 状态停留一段时间?

Which mechanisms make TCP delivery reliable, and why does connection teardown take four segments, with the active closer lingering in TIME_WAIT?

可靠性由序号加确认应答、超时重传、滑动窗口流量控制以及拥塞控制共同保证:接收端逐段确认,发送方对丢失段退避重发,自适应的 RTT 估计驱动重传定时器。四次挥手是因为 TCP 全双工,两个方向的数据流必须各自单独关闭,一方收到 FIN 并回 ACK 后仍可继续发送剩余数据(半关闭)。主动关闭方随后进入 TIME_WAIT 停留 2MSL,确保最后的 ACK 丢失时可重发,并让迷路的旧报文在网络中消亡,避免污染复用同一四元组的新连接。
Reliability rests on sequence numbers with acknowledgments, retransmission timeouts driven by adaptive RTT estimation, sliding-window flow control, and congestion control: the receiver ACKs every segment and the sender backs off and resends lost ones. Teardown takes four segments because TCP is full-duplex — each direction closes independently, and after answering FIN with ACK a side may still send remaining data (half-close). The active closer then lingers in TIME_WAIT for 2MSL so the final ACK can be retransmitted and stray old packets die out before the same 4-tuple is reused.
难度 进阶 · 适合 大众 CC BY 4.0 · 来源待核验 · Source pending review
来源 · Source

出处备注:作者 / 书名 / 版次 / 出版社 / 年份齐备,仅缺独立比对证据;已在可信度报告单列披露,不再重复核验。

W. Richard Stevens,《TCP/IP Illustrated, Volume 1: The Protocols》,Addison-Wesley,1994

W. Richard Stevens, TCP/IP Illustrated, Volume 1: The Protocols, Addison-Wesley, 1994

#TCP #可靠传输

HTTPS 相比 HTTP 在安全性上主要增加了什么机制?

What security mechanism does HTTPS add over HTTP?

HTTPS 在 HTTP 之下叠加了 TLS/SSL 加密层,对传输内容加密并在握手阶段通过证书验证服务器身份。这使通信内容难以被窃听或篡改,也能防止中间人冒充服务器。
HTTPS layers TLS/SSL beneath HTTP, encrypting the payload and using certificates during the handshake to authenticate the server's identity. This makes the traffic hard to eavesdrop or tamper with and prevents man-in-the-middle impersonation.
难度 进阶 · 适合 初中(12-15) CC BY 4.0 · 已核验 · Verified 2026-11-03
来源 · Source

RFC 2818 (HTTP over TLS) 与 Kurose《计算机网络》第8章

RFC 2818 (HTTP Over TLS) and J. Kurose, K. Ross, Computer Networking, 7th ed., Chapter 8 (Network Security)

#HTTP #HTTPS #TLS