Closed ikreb7 closed 9 months ago
@ikreb7 Looks like you are using @peculiar/webcrypto
in browser. You should use native crypto
in browser, because @peculiar/webcrypto
is WebCrypto API implementation that uses NodeJS Crypto API and it means it uses NodeJS objects like Buffer.
Try something like this
import * as x509 from "@peculiar/x509";
x509.cryptoProvider.set(self.crypto); // or crypto
Thank you! My fault.
Hello,
I get this error message
ReferenceError: Buffer is not <anonymous> webcrypto.es.js:244
. This is my example code.This are my package.json file
The error is already thrown with the line
const crypto = new Crypto();
.