OFBiz
  1. OFBiz
  2. OFBIZ-2628

No Url encoding for get parameters

    Details

      Description

      Let's say I want to create a new category which ID is DVD+R
      Creation is ok through the admin interface, but whenever i want to access this category, the get parameter productCategoryId=.... of the url is wrong as it's not url encoded, so we have :
      https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD+R instead of
      https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD%2BR

      Both <@ofbizUrl> tag and menu widgets are not encoding get parameters.

      Way to correct :
      framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java modify the makeLink function
      framework/widget/src/org/ofbiz/widget/WidgetWorker.java : function buildhyperlinkUrl need to use defaultWebEncoder.encodeForURL instead of simpleEncoder

      Beofre i do the fix, can a core developper let me know about possible side effects

        Activity

        Sascha Rodekamp made changes -
        Status Reopened [ 4 ] Closed [ 6 ]
        Fix Version/s Release Branch 10.04 [ 12314832 ]
        Resolution Fixed [ 1 ]
        Sascha Rodekamp made changes -
        Wojciech Szymanowski made changes -
        Wojciech Szymanowski made changes -
        Jacques Le Roux made changes -
        Resolution Fixed [ 1 ]
        Status Closed [ 6 ] Reopened [ 4 ]
        Wojciech Szymanowski made changes -
        Sascha Rodekamp made changes -
        Fix Version/s Release Branch 10.04 [ 12314832 ]
        Resolution Fixed [ 1 ]
        Status Reopened [ 4 ] Closed [ 6 ]
        Fix Version/s Release Branch 12.04 [ 12321265 ]
        Sascha Rodekamp made changes -
        Resolution Fixed [ 1 ]
        Status Closed [ 6 ] Reopened [ 4 ]
        Sascha Rodekamp made changes -
        Status Reopened [ 4 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]
        Sascha Rodekamp made changes -
        Resolution Fixed [ 1 ]
        Status Closed [ 6 ] Reopened [ 4 ]
        Sascha Rodekamp made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Fix Version/s Release Branch 10.04 [ 12314832 ]
        Fix Version/s Release Branch 11.04 [ 12316420 ]
        Fix Version/s SVN trunk [ 12311928 ]
        Resolution Fixed [ 1 ]
        Sascha Rodekamp made changes -
        Sascha Rodekamp made changes -
        Assignee Sascha Rodekamp [ sascha ]
        Markus M. May made changes -
        Gavin made changes -
        Workflow jira [ 12466282 ] OFbiz Workflow [ 12505899 ]
        Patrick Antivackis made changes -
        Attachment Patch-OFBIZ-2628.txt [ 12423509 ]
        Patrick Antivackis made changes -
        Attachment Patch-OFBIZ-2628.txt [ 12423509 ]
        Patrick Antivackis made changes -
        Attachment OFBIZ-2628-widget.patch [ 12411571 ]
        Patrick Antivackis made changes -
        Attachment OFBIZ-2628-widget.patch [ 12411571 ]
        Patrick Antivackis made changes -
        Field Original Value New Value
        Description Let's say I want to create a new category which ID is DVD+R
        Creation is ok through the admin interface, but whenever i want to access this category, the get parameter productCategoryId=.... of the url is wrong as it's not url encoded, so we have :
        https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD&#43;R instead of
        https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD%2BR

        Both <@ofbizUrl> tag and menu widgets are not encoding get parameters.

        Way to correct :
        framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java modify the makeLink function
        framework/widget/src/org/ofbiz/widget/WidgetWorker.java : need to use defaultWebEncoder.encodeForURL instead of simpleEncoder

        Beofre i do the fix, can a core developper let me know about possible side effects
        Let's say I want to create a new category which ID is DVD+R
        Creation is ok through the admin interface, but whenever i want to access this category, the get parameter productCategoryId=.... of the url is wrong as it's not url encoded, so we have :
        https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD&#43;R instead of
        https://localhost:8443/catalog/control/EditCategory?productCategoryId=DVD%2BR

        Both <@ofbizUrl> tag and menu widgets are not encoding get parameters.

        Way to correct :
        framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java modify the makeLink function
        framework/widget/src/org/ofbiz/widget/WidgetWorker.java : function buildhyperlinkUrl need to use defaultWebEncoder.encodeForURL instead of simpleEncoder

        Beofre i do the fix, can a core developper let me know about possible side effects
        Patrick Antivackis created issue -

          People

          • Assignee:
            Sascha Rodekamp
            Reporter:
            Patrick Antivackis
          • Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 4h
              4h
              Remaining:
              Remaining Estimate - 4h
              4h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development