[BUG] passwd file paths defined in multiple places
Denys Vlasenko
vda.linux at googlemail.com
Wed Jan 12 13:25:17 UTC 2011
On Tue, Jan 11, 2011 at 3:25 PM, Tito <farmatito at tiscali.it> wrote:
> form libbb.h
>
> #define bb_path_passwd_file "/etc/passwd"
> #define bb_path_shadow_file "/etc/shadow"
> #define bb_path_gshadow_file "/etc/gshadow"
> #define bb_path_group_file "/etc/group"
>
> from pwd_grp.c
>
> #ifndef _PATH_SHADOW
> #define _PATH_SHADOW "/etc/shadow"
> #endif
> #ifndef _PATH_PASSWD
> #define _PATH_PASSWD "/etc/passwd"
> #endif
> #ifndef _PATH_GROUP
> #define _PATH_GROUP "/etc/group"
> #endif
>
>
> the paths are defined in multiple places and
> with CONFIG_USE_BB_PWD_GRP=y
> if you change them in libbb.h
> the changes are not honoured in pwd_grp.c
> SHould be consistent and defined in only one file
> for example for testing purposes on local files like:
>
> #ifdef DEBUG_PWD_GRP
> #define bb_path_passwd_file "./passwd"
> #define bb_path_shadow_file "./shadow"
> #define bb_path_gshadow_file "./gshadow"
> #define bb_path_group_file "./group"
> #else
> #define bb_path_passwd_file "/etc/passwd"
> #define bb_path_shadow_file "/etc/shadow"
> #define bb_path_gshadow_file "/etc/gshadow"
> #define bb_path_group_file "/etc/group"
> #endif
>
> Denys what you think about that?
They are not meant to be configurable.
(I believe pwd_grp.c has been taken from uclibc,
presumably to make glibc-without-nss builds possible.)
--
vda
More information about the busybox
mailing list