Bug 470093 - getfattr -R seems broken
getfattr -R seems broken
Status: CLOSED NEXTRELEASE
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: attr (Show other bugs)
5.3
All Linux
medium Severity medium
: rc
: ---
Assigned To: Kamil Dudka
qe-baseos-daemons
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-11-05 13:16 EST by Eric Sandeen
Modified: 2013-03-05 08:22 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-03-05 08:22:18 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
backport from 2.4.40 (10.11 KB, patch)
2009-09-15 07:41 EDT, Kamil Dudka
no flags Details | Diff
backport from 2.4.41 (13.82 KB, patch)
2009-09-15 07:54 EDT, Kamil Dudka
no flags Details | Diff

  None (edit)
Description Eric Sandeen 2008-11-05 13:16:17 EST
Using the following test script:

#!/bin/bash
rm -f reg lnk
rmdir dir

touch reg
mkdir dir
ln -s dir lnk

setfattr -h -n trusted.name reg
setfattr -h -n trusted.name dir
setfattr -h -n trusted.name lnk
getfattr -h -L -R -m '.' -e hex .

I don't get any output for the symlink itself:

# ./testit.sh 
# file: .
security.selinux

# file: testit.sh
security.selinux

# file: reg
security.selinux
trusted.name

# file: dir
security.selinux
trusted.name

Although the attr *is* set on the link:

# getfattr -h -L -R -m '.' -e hex lnk
# file: lnk
security.selinux
trusted.name

However, with newer attr packages (2.4.41 or so) I do get it from -R:

# ./testit.sh 
# file: .
security.selinux

# file: testit.sh
security.selinux

# file: reg
security.selinux
trusted.name

# file: dir
security.selinux
trusted.name

# file: lnk
security.selinux
trusted.name
Comment 1 Zdenek Prikryl 2008-11-06 02:46:14 EST
Problem is in recursive listing of attributes (-R). In this case, symlinks handling doesn't work properly. This problem was fixed in version 2.4.40.
Comment 2 Kamil Dudka 2009-09-15 07:41:06 EDT
Created attachment 361067 [details]
backport from 2.4.40

The version 2.4.40 fixes the bug, however it doesn't work well with symlink loops. I'll try to take the walk_tree module from one of the later versions of attr.
Comment 3 Kamil Dudka 2009-09-15 07:54:01 EDT
Created attachment 361069 [details]
backport from 2.4.41
Comment 4 RHEL Product and Program Management 2009-11-06 13:51:45 EST
This request was evaluated by Red Hat Product Management for
inclusion, but this component is not scheduled to be updated in
the current Red Hat Enterprise Linux release. If you would like
this request to be reviewed for the next minor release, ask your
support representative to set the next rhel-x.y flag to "?".
Comment 6 RHEL Product and Program Management 2010-08-09 14:44:34 EDT
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
Comment 7 RHEL Product and Program Management 2011-01-11 17:16:22 EST
This request was erroneously denied for the current release of
Red Hat Enterprise Linux.  The error has been fixed and this
request has been re-proposed for the current release.
Comment 8 RHEL Product and Program Management 2011-05-31 09:50:32 EDT
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
Comment 9 RHEL Product and Program Management 2011-09-22 20:21:24 EDT
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
Comment 10 Kamil Dudka 2013-03-05 08:22:18 EST
I am sorry, but it is too late in the RHEL-5 release cycle.  At the moment we are addressing only critical and security related issues in RHEL-5.  This one is fixed in RHEL-6.  I am closing the bug as NEXTRELEASE.

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