s/getpwnam/k_&/g.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@517 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -371,7 +371,7 @@ globtilde(const Char *pattern, Char *patbuf, glob_t *pglob)
|
||||
/*
|
||||
* Expand a ~user
|
||||
*/
|
||||
if ((pwd = getpwnam((char*) patbuf)) == NULL)
|
||||
if ((pwd = k_getpwnam((char*) patbuf)) == NULL)
|
||||
return pattern;
|
||||
else
|
||||
h = pwd->pw_dir;
|
||||
|
@@ -201,7 +201,7 @@ static char *gunique (char *);
|
||||
static void lostconn (int);
|
||||
static int receive_data (FILE *, FILE *);
|
||||
static void send_data (FILE *, FILE *, off_t);
|
||||
static struct passwd * sgetpwnam (char *);
|
||||
static struct passwd * sk_getpwnam (char *);
|
||||
|
||||
static char *
|
||||
curdir(void)
|
||||
@@ -464,7 +464,7 @@ sgetpwnam(char *name)
|
||||
static struct passwd save;
|
||||
struct passwd *p;
|
||||
|
||||
if ((p = getpwnam(name)) == NULL)
|
||||
if ((p = k_getpwnam(name)) == NULL)
|
||||
return (p);
|
||||
if (save.pw_name) {
|
||||
free(save.pw_name);
|
||||
|
@@ -51,7 +51,7 @@ recv_conn (int sock, des_cblock *key, des_key_schedule schedule,
|
||||
strncmp(version, "KXSERV.0", KRB_SENDAUTH_VLEN) != 0) {
|
||||
return 1;
|
||||
}
|
||||
passwd = getpwnam (auth.pname);
|
||||
passwd = k_getpwnam (auth.pname);
|
||||
if (passwd == NULL)
|
||||
return fatal (sock, "Cannot find uid");
|
||||
username = strdup (passwd->pw_name);
|
||||
|
@@ -31,7 +31,7 @@ pop_pass (POP *p)
|
||||
#endif /* KERBEROS */
|
||||
|
||||
/* Look for the user in the password file */
|
||||
if ((pw = getpwnam(p->user)) == NULL)
|
||||
if ((pw = k_getpwnam(p->user)) == NULL)
|
||||
return (pop_msg(p,POP_FAILURE,
|
||||
"Password supplied for \"%s\" is incorrect.",p->user));
|
||||
|
||||
|
@@ -420,7 +420,7 @@ rd_and_store_for_creds(inbuf, ticket, lusername)
|
||||
return(retval);
|
||||
}
|
||||
|
||||
if (!(pwd = (struct passwd *) getpwnam(lusername))) {
|
||||
if (!(pwd = (struct passwd *) k_getpwnam(lusername))) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@@ -413,7 +413,7 @@ char *name, *passwd;
|
||||
struct passwd *pwd;
|
||||
int passwdok_status = 0;
|
||||
|
||||
if (pwd = getpwnam(name))
|
||||
if (pwd = k_getpwnam(name))
|
||||
salt = pwd->pw_passwd;
|
||||
else salt = "xx";
|
||||
|
||||
|
@@ -462,7 +462,7 @@ char *name, *passwd;
|
||||
struct passwd *pwd;
|
||||
int passwdok_status = 0;
|
||||
|
||||
if (pwd = getpwnam(name))
|
||||
if (pwd = k_getpwnam(name))
|
||||
salt = pwd->pw_passwd;
|
||||
else salt = "xx";
|
||||
|
||||
|
@@ -488,7 +488,7 @@ spx_status(ap, name, level)
|
||||
* and acl_file to "~kannan/.sphinx"
|
||||
*/
|
||||
|
||||
pwd = getpwnam(UserNameRequested);
|
||||
pwd = k_getpwnam(UserNameRequested);
|
||||
if (pwd == NULL) {
|
||||
return(AUTH_USER); /* not authenticated */
|
||||
}
|
||||
|
@@ -2362,7 +2362,7 @@ int tn(int argc, char **argv)
|
||||
|
||||
user = getenv("USER");
|
||||
if (user == NULL ||
|
||||
((pw = getpwnam(user)) && pw->pw_uid != getuid())) {
|
||||
((pw = k_getpwnam(user)) && pw->pw_uid != getuid())) {
|
||||
if (pw = getpwuid(getuid()))
|
||||
user = pw->pw_name;
|
||||
else
|
||||
|
@@ -31,7 +31,7 @@ SHLIBEXT = @SHLIBEXT@
|
||||
LIB = $(LIBNAME).$(LIBEXT)
|
||||
|
||||
|
||||
OBJECTS = signal.o @LIBOBJS@
|
||||
OBJECTS = k_getpwnam.o signal.o @LIBOBJS@
|
||||
|
||||
all: $(LIB)
|
||||
|
||||
|
@@ -371,7 +371,7 @@ globtilde(const Char *pattern, Char *patbuf, glob_t *pglob)
|
||||
/*
|
||||
* Expand a ~user
|
||||
*/
|
||||
if ((pwd = getpwnam((char*) patbuf)) == NULL)
|
||||
if ((pwd = k_getpwnam((char*) patbuf)) == NULL)
|
||||
return pattern;
|
||||
else
|
||||
h = pwd->pw_dir;
|
||||
|
@@ -220,7 +220,7 @@ again:
|
||||
}
|
||||
if (first == 1 && (__check_rhosts_file || superuser)) {
|
||||
first = 0;
|
||||
if ((pwd = getpwnam(luser)) == NULL)
|
||||
if ((pwd = k_getpwnam(luser)) == NULL)
|
||||
return (-1);
|
||||
(void)strcpy(pbuf, pwd->pw_dir);
|
||||
(void)strcat(pbuf, "/.rhosts");
|
||||
|
@@ -70,4 +70,7 @@ int getent(char *cp, char *name);
|
||||
char *getstr(char *id, char **cpp);
|
||||
#endif
|
||||
|
||||
#include <pwd.h>
|
||||
struct passwd *k_getpwnam (char *user);
|
||||
|
||||
#endif /* __ROKEN_H__ */
|
||||
|
@@ -70,4 +70,7 @@ int getent(char *cp, char *name);
|
||||
char *getstr(char *id, char **cpp);
|
||||
#endif
|
||||
|
||||
#include <pwd.h>
|
||||
struct passwd *k_getpwnam (char *user);
|
||||
|
||||
#endif /* __ROKEN_H__ */
|
||||
|
Reference in New Issue
Block a user