Subject: bin/282: sliplogin tells lies to ifconfig and ifconfig believes it!
To: None <gnats-admin>
From: Jonathan O'Brien <obrien@hulk.sfsu.edu>
List: netbsd-bugs
Date: 06/07/1994 15:05:02
>Number:         282
>Category:       bin
>Synopsis:       sliplogin's arglist not bzero'd, ifconfig fails on said args
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    gnats-admin (Utility Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jun  7 15:05:01 1994
>Originator:     Jonathan O'Brien
>Organization:
"	"
>Release:        -current May 30th
>Environment:
	
System: NetBSD hulk.sfsu.edu 0.9B NetBSD 0.9B (HULK) #0: Tue Jun 7 11:31:35 PDT 1994 root@hulk.sfsu.edu:/usr/src/sys/arch/i386/compile/HULK i386


>Description:
	
sliplogin will read in all of its args then pass the list out to slip.login.
Problem is that the last few args aren't nulled out causing probs in ifconfig.
Ex.
For this slip.hosts:
Smedusa	hulk		medusa		0xffff0000	metric 1
This is passed to slip.login:
/sbin/ifconfig sl0 inet hulk medusa netmask 0xffff0000 metric 1 00 01
This is the output of ifconfig sl0:
sl0: flags=d011<UP,POINTOPOINT,LINK0,LINK2,MULTICAST> metric 1
	inet 130.212.3.12 --> 0.0.0.1 netmask 0xffff0000 

In my view this problem is twofold, sliplogin should null all its arg's, and
ifconfig should not allow the bogus args at the end to hose it.

>How-To-Repeat:

Use the slip.hosts and slip.login provided in the source dist.

Set up a login:
Smedusa::207:30::0:0:Slip Login:/tmp:/usr/sbin/sliplogin

login and ifconfig sl0 on another line.

	
>Fix:
	
I fixed it by removing the extra unnecessary arg's in the slip.login. i.e. I
nuked $10 and $11. This is not the proper fix.

>Audit-Trail:
>Unformatted:


------------------------------------------------------------------------------