erps v0.3.0 Erps.Transport.Tls View Source
implements a two-way TLS transport strategy.
this transport is useful when you have trusted clients and servers that are authenticated against each other and must have an encrypted channel over WAN.
Link to this section Summary
Functions
Callback implementation for Erps.Transport.Api.accept/2
.
Callback implementation for Erps.Transport.Api.connect/3
.
(server) a specialized function that generates a match function option used to verify that the incoming client is bound to a single ip address.
Callback implementation for Erps.Transport.Api.listen/2
, via Erps.Transport.OneWayTls.listen/2
.
Callback implementation for Erps.Transport.Api.send/2
, via :ssl.send/2
.
(client) a specialized function that generates a match function option used to verify that the targetted server is bound to a single ip address.
Callback implementation for Erps.Transport.Api.upgrade!/2
, via Erps.Transport.OneWayTls.upgrade!/2
.
Link to this section Functions
accept(sock, timeout) View Source
Callback implementation for Erps.Transport.Api.accept/2
.
connect(host, port, opts) View Source
Callback implementation for Erps.Transport.Api.connect/3
.
handshake(socket, tls_opts!)
View Source
handshake(:inet.socket(), keyword()) ::
{:ok, Erps.Transport.Api.socket()} | {:error, any()}
handshake(:inet.socket(), keyword()) :: {:ok, Erps.Transport.Api.socket()} | {:error, any()}
(server) a specialized function that generates a match function option used to verify that the incoming client is bound to a single ip address.
listen(port, opts) View Source
Callback implementation for Erps.Transport.Api.listen/2
, via Erps.Transport.OneWayTls.listen/2
.
send(sock, content) View Source
Callback implementation for Erps.Transport.Api.send/2
, via :ssl.send/2
.
single_ip_check(ip)
View Source
single_ip_check(:inet.ip_address()) :: [
{:match_fun, ({:ip, :inet.ip_address()}, {:dNSName, charlist()} -> boolean())}
]
single_ip_check(:inet.ip_address()) :: [ {:match_fun, ({:ip, :inet.ip_address()}, {:dNSName, charlist()} -> boolean())} ]
(client) a specialized function that generates a match function option used to verify that the targetted server is bound to a single ip address.
should be used as in as the :customize_hostname_check
option for clients
upgrade!(sock, opts) View Source
Callback implementation for Erps.Transport.Api.upgrade!/2
, via Erps.Transport.OneWayTls.upgrade!/2
.