Bug 43076 - Copying files to nfs home directory copies files as root
Copying files to nfs home directory copies files as root
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: nfs-utils (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Pete Zaitcev
David Lawrence
: Security
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-05-31 11:52 EDT by Judd Tracy
Modified: 2007-04-18 12:33 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-03-31 15:46:25 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)

  None (edit)
Description Judd Tracy 2001-05-31 11:52:15 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.76 [en] (X11; U; Linux 2.4.2-2smp i686)

Description of problem:
When we login to X and start KDE and we don't have a $HOME/Desktop
directory the startkde script will perform cp -aR /etc/skel/Desktop $HOME
but the files are copied over and owned by root.  The script is being run
as the user, and the files in the /etc/skel/Desktop directory are owned by
root.  The NFS server is running on an IRIX box and has the option to
squash root turned on.  I know this sound like an IRIX problem, but the
problem does not happen on IRIX-IRIX, Mandrake7.1-IRIX, or
Redhat7.1-Redhat7.1 transfers.  In each of these cases the files were
copied over with the proper ownership, except mandrake still had the groups
of the files set to root. 

How reproducible:
Always

Steps to Reproduce:
1. Have IRIX nfs server with root_squash turned on.
2. Copy root owned files to IRIX nfs partition using cp -aR dir1 dir2
3.
	

Actual Results:  All of the files that were copied over are owned by root.

Expected Results:  The files should have been owned by the user who copied
them.

Additional info:

% cp -aR /etc/skel/Desktop/ .
cp: setting permissions for `./Desktop/kontrol-panel': Operation not
permitted
cp: setting permissions for `./Desktop/.directory': Operation not permitted
cp: setting permissions for `./Desktop/Linux Documentation': Operation not
permitted
cp: setting permissions for `./Desktop/www.redhat.com': Operation not
permitted
cp: setting permissions for `./Desktop/Printer': Operation not permitted
cp: setting permissions for `./Desktop': Operation not permitted

Even though there are error messages the files are still copied and owned
by root.

This is a possible security problem as setuid root programs could be copied
over and run on the server (atleast in theory)
Comment 1 Bob Matthews 2001-06-04 12:35:17 EDT
What happens if you export the systems from the IRIX box using NFS version 2?
Comment 2 Kjartan Maraas 2003-03-31 15:33:22 EST
Any new info on this?
Comment 3 Pete Zaitcev 2003-03-31 15:46:25 EST
Thanks for reminding me, Kjartan. The requestor obviously lost interest,
but I keep such bugs NEEDINFO-ed for a while to give him the last chance.
Closing now.

If you have a bug to report, even with similar symptoms, open a new one.

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