feat(server): separate HTTPS from mTLS authentication#1351
Open
sjenning wants to merge 1 commit into
Open
Conversation
Make --tls-client-ca optional so the gateway can run with HTTPS encryption without requiring mTLS client certificates. This enables OIDC-only authentication over encrypted connections. Three TLS modes are now supported: - mTLS (--tls-client-ca provided): client certs required (default) - HTTPS-only (--tls-client-ca omitted): server TLS only, no client certs - Plaintext (--disable-tls): no TLS at all The Helm chart conditionally includes the client-ca volume and env var based on whether clientCaSecretName is configured. A startup warning is emitted when neither mTLS nor OIDC is configured.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
--tls-client-caoptional when TLS is enabled, decoupling HTTPS encryption from mTLS client certificate authenticationRelated Issue
N/A
Changes
openshell-core/config.rs: ChangeTlsConfig.client_ca_pathfromPathBuftoOption<PathBuf>openshell-server/tls.rs: BranchTlsAcceptor::from_files—Some(ca)builds mTLS verifier,Noneuseswith_no_client_auth()openshell-server/cli.rs: Remove runtime error requiring--tls-client-ca; add HTTPS-only log message and no-auth warningopenshell-server/lib.rs: Passclient_ca_path.as_deref()tofrom_filesopenshell-server/compute/vm.rs: Wrap testclient_ca_pathvalues inSome()statefulset.yaml: Conditionally include client-ca env var, volume mount, and volumevalues.yaml: Document thatclientCaSecretNameis optionalTesting
mise run pre-commitpassesedge_tunnel_authintegration tests pass (including newhttps_only_no_client_cert_required)multiplex_tls_integrationtests pass--tls-certand--tls-keyonly, verify HTTPS-only mode works with OIDCChecklist
--tls-client-cawork identically)