Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-10407

Incorrect check for empty image file paths during conversion

    Details

    • Type: Bug
    • Status: Unverified Fix
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.9
    • Fix Version/s: 3.0.11-RC1
    • Component/s: phpBB 2.0 convertor
    • Labels:
      None

      Description

      Reported by nicon` in IRC
      This applies to avatar_path, avatar_gallery_path, smilies_path, and attachments upload_path.

      Using avatar_gallery_path as an example:
      In convert_phpbb20.php [309], 'avatar_gallery_path' => get_config_value('avatar_gallery_path') . '/',
      In functions_convert.php [427], if (empty($convert->convertor['avatar_gallery_path'])
      avatar_gallery_path will never be empty because of the added trailing slash. phpBB will then attempt to copy all the directories in the phpBB structure resulting in an error message similar to:

      Fatal installation error

      functions_convert.php [ 2429 ]

      Please make sure that these folders exist and are writable by the webserver then try again:
      »./../images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars
      [...]
      /phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/phpBB3/images/avatars/gallery/install/sf_tpl_files

      and the error messages continue on.

      Proposed fix concept:
      OPEN functions_convert.php
      FIND
      if (empty($convert->convertor['avatar_gallery_path'])
      REPLACE WITH
      $agp = get_config_value('avatar_gallery_path');
      if (empty($agp))

      I have a patch in the works.

        Activity

        Hide
        nickvergessen Joas Schilling added a comment -

        > I have a patch in the works.

        Status?

        Show
        nickvergessen Joas Schilling added a comment - > I have a patch in the works. Status?
        Hide
        imkingdavid David King added a comment - - edited

        The pull request was closed but not merged. Status?

        Show
        imkingdavid David King added a comment - - edited The pull request was closed but not merged. Status?
        Hide
        D¡cky Richard Foote [X] (Inactive) added a comment -

        A new commit is done and a pull request will be submitted soonn

        Show
        D¡cky Richard Foote [X] (Inactive) added a comment - A new commit is done and a pull request will be submitted soonn

          People

          • Assignee:
            bantu Andreas Fischer
            Reporter:
            D¡cky Richard Foote [X] (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development