LLMNR

acronym

networkingsecurity

Kept in this browser · My desk

Stands for: Link-Local Multicast Name Resolution

Microsoft's multicast name-resolution protocol, described in RFC 4795 (January 2007), with which a Windows host asks every host on its link, on UDP port 5355, for a name that DNS could not resolve.

It is a fallback, and that is its danger: the names that reach it are mostly mistyped or obsolete ones that no legitimate host will answer, so any neighbour that answers first is believed. The answer usually leads the client to offer an NTLM authentication, which is why name poisoning appears in so many intrusions and why CISA and NSA (2023) ask organizations to disable LLMNR where it is not needed. One Group Policy setting turns it off; Microsoft announced in 2022 that it wants mDNS to be the only multicast name protocol on by default.

What it is. RFC 4795, by Bernard Aboba, Dave Thaler and Levon Esibov of Microsoft, January 2007, is Informational: 'It does not specify an Internet standard of any kind'. It documents the protocol Windows uses, beside DNS and NetBIOS, to resolve names when 'conventional DNS name resolution is not possible on the local link', in the words of Microsoft's Windows protocols overview (MS-WPO 7.1.4).

How it works. Queries 'are sent to and received on port 5355', to 224.0.0.252 in IPv4 and FF02::1:3 in IPv6, in the DNS message format with three flags of their own: C (conflict), TC (truncation) and T (tentative). A responder answers only for names it is authoritative for, by unicast UDP back to the sender; the RFC recommends a default TTL of 30 seconds for answers and limiting LLMNR to single-label names. A query for the name fileserv is 26 bytes: an ID, zero flags, one question, the name as 08 66 69 6C 65 73 65 72 76 00, type A and class IN. A poisoned answer repeats the ID (everyone saw it), sets the QR bit, adds an A record with TTL 30 and the responder's own address, 50 bytes in all.

Security, in the RFC's own words. 'multicast LLMNR queries are propagated to all hosts on the link, making it possible for an on-link attacker to spoof LLMNR responses without having to guess the value of the ID field'; 'If an LLMNR query is sent for an off-link host, spoofing a response in a timely way is not difficult, since a legitimate response will never be received'; the threats 'are most serious in wireless networks'. The mitigations it offers (TSIG, IPsec with group keys, DNSSEC) assume pre-arranged security that ordinary networks do not have, and group keys 'do not protect against forgery by an attacker that is a member of the group'. It recommends logging conflicts as forensic evidence.

On the record. MITRE ATT&CK lists LLMNR (UDP 5355) first in T1557.001, Name Resolution Poisoning and SMB Relay: the adversary answers 'as if they know the identity of the requested host', and if the resource requires authentication 'the username and NTLMv2 hash will then be sent'. CISA and NSA's advisory AA23-278A (October 2023) reports that their assessment teams observed LLMNR and NBT-NS enabled in production and that, combined with SMB servers that do not require signing, attackers can reach remote systems 'without needing to capture and crack any hashes'.

Turning it off. The Group Policy setting 'Turn off multicast name resolution' (Computer Configuration, Administrative Templates, Network, DNS Client; registry value EnableMulticast) 'Specifies that link local multicast name resolution (LLMNR) is disabled'; unconfigured, LLMNR stays enabled on all adapters. CISA's countermeasure CM0053 asks first for an assessment of what uses it and whether DNS can replace it. Microsoft's networking blog (22 April 2022) called NetBIOS name resolution and LLMNR 'rarely used' and said their enablement 'needlessly expands the attack surface', set the goal that mDNS be the only multicast name protocol on by default, and noted that “The default LLMNR behavior has not been changed in Windows yet”. What goes wrong: legacy devices or scripts that relied on short names, discovered only after the switch; and disabling LLMNR while leaving NetBIOS on, which keeps the same hole.

Implementation rules worth knowing. RFC 4795 requires that 'LLMNR implementations MUST use a distinct, isolated cache for LLMNR on each interface', so that answers from one link cannot pollute DNS answers, that a DNS server's host answer LLMNR only for its own records, and that 'DNS servers MUST NOT send LLMNR queries in order to resolve DNS queries'. Responders reply to TCP connection attempts with a time to live of one so that off-link senders cannot complete a session. None of those rules addresses the attacker on the link. The WPAD episode shows what LLMNR's reach meant in practice: until Microsoft's MS16-077 update of June 2016, a browser's query for the proxy name wpad fell through to the multicast protocols when DNS had no answer, and the poisoner supplied the proxy configuration.

Neighbours. NetBIOS Name Service, mDNS, DNS suffix search, WPAD, NTLM and SMB signing, and name resolution poisoning as the attack built on all three.

Also known as: link-local multicast name resolution, rfc 4795, llmnr poisoning, llmnr spoofing, port 5355

Sources

← Back to L Back to the glossary