Hello, 

here is a patch to solve this issue. Its documentation is included in the
header. Alex, this bug is "yours". I leave to you the decision about it
actual inclusion or rework.

Bye, Mt.
Goal: make sure that we have a decent default SHELL setting in adduser
Fixes: #48304, which reincarned into #293492

Status wrt upstream:
Tomasz would prefer to have a decent fall back rather than default setting
(thinking about wrongly typed shell for root). This is how it works under
solaris. But he's ok with this patch, as temporary fix.

Index: shadow-4.0.3/src/useradd.c
===================================================================
--- shadow-4.0.3.orig/src/useradd.c     2005-05-12 11:05:27.577364326 +0200
+++ shadow-4.0.3/src/useradd.c  2005-05-12 11:07:39.748616230 +0200
@@ -76,7 +76,7 @@ RCSID (PKG_VER "$Id: useradd.c,v 1.32 20
 static gid_t def_group = 100;
 static const char *def_gname = "other";
 static const char *def_home = "/home";
-static const char *def_shell = "";
+static const char *def_shell = "/bin/sh";
 static const char *def_template = SKEL_DIR;
 
 #ifdef SHADOWPWD

Attachment: signature.asc
Description: Digital signature

Reply via email to