515 views

Description

New Call passes parameters via URL to create Service Requests. If the New Call has long description text that contains special characters and TinyURL is invoked, it fails to encode them. The Service Request is not created and a blank screen instead of the shopping cart is displayed on the first step of this process.

Steps to Reproduce

  1. Install the Service desk plugin.

  2. Create a new call (new_call) and populate the form fields with the following sample values (or use your own values):

    • Call Type: Request
    • Caller: Demo user Abel Tuter
    • Request Item: Access
    • Description: "Leading 2% cash" and additional text that is longer than 1024 character (the value on the property glide.tiny_url_min_length).
  3. Click Submit.

    Note that submission of the form redirects to a blank screen and the following error is logged in the localhost logs:

    Default-thread-3 3FC590E237CF6E0076C819A543990ED4 SEVERE *** ERROR *** URLDecoder: Illegal hex characters in escape (%) pattern - For input string: " c" java.lang.IllegalArgumentException: URLDecoder: Illegal hex characters in escape (%) pattern - For input string: " c" at java.net.URLDecoder.decode(URLDecoder.java:173) at com.glide.util.StringUtil.urlDecode(StringUtil.java:1132) at com.glide.tiny_url.TinyURL.setParameters(TinyURL.java:165) at com.glide.tiny_url.TinyURL.getByParams(TinyURL.java:80) at com.glide.ui.RedirectTransaction.redirectWithTinyURL(RedirectTransaction.java:790) at com.glide.ui.RedirectTransaction.doRedirect(RedirectTransaction.java:766) at com.glide.ui.RedirectTransaction.process(RedirectTransaction.java:100) at com.glide.ui.GlideServletUITransaction.process(GlideServletUITransaction.java:73) at com.glide.processors.AProcessor.runProcessor(AProcessor.java:409) at com.glide.processors.AProcessor.processTransaction(AProcessor.java:183) at com.glide.processors.ProcessorRegistry.process(ProcessorRegistry.java:165) at com.glide.ui.GlideServletTransaction.process(GlideServletTransaction.java:32) at com.glide.sys.ServletTransaction.run(ServletTransaction.java:34) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:682)

Workaround

Modify the following line in Business Rule: CallTypeChanged to Request 01175810eb100100fcfb858ad106fee3

From:

var url = 'com.glideapp.servicecatalog_cat_item_view.do?sysparm_id=' + reqItem + '&sysparm_requested_for=' + reqFor + '&sysparm_location=' + location + '&sysparm_special_instructions=' + comments;

To:

var url = "com.glideapp.servicecatalog_cat_item_view.do?sysparm_id=" + reqItem + "&sysparm_requested_for=" + GlideStringUtil.urlEncode(reqFor) + "&sysparm_location=" + GlideStringUtil.urlEncode(location) + "&sysparm_special_instructions=" + GlideStringUtil.urlEncode(comments);

 


Related Problem: PRB724388

Seen In

Fuji Patch 10
Geneva Patch 6 Hot Fix 2

Fixed In

Helsinki Patch 11
Istanbul Patch 6
Jakarta

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-07-30 16:05:12
Published:2016-11-16