mirror of
https://github.com/friendica/friendica
synced 2024-12-23 03:20:15 +00:00
Return 400 error code when webfinger request omits resource parameter. Fixes #14292
This commit is contained in:
parent
946337645d
commit
d4aa5d9aad
1 changed files with 2 additions and 2 deletions
|
@ -44,7 +44,7 @@ class Xrd extends BaseModule
|
||||||
// @TODO: Replace with parameter from router
|
// @TODO: Replace with parameter from router
|
||||||
if (DI::args()->getArgv()[0] == 'xrd') {
|
if (DI::args()->getArgv()[0] == 'xrd') {
|
||||||
if (empty($_GET['uri'])) {
|
if (empty($_GET['uri'])) {
|
||||||
return;
|
throw new BadRequestException();
|
||||||
}
|
}
|
||||||
|
|
||||||
$uri = urldecode(trim($_GET['uri']));
|
$uri = urldecode(trim($_GET['uri']));
|
||||||
|
@ -55,7 +55,7 @@ class Xrd extends BaseModule
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (empty($_GET['resource'])) {
|
if (empty($_GET['resource'])) {
|
||||||
return;
|
throw new BadRequestException();
|
||||||
}
|
}
|
||||||
|
|
||||||
$uri = urldecode(trim($_GET['resource']));
|
$uri = urldecode(trim($_GET['resource']));
|
||||||
|
|
Loading…
Reference in a new issue