ExAcme (ExAcme v0.1.0)

View Source

ExAcme is an ACME protocol client for managing SSL certificates.

It provides functionalities to interact with the ACME server, including generating keys, sending ACME requests, and handling directory and nonce information.

Features

  • Start and manage the ExAcme client agent.
  • Fetch directory information and terms of service.
  • Send signed ACME requests.
  • Handle nonce refreshing automatically.

Use the client to interact with ACME endpoints.

Summary

Types

Client process holding directory cache and state

Functions

Returns a specification to start this module under a supervisor.

Retrieves the directory information from the client.

Checks if an external account is required.

Retrieves the profiles from the ACME directory.

Starts the ExAcme client agent with the given options.

Retrieves the terms of service URL from the ACME directory information.

Types

client()

@type client() :: Agent.agent()

Client process holding directory cache and state

Functions

child_spec(arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

directory(client)

@spec directory(Agent.agent()) :: map()

Retrieves the directory information from the client.

Parameters

  • client - The pid or name of the ExAcme client agent.

external_account_required?(client)

@spec external_account_required?(Agent.agent()) :: boolean()

Checks if an external account is required.

Parameters

  • client - The pid or name of the ExAcme client agent.

profiles(client)

@spec profiles(Agent.agent()) :: [map()]

Retrieves the profiles from the ACME directory.

Parameters

  • client - The pid or name of the ExAcme client agent.

send_request(acme_request, account_key, client)

@spec send_request(ExAcme.Request.t(), ExAcme.AccountKey.t(), Agent.agent()) ::
  {:ok, map()} | {:error, any()}

Sends an ACME request.

Parameters

  • acme_request - The ACME request to send.
  • account_key - The account key for signing.
  • client - The ExAcme client agent.

start_link(options)

@spec start_link(Keyword.t()) :: client()

Starts the ExAcme client agent with the given options.

Options

  • :directory_url - The URL of the ACME directory.
  • :finch - The module name or pid of the Finch HTTP client to use.

terms_of_service(client)

@spec terms_of_service(Agent.agent()) :: String.t()

Retrieves the terms of service URL from the ACME directory information.

Parameters

  • client - The pid or name of the ExAcme client agent.