diff --git a/core/Controller/ClientFlowLoginV2Controller.php b/core/Controller/ClientFlowLoginV2Controller.php
index f5bd2d216dde3..915a130193a11 100644
--- a/core/Controller/ClientFlowLoginV2Controller.php
+++ b/core/Controller/ClientFlowLoginV2Controller.php
@@ -100,7 +100,7 @@ public function poll(string $token): JSONResponse {
*/
#[OpenAPI(scope: OpenAPI::SCOPE_IGNORE)]
#[UseSession]
- public function landing(string $token, $user = ''): Response {
+ public function landing(string $token, string $user = '', int $direct = 0): Response {
if (!$this->loginFlowV2Service->startLoginFlow($token)) {
return $this->loginTokenForbiddenResponse();
}
@@ -108,7 +108,7 @@ public function landing(string $token, $user = ''): Response {
$this->session->set(self::TOKEN_NAME, $token);
return new RedirectResponse(
- $this->urlGenerator->linkToRouteAbsolute('core.ClientFlowLoginV2.showAuthPickerPage', ['user' => $user])
+ $this->urlGenerator->linkToRouteAbsolute('core.ClientFlowLoginV2.showAuthPickerPage', ['user' => $user, 'direct' => $direct])
);
}
@@ -118,7 +118,7 @@ public function landing(string $token, $user = ''): Response {
*/
#[OpenAPI(scope: OpenAPI::SCOPE_IGNORE)]
#[UseSession]
- public function showAuthPickerPage($user = ''): StandaloneTemplateResponse {
+ public function showAuthPickerPage(string $user = '', int $direct = 0): StandaloneTemplateResponse {
try {
$flow = $this->getFlowByLoginToken();
} catch (LoginFlowV2NotFoundException $e) {
@@ -140,6 +140,7 @@ public function showAuthPickerPage($user = ''): StandaloneTemplateResponse {
'urlGenerator' => $this->urlGenerator,
'stateToken' => $stateToken,
'user' => $user,
+ 'direct' => $direct,
],
'guest'
);
@@ -152,7 +153,7 @@ public function showAuthPickerPage($user = ''): StandaloneTemplateResponse {
*/
#[OpenAPI(scope: OpenAPI::SCOPE_IGNORE)]
#[UseSession]
- public function grantPage(?string $stateToken): StandaloneTemplateResponse {
+ public function grantPage(?string $stateToken, int $direct = 0): StandaloneTemplateResponse {
if ($stateToken === null) {
return $this->stateTokenMissingResponse();
}
@@ -179,6 +180,7 @@ public function grantPage(?string $stateToken): StandaloneTemplateResponse {
'instanceName' => $this->defaults->getName(),
'urlGenerator' => $this->urlGenerator,
'stateToken' => $stateToken,
+ 'direct' => $direct,
],
'guest'
);
diff --git a/core/templates/loginflowv2/authpicker.php b/core/templates/loginflowv2/authpicker.php
index 0e18cc99ce15f..a3cb4be7db3a9 100644
--- a/core/templates/loginflowv2/authpicker.php
+++ b/core/templates/loginflowv2/authpicker.php
@@ -46,7 +46,7 @@
-
diff --git a/core/templates/loginflowv2/grant.php b/core/templates/loginflowv2/grant.php index 567c3b4e7760e..599e612010bf6 100644 --- a/core/templates/loginflowv2/grant.php +++ b/core/templates/loginflowv2/grant.php @@ -48,6 +48,9 @@