Packet loops occurring due to an attack on UDP-based protocols

Coordination center CERT (computer emergency response team), published warning about series of vulnerabilities in implementations of various application protocols using the UDP protocol as a transport. The vulnerabilities can be used to cause denial of service due to the possibility of looping packets between two hosts. For example, attackers can exhaust available network bandwidth, block network services (for example, by creating high load and exceeding request rate limits), and implement traffic amplifiers for DDoS attacks.

Protocols whose implementations are vulnerable include DNS, NTP, TFTP, Echo (RFC862), Chargen (RFC864) and QOTD (RFC865). Presence of vulnerability (CVE-2024-2169) confirmed in selected products from Cisco, Microsoft, Broadcom, Brother, Honeywell (CVE-2024-1309) and MikroTik. As a workaround to block vulnerabilities, it is recommended to enable spoofing blocking (uRPF), limit access to unnecessary UDP services and configure traffic intensity limitation (rate-limit and QoS).

The vulnerabilities are due to the insecurity of the UDP protocol against address spoofing – if there is no protection against spoofing on transit routers, an attacker can indicate the IP address of an arbitrary server in a UDP packet and send this packet to another server, which will return a response to the specified fake address. The attack method boils down to creating a looping situation in the exchange of packets between servers using vulnerable protocol implementations. For example, in response to an incoming packet, the target server can send a response with an error code, and the server whose address was substituted by the attacker will return its response, which, in turn, will again lead to the return of a packet with an error code. Thus, the servers will endlessly begin to play ping-pong with each other in batches.

It is noteworthy that this type of attack is not new, and in the ntpd time synchronization server, one of the attack options was eliminated back in 2009 (CVE-2009-3563) in versions 4.2.4p8 and 4.2.5. The attack consisted of sending an NTP packet with a fake address and the MODE_PRIVATE flag set, upon processing which the target server returned a response stating that it was impossible to use private mode, leaving the MODE_PRIVATE flag set in the response. Accordingly, the other server also could not process this flag and returned its response, which led to a loop in the exchange of packets between two NTP servers. For the DNS protocol, a warning about the possibility of such an attack published back in 1996.

A global scan of Internet addresses showed that there are currently at least 23 thousand vulnerable TFTP servers, 63 thousand DNS servers, 89 thousand NTP servers, 56 thousand Echo/RFC862 services, 22 thousand Chargen/RFC864 and 21 thousand QOTD/RFC865 services. In the case of NTP servers, it is believed that the unpatched vulnerability is due to the use of very old versions of ntpd, released before 2010. Echo, Chargen and QOTD services are inherently vulnerable due to their architecture. The situation with TFTP and DNS servers requires investigation with their administrators. The atftpd and tftpd servers are not affected by this problem because they use a random source network port number when sending a response. Among the vulnerable DNS servers mentioned dproxy-nexgen. In Microsoft products the problem manifests itself in
WDS (Windows Deployment Services), and in Cisco products the problem is present in 2800 and 2970 series routers.

Thanks for reading: