diff options
| author | Moritz Strohm <strohm@data-quest.de> | 2025-04-10 12:46:32 +0200 |
|---|---|---|
| committer | Murtaza Sultani <sultani@data-quest.de> | 2025-09-11 16:20:06 +0200 |
| commit | 52b151dbe997c3d91c60473611c3a1cf442f9659 (patch) | |
| tree | 3c7f7ad923f639760e5a8fee32a07372c9b969e2 /lib/classes/LTI13a/Registration.php | |
| parent | a44d881b5fe972fdb570a856078629a4d717f927 (diff) | |
added methods for a virtual global LTI toolstep-05405
Diffstat (limited to 'lib/classes/LTI13a/Registration.php')
| -rw-r--r-- | lib/classes/LTI13a/Registration.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/lib/classes/LTI13a/Registration.php b/lib/classes/LTI13a/Registration.php index 096519e..2ce1e8d 100644 --- a/lib/classes/LTI13a/Registration.php +++ b/lib/classes/LTI13a/Registration.php @@ -110,7 +110,8 @@ class Registration implements RegistrationInterface if ($this->tool) { return $this->tool->getToolData(); } elseif ($this->platform) { - //TODO: Use the global tool configuration for Stud.IP as LTI tool. + //Return the global tool: + return \LtiTool::getGlobalTool(); } //If no tool or platform is present, the registration is not linked to a tool. throw new \Studip\LTIException( @@ -186,7 +187,11 @@ class Registration implements RegistrationInterface } return $keyring->toKeyChain(); } elseif ($this->platform) { - //TODO: return the global tool key chain. + //Return the global tool keychain. + $keyring = \LtiTool::getGlobalToolKeyring(true); + if ($keyring) { + return $keyring->toKeyChain(); + } } return null; @@ -208,8 +213,8 @@ class Registration implements RegistrationInterface if ($this->tool) { return $this->tool->jwks_url ?? null; } else { - //TODO: Return the global JWKS URL for Stud.IP as LTI tool. - return null; + //Return the global JWKS URL for Stud.IP as LTI tool. + return \LtiTool::getGlobalJwksUrl(); } } } |
