Fix in case token comes through with HTTP instead of HTTPS
This commit is contained in:
parent
0c1eaf3a31
commit
5a388efa14
|
@ -8,5 +8,10 @@
|
|||
require_once __DIR__.'/server.php';
|
||||
|
||||
// Handle a request for an OAuth2.0 Access Token and send the response to the client
|
||||
error_log("token.php \$_POST = " . json_encode($_POST));
|
||||
if (substr($_POST["redirect_uri"],0,5) == "http:") {
|
||||
$_POST["redirect_uri"] = "https" . substr($_POST["redirect_uri"],4);
|
||||
}
|
||||
|
||||
$server->handleTokenRequest(OAuth2\Request::createFromGlobals())->send();
|
||||
?>
|
||||
?>
|
||||
|
|
Loading…
Reference in New Issue