Documentation
¶
Overview ¶
Package pemfile holds the checks shared by the inbound (internal/servertls) and outbound (internal/httpclient) TLS loaders for the PEM files named in configuration.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendCertificates ¶
AppendCertificates adds every certificate in data to pool. Unlike AppendCertsFromPEM, it rejects a block that does not parse, so a bundle cannot silently drop one of its CAs. pem.Decode itself skips a block with bad framing or base64, so the decoded blocks are counted against the BEGIN markers. Like pem.Decode, only a marker that starts a line counts, so a comment that quotes one does not fail the bundle. Blocks of other types are skipped.
func CheckPath ¶
CheckPath rejects PEM contents given where a file path belongs, as with SERVER_TLS_KEY_FILE="$(cat tls.key)" or a ${file:...} reference, which resolves to the file's contents. The error names only the field: an *fs.PathError would echo the whole value, writing a private key to the logs.
Types ¶
This section is empty.