Searched refs:pwd (Results 1 - 25 of 560) sorted by relevance

1234567891011>>

/netbsd-current/external/mit/libuv/dist/test/
H A Dtest-get-passwd.c36 uv_passwd_t pwd; local
41 r = uv_os_get_passwd(&pwd);
43 len = strlen(pwd.username);
47 ASSERT_NULL(pwd.shell);
49 len = strlen(pwd.shell);
55 len = strlen(pwd.homedir);
59 if (len == 3 && pwd.homedir[1] == ':')
60 ASSERT(pwd.homedir[2] == '\\');
62 ASSERT(pwd.homedir[len - 1] != '\\');
65 ASSERT(pwd
[all...]
/netbsd-current/external/ibm-public/postfix/dist/src/util/
H A Dusername.c32 #include <pwd.h>
43 struct passwd *pwd; local
46 if ((pwd = getpwuid(uid)) == 0)
48 return (pwd->pw_name);
H A Dchroot_uid.c34 #include <pwd.h>
47 struct passwd *pwd; local
56 if ((pwd = getpwnam(user_name)) == 0)
58 uid = pwd->pw_uid;
59 gid = pwd->pw_gid;
H A Dfullname.c41 #include <pwd.h>
60 struct passwd *pwd; local
75 if ((pwd = getpwuid(uid)) == 0)
85 for (cp = pwd->pw_gecos; (ch = *(unsigned char *) cp) != 0; cp++) {
89 if (pwd->pw_name[0]) {
90 VSTRING_ADDCH(result, TOUPPER(pwd->pw_name[0]));
91 vstring_strcat(result, pwd->pw_name + 1);
/netbsd-current/tools/compat/
H A Dsetpassent.c6 #include <pwd.h>
/netbsd-current/crypto/external/bsd/heimdal/dist/lib/roken/
H A Dget_default_username.c66 struct passwd *pwd; local
69 pwd = k_getpwnam (user);
70 if (pwd != NULL && pwd->pw_uid == uid)
73 pwd = k_getpwuid (uid);
74 if (pwd != NULL)
75 return pwd->pw_name;
H A Dgetxxyyy.c52 copypw(struct passwd *pwd, char *buffer, size_t bufsize, const struct passwd *p) argument
63 memset(pwd, 0, sizeof(*pwd));
70 pwd->el = buffer; \
78 pwd->pw_uid = p->pw_uid;
79 pwd->pw_gid = p->pw_gid;
91 rk_getpwnam_r(const char *name, struct passwd *pwd, char *buffer, argument
103 copypw(pwd, buffer, bufsize, p);
105 *result = pwd;
117 rk_getpwnam_r(const char *name, struct passwd *pwd, cha argument
158 struct passwd pwd, *result; local
[all...]
/netbsd-current/tests/lib/librumphijack/
H A Dh_cwd.c43 static char pwd[1024]; variable
84 if (getcwd(pwd, sizeof(pwd)) == NULL)
86 if (strcmp(pwd, prefix) != 0)
92 if (getcwd(pwd, sizeof(pwd)) == NULL)
94 if (strcmp(pwd, makepath("dir")) != 0)
100 if (getcwd(pwd, sizeof(pwd)) == NULL)
102 if (strcmp(pwd, makepat
[all...]
/netbsd-current/usr.bin/newgrp/
H A Dnewgrp.c43 #include <pwd.h>
66 struct passwd *pwd; local
76 pwd = getpwuid(uid);
77 if (pwd == NULL)
81 if ((lc = login_getclass(pwd->pw_class)) == NULL)
82 errx(EXIT_FAILURE, "%s: unknown login class", pwd->pw_class);
106 pwd->pw_gid = newgrp(*argv, pwd);
107 addgrp(pwd->pw_gid);
108 if (setgid(pwd
[all...]
/netbsd-current/crypto/external/bsd/heimdal/dist/lib/otp/
H A Dotp_md.h38 int otp_md4_init (OtpKey key, const char *pwd, const char *seed);
42 int otp_md5_init (OtpKey key, const char *pwd, const char *seed);
46 int otp_sha_init (OtpKey key, const char *pwd, const char *seed);
/netbsd-current/external/bsd/openpam/dist/lib/libpam/
H A Dopenpam_borrow_cred.c49 #include <pwd.h>
66 const struct passwd *pwd)
72 ENTERN(pwd->pw_uid);
79 if (geteuid() != 0 && geteuid() != pwd->pw_uid) {
100 if (geteuid() == pwd->pw_uid)
102 if (initgroups(pwd->pw_name, pwd->pw_gid) < 0 ||
103 setegid(pwd->pw_gid) < 0 || seteuid(pwd->pw_uid) < 0) {
121 * switches to those of the user specified by its =pwd argumen
65 openpam_borrow_cred(pam_handle_t *pamh, const struct passwd *pwd) argument
[all...]
/netbsd-current/bin/pwd/
H A Dpwd.c1 /* $NetBSD: pwd.c,v 1.23 2021/11/16 16:57:15 kre Exp $ */
40 static char sccsid[] = "@(#)pwd.c 8.3 (Berkeley) 4/1/94";
42 __RCSID("$NetBSD: pwd.c,v 1.23 2021/11/16 16:57:15 kre Exp $");
66 * (Some scripts run /bin/pwd in order to get 'pwd -P'.)
121 char *pwd; local
125 pwd = getenv("PWD");
126 if (pwd == NULL)
128 if (pwd[0] != '/')
130 if (strstr(pwd, "/
[all...]
/netbsd-current/distrib/utils/libhack/
H A Dgetpwent.c66 #include <pwd.h>
98 struct passwd **pwd)
106 *pwd = NULL;
108 *pwd = pwres;
115 struct passwd *pwd; local
117 &pwd) == 0 ? pwd : NULL;
122 struct passwd **pwd)
132 *pwd = NULL;
134 *pwd
97 getpwent_r(struct passwd *pwres, char *buf, size_t bufsiz, struct passwd **pwd) argument
121 getpwnam_r(const char *name, struct passwd *pwres, char *buf, size_t bufsiz, struct passwd **pwd) argument
141 struct passwd *pwd; local
147 getpwuid_r(uid_t uid, struct passwd *pwres, char *buf, size_t bufsiz, struct passwd **pwd) argument
206 pwscan(int search, uid_t uid, const char *name, struct passwd *pwd, char *buf, size_t bufsiz) argument
233 pwmatchline(int search, uid_t uid, const char *name, struct passwd *pwd, char *buf) argument
[all...]
/netbsd-current/usr.bin/su/
H A Dsu.c53 #include <pwd.h>
105 struct passwd *pwd; local
186 if (username == NULL || (pwd = getpwnam(username)) == NULL ||
187 pwd->pw_uid != ruid)
188 pwd = getpwuid(ruid);
189 if (pwd == NULL)
191 username = estrdup(pwd->pw_name);
193 userpass = estrdup(pwd->pw_passwd);
197 if (pwd->pw_shell && *pwd
[all...]
/netbsd-current/lib/libpam/modules/pam_unix/
H A Dpam_unix.c52 #include <pwd.h>
88 struct passwd *pwd, pwres; local
93 pwd = NULL;
96 &pwd); local
102 (void) getpwnam_r(user, &pwres, pwbuf, sizeof(pwbuf), &pwd);
105 if (pwd != NULL) {
107 realpw = pwd->pw_passwd;
118 lc = login_getpwclass(pwd);
148 struct passwd *pwd, pwres; local
161 getpwnam_r(user, &pwres, pwbuf, sizeof(pwbuf), &pwd) !
246 yp_set_password(pam_handle_t *pamh, struct passwd *opwd, struct passwd *pwd, const char *old_pass, const char *domain) argument
356 local_set_password(pam_handle_t *pamh, struct passwd *opwd, struct passwd *pwd) argument
407 struct passwd *pwd, new_pwd, old_pwd; local
[all...]
/netbsd-current/external/gpl3/gcc/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/external/gpl3/binutils/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/external/gpl3/gdb/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/external/gpl3/gdb.old/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/external/gpl3/binutils.old/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/external/gpl3/gcc.old/dist/libiberty/
H A Dgetpwd.c70 static char *pwd; local
73 char *p = pwd;
103 pwd = p;
117 static char *pwd = 0; local
119 if (!pwd)
120 pwd = getcwd (XNEWVEC (char, MAXPATHLEN + 1), MAXPATHLEN + 1
125 return pwd;
/netbsd-current/lib/libpam/modules/pam_chroot/
H A Dpam_chroot.c46 #include <pwd.h>
63 struct passwd *pwd, pwres; local
69 getpwnam_r(user, &pwres, pwbuf, sizeof(pwbuf), &pwd) != 0 ||
70 pwd == NULL)
72 if (pwd->pw_uid == 0 && !openpam_get_option(pamh, "also_root"))
74 if (pwd->pw_dir == NULL)
76 if ((end = strstr(pwd->pw_dir, "/./")) != NULL) {
78 (int)(end - pwd->pw_dir), pwd->pw_dir) > (int)sizeof(buf)) {
/netbsd-current/external/bsd/openldap/dist/servers/slapd/
H A Duser.c32 #include <pwd.h>
56 struct passwd *pwd; local
69 pwd = getpwuid( uid );
75 pwd = getpwnam( user );
77 if ( pwd == NULL ) {
84 user = (pwd != NULL ? pwd->pw_name : NULL);
87 uid = pwd->pw_uid;
90 gid = pwd->pw_gid;
/netbsd-current/external/bsd/openldap/dist/contrib/ldapc++/src/
H A DLDAPRebindAuth.cpp14 LDAPRebindAuth::LDAPRebindAuth(const string& dn, const string& pwd){ argument
17 << " pwd:" << pwd << endl);
19 m_password=pwd;
/netbsd-current/usr.bin/login/
H A Dlogin_pam.c62 #include <pwd.h>
251 if (failures > (pwd ? 0 : 1))
293 pwd = NULL;
294 (void)getpwnam_r(username, &pwres, pwbuf, sizeof(pwbuf), &pwd);
298 * within the next block. pwd can be NULL since it
301 lc = login_getclass(pwd ? pwd->pw_class : NULL);
309 if (pwd) {
310 if (pwd->pw_uid == 0)
313 if (fflag && (uid == 0 || uid == pwd
[all...]

Completed in 206 milliseconds

1234567891011>>