---
title: "Fix kubectl, Helm & Minikube x509 Unknown Authority on Mac — SWG bar"
description: "Fix kubectl, Helm & Minikube x509: certificate signed by unknown authority errors behind Zscaler, Cloudflare WARP, or Netskope on macOS safely."
image: "https://swgbar.com/brand/swgbar-og-1200x630.png"
agent:
  instructions: "Use this search API to find relevant content across this site with keywords or natural-language queries, instead of crawling individual pages. Results are returned in Markdown."
  endpoint: "https://swgbar.com/.well-known/search?q={query}"
  method: "GET"
  documentation: "https://developers.cloudflare.com/ai-search/how-to/search-for-agents/"
---

Source: https://swgbar.com/en/guides/fix-kubernetes-kubectl-helm-minikube-x509-mac/
Language: en

# Fix kubectl, Helm & Minikube x509 Unknown Authority on Mac

Fix kubectl, Helm & Minikube x509: certificate signed by unknown authority errors behind Zscaler, Cloudflare WARP, or Netskope on macOS safely.

SWG bar · Updated December 3, 2026

When running `kubectl get pods`, `helm repo update`, `helm pull`, or `minikube start` on a corporate Mac behind Zscaler, Cloudflare WARP, Netskope, Cisco Umbrella, Palo Alto GlobalProtect, or Fortinet, Kubernetes CLI and container-runtime commands frequently abort during TLS verification with errors like:

```
# kubectl (remote API server or OIDC token exchange)
Unable to connect to the server: tls: failed to verify certificate:
  x509: certificate signed by unknown authority

# Helm (chart repository or OCI registry)
Error: looks like "https://charts.bitnami.com/bitnami" is not a valid chart repository or cannot be reached:
  Get "https://charts.bitnami.com/bitnami/index.yaml": tls: failed to verify certificate:
  x509: certificate signed by unknown authority

# Minikube (containerd pulling control-plane or workload images inside the node VM)
Exiting due to GUEST_IMAGE_PULL: Failed to pull image "registry.k8s.io/kube-apiserver:v1.31.0":
  tls: failed to verify certificate: x509: certificate signed by unknown authority
```

