serenity/Kernel/Net
Gunnar Beutner 7272127927 Kernel: Don't process TCP packets out of order
Previously we'd process TCP packets in whatever order we received
them in. In the case where packets arrived out of order we'd end
up passing garbage to the userspace process.

This was most evident for TLS connections:

courage:~ $ git clone https://github.com/SerenityOS/serenity
Cloning into 'serenity'...
remote: Enumerating objects: 178826, done.
remote: Counting objects: 100% (1880/1880), done.
remote: Compressing objects: 100% (907/907), done.
error: RPC failed; curl 56 OpenSSL SSL_read: error:1408F119:SSL
routines:SSL3_GET_RECORD:decryption failed or bad record mac, errno 0
error: 1918 bytes of body are still expected
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: fetch-pack: invalid index-pack output
2021-05-12 13:47:07 +02:00
..
ARP.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
E1000NetworkAdapter.cpp Kernel: Make sure we read all packets 2021-05-01 20:08:08 +02:00
E1000NetworkAdapter.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
EthernetFrameHeader.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
EtherType.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
ICMP.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
IPv4.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
IPv4Socket.cpp Kernel: Avoid allocating KBuffers for TCP packets 2021-05-12 13:47:07 +02:00
IPv4Socket.h Kernel: Avoid allocating KBuffers for TCP packets 2021-05-12 13:47:07 +02:00
IPv4SocketTuple.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
LocalSocket.cpp Kernel: Harden LocalSocket Vector usage against OOM. 2021-05-01 09:10:30 +02:00
LocalSocket.h Kernel+LibC: Implement the socketpair() syscall 2021-04-28 14:19:45 +02:00
LoopbackAdapter.cpp Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
LoopbackAdapter.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
NE2000NetworkAdapter.cpp Everywhere: Use "the SerenityOS developers." in copyright headers 2021-04-29 00:59:26 +02:00
NE2000NetworkAdapter.h Everywhere: Use "the SerenityOS developers." in copyright headers 2021-04-29 00:59:26 +02:00
NetworkAdapter.cpp Kernel: Limit the number of in-flight packet buffers 2021-05-07 16:00:07 +02:00
NetworkAdapter.h Kernel: Limit the number of in-flight packet buffers 2021-05-07 16:00:07 +02:00
NetworkTask.cpp Kernel: Don't process TCP packets out of order 2021-05-12 13:47:07 +02:00
NetworkTask.h Kernel: Avoid deadlock when trying to send packets from the NetworkTask 2021-04-30 23:11:56 +02:00
Routing.cpp Kernel: Use correct destination MAC address for multicast packets 2021-05-10 17:26:17 +02:00
Routing.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
RTL8139NetworkAdapter.cpp AK: Rename adopt() to adopt_ref() 2021-04-23 16:46:57 +02:00
RTL8139NetworkAdapter.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
Socket.cpp Kernel: Harden Socket Vector usage against OOM 2021-05-01 09:10:30 +02:00
Socket.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
TCP.h Kernel: Set MSS option for outbound TCP SYN packets 2021-05-12 13:47:07 +02:00
TCPSocket.cpp Kernel: Set MSS option for outbound TCP SYN packets 2021-05-12 13:47:07 +02:00
TCPSocket.h Kernel: Set MSS option for outbound TCP SYN packets 2021-05-12 13:47:07 +02:00
UDP.h Everything: Move to SPDX license identifiers in all files. 2021-04-22 11:22:27 +02:00
UDPSocket.cpp Kernel: Truncate UDP packets on read 2021-05-06 08:49:35 +02:00
UDPSocket.h Kernel/IPv4: Propagate errors from local port allocation 2021-04-30 15:27:41 +02:00