Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Docs: note that Bun resources don't trust the dev cert via NODE_EXTRA_CA_CERTS (upstream Bun bug)

Open Beginner friendly
#1,802 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
88/100
Issue type
Documentation
Clarity
Clearly specified
Activity status
Active
Tech stack
bun
Domain
documentation

Research direction

Start with the Certificate configuration and JavaScript apps in the AppHost documentation pages named in the issue, especially the Bun/AddBunApp sections. Add a caution linking to oven-sh/bun#44365, explain that NODE_EXTRA_CA_CERTS does not reliably establish trust for the dev certificate, and document the plain-HTTP endpoint workaround; done when both pages contain the relevant guidance.

Written by the indexing model from the issue text.

Description

Problem

Aspire sets up development certificate trust for the various resource types, but for Bun resources (AddBunApp/addBunApp), that doesn't actually work today. Aspire configures NODE_EXTRA_CA_CERTS (and SSL_CERT_DIR) on Bun resources automatically, pointing at the generated dev cert. Confirmed by inspecting the actual running process's environment. But Bun's fetch() still rejects the certificate with:

TypeError: unable to verify the first certificate
  code: "UNABLE_TO_VERIFY_LEAF_SIGNATURE"

This is a genuine Bun bug, not an Aspire misconfiguration: Bun doesn't trust a pinned self-signed leaf certificate with basicConstraints: CA:FALSE via NODE_EXTRA_CA_CERTS, even though Node.js does for the exact same certificate and env var. I filed and reproduced this upstream with a minimal, Aspire-independent repro: oven-sh/bun#44365.

Net effect: any Bun-hosted resource (e.g. a CopilotKit/AG-UI runtime bridge, or any custom Bun service) that calls another Aspire project resource over HTTPS in local development will fail with UNABLE_TO_VERIFY_LEAF_SIGNATURE out of the box, with no Aspire-side configuration able to fix it. The only current workaround is to call the target resource's plain-HTTP endpoint instead of HTTPS for that specific call.

Request

Please add a note to the relevant docs pages so other users don't lose time rediscovering this:

Dominant language
MDX
Stars
195
Forks
91
Avg merge
1d 19h
Merged PRs (30d)
111

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/aspire.dev

All issues in microsoft/aspire.dev

Similar issues

More Documentation issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.