From: Iker Pedrosa Date: Fri, 12 Nov 2021 14:23:30 +0000 (+0100) Subject: useradd: change SELinux labels for home files X-Git-Tag: 4.10~20^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06eb4e4d76ac7f1ac86e68a89b2dc9be7c7323a2;p=thirdparty%2Fshadow.git useradd: change SELinux labels for home files Change SELinux labels for files copied from the skeleton directory to the home directory. This could cause gnome's graphical user adding to fail without copying the full skeleton files. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=2022658 Signed-off-by: Iker Pedrosa --- diff --git a/src/useradd.c b/src/useradd.c index b463a1708..f7c979580 100644 --- a/src/useradd.c +++ b/src/useradd.c @@ -2704,7 +2704,7 @@ int main (int argc, char **argv) if (mflg) { create_home (); if (home_added) { - copy_tree (def_template, prefix_user_home, false, false, + copy_tree (def_template, prefix_user_home, false, true, (uid_t)-1, user_id, (gid_t)-1, user_gid); } else { fprintf (stderr,