what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

Linux / FreeBSD TCP-Based Denial Of Service

Linux / FreeBSD TCP-Based Denial Of Service
Posted Jun 18, 2019
Authored by Jonathan Looney | Site netflix.com

Netflix has identified several TCP networking vulnerabilities in FreeBSD and Linux kernels. The vulnerabilities specifically relate to the minimum segment size (MSS) and TCP Selective Acknowledgement (SACK) capabilities. The most serious, dubbed _"SACK Panic_," allows a remotely-triggered kernel panic on recent Linux kernels. There are patches that address most of these vulnerabilities. If patches can not be applied, certain mitigations will be effective.

tags | advisory, kernel, tcp, vulnerability
systems | linux, freebsd, bsd
advisories | CVE-2019-11477, CVE-2019-11478, CVE-2019-11479, CVE-2019-5599
SHA-256 | 2842c96d7b20ef5dfb0f2ea06c76a1334026b1cbd1953a2b31793af5c8fa3ba7

Linux / FreeBSD TCP-Based Denial Of Service

Change Mirror Download
# Advisory
###### ID: NFLX-2019-001

###### Title: Linux and FreeBSD Kernel: Multiple TCP-based remote denial of service vulnerabilities

###### Release Date: 2019-06-17

###### Severity: Critical

### Overview:

Netflix has identified several TCP networking vulnerabilities in FreeBSD and Linux kernels.

The vulnerabilities specifically relate to the minimum segment size (MSS) and TCP Selective Acknowledgement (SACK) capabilities. The most serious, dubbed _“SACK Panic_,” allows a remotely-triggered kernel panic on recent Linux kernels.

There are patches that address most of these vulnerabilities. If patches can not be applied, certain mitigations will be effective. We recommend that affected parties enact one of those described below, based on their environment.

### Details:

#### 1: [CVE-2019-11477](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-11477): SACK Panic (Linux >= 2.6.29)

__Description:__
A sequence of SACKs may be crafted such that one can trigger an integer overflow, leading to a kernel panic.

__Fix:__ Apply the patch [PATCH_net_1_4.patch](2019-001/PATCH_net_1_4.patch). Additionally, versions of the Linux kernel up to, and including, 4.14 require a second patch [PATCH_net_1a.patch](2019-001/PATCH_net_1a.patch).

__Workaround #1:__ Block connections with a low MSS using one of the supplied [filters](2019-001/block-low-mss/README.md). (The values in the filters are examples. You can apply a higher or lower limit, as appropriate for your environment.) Note that these filters may break legitimate connections which rely on a low MSS. Also, note that this mitigation is only effective if TCP probing is disabled (that is, the `net.ipv4.tcp_mtu_probing` sysctl is set to 0, which appears to be the default value for that sysctl).

__Workaround #2:__ Disable SACK processing (`/proc/sys/net/ipv4/tcp_sack` set to 0).

(Note that either workaround should be sufficient on its own. It is not necessary to apply both workarounds.)


### 2: [CVE-2019-11478](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-11478): SACK Slowness (Linux < 4.15) or Excess Resource Usage (all Linux versions)

__Description:__ It is possible to send a crafted sequence of SACKs which will fragment the TCP retransmission queue. On Linux kernels prior to 4.15, an attacker may be able to further exploit the fragmented queue to cause an expensive linked-list walk for subsequent SACKs received for that same TCP connection.

__Fix:__ Apply the patch [PATCH_net_2_4.patch](2019-001/PATCH_net_2_4.patch)

__Workaround #1:__ Block connections with a low MSS using one of the supplied [filters](2019-001/block-low-mss/README.md). (The values in the filters are examples. You can apply a higher or lower limit, as appropriate for your environment.) Note that these filters may break legitimate connections which rely on a low MSS. Also, note that this mitigation is only effective if TCP probing is disabled (that is, the `net.ipv4.tcp_mtu_probing` sysctl is set to 0, which appears to be the default value for that sysctl).

__Workaround #2:__ Disable SACK processing (`/proc/sys/net/ipv4/tcp_sack` set to 0).

(Note that either workaround should be sufficient on its own. It is not necessary to apply both workarounds.)


