Protocol ExplorerGuidesPricing

Captive Portal Login: DHCP Discovery to Internet Access

A Wi-Fi login page is only one stage in a captive network. The device first joins a link, obtains configuration, discovers portal state and then relies on network enforcement to grant access.

By Protocol Explorer · Updated

Wi-Fi association does not mean Internet access

A device can authenticate to an access point and associate successfully while the network still blocks most destinations. It can then receive an IP address and DNS configuration but remain subject to a captive access policy.

Treat wireless link state, address configuration and permission for external traffic as separate layers. This prevents a successful Wi-Fi password entry from being mistaken for a completed portal login.

DHCP option 114 advertises a portal API URI

RFC 8910 defines a Captive-Portal option for DHCPv4, DHCPv6 and IPv6 Router Advertisements. The option supplies the URI for a Captive Portal API. In DHCPv4, the option code is 114. The API URI is not necessarily the web page the user will see.

A client can learn the URI while it receives network configuration. In dual-stack networks, operators should keep the URI consistent across provisioning methods so a client does not see different portal state depending on its address family.

The API reports whether the client is captive

RFC 8908 defines an HTTPS API whose JSON response includes a captive boolean. If true, the client has not met the network’s access conditions; the response can also include a user-portal URL and session limits. The API uses TLS so the client can authenticate the provisioned endpoint.

The API reports state but does not standardize how a user signs in. The venue may require acceptance of terms, credentials, payment or another action on a separate user-facing portal.

The operator must update enforcement after the user action

After the user completes the venue’s flow, the portal service needs to cause the enforcement device to change the client’s policy. The device can query the API again to confirm captive false. If the API and the enforcement device disagree about the client identity or address, the page can say success while general traffic remains blocked.

RADIUS may participate in enterprise or provider access control, but it is not the same thing as the Captive Portal API. Follow each protocol exchange separately and correlate them through server logs or a shared session identifier.

Why legacy connectivity probes still appear

Older devices and portals may use a known HTTP endpoint or DNS answer to infer captive state. A changed response can trigger a redirect to the login page. This explains why a browser may open a portal without the standardized API being used.

The CAPPORT architecture is designed to avoid forging unrelated DNS or HTTP responses, particularly HTTPS responses, but deployments migrate over time. A visible redirect should be interpreted as evidence of that request path, not proof of a particular operating system detection mechanism.

The API URI can change with network provisioning

A Captive Portal API URI belongs to the current network configuration. RFC 8908 says a client should not assume that the endpoint remains the same when it joins another network; DHCP renewal or a new Router Advertisement can also supply updated information. Re-discovery keeps the device from querying an old venue or session endpoint.

When a device moves between access points, changes address family or reconnects after a lease expires, compare the URI it learned with the API host it actually queried. If the user portal and status API refer to different sessions, a stale endpoint or inconsistent provisioning can make the login loop even when the web form itself works.

Troubleshoot the stage that failed

If no portal appears, check whether the client learned the URI, can resolve and reach the API host, validates its certificate, and receives a valid application/captive+json response. If login succeeds but traffic remains blocked, compare the API state with the enforcement policy and address used by the client.

When only IPv6 or only IPv4 fails, compare the router advertisement and DHCP provisioning, DNS answer, route and enforcement state for that family. A network-side encrypted capture cannot reveal the API JSON; use authorized endpoint logs for the captive state.

Privacy, identifiers and simulation limits

Portal APIs can use per-client identifiers to return the right session state. Stable identifiers and access logs can reveal activity, so operators should protect, minimize and limit retention of that data.

Protocol Explorer’s sequence is scripted, uses illustrative addresses and does not join a wireless network or query a real portal. For an incident, use the standards, operator logs and a capture you are authorized to inspect.

Read the underlying protocol standards

Continue with protocol lessons

How to read a packet

Related guides