Bug 158574

Summary: adduser rewrites existing dot-files with /etc/skel files
Product: [Fedora] Fedora Reporter: Aldy Hernandez <aldyh>
Component: shadow-utilsAssignee: Peter Vrabec <pvrabec>
Status: CLOSED DUPLICATE QA Contact: David Lawrence <dkl>
Severity: high Docs Contact:
Priority: medium    
Version: 3   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-08-01 12:54:33 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Aldy Hernandez 2005-05-23 18:13:29 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0

Description of problem:
Adduser will rewrite *existing* files in /home/USER from the skeletons in /etc/skel.  This is especially dangerous if /home directories are NFS mounted (home is already populated).

For example, imagine I am adding user "foo" on a new machine that needs /etc/passwd populated.  If this machine has foo's home directory NFS mounted (or already present), it will overwrite any files there with the versions in /etc/skel.

Version-Release number of selected component (if applicable):
shadow-utils-4.0.3-57

How reproducible:
Always

Steps to Reproduce:
1. Create /home/foo with .bashrc.
2. adduser foo ...
3. See how /home/foo/.bashrc was rewritten.
  

Expected Results:  adduser should not overwrite existing files

Additional info:

Comment 1 Peter Vrabec 2005-08-01 12:54:33 UTC

*** This bug has been marked as a duplicate of 89591 ***