1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-25 01:05:36 +00:00

Update inbox workers, fixes #3304

This commit is contained in:
Daniel Supernault 2022-03-16 21:02:23 -06:00
parent b464021058
commit cd4f73bed9
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
2 changed files with 8 additions and 2 deletions

View file

@ -59,7 +59,7 @@ class InboxValidator implements ShouldQueue
// Job processed already
return 1;
}
Cache::put($lockKey, 1, 300);
Cache::put($lockKey, 1, 3600);
}
if(!isset($headers['signature']) || !isset($headers['date'])) {
@ -155,6 +155,9 @@ class InboxValidator implements ShouldQueue
) {
return;
}
if(!isset($bodyDecoded['id'])) {
return;
}
$signatureData = HttpSignature::parseSignatureHeader($signature);
$keyId = Helpers::validateUrl($signatureData['keyId']);
$id = Helpers::validateUrl($bodyDecoded['id']);

View file

@ -55,7 +55,7 @@ class InboxWorker implements ShouldQueue
// Job processed already
return 1;
}
Cache::put($lockKey, 1, 300);
Cache::put($lockKey, 1, 3600);
}
if(!isset($headers['signature']) || !isset($headers['date'])) {
@ -145,6 +145,9 @@ class InboxWorker implements ShouldQueue
) {
return;
}
if(!isset($bodyDecoded['id'])) {
return;
}
$signatureData = HttpSignature::parseSignatureHeader($signature);
$keyId = Helpers::validateUrl($signatureData['keyId']);
$id = Helpers::validateUrl($bodyDecoded['id']);