Paste your exact terminal log into the free [SWG & SSL Error Decoder](<https://swgbar.com/en/tools/tls-error-decoder/>) to pinpoint which layer rejected the chain, or follow the upgrade-safe macOS fix below.

## 1\. Why `kubectl`, Helm & Minikube reject corporate SWG certificates

Safari and Chrome validate TLS certificates through macOS System Keychain, where MDM installs your company’s SWG Root CA. Kubernetes tooling crosses **three separate trust boundaries** that browsers never hit:

*   **`kubectl` & `~/.kube/config` CA pinning**: When a cluster context specifies `certificate-authority-data` (or `certificate-authority`), `kubectl` validates the Kubernetes API server strictly against that cluster CA—not macOS Keychain. If an SWG breaks and re-signs HTTPS traffic to a remote API server (`*.eks.amazonaws.com`, `*.azmk8s.io`, GKE, or private clusters) or to your OIDC identity provider, `kubectl` immediately rejects the re-signed certificate. In addition, if `SSL_CERT_FILE` is already set in your shell to an incomplete PEM file, Go’s `crypto/x509` skips macOS Keychain for OIDC and cloud-auth exec plugins as well.
*   **Helm (`helm repo` & OCI registries)**: Helm is a Go CLI backed by `crypto/x509`. Setting `SSL_CERT_FILE` to a partial certificate bundle overrides macOS Keychain lookup and breaks chart repositories (`charts.bitnami.com`) and OCI registries (`ghcr.io`, `registry-1.docker.io`).
*   **Minikube (macOS host CLI + Linux VM/container runtime)**: Minikube runs `containerd` and `kubelet` _inside_ a Linux VM or Docker container whose trust store lives in Linux `/etc/ssl/certs`. That guest Linux environment cannot read macOS System Keychain, so `minikube start` and pod pulls fail with `GUEST_IMAGE_PULL` or `ImagePullBackOff` whenever an SWG intercepts `registry.k8s.io`, `gcr.io`, `ghcr.io`, or `docker.io`.

Inspect your current TLS environment and active context first:

```
env | grep -E 'SSL_CERT|CURL_CA|KUBECONFIG|HELM_|HTTPS_PROXY|NO_PROXY'
kubectl config view --minify -o jsonpath='{.clusters[0].cluster.server}' ; echo
helm version --short && minikube version --short
```

Never point `SSL_CERT_FILE` at _only_ your corporate SWG root CA—doing so breaks every non-inspected public endpoint for Go-based CLIs.

## 2\. Build an upgrade-safe combined macOS + corporate SWG CA bundle

Create a combined PEM bundle in `~/.certs/k8s-combined-ca.pem` containing **Apple’s built-in trusted public root CAs plus your corporate SWG Root CA**, and also export a standalone `.crt` file into `~/.minikube/certs/` for Minikube’s guest node:

```
mkdir -p "$HOME/.certs" "$HOME/.minikube/certs"

# 1. Export Apple's built-in trusted public root CAs
security find-certificate -a -p /System/Library/Keychains/SystemRootCertificates.keychain > "$HOME/.certs/k8s-combined-ca.pem"

# 2. Append your corporate SWG Root CA (replace "Zscaler" with Cloudflare, goskope, Cisco Umbrella, Fortinet, etc.)
security find-certificate -c "Zscaler" -p /Library/Keychains/System.keychain >> "$HOME/.certs/k8s-combined-ca.pem"

# 3. Export the standalone corporate SWG Root CA as .crt for Minikube's Linux node
security find-certificate -c "Zscaler" -p /Library/Keychains/System.keychain > "$HOME/.minikube/certs/corporate-swg-ca.crt"
```

Because `~/.certs/k8s-combined-ca.pem` includes both standard public roots and your corporate SWG root, inspected registries and direct endpoints both validate cleanly across Homebrew and CLI upgrades.

## 3\. Persist CA trust for `kubectl`, Helm & Minikube

Export `SSL_CERT_FILE` and `CURL_CA_BUNDLE` in `~/.zshrc` so `kubectl`, `helm`, `minikube`, and cloud auth helpers (`aws-iam-authenticator`, `gke-gcloud-auth-plugin`, `kubelogin`) all load the combined trust bundle:

```
cat <<'EOF' >> ~/.zshrc
export SSL_CERT_FILE="$HOME/.certs/k8s-combined-ca.pem"
export CURL_CA_BUNDLE="$HOME/.certs/k8s-combined-ca.pem"
EOF
source ~/.zshrc
```

Next, apply tool-specific persistent settings:

*   **Helm**: Pass `--ca-file` when adding an inspected chart repository (Helm saves the CA reference in `repositories.yaml` for future `helm repo update` runs):
    
    ```
    helm repo add bitnami https://charts.bitnami.com/bitnami --ca-file "$HOME/.certs/k8s-combined-ca.pem"
    helm repo update
    ```
    
*   **Minikube**: Start (or recreate) your cluster with `--embed-certs` so Minikube installs every `.crt` file from `~/.minikube/certs/` into the guest Linux OS trust store and `containerd` / Docker runtime:
    
    ```
    minikube start --embed-certs
    ```
    
    If your Mac also sets `HTTP_PROXY` / `HTTPS_PROXY`, ensure local Minikube addresses stay excluded in `NO_PROXY` (for example `export NO_PROXY="127.0.0.1,localhost,192.168.49.0/24,10.96.0.0/12"`) so your corporate proxy does not intercept the local control plane.

Verify all three tools with full TLS verification enabled—**never** disable verification (`kubectl --insecure-skip-tls-verify`, `insecure-skip-tls-verify: true` in `~/.kube/config`, `helm --insecure-skip-tls-verify`, `curl -k`, or `NODE_TLS_REJECT_UNAUTHORIZED=0`):

```
kubectl cluster-info
helm search repo bitnami/nginx
minikube kubectl -- get nodes
```

## 4\. Handle kubeconfig mTLS, cluster CA pinning & GUI Kubernetes clients

Two common scenarios remain broken even after configuring `SSL_CERT_FILE`:

*   **Cluster CA pinning & client-certificate mTLS on remote API servers**: Many Kubernetes clusters authenticate `kubectl` with mutual TLS (`client-certificate-data` / `client-key-data`) and pin a cluster-specific CA in `certificate-authority-data`. An SWG performing HTTPS break-and-inspect cannot forge the cluster’s private CA or relay mTLS client certificates cleanly. Those API server hostnames must bypass SWG decryption rather than trusting an SWG root CA.
*   **GUI Kubernetes apps & IDE plugins**: If `kubectl` and `helm` succeed in Terminal but fail inside **Lens / OpenLens**, **VS Code Kubernetes**, or **IntelliJ**, GUI apps did not load `~/.zshrc`. Export the CA bundle for the current macOS login session and restart the app:
    
    ```
    launchctl setenv SSL_CERT_FILE "$HOME/.certs/k8s-combined-ca.pem"
    launchctl setenv CURL_CA_BUNDLE "$HOME/.certs/k8s-combined-ca.pem"
    ```
    

## 5\. Avoid kubeconfig CA conflicts & VM cert drift with per-domain SWG bypass

Rebuilding Minikube nodes whenever a corporate SWG rotates intermediate certificates—or working around mTLS and `certificate-authority-data` pinning on remote clusters—quickly turns into recurring maintenance. Where your company’s policy permits per-domain SWG bypass for container registries and cluster endpoints, [SWG bar](<https://swgbar.com/en/install/>) detects which hosts are intercepted and restores the authentic TLS certificate per domain without turning off your corporate VPN or SSO (includes a 14 actual-use-day free trial):

```
swgbar probe registry.k8s.io
swgbar bypass enable registry.k8s.io
swgbar bypass enable charts.bitnami.com
swgbar bypass enable ghcr.io
```

Troubleshooting Docker pulls or pinned TLS endpoints on the same corporate Mac? Continue with [Fix Python `CERTIFICATE_VERIFY_FAILED` & Docker `x509` errors on Mac](<https://swgbar.com/en/guides/fix-python-docker-certificate-verify-failed-x509-mac/>), [Why certificate pinning and mTLS fail under SWG break-and-inspect](<https://swgbar.com/en/guides/certificate-pinning-mtls-swg-inspection-macos/>), and [How to bypass SWG on a Mac](<https://swgbar.com/en/guides/how-to-bypass-swg/>).

macOS 14+ · Apple Silicon

## Stop guessing which domains your company SWG decrypts.

SWG bar checks HTTPS inspection right from your Mac’s menu bar and lets you bypass broken domains in one click—while keeping corporate VPN and SSO running.

[Start a 14-day trial for $0](<https://swgbar.com/releases/2.4.13/SWGBar-macOS-arm64.pkg>) [Decode a TLS error](<https://swgbar.com/en/tools/tls-error-decoder/>) [Free Chrome extension](<https://chromewebstore.google.com/detail/bidclnlfneemkkdeanlcbpjfdalelmbf>)

## Keep reading

*   [How to Bypass SWG on a Mac (1-Click & CLI Guide)](<https://swgbar.com/en/guides/how-to-bypass-swg/>)
*   [How to Bypass SSL Inspection on a Mac (Why Keychain & curl -k Fail)](<https://swgbar.com/en/guides/bypass-ssl-inspection-mac/>)
*   [HTTPS & TLS Break-and-Inspect on macOS: HTTP/2, QUIC & Per-Domain Bypass](<https://swgbar.com/en/guides/bypass-https-tls-inspection-mac/>)
*   [Why macOS Proxy Settings Fail Against Corporate Proxies (scutil & Per-Domain Fix)](<https://swgbar.com/en/guides/bypass-corporate-proxy-ssl-inspection-mac/>)
*   [How to Check if Your Mac Is Intercepted by an SWG (Zscaler, Netskope & SSL Inspection)](<https://swgbar.com/en/guides/detect-https-inspection/>)
*   [How to Check if Your Employer or Work Mac Is Intercepting HTTPS (SSL Inspection)](<https://swgbar.com/en/guides/check-if-work-mac-intercepting-https/>)
*   [Can My Employer See My Browsing History, Incognito & Personal Accounts on a Work Mac?](<https://swgbar.com/en/guides/can-employer-see-browsing-history-incognito-work-mac/>)
*   [SSL Inspection Checker for Mac: Menu Bar Tool to Detect HTTPS Interception](<https://swgbar.com/en/guides/ssl-inspection-checker-mac/>)
*   [Zscaler SSL Inspection on Mac: How to Check & Bypass per Domain](<https://swgbar.com/en/guides/zscaler-ssl-inspection-bypass-mac/>)
*   [How to Turn Off or Bypass Zscaler on a Mac (When Tamper Protection Locks It)](<https://swgbar.com/en/guides/disable-turn-off-zscaler-on-mac/>)
*   [Cloudflare WARP & Zero Trust TLS Inspection on Mac: Detect & Bypass](<https://swgbar.com/en/guides/cloudflare-warp-tls-inspection-mac/>)
*   [Netskope SSL Inspection on Mac: Check Decryption & Bypass per Domain](<https://swgbar.com/en/guides/netskope-ssl-inspection-bypass-mac/>)
*   [Cisco Umbrella SSL Inspection on Mac: Check Decryption & Bypass per Domain](<https://swgbar.com/en/guides/cisco-umbrella-ssl-inspection-bypass-mac/>)
*   [Palo Alto GlobalProtect & Prisma Access SSL Decryption on Mac: Check & Bypass](<https://swgbar.com/en/guides/palo-alto-globalprotect-prisma-ssl-decryption-mac/>)
*   [Fortinet FortiClient & FortiGate (Fortinet\_CA\_SSL) Inspection on Mac: Check & Bypass](<https://swgbar.com/en/guides/fortinet-forticlient-ssl-inspection-bypass-mac/>)
*   [Fix Git & npm 'unable to get local issuer certificate' / SELF\_SIGNED\_CERT\_IN\_CHAIN on Mac](<https://swgbar.com/en/guides/fix-git-npm-unable-to-get-local-issuer-certificate-mac/>)
*   [Fix Python 'CERTIFICATE\_VERIFY\_FAILED' & Docker 'x509: certificate signed by unknown authority' on Mac](<https://swgbar.com/en/guides/fix-python-docker-certificate-verify-failed-x509-mac/>)
*   [Fix GitHub Copilot, OpenAI Codex & Gemini CLI SSL Certificate Errors on Mac (Zscaler / SWG)](<https://swgbar.com/en/guides/fix-codex-copilot-gemini-cli-ssl-certificate-error-mac/>)
*   [Fix Java, Maven, Gradle, IntelliJ & Android Studio 'PKIX path building failed' on Mac](<https://swgbar.com/en/guides/fix-java-maven-gradle-intellij-android-studio-pkix-mac/>)
*   [Fix AWS CLI & Boto3 'SSL validation failed' Certificate Errors on Mac](<https://swgbar.com/en/guides/fix-aws-cli-boto3-ssl-validation-failed-mac/>)
*   [Fix Google Cloud (gcloud) & Azure CLI (az login) SSL Certificate Errors on Mac](<https://swgbar.com/en/guides/fix-gcloud-azure-cli-ssl-certificate-verify-failed-mac/>)
*   [Fix Firefox 'SEC\_ERROR\_UNKNOWN\_ISSUER' Behind Zscaler & Corporate SWGs on Mac](<https://swgbar.com/en/guides/fix-firefox-sec-error-unknown-issuer-mac/>)
*   [Fix Ruby, Bundler & CocoaPods OpenSSL::SSL::SSLError on Mac](<https://swgbar.com/en/guides/fix-ruby-bundler-cocoapods-fastlane-ssl-error-mac/>)
*   [Fix Rust (cargo/rustup) & Go x509 SSL Errors on Mac](<https://swgbar.com/en/guides/fix-rust-cargo-rustup-go-ssl-x509-error-mac/>)
*   [Fix curl (60), Wget & PHP Composer SSL Certificate Errors on Mac](<https://swgbar.com/en/guides/fix-curl-60-wget-php-composer-ssl-error-mac/>)
*   [Confirmed vs. Suspected HTTPS inspection in SWG bar](<https://swgbar.com/en/guides/confirmed-vs-suspected-https-inspection/>)
*   [Inspect MITM root certificates & issuers in SWG bar](<https://swgbar.com/en/guides/inspect-mitm-root-certificates-macos/>)
*   [Enterprise SWG & MDM HTTPS inspection on a Mac](<https://swgbar.com/en/guides/enterprise-swg-https-inspection-macos/>)
*   [SWG bypass vs. TLS inspection exception (break and inspect)](<https://swgbar.com/en/guides/swg-bypass-vs-tls-exception/>)
*   [Bypass SWG for multi-domain web apps, SSO, CDNs & APIs on Mac](<https://swgbar.com/en/guides/multi-domain-sso-api-cdn-swg-bypass/>)
*   [Fix SWG bypass Recovering, Paused & connection errors on Mac](<https://swgbar.com/en/guides/troubleshoot-swg-bypass-recovering-paused-macos/>)
*   [macOS VPN virtual interfaces vs. SWG HTTPS inspection](<https://swgbar.com/en/guides/macos-vpn-virtual-interface-vs-swg-inspection/>)
*   [Why certificate-pinned apps & mTLS break under SWG inspection](<https://swgbar.com/en/guides/certificate-pinning-mtls-swg-inspection-macos/>)
*   [Fix SWG TLS & SSL certificate errors in CLI and AI tools on a Mac](<https://swgbar.com/en/guides/swg-tls-certificate-errors-macos/>)
*   [Homebrew, Docker, Python & Node.js CA trust behind an SWG on Mac](<https://swgbar.com/en/guides/homebrew-docker-python-node-ca-trust-swg-macos/>)
*   [Fix Claude Code & Cursor 'unable to get local issuer certificate' on Mac (SWG & MCP)](<https://swgbar.com/en/guides/ai-coding-agents-claude-code-cursor-swg-macos/>)
*   [Verify TLS certificates with openssl & security verify-cert on Mac](<https://swgbar.com/en/guides/verify-tls-certificates-openssl-security-verify-cert-macos/>)
*   [SWG bar permissions, local privacy & TLS probe limits](<https://swgbar.com/en/guides/macos-network-extension-privacy-probe-limits/>)
*   [How SWG bar checks HTTPS inspection](<https://swgbar.com/en/how-it-works/>)
*   [SWG bar Pricing — One-Time License for macOS (Personal & Team)](<https://swgbar.com/en/pricing/>)
*   [Download & install SWG bar for Mac (macOS 14+)](<https://swgbar.com/en/install/>)
*   [Chrome Extension to Detect SSL & HTTPS Inspection (SWG Bar Companion)](<https://swgbar.com/en/chrome-extension/>)
*   [SWG bar CLI Guide](<https://swgbar.com/en/cli/>)
*   [SWG bar MCP Server — macOS TLS Certificate Monitoring & SWG Bypass for Claude Code and Cursor](<https://swgbar.com/en/mcp/>)
*   [SWG bar release information](<https://swgbar.com/en/releases/>)
*   [About SWG bar](<https://swgbar.com/en/about/>)
