olingo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jon McEwen (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (OLINGO-1107) UriDecoder should use java.net.URLDecoder
Date Wed, 12 Apr 2017 13:11:41 GMT

     [ https://issues.apache.org/jira/browse/OLINGO-1107?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Jon McEwen updated OLINGO-1107:
-------------------------------
    Description: 
Query filters are incorrectly parsed, because the org.apache.olingo.commons.core.Decoder doesn't
convert '+' to space.

Simple fix is to use java.net.URLDecoder instead (line 85):

{{return URLDecoder.decode(encoded, "UTF-8");}}

Additional unit test:

{code:Java}
  @Test
  public void decodePlusAsSpace() throws Exception{
	  checkOption("%24filter=PaymentStatus+eq+%27Cleared%27", "$filter", "PaymentStatus eq 'Cleared'");
  }
{code}

  was:
Query filters are incorrectly parsed, because the org.apache.olingo.commons.core.Decoder doesn't
convert '+' to space.

Simple fix is to use java.net.URLDecoder instead (line 85):

{{return URLDecoder.decode(encoded, "UTF-8");}}

Additional unit test:

{{
  @Test
  public void decodePlusAsSpace() throws Exception{
	  checkOption("%24filter=PaymentStatus+eq+%27Cleared%27", "$filter", "PaymentStatus eq 'Cleared'");
  }
}}


> UriDecoder should use java.net.URLDecoder
> -----------------------------------------
>
>                 Key: OLINGO-1107
>                 URL: https://issues.apache.org/jira/browse/OLINGO-1107
>             Project: Olingo
>          Issue Type: Bug
>          Components: odata4-server
>    Affects Versions: (Java) V4 4.3.0
>            Reporter: Jon McEwen
>
> Query filters are incorrectly parsed, because the org.apache.olingo.commons.core.Decoder
doesn't convert '+' to space.
> Simple fix is to use java.net.URLDecoder instead (line 85):
> {{return URLDecoder.decode(encoded, "UTF-8");}}
> Additional unit test:
> {code:Java}
>   @Test
>   public void decodePlusAsSpace() throws Exception{
> 	  checkOption("%24filter=PaymentStatus+eq+%27Cleared%27", "$filter", "PaymentStatus
eq 'Cleared'");
>   }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message