You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by bu...@apache.org on 2005/01/17 15:30:39 UTC
DO NOT REPLY [Bug 33136] New: -
WebDavResource.listWebDavResources() buggy when resource path contains escaped characters
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=33136>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=33136
Summary: WebDavResource.listWebDavResources() buggy when resource
path contains escaped characters
Product: Slide
Version: 2.0
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: WebDAV client
AssignedTo: slide-dev@jakarta.apache.org
ReportedBy: franco@redshift.ch
PROBLEM DESCRIPTION:
when accessing resources who's URI contains escaped characters,
WebDavResource.listWebDavResources() can return incorrect results.
more specifically, we made use of the slide client API (2.0) to access WebDAV
repositories managed by a SAP Netweaver. when attempting to access an empty
COLLECTION resource with a URI such as:
/foo/bar/gl�ck
WebDavResource.listWebDavResources() SHOULD have returned
/foo/bar/gl�ck with resourcetype = collection
in fact, the method returned:
/foo/bar/gl�ck/gl�ck with resourcetype = <empty>
ANALYSIS:
we traced the problem to a case difference between the slide client internal
representation of the resource URI as opposed to the representation of the
resource URI as returned by SAP Netweaver. subsequent path matching in
WebDavResource.setWebDavProperties() fails due to this differene in
representation.
SOLUTION:
we propose the following patch to WebDavResource.setWebDavProperties():
replace the code segment:
*******************************************
if (!href.startsWith("/"))
href = URIUtil.getPath(href);
String httpURLPath = httpURL.getEscapedPath();
*******************************************
with code segment:
*******************************************
if (!href.startsWith("/"))
href = URIUtil.getPath(href);
//this patch fixes problems with case-differences in escape codes
href = URIUtil.encodePath(URIUtil.decode(href));
String httpURLPath = httpURL.getEscapedPath();
*******************************************
proposed solution ensures that response paths will contain upper-case
escape codes, therefore matching internal slide client representation
of resource paths.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org