Closed joetidee closed 5 years ago
This package does not process JWTs, so a message of "jwt malformed"
suggests that the error is occurring in application-level code, rather than this package. Could you provide any diagnostics that led you to pinpoint this package as the source of the issue?
This is the full code that I'm running, which is a function that is provided by your package:
const PassportLocalStrategy = require('passport-local').Strategy;
module.exports = new PassportLocalStrategy({
usernameField: 'email',
passwordField: 'password',
session: false,
passReqToCallback: true,
}, async (req, email, password, done) => {
try {
return done(null, false, { message : 'foobar' });
} catch (err) {
}
});
Ok, this error is thrown by jsonwebtoken
package
Expected behavior
I would expect the message in the http response to match that specified in the
done
function.Actual behavior
I receive the following http response:
Environment