diff options
Diffstat (limited to 'server/middlewares/activitypub.ts')
-rw-r--r-- | server/middlewares/activitypub.ts | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/server/middlewares/activitypub.ts b/server/middlewares/activitypub.ts index 5fa10cbfd..c528ee250 100644 --- a/server/middlewares/activitypub.ts +++ b/server/middlewares/activitypub.ts | |||
@@ -4,7 +4,6 @@ import { logger } from '../helpers/logger' | |||
4 | import { isHTTPSignatureVerified, isJsonLDSignatureVerified, parseHTTPSignature } from '../helpers/peertube-crypto' | 4 | import { isHTTPSignatureVerified, isJsonLDSignatureVerified, parseHTTPSignature } from '../helpers/peertube-crypto' |
5 | import { ACCEPT_HEADERS, ACTIVITY_PUB, HTTP_SIGNATURE } from '../initializers' | 5 | import { ACCEPT_HEADERS, ACTIVITY_PUB, HTTP_SIGNATURE } from '../initializers' |
6 | import { getOrCreateActorAndServerAndModel } from '../lib/activitypub' | 6 | import { getOrCreateActorAndServerAndModel } from '../lib/activitypub' |
7 | import { ActorModel } from '../models/activitypub/actor' | ||
8 | import { loadActorUrlOrGetFromWebfinger } from '../helpers/webfinger' | 7 | import { loadActorUrlOrGetFromWebfinger } from '../helpers/webfinger' |
9 | 8 | ||
10 | async function checkSignature (req: Request, res: Response, next: NextFunction) { | 9 | async function checkSignature (req: Request, res: Response, next: NextFunction) { |
@@ -12,7 +11,7 @@ async function checkSignature (req: Request, res: Response, next: NextFunction) | |||
12 | const httpSignatureChecked = await checkHttpSignature(req, res) | 11 | const httpSignatureChecked = await checkHttpSignature(req, res) |
13 | if (httpSignatureChecked !== true) return | 12 | if (httpSignatureChecked !== true) return |
14 | 13 | ||
15 | const actor: ActorModel = res.locals.signature.actor | 14 | const actor = res.locals.signature.actor |
16 | 15 | ||
17 | // Forwarded activity | 16 | // Forwarded activity |
18 | const bodyActor = req.body.actor | 17 | const bodyActor = req.body.actor |