Commit b53d0252 authored by Sebastian Kummer's avatar Sebastian Kummer

ZP-672 Also authenticate Option requests.

Released under the Affero GNU General Public License (AGPL) version 3.
parent 2a3babc3
...@@ -74,8 +74,10 @@ include_once(ZPUSH_CONFIG); ...@@ -74,8 +74,10 @@ include_once(ZPUSH_CONFIG);
throw new AuthenticationRequiredException("Access denied. Please send authorisation information"); throw new AuthenticationRequiredException("Access denied. Please send authorisation information");
// Stop here if this is an OPTIONS request // Stop here if this is an OPTIONS request
if (Request::IsMethodOPTIONS()) if (Request::IsMethodOPTIONS()) {
RequestProcessor::Authenticate();
throw new NoPostRequestException("Options request", NoPostRequestException::OPTIONS_REQUEST); throw new NoPostRequestException("Options request", NoPostRequestException::OPTIONS_REQUEST);
}
ZPush::CheckAdvancedConfig(); ZPush::CheckAdvancedConfig();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment