tls_connection

Types


ciphers() = [ssl_cipher:erl_cipher_suite()] | string()

connect_option() = socket_connect_option()
                         | ssl_option()
                         | transport_option()

listen_option() = socket_listen_option()
                        | ssl_option()
                        | transport_option()

path() = string()

prf_random() = client_random | server_random

reason() = term()

socket_connect_option() = gen_tcp:connect_option()

socket_listen_option() = gen_tcp:listen_option()

ssl_imp() = new | old

ssl_option() = {versions, ssl_record:ssl_atom_version()}
                     | {verify, verify_type()}
                     | {verify_fun,
                        {function(), InitialUserState :: term()}}
                     | {fail_if_no_peer_cert, boolean()}
                     | {depth, integer()}
                     | {cert, Der :: binary()}
                     | {certfile, path()}
                     | {key, Der :: binary()}
                     | {keyfile, path()}
                     | {password, string()}
                     | {cacerts, [Der :: binary()]}
                     | {cacertfile, path()}
                     | {dh, Der :: binary()}
                     | {dhfile, path()}
                     | {user_lookup_fun,
                        {function(), InitialUserState :: term()}}
                     | {psk_identity, string()}
                     | {srp_identity, {string(), string()}}
                     | {ciphers, ciphers()}
                     | {ssl_imp, ssl_imp()}
                     | {reuse_sessions, boolean()}
                     | {reuse_session, function()}
                     | {hibernate_after, integer() | undefined}
                     | {next_protocols_advertised, [binary()]}
                     | {client_preferred_next_protocols,
                        binary(),
                        client | server,
                        [binary()]}

sslsocket() = #sslsocket{}

transport_option() =
            {cb_info,
             {CallbackModule :: atom(),
              DataTag :: atom(),
              ClosedTag :: atom(),
              ErrTag :: atom()}}

verify_type() = verify_none | verify_peer

Functions


start_fsm(Role, Host, Port, Socket, Opts, User, CbInfo, Timeout) -> term()

send_handshake(Handshake, State) -> term()

send_alert(Alert, State) -> term()

send_change_cipher(Msg, State) -> term()

start_link(Role::atom(), Host::host(), Port::port_number() (see module inet), Socket::port(), Options::list(), User::pid(), CbInfo::tuple()) -> {ok, pid()} | ignore | {error, reason()}

init(X1) -> term()

hello(Hello, State) -> term()

abbreviated(Msg, State) -> term()

certify(Msg, State) -> term()

cipher(Msg, State) -> term()

connection(Hello_request, State) -> term()

handle_event(Event, StateName, State) -> term()

handle_sync_event(Event, From, StateName, State) -> term()

handle_info(Msg, StateName, State) -> term()

terminate(Reason, StateName, State) -> term()

code_change(OldVsn, StateName, State0, X4) -> term()

format_status(Type, Data) -> term()

next_state(Current, Next, Alert, State) -> term()

next_record(State) -> term()

next_record_if_active(State) -> term()

next_state_connection(StateName, State) -> term()

passive_receive(State0, StateName) -> term()

read_application_data(Data, State) -> term()

write_application_data(Data0, From, State) -> term()

renegotiate(State) -> term()

alert_user(Transport, Tracker, Socket, X4, Opts, Pid, From, Alert, Role) -> term()

alert_user(Transport, Tracker, Socket, From, Alert, Role) -> term()

handle_own_alert(Alert, Version, StateName, State) -> term()

handle_normal_shutdown(Alert, StateName, State) -> term()

handle_unexpected_message(Msg, Info, State) -> term()

handle_close_alert(Data, StateName, State0) -> term()

workaround_transport_delivery_problems(Socket, Transport) -> term()