oathkeeper: github.com/ory/oathkeeper/internal/httpclient/models Index | Files

package models

import "github.com/ory/oathkeeper/internal/httpclient/models"

Index

Package Files

health_not_ready_status.go health_status.go json_web_key.go json_web_key_set.go rule.go rule_handler.go rule_match.go upstream.go version.go

type HealthNotReadyStatus Uses

type HealthNotReadyStatus struct {

    // Errors contains a list of errors that caused the not ready status.
    Errors map[string]string `json:"errors,omitempty"`
}

HealthNotReadyStatus health not ready status

swagger:model healthNotReadyStatus

func (*HealthNotReadyStatus) MarshalBinary Uses

func (m *HealthNotReadyStatus) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*HealthNotReadyStatus) UnmarshalBinary Uses

func (m *HealthNotReadyStatus) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*HealthNotReadyStatus) Validate Uses

func (m *HealthNotReadyStatus) Validate(formats strfmt.Registry) error

Validate validates this health not ready status

type HealthStatus Uses

type HealthStatus struct {

    // Status always contains "ok".
    Status string `json:"status,omitempty"`
}

HealthStatus health status

swagger:model healthStatus

func (*HealthStatus) MarshalBinary Uses

func (m *HealthStatus) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*HealthStatus) UnmarshalBinary Uses

func (m *HealthStatus) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*HealthStatus) Validate Uses

func (m *HealthStatus) Validate(formats strfmt.Registry) error

Validate validates this health status

type JSONWebKey Uses

type JSONWebKey struct {

    // The "alg" (algorithm) parameter identifies the algorithm intended for
    // use with the key.  The values used should either be registered in the
    // IANA "JSON Web Signature and Encryption Algorithms" registry
    // established by [JWA] or be a value that contains a Collision-
    // Resistant Name.
    Alg string `json:"alg,omitempty"`

    // crv
    Crv string `json:"crv,omitempty"`

    // d
    D   string `json:"d,omitempty"`

    // dp
    Dp  string `json:"dp,omitempty"`

    // dq
    Dq  string `json:"dq,omitempty"`

    // e
    E   string `json:"e,omitempty"`

    // k
    K   string `json:"k,omitempty"`

    // The "kid" (key ID) parameter is used to match a specific key.  This
    // is used, for instance, to choose among a set of keys within a JWK Set
    // during key rollover.  The structure of the "kid" value is
    // unspecified.  When "kid" values are used within a JWK Set, different
    // keys within the JWK Set SHOULD use distinct "kid" values.  (One
    // example in which different keys might use the same "kid" value is if
    // they have different "kty" (key type) values but are considered to be
    // equivalent alternatives by the application using them.)  The "kid"
    // value is a case-sensitive string.
    Kid string `json:"kid,omitempty"`

    // The "kty" (key type) parameter identifies the cryptographic algorithm
    // family used with the key, such as "RSA" or "EC". "kty" values should
    // either be registered in the IANA "JSON Web Key Types" registry
    // established by [JWA] or be a value that contains a Collision-
    // Resistant Name.  The "kty" value is a case-sensitive string.
    Kty string `json:"kty,omitempty"`

    // n
    N   string `json:"n,omitempty"`

    // p
    P   string `json:"p,omitempty"`

    // q
    Q   string `json:"q,omitempty"`

    // qi
    Qi  string `json:"qi,omitempty"`

    // The "use" (public key use) parameter identifies the intended use of
    // the public key. The "use" parameter is employed to indicate whether
    // a public key is used for encrypting data or verifying the signature
    // on data. Values are commonly "sig" (signature) or "enc" (encryption).
    Use string `json:"use,omitempty"`

    // x
    X   string `json:"x,omitempty"`

    // The "x5c" (X.509 certificate chain) parameter contains a chain of one
    // or more PKIX certificates [RFC5280].  The certificate chain is
    // represented as a JSON array of certificate value strings.  Each
    // string in the array is a base64-encoded (Section 4 of [RFC4648] --
    // not base64url-encoded) DER [ITU.X690.1994] PKIX certificate value.
    // The PKIX certificate containing the key value MUST be the first
    // certificate.
    X5c []string `json:"x5c"`

    // y
    Y   string `json:"y,omitempty"`
}

JSONWebKey json web key

swagger:model jsonWebKey

func (*JSONWebKey) MarshalBinary Uses

func (m *JSONWebKey) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*JSONWebKey) UnmarshalBinary Uses

func (m *JSONWebKey) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*JSONWebKey) Validate Uses

func (m *JSONWebKey) Validate(formats strfmt.Registry) error

Validate validates this json web key

type JSONWebKeySet Uses

type JSONWebKeySet struct {

    // The value of the "keys" parameter is an array of JWK values.  By
    // default, the order of the JWK values within the array does not imply
    // an order of preference among them, although applications of JWK Sets
    // can choose to assign a meaning to the order for their purposes, if
    // desired.
    Keys []*JSONWebKey `json:"keys"`
}

JSONWebKeySet json web key set

swagger:model jsonWebKeySet

func (*JSONWebKeySet) MarshalBinary Uses

func (m *JSONWebKeySet) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*JSONWebKeySet) UnmarshalBinary Uses

func (m *JSONWebKeySet) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*JSONWebKeySet) Validate Uses

