From owner-freebsd-hackers Wed Jan 4 20:43:15 1995 Return-Path: hackers-owner Received: (from root@localhost) by freefall.cdrom.com (8.6.9/8.6.6) id UAA19654 for hackers-outgoing; Wed, 4 Jan 1995 20:43:15 -0800 Received: from alpha.dsu.edu (ghelmer@alpha.dsu.edu [138.247.32.12]) by freefall.cdrom.com (8.6.9/8.6.6) with ESMTP id UAA19648 for ; Wed, 4 Jan 1995 20:43:14 -0800 Received: (from ghelmer@localhost) by alpha.dsu.edu (8.6.9/8.6.9) id WAA24442; Wed, 4 Jan 1995 22:42:48 -0600 Date: Wed, 4 Jan 1995 22:42:48 -0600 (CST) From: Guy Helmer To: freebsd-hackers@freefall.cdrom.com Subject: Suggestions solicited re: dynam. IP addr w/ sliplogin Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: hackers-owner@FreeBSD.org Precedence: bulk I've been hacking on sliplogin to dynamically assign IP addresses; it examines /etc/slip.hosts as before, but if it runs into a "group:" that matches a group the current user belongs to, it uses the given remote-addr as a basis for assiging a dynamic SLIP address. I had the "bright idea" that I could just use the assigned SLIP unit # as an offset added to the base remote-addr and then report the address to the user, but I/O to the tty appears to be impossible after the line has been switched to the SLIP line discipline, so under this method I can't tell the user what his/her IP address is... I have implemented another method where a range of addresses is iteratively assigned (base remote-addr + n, where n is from 0 to whatever), but this method will fail should a particular SLIP line stay active until "n" cycles completely around... Might anyone have any thoughts regarding a tidy method of assigning dynamic IP address in sliplogin? I have reviewed someone else's solution (was it Robert Shady's?), but I would like to have a solution completely implemented within sliplogin and be certain it is immune to races. I could add code to sliplogin to review the current state of the SLIP interfaces, but I had been hoping for something "easier" :-) Thanks, Guy Guy Helmer, Dakota State University Computing Services - ghelmer@alpha.dsu.edu