温馨提示:本站仅提供公开网络链接索引服务,不存储、不篡改任何第三方内容,所有内容版权归原作者所有
AI智能索引来源:http://www.bun.com/reference/node/crypto/Verify/verify
点击访问原文链接

Verify.verify method | Node.js crypto module | Bun

Verify.verify method | Node.js crypto module | BunBuildDocsReferenceGuidesBlogDiscord/node:crypto/Verify/verifyMverify

Search the reference...

/

BuildDocsReferenceGuidesBlogDiscord/node:crypto/Verify/verifyMverify

method

crypto.Verify.verifyverify(object: KeyLike | VerifyKeyObjectInput | VerifyPublicKeyInput | VerifyJsonWebKeyInput,signature: ArrayBufferView): boolean;

Verifies the provided data using the given object and signature.

If object is not a KeyObject, this function behaves as if object had been passed to createPublicKey. If it is an object, the following additional properties can be passed:

The signature argument is the previously calculated signature for the data, in the signatureEncoding. If a signatureEncoding is specified, the signature is expected to be a string; otherwise signature is expected to be a Buffer, TypedArray, or DataView.

The verify object can not be used again after verify.verify() has been called. Multiple calls to verify.verify() will result in an error being thrown.

Because public keys can be derived from private keys, a private key may be passed instead of a public key.

verify(object: KeyLike | VerifyKeyObjectInput | VerifyPublicKeyInput | VerifyJsonWebKeyInput,signature: string,signature_format?: BinaryToTextEncoding): boolean;

Verifies the provided data using the given object and signature.

If object is not a KeyObject, this function behaves as if object had been passed to createPublicKey. If it is an object, the following additional properties can be passed:

The signature argument is the previously calculated signature for the data, in the signatureEncoding. If a signatureEncoding is specified, the signature is expected to be a string; otherwise signature is expected to be a Buffer, TypedArray, or DataView.

The verify object can not be used again after verify.verify() has been called. Multiple calls to verify.verify() will result in an error being thrown.

Because public keys can be derived from private keys, a private key may be passed instead of a public key.

Referenced typestype KeyLike = string | Buffer | KeyObjectinterface VerifyKeyObjectInputcontext?: ArrayBuffer | ArrayBufferViewArrayBufferLike>dsaEncoding?: DSAEncodingkey: KeyObjectpadding?: number
saltLength?: numberinterface VerifyPublicKeyInputcontext?: ArrayBuffer | ArrayBufferViewArrayBufferLike>dsaEncoding?: DSAEncodingencoding?: stringformat?: KeyFormatkey: string | BufferArrayBufferLike>padding?: number
saltLength?: numbertype?: PublicKeyExportTypeinterface VerifyJsonWebKeyInputcontext?: ArrayBuffer | ArrayBufferViewArrayBufferLike>dsaEncoding?: DSAEncodingformat: 'jwk'key: JsonWebKeypadding?: number
saltLength?: numbertype BinaryToTextEncoding = 'base64' | 'base64url' | 'hex' | 'binary'

Resources

ReferenceDocsGuidesDiscordMerch StoreGitHubBlog 

Toolkit

RuntimePackage managerTest runnerBundlerPackage runner

Project

Bun 1.0Bun 1.1Bun 1.2Bun 1.3RoadmapContributingLicense

Baked with ❤️ in San Francisco

We're hiring →

Verify.verify method | Node.js crypto module | Bun,AI智能索引,全网链接索引,智能导航,网页索引

    API documentation for method node:crypto.Verify.verify | Bun