Browse Source

Daemon: Fix preflight CORS request handling

master
Mathias Aschwanden 8 years ago
parent
commit
f6a17b2f5e
  1. 3
      lib/jsonrpc.py

3
lib/jsonrpc.py

@ -58,6 +58,9 @@ class VerifyingJSONRPCServer(SimpleJSONRPCServer):
# first, call the original implementation which returns
# True if all OK so far
if SimpleJSONRPCRequestHandler.parse_request(myself):
# Do not authenticate OPTIONS-requests
if myself.command.strip() == 'OPTIONS':
return True
try:
self.authenticate(myself.headers)
return True

Loading…
Cancel
Save