Skip to content

[jsonwebtoken] cannot skip audience validation #866

@ayZagen

Description

@ayZagen

How to skip audience and issuer checks?

  const decoded = decodeHeader( jwtString);
  const res = await verify(
    jwtString,
    cert,
    { algorithms: [ decoded.algorithm ], aud: undefined, iss: undefined, sub: undefined }
  );
// Throws { "code": "GenericFailure", "stack": "InvalidAudience" }

not defining or giving an empty array is not working too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions