eyre: only allow authenticated GET scry requests

Lacking any other permissioning mechanism, we must simply reject
unauthenticated HTTP-scry requests for now.
This commit is contained in:
Fang 2020-06-12 00:57:25 +02:00
parent d20877e414
commit b870466977
No known key found for this signature in database
GPG Key ID: EB035760C1BBA972

View File

@ -870,6 +870,10 @@
++ handle-scry
|= [authenticated=? =address =request:http]
|^ ^- (quip move server-state)
?. authenticated
(error-response 403 ~)
?. =(%'GET' method.request)
(error-response 405 "may only GET scries")
:: make sure the path contains an app to scry into
::
=+ req=(parse-request-line url.request)