Discourse LTI allows Discourse to integrate with a number of learning management systems via the LTI 1.3 standard.
Install Guide
This plugin is bundled with Discourse core. There is no need to install the plugin separately.
This plugin implements the LTI 1.3 standard for authentication, which is supported by a number of learning management systems. Discourse acts as a “Tool” within the LTI standard. Once configured, users will be able to click a button/link on the learning management system, and instantly be logged into Discourse.
Precise setup instructions will vary based on your Learning Management System. But in general:
Create a new “Tool” entry in your learning management system
LTI Version: 1.3
Launch URL: any URL on your site. Users will be directed here after login
Tool Public Key - leave blank. Discourse never sends data to the LMS
In your LMS, find the 'Authorization endpoint", “Tool Client ID”, “Platform Issuer ID”, and the “Platform Public Key”, and add them to the relevant site settings in Discourse. In Discourse, the settings can be found by searching for lti in the Discourse site settings UI.
If your learning management system guarantees User emails have been validated, enable the lti email verified site setting. Warning: If your LMS does not verify emails, enabling lti email verified is a security risk.
Turn on the lti enabled site setting
If these instructions don’t make sense for your LMS, please post in the topic below and we’ll do our best to update the instructions accordingly.
What if my site is invite_required?
If you want your users to go through the Discourse invite redemption flow when they first log in, you can use LTI “Custom Properties” to specify a Discourse invite link. New users will be directed to the invite, while existing users will be sent to the regular launch URL. For example:
Ich bin einer unserer Administratoren und auch ein Softwareentwickler. Ich glaube, das Problem, das ich habe, hat mit Cookies und dem „State“ zwischen Discourse und Canvas zu tun, die nicht übereinstimmen.
Dies ist der Fehler, den ich in den Discourse-Protokollen erhalte:
(lti) Authentifizierungsfehler! state_mismatch: StandardError, State-Parameter stimmte nicht mit der Sitzung überein
Gibt es einen Abschnitt „Launching without Cookies“, der hier relevant ist. Aber ich bin mir nicht zu 100 % sicher. Jede Hilfe oder Einblicke wäre sehr willkommen.
Für den öffentlichen Schlüssel können Sie zu https://\u003cyour_canvas_url\u003e/api/lti/security/jwks navigieren und den zweiten Schlüssel kopieren. Dann können Sie zu https://8gwifi.org/jwkconvertfunctions.jsp gehen, ihn dort einfügen und konvertieren. Kopieren Sie dann den Text zwischen-----BEGIN/END PUBLIC KEY----- und fügen Sie ihn in den Lti platform public key in den Discourse LTI-Einstellungen ein. Speichern Sie dann.
Hier ist die Einschränkung. Diese JWKs, die Canvas generiert, werden anscheinend monatlich rotiert. Sobald sich dieser zweite Schlüssel ändert, funktioniert das LTI nicht mehr und Sie müssen ihn durch den neuen ersetzen, indem Sie Schritt 3 befolgen.
Das Discourse LTI-Plugin muss eine Public JWK URL unterstützen, um aktuell zu bleiben.
Dieses Plugin ist jetzt Teil des Discourse-Kerns im Rahmen von Bundling more popular plugins with Discourse core. Wenn Sie selbst hosten und das Plugin verwenden, müssen Sie es vor dem nächsten Upgrade aus Ihrer app.yml entfernen.