Fix bug in impersonation check

This commit is contained in:
Anthony Wang 2023-01-18 20:43:57 +00:00
parent f054570ee2
commit 4fbf68e700
No known key found for this signature in database
GPG key ID: 42A5B952E6DD8D38

View file

@ -88,7 +88,6 @@ class fuwuqi(SimpleHTTPRequestHandler):
actor = keyid.removesuffix('#main-key')
if ('actor' in activity and activity['actor'] != actor) or \
('attributedTo' in activity and activity['attributedTo'] != actor) or \
('actor' in activity['object'] and activity['object']['actor'] != actor) or \
('attributedTo' in activity['object'] and activity['object']['attributedTo'] != actor):
self.send_response(401)
return