View Source Macfly.Macaroon (macfly v0.2.16)

Summary

Types

@type t() :: %Macfly.Macaroon{
  caveats: [Macfly.Caveat.t()],
  location: String.t(),
  nonce: Macfly.Nonce.t(),
  tail: binary()
}

Functions

Link to this function

add_third_party(m, location, tp_key, caveats \\ [])

View Source
@spec add_third_party(t(), String.t(), <<_::256>>, [Macfly.Caveat.t()]) :: t()
@spec attenuate(t(), [Macfly.Caveat.t()]) :: t()
Link to this function

decode(token, options \\ %Options{})

View Source
@spec decode(String.t(), Macfly.Options.t()) :: {:ok, t()} | {:error, any()}
@spec encode(t()) :: String.t()
Link to this function

from_wire(wire_macaroon, options \\ %Options{})

View Source
Link to this function

new(key, kid_or_nonce, location, caveats \\ [])

View Source
@spec new(binary(), binary() | Macfly.Nonce.t(), String.t(), [Macfly.Caveat.t()]) ::
  t()