Skip to main content

Module loopback

Module loopback 

Source
Expand description

Desktop loopback redirect capture (RFC 8252 §7.3).

Binds 127.0.0.1:<ephemeral>, builds the authorization URL with PKCE (S256) and a single-use state, then captures exactly one redirect: the listener serves one response and shuts down.

Structs§

CapturedCode
Result of a captured redirect.
LoopbackFlow
A started loopback flow: the authorization URL to open plus the capture server waiting on an ephemeral loopback port.

Enums§

LoopbackError
Errors from the loopback capture flow.

Constants§

CALLBACK_PATH
Fixed callback path for the redirect URI.
LOOPBACK_HOST
Loopback host the capture server binds (never a routable interface).

Functions§

build_authorization_url
Build the browser authorization URL (RFC 8252 style; the user opens it externally) with PKCE S256, state, scopes, and an optional login hint.
loopback_redirect_uri
The redirect URI for a loopback port: http://127.0.0.1:<port>/cb.