hi Bill, >> On Thu, 17 Jul 2003 00:33:26 -0700 (PDT), wpaul_at_freebsd.org (Bill >> Paul) said: Bi> Grrrrr. I don't know how I can keep getting this wrong. Ok, this Bi> time I tested the change with a sample program. Try applying Bi> http://www.freebsd.org/~wpaul/getpwent.diff again. Verify that Bi> the result matches the file in the fbsd5 test account. The Bi> getpwuid() routine seems to work ok, though my test for the Bi> geteuid() == 0 case was a bit of a kludge since I don't actually Bi> have root on the test box. Bi> -Bill I feel that the following else-clause is required to store map name such as "passwd.byname" in variable buffer. if (geteuid() == 0) { if (snprintf(buffer, bufsize, "master.passwd.by%s", (how == nss_lt_id) ? "uid" : "name") >= bufsize) return (NS_UNAVAIL); rv = yp_order(domain, buffer, &outname); if (rv == 0) *master = 1; } else { if (snprintf(buffer, bufsize, "passwd.by%s", (how == nss_lt_id) ? "uid" : "name") >= bufsize) return (NS_UNAVAIL); } But I have not tested the code yet. -- --- TOMITA YoshinoriReceived on Wed Jul 16 2003 - 22:58:28 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:15 UTC