Behaviours: application
, gen_statem
.
acme_operation() = bin_string()
agent_key_file_info() = {new, bin_file_path()} | bin_file_path()
any_directory_path() = file_utils:any_directory_path()
any_file_path() = file_utils:any_file_path()
application_name() = otp_utils:application_name()
bin_certificate() = binary()
bin_challenge_type() = bin_string()
bin_csr_key() = bin_key()
bin_domain() = net_utils:bin_fqdn()
bin_file_path() = file_utils:bin_file_path()
bin_key() = binary()
bin_san() = bin_string()
bin_string() = text_utils:bin_string()
bin_uri() = web_utils:bin_uri()
binary_b64() = binary()
bridge_spec() = trace_bridge:bridge_spec()
cert_file_path() = pem_file_path()
cert_priv_key_file_path() = pem_file_path()
cert_req_option_id() = async | callback | netopts | challenge_type | sans | json
cert_req_option_map() = table(cert_req_option_id(), term())
certificate_provider() = letsencrypt
certificate_type() = single_domain | wildcard_domain
challenge() = table(bin_string(), bin_string())
challenge_type() = 'http-01' | 'dns-01' | 'tls-sni-01'
creation_callback() = fun((obtain_outcome()) -> void())
creation_outcome() = {certificate_ready, cert_file_path(), cert_priv_key_file_path()} | tagged_error()
That is: {'error', term()}
credentials_path() = any_file_path()
directory_map() = table(acme_operation(), bin_uri())
dns_provider() = ovh
domain_name() = net_utils:string_fqdn() | bin_domain()
environment() = staging | production
error_reason() = basic_utils:error_reason()
event_content() = term()
event_type() = gen_statem:event_type()
file_name() = file_utils:file_name()
fsm_pid() = pid()
json() = json_utils:json()
json_map_decoded() = map()
jws() = #jws{alg = leec:jws_algorithm(), url = option(leec:bin_uri()), kid = option(leec:bin_uri()), jwk = option(leec:tls_public_key()), nonce = option(leec:nonce())}
jws_algorithm() = 'RS256'
key_auth() = binary()
key_integer() = integer() | binary()
leec_caller_state() = {challenge_type(), fsm_pid()}
leec_dns_state() = #leec_dns_state{environment = leec:environment(), state_dir_path = file_utils:bin_directory_path(), work_dir_path = file_utils:bin_directory_path(), certbot_path = file_utils:bin_executable_path(), credentials_dir_path = file_utils:bin_directory_path(), cert_dir_path = file_utils:bin_directory_path(), cert_key_file = option(file_utils:bin_file_path()), domain = option(net_utils:bin_fqdn())}
leec_http_state() = #leec_http_state{environment = leec:environment(), directory_map = option(leec:directory_map()), cert_dir_path = file_utils:bin_directory_path(), cert_key_file = option(file_utils:bin_file_path()), cert_priv_key_path = option(leec:cert_priv_key_file_path()), interfacing_mode = option(leec:web_interfacing_mode()), webroot_dir_path = option(file_utils:bin_directory_path()), port = net_utils:tcp_port(), nonce = option(leec:nonce()), domain = option(net_utils:bin_fqdn()), sans = [leec:san()], agent_key_file_info = option(leec:agent_key_file_info()), agent_private_key = option(leec:tls_private_key()), jws = option(leec:jws()), account_key = option(leec:tls_public_key()), order = option(leec:order_map()), challenges = leec:uri_challenge_map(), cert_req_option_map = leec:cert_req_option_map(), json_parser_state = json_utils:parser_state(), tcp_connection_cache = leec:tcp_connection_cache()}
leec_state() = leec_http_state() | leec_dns_state()
milliseconds() = unit_utils:milliseconds()
nonce() = binary()
obtain_outcome() = async | obtained_outcome()
obtained_outcome() = {certificate_generation_success, cert_file_path(), cert_priv_key_file_path()} | {certificate_generation_failure, error_reason()}
option(T) = basic_utils:option(T)
order_map() = table(bin_string(), bin_uri())
pem_file_path() = bin_file_path()
request() = atom()
rsa_private_key() = [key_integer()]
san() = ustring()
start_common_option() = {environment, environment()} | {work_dir_path, any_directory_path()} | {agent_key_file_path, any_file_path()} | {cert_dir_path, any_directory_path()} | {http_timeout, milliseconds()}
start_dns_01_option() = {dns_provider, dns_provider()} | {cred_dir_path, any_directory_path()}
start_http_01_option() = {interfacing_mode, web_interfacing_mode()} | {webroot_dir_path, any_directory_path()} | {port, tcp_port()}
start_option() = start_common_option() | start_http_01_option() | start_dns_01_option()
start_outcome() = {ok, leec_caller_state()} | basic_utils:tagged_error()
'ok' | gen_statem:start_ret().
state_callback_result() = fsm_utils:state_callback_result(gen_statem:action())
status() = pending | processing | valid | invalid | revoked
table(K, V) = map_hashtable:map_hashtable(K, V)
tagged_error() = basic_utils:tagged_error()
tcp_connection_cache() = table({web_utils:protocol_type(), net_utils:string_host_name(), tcp_port()}, shotgun:connection())
tcp_port() = net_utils:tcp_port()
thumbprint() = json()
thumbprint_map() = table(token(), thumbprint())
tls_csr() = binary_b64()
tls_private_key() = #tls_private_key{raw = leec:rsa_private_key(), b64_pair = {leec:binary_b64(), leec:binary_b64()}, file_path = file_utils:bin_file_path()}
tls_public_key() = #tls_public_key{kty = 'RSA', n = text_utils:bin_string(), e = text_utils:bin_string()}
token() = ustring()
type_challenge_map() = table(challenge_type(), challenge())
uri_challenge_map() = table(bin_uri(), challenge())
ustring() = text_utils:ustring()
void() = basic_utils:void()
web_interfacing_mode() = webroot | slave | standalone
callback_mode() -> fsm_utils:callback_mode_ret()
caller_state_to_string(LEECCallerState::leec_caller_state()) -> ustring()
can_perform_dns_challenges() -> boolean()
code_change(X1, StateName, LHState, X4) -> any()
dns_provider_to_string(DNSProvider::dns_provider()) -> ustring()
finalize(EventType, PreviousState, Data) -> any()
get_agent_key_path(CallerState::leec_caller_state()) -> error | option(bin_file_path())
get_certificate_priv_key_filename(DomainName::domain_name()) -> file_name()
get_credentials_path_for(DNSProvider::dns_provider(), DomainName::domain_name(), AnyCredBasePath::any_directory_path()) -> credentials_path()
get_default_cert_request_options(ChallengeType::challenge_type()) -> cert_req_option_map()
get_default_cert_request_options(ChallengeType::challenge_type(), Async::boolean()) -> cert_req_option_map()
get_ongoing_challenges(FsmPid::fsm_pid()) -> error | no_challenge | thumbprint_map()
get_ordered_prerequisites() -> [application_name()]
idle(EventType::event_type(), PreviousState::event_content(), Data::leec_http_state()) -> state_callback_result()
init(X1::{challenge_type(), [start_option()], json_utils:parser_state(), option(bridge_spec())}) -> {ok, InitialStateName::idle, InitialData::leec_http_state()}
invalid(EventType, PreviousState, Data) -> any()
is_known_challenge_type(ChalType::atom()) -> boolean()
is_supported_dns_provider(DNSProvider::atom()) -> boolean()
maybe_caller_state_to_string(MaybeLEECCallerState::option(leec_caller_state())) -> ustring()
obtain_cert_helper(Domain::domain_name(), ChallengeType::challenge_type(), FsmPid::fsm_pid(), CertReqOptionMap::cert_req_option_map(), MaybeBridgeInfo::option(trace_bridge:bridge_info())) -> obtained_outcome()
obtain_certificate_for(Domain::domain_name(), LeecCallerState::leec_caller_state()) -> obtain_outcome()
obtain_certificate_for(Domain::domain_name(), LeecCallerState::leec_caller_state(), CertReqOptionMap::cert_req_option_map()) -> obtain_outcome()
pending(EventType, PreviousState, Data) -> any()
reset_state(ChallengeType::challenge_type(), AnyCertDir::any_directory_path()) -> boolean()
send_ongoing_challenges(LCS::leec_caller_state(), TargetPid::pid()) -> void()
start(ChallengeType::challenge_type(), StartOptions::[start_option()]) -> start_outcome()
start(ChallengeType::challenge_type(), StartOptions::[start_option()], MaybeBridgeSpec::option(bridge_spec())) -> start_outcome()
state_to_string(LHS::leec_state()) -> ustring()
stop(LCS::leec_caller_state()) -> void()
terminate(LEECCallerState::leec_caller_state()) -> void()
terminate(Reason, State, Data) -> any()
valid(EventType, PreviousState, Data) -> any()
Generated by EDoc