Red Hat Bugzilla – Bug 158574
adduser rewrites existing dot-files with /etc/skel files
Last modified: 2007-11-30 17:11:06 EST
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):
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
*** This bug has been marked as a duplicate of 89591 ***