mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-04 20:24:59 -04:00
Verify third party ID server certificates
This commit is contained in:
parent
6ffbcf45c6
commit
b8dd5b1a2d
4 changed files with 43 additions and 9 deletions
|
@ -63,7 +63,7 @@ def check_key_valid(http_client, event):
|
|||
event.content["third_party_invite"]["key_validity_url"],
|
||||
{"public_key": event.content["third_party_invite"]["public_key"]}
|
||||
)
|
||||
if not response["valid"]:
|
||||
raise AuthError(403, "Third party certificate was invalid")
|
||||
except IOError:
|
||||
except Exception:
|
||||
raise AuthError(502, "Third party certificate could not be checked")
|
||||
if "valid" not in response or not response["valid"]:
|
||||
raise AuthError(403, "Third party certificate was invalid")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue