Uploaded image for project: 'phpBB'
  1. phpBB
  2. PHPBB-12082

phpbb filesystem removes slashes after scheme of URI if path is out of bounds

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: Minor Minor
    • 3.1.0-a3
    • 3.1.0-dev, 3.1.0-a2
    • Other
    • None

      If a URL like

      http://localhost/phpbb3/../../../index.php

      is supplied to clean_path(), the method removes more slashes than it obviously should. The above URL results in this cleaned path:

      http:/index.php

      That new, cleaned URL is obviously incorrect and does not follow the URI scheme anymore.
      I'm not sure if clean_path shouldn't be used for URLs or if we should just make sure that the slashes after the URI scheme are not removed.

            bantu Andreas Fischer [X] (Inactive)
            Marc Marc
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: