From peter@pobox.eng.baileynm.com  Tue Oct 20 10:27:52 1998
Received: from mail.baileynm.com (fw.baileynm.com [206.109.159.11])
          by hub.freebsd.org (8.8.8/8.8.8) with SMTP id KAA10375
          for <FreeBSD-gnats-submit@freebsd.org>; Tue, 20 Oct 1998 10:27:51 -0700 (PDT)
          (envelope-from peter@pobox.eng.baileynm.com)
Received: (qmail 22329 invoked from network); 20 Oct 1998 17:27:24 -0000
Received: from pobox.eng.baileynm.com (198.178.0.191)
  by fw.nmti.com with SMTP; 20 Oct 1998 17:27:24 -0000
Received: (from root@localhost)
	by pobox.eng.baileynm.com (8.8.7/8.8.7) id MAA06981;
	Tue, 20 Oct 1998 12:27:24 -0500 (CDT)
	(envelope-from peter)
Message-Id: <199810201727.MAA06981@pobox.eng.baileynm.com>
Date: Tue, 20 Oct 1998 12:27:24 -0500 (CDT)
From: peter@baileynm.com
Reply-To: peter@baileynm.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: Windows DUN sends DOMAINusername, ppp is unhappy.
X-Send-Pr-Version: 3.2

>Number:         8388
>Category:       misc
>Synopsis:       Windows DUN sends DOMAIN\username, ppp is unhappy.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 20 10:30:01 PDT 1998
>Closed-Date:    Tue Mar 9 11:45:23 PST 1999
>Last-Modified:  Tue Mar  9 11:47:33 PST 1999
>Originator:     Peter da Silva
>Release:        FreeBSD 2.2.5-RELEASE i386
>Organization:
Bailey Network Management
>Environment:

	FreeBSD box as dial-in server with ppp and Windows users.

>Description:

	Users forget to take out "DOMAIN" in DUN dialog box when switching
	between NT and BSD dial-in servers. Dialin fails. Users assume it's
	because FreeBSD is a POS and whine about using NT instead. Sysadmin
	fixes problem instead of whining on IRC. Nobody dies.

>How-To-Repeat:

	Dial-in with DOMAIN in DUN dialog box.

>Fix:
	
	If getpwnam fails in pap.c, then call it again with remainder of
	username (pap.c, about line 125) :

     result = (pwd = getpwnam(name)) &&
              !strcmp(crypt(key, pwd->pw_passwd), pwd->pw_passwd);
+    if(!result) {
+        if(!pwd) { /* disgusting hack to avoid complaints about domain auth */
+                char *s;
+                if(s=strchr(name, '\\')) {
+                    result = (pwd = getpwnam(s+1)) &&
+                     !strcmp(crypt(key, pwd->pw_passwd), pwd->pw_passwd);
+                }
+                if(!pwd)
+                        LogPrintf(LogLCP, "No such user?\n");
+        }
+    }
     endpwent();


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: brian 
State-Changed-When: Tue Mar 9 11:45:23 PST 1999 
State-Changed-Why:  
The suggested fix is commented as a ``disgusting hack'', and 
IMHO is.  If people misconfigure their client, they get what they 
deserve I'm afraid. 
>Unformatted:
