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

Essay question file type restriction doesn't validate extension

    XMLWordPrintable

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 3.8.6, 3.9.3, 3.10
    • None
    • Filepicker, Questions
    • 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

              Unassigned Unassigned
              emerrill Eric Merrill
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, Safat Shahin, Tim Hunt, Ilya Tregubov, Kevin Percy, Mathew May, Mihail Geshoski, Shamim Rezaie
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: