Skip to content

Should jwsDecode return null if payload is not valid JSON? #23

@dschenkelman

Description

@dschenkelman

First of all: awesome library, we use it a lot at Auth0!

Does the issue question make sense? It would require a try/catch around this line:
https://github.com/brianloveswords/node-jws/blob/master/lib/verify-stream.js#L71

I think it should as that is how other invalid cases are dealt with. I'm will send the PR if you tell me that is OK.

Thanks!

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