Writes server.pem and private_key.pem for quack_serve() to serve
HTTPS with, and returns their paths with the certificate's SHA-256
fingerprint, which clients pass as ssl_fingerprint to attach_quack()
or quack_query() so they can trust the self-signed certificate.
Existing key files are not overwritten.
See also
Other quack:
attach_quack(),
detach_quack(),
install_quack(),
quack_query(),
quack_serve(),
quack_stop()
Examples
if (FALSE) { # \dontrun{
keys <- quack_generate_keys(directory = "~/quack-keys")
quack_serve(
"quack:0.0.0.0:9494", token = "super_secret",
allow_other_hostname = TRUE,
ssl_cert_file = keys$cert_file, ssl_key_file = keys$key_file
)
# Clients pin the certificate:
# attach_quack("team", "quack:host:9494", token = "super_secret",
# ssl_fingerprint = keys$fingerprint)
} # }
