Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8213616

URLPermission with query or fragment behaves incorrectly

XMLWordPrintable

    • b21

      It's possible to create a java.net.URLPermission (contrary to the spec) with a query and/or fragment after the path, and this affects the behavior of the implies() method such that it behaves incorrectly.

      URLPermission is specified that query and fragments are not part of the URL string passed to the constructor, but it is not specified to throw IAE.

      The simplest solution might be to strip these components when the object is constructed.

            michaelm Michael McMahon
            michaelm Michael McMahon
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: