Skip to content

Commit

Permalink
fix: AES Key Wrap input type check
Browse files Browse the repository at this point in the history
  • Loading branch information
panva committed Jul 1, 2021
1 parent 65fdec2 commit b83821b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/check_key_type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const checkKeyType = (alg: string, key: KeyLike): void => {
alg.startsWith('HS') ||
alg === 'dir' ||
alg.startsWith('PBES2') ||
alg.match(/^A\d{3}(?:GCM)KW$/)
alg.match(/^A\d{3}(?:GCM)?KW$/)
) {
if (key instanceof Uint8Array || key.type === 'secret') {
return
Expand Down

0 comments on commit b83821b

Please sign in to comment.