Uploaded image for project: 'Maven Site Plugin'
  1. Maven Site Plugin
  2. MSITE-303

Discard invalid characters from directory name generated for staging site

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Trivial
    • Resolution: Fixed
    • 2.0-beta-6
    • 2.0-beta-7
    • None
    • None
    • Patch

    Description

      site-stage takes the distribution URL and builds a filesystem path from it. This can potentially lead to invalid paths since URLs may contain characters that are not valid for directory names.

      It's mostly a theoretical issue since good URLs don't include bad characters. The only exploit I can offer is to set the distribution URL to something like file://G:/Sites/ on a Windows box which then will cause an invalid file name like G:\Sites\stage\localhost\G:\Sites\multi-module-project\index.html. I experienced this during some local quick&dirty testing.

      Attachments

        1. filter-invalid-chars.patch
          1 kB
          Benjamin Bentmann

        Activity

          People

            bentmann Benjamin Bentmann
            bentmann Benjamin Bentmann
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: