Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-67072

Include client_id and lti_deployment_id in OIDC Login Initiation request

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      This test will check data is passed to the tool, and thus will require to use the network developer tool in the browser.

      Pre-requisite: install an LTI 1.3 tool

      You need an LTI 1.3 tool installed on your site. Any would do. If you don't have one, you can install for example ZTest by following the steps:

      1. Log in as an administrator
      2. Navigate to Site Administration > Plugins > External tool > Manage tools
      3. Click on configure a tool manually
      4. Fill the form as follow:
        1. Tool name: ZTest 1.3
        2. Tool url: https://ztest.cengage.info/ztest/lti
      5. LTI Version: LTI 1.3
      6. Public key: copy the value from https://ztest.cengage.info/ztest/ LTI 1.3 Connect info tab
      7. Initiate Login URI: https://ztest.cengage.info/ztest/ws/lti/startlaunch?lti13=true&client_id=CLIENT_ID_HERE&platform=moodle
      8. Redirect URI: https://ztest.cengage.info/ztest/lti13
      9. Click on ‘Show more’
      10. Check Content-Item message
      11. Once the tool is created, press the "Tool configuration" icon.
      12. Take note of the following values:
        • Client ID
        • Deployment ID
      13. Close the modal and edit the tool.
      14. Update the initiate login URI and replace CLIENT_ID_HERE with the client id value for that tool
      15. Save the changes

      Verify client_id and deployment_id are passed on Deep Linking launch and Resource Link Launch

      1. As an instructor, log to a course
      2. Turn editing ON
      3. Click Add an activity or resource and select external tool
      4. On the Add external tool page, select ZTest 13 tool for the preconfigured tool
      5. Open your browser's developer tool and open the Network tab.
      6. Click on Select Content
      7. In the modal:
        1. Click content-item button
      8. Click on Select Content
      9. On the browser dev tool's network tab. Search for the entry for "startlaunch".
      10. Verify the following:
      11. In the modal:
        1. Click on menu icon on the top-right part and select "Content Item"
        2. Click Submit button
      12. Once back in the External Link Editor choose Save and Display
      13. Once ZTest is displayed, verify in the network tab:

       

      Show
      This test will check data is passed to the tool, and thus will require to use the network developer tool in the browser. Pre-requisite: install an LTI 1.3 tool You need an LTI 1.3 tool installed on your site. Any would do. If you don't have one, you can install for example ZTest by following the steps: Log in as an administrator Navigate to Site Administration > Plugins > External tool > Manage tools Click on configure a tool manually Fill the form as follow: Tool name: ZTest 1.3 Tool url: https://ztest.cengage.info/ztest/lti LTI Version: LTI 1.3 Public key: copy the value from https://ztest.cengage.info/ztest/ LTI 1.3 Connect info tab Initiate Login URI: https://ztest.cengage.info/ztest/ws/lti/startlaunch?lti13=true&client_id=CLIENT_ID_HERE&platform=moodle Redirect URI: https://ztest.cengage.info/ztest/lti13 Click on ‘Show more’ Check Content-Item message Once the tool is created, press the " Tool configuration " icon. Take note of the following values: Client ID Deployment ID Close the modal and edit the tool. Update the initiate login URI and replace CLIENT_ID_HERE with the client id value for that tool Save the changes Verify client_id and deployment_id are passed on Deep Linking launch and Resource Link Launch As an instructor, log to a course Turn editing ON Click Add an activity or resource and select external tool On the Add external tool page, select ZTest 13 tool for the preconfigured tool Open your browser's developer tool and open the Network tab. Click on Select Content In the modal: Click content-item button Click on Select Content On the browser dev tool's network tab. Search for the entry for " startlaunch ". Verify the following: The request URL: https://ztest.cengage.info/ztest/ws/lti/startlaunch?lti13=true&client_id=CLIENT_ID_HERE&platform=moodle " client_id parameter " equal to the tool's Client ID " lti_deployment_id " parameter equal to the tool's Deployment ID In the modal: Click on menu icon on the top-right part and select " Content Item " Click Submit button Once back in the External Link Editor choose Save and Display Once ZTest is displayed, verify in the network tab: https://ztest.cengage.info/ztest/ws/lti/startlaunch " client_id parameter " equal to the tool's Client ID " lti_deployment_id " parameter equal to the tool's Deployment ID  
    • Affected Branches:
      MOODLE_38_STABLE, MOODLE_39_STABLE
    • Fixed Branches:
      MOODLE_39_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-67072-oidc-additional-login-parameters

      Description

      LTI proposes the extend the initial OIDC initiation request payload with the OAuth client_id and the LTI Deployment id.

      This can dramatically simplify the tool implementation by not reverting to custom login URL per installation as a work around.

      AC:
      As per https://www.imsglobal.org/spec/lti/v1p3/#additional-login-parameters each initiation request contains:

      • client_id: client id of the tool
      • lti_deployment_id: LTI deployment id of the tool

        Attachments

          Activity

            People

            Assignee:
            claudevervoort Claude Vervoort
            Reporter:
            claudevervoort Claude Vervoort
            Peer reviewer:
            Mathew May
            Integrator:
            Jun Pataleta
            Tester:
            Janelle Barcega
            Participants:
            Component watchers:
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
            Votes:
            1 Vote for this issue
            Watchers:
            8 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              15/Jun/20

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 4 hours, 45 minutes
                4h 45m