Skip to content

origin

Structs

  • ControlPlaneOrigin - A validated origin for the Firma control plane.
  • LoginCommand - The firma login command that logs in again to a saved connection’s

Enums


Struct

A validated origin for the Firma control plane.

This type accepts only a scheme, host, and optional port. It prevents an operator-supplied value from carrying a path, credentials, query, or fragment into an authorization or token endpoint URL.

Tuple Struct: ()

Methods:

  • fn new(url: Url, validation_mode: OriginValidationMode) -> Result<Self, ControlPlaneOriginError> - Validate url as a control-plane origin for validation_mode.
  • fn saved(connection: &Connection) -> Result<Self, ControlPlaneOriginError> - Validate the origin a saved connection names, under the mode its login
  • fn as_url(self: &Self) -> &Url - Return the validated URL backing this origin.

Traits: Eq

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

firma_login::origin::ControlPlaneOriginError

Section titled “firma_login::origin::ControlPlaneOriginError”

Enum

Why a candidate control-plane origin is unsuitable for native login.

Variants:

  • MissingHost - The URL does not identify a host.
  • UserInfo - The URL includes a user name or password.
  • Path - The URL includes a non-root path.
  • Query - The URL includes a query string.
  • Fragment - The URL includes a fragment.
  • RequiresHttps - The URL uses HTTP outside the explicit local-development mode.
  • DevelopmentHttpRequiresLoopback - The URL uses development HTTP against a non-loopback host.
  • UnsupportedScheme - The URL has a scheme other than HTTP or HTTPS.

Traits: Eq, Error

Trait Implementations:

  • Display
    • fn fmt(self: &Self, __formatter: & mut ::core::fmt::Formatter) -> ::core::fmt::Result
  • From
    • fn from(error: HttpUrlError) -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Struct

The firma login command that logs in again to a saved connection’s Control Plane. A bare firma login targets the hosted one, so the origin is always named.

Traits: Eq

Trait Implementations:

  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Display
    • fn fmt(self: &Self, formatter: & mut fmt::Formatter) -> fmt::Result
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • Clone
    • fn clone(self: &Self) -> Self

Enum

The security policy used to validate a control-plane origin.

Variants:

  • Production - Require HTTPS for every control-plane origin.
  • DevelopmentLoopback - Permit HTTP only when the host is a local loopback address or

Traits: Eq, Copy

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Default
    • fn default() -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result