Bug 1465011 - glusterfind: DELETE path needs to be unquoted before further processing
Summary: glusterfind: DELETE path needs to be unquoted before further processing
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: glusterfind
Version: rhgs-3.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: RHGS 3.3.0
Assignee: Milind Changire
QA Contact: Anil Shah
URL:
Whiteboard: 3.3.0-devel-freeze-exception
Depends On: 1465024
Blocks: 1417151
TreeView+ depends on / blocked
 
Reported: 2017-06-26 12:27 UTC by Milind Changire
Modified: 2017-09-21 05:02 UTC (History)
4 users (show)

Fixed In Version: glusterfs-3.8.4-32
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1465024 (view as bug list)
Environment:
Last Closed: 2017-09-21 05:02:13 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2774 0 normal SHIPPED_LIVE glusterfs bug fix and enhancement update 2017-09-21 08:16:29 UTC

Description Milind Changire 2017-06-26 12:27:48 UTC
Description of problem:
path collected for UNLINK/RMDIR operations is not correctly unquoted, this causes the '%2F' character sequence quoted as '%252F'

Version-Release number of selected component (if applicable):
glusterfs-3.8.4-28
(probably earlier versions as well)

How reproducible:
100%


Steps to Reproduce:
1. create glusterfind session on any volume type
2. create file dir1/dir2/dir3/file1.txt at mount point
3. wait for changelog to roll-over
4. run glusterfind pre without --no-encode to list the NEW entry
5. run glusterfind post
6. delete dir1/dir2/dir3/file1.txt
7. wait for changelog to roll-over
8. run glusterfind pre without --no-encode to list the DELETE entry

Actual results:
entry will be seen as
DELETE dir1%252Fdir2%252Fdir3%252Ffile1.txt


Expected results:
DELETE dir1%2Fdir2%2Fdir3%2Ffile1.txt

Additional info:

Comment 1 Atin Mukherjee 2017-06-27 06:59:08 UTC
upstream patch : https://review.gluster.org/17629

Comment 5 Atin Mukherjee 2017-06-30 08:24:07 UTC
downstream patch : https://code.engineering.redhat.com/gerrit/#/c/110578/

Comment 7 Anil Shah 2017-07-05 10:52:01 UTC
[root@rhs-arch-srv1 changelogs]# glusterfind create s1 newvolume
Session s1 created with volume newvolume
[root@rhs-arch-srv1 changelogs]# glusterfind list
SESSION                   VOLUME                    SESSION TIME             
---------------------------------------------------------------------------
   s1                        newvolume                 2017-07-05 09:47:04   

[root@rhs-arch-srv1 changelogs]# glusterfind pre s1 newvolume /tmp/s1.log
Generated output file /tmp/s1.log

[root@rhs-arch-srv1 changelogs]# glusterfind post s1 newvolume 
Session s1 with volume newvolume updated

[root@rhs-arch-srv1 changelogs]# glusterfind pre s1 newvolume /tmp/s1.log
Generated output file /tmp/s1.log


[root@rhs-arch-srv1 changelogs]# cat /tmp/s1.log 
DELETE dir1%2Fdir2%2Fdir3%2Ffile

bug verified on build glusterfs-3.8.4-32.el7rhgs.x86_64

Comment 9 errata-xmlrpc 2017-09-21 05:02:13 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:2774


Note You need to log in before you can comment on or make changes to this bug.