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

No checking for valid context in /rss/file.php

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.2.1
    • Fix Version/s: 3.1.5, 3.2.2
    • Component/s: RSS
    • Labels:

      Description

      As pointed out in MDLSITE-3067, exceptions are raised if a client attempts to access an RSS feed for a context that no longer exists.

      The root cause of this is that /rss/file.php is calling get_context_info_array() which uses MUST_EXIST so throws an exception.

      It would be good if this was caught and a 404 response returned.

      To replicate:

      1. Switch RSS on at server level for forums
      2. Create a forum with RSS switched on and follow the RSS link
      3. Delete the forum
      4. Refresh the RSS link
      5. You should see an error

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              maherne Michael Aherne
              Reporter:
              maherne Michael Aherne
              Peer reviewer:
              Dan Poltawski
              Integrator:
              David Monllaó
              Tester:
              Andrew Nicols
              Participants:
              Component watchers:
              Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                13/Mar/17