Move check_user_shell() to pwutil.c as user_shell_valid()

This will make it possible to support a different backend which may
be used by testsudoers in the future.
This commit is contained in:
Todd C. Miller
2023-09-09 14:07:28 -06:00
parent 28a13501d8
commit d18ee8e0e7
8 changed files with 41 additions and 35 deletions

View File

@@ -73,5 +73,6 @@ struct cache_item *sudo_make_gritem(gid_t gid, const char *group);
struct cache_item *sudo_make_grlist_item(const struct passwd *pw, char * const *groups);
struct cache_item *sudo_make_gidlist_item(const struct passwd *pw, int ngids, GETGROUPS_T *gids, char * const *gidstrs, unsigned int type);
struct cache_item *sudo_make_pwitem(uid_t uid, const char *user);
bool valid_shell(const char *shell);
#endif /* SUDOERS_PWUTIL_H */