Documentation
¶
Overview ¶
Package tlsutil generates and manages TLS certificates for Pando's HTTP server. It creates a self-signed certificate stored in the user's data directory so that the PWA installation prompt is available when accessing Pando remotely.
Index ¶
Constants ¶
const ( // LoopbackServerName is the DNS name the generated certificate always // carries, so callers can pin it while connecting to 127.0.0.1. LoopbackServerName = "localhost" )
Variables ¶
This section is empty.
Functions ¶
func LoadPinnedLoopbackTLSConfig ¶ added in v1.2.7
LoadPinnedLoopbackTLSConfig builds a TLS client config that trusts only the certificate stored at certPath and verifies it against localhost while allowing the caller to connect to 127.0.0.1.
Types ¶
type CertPaths ¶
CertPaths holds the file paths for the TLS certificate and private key.
func EnsureCert ¶
EnsureCert returns paths to a TLS cert/key pair inside dataDir. If the files already exist they are reused; otherwise a new self-signed ECDSA P-256 certificate is generated and persisted.