From owner-freebsd-chat Mon Jan 1 01:14:43 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id BAA14143 for chat-outgoing; Mon, 1 Jan 1996 01:14:43 -0800 (PST) Received: from jhome.DIALix.COM (root@jhome.DIALix.COM [192.203.228.69]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id BAA14136 for ; Mon, 1 Jan 1996 01:14:36 -0800 (PST) Received: (from peter@localhost) by jhome.DIALix.COM (8.7.3/8.7.3) id RAA05354; Mon, 1 Jan 1996 17:14:32 +0800 (WST) Date: Mon, 1 Jan 1996 17:14:32 +0800 (WST) From: Peter Wemm To: chat@freebsd.org Subject: C'mon you slackers! :-) Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-chat@freebsd.org Precedence: bulk I just noticed that I got the first commit for 1996 (freefall time) onto freefall at 12:27am.. Does the 7 commits that I did mean I've done 100% of the work so far this year? (freefall time) :-) :-) :-) :-) :-) Happy new year! (seems a bit odd saying this at 5pm Jan 1, Perth time :-) Cheers, -Peter (hides from the bites ;-) From owner-freebsd-chat Mon Jan 1 09:09:40 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id JAA27671 for chat-outgoing; Mon, 1 Jan 1996 09:09:40 -0800 (PST) Received: from time.cdrom.com (time.cdrom.com [192.216.222.226]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id JAA27666 for ; Mon, 1 Jan 1996 09:09:37 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by time.cdrom.com (8.6.12/8.6.9) with SMTP id JAA04556; Mon, 1 Jan 1996 09:09:09 -0800 To: Peter Wemm cc: chat@freebsd.org Subject: Re: C'mon you slackers! :-) In-reply-to: Your message of "Mon, 01 Jan 1996 17:14:32 +0800." Date: Mon, 01 Jan 1996 09:09:09 -0800 Message-ID: <4553.820516149@time.cdrom.com> From: "Jordan K. Hubbard" Sender: owner-chat@freebsd.org Precedence: bulk > I just noticed that I got the first commit for 1996 (freefall time) onto > freefall at 12:27am.. Yeah, but did you notice that I got the last one in for '95? That's gotta count for something! I'm depressed that nobody even noticed. :-) :-) Jordan From owner-freebsd-chat Wed Jan 3 15:10:37 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id PAA28597 for chat-outgoing; Wed, 3 Jan 1996 15:10:37 -0800 (PST) Received: from fslg8.fsl.noaa.gov (fslg8.fsl.noaa.gov [137.75.131.171]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id PAA28570 for ; Wed, 3 Jan 1996 15:10:27 -0800 (PST) Received: by fslg8.fsl.noaa.gov (5.57/Ultrix3.0-C) id AA23437; Wed, 3 Jan 96 17:10:23 -0600 Received: by emu.fsl.noaa.gov (1.38.193.4/SMI-4.1 (1.38.193.4)) id AA18260; Wed, 3 Jan 1996 16:10:22 -0700 Date: Wed, 3 Jan 1996 16:10:22 -0700 From: kelly@fsl.noaa.gov (Sean Kelly) Message-Id: <9601032310.AA18260@emu.fsl.noaa.gov> To: lyndon@orthanc.com Cc: chat@freebsd.org In-Reply-To: <199601032118.NAA03268@multivac.orthanc.com> (lyndon@orthanc.com) Subject: Re: Wasteful e-mail messages Sender: owner-chat@freebsd.org Precedence: bulk >>>>> "Lyndon" == VE7TCP writes: Lyndon> Also, when replying to messages it is NOT mandatory to CC Lyndon> the mailing list. We could easily cut the volume of Lyndon> traffic on the FreeBSD mailing lists in half if people Lyndon> stopped automatically CCing replies to the list. Let's Lyndon> use a bit of common sense. Please? Although in -questions, some users may appreciate seeing answers to questions that they didn't post. -- Sean Kelly NOAA Forecast Systems Laboratory, Boulder Colorado USA Too bad you can't just grab a tree by the very tiptop and bend it clear over the ground and then let her fly, because I bet you'd be amazed at all the stuff that comes flying out. -- Jack Handey From owner-freebsd-chat Wed Jan 3 16:07:35 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id QAA11502 for chat-outgoing; Wed, 3 Jan 1996 16:07:35 -0800 (PST) Received: from Aspen.Woc.Atinc.COM (aspen.woc.atinc.com [198.138.38.205]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id QAA11476 for ; Wed, 3 Jan 1996 16:07:27 -0800 (PST) Received: (from jmb@localhost) by Aspen.Woc.Atinc.COM (8.6.12/8.6.9) id TAA06280; Wed, 3 Jan 1996 19:06:37 -0500 Date: Wed, 3 Jan 1996 19:06:36 -0500 (EST) From: "Jonathan M. Bresler" X-Sender: jmb@Aspen.Woc.Atinc.COM To: Peter Berger cc: chat@FreeBSD.ORG Subject: Re: COMPAT_43 ... what breaks? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-chat@FreeBSD.ORG Precedence: bulk On Wed, 3 Jan 1996, Peter Berger wrote: > So just what -will- break if you compile a kernel without COMPAT_43? > Inquiring minds want to know. chucky's heart ? Jonathan M. Bresler FreeBSD Postmaster jmb@FreeBSD.ORG play go. ride bike. hack FreeBSD.--ah the good life i am moving to a new job. PLEASE USE: jmb@FreeBSD.ORG From owner-freebsd-chat Wed Jan 3 17:11:56 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id RAA22550 for chat-outgoing; Wed, 3 Jan 1996 17:11:56 -0800 (PST) Received: from toadflax.cs.ucdavis.edu (toadflax.cs.ucdavis.edu [128.120.56.188]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id RAA22543 for ; Wed, 3 Jan 1996 17:11:51 -0800 (PST) Received: by toadflax.cs.ucdavis.edu (4.1/UCD.CS.2.6) id AA04990; Wed, 3 Jan 96 17:11:48 PST From: obrien@cs.ucdavis.edu (David E. O'Brien) Message-Id: <9601040111.AA04990@toadflax.cs.ucdavis.edu> Subject: Re: Wasteful e-mail messages To: FreeBSD-chat@FreeBSD.org (FreeBSD misc chating list) Date: Wed, 3 Jan 1996 17:11:46 -0800 (PST) In-Reply-To: <9601032310.AA18260@emu.fsl.noaa.gov> from "Sean Kelly" at Jan 3, 96 04:10:22 pm X-Mailer: ELM [version 2.4 PL24 ME8b] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-chat@FreeBSD.org Precedence: bulk > Lyndon> Also, when replying to messages it is NOT mandatory to CC > Lyndon> the mailing list. We could easily cut the volume of > Lyndon> traffic on the FreeBSD mailing lists in half if people > Lyndon> stopped automatically CCing replies to the list. Let's > Lyndon> use a bit of common sense. Please? Or the other way around. P-l-e-a-s-e take me off the CC: list of the X-windows install thread. I promiss I will read the messages from the freebsd-hackers list. 95% of my mail for the past three days has been from this. (not that is really *that* bad to popular I guess :-)) Happy BSD New Year! -- David (obrien@cs.ucdavis.edu) P.S. Wonder how many FBSD pentiums Santa carried this year? From owner-freebsd-chat Thu Jan 4 01:52:40 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id BAA26196 for chat-outgoing; Thu, 4 Jan 1996 01:52:40 -0800 (PST) Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id BAA26169 Thu, 4 Jan 1996 01:52:08 -0800 (PST) Received: from sax.sax.de by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id KAA23086; Thu, 4 Jan 1996 10:51:35 +0100 Received: by sax.sax.de (8.6.11/8.6.12-s1) with UUCP id KAA21131; Thu, 4 Jan 1996 10:51:26 +0100 Received: (from j@localhost) by uriah.heep.sax.de (8.7.3/8.6.9) id KAA10648; Thu, 4 Jan 1996 10:30:58 +0100 (MET) From: J Wunsch Message-Id: <199601040930.KAA10648@uriah.heep.sax.de> Subject: Re: COMPAT_43 ... what breaks? To: jmb@freebsd.org (Jonathan M. Bresler) Date: Thu, 4 Jan 1996 10:30:57 +0100 (MET) Cc: peterb@telerama.lm.com, chat@freebsd.org Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: from "Jonathan M. Bresler" at Jan 3, 96 07:06:36 pm X-Phone: +49-351-2012 669 X-Mailer: ELM [version 2.4 PL23] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-chat@freebsd.org Precedence: bulk As Jonathan M. Bresler wrote: > > On Wed, 3 Jan 1996, Peter Berger wrote: > > > So just what -will- break if you compile a kernel without COMPAT_43? > > Inquiring minds want to know. > > chucky's heart ? Most things will work fine. Only minor things like getty will fail, since they still use sgtty-style terminal controls. :-] (Unfortunately, it's a bit hard to log into the system without a working getty. :-) -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-) From owner-freebsd-chat Thu Jan 4 02:07:31 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id CAA26925 for chat-outgoing; Thu, 4 Jan 1996 02:07:31 -0800 (PST) Received: from toadflax.cs.ucdavis.edu (toadflax.cs.ucdavis.edu [128.120.56.188]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id CAA26918 for ; Thu, 4 Jan 1996 02:07:27 -0800 (PST) Received: by toadflax.cs.ucdavis.edu (4.1/UCD.CS.2.6) id AA14143; Thu, 4 Jan 96 02:07:21 PST From: obrien@cs.ucdavis.edu (David E. O'Brien) Message-Id: <9601041007.AA14143@toadflax.cs.ucdavis.edu> Subject: Re: HIGWAY ROBBERY!! To: FreeBSD-chat@FreeBSD.org (FreeBSD misc chating list) Date: Thu, 4 Jan 1996 02:07:19 -0800 (PST) X-Mailer: ELM [version 2.4 PL24 ME8b] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-chat@FreeBSD.org Precedence: bulk > >DEAR SIRS AND FELLOWS, > >I HAVE BEEN UNDUELY ROBBED BY YOUR INCOMPETENT PRODUCT. DURING INSTALL IT >DELETED ALL MY DOS GAMES AND PROGRAMS I SPENT YEARS GETTING FROM FTP AND >FSP SITES!! > >HOW DARE THIS TREACHERY BE UNLEASHED ON MY HARD DRIVE! WHO WILL PAY ME FOR >THESE LOSSES...WHO WILL HELP ME TO REGAIN MY PRECIOUS PROGRAMS?? > >THIS WILL NOT GO UNCHALLENGED...I SHALL SEEK PUBLIC AGENCIES TO COMBAT >YOUR FAULTY PRODUCT THAT INTENTIONALLY DESTROYS HARD DRIVES. > .... > >oh, and do please, all of you...have a happy new year. :) > >SpUnk3Y Am I the only one that took this as a joke (mostly because of the "happy new year :) line)? -- David (obrien@cs.ucdavis.edu) From owner-freebsd-chat Thu Jan 4 08:29:19 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id IAA14518 for chat-outgoing; Thu, 4 Jan 1996 08:29:19 -0800 (PST) Received: from ncd.com (firewall-user@welch.ncd.com [192.43.160.250]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id IAA14511 for ; Thu, 4 Jan 1996 08:29:12 -0800 (PST) Received: by ncd.com; id IAA23167; Thu, 4 Jan 1996 08:56:58 -0800 Received: from z-code.z-code.com(192.82.56.21) by welch.ncd.com via smap (g3.0.1) id xmaa23160; Thu, 4 Jan 96 08:56:43 -0800 Received: from zolaris.z-code.com (zolaris.z-code.com [192.82.56.41]) by z-code.z-code.com (8.6.9/8.6.9) with SMTP id IAA13821 for ; Thu, 4 Jan 1996 08:27:02 -0800 Received: by zolaris.z-code.com (5.x/SMI-SVR4) id AA00055; Thu, 4 Jan 1996 08:24:51 -0800 From: "Ulf Zimmermann" Message-Id: <9601040824.ZM53@zolaris.z-code.com> Date: Thu, 4 Jan 1996 08:24:50 -0800 X-Mailer: Z-Mail (3.2.0 06sep94) To: chat@freebsd.org Subject: How about a Modem or ISDN dial up ? Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-chat@freebsd.org Precedence: bulk Hi. After I called so many ISP's in the bay area and no one is offering me the service I would like to get, I am planning to get a T1 for home. As this would be a little bit more expensive, I got the following idea: I have 2 IP class C networks. So if you are in local call reach to Alameda (510-865 or 510-521) I would offer 24h dedicated dial-up. The costs would not be under the cost of normal ISP's, but we should be able to get our service better running ;-) Everyone can get a 3 or 4 bit subnet, even more is possible. DNS, News and so on will also be running at my home site. So how about that idea ? Write :) or send suggestions. Ulf. -- Ulf Zimmermann, NCD Software, 101 Rowland Way, Suite 300, Novato, CA 94945 phone: 415-899-7941, email: ulf@z-code.ncd.com, phone-home: 510-865-0204 ====================================== FreeBSD 2.1.0 is available now! -------------------------------------- FreeBSD: Turning PCs into Workstations ====================================== From owner-freebsd-chat Fri Jan 5 18:56:17 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id SAA19248 for chat-outgoing; Fri, 5 Jan 1996 18:56:17 -0800 (PST) Received: from bambi.pomona.edu (bambi.pomona.edu [134.173.64.3]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id SAA19237 for ; Fri, 5 Jan 1996 18:56:13 -0800 (PST) Received: from POMONA.EDU by POMONA.EDU (PMDF V5.0-4 #12356) id <01HZNTWGSQF48WX29B@POMONA.EDU> for chat@freebsd.org; Fri, 05 Jan 1996 18:56:10 -0800 (PST) Date: Fri, 05 Jan 1996 18:56:10 -0800 (PST) From: JOHN Subject: BASH shell script question.. To: chat@freebsd.org Message-id: <01HZNTWGSU6Q8WX29B@POMONA.EDU> X-VMS-To: IN%"chat@freebsd.org" MIME-version: 1.0 Content-type: TEXT/PLAIN; CHARSET=US-ASCII Content-transfer-encoding: 7BIT Sender: owner-chat@freebsd.org Precedence: bulk If I want a command to exit a shell script, and then exit the login shell (logging out the user), how would I pass the command to the login shell? Or, even better, is it possible to make a shell script the login shell, so that once the script exits, the user is logged off? Thanks John From owner-freebsd-chat Fri Jan 5 21:55:45 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id VAA26783 for chat-outgoing; Fri, 5 Jan 1996 21:55:45 -0800 (PST) Received: from fslg8.fsl.noaa.gov (fslg8.fsl.noaa.gov [137.75.131.171]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id VAA26778 for ; Fri, 5 Jan 1996 21:55:42 -0800 (PST) Received: by fslg8.fsl.noaa.gov (5.57/Ultrix3.0-C) id AA13730; Fri, 5 Jan 96 23:55:42 -0600 Received: by emu.fsl.noaa.gov (1.38.193.4/SMI-4.1 (1.38.193.4)) id AA08315; Fri, 5 Jan 1996 22:55:41 -0700 Date: Fri, 5 Jan 1996 22:55:41 -0700 From: kelly@fsl.noaa.gov (Sean Kelly) Message-Id: <9601060555.AA08315@emu.fsl.noaa.gov> To: JSINNOTT@pomona.edu Cc: chat@freebsd.org In-Reply-To: <01HZNTWGSU6Q8WX29B@POMONA.EDU> (message from JOHN on Fri, 05 Jan 1996 18:56:10 -0800 (PST)) Subject: Re: BASH shell script question.. Sender: owner-chat@freebsd.org Precedence: bulk >>>>> "JOHN" == JOHN writes: JOHN> If I want a command to exit a shell script, and then exit JOHN> the login shell (logging out the user), how would I pass the JOHN> command to the login shell? The script could send kill -HUP to the login shell. JOHN> Or, even better, is it possible to make a shell script the JOHN> login shell, so that once the script exits, the user is JOHN> logged off? Yes. Just make the script the login shell in the password file for the user in question. As root, use vipw or chpass -s to change the login shell to the full pathname of the script. Make sure the script is executable. That's it. Also, if you DON'T list the script pathname as a valid shell in /etc/shells, the user won't be able to change his login shell to anything else. If you do list the script pathane in /etc/shells, then the user can change his login shell to anything else listed in /etc/shells. -- Sean Kelly NOAA Forecast Systems Laboratory, Boulder Colorado USA I saw a bank that said "24 Hour Banking", but I don't have that much time. -- Steven Wright From owner-freebsd-chat Sat Jan 6 05:53:13 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id FAA22367 for chat-outgoing; Sat, 6 Jan 1996 05:53:13 -0800 (PST) Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id FAA22341 for ; Sat, 6 Jan 1996 05:53:08 -0800 (PST) Received: from sax.sax.de by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id OAA09155; Sat, 6 Jan 1996 14:52:05 +0100 Received: by sax.sax.de (8.6.11/8.6.12-s1) with UUCP id OAA14259; Sat, 6 Jan 1996 14:52:04 +0100 Received: (from j@localhost) by uriah.heep.sax.de (8.7.3/8.6.9) id OAA13251; Sat, 6 Jan 1996 14:14:28 +0100 (MET) From: J Wunsch Message-Id: <199601061314.OAA13251@uriah.heep.sax.de> Subject: Re: BASH shell script question.. To: freebsd-chat@freebsd.org Date: Sat, 6 Jan 1996 14:14:28 +0100 (MET) Cc: JSINNOTT@pomona.edu Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: <9601060555.AA08315@emu.fsl.noaa.gov> from "Sean Kelly" at Jan 5, 96 10:55:41 pm X-Phone: +49-351-2012 669 X-Mailer: ELM [version 2.4 PL23] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-chat@freebsd.org Precedence: bulk As Sean Kelly wrote: > > Yes. Just make the script the login shell in the password file for > the user in question. As root, use vipw or chpass -s to change the > login shell to the full pathname of the script. Make sure the script ^^^^^^^^^^^^^^^^^^^^ > is executable. That's it. ^^^^^^^^^^^^^^ This translates into ``the script must be an "interpreted executable"''. I.e., you have to use #!/usr/local/bin/bash as the first line of your script, in addition to setting the appropriate x-permissions. Without this, execve(2) won't accept the script as an executable program. (For a normal shell environment, this is the point where your login shell jumps in and feeds the script into some sort of a shell. This doesn't work for a login program however.) -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-) From owner-freebsd-chat Sat Jan 6 06:22:02 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id GAA24746 for chat-outgoing; Sat, 6 Jan 1996 06:22:02 -0800 (PST) Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id GAA24711 for ; Sat, 6 Jan 1996 06:21:54 -0800 (PST) Received: from sax.sax.de by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id PAA09662; Sat, 6 Jan 1996 15:21:39 +0100 Received: by sax.sax.de (8.6.11/8.6.12-s1) with UUCP id PAA14458; Sat, 6 Jan 1996 15:21:33 +0100 Received: (from j@localhost) by uriah.heep.sax.de (8.7.3/8.6.9) id PAA14342; Sat, 6 Jan 1996 15:18:01 +0100 (MET) From: J Wunsch Message-Id: <199601061418.PAA14342@uriah.heep.sax.de> Subject: Re: Whacking the troll repliers. To: imp@village.org (Warner Losh) Date: Sat, 6 Jan 1996 15:18:00 +0100 (MET) Cc: terry@lambert.org, witr@rwwa.com, freebsd-chat@freebsd.org Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: <199601050542.WAA01138@rover.village.org> from "Warner Losh" at Jan 4, 96 10:42:00 pm X-Phone: +49-351-2012 669 X-Mailer: ELM [version 2.4 PL23] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-chat@freebsd.org Precedence: bulk As Warner Losh wrote: > [JMJr.] > It has been too long with a good faring. Much too long :-) Actually, it's been a fairing. :) -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-) From owner-freebsd-chat Sat Jan 6 13:28:04 1996 Return-Path: owner-chat Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id NAA18995 for chat-outgoing; Sat, 6 Jan 1996 13:28:04 -0800 (PST) Received: from bambi.pomona.edu (bambi.pomona.edu [134.173.64.3]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id NAA18972 for ; Sat, 6 Jan 1996 13:28:00 -0800 (PST) Received: from POMONA.EDU by POMONA.EDU (PMDF V5.0-4 #12356) id <01HZOWRLHYV48WX3K4@POMONA.EDU> for freebsd-chat@freebsd.org; Sat, 06 Jan 1996 13:27:57 -0800 (PST) Date: Sat, 06 Jan 1996 13:27:57 -0800 (PST) From: JOHN Subject: Request for comments on shell script! To: freebsd-chat@freebsd.org Message-id: <01HZOWRLI2MQ8WX3K4@POMONA.EDU> X-VMS-To: IN%"freebsd-chat@freebsd.org" X-VMS-Cc: JSINNOTT MIME-version: 1.0 Content-type: TEXT/PLAIN; CHARSET=US-ASCII Content-transfer-encoding: 7BIT Sender: owner-chat@freebsd.org Precedence: bulk I hope this isn't an inappropriate forum for this.. Basically, I wrote a bash shell script to provide menu functions to users unfamiliar with Unix. I am going to run this script in the place of a true command shell. But I do provide for the user to start a shell if he or she wants to. This is nothing fancy, and I am SURE there are more elegant ways to do this, but except for a few things, this works so far for me. I did look into the mshell by the way. Anyway - my problem is, I wrote this in such a way that I believe every time a user goes to a sub menu (mail.menu for instance) and then returns to the main.menu, a new process is spawned. I think this because if I run the script as a shell, and go to different menus, and then use the [B]ye! command to logout, it returns back to the main menu AS MANY TIMES AS I HAVE GONE TO A SUB MENU AND BACK. After that number of times, it finally logs out. So, if anyone has any suggestions as to how I can solve this problem, I would appreciate it. Also, any comments on possible security problems, as well as any pointers to programming would also be welcome. I am VERY new to programming and even newer to FreeBSD, so please be patient with it. :) Thanks a lot! John PS - the main.menu, which is where the user is first placed, is the last function defined, with the sub menus defined before it. Script follows: #!/usr/local/bin/bash PATH=$HOME/bin:/bin:/usr/bin:/usr/local/bin export PATH EDITOR=vi export EDITOR PAGER=less export PAGER umask 2 function mail.menu { clear echo " `date`" echo "" echo " Mail Menu " echo " ^^^^^^^^^ " echo "" echo "" echo " [P]ine Easy to use pine mail client. " echo " [E]lm Simple but powerful mail client." echo " [M]ail Quick mail on command line. " echo "" echo "" echo "" echo "" echo "" echo " [R]eturn Return to the Main Menu. " echo "" echo "" echo "" echo "" echo "" echo "" echo -n "Command> "; read command case $command in P|p) clear pine mail.menu;; E|e) clear elm mail.menu;; M|m) clear echo "Who would you like to mail?"; read target mail $target mail.menu;; R|r) main.menu;; *) echo "Sorry, that is not an acceptable command. Please try again." sleep 1 mail.menu;; esac } function telnet.menu { clear echo "Please enter the hostname of the site to which you would like to connect." echo "Enter in the format \"name.subdomain.domain\" - i.e. anubis.pomona.edu" echo "" echo -n "Hostname> " read telnet case `ping -c1 $telnet > /dev/null` in 0) echo "" echo "That host can not be reached at this time. Check to see that" echo "you entered the name correctly. If you have, either try " echo "specifying the IP address of the host, or try again later." main.menu;; *) clear; telnet $telnet;; esac } function ftp.menu { clear echo "Please enter the hostname of the site to which you would like to connect." echo "Enter in the format \"name.subdomain.domain\" - i.e. anubis.pomona.edu" echo "" echo -n "Hostname> " read ftp case `ping -c1 $ftp > /dev/null` in 0) echo "" echo "That host can not be reached at this time. Check to see that" echo "you entered the name correctly. If you have, either try " echo "specifying the IP address of the host, or try again later." main.menu;; *) clear echo "Attempting to connect, program will redial if host is busy" echo "so be patient!" echo ""; ncftp -r $ftp;; esac } function phone.menu { clear echo "Please enter the name of the user to which you would like to talk." echo "If they are on this host, then you may just enter their username, " echo "otherwise enter their full e-mail address." echo "" echo "Enter in the format \"name@subdomain.domain\" - i.e. john@pomona.edu" echo "" echo -n "Username> " read username clear echo "Attempting to connect with the user, wait..." echo ""; ytalk $username main.menu } function shell.menu { clear echo " `date`" echo "" echo " Shell Menu " echo " ^^^^^^^^^^ " echo "" echo "" echo " [B]ash GNU Bourne Again SHell. " echo " [C]sh The C shell, developed at Berkeley." echo "" echo "" echo "" echo "" echo "" echo "" echo " [R]eturn Return to the Main Menu. " echo "" echo "" echo "" echo "" echo "" echo "" echo -n "Command> "; read command case $command in B|b) clear bash shell.menu;; C|c) clear csh shell.menu;; R|r) main.menu;; *) echo "Sorry, that is not an acceptable command. Please try again." sleep 1 shell.menu;; esac } function finger.menu { clear echo "Who would you like to check up on? Please enter the full e-mail" echo "address of the user, if they are on a remote host." echo "" echo "" echo -n "User> " read user clear finger $user sleep 4 info.menu } function whois.menu { clear echo "Please enter the key words you think might identify the host you" echo "are looking up. For instance, to look up DNS names for UCLA," echo "you might enter University California Los Angeles - simple!" echo "" echo "The information that the Whois search returns will be fed into" echo "the viewing utility, \"less\". If the output is short, you won't" echo "really need it, but if it is long, it might be helpful. To move" echo "down a line in \"less\", type RETURN and type SPACE to go down" echo "a page at a time. To move back one page, type \"b\"." echo "" echo "" echo -n "Please enter your key words> " read whois clear whois $whois | less info.menu } function info.menu { clear echo " `date`" echo "" echo " Info Menu " echo " ^^^^^^^^^ " echo "" echo "" echo " [F]inger Check up on another user. " echo " [W]hois Look up information on other hosts." echo " [A]rchie Not implemented at this time. " echo "" echo " (More items to be added later.)" echo "" echo "" echo "" echo "" echo " [R]eturn Return to the Main Menu. " echo "" echo "" echo "" echo "" echo "" echo "" echo -n "Command> "; read command case $command in F|f) finger.menu;; W|w) whois.menu;; A|a) clear echo "Unimplemented at this time - check back later!" sleep 1 info.menu;; R|r) main.menu;; *) echo "Sorry, that is not an acceptable command. Please try again." sleep 1 info.menu;; esac } function main.menu { clear echo " Welcome to `hostname -s`, $LOGNAME! " echo " `date` " echo "" echo " ANUBIS MAIN MENU " echo "" echo " [M]ail Send, receive, and reply to e-mail." echo " [N]ews Post, read, and reply to Usenet News." echo " [W]eb Use the text mode WWW browser, Lynx." echo " [T]elnet Telnet to another host." echo " [F]TP Transfer files to and from another host." echo " [P]hone Talk to a user on this or another host." echo " [S]hell Run the Bash or Csh Unix Shell programs." echo "" echo " [I]nfo Finger, Whois, Archie, etc." echo " [C]omments Send mail to the system operator." echo " [L]ook Look to see who is on this system." echo "" echo " [B]ye! Logout out of this system." echo "" echo "" echo "" echo -n "Command> "; read command case $command in M|m) mail.menu main.menu;; N|n) clear rtin main.menu;; W|w) clear lynx main.menu;; T|t) telnet.menu main.menu;; F|f) ftp.menu main.menu;; P|p) phone.menu main.menu;; S|s) shell.menu main.menu;; I|i) info.menu main.menu;; C|c) clear echo "Enter your subject, type what you want, and then type a period and enter on an empty line to send the message. I'll get back to you as soon as possible." echo "Thanks." echo "" mail root main.menu;; L|l) clear who sleep 3 main.menu;; B|b) clear echo "Thanks for visiting `hostname -s`, $LOGNAME! Stop by again soon." sleep 3 kill -HUP;; *) clear echo "That is not a valid command. Please try again." sleep 1 main.menu;; esac } main.menu