-
Bug
-
Resolution: Fixed
-
Minor
-
4.1.3, 4.2
-
MOODLE_401_STABLE, MOODLE_402_STABLE
-
MOODLE_401_STABLE, MOODLE_402_STABLE
-
MDL-78533-401 -
We discovered that for select courses, the WS function gradereport_user_get_grade_items would return
{"exception":"invalid_response_exception","errorcode":"invalidresponse","message":"Invalid response value detected"}After some investigation, we tracked the issue down to some teachers using HTML tags in the name of their activities; specifically "<b></b>"
This seems to be failing validation in the structure defined in: /grade/report/user/classes/external/user.php line 511. itemname is set to be PARAM_TEXT which invalidated the web function results.
Two possible solutions we see are:
1) Change the structure definition to PARAM_RAW to allow the HTML tags,
2) Prevent users from saving an activity or grade item name with HTML tags.