### 3: [CVE-2019-5599](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-5599): SACK Slowness (FreeBSD 12 using the RACK TCP Stack)

__Description:__ It is possible to send a crafted sequence of SACKs which will fragment the RACK send map. An attacker may be able to further exploit the fragmented send map to cause an expensive linked-list walk for subsequent SACKs received for that same TCP connection.

__Workaround #1:__ Apply the patch [split_limit.patch](2019-001/split_limit.patch) and set the `net.inet.tcp.rack.split_limit` sysctl to a reasonable value to limit the size of the SACK table.

__Workaround #2:__ Temporarily disable the RACK TCP stack.

(Note that either workaround should be sufficient on its own. It is not necessary to apply both workarounds.)


### 4: [CVE-2019-11479](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-11479): Excess Resource Consumption Due to Low MSS Values (all Linux versions)

__Description:__ An attacker can force the Linux kernel to segment its responses into multiple TCP segments, each of which contains only 8 bytes of data. This drastically increases the bandwidth required to deliver the same amount of data. Further, it consumes additional resources (CPU and NIC processing power). This attack requires continued effort from the attacker and the impacts will end shortly after the attacker stops sending traffic.

__Fix:__ Two patches [PATCH_net_3_4.patch](2019-001/PATCH_net_3_4.patch) and [PATCH_net_4_4.patch](2019-001/PATCH_net_4_4.patch) add a sysctl which enforces a minimum MSS, set by the `net.ipv4.tcp_min_snd_mss` sysctl. This lets an administrator enforce a minimum MSS appropriate for their applications.

__Workaround:__ Block connections with a low MSS using one of the supplied [filters](2019-001/block-low-mss/README.md). (The values in the filters are examples. You can apply a higher or lower limit, as appropriate for your environment.) Note that these filters may break legitimate connections which rely on a low MSS. Also, note that this mitigation is only effective if TCP probing is disabled (that is, the `net.ipv4.tcp_mtu_probing` sysctl is set to 0, which appears to be the default value for that sysctl).


### Note:
Good system and application coding and configuration practices (limiting write buffers to the necessary level, monitoring connection memory consumption via SO_MEMINFO, and aggressively closing misbehaving connections) can help to limit the impact of attacks against these kinds of vulnerabilities.


## Acknowledgments:
Originally reported by Jonathan Looney.

We thank Eric Dumazet for providing Linux fixes and support.

We thank Bruce Curtis for providing the Linux filters.

We thank Jonathan Lemon and Alexey Kodanev for helping to improve the Linux patches.

We gratefully acknowledge the assistance of Tyler Hicks in testing fixes, refining the information about vulnerable versions, and providing assistance during the disclosure process.

Login or Register to add favorites

File Archive:

April 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Apr 1st
    10 Files
  • 2
    Apr 2nd
    26 Files
  • 3
    Apr 3rd
    40 Files
  • 4
    Apr 4th
    6 Files
  • 5
    Apr 5th
    26 Files
  • 6
    Apr 6th
    0 Files
  • 7
    Apr 7th
    0 Files
  • 8
    Apr 8th
    22 Files
  • 9
    Apr 9th
    14 Files
  • 10
    Apr 10th
    10 Files
  • 11
    Apr 11th
    13 Files
  • 12
    Apr 12th
    14 Files
  • 13
    Apr 13th
    0 Files
  • 14
    Apr 14th
    0 Files
  • 15
    Apr 15th
    30 Files
  • 16
    Apr 16th
    10 Files
  • 17
    Apr 17th
    22 Files
  • 18
    Apr 18th
    45 Files
  • 19
    Apr 19th
    8 Files
  • 20
    Apr 20th
    0 Files
  • 21
    Apr 21st
    0 Files
  • 22
    Apr 22nd
    11 Files
  • 23
    Apr 23rd
    68 Files
  • 24
    Apr 24th
    23 Files
  • 25
    Apr 25th
    0 Files
  • 26
    Apr 26th
    0 Files
  • 27
    Apr 27th
    0 Files
  • 28
    Apr 28th
    0 Files
  • 29
    Apr 29th
    0 Files
  • 30
    Apr 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close