Local Network Access (LNA) restricts websites from making requests to local/private network resources without user permission. In Firefox, this is gated behind a permission prompt.
The spec defines three address spaces, from most to least public:
93.184.216.34)
192.168.x.x, 10.x.x.x,
172.16-31.x.x)
127.0.0.1, ::1)
A request from a more-public context to a less-public address is considered a local network request and requires permission.
Pick one of the options below and run it in a terminal. Each starts an
HTTP server on localhost:8080 that serves a simple page with
permissive CORS headers, so every test button works out of the box.
Once you see "Listening on http://localhost:8080", you're ready to run the tests below.
localhost,
127.0.0.1, ::1) as trustworthy, so
http:// requests to them are not blocked as mixed
content. However, requests to
private network addresses (192.168.x.x,
10.x.x.x, etc.) over http:// will be
blocked. Use the loopback presets for testing.
Try fetching a local/private network resource. The browser should show a permission prompt.
Load various subresource types from local network addresses.
Embed a local network page in an iframe.
Permissions-PolicyTwo policy-controlled features gate LNA:
local-network — controls requests to local
(private) addresses
loopback-network — controls requests to loopback
addresses
Default allowlist is 'self'. Cross-origin iframes need
explicit delegation:
<iframe src="..." allow="local-network"></iframe>