Copyright © 2012-2020 Marc Worrell, Maas-Maarten Zeeman
Authors: Marc Worrell (marc@worrell.nl), Maas-Maarten Zeeman (mmzeeman@xs4all.nl).
options() = #{hostname => string() | binary(), servername => string() | binary()}
check_keyfile/1 | Check if the file contains a valid private key. |
ciphers/0 | Return the list of ciphers for http connections. |
decode_cert/1 | Decode a certificate file, return map with 'common_name', 'subject_alt_names' and 'not_after'. |
ensure_self_signed/3 | Check if all certificates are available in the site's ssl directory. |
generate_self_signed/3 | Generate a self signed certificate with the hostname and servername in the options. |
normalize_hostname/1 | Normalize a hostname, filters invalid characters and lowercases the all alphabetic characters. |
check_keyfile(Filename::file:filename_all()) -> ok | {error, Reason}
Check if the file contains a valid private key.
ciphers() -> [string()]
Return the list of ciphers for http connections.
decode_cert(CertFile::file:filename_all()) -> {ok, map()} | {error, not_a_certificate}
Decode a certificate file, return map with 'common_name', 'subject_alt_names' and 'not_after'.
ensure_self_signed(CertFile::file:filename_all(), PemFile::file:filename_all(), Options::options()) -> ok | {error, term()}
Check if all certificates are available in the site's ssl directory
generate_self_signed(CertFile::file:filename_all(), PemFile::file:filename_all(), Options::options()) -> ok | {error, term()}
Generate a self signed certificate with the hostname and servername in the options. The hostname and servername both default to inet:gethostname/0. The key is generated in the PemFile and the certificate in the CertFile. If the directory of the PemFile does not exist then it is created.
normalize_hostname(Hostname::binary() | string()) -> string()
Normalize a hostname, filters invalid characters and lowercases the all alphabetic characters.
Generated by EDoc