Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export named 'diffieHellman' not found in module 'crypto' when running in Nuxt server with bun --bun dev #9569

Open
ZTL-UwU opened this issue Mar 22, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@ZTL-UwU
Copy link
Contributor

ZTL-UwU commented Mar 22, 2024

What version of Bun is running?

1.0.35

What platform is your computer?

Linux 6.7.6-arch1-2 x86_64 unknown

What steps can reproduce the bug?

Minimal repro: https://github.com/ZTL-UwU/bun-diffieHellman

use jose in a nuxt server

run the app with bun --bun dev

What is the expected behavior?

{
  "payload": {
    "hello": "world",
    "exp": 1711128271
  },
  "protectedHeader": {
    "alg": "dir",
    "enc": "A128CBC-HS256"
  }
}

is shown on the index page.

What do you see instead?

image

Additional information

The same jose script works outside of nuxt even with bun --bun

@ZTL-UwU ZTL-UwU added the bug Something isn't working label Mar 22, 2024
@ssebastianoo
Copy link

ssebastianoo commented Jun 10, 2024

Same with SvelteKit

image

@JosephClay
Copy link

Same error encountered with vite macOS arm64 Bun v1.1.12

@corbinu
Copy link

corbinu commented Jun 12, 2024

Still happens with Nuxt in 1.1.13 tested on both macOS amr64 and Ubuntu 24.04 amd64

Screenshot 2024-06-12 at 7 35 15 AM

In my case seems to occur with @nuxtjs/hanko using jose

@gemue-parndt
Copy link

I still encounter the error in Bun v1.1.15 when using Auth.JS

@birkskyum
Copy link
Collaborator

Similar to:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants