Daniel Molina created OLINGO-250:
------------------------------------
Summary: 'jsonLightPayloadInfo' function does not unescape
entityset names extracted directly from a URL
Key: OLINGO-250
URL: https://issues.apache.org/jira/browse/OLINGO-250
Project: Olingo
Issue Type: Bug
Components: datajs
Affects Versions: V2 1.2.0, V2 1.1.0
Environment: All
Reporter: Daniel Molina
The 'jsonLightPayloadInfo' function (line 7083 in datajs-1.1.2.js) parses the
URI coming from the metadata (data[metadataAnnotation]) into a more meaningful
object (fragment). The problem is that it never calls
decodeURIComponent to ensure data is represented correctly. Thus the lookup
performed by 'lookupEntitySet' fails in scenarios where the URL data was
escaped as 'container.entitySet' uses non-escaped values. The fix should be
(line 7112):
var fragment = decodeURIComponent(metadataUri.substring(fragmentStart + 1,
fragmentEnd));
--
This message was sent by Atlassian JIRA
(v6.2#6252)