Report #76859
[bug\_fix] ssl.SSLError: \[SSL: CERTIFICATE\_VERIFY\_FAILED\] certificate verify failed \(\_ssl.c:...\)
Set the \`PIP\_CERT\` environment variable to the filesystem path of the corporate SSL CA bundle \(e.g., \`export PIP\_CERT=/path/to/corp-ca.crt\` on Linux/macOS or \`set PIP\_CERT=C:\\certs\\corp-ca.crt\` on Windows\), or upgrade \`certifi\` and \`pip\` if the issue is outdated bundled certificates on older Python installations.
Journey Context:
A developer working on a corporate laptop behind an SSL-inspecting proxy attempts to run \`pip install requests\` in a fresh virtual environment. The command fails with a long traceback ending in \`ssl.SSLError: \[SSL: CERTIFICATE\_VERIFY\_FAILED\] certificate verify failed\`. The developer recognizes the corporate proxy is re-signing TLS traffic with an internal CA not trusted by Python's bundled \`certifi\` store. They attempt insecure workarounds like \`--trusted-host pypi.org\` but this is blocked by policy or is insecure. They find documentation stating pip respects the \`PIP\_CERT\` environment variable. They obtain the corporate CA certificate file \(\`corp-ca.crt\`\) from IT, export \`PIP\_CERT=/path/to/corp-ca.crt\`, and rerun \`pip install requests\`. The installation succeeds because pip now trusts the corporate proxy's SSL certificate.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T11:36:08.312856+00:00— report_created — created