Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion types/node/crypto.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -610,5 +610,5 @@ declare module "crypto" {
* If `key` is not a [`KeyObject`][], this function behaves as if `key` had been
* passed to [`crypto.createPublicKey()`][].
*/
function verify(algorithm: string | null | undefined, data: NodeJS.ArrayBufferView, key: KeyLike | VerifyKeyWithOptions, signature: NodeJS.ArrayBufferView): Buffer;
function verify(algorithm: string | null | undefined, data: NodeJS.ArrayBufferView, key: KeyLike | VerifyKeyWithOptions, signature: NodeJS.ArrayBufferView): boolean;
}
2 changes: 1 addition & 1 deletion types/node/test/crypto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,7 @@ import { promisify } from 'util';

{
const sig: Buffer = crypto.sign('md5', Buffer.from(''), 'mykey');
const correct: Buffer = crypto.verify('md5', sig, 'mykey', sig);
const correct: boolean = crypto.verify('md5', sig, 'mykey', sig);
}

{
Expand Down