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

Essay question file type restriction doesn't validate extension

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.8.6, 3.9.3, 3.10
    • Fix Version/s: None
    • Component/s: Filepicker, Questions
    • Labels:
    • Affected Branches:
      MOODLE_310_STABLE, MOODLE_38_STABLE, MOODLE_39_STABLE

      Description

      The essay question's file type restriction only validates on mimetype, not actual extension, meaning that many files can be substituted for each other, like a .txt and a .java, both of which are text/plain.

      The assign tool, which has a similar restriction, uses the mimetype restriction at the upload step (since I think that is all the filepicker supports currently...) but does a validation when you try and save, and won't let you continue if there files with unallowed extensions.

      The question should follow the same scheme (or filepicker should be updated to allow direct limitation of file extension, not just mime).

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              emerrill Eric Merrill
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan, Tim Hunt, Andrew Lyons, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated: