From owner-freebsd-bugs@FreeBSD.ORG Wed May 19 09:20:36 2004 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 96AE716A4CF for ; Wed, 19 May 2004 09:20:36 -0700 (PDT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 78C1143D39 for ; Wed, 19 May 2004 09:20:36 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) i4JGKJiE053718 for ; Wed, 19 May 2004 09:20:19 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.11/8.12.11/Submit) id i4JGKJNQ053717; Wed, 19 May 2004 09:20:19 -0700 (PDT) (envelope-from gnats) Resent-Date: Wed, 19 May 2004 09:20:19 -0700 (PDT) Resent-Message-Id: <200405191620.i4JGKJNQ053717@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Stavros Grigorakakis Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8058316A4CE for ; Wed, 19 May 2004 09:16:10 -0700 (PDT) Received: from www.freebsd.org (www.freebsd.org [216.136.204.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6371343D1F for ; Wed, 19 May 2004 09:16:10 -0700 (PDT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.12.11/8.12.11) with ESMTP id i4JGFhAU071853 for ; Wed, 19 May 2004 09:15:43 -0700 (PDT) (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.12.11/8.12.11/Submit) id i4JGFhWV071852; Wed, 19 May 2004 09:15:43 -0700 (PDT) (envelope-from nobody) Message-Id: <200405191615.i4JGFhWV071852@www.freebsd.org> Date: Wed, 19 May 2004 09:15:43 -0700 (PDT) From: Stavros Grigorakakis To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-2.3 Subject: misc/66893: LINUX NIS clients connecting to FREEBSD NIS servers get authentication failure X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 May 2004 16:20:36 -0000 >Number: 66893 >Category: misc >Synopsis: LINUX NIS clients connecting to FREEBSD NIS servers get authentication failure >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed May 19 09:20:18 PDT 2004 >Closed-Date: >Last-Modified: >Originator: Stavros Grigorakakis >Release: >Organization: DMST AUEB >Environment: FreeBSD aegean.dmst.aueb.gr 4.9-PRERELEASE FreeBSD 4.9-PRERELEASE #0 >Description: There are some problems connnecting a Linux NIS client to a FreeBSD NIS server (Linux is RH9 and freeBSD is 4.9 RELEASE but i believe it concerns all versions) Having both sides setup , users always get an authentication failure on the linux boxes. Same problem is described in http://lists.freebsd.org/pipermail/freebsd-net/2003-August/001126.html There it is suggested that the only problem is a missing NIS map ( named master.passwd in freeBSD) shadow.byname. However patching as suggested the /var/yp/Makefile doesnot solve the problem although it sure is necssary to make the shadow map. >How-To-Repeat: Just try to set out of the box a linux NIS client to authenticate against a Freebsd NIS server >Fix: Linux authentication routine is distrubbed by the presence of asterisk in tha passwd tables and maps an really foolishly expects an "x" I have made small modification in line 470 of /var/yp/Makefile changing from print $$1":*:"$$3":"$$4":"$$8":"$$9":"$$10}' $^ \ to print $$1":x"$$3":"$$4":"$$8":"$$9":"$$10}' $^ \ FreeBSD NIS clients seem not have spotted the difference. However having searched for possible implications i must point out that the asterisk is used in the /usr/src/usr.sbin/rpc.yppasswdd/yppasswdd_server.c (read comments line 348 ) so i suggest changing line 416 pw->pw_name, *(ptr+1) == '*' ? "*" : pw->pw_passwd, to pw->pw_name, *(ptr+1) == ('*'||'x') ? "x" : pw->pw_passwd, (I am not so sure what would be the implications if we dont... ) Results: Linux client users can cleanly authenticate now I have no indication of any implication in FBSD NIS clients but it sure is necessary for someone to look more thoroughly ATTENTION : More work to be done: A user on a linux client still cant change his password using yppasswd , so .. they still have to visit a freebsd box and use yppasswd there :-) Conclusion: It would be appreciable if someone (on either side) made NIS work fine out of the box >Release-Note: >Audit-Trail: >Unformatted: