phoenix_client_ssl v0.5.0 PhoenixClientSsl.Plug.ExtractClientCertificate
This Plug extracts the TLS Client Certificate from eligible connections.
Installation
The plug can be installed in any pipeline
of the Phoenix Router. It takes no options.
defmodule Aceme.Web.Router do
use Acme.Web, :router
pipeline :api do
plug :accepts, ["json"]
# This line enables the plug
plug PhoenixClientSsl.Plug.ExtractClientCertificate
end
scope "/", Acme.Web do
pipe_through :api
get "/", SomeController, :index
end
end
Link to this section Summary
Link to this section Functions
Link to this function
call(conn, options)
Extract TLS Client Certificate from Connection.
Skipping if either the certificate is already set, the socket is non-ssl,
or if the connection adapter is not Plug.Adapters.Cowboy.Conn
or Plug.Cowboy.Conn
Link to this function
init(list)
No configuration needed.