-
- Downloads
feat: enable sharing username, email in LTI 1.3 launches and support blocking PII transmission
This commit enables sharing username and email in LTI 1.3 basic launches. This commit adds preferred_username and email as attributes of the Lti1p3LaunchData. The application or context that instantiates Lti1p3LaunchData is responsible for ensuring that username and email can be sent via an LTI 1.3 launch and supplying these data, if appropriate. This commit sends username and email as part of an LTI 1.3 basic launch when the XBlock fields ask_to_send_username and ask_to_send_email are set to True, respectively. Code was also added to block the transmission of username and email in both LTI 1.1 and LTI 1.3 launches if the value of the lti_access_to_learners_editable method of the LTI configuration service (i.e. the value of the CourseAllowPIISharingInLTIFlag ConfigurationModel) returns False, as originally intended and documented in the "Unified Flag for Enabling Sharing of PII in LTI " decision record. However, the LTI configuration service is not currently available or defined in all runtime contexts, so this behavior only works when editing the XBlock in Studio (i.e. the studio_view). It does not work from the XBlock preview in Studio (i.e. the author_view) or from the LMS (i.e. the student_view). The impact of this is that the ask_to_send_username and ask_to_send_email fields will be hidden in LTI XBlocks in courses for which an instance of the CourseAllowPIISharingInLTIFlag ConfigurationModel does not exist or for which an existing instance of the CourseAllowPIISharingInLTIFlag ConfigurationModel is disabled. If there already exists an instance of the CourseAllowPIISharingInLTIFlag ConfigurationModel for a course, then disabling the flag will only hide the ask_to_send_username and ask_to_send_email in the LTI XBlock edit menu. It will not prevent the transmission of username or email via the launch in Studio preview or via the launch in the LMS. If a course has already set ask_to_send_username or ask_to_send_email to True in the XBlock edit menu, that information will continue to be sent via the LTI 1.1 or LTI 1.3 launch. We plan to fix this bug in the future.
Showing
- lti_consumer/data.py 4 additions, 0 deletionslti_consumer/data.py
- lti_consumer/lti_1p3/consumer.py 7 additions, 1 deletionlti_consumer/lti_1p3/consumer.py
- lti_consumer/lti_1p3/tests/test_consumer.py 10 additions, 2 deletionslti_consumer/lti_1p3/tests/test_consumer.py
- lti_consumer/lti_xblock.py 49 additions, 14 deletionslti_consumer/lti_xblock.py
- lti_consumer/plugin/views.py 2 additions, 0 deletionslti_consumer/plugin/views.py
- lti_consumer/tests/test_utils.py 16 additions, 0 deletionslti_consumer/tests/test_utils.py
- lti_consumer/tests/unit/test_lti_xblock.py 134 additions, 20 deletionslti_consumer/tests/unit/test_lti_xblock.py
Loading
Please register or sign in to comment