phacility/phabricator · error · Exception
OAuth application redirect URIs must not contain URI fragmen
Error message
OAuth application redirect URIs must not contain URI fragments, but the URI "%s" has a fragment ("%s"). What it means
Error "OAuth application redirect URIs must not contain URI fragments, but the URI "%s" has a fragment ("%s")." thrown in phacility/phabricator.
Source
Thrown at src/applications/oauthserver/PhabricatorOAuthServer.php:205
} catch (Exception $ex) {
return false;
}
}
/**
* See http://tools.ietf.org/html/draft-ietf-oauth-v2-23#section-3.1.2
* for details on what makes a given redirect URI "valid".
*/
public function assertValidRedirectURI($raw_uri) {
// This covers basics like reasonable formatting and the existence of a
// protocol.
PhabricatorEnv::requireValidRemoteURIForLink($raw_uri);
$uri = new PhutilURI($raw_uri);
$fragment = $uri->getFragment();
if (strlen($fragment)) {
throw new Exception(
pht(
'OAuth application redirect URIs must not contain URI '.
'fragments, but the URI "%s" has a fragment ("%s").',
$raw_uri,
$fragment));
}
$protocol = $uri->getProtocol();
switch ($protocol) {
case 'http':
case 'https':
break;
default:
throw new Exception(
pht(
'OAuth application redirect URIs must only use the "http" or '.
'"https" protocols, but the URI "%s" uses the "%s" protocol.',
$raw_uri,View on GitHub (pinned to 5720a38cfe)
When it happens
Trigger: Thrown at src/applications/oauthserver/PhabricatorOAuthServer.php:205 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/eb4454824fad4e0d.
Report an issue: GitHub.