Reference count cached passwd and group structs. The cache holds
one reference itself and another is added by sudo_getgr{gid,nam} and sudo_getpw{uid,nam}. The final ref on the runas and user passwd and group structs are persistent for now.
This commit is contained in:
@@ -270,6 +270,10 @@ struct passwd *sudo_getpwuid(uid_t);
|
||||
struct group *sudo_getgrnam(const char *);
|
||||
struct group *sudo_fakegrnam(const char *);
|
||||
struct group *sudo_getgrgid(gid_t);
|
||||
void gr_addref(struct group *);
|
||||
void gr_delref(struct group *);
|
||||
void pw_addref(struct passwd *);
|
||||
void pw_delref(struct passwd *);
|
||||
int user_in_group(struct passwd *, const char *);
|
||||
|
||||
/* timestr.c */
|
||||
|
Reference in New Issue
Block a user