bazelbuild / bazelbuild/bazel

Bazel 8.4.0 RC1 still does not honor custom CA cert under /etc/pki

Open
#26,814 2 comments 0 reactions 0 assignees View on GitHub
awaiting-user-response P2 team-ExternalDeps type: bug
Dominant language
Java
Stars
25.8k
Forks
4.6k
Avg merge
2d 20h
Merged PRs (30d)
72

Description

> A fix for this issue has been included in [Bazel 8.4.0 RC1](https://github.com/bazelbuild/bazel/releases/tag/8.4.0rc1). Please test out the release candidate and report any issues as soon as possible.
> If you're using Bazelisk, you can point to the latest RC by setting USE_BAZEL_VERSION=8.4.0rc1. Thanks!

_Originally posted by @iancha1992 in [#10349](https://github.com/bazelbuild/bazel/issues/10349#issuecomment-3211833369)_

Hi bazel team,

I updated my bazel to Bazel 8.4.0 RC1 but still got cert issue when downloading an internal package. I verified that my wget works for this.

```
jobuser [ ~/linfer-kernels ]$ bazel build --nobuild --enable_workspace --noenable_bzlmod
WARNING: Download from https://artifactory.corp.linkedin.com:8083/artifactory/TOOLS/com/linkedin/rules_linkedin_packaging/rules_linkedin_packaging/0.1.47/rules_linkedin_packaging-0.1.47.tar.gz failed: class javax.net.ssl.SSLHandshakeException (certificate_unknown) PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
INFO: Repository rules_linkedin_packaging instantiated at:
/home/jobuser/linfer-kernels/WORKSPACE:9:13: in
Repository rule http_archive defined at:
/home/jobuser/.cache/bazel/_bazel_jobuser/dc3b9882d7bff530240445d76889e19d/external/bazel_tools/tools/build_defs/repo/http.bzl:431:31: in
ERROR: /home/jobuser/.cache/bazel/_bazel_jobuser/dc3b9882d7bff530240445d76889e19d/external/bazel_tools/tools/build_defs/repo/http.bzl:155:45: An error occurred during the fetch of repository 'rules_linkedin_packaging':
Traceback (most recent call last):
File "/home/jobuser/.cache/bazel/_bazel_jobuser/dc3b9882d7bff530240445d76889e19d/external/bazel_tools/tools/build_defs/repo/http.bzl", line 155, column 45, in _http_archive_impl
download_info = ctx.download_and_extract(
Error in download_and_extract: java.io.IOException: Error downloading [https://artifactory.corp.linkedin.com:8083/artifactory/TOOLS/com/linkedin/rules_linkedin_packaging/rules_linkedin_packaging/0.1.47/rules_linkedin_packaging-0.1.47.tar.gz] to /home/jobuser/.cache/bazel/_bazel_jobuser/dc3b9882d7bff530240445d76889e19d/external/rules_linkedin_packaging/temp6179888529839676607/rules_linkedin_packaging-0.1.47.tar.gz: (certificate_unknown) PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
ERROR: Error computing the main repository mapping: no such package '@@rules_linkedin_packaging//rules': java.io.IOException: Error downloading [https://artifactory.corp.linkedin.com:8083/artifactory/TOOLS/com/linkedin/rules_linkedin_packaging/rules_linkedin_packaging/0.1.47/rules_linkedin_packaging-0.1.47.tar.gz] to /home/jobuser/.cache/bazel/_bazel_jobuser/dc3b9882d7bff530240445d76889e19d/external/rules_linkedin_packaging/temp6179888529839676607/rules_linkedin_packaging-0.1.47.tar.gz: (certificate_unknown) PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
```

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the failure with the Bazel command and custom certificate described in the issue, then inspect the repository download path in tools/build_defs/repo/http.bzl. Verify whether Bazel 8.4.0 RC1 honors the certificate under /etc/pki and whether the failing http_archive fetch succeeds; the issue needs a current reproduction before implementation work can be scoped.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.