source: clfs-sysroot/patches/shadow-4.1.2.2-sysroot_hacks-2.patch@ fd3ab6f

Last change on this file since fd3ab6f was 63c1d49, checked in by Joe Ciccone <jciccone@…>, 16 years ago

Updated the shadow sysroot hacks patch so that shadows applications dont try to flush the nscd cache for their respective programs.

  • Property mode set to 100644
File size: 32.4 KB
RevLine 
[cd4af16]1Submitted By: Joe Ciccone <jciccone@gmail.com>
2Date: 2006-11-24
3Initial Package Version: 4.0.18.1
[63c1d49]4 Rediffed Against 4.1.2.2 by Joe Ciccone on 2009-01-03
[cd4af16]5Origin: Joe Ciccone
6Upstream Status: None
7Description: Changes the hardcoded /etc to the value of the --sysconfdir
8 parameter passed to configure. Allows the utilities to be run
9 as a user other then root and properly modify the passwd and group
[63c1d49]10 files for the target system. This patch also disables the
11 calls that flushes the nscd cache. There is no point in flushing
12 the hosts cache db when it wasn't modified.
[cd4af16]13
14diff -Naur shadow-4.1.2.2.orig/contrib/Makefile.in shadow-4.1.2.2/contrib/Makefile.in
15--- shadow-4.1.2.2.orig/contrib/Makefile.in 2008-11-22 19:10:51.000000000 -0500
[63c1d49]16+++ shadow-4.1.2.2/contrib/Makefile.in 2009-01-04 17:35:46.184121662 -0500
[cd4af16]17@@ -184,6 +184,7 @@
18 srcdir = @srcdir@
19 sysconfdir = @sysconfdir@
20 target_alias = @target_alias@
21+top_build_prefix = @top_build_prefix@
22 top_builddir = @top_builddir@
23 top_srcdir = @top_srcdir@
24 EXTRA_DIST = README adduser.c adduser-old.c adduser.sh adduser2.sh \
25diff -Naur shadow-4.1.2.2.orig/doc/Makefile.in shadow-4.1.2.2/doc/Makefile.in
26--- shadow-4.1.2.2.orig/doc/Makefile.in 2008-11-22 19:10:51.000000000 -0500
[63c1d49]27+++ shadow-4.1.2.2/doc/Makefile.in 2009-01-04 17:35:46.184121662 -0500
[cd4af16]28@@ -184,6 +184,7 @@
29 srcdir = @srcdir@
30 sysconfdir = @sysconfdir@
31 target_alias = @target_alias@
32+top_build_prefix = @top_build_prefix@
33 top_builddir = @top_builddir@
34 top_srcdir = @top_srcdir@
35 EXTRA_DIST = HOWTO README.limits \
36diff -Naur shadow-4.1.2.2.orig/etc/Makefile.in shadow-4.1.2.2/etc/Makefile.in
37--- shadow-4.1.2.2.orig/etc/Makefile.in 2008-11-22 19:10:51.000000000 -0500
[63c1d49]38+++ shadow-4.1.2.2/etc/Makefile.in 2009-01-04 17:35:46.187460880 -0500
[cd4af16]39@@ -209,6 +209,7 @@
40 srcdir = @srcdir@
41 sysconfdir = @sysconfdir@
42 target_alias = @target_alias@
43+top_build_prefix = @top_build_prefix@
44 top_builddir = @top_builddir@
45 top_srcdir = @top_srcdir@
46 sysconf_DATA = login.defs
47diff -Naur shadow-4.1.2.2.orig/etc/pam.d/Makefile.in shadow-4.1.2.2/etc/pam.d/Makefile.in
48--- shadow-4.1.2.2.orig/etc/pam.d/Makefile.in 2008-11-22 19:10:51.000000000 -0500
[63c1d49]49+++ shadow-4.1.2.2/etc/pam.d/Makefile.in 2009-01-04 17:35:46.187460880 -0500
[cd4af16]50@@ -194,6 +194,7 @@
51 srcdir = @srcdir@
52 sysconfdir = @sysconfdir@
53 target_alias = @target_alias@
54+top_build_prefix = @top_build_prefix@
55 top_builddir = @top_builddir@
56 top_srcdir = @top_srcdir@
57 pamd_files = \
58diff -Naur shadow-4.1.2.2.orig/lib/commonio.c shadow-4.1.2.2/lib/commonio.c
59--- shadow-4.1.2.2.orig/lib/commonio.c 2008-11-22 18:11:15.000000000 -0500
[63c1d49]60+++ shadow-4.1.2.2/lib/commonio.c 2009-01-04 17:49:44.478189054 -0500
[cd4af16]61@@ -183,14 +183,6 @@
62 if (!fp)
63 return NULL;
64
65-#ifdef HAVE_FCHOWN
66- if (fchown (fileno (fp), sb->st_uid, sb->st_gid))
67- goto fail;
68-#else
69- if (chown (name, sb->st_mode))
70- goto fail;
71-#endif
72-
73 #ifdef HAVE_FCHMOD
74 if (fchmod (fileno (fp), sb->st_mode & 0664))
75 goto fail;
[63c1d49]76@@ -353,9 +345,10 @@
77 if (lock_count == 0) {
78 /* Tell nscd when lock count goes to zero,
79 if any of the files were changed. */
80+
81 if (nscd_need_reload) {
82- nscd_flush_cache ("passwd");
83- nscd_flush_cache ("group");
84+// nscd_flush_cache ("passwd");
85+// nscd_flush_cache ("group");
86 nscd_need_reload = 0;
87 }
88 #ifdef HAVE_LCKPWDF
89@@ -749,7 +742,7 @@
[cd4af16]90 * Default permissions for new [g]shadow files.
91 * (passwd and group always exist...)
92 */
93- sb.st_mode = 0400;
94+ sb.st_mode = 0600;
95 sb.st_uid = 0;
96 sb.st_gid = 0;
97 }
98diff -Naur shadow-4.1.2.2.orig/lib/defines.h shadow-4.1.2.2/lib/defines.h
99--- shadow-4.1.2.2.orig/lib/defines.h 2008-11-22 18:11:15.000000000 -0500
[63c1d49]100+++ shadow-4.1.2.2/lib/defines.h 2009-01-04 17:35:46.187460880 -0500
[cd4af16]101@@ -265,20 +265,20 @@
102 (strncpy((A), (B), sizeof(A) - 1), (A)[sizeof(A) - 1] = '\0')
103
104 #ifndef PASSWD_FILE
105-#define PASSWD_FILE "/etc/passwd"
106+#define PASSWD_FILE SYSCONFDIR"/passwd"
107 #endif
108
109 #ifndef GROUP_FILE
110-#define GROUP_FILE "/etc/group"
111+#define GROUP_FILE SYSCONFDIR"/group"
112 #endif
113
114 #ifndef SHADOW_FILE
115-#define SHADOW_FILE "/etc/shadow"
116+#define SHADOW_FILE SYSCONFDIR"/shadow"
117 #endif
118
119 #ifdef SHADOWGRP
120 #ifndef SGROUP_FILE
121-#define SGROUP_FILE "/etc/gshadow"
122+#define SGROUP_FILE SYSCONFDIR"/gshadow"
123 #endif
124 #endif
125
126diff -Naur shadow-4.1.2.2.orig/lib/getdef.c shadow-4.1.2.2/lib/getdef.c
127--- shadow-4.1.2.2.orig/lib/getdef.c 2008-11-22 18:11:15.000000000 -0500
[63c1d49]128+++ shadow-4.1.2.2/lib/getdef.c 2009-01-04 17:35:46.187460880 -0500
[cd4af16]129@@ -127,7 +127,7 @@
130 };
131
132 #ifndef LOGINDEFS
133-#define LOGINDEFS "/etc/login.defs"
134+#define LOGINDEFS SYSCONFDIR"/login.defs"
135 #endif
136
137 static char def_fname[] = LOGINDEFS; /* login config defs file */
138diff -Naur shadow-4.1.2.2.orig/lib/gshadow_.h shadow-4.1.2.2/lib/gshadow_.h
139--- shadow-4.1.2.2.orig/lib/gshadow_.h 2008-11-22 18:11:15.000000000 -0500
[63c1d49]140+++ shadow-4.1.2.2/lib/gshadow_.h 2009-01-04 17:35:46.187460880 -0500
[cd4af16]141@@ -71,5 +71,5 @@
142 int putsgent ();
143 #endif
144
145-#define GSHADOW "/etc/gshadow"
146+#define GSHADOW SYSCONFDIR"/gshadow"
147 #endif /* ifndef _H_GSHADOW */
148diff -Naur shadow-4.1.2.2.orig/lib/Makefile.am shadow-4.1.2.2/lib/Makefile.am
149--- shadow-4.1.2.2.orig/lib/Makefile.am 2008-11-22 18:11:15.000000000 -0500
[63c1d49]150+++ shadow-4.1.2.2/lib/Makefile.am 2009-01-04 17:35:46.187460880 -0500
[cd4af16]151@@ -2,6 +2,7 @@
152 AUTOMAKE_OPTIONS = 1.0 foreign
153
154 DEFS =
155+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\"
156
157 noinst_LTLIBRARIES = libshadow.la
158
159diff -Naur shadow-4.1.2.2.orig/lib/Makefile.in shadow-4.1.2.2/lib/Makefile.in
160--- shadow-4.1.2.2.orig/lib/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]161+++ shadow-4.1.2.2/lib/Makefile.in 2009-01-04 17:35:46.187460880 -0500
[cd4af16]162@@ -206,9 +206,11 @@
163 srcdir = @srcdir@
164 sysconfdir = @sysconfdir@
165 target_alias = @target_alias@
166+top_build_prefix = @top_build_prefix@
167 top_builddir = @top_builddir@
168 top_srcdir = @top_srcdir@
169 AUTOMAKE_OPTIONS = 1.0 foreign
170+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\"
171 noinst_LTLIBRARIES = libshadow.la
172 libshadow_la_LDFLAGS = -version-info 0:0:0
173 libshadow_la_SOURCES = \
174diff -Naur shadow-4.1.2.2.orig/lib/port.h shadow-4.1.2.2/lib/port.h
175--- shadow-4.1.2.2.orig/lib/port.h 2008-11-22 18:11:15.000000000 -0500
[63c1d49]176+++ shadow-4.1.2.2/lib/port.h 2009-01-04 17:35:46.187460880 -0500
[cd4af16]177@@ -52,7 +52,7 @@
178 * PORT_DAY - Day of the week to a bit value (0 = Sunday).
179 */
180
181-#define PORTS "/etc/porttime"
182+#define PORTS SYSCONFDIR"/porttime"
183 #define PORT_IDS 64
184 #define PORT_TTY 64
185 #define PORT_TIMES 24
186diff -Naur shadow-4.1.2.2.orig/libmisc/limits.c shadow-4.1.2.2/libmisc/limits.c
187--- shadow-4.1.2.2.orig/libmisc/limits.c 2008-11-22 18:11:08.000000000 -0500
[63c1d49]188+++ shadow-4.1.2.2/libmisc/limits.c 2009-01-04 17:35:46.187460880 -0500
[cd4af16]189@@ -54,7 +54,7 @@
190 #endif
191 #ifdef LIMITS
192 #ifndef LIMITS_FILE
193-#define LIMITS_FILE "/etc/limits"
194+#define LIMITS_FILE SYSCONFDIR"/limits"
195 #endif
196 #define LOGIN_ERROR_RLIMIT 1
197 #define LOGIN_ERROR_LOGIN 2
198diff -Naur shadow-4.1.2.2.orig/libmisc/Makefile.am shadow-4.1.2.2/libmisc/Makefile.am
199--- shadow-4.1.2.2.orig/libmisc/Makefile.am 2008-11-22 18:11:08.000000000 -0500
[63c1d49]200+++ shadow-4.1.2.2/libmisc/Makefile.am 2009-01-04 17:35:46.187460880 -0500
[cd4af16]201@@ -1,6 +1,8 @@
202
203 EXTRA_DIST = .indent.pro xgetXXbyYY.c
204
205+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\"
206+
207 INCLUDES = -I$(top_srcdir)/lib
208
209 noinst_LIBRARIES = libmisc.a
210diff -Naur shadow-4.1.2.2.orig/libmisc/Makefile.in shadow-4.1.2.2/libmisc/Makefile.in
211--- shadow-4.1.2.2.orig/libmisc/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]212+++ shadow-4.1.2.2/libmisc/Makefile.in 2009-01-04 17:35:46.187460880 -0500
[cd4af16]213@@ -223,9 +223,11 @@
214 srcdir = @srcdir@
215 sysconfdir = @sysconfdir@
216 target_alias = @target_alias@
217+top_build_prefix = @top_build_prefix@
218 top_builddir = @top_builddir@
219 top_srcdir = @top_srcdir@
220 EXTRA_DIST = .indent.pro xgetXXbyYY.c
221+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\"
222 INCLUDES = -I$(top_srcdir)/lib
223 noinst_LIBRARIES = libmisc.a
224 libmisc_a_SOURCES = \
225diff -Naur shadow-4.1.2.2.orig/Makefile.in shadow-4.1.2.2/Makefile.in
226--- shadow-4.1.2.2.orig/Makefile.in 2008-11-22 19:10:53.000000000 -0500
[63c1d49]227+++ shadow-4.1.2.2/Makefile.in 2009-01-04 17:35:46.187460880 -0500
[cd4af16]228@@ -209,6 +209,7 @@
229 srcdir = @srcdir@
230 sysconfdir = @sysconfdir@
231 target_alias = @target_alias@
232+top_build_prefix = @top_build_prefix@
233 top_builddir = @top_builddir@
234 top_srcdir = @top_srcdir@
235 EXTRA_DIST = NEWS README TODO shadow.spec.in
236diff -Naur shadow-4.1.2.2.orig/man/cs/Makefile.in shadow-4.1.2.2/man/cs/Makefile.in
237--- shadow-4.1.2.2.orig/man/cs/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]238+++ shadow-4.1.2.2/man/cs/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]239@@ -188,6 +188,7 @@
240 srcdir = @srcdir@
241 sysconfdir = @sysconfdir@
242 target_alias = @target_alias@
243+top_build_prefix = @top_build_prefix@
244 top_builddir = @top_builddir@
245 top_srcdir = @top_srcdir@
246 man_MANS = \
247diff -Naur shadow-4.1.2.2.orig/man/de/Makefile.in shadow-4.1.2.2/man/de/Makefile.in
248--- shadow-4.1.2.2.orig/man/de/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]249+++ shadow-4.1.2.2/man/de/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]250@@ -190,6 +190,7 @@
251 srcdir = @srcdir@
252 sysconfdir = @sysconfdir@
253 target_alias = @target_alias@
254+top_build_prefix = @top_build_prefix@
255 top_builddir = @top_builddir@
256 top_srcdir = @top_srcdir@
257 man_MANS = \
258diff -Naur shadow-4.1.2.2.orig/man/es/Makefile.in shadow-4.1.2.2/man/es/Makefile.in
259--- shadow-4.1.2.2.orig/man/es/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]260+++ shadow-4.1.2.2/man/es/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]261@@ -188,6 +188,7 @@
262 srcdir = @srcdir@
263 sysconfdir = @sysconfdir@
264 target_alias = @target_alias@
265+top_build_prefix = @top_build_prefix@
266 top_builddir = @top_builddir@
267 top_srcdir = @top_srcdir@
268 man_MANS = \
269diff -Naur shadow-4.1.2.2.orig/man/fi/Makefile.in shadow-4.1.2.2/man/fi/Makefile.in
270--- shadow-4.1.2.2.orig/man/fi/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]271+++ shadow-4.1.2.2/man/fi/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]272@@ -185,6 +185,7 @@
273 srcdir = @srcdir@
274 sysconfdir = @sysconfdir@
275 target_alias = @target_alias@
276+top_build_prefix = @top_build_prefix@
277 top_builddir = @top_builddir@
278 top_srcdir = @top_srcdir@
279 man_MANS = \
280diff -Naur shadow-4.1.2.2.orig/man/fr/Makefile.in shadow-4.1.2.2/man/fr/Makefile.in
281--- shadow-4.1.2.2.orig/man/fr/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]282+++ shadow-4.1.2.2/man/fr/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]283@@ -192,6 +192,7 @@
284 srcdir = @srcdir@
285 sysconfdir = @sysconfdir@
286 target_alias = @target_alias@
287+top_build_prefix = @top_build_prefix@
288 top_builddir = @top_builddir@
289 top_srcdir = @top_srcdir@
290 man_MANS = chage.1 chfn.1 chpasswd.8 chsh.1 expiry.1 faillog.5 \
291diff -Naur shadow-4.1.2.2.orig/man/hu/Makefile.in shadow-4.1.2.2/man/hu/Makefile.in
292--- shadow-4.1.2.2.orig/man/hu/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]293+++ shadow-4.1.2.2/man/hu/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]294@@ -188,6 +188,7 @@
295 srcdir = @srcdir@
296 sysconfdir = @sysconfdir@
297 target_alias = @target_alias@
298+top_build_prefix = @top_build_prefix@
299 top_builddir = @top_builddir@
300 top_srcdir = @top_srcdir@
301 man_MANS = \
302diff -Naur shadow-4.1.2.2.orig/man/id/Makefile.in shadow-4.1.2.2/man/id/Makefile.in
303--- shadow-4.1.2.2.orig/man/id/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]304+++ shadow-4.1.2.2/man/id/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]305@@ -186,6 +186,7 @@
306 srcdir = @srcdir@
307 sysconfdir = @sysconfdir@
308 target_alias = @target_alias@
309+top_build_prefix = @top_build_prefix@
310 top_builddir = @top_builddir@
311 top_srcdir = @top_srcdir@
312 man_MANS = \
313diff -Naur shadow-4.1.2.2.orig/man/it/Makefile.in shadow-4.1.2.2/man/it/Makefile.in
314--- shadow-4.1.2.2.orig/man/it/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]315+++ shadow-4.1.2.2/man/it/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]316@@ -192,6 +192,7 @@
317 srcdir = @srcdir@
318 sysconfdir = @sysconfdir@
319 target_alias = @target_alias@
320+top_build_prefix = @top_build_prefix@
321 top_builddir = @top_builddir@
322 top_srcdir = @top_srcdir@
323 man_MANS = chage.1 chfn.1 chpasswd.8 chsh.1 expiry.1 faillog.5 \
324diff -Naur shadow-4.1.2.2.orig/man/ja/Makefile.in shadow-4.1.2.2/man/ja/Makefile.in
325--- shadow-4.1.2.2.orig/man/ja/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]326+++ shadow-4.1.2.2/man/ja/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]327@@ -189,6 +189,7 @@
328 srcdir = @srcdir@
329 sysconfdir = @sysconfdir@
330 target_alias = @target_alias@
331+top_build_prefix = @top_build_prefix@
332 top_builddir = @top_builddir@
333 top_srcdir = @top_srcdir@
334 man_MANS = chage.1 chfn.1 chpasswd.8 chsh.1 expiry.1 faillog.5 \
335diff -Naur shadow-4.1.2.2.orig/man/ko/Makefile.in shadow-4.1.2.2/man/ko/Makefile.in
336--- shadow-4.1.2.2.orig/man/ko/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]337+++ shadow-4.1.2.2/man/ko/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]338@@ -188,6 +188,7 @@
339 srcdir = @srcdir@
340 sysconfdir = @sysconfdir@
341 target_alias = @target_alias@
342+top_build_prefix = @top_build_prefix@
343 top_builddir = @top_builddir@
344 top_srcdir = @top_srcdir@
345 man_MANS = \
346diff -Naur shadow-4.1.2.2.orig/man/Makefile.in shadow-4.1.2.2/man/Makefile.in
347--- shadow-4.1.2.2.orig/man/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]348+++ shadow-4.1.2.2/man/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]349@@ -204,6 +204,7 @@
350 srcdir = @srcdir@
351 sysconfdir = @sysconfdir@
352 target_alias = @target_alias@
353+top_build_prefix = @top_build_prefix@
354 top_builddir = @top_builddir@
355 top_srcdir = @top_srcdir@
356 @USE_NLS_FALSE@SUBDIRS =
357diff -Naur shadow-4.1.2.2.orig/man/pl/Makefile.in shadow-4.1.2.2/man/pl/Makefile.in
358--- shadow-4.1.2.2.orig/man/pl/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]359+++ shadow-4.1.2.2/man/pl/Makefile.in 2009-01-04 17:35:46.190976966 -0500
[cd4af16]360@@ -191,6 +191,7 @@
361 srcdir = @srcdir@
362 sysconfdir = @sysconfdir@
363 target_alias = @target_alias@
364+top_build_prefix = @top_build_prefix@
365 top_builddir = @top_builddir@
366 top_srcdir = @top_srcdir@
367 man_MANS = chage.1 chfn.1 chgpasswd.8 chpasswd.8 chsh.1 expiry.1 \
368diff -Naur shadow-4.1.2.2.orig/man/pt_BR/Makefile.in shadow-4.1.2.2/man/pt_BR/Makefile.in
369--- shadow-4.1.2.2.orig/man/pt_BR/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]370+++ shadow-4.1.2.2/man/pt_BR/Makefile.in 2009-01-04 17:35:46.194310377 -0500
[cd4af16]371@@ -188,6 +188,7 @@
372 srcdir = @srcdir@
373 sysconfdir = @sysconfdir@
374 target_alias = @target_alias@
375+top_build_prefix = @top_build_prefix@
376 top_builddir = @top_builddir@
377 top_srcdir = @top_srcdir@
378 man_MANS = \
379diff -Naur shadow-4.1.2.2.orig/man/ru/Makefile.in shadow-4.1.2.2/man/ru/Makefile.in
380--- shadow-4.1.2.2.orig/man/ru/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]381+++ shadow-4.1.2.2/man/ru/Makefile.in 2009-01-04 17:35:46.194310377 -0500
[cd4af16]382@@ -192,6 +192,7 @@
383 srcdir = @srcdir@
384 sysconfdir = @sysconfdir@
385 target_alias = @target_alias@
386+top_build_prefix = @top_build_prefix@
387 top_builddir = @top_builddir@
388 top_srcdir = @top_srcdir@
389 man_MANS = $(man_nopam) chage.1 chfn.1 chgpasswd.8 chpasswd.8 chsh.1 \
390diff -Naur shadow-4.1.2.2.orig/man/sv/Makefile.in shadow-4.1.2.2/man/sv/Makefile.in
391--- shadow-4.1.2.2.orig/man/sv/Makefile.in 2008-11-22 19:10:52.000000000 -0500
[63c1d49]392+++ shadow-4.1.2.2/man/sv/Makefile.in 2009-01-04 17:35:46.197643570 -0500
[cd4af16]393@@ -192,6 +192,7 @@
394 srcdir = @srcdir@
395 sysconfdir = @sysconfdir@
396 target_alias = @target_alias@
397+top_build_prefix = @top_build_prefix@
398 top_builddir = @top_builddir@
399 top_srcdir = @top_srcdir@
400 man_MANS = chage.1 chfn.1 chgpasswd.8 chpasswd.8 chsh.1 expiry.1 \
401diff -Naur shadow-4.1.2.2.orig/man/tr/Makefile.in shadow-4.1.2.2/man/tr/Makefile.in
402--- shadow-4.1.2.2.orig/man/tr/Makefile.in 2008-11-22 19:10:53.000000000 -0500
[63c1d49]403+++ shadow-4.1.2.2/man/tr/Makefile.in 2009-01-04 17:35:46.197643570 -0500
[cd4af16]404@@ -188,6 +188,7 @@
405 srcdir = @srcdir@
406 sysconfdir = @sysconfdir@
407 target_alias = @target_alias@
408+top_build_prefix = @top_build_prefix@
409 top_builddir = @top_builddir@
410 top_srcdir = @top_srcdir@
411 man_MANS = \
412diff -Naur shadow-4.1.2.2.orig/man/zh_CN/Makefile.in shadow-4.1.2.2/man/zh_CN/Makefile.in
413--- shadow-4.1.2.2.orig/man/zh_CN/Makefile.in 2008-11-22 19:10:53.000000000 -0500
[63c1d49]414+++ shadow-4.1.2.2/man/zh_CN/Makefile.in 2009-01-04 17:35:46.197643570 -0500
[cd4af16]415@@ -190,6 +190,7 @@
416 srcdir = @srcdir@
417 sysconfdir = @sysconfdir@
418 target_alias = @target_alias@
419+top_build_prefix = @top_build_prefix@
420 top_builddir = @top_builddir@
421 top_srcdir = @top_srcdir@
422 man_MANS = \
423diff -Naur shadow-4.1.2.2.orig/man/zh_TW/Makefile.in shadow-4.1.2.2/man/zh_TW/Makefile.in
424--- shadow-4.1.2.2.orig/man/zh_TW/Makefile.in 2008-11-22 19:10:53.000000000 -0500
[63c1d49]425+++ shadow-4.1.2.2/man/zh_TW/Makefile.in 2009-01-04 17:35:46.197643570 -0500
[cd4af16]426@@ -190,6 +190,7 @@
427 srcdir = @srcdir@
428 sysconfdir = @sysconfdir@
429 target_alias = @target_alias@
430+top_build_prefix = @top_build_prefix@
431 top_builddir = @top_builddir@
432 top_srcdir = @top_srcdir@
433 man_MANS = \
434diff -Naur shadow-4.1.2.2.orig/src/chage.c shadow-4.1.2.2/src/chage.c
435--- shadow-4.1.2.2.orig/src/chage.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]436+++ shadow-4.1.2.2/src/chage.c 2009-01-04 17:35:46.197643570 -0500
[cd4af16]437@@ -759,7 +759,7 @@
438
439 ruid = getuid ();
440 rgid = getgid ();
441- amroot = (ruid == 0);
442+ amroot = 1; /* (ruid == 0); */
443 #ifdef WITH_SELINUX
444 if (amroot && (is_selinux_enabled () > 0)) {
445 amroot = (selinux_check_passwd_access (PASSWD__ROOTOK) == 0);
[63c1d49]446diff -Naur shadow-4.1.2.2.orig/src/chfn.c shadow-4.1.2.2/src/chfn.c
447--- shadow-4.1.2.2.orig/src/chfn.c 2008-11-22 18:11:13.000000000 -0500
448+++ shadow-4.1.2.2/src/chfn.c 2009-01-04 17:36:38.497642038 -0500
449@@ -712,7 +712,7 @@
450
451 SYSLOG ((LOG_INFO, "changed user `%s' information", user));
452
453- nscd_flush_cache ("passwd");
454+// nscd_flush_cache ("passwd");
455
456 #ifdef USE_PAM
457 pam_end (pamh, PAM_SUCCESS);
458diff -Naur shadow-4.1.2.2.orig/src/chgpasswd.c shadow-4.1.2.2/src/chgpasswd.c
459--- shadow-4.1.2.2.orig/src/chgpasswd.c 2008-11-22 18:11:13.000000000 -0500
460+++ shadow-4.1.2.2/src/chgpasswd.c 2009-01-04 17:36:51.777440247 -0500
461@@ -487,7 +487,7 @@
462
463 close_files ();
464
465- nscd_flush_cache ("group");
466+// nscd_flush_cache ("group");
467
468 #ifdef USE_PAM
469 pam_end (pamh, PAM_SUCCESS);
470diff -Naur shadow-4.1.2.2.orig/src/chpasswd.c shadow-4.1.2.2/src/chpasswd.c
471--- shadow-4.1.2.2.orig/src/chpasswd.c 2008-11-22 18:11:13.000000000 -0500
472+++ shadow-4.1.2.2/src/chpasswd.c 2009-01-04 17:37:03.177974182 -0500
473@@ -472,7 +472,7 @@
474
475 close_files ();
476
477- nscd_flush_cache ("passwd");
478+// nscd_flush_cache ("passwd");
479
480 #ifdef USE_PAM
481 pam_end (pamh, PAM_SUCCESS);
[cd4af16]482diff -Naur shadow-4.1.2.2.orig/src/chsh.c shadow-4.1.2.2/src/chsh.c
483--- shadow-4.1.2.2.orig/src/chsh.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]484+++ shadow-4.1.2.2/src/chsh.c 2009-01-04 17:37:20.960781498 -0500
[cd4af16]485@@ -55,7 +55,7 @@
486 #include "pam_defs.h"
487 #endif
488 #ifndef SHELLS_FILE
489-#define SHELLS_FILE "/etc/shells"
490+#define SHELLS_FILE SYSCONFDIR"/shells"
491 #endif
492 /*
493 * Global variables
494@@ -440,7 +440,7 @@
495 /*
496 * This command behaves different for root and non-root users.
497 */
498- amroot = getuid () == 0;
499+ amroot = 1; /* getuid () == 0; */
500
501 /*
502 * Get the program name. The program name is used as a prefix to
[63c1d49]503@@ -540,7 +540,7 @@
504
505 SYSLOG ((LOG_INFO, "changed user `%s' shell to `%s'", user, loginsh));
506
507- nscd_flush_cache ("passwd");
508+// nscd_flush_cache ("passwd");
509
510 #ifdef USE_PAM
511 pam_end (pamh, PAM_SUCCESS);
[cd4af16]512diff -Naur shadow-4.1.2.2.orig/src/gpasswd.c shadow-4.1.2.2/src/gpasswd.c
513--- shadow-4.1.2.2.orig/src/gpasswd.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]514+++ shadow-4.1.2.2/src/gpasswd.c 2009-01-04 17:37:35.680767524 -0500
[cd4af16]515@@ -81,7 +81,7 @@
516 /* The UID of the caller */
517 static unsigned long bywho = -1;
518 /* Indicate if gpasswd was called by root */
519-#define amroot (0 == bywho)
520+#define amroot 1 /* (0 == bywho) */
521
522 /* The number of retries for th user to provide and repeat a new password */
523 #ifndef RETRIES
524@@ -966,6 +966,7 @@
525 * output, etc.
526 */
527 output:
528+/*
529 if (setuid (0) != 0) {
530 fputs (_("Cannot change ID to root.\n"), stderr);
531 SYSLOG ((LOG_ERR, "can't setuid(0)"));
532@@ -976,6 +977,7 @@
533 closelog ();
534 fail_exit (1);
535 }
536+*/
537 pwd_init ();
538
539 open_files ();
[63c1d49]540@@ -988,7 +990,7 @@
541
542 close_files ();
543
544- nscd_flush_cache ("group");
545+// nscd_flush_cache ("group");
546
547 exit (E_SUCCESS);
548 }
549diff -Naur shadow-4.1.2.2.orig/src/groupadd.c shadow-4.1.2.2/src/groupadd.c
550--- shadow-4.1.2.2.orig/src/groupadd.c 2008-11-22 18:11:13.000000000 -0500
551+++ shadow-4.1.2.2/src/groupadd.c 2009-01-04 17:37:45.808677407 -0500
552@@ -575,7 +575,7 @@
553 grp_update ();
554 close_files ();
555
556- nscd_flush_cache ("group");
557+// nscd_flush_cache ("group");
558
559 #ifdef USE_PAM
560 pam_end (pamh, PAM_SUCCESS);
561diff -Naur shadow-4.1.2.2.orig/src/groupdel.c shadow-4.1.2.2/src/groupdel.c
562--- shadow-4.1.2.2.orig/src/groupdel.c 2008-11-22 18:11:13.000000000 -0500
563+++ shadow-4.1.2.2/src/groupdel.c 2009-01-04 17:37:59.640771523 -0500
564@@ -366,7 +366,7 @@
565
566 close_files ();
567
568- nscd_flush_cache ("group");
569+// nscd_flush_cache ("group");
570
571 #ifdef USE_PAM
572 if (retval == PAM_SUCCESS)
573diff -Naur shadow-4.1.2.2.orig/src/groupmod.c shadow-4.1.2.2/src/groupmod.c
574--- shadow-4.1.2.2.orig/src/groupmod.c 2008-11-22 18:11:13.000000000 -0500
575+++ shadow-4.1.2.2/src/groupmod.c 2009-01-04 17:38:10.984091461 -0500
576@@ -694,7 +694,7 @@
577
578 close_files ();
579
580- nscd_flush_cache ("group");
581+// nscd_flush_cache ("group");
582
583 #ifdef USE_PAM
584 if (retval == PAM_SUCCESS)
585diff -Naur shadow-4.1.2.2.orig/src/grpck.c shadow-4.1.2.2/src/grpck.c
586--- shadow-4.1.2.2.orig/src/grpck.c 2008-11-22 18:11:13.000000000 -0500
587+++ shadow-4.1.2.2/src/grpck.c 2009-01-04 17:38:25.327423087 -0500
588@@ -777,7 +777,7 @@
589 /* Commit the change in the database if needed */
590 close_files (changed);
591
592- nscd_flush_cache ("group");
593+// nscd_flush_cache ("group");
594
595 /*
596 * Tell the user what we did and exit.
597diff -Naur shadow-4.1.2.2.orig/src/grpconv.c shadow-4.1.2.2/src/grpconv.c
598--- shadow-4.1.2.2.orig/src/grpconv.c 2008-11-22 18:11:13.000000000 -0500
599+++ shadow-4.1.2.2/src/grpconv.c 2009-01-04 17:38:32.594090975 -0500
600@@ -179,7 +179,7 @@
601 sgr_unlock ();
602 gr_unlock ();
603
604- nscd_flush_cache ("group");
605+// nscd_flush_cache ("group");
606
607 return 0;
608 }
609diff -Naur shadow-4.1.2.2.orig/src/grpunconv.c shadow-4.1.2.2/src/grpunconv.c
610--- shadow-4.1.2.2.orig/src/grpunconv.c 2008-11-22 18:11:13.000000000 -0500
611+++ shadow-4.1.2.2/src/grpunconv.c 2009-01-04 17:38:45.274092355 -0500
612@@ -142,7 +142,7 @@
613 sgr_unlock ();
614 gr_unlock ();
615
616- nscd_flush_cache ("group");
617+// nscd_flush_cache ("group");
618
619 return 0;
620 }
[cd4af16]621diff -Naur shadow-4.1.2.2.orig/src/login_nopam.c shadow-4.1.2.2/src/login_nopam.c
622--- shadow-4.1.2.2.orig/src/login_nopam.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]623+++ shadow-4.1.2.2/src/login_nopam.c 2009-01-04 17:35:46.197643570 -0500
[cd4af16]624@@ -59,7 +59,7 @@
625
626 /* Path name of the access control file. */
627 #ifndef TABLE
628-#define TABLE "/etc/login.access"
629+#define TABLE SYSCONFDIR"/login.access"
630 #endif
631
632 /* Delimiters for fields and for lists of users, ttys or hosts. */
633diff -Naur shadow-4.1.2.2.orig/src/logoutd.c shadow-4.1.2.2/src/logoutd.c
634--- shadow-4.1.2.2.orig/src/logoutd.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]635+++ shadow-4.1.2.2/src/logoutd.c 2009-01-04 17:35:46.197643570 -0500
[cd4af16]636@@ -50,7 +50,7 @@
637 #endif
638
639 #ifndef HUP_MESG_FILE
640-#define HUP_MESG_FILE "/etc/logoutd.mesg"
641+#define HUP_MESG_FILE SYSCONFDIR"/logoutd.mesg"
642 #endif
643
644 #if HAVE_UTMPX_H
645diff -Naur shadow-4.1.2.2.orig/src/Makefile.am shadow-4.1.2.2/src/Makefile.am
646--- shadow-4.1.2.2.orig/src/Makefile.am 2008-11-22 18:11:13.000000000 -0500
[63c1d49]647+++ shadow-4.1.2.2/src/Makefile.am 2009-01-04 17:35:46.197643570 -0500
[cd4af16]648@@ -3,7 +3,7 @@
649 .indent.pro
650
651 ubindir = ${prefix}/bin
652-usbindir = ${prefix}/sbin
653+usbindir = ${prefix}/bin
654 suidperms = 4755
655
656 INCLUDES = \
657@@ -53,7 +53,7 @@
658 LDADD = $(INTLLIBS) \
659 $(top_builddir)/libmisc/libmisc.a \
660 $(top_builddir)/lib/libshadow.la
661-AM_CPPFLAGS = -DLOCALEDIR=\"$(datadir)/locale\"
662+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\" -DLOCALEDIR=\"$(datadir)/locale\" -DSG=\"`echo sg | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`\" -DVIGR=\"`echo vigr | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`\"
663
664 chage_LDADD = $(LDADD) $(LIBPAM) $(LIBAUDIT) $(LIBSELINUX)
665 chfn_LDADD = $(LDADD) $(LIBPAM) $(LIBSELINUX) $(LIBCRYPT) $(LIBSKEY) $(LIBMD)
666@@ -91,11 +91,11 @@
667
668 install-am: all-am
669 $(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
670- ln -sf newgrp $(DESTDIR)$(ubindir)/sg
671- ln -sf vipw $(DESTDIR)$(usbindir)/vigr
672+ ln -sf `echo newgrp | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(ubindir)/`echo sg | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
673+ ln -sf `echo vipw | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(usbindir)/`echo vigr | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
674 for i in $(suidbins); do \
675- chmod -f $(suidperms) $(DESTDIR)$(bindir)/$$i; \
676+ chmod -f 4755 $(DESTDIR)$(bindir)/`echo $$i | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
677 done
678 for i in $(suidubins); do \
679- chmod -f $(suidperms) $(DESTDIR)$(ubindir)/$$i; \
680+ chmod -f 4755 $(DESTDIR)$(ubindir)/`echo $$i | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
681 done
682diff -Naur shadow-4.1.2.2.orig/src/Makefile.in shadow-4.1.2.2/src/Makefile.in
683--- shadow-4.1.2.2.orig/src/Makefile.in 2008-11-22 19:10:53.000000000 -0500
[63c1d49]684+++ shadow-4.1.2.2/src/Makefile.in 2009-01-04 17:35:46.200767525 -0500
[cd4af16]685@@ -371,13 +371,14 @@
686 srcdir = @srcdir@
687 sysconfdir = @sysconfdir@
688 target_alias = @target_alias@
689+top_build_prefix = @top_build_prefix@
690 top_builddir = @top_builddir@
691 top_srcdir = @top_srcdir@
692 EXTRA_DIST = \
693 .indent.pro
694
695 ubindir = ${prefix}/bin
696-usbindir = ${prefix}/sbin
697+usbindir = ${prefix}/bin
698 suidperms = 4755
699 INCLUDES = \
700 -I${top_srcdir}/lib \
701@@ -389,7 +390,7 @@
702 $(top_builddir)/libmisc/libmisc.a \
703 $(top_builddir)/lib/libshadow.la
704
705-AM_CPPFLAGS = -DLOCALEDIR=\"$(datadir)/locale\"
706+AM_CPPFLAGS = -DSYSCONFDIR=\"$(sysconfdir)\" -DLOCALEDIR=\"$(datadir)/locale\" -DSG=\"`echo sg | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`\" -DVIGR=\"`echo vigr | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`\"
707 chage_LDADD = $(LDADD) $(LIBPAM) $(LIBAUDIT) $(LIBSELINUX)
708 chfn_LDADD = $(LDADD) $(LIBPAM) $(LIBSELINUX) $(LIBCRYPT) $(LIBSKEY) $(LIBMD)
709 chgpasswd_LDADD = $(LDADD) $(LIBPAM) $(LIBSELINUX) $(LIBCRYPT)
710@@ -931,13 +932,13 @@
711
712 install-am: all-am
713 $(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
714- ln -sf newgrp $(DESTDIR)$(ubindir)/sg
715- ln -sf vipw $(DESTDIR)$(usbindir)/vigr
716+ ln -sf `echo newgrp | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(ubindir)/`echo sg | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
717+ ln -sf `echo vipw | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(usbindir)/`echo vigr | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
718 for i in $(suidbins); do \
719- chmod -f $(suidperms) $(DESTDIR)$(bindir)/$$i; \
720+ chmod -f 4755 $(DESTDIR)$(bindir)/`echo $$i | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
721 done
722 for i in $(suidubins); do \
723- chmod -f $(suidperms) $(DESTDIR)$(ubindir)/$$i; \
724+ chmod -f 4755 $(DESTDIR)$(ubindir)/`echo $$i | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
725 done
726 # Tell versions [3.59,3.63) of GNU make to not export all variables.
727 # Otherwise a system limit (for SysV at least) may be exceeded.
728diff -Naur shadow-4.1.2.2.orig/src/newgrp.c shadow-4.1.2.2/src/newgrp.c
729--- shadow-4.1.2.2.orig/src/newgrp.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]730+++ shadow-4.1.2.2/src/newgrp.c 2009-01-04 17:35:46.200767525 -0500
[cd4af16]731@@ -270,7 +270,7 @@
732 if (child < 0) {
733 /* error in fork() */
734 fprintf (stderr, _("%s: failure forking: %s\n"),
735- is_newgrp ? "newgrp" : "sg", strerror (errno));
736+ is_newgrp ? "newgrp" : SG, strerror (errno));
737 #ifdef WITH_AUDIT
738 if (group) {
739 snprintf (audit_buf, sizeof(audit_buf),
740@@ -387,7 +387,7 @@
741 */
742 Prog = Basename (argv[0]);
743 is_newgrp = (strcmp (Prog, "newgrp") == 0);
744- OPENLOG (is_newgrp ? "newgrp" : "sg");
745+ OPENLOG (is_newgrp ? "newgrp" : SG);
746 gid = getgid ();
747 argc--;
748 argv++;
[63c1d49]749diff -Naur shadow-4.1.2.2.orig/src/newusers.c shadow-4.1.2.2/src/newusers.c
750--- shadow-4.1.2.2.orig/src/newusers.c 2008-11-22 18:11:13.000000000 -0500
751+++ shadow-4.1.2.2/src/newusers.c 2009-01-04 17:39:02.984711408 -0500
752@@ -865,8 +865,8 @@
753
754 close_files ();
755
756- nscd_flush_cache ("passwd");
757- nscd_flush_cache ("group");
758+// nscd_flush_cache ("passwd");
759+// nscd_flush_cache ("group");
760
761 #ifdef USE_PAM
762 pam_end (pamh, PAM_SUCCESS);
[cd4af16]763diff -Naur shadow-4.1.2.2.orig/src/passwd.c shadow-4.1.2.2/src/passwd.c
764--- shadow-4.1.2.2.orig/src/passwd.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]765+++ shadow-4.1.2.2/src/passwd.c 2009-01-04 17:39:10.697416330 -0500
[cd4af16]766@@ -717,7 +717,7 @@
767 * The program behaves differently when executed by root than when
768 * executed by a normal user.
769 */
770- amroot = (getuid () == 0);
771+ amroot = 1; /* (getuid () == 0); */
772
773 /*
774 * Get the program name. The program name is used as a prefix to
[63c1d49]775@@ -998,19 +998,21 @@
[cd4af16]776 exit (E_SUCCESS);
777 }
778 #endif /* USE_PAM */
779+/*
780 if (setuid (0)) {
781 fputs (_("Cannot change ID to root.\n"), stderr);
782 SYSLOG ((LOG_ERR, "can't setuid(0)"));
783 closelog ();
784 exit (E_NOPERM);
785 }
786+*/
787 if (spw_file_present ())
788 update_shadow ();
789 else
[63c1d49]790 update_noshadow ();
791
792- nscd_flush_cache ("passwd");
793- nscd_flush_cache ("group");
794+// nscd_flush_cache ("passwd");
795+// nscd_flush_cache ("group");
796
797 SYSLOG ((LOG_INFO, "password for `%s' changed by `%s'", name, myname));
798 closelog ();
799diff -Naur shadow-4.1.2.2.orig/src/pwck.c shadow-4.1.2.2/src/pwck.c
800--- shadow-4.1.2.2.orig/src/pwck.c 2008-11-22 18:11:13.000000000 -0500
801+++ shadow-4.1.2.2/src/pwck.c 2009-01-04 17:39:28.314083740 -0500
802@@ -636,7 +636,7 @@
803
804 close_files (changed);
805
806- nscd_flush_cache ("passwd");
807+// nscd_flush_cache ("passwd");
808
809 /*
810 * Tell the user what we did and exit.
811diff -Naur shadow-4.1.2.2.orig/src/pwconv.c shadow-4.1.2.2/src/pwconv.c
812--- shadow-4.1.2.2.orig/src/pwconv.c 2008-11-22 18:11:13.000000000 -0500
813+++ shadow-4.1.2.2/src/pwconv.c 2009-01-04 17:39:39.097415639 -0500
814@@ -208,7 +208,7 @@
815 spw_unlock ();
816 pw_unlock ();
817
818- nscd_flush_cache ("passwd");
819+// nscd_flush_cache ("passwd");
820
821 exit (E_SUCCESS);
822 }
823diff -Naur shadow-4.1.2.2.orig/src/pwunconv.c shadow-4.1.2.2/src/pwunconv.c
824--- shadow-4.1.2.2.orig/src/pwunconv.c 2008-11-22 18:11:13.000000000 -0500
825+++ shadow-4.1.2.2/src/pwunconv.c 2009-01-04 17:39:49.297468490 -0500
826@@ -149,7 +149,7 @@
827 spw_unlock ();
828 pw_unlock ();
829
830- nscd_flush_cache ("passwd");
831+// nscd_flush_cache ("passwd");
832
833 return 0;
834 }
[cd4af16]835diff -Naur shadow-4.1.2.2.orig/src/suauth.c shadow-4.1.2.2/src/suauth.c
836--- shadow-4.1.2.2.orig/src/suauth.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]837+++ shadow-4.1.2.2/src/suauth.c 2009-01-04 17:35:46.200767525 -0500
[cd4af16]838@@ -40,7 +40,7 @@
839 #include "prototypes.h"
840
841 #ifndef SUAUTHFILE
842-#define SUAUTHFILE "/etc/suauth"
843+#define SUAUTHFILE SYSCONFDIR"/suauth"
844 #endif
845
846 #define NOACTION 0
847diff -Naur shadow-4.1.2.2.orig/src/useradd.c shadow-4.1.2.2/src/useradd.c
848--- shadow-4.1.2.2.orig/src/useradd.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]849+++ shadow-4.1.2.2/src/useradd.c 2009-01-04 17:40:06.618042276 -0500
[cd4af16]850@@ -64,11 +64,11 @@
851 #include "shadowio.h"
852
853 #ifndef SKEL_DIR
854-#define SKEL_DIR "/etc/skel"
855+#define SKEL_DIR SYSCONFDIR"/skel"
856 #endif
857 #ifndef USER_DEFAULTS_FILE
858-#define USER_DEFAULTS_FILE "/etc/default/useradd"
859-#define NEW_USER_FILE "/etc/default/nuaddXXXXXX"
860+#define USER_DEFAULTS_FILE SYSCONFDIR"/default/useradd"
861+#define NEW_USER_FILE SYSCONFDIR"/default/nuaddXXXXXX"
862 #endif
863 /*
864 * Needed for MkLinux DR1/2/2.1 - J.
[63c1d49]865@@ -1751,8 +1751,8 @@
866
867 close_files ();
868
869- nscd_flush_cache ("passwd");
870- nscd_flush_cache ("group");
871+// nscd_flush_cache ("passwd");
872+// nscd_flush_cache ("group");
873
874 #ifdef USE_PAM
875 if (retval == PAM_SUCCESS)
876diff -Naur shadow-4.1.2.2.orig/src/userdel.c shadow-4.1.2.2/src/userdel.c
877--- shadow-4.1.2.2.orig/src/userdel.c 2008-11-22 18:11:13.000000000 -0500
878+++ shadow-4.1.2.2/src/userdel.c 2009-01-04 17:40:20.458047660 -0500
879@@ -818,8 +818,8 @@
880 user_cancel (user_name);
881 close_files ();
882
883- nscd_flush_cache ("passwd");
884- nscd_flush_cache ("group");
885+// nscd_flush_cache ("passwd");
886+// nscd_flush_cache ("group");
887
888 #ifdef USE_PAM
889 if (retval == PAM_SUCCESS)
890diff -Naur shadow-4.1.2.2.orig/src/usermod.c shadow-4.1.2.2/src/usermod.c
891--- shadow-4.1.2.2.orig/src/usermod.c 2008-11-22 18:11:13.000000000 -0500
892+++ shadow-4.1.2.2/src/usermod.c 2009-01-04 17:40:28.647917233 -0500
893@@ -1531,8 +1531,8 @@
894 grp_update ();
895 close_files ();
896
897- nscd_flush_cache ("passwd");
898- nscd_flush_cache ("group");
899+// nscd_flush_cache ("passwd");
900+// nscd_flush_cache ("group");
901
902 if (mflg)
903 move_home ();
[cd4af16]904diff -Naur shadow-4.1.2.2.orig/src/vipw.c shadow-4.1.2.2/src/vipw.c
905--- shadow-4.1.2.2.orig/src/vipw.c 2008-11-22 18:11:13.000000000 -0500
[63c1d49]906+++ shadow-4.1.2.2/src/vipw.c 2009-01-04 17:40:43.305534712 -0500
[cd4af16]907@@ -257,7 +257,7 @@
908 textdomain (PACKAGE);
909
910 progname = ((a = strrchr (*argv, '/')) ? a + 1 : *argv);
911- do_vipw = (strcmp (progname, "vigr") != 0);
912+ do_vipw = (strcmp (progname, VIGR) != 0);
913
914 {
915 /*
[63c1d49]916@@ -334,8 +334,8 @@
917 #endif
918 }
919
920- nscd_flush_cache ("passwd");
921- nscd_flush_cache ("group");
922+// nscd_flush_cache ("passwd");
923+// nscd_flush_cache ("group");
924
925 exit (E_SUCCESS);
926 }
Note: See TracBrowser for help on using the repository browser.