Date: Thu, 17 Jul 2003 16:58:27 +0900 From: TOMITA Yoshinori <yoshint@flab.fujitsu.co.jp> To: current@freebsd.org Subject: Re: Help diagnosing NIS breakage ? Message-ID: <ywlwuehvb30.fsf@cerberus.proc.flab.fujitsu.co.jp> In-Reply-To: <20030717073326.7023837B401@hub.freebsd.org> (Bill Paul's message of "Thu, 17 Jul 2003 00:33:26 -0700 (PDT)") References: <EE3D3FBAFFCAED448C21C398FDAD91AC2374B0@EBE1.gc.nat> <20030717073326.7023837B401@hub.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
hi Bill, >> On Thu, 17 Jul 2003 00:33:26 -0700 (PDT), wpaul@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 Yoshinori
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ywlwuehvb30.fsf>