And another one
This commit is contained in:
parent
b8346c7a19
commit
10a90ea48f
|
@ -25,6 +25,9 @@ export = async (req: Request, res: Response, next: NextFunction) => {
|
||||||
console.log(`Could not retrieve actor ${req.body.actor} to validate HTTP signature for`, req.body);
|
console.log(`Could not retrieve actor ${req.body.actor} to validate HTTP signature for`, req.body);
|
||||||
res.status(401).end("Could not retrieve actor to validate HTTP signature");
|
res.status(401).end("Could not retrieve actor to validate HTTP signature");
|
||||||
}
|
}
|
||||||
|
} else if (!actor.publicKey) {
|
||||||
|
console.log(`Could not validate HTTP signature, actor missing public key: ${actor}`);
|
||||||
|
res.status(401).end("Actor missing public key.")
|
||||||
} else if (!validate(req, actor.publicKey.publicKeyPem)) {
|
} else if (!validate(req, actor.publicKey.publicKeyPem)) {
|
||||||
console.log(`Could not validate HTTP signature for ${req.body.actor}`);
|
console.log(`Could not validate HTTP signature for ${req.body.actor}`);
|
||||||
res.status(401).end("Could not validate HTTP signature");
|
res.status(401).end("Could not validate HTTP signature");
|
||||||
|
|
Loading…
Reference in New Issue