Merge pull request #14499 from annando/issue-14478-2
Issue 14478: Fix OAuth registration with Bufferpull/14509/head
commit
4c3c4bd58d
|
@ -129,8 +129,9 @@ class OAuth
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
||||||
// The redirect_uri could contain several URI that are separated by spaces.
|
// The redirect_uri could contain several URI that are separated by spaces or new lines.
|
||||||
if (($application['redirect_uri'] != $redirect_uri) && !in_array($redirect_uri, explode(' ', $application['redirect_uri']))) {
|
$uris = explode(' ', str_replace(["\n", "\r", "\t"], ' ', $application['redirect_uri']));
|
||||||
|
if (!in_array($redirect_uri, $uris)) {
|
||||||
Logger::warning('Redirection uri does not match', ['redirect_uri' => $redirect_uri, 'application-redirect_uri' => $application['redirect_uri']]);
|
Logger::warning('Redirection uri does not match', ['redirect_uri' => $redirect_uri, 'application-redirect_uri' => $application['redirect_uri']]);
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue