{
  "id": "go/http-tls-certificate-unknown-authority",
  "signature": "Get \"https://internal.svc\": tls: failed to verify certificate: x509: certificate signed by unknown authority",
  "signature_zh": "Get \"https://internal.svc\"：tls：证书验证失败：x509：证书由未知机构签发",
  "regex": "Get\\ \"https://internal\\.svc\":\\ tls:\\ failed\\ to\\ verify\\ certificate:\\ x509:\\ certificate\\ signed\\ by\\ unknown\\ authority",
  "domain": "go",
  "category": "auth_error",
  "subcategory": null,
  "root_cause": "The server uses a private CA whose root is not in the system trust store, or the container lacks ca-certificates.",
  "root_cause_type": "generic",
  "root_cause_zh": "服务器使用私有 CA，其根证书不在系统信任库中，或容器缺少 ca-certificates。",
  "versions": [
    {
      "version": "1.18",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "1.21",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Disables verification entirely, defeating TLS security in production.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Does not address the unknown authority issue.",
      "fail_rate": 0.85,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "",
      "success_rate": 0.9,
      "how": "pool, _ := x509.SystemCertPool()\npem, _ := os.ReadFile(\"/etc/ssl/private-ca.pem\")\npool.AppendCertsFromPEM(pem)\ntr := &http.Transport{TLSClientConfig: &tls.Config{RootCAs: pool}}",
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "success_rate": 0.88,
      "how": "Install ca-certificates in the container image and mount the private CA into /usr/local/share/ca-certificates.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": null,
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.87,
  "fix_success_rate": 0.8,
  "resolvable": "true",
  "first_seen": "2024-03-30",
  "last_confirmed": "2025-01-01",
  "last_updated": "2025-01-01",
  "evidence_count": 0,
  "tags": [],
  "locale": "en",
  "aliases": []
}