-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Description
Feature request description
Support securely serving the API socket over TCP with TLS and mTLS.
I would like to replace docker with podman in a case where mTLS is required across a network boundary where SSH connections are unacceptable.
While it is possible to proxy the podman socket using e.g. nginx to add TLS on the server side, the remote client has no such capability to consume it. Requiring my end-users to set up a TLS proxy on their local machines is completely out of the question.
Suggest potential solution
Add flags --tls-cert
, --tls-key
, and --tls-ca
to both podman system service
and podman system connection add
(the latter seems to require changes to https://github.com/containers/common/blob/main/pkg/config/config.go#L690).
Use the Go standard library to both serve and make requests using the provided certificates.
Have you considered any alternatives?
It could be possible to avoid adding new flags (and thus, changing common) by re-using the --identity
flag, and requiring the user to provide a single file containing the client certificate chain, client private key, and CA certificate chain, in that order, in a single PEM file. This should be possible using Go's encoding/pem
library by detecting when the Type
field changes. However, this feel brittle and inelegant, and doesn't provide any way of configuring the server.
Additional context
I am familiar with configuring TLS in Go, and I am happy to implement this change if either design is deemed acceptable.