Documentation
¶
Overview ¶
Package browser provides browser-based authentication functionality.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsChromeAvailable ¶
func IsChromeAvailable() bool
IsChromeAvailable checks if Chrome or Chromium is available on the system. Returns true if Chrome/Chromium is found at common installation paths.
Types ¶
type AuthResult ¶
AuthResult contains the result of browser-based authentication.
func AuthenticateWithChrome ¶
func AuthenticateWithChrome(targetURL string, authHostname string, timeout time.Duration, env map[string]string) (*AuthResult, error)
AuthenticateWithChrome opens Chrome, navigates to the target URL, waits for authentication to complete, and extracts cookies from the authenticated session.
The user must complete authentication (including Touch ID) in the browser window. The function waits until the browser navigates away from the auth hostname, indicating successful authentication. env is a map of environment variables to set for the browser process (e.g. KRB5CCNAME).