func (m *JSONWebKeySet) Validate(formats strfmt.Registry) error

Validate validates this json web key set

type Rule Uses

type Rule struct {

    // Authenticators is a list of authentication handlers that will try and authenticate the provided credentials.
    // Authenticators are checked iteratively from index 0 to n and if the first authenticator to return a positive
    // result will be the one used.
    //
    // If you want the rule to first check a specific authenticator  before "falling back" to others, have that authenticator
    // as the first item in the array.
    Authenticators []*RuleHandler `json:"authenticators"`

    // authorizer
    Authorizer *RuleHandler `json:"authorizer,omitempty"`

    // Description is a human readable description of this rule.
    Description string `json:"description,omitempty"`

    // ID is the unique id of the rule. It can be at most 190 characters long, but the layout of the ID is up to you.
    // You will need this ID later on to update or delete the rule.
    ID  string `json:"id,omitempty"`

    // match
    Match *RuleMatch `json:"match,omitempty"`

    // Mutators is a list of mutation handlers that transform the HTTP request. A common use case is generating a new set
    // of credentials (e.g. JWT) which then will be forwarded to the upstream server.
    //
    // Mutations are performed iteratively from index 0 to n and should all succeed in order for the HTTP request to be forwarded.
    Mutators []*RuleHandler `json:"mutators"`

    // upstream
    Upstream *Upstream `json:"upstream,omitempty"`
}

Rule swaggerRule is a single rule that will get checked on every HTTP request.

swagger:model rule

func (*Rule) MarshalBinary Uses

func (m *Rule) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Rule) UnmarshalBinary Uses

func (m *Rule) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Rule) Validate Uses

func (m *Rule) Validate(formats strfmt.Registry) error

Validate validates this rule

type RuleHandler Uses

type RuleHandler struct {

    // Config contains the configuration for the handler. Please read the user
    // guide for a complete list of each handler's available settings.
    Config interface{} `json:"config,omitempty"`

    // Handler identifies the implementation which will be used to handle this specific request. Please read the user
    // guide for a complete list of available handlers.
    Handler string `json:"handler,omitempty"`
}

RuleHandler rule handler

swagger:model ruleHandler

func (*RuleHandler) MarshalBinary Uses

func (m *RuleHandler) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*RuleHandler) UnmarshalBinary Uses

func (m *RuleHandler) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*RuleHandler) Validate Uses

func (m *RuleHandler) Validate(formats strfmt.Registry) error

Validate validates this rule handler

type RuleMatch Uses

type RuleMatch struct {

    // An array of HTTP methods (e.g. GET, POST, PUT, DELETE, ...). When ORY Oathkeeper searches for rules
    // to decide what to do with an incoming request to the proxy server, it compares the HTTP method of the incoming
    // request with the HTTP methods of each rules. If a match is found, the rule is considered a partial match.
    // If the matchesUrl field is satisfied as well, the rule is considered a full match.
    Methods []string `json:"methods"`

    // This field represents the URL pattern this rule matches. When ORY Oathkeeper searches for rules
    // to decide what to do with an incoming request to the proxy server, it compares the full request URL
    // (e.g. https://mydomain.com/api/resource) without query parameters of the incoming
    // request with this field. If a match is found, the rule is considered a partial match.
    // If the matchesMethods field is satisfied as well, the rule is considered a full match.
    //
    // You can use regular expressions in this field to match more than one url. Regular expressions are encapsulated in
    // brackets < and >. The following example matches all paths of the domain `mydomain.com`: `https://mydomain.com/<.*>`.
    URL string `json:"url,omitempty"`
}

RuleMatch rule match

swagger:model ruleMatch

func (*RuleMatch) MarshalBinary Uses

func (m *RuleMatch) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*RuleMatch) UnmarshalBinary Uses

func (m *RuleMatch) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*RuleMatch) Validate Uses

func (m *RuleMatch) Validate(formats strfmt.Registry) error

Validate validates this rule match

type Upstream Uses

type Upstream struct {

    // PreserveHost, if false (the default), tells ORY Oathkeeper to set the upstream request's Host header to the
    // hostname of the API's upstream's URL. Setting this flag to true instructs ORY Oathkeeper not to do so.
    PreserveHost bool `json:"preserve_host,omitempty"`

    // StripPath if set, replaces the provided path prefix when forwarding the requested URL to the upstream URL.
    StripPath string `json:"strip_path,omitempty"`

    // URL is the URL the request will be proxied to.
    URL string `json:"url,omitempty"`
}

Upstream upstream

swagger:model Upstream

func (*Upstream) MarshalBinary Uses

func (m *Upstream) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Upstream) UnmarshalBinary Uses

func (m *Upstream) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Upstream) Validate Uses

func (m *Upstream) Validate(formats strfmt.Registry) error

Validate validates this upstream

type Version Uses

type Version struct {

    // Version is the service's version.
    Version string `json:"version,omitempty"`
}

Version version

swagger:model version

func (*Version) MarshalBinary Uses

func (m *Version) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*Version) UnmarshalBinary Uses

func (m *Version) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*Version) Validate Uses

func (m *Version) Validate(formats strfmt.Registry) error

Validate validates this version

Package models imports 4 packages (graph) and is imported by 3 packages. Updated 2020-05-29. Refresh now. Tools for package owners.