Skip to main content

Crate loginflow

Crate loginflow 

Source
Expand description

Loginflow drives a target from URL + credentials to a captured session in authjar.

v0.1 substrate: HTML form discovery, browser fill/submit via runtime-headless, TOTP MFA, HTTP fast-path compatible with scald’s LoginFlow, and canary verification.

§Safe Defaults

  • Input size: HTTP bodies are bounded to 1MB by default.
  • Recursion depth: DOM tree recursion is bounded to 128 levels.
  • Outbound network: Loopback and private IP space are allowed for dev targets, but can be restricted via stealth profiles.
  • Process spawning: Browser launches use runtime-headless’s canonical stealth launch defaults and remain overrideable.
  • Filesystem writes: Output is written strictly to the configured authjar store; no other filesystem access occurs.

Re-exports§

pub use capture::capture_from_auth_session;
pub use capture::CapturedSession;
pub use capture::ScaldAuth;
pub use discover::discover_best_login_form;
pub use discover::discover_best_oauth_entry;
pub use discover::discover_login_forms_in_html;
pub use discover::discover_oauth_entry_points;
pub use discover::DiscoveredForm;
pub use discover::DiscoveredOAuth;
pub use discover::FormMethod;
pub use drive::follow_oauth_redirect_chain;
pub use drive::oauth_redirect_client;
pub use drive::CaptchaChallenge;
pub use drive::CaptchaError;
pub use drive::CaptchaKind;
pub use drive::CaptchaSolution;
pub use drive::CaptchaSolver;
pub use drive::OAuthChainResult;
pub use drive::RedirectHop;
pub use drive::StubCaptchaSolver;
pub use error::BuildError;
pub use error::CaptureError;
pub use error::DiscoverError;
pub use error::DriveError;
pub use error::HttpLoginError;
pub use error::LoginFlowError;
pub use error::MfaError;
pub use error::VerifyError;
pub use http_fastpath::eligible_for_http_fastpath;
pub use http_fastpath::perform_http_login;
pub use http_fastpath::ScaldLoginFlow;
pub use mfa::totp_code_at;
pub use mfa::MfaPrompt;
pub use mfa::MfaResponse;
pub use mfa::MfaSource;
pub use mfa::TotpMfaSource;
pub use mfa::TotpSecret;
pub use verify::verify_canary;
pub use verify::CanaryConfig;

Modules§

capture
Post-login session capture into authjar and scald wire types.
discover
Login form discovery from HTML.
drive
Login execution: HTTP OAuth chains and browser form drive.
error
Error types for loginflow.
http_fastpath
scald-compatible HTTP form POST fast path (no browser).
mfa
MFA sources and helpers.
verify
Post-login verification.

Structs§

Credentials
Credentials for a single login attempt.
LoginFlow
Configured login driver (opaque builder output).
LoginFlowBuilder
Builder for LoginFlow.