Sun-Spots-Request@RICE.EDU (Vicky Riffle) (01/06/87)
SUN-SPOTS DIGEST Tuesday, 6 Jan 1987 Volume 5 : Issue 1 Today's Topics: Sun User Group wants submissions for the next Software Tape Re: Color windows running under Suntools Re: formatting disks from Sun... Fix to problem of getting RCS to work on Sun 3.0 NFS Change to merge filesystems (long) patches for subnets, single-user boot security (very long) Other Ethercards on the SUN Excelan board on a Sun-3 Re: Pixar computer on the Sun workstation Is NeWS good news? 1/2 inch 1600/6250 bpi tape drives for Sun-3's? Laserwriter & Sun interactions? scrolling canvases? Appropriate place to exchange icons and rasterfiles? Including SUN screendumps in itroff files. Is it possible? Improper cleanup when exiting Suntools? Sun 3.0 /bin/login doesn't set tty ownership? Frame Buffers/VMEbus to UNIBUS conversion woes...? CDC 9771 drives on Sun-2/170 or Sun-3/180? Protocol implementation in Sun open architecture? SunView & SunLisp? mail on diskless workstations? ld -A under rel 3.2? sun fortran recursion? MX mods for 3.2 sendmail? Sun 4.2bsd adb annoyances? ------------------------------------------------------------------------ Date: Wed, 10 Dec 86 01:46:57 PST From: hoptoad!gnu@lll-crg.ARPA (John Gilmore) Subject: Sun User Group wants submissions for the next Software Tape The Sun User Group is an independent users' group for people who own or use Sun Workstations. We're the people who put on the Sun conferences every year (with a lot of help from Sun). We also work to collect and distribute non-proprietary software for Suns. We are collecting and collating software for the next tape. In the past, all the software has been public domain or freely redistributable. This will continue; in addition, we will also be creating two tapes for AT&T licensed software (e.g. enhanced Unix programs). Sun users with binary licenses will be able to get binary copies of the licensed software; ATT+UCB source licensees can get a source tape. Anybody will be able to get the unlicensed tape. Due to the proliferation of lawyers we will have to send you a release form (electronically or by paper mail) which you can print out, sign, and send in to us. I am actively working to get the legalese out of this form and make it simple and straightforward. You can send in the software first and we will send back the form before we distribute it. You must own the software, or certify that it is public domain, or it must be freely redistributable under copyright. In general, we want pieces of software that are not available from other public sources and/or are specific to Sun Workstations. For example, we won't be distributing GNU Emacs or Tex, though we might distribute Sun-specific mods to them that aren't part of the generic release. On the other hand, we have public domain versions of curses and University Ingres which have not seen wide distribution; we plan to put these on the tape, even though they are not specific to Suns. Comments on our tape policies are welcome, especially if accompanied by software! I'd like to make a special request to Sun employees to make available some of the toys and tools that have been floating around but never got released. Phil Heller has graciously agreed, with the full support of his management, to send us the collection of demo software that has dazzled all of us in the Sun vendor exhibits. Mike Shantz wants to release an excellent 24-bit to 8-bit color dithering program that's been around since about 1982 -- his management is still thinking about it. If you have some tool that never made it onto a Sun release (perhaps for fear that you would have to support it!), now is your chance to get it into customers' hands and out of your ~/bin or /usr/local directory. Submissions should consist of a directory containing the software, Makefile (if needed), documentation, and a README file with a summary of what it is, where it came from, who owns it, and what (if any) restrictions there are on its use. We can receive them by email (shar scripts), direct uucp transfer, or on tar tapes (1600, 6250, or QIC-11 or QIC-24 1/4'' cartridges). David Hartwell put together the previous S.U.G. tape and is also working on the upcoming ones. He is covered by an AT&T source license, so you must send licensed sources to him: David Hartwell phone +1 415 422 4457 hartwell@lll-lcc.arpa {ihnp4,sun,rutgers,seismo,caip}!lll-crg!lll-lcc!hartwell You can send unlicensed software to him or to any of us on the tape committee: Rich Morin {hoptoad,lll-lcc}!cfcl!rdm +1 415 994 6860 or John Gilmore {ihnp4,sun,lll-crg,ptsfa}!hoptoad!gnu +1 415 931 4667 Thanks everybody -- John Gilmore Member, Sun User Group board of directors PS: For generic questions about the Sun User Group, like "how do I get the existing tape" or "how do I join", please send mail to sun!users or users@sun.com . ------------------------------ Date: Wed, 3 Dec 86 21:23:34 PST From: dcmartin@ingres.berkeley.edu (David C. Martin) Subject: Re: Color windows running under Suntools You didn't specify whether you wrote this program or someone else did, so I don't know if it your programming ability or something else. As for the programming end, you want to use pw_setcmsname() and pw_putcolormap() to set the colormap for a particular pixwin of a window. You should see the Sunview programmers guide or the Sunwindows reference manual for information on this aspect of Suntools programming. As for the use of -Wb, -Wf and -Wg (check suntools(1) for an explanation), these are only used to modify the first and last entries in the colormap and probably should not be used w/ a program needing all 256 colors. The changes you see in the color of the window when you enter and exit happen due to the fact that that window is requesting the entire colormap. Wheneever you have programs which must vie for access to the colormap, whether in whole or in part, the windows will flash into the appropriate color when you enter the window. Try running the rainbow(1) demo program (it may be called colortool now, but it was rainbow when I wrote it). You can probably get the source from Sun. Hope this helps. dcm ----- David C. Martin ----- arpa: dcmartin@ingres.Berkeley.EDU uucp: {ihnp4,decvax}!ucbvax!dcmartin at&t: 415/642-9585 (O) ------------------------------ Date: Thu, 4 Dec 86 10:09:53 PST From: dcmartin@ingres.berkeley.edu (David C. Martin) Subject: Re: formatting disks from Sun... Greg Tarsa writes in mod.computers.sun: > Warning: Do not FORMAT any SMD disk that you purchased from SUN > you will lose valuable information that you cannot replace. > >By that time it had been chugging away for more than an hour, but I still >hit ^C. > >Can anyone tell me what I lost? ... Yes, you probably lost the bad block information. The std. way to format the disk is to read the information on bad blocks from the disk (via 'r' under format, check it w/ 'p') and then format and rewrite the bad blocks. You can probably fix this by checking the disks w/ a continuous (30hr) read/write test on the disk. This action would probably be a good idea anyway since it sounds like you have some problems w/ the initial bad block list. For more information, check "Installing Unix on the Sun Workstation". dcm ----- David C. Martin ----- Computer Science Division University of California Berkeley, CA 94720 ----- arpa: dcmartin@ingres.Berkeley.EDU uucp: {ihnp4,decvax}!ucbvax!dcmartin at&t: 415/642-9585 (O) ------------------------------ Date: Fri, 5 Dec 86 11:05:05 EST From: wpm@mitre-gateway.arpa (William P. Malloy) Subject: Fix to problem of getting RCS to work on Sun 3.0 I've just got on the Sun-Spots list and I was reading some of the old digests and noticed the messages from penny@CCA.CCA.COM (Penny Rheingans) and franklin%pp@mcc.arpa (Maurice T. Franklin) in the old Sun-Spots issues. They had trouble getting RCS to work on Sun3.0 after having ported it to Sun 2.0 (and fixing all those NASTY null pointer dereference's). While I discovered a similar problem here on our machines running Sun3.0 IFF you make *LOTS* of changes to a file (where lots is some number of lines N that I'm not sure of). It's caused by an attempt at efficiency in diff that goes astray under Sun3.0. Just look at these lines from the routine ralloc() in the file rdiff/diff.c. Looks suspicious doesn't it? Note the quote below from the malloc() man page: free(p); <== Delete this line free(dummy); <== Delete this line dummy = malloc(1); <== Delete this line q = realloc(p, (unsigned)n); .\" @(#)malloc.3 1.1 85/12/28 SMI; from UCB 4.2 For backwards compatibility, realloc accepts a pointer to a block freed since the most recent call to malloc, calloc, realloc, valloc, or memalign. Note that using realloc with a block freed before the most recent call to malloc, calloc, realloc, valloc, or memalign is an error. ========================================================================== It should be noted that the Sun source code for ``diff'' also has these three lines removed. The only good thing about this is that I finally got motivated enough to learn to use ``dbx'', after years of using ``adb'' ever since ``sdb'' went away. It took me a whole day to find and fix this. I really wish RCS had been as well designed on the inside as it is on the outside. BTW Am I the only one who finds ``dbx'' ANNOYING? It is both verbose on output @ 19,200 it just flashes past you, and @ requiring you to type in LONG commands. It's also seems quite hostile at not doing ANYTHING unless you know exactly what it wants. It seems to have been designed by someone without any concept whatsoever of the UNIX design philsophy. How many people reading this message use ``adb'' or just printf's instead because ``dbx'' is such a stuck up piece of software and it takes too long to use? p.s. Does anyone out there have a copy of the RCS man pages I can get? The individual who had installed RCS here only kept around the source code. -- William P. Malloy (wpm@gateway.mitre.org) The MITRE Corporation 1820 Dolley Madison Blvd McLean, Virginia 22102 ------------------------------ Date: Fri, 5 Dec 86 22:12:03 EST From: NFS Functionality Enhancement Committee <dpk@BRL.ARPA> Subject: NFS Change to merge filesystems We are just beginning to use NFS around BRL and I have been amazed at how little thought seems to have been put into using NFS in a large collection of large hosts. Many of our machine have 8 to 16 disk segments mounted, and almost as many physical disks, so there is little that can be done to lower the number of mounted partitions. We wish to make every file system available from every system (or a close approximation of this). If we were to use the normal SUN NFS implementation, we would have mount tables with 100 to 200 mounted filesystems. This is a nightmare. I like to sleep, so I have made the following change to nfs/nfs_server.c (part of the NFS related kernel source). The effect of this change is to make tree of mounted local file systems appear as a single homogeneous file system to remote system that mount the root of such a tree. Mount points are invisibly followed as long as they go to a file system of the same type (which in this case is local). The restriction on the same type of file system is necessary to prevent file system loops. When/If more local file system types are supported, the "if" below would have to be made smarter. The statfs operation is somewhat meaningless with this change since it will only return the stats for the file system you mounted and not any file systems under it. The end result of all this is that you can now make all the file systems on a server system available by simply mounting the root file system (actually directory, e.g. mount -t nfs -o bg,soft host:/ /n/host). We have chosen to creat a directory /n and to make a directory in it for each system we wish to make available. We then mount the root of each system as /n/hostA, /n/hostB, ... It is quite possible some of you may be able to suggest some improvments to this implementation, such as ways to make it conditional or to better handle the statfs data. For us, this change alone is a big step forward in making NFS usable in a large cluster of independent super-mini computers (Vaxen, Goulds, Alliants) as well as workstations (Iris's, Suns). Comments welcome. -Doug- Encl. Diff of /sys/nfs/nfs_server.c. Line numbers are from the Gould version of the SUN sources, your mileage may vary. *** /tmp/,RCSt1000710 Fri Dec 5 21:38:09 1986 --- nfs_server.c Fri Dec 5 21:37:43 1986 *************** *** 289,294 **** --- 289,327 ---- if (error) { vp = (struct vnode *)0; } else { + #ifdef BRL + register struct vfs *vfsp; + struct vnode *tvp; + + /* + * The following allows the exporting of contiguous + * collections of local file systems. -DPK- + * + * If this vnode is mounted on, and the mounted VFS + * is the same as the current one (local), then we + * transparently indirect to the vnode which + * is the root of the mounted file system. + * Before we do this we must check that an unmount is not + * in progress on this vnode. This maintains the fs status + * quo while a possibly lengthy unmount is going on. + */ + mloop: + while ((vfsp = vp->v_vfsmountedhere) && + vfsp->vfs_op == vp->v_vfsp->vfs_op) { + while (vfsp->vfs_flag & VFS_MLOCK) { + vfsp->vfs_flag |= VFS_MWAIT; + sleep((caddr_t)vfsp, PVFS); + goto mloop; + } + error = VFS_ROOT(vp->v_vfsmountedhere, &tvp); + VN_RELE(vp); + if (error) { + vp = (struct vnode *)0; + goto bad; + } + vp = tvp; + } + #endif BRL error = VOP_GETATTR(vp, &va, u.u_cred); if (!error) { vattr_to_nattr(&va, &dr->dr_attr); *************** *** 295,300 **** --- 328,334 ---- error = makefh(&dr->dr_fhandle, vp); } } + bad: dr->dr_status = puterrno(error); if (vp) { VN_RELE(vp); ------------------------------ Date: Sun, 7 Dec 86 19:32:24 est From: hedrick@topaz.rutgers.edu (Charles Hedrick) Subject: patches for subnets, single-user boot security This posting includes two useful Sun patches: - installing support for subnets - preventing students from getting into root by booting machines single-user A number of people have asked for our subnet patches for the Sun. In fact Sun has started sending people to us. The following code is from 3.0, but as far as I know, it should work with 3.2. What this code does is to make the system think that each of your subnets is a separate network. That is, the routines that split an address up into net and host number normally split up 128.6.4.2 into a net number of 128.6 and a host number of 4.2. With our code, it treats 128.6.4 as the network and 2 as the host. It does this only for our own subnets, which is right. You will have to modify in.h to use your network number instead of ours. There is some problem deciding what the broadcast address should be. I believe 4.3 uses 128.6.4.255 on network 128.6, subnet 4. Unmodified 4.2 uses 128.6.0.0. With our subnet patch, it would normally use 128.6.4.0. Unfortunately, we do not have control over all of the machines on our network. Some are going to be Suns running unmodified Sun kernels. There can be big problems on the net if 4.2 systems don't agree upon the broadcast address. Thus we hack ip_output so that broadcasts always use 128.6.0.0. If you have 4.3, and you are willing to make sure that every one of your Suns uses this new code, you may want to modify the code to use the 4.3 version. I've added a comment suggesting how to do that, though I haven't tried it. I have hacked ip_input to recognize any of the possible broadcast addresses, i.e. 128.6.0.0, 128.6.4.0, 128.6.255.255, 128.6.4.255, 255.255.255.255 This should ease transition to the new conventions when you finally decide to switch. In addition to the kernel, all programs that send broadcasts must be modified so that they use the new broadcast addresses, e.g. 128.6.4.0. To do this, take a look at the module in.c below. Make the corresponding patches to the C library routines inet_netof and inet_lnaof, and relink the programs. You must fix at least umount and ypbind. You must fix routed if you run it. (We do not.) We suspect that it is OK to run an unmodified version of boot, but include the patches to boot anyway. We also include the patch to make boot require a password before doing "b -s". This is an obvious necessity in a student environment, else L1-A followed by "b -s" will give everyone access to root. Finally, ip_input shows a patch to turn off forwarding of packets. This should be done on any machine that is not a gateway. We also do something slightly more drastic than the original code, in that we do not send back ICMP error messages when we drop packets. Here's the problem: Suppose some poor schmuck makes a mistake in setting up his system. He sends out packets to some random address. With the normal setting, every machine on the network will try to forward it, and then send back ICMP destination unreachable. We'd rather have only the gateways send back the error. Note that gateway machines need to have ipforward on, so if any of your Suns are used as gateways, you won't want this patch for those machines. See the comments. *** netinet/in.c.ORIG Tue Aug 19 21:28:17 1986 --- netinet/in.c Tue Aug 19 21:28:13 1986 *************** *** 1,5 /* @(#)in.c 1.1 86/02/03 SMI; from UCB 4.12 83/03/14 */ - #include "../h/param.h" #include "../h/mbuf.h" #include "../h/protosw.h" --- 1,4 ----- /* @(#)in.c 1.1 86/02/03 SMI; from UCB 4.12 83/03/14 */ #include "../h/param.h" #include "../h/mbuf.h" #include "../h/protosw.h" *************** *** 5,11 #include "../h/protosw.h" #include "../h/socket.h" #include "../h/socketvar.h" ! #include "../netinet/in.h" #include "../netinet/in_systm.h" #include "../net/if.h" #include "../net/route.h" --- 4,10 ----- #include "../h/protosw.h" #include "../h/socket.h" #include "../h/socketvar.h" ! #include "in.h" #include "../netinet/in_systm.h" #include "../net/if.h" #include "../net/route.h" *************** *** 55,60 struct in_addr in; { register u_long i = ntohl(in.s_addr); if (IN_CLASSA(i)) return (((i)&IN_CLASSA_NET) >> IN_CLASSA_NSHIFT); --- 54,63 ----- struct in_addr in; { register u_long i = ntohl(in.s_addr); + /* subnet hack, taken from topaz's subnet code cwm 10/23/85 */ + if ((i & SUBNETMASK) == MYSUBNET) + return (((i)&SUBNETNET) >> SUBNETSHIFT); + /* end of subnet hack cwm 10/23/85 */ if (IN_CLASSA(i)) *************** *** 56,61 { register u_long i = ntohl(in.s_addr); if (IN_CLASSA(i)) return (((i)&IN_CLASSA_NET) >> IN_CLASSA_NSHIFT); else if (IN_CLASSB(i)) --- 59,65 ----- return (((i)&SUBNETNET) >> SUBNETSHIFT); /* end of subnet hack cwm 10/23/85 */ + if (IN_CLASSA(i)) return (((i)&IN_CLASSA_NET) >> IN_CLASSA_NSHIFT); else if (IN_CLASSB(i)) *************** *** 71,77 struct in_addr in; { register u_long i = ntohl(in.s_addr); ! if (IN_CLASSA(i)) return ((i)&IN_CLASSA_HOST); else if (IN_CLASSB(i)) --- 75,84 ----- struct in_addr in; { register u_long i = ntohl(in.s_addr); ! /* subnet hack, taken from topaz's subnet code cwm 10/23/85 */ ! if ((i & SUBNETMASK) == MYSUBNET) ! return ((i)&SUBNETHOST); ! /* end of subnet hack */ if (IN_CLASSA(i)) return ((i)&IN_CLASSA_HOST); else if (IN_CLASSB(i)) *** netinet/in.h.ORIG Tue Aug 19 21:28:18 1986 --- netinet/in.h Tue Aug 19 21:28:09 1986 *************** *** 5,10 * Per RFC 790, September 1981. */ /* * Protocols */ --- 5,19 ----- * Per RFC 790, September 1981. */ + /* Edit history: + + RU 1: add masks for subnet discrimitation and hostname recognition + Chuck Hedrick 7/31/86 + + */ + + + /* * Protocols */ *************** *** 87,92 #define s_impno S_un.S_un_b.s_b4 /* imp # */ #define s_lh S_un.S_un_b.s_b3 /* logical host */ }; /* * Definitions of bits in internet address integers. --- 96,110 ----- #define s_impno S_un.S_un_b.s_b4 /* imp # */ #define s_lh S_un.S_un_b.s_b3 /* logical host */ }; + + /* RU 1:definitions set for subnetting code: cwm 10/23/85 */ + + /* + * In reading this code, note that Rutgers is 128.6.0.0, i.e. x80060000. + * A typical subnet is 128.6.4.0, i.e. x80060400 + * A typical host is 128.6.4.2, i.e. x80060402 + */ + /* MYSUBNET is actually your class B [or whatever] net */ + #define MYSUBNET 0x80060000 + /* SUBNETMASK is a mask covering the main net, i.e. not including subnets */ + #define SUBNETMASK 0xffff0000 + /* SUBNETNET is a mask that includes the subnet */ + #define SUBNETNET 0xffffff00 + /* SUBNETSHIFT is used to right-justify SUBNETNET */ + #define SUBNETSHIFT 8 + /* SUBNETHOST is a mask that includes host only -- the bits 0 in SUBNETNET */ + #define SUBNETHOST 0x000000ff + /* end of subnet addtions cwm 10/23/85 */ /* * Definitions of bits in internet address integers. *** netinet/ip_input.c.ORIG Tue Aug 19 21:28:17 1986 --- netinet/ip_input.c Tue Aug 19 21:28:14 1986 *************** *** 156,161 */ if (ifinet) { struct sockaddr_in *sin; sin = (struct sockaddr_in *)&ifinet->if_addr; if (sin->sin_addr.s_addr == ip->ip_dst.s_addr) --- 156,162 ----- */ if (ifinet) { struct sockaddr_in *sin; + long i; sin = (struct sockaddr_in *)&ifinet->if_addr; if (sin->sin_addr.s_addr == ip->ip_dst.s_addr) *************** *** 161,166 if (sin->sin_addr.s_addr == ip->ip_dst.s_addr) goto ours; sin = (struct sockaddr_in *)&ifinet->if_broadaddr; if ((ifinet->if_flags & IFF_BROADCAST) && sin->sin_addr.s_addr == ip->ip_dst.s_addr) goto ours; --- 162,179 ----- if (sin->sin_addr.s_addr == ip->ip_dst.s_addr) goto ours; sin = (struct sockaddr_in *)&ifinet->if_broadaddr; + i = ip->ip_dst.s_addr; + /* + * RU: Use a looser test for broadcast packets. All ones + * will be accepted later on by original Sun code. + * The next test, with the IFF_BROADCAST in it, should now + * be irrelevant most of the time. + */ + if ((i & SUBNETMASK) == MYSUBNET) { + i &= SUBNETHOST; + if (i == 0 || i == SUBNETHOST) + goto ours; + } if ((ifinet->if_flags & IFF_BROADCAST) && sin->sin_addr.s_addr == ip->ip_dst.s_addr) goto ours; *************** *** 627,633 } int ipprintfs = 0; ! int ipforwarding = 1; /* * Forward a packet. If some error occurs return the sender * and icmp packet. Note we can't always generate a meaningful --- 640,650 ----- } int ipprintfs = 0; ! /* int ipforwarding = 1; */ ! /* RU: for Rutgers, we don't want to ipforward */ ! /* If your machine is a gateway, set ipforwarding back to 1 */ ! int ipforwarding = 0; ! ! /* * Forward a packet. If some error occurs return the sender * and icmp packet. Note we can't always generate a meaningful *************** *** 645,651 * for which they were destined -- happens with multiple * IP nets on one Ethernet */ ! if (in_netof(ip->ip_dst) == INADDR_ANY || (in_lnaof(ip->ip_dst) == INADDR_ANY && in_netof(ip->ip_dst) == in_netof(ip->ip_src))) { m_freem(dtom(ip)); --- 662,674 ----- * for which they were destined -- happens with multiple * IP nets on one Ethernet */ ! ! /* ! * RU: added ipforwarding == 0 here. We want stuff to be thrown away ! * with no error messages when we aren't a gateway ! */ ! if (ipforwarding == 0 || ! in_netof(ip->ip_dst) == INADDR_ANY || (in_lnaof(ip->ip_dst) == INADDR_ANY && in_netof(ip->ip_dst) == in_netof(ip->ip_src))) { m_freem(dtom(ip)); *************** *** 650,656 in_netof(ip->ip_dst) == in_netof(ip->ip_src))) { m_freem(dtom(ip)); return; ! } if (ipprintfs) printf("forward: src %x dst %x ttl %x\n", ip->ip_src, ip->ip_dst, ip->ip_ttl); --- 673,680 ----- in_netof(ip->ip_dst) == in_netof(ip->ip_src))) { m_freem(dtom(ip)); return; ! } ! if (ipprintfs) printf("forward: src %x dst %x ttl %x\n", ip->ip_src, ip->ip_dst, ip->ip_ttl); *** netinet/ip_output.c.ORIG Tue Aug 19 21:28:18 1986 --- netinet/ip_output.c Tue Aug 19 21:28:14 1986 *************** *** 122,127 error = EMSGSIZE; goto bad; } } /* --- 122,135 ----- error = EMSGSIZE; goto bad; } + /* + * RU: Normalize broadcast addresses. 4.3 has a more general + * solution for this, which lets us set a broadcast address for each + * network. + */ + if ((ip->ip_dst.s_addr & SUBNETMASK) == MYSUBNET) + ip->ip_dst.s_addr = MYSUBNET; /* 128.6.0.0 */ + } /* *** sunstand/boot.c.ORIG Tue Aug 19 21:29:46 1986 --- sunstand/boot.c Sun Nov 16 18:54:53 1986 *************** *** 6,11 * Copyright (c) 1983 by Sun Microsystems, Inc. */ #include "saio.h" #include "../h/reboot.h" #include "../mon/sunromvec.h" --- 6,19 ----- * Copyright (c) 1983 by Sun Microsystems, Inc. */ + /* 7/26/86: RU 1 - added code to ask for an (encrypted) password when a + single-user boot is asked for for. Also, a new routine (also new + routines in prf.c) to read characters without echoing them for + passwords. */ + + /* 11/14/86 RU 2 - tftpboot fails to work correctly on single-user + boot. fix this */ + #include "saio.h" #include "../h/reboot.h" #include "../mon/sunromvec.h" *************** *** 38,43 #ifdef JUSTASK howto = RB_ASKNAME|RB_SINGLE; #else arg = bp->bp_argv[0]; howto = bootflags(bp->bp_argv[1]); if ((howto&RB_ASKNAME)==0) { --- 46,53 ----- #ifdef JUSTASK howto = RB_ASKNAME|RB_SINGLE; #else + /* printf("boot arg is *%s*\n",bp->bp_argv[0]); + printf("boot flags are: *%s*\n",bp->bp_argv[1]); */ arg = bp->bp_argv[0]; howto = bootflags(bp->bp_argv[1]); /* RU 2: print out bootflags, to see how tftpboot sees the world */ *************** *** 40,45 #else arg = bp->bp_argv[0]; howto = bootflags(bp->bp_argv[1]); if ((howto&RB_ASKNAME)==0) { register char *s, *p; --- 50,57 ----- printf("boot flags are: *%s*\n",bp->bp_argv[1]); */ arg = bp->bp_argv[0]; howto = bootflags(bp->bp_argv[1]); + /* RU 2: print out bootflags, to see how tftpboot sees the world */ + if ((howto&RB_ASKNAME)==0) { register char *s, *p; for (s = arg, p = aline; *s; s++, p++) *************** *** 42,48 howto = bootflags(bp->bp_argv[1]); if ((howto&RB_ASKNAME)==0) { register char *s, *p; - for (s = arg, p = aline; *s; s++, p++) *p = *s; --- 54,59 ----- if ((howto&RB_ASKNAME)==0) { register char *s, *p; for (s = arg, p = aline; *s; s++, p++) *p = *s; *************** *** 108,113 { register int i, boothowto = 0; if (*cp++ == '-') do { for (i = 0; bootf[i].let; i++) { --- 119,137 ----- { register int i, boothowto = 0; + /* for RU hack: use j, str and ch to read the password */ + char str[20]; + register char ch; + register int j; + + /* printf("here in bootflags, cp = *%s* *cp = *%c* (%d octal)\n",cp,*cp,*cp); */ + j = 1; + + /* RU 2: we have to be a bit more careful with what we test for than we + used to. this replaces 'if (cp ==0)' */ + + if (*cp != '-') j = 0; + if (*cp++ == '-') do { for (i = 0; bootf[i].let; i++) { *************** *** 118,123 } cp++; } while (bootf[i].let && *cp); return (boothowto); } #endif --- 142,169 ----- } cp++; } while (bootf[i].let && *cp); + + /* RU 1: RU hack. if there are any parameters, ask for a password */ + + /* if (boothowto & RB_SINGLE) {printf("Password?"); */ + if (j ==1) {printf("Password?"); + i= 0; + while ((ch = getqchar()) != '\n') + { str[i] = ch; i++; + if (i > 19) i = 19; + }; + str[i] = '\0'; + + if (strcmp(crypt(str,"XX"),"XXfX1CKbtN.Pg")!=0) + { + /* invalid password, mask out the */ + /* stand-alone boot part */ + printf("sorry about that\n"); + boothowto = 0; + _stop((char *) 0); + } else printf("OK!\n"); + }; + return (boothowto); } #endif *************** *** 160,162 bp->bp_argv[narg] = 0; } } --- 206,227 ----- bp->bp_argv[narg] = 0; } } + getqchar() + + /* RU Hack: get characters 'quietly': without echoing */ + { + register int c; + + while ((c = (*romp->v_mayget)()) == -1) + ; + if (c == '\r') + c = '\n'; + if (c == 0177 || c == '\b') { + /* putchar('\b'); + putchar(' '); */ + c = '\b'; + } + /* putchar(c); */ + return (c); + } + *** sunstand/inet.c.ORIG Tue Aug 19 21:29:58 1986 --- sunstand/inet.c Tue Aug 19 21:29:44 1986 *************** *** 313,318 { register u_long i = ntohl(in.s_addr); if (IN_CLASSA(i)) return ((i)&IN_CLASSA_HOST); else if (IN_CLASSB(i)) --- 313,322 ----- { register u_long i = ntohl(in.s_addr); + /* subnet hack, taken from topaz's subnet code cwm 10/23/85 */ + if ((i & SUBNETMASK) == MYSUBNET) + return ((i)&SUBNETHOST); + /* end of subnet hack */ if (IN_CLASSA(i)) return ((i)&IN_CLASSA_HOST); else if (IN_CLASSB(i)) *************** *** 329,334 { register u_long i = ntohl(in.s_addr); if (IN_CLASSA(i)) { i &= IN_CLASSA_HOST; return (i == 0 || i == 0xFFFFFF); --- 333,344 ----- { register u_long i = ntohl(in.s_addr); + /* subnet hack, taken from topaz's subnet code cwm 10/23/85 */ + if ((i & SUBNETMASK) == MYSUBNET) { + i &= SUBNETHOST; + return (i == 0 || i == SUBNETHOST); + }; + /* end of subnet hack */ if (IN_CLASSA(i)) { i &= IN_CLASSA_HOST; return (i == 0 || i == 0xFFFFFF); *** sunstand/prf.c.ORIG Tue Aug 19 21:29:46 1986 --- sunstand/prf.c Tue Aug 19 21:29:41 1986 *************** *** 2,7 * @(#)prf.c 1.1 86/02/03 Copyright (c) 1985 by Sun Microsystems, Inc. */ #include "../h/types.h" #include "../mon/sunromvec.h" --- 2,11 ----- * @(#)prf.c 1.1 86/02/03 Copyright (c) 1985 by Sun Microsystems, Inc. */ + /* 7/26/86: CWM added routines gets and getchar for reading passwords - + see boot.c */ + + #include "../h/types.h" #include "../mon/sunromvec.h" *************** *** 133,136 { (*romp->v_putchar)(c); } --- 137,189 ----- { (*romp->v_putchar)(c); + } + + getchar() + { + register int c; + + while ((c = (*romp->v_mayget)()) == -1) + ; + if (c == '\r') + c = '\n'; + if (c == 0177 || c == '\b') { + putchar('\b'); + putchar(' '); + c = '\b'; + } + putchar(c); + return (c); + } + + /* Rutgers changes to get the ask-for-single-boot code to work right */ + + gets(buf) + char *buf; + { + register char *lp; + register c; + + lp = buf; + for (;;) { + c = getchar() & 0177; + switch(c) { + case '\n': + case '\r': + c = '\n'; + *lp++ = '\0'; + return; + case '\b': + lp--; + if (lp < buf) + lp = buf; + continue; + case 'u'&037: /* ^U */ + lp = buf; + putchar('\n'); + continue; + default: + *lp++ = c; + } + } } ------------------------------ Date: Mon, 15 Dec 86 10:13:03 EST From: mo@seismo.CSS.GOV (Mike O'Dell) Subject: Other Ethercards on the SUN In the previous issue, someone asked about putting "smart" Ethernet cards on the SUN, specifically mentioning the Excelan. That is a bad idea, mostly because at the moment, none of the available cards can do the protocols as fast as the SUN itself can. Specifically relating to the Excelan, the current Exos card when connected to a reasonable Unix box of another brand gets 80-100 Kbytes/second doing read/write spin-loops. Doing the same thing, a SUN3-SUN3 path doing the same thing gets about 300 Kbytes/second. I haven't benched CMC's 68000 card; it might be slightly faster than the Exos, but it is unlikely it is faster than the SUN. All the other protocol boards use Intel cpu's, which have many inherent disadvantages in protocol implementations, not the least of which is the byte-swaps. Further, most card implementations don't know about local routing information, often don't know anything about EGP, and some barely understand gateways. The competence of the implemenations vary widely. The big gotcha, though, is the host-front-end protocol. Often, the protocol to talk with the board is as complicated as the protocol being off-loaded. The Excelan board drivers I've seen have some terribly grim code to synchronize message transfers between the host and the FE processor. Don't get me wrong - if you could figure out how to do a really low-overhead interface and Host/FE protocol, and then build a network implementation which knows about everthing without cutting corners, and runs on a blisteringly fast CPU with the right byte-order, you would win big, at least in the amount of HOST spent doing networking. At the moment, however, there ain't such a beast available. (CMC's new MIPS board might change that, however.) -Mike O'Dell ------------------------------ Date: Tue, 16 Dec 86 10:44:42 EST From: Rick Genter <rgenter@DIAMOND.BBN.COM> Subject: Excelan board on a Sun-3 Our experience with the Excelan board is that it's performance is roughly 25-50% that of the software implementation of TCP/IP in vanilla 4.2 BSD Unix. Remember it's only a poor 8088 cranking away on the Excelan board. - Rick -------- Rick Genter BBN Laboratories Inc. (617) 497-3848 10 Moulton St. 6/512 rgenter@bbn.COM (Internet new) Cambridge, MA 02238 rgenter@bbnj.ARPA (Internet old) seismo!bbn.com!rgenter (UUCP) ------------------------------ Date: 16 Dec 1986 1149-PST (Tuesday) From: trwrb!trwspp!spp2!hull@ucbvax.Berkeley.EDU (David L. Hull) Subject: Re: Pixar computer on the Sun workstation Pixar was originally the computer graphics subdivision of Lucasfilm. At the beginning of 1986, it was sold to Steve Jobs, of Apple Computer fame. Pixar's product is the Pixar Image Computer, a general-purpose graphics computer which they claim operates at 40 MIPS. The standard configuration has a 24 Mb, 2000 by 2000 pixel picture memory. As of May 5, 1986, it cost $122,000 for the Image Computer alone, or $180,000 for the Image Computer with a Sun workstation, on which one writes and compiles the code for the Image Computer. Pixar has been shipping since May 11, 1986. I've seen one of these things and they're pretty nifty. For more information, contact Pixar at: P. O. Box 13719 San Rafael, California 94913 +1 (415) 499-3600 ---------------------------------------- David Hull TRW, Inc. Redondo Beach, CA ...{ucbvax|decvax}!trwrb!trwspp!spp2!hull ------------------------------ Date: Fri, 5 Dec 86 11:04:56 est From: mike@bambi.bellcore.com (Mike Caplinger) Subject: Is NeWS good news? I thought I might ask a possibly heretical question: is the pending arrival of NeWS such a good idea? The world needs a standard, portable window system very badly, but there are candidates better placed than NeWS, particularly MIT's X, which already has support for DEC, Sun, Apollo, Integrated Solutions, and IBM workstations. Regardless of the technical merits of NeWS over X (I don't know enough about either to say) X looks much further along as a portable, supported standard. I am wary of Sun establishing standards that their competitors might like to use -- note that NFS has appeared so far on superminis and Crayettes, not on competing workstations. Would anybody (Gettys and Gosling especially) like to comment? Mike Caplinger mike@bellcore.com {decvax,ihnp4}!bambi!mike ------------------------------ Date: Wed, 3 Dec 86 12:06:16 PST From: whj@vlsi.cs.washington.edu (Warren Jessop) Subject: 1/2 inch 1600/6250 bpi tape drives for Sun-3's? Jon- I too will need a 1600/6250 bpi tape drive for a network of Suns we are getting. I was thinking of about a Kennedy 9400 with a Ciprico Tapemaster 3000 controller. Right now I'm more worried about price than performance. The price we are looking at is about $10600 for the drive and controller. I'm wondering what your deal is on the Fujitsu and Interphase. Thanks. Warren. ------------------------------ Date: Fri, 05 Dec 86 13:38:52 PST From: cracraft@math.ucla.edu Subject: Laserwriter & Sun interactions? Recently, we installed Postscript/Transcript on our SUN's. Two problems have arisen and I am wondering if any of you have run into these also: 1) If enscript/lpr are used to queue multiple jobs, or multiple copies of the same jobs, sometimes several of the jobs are simply discarded from the print-queue. 2) If pssun is installed in /usr/lib/ps, along with an entry for 'psvf' in psint.sh to which '/usr/lib/psvf' is linked, one would expect 'screendump | lpr -PPostScript -v' to product an image of the SUN screen on a LaserWriter page, but only the banner comes out. Any advice or suggestions would be appreciated! Stuart ------------------------------ Date: Fri, 5 Dec 86 22:27:32 GMT From: Richard Tobin <richard%aiva.edinburgh.ac.uk@Cs.Ucl.AC.UK> Subject: scrolling canvases? does anyone know how to programatically scroll a canvas? i can't find any reference to it in the canvas section of the manual. calling scrollbar_scroll_to on the appropriate scrollbar doesn't seem to work. (actually, it does if i also call canvas_scroll, but i'm wondering if there's an official/documented way to do it). Richard Tobin, JANET: R.Tobin@uk.ac.edinburgh AI Applications Institute, ARPA: R.Tobin%uk.ac.edinburgh@ucl-cs.arpa Edinburgh University. UUCP: ...!ukc!edinburgh.ac.uk!R.Tobin ------------------------------ Date: Sun, 7 Dec 86 08:28:24 EST From: Don Gworek <uggworek%buffalo.csnet@RELAY.CS.NET> Subject: Appropriate place to exchange icons and rasterfiles? What's the appropriate newsgroup or mail list to exchange icon.h header files and rasterfiles for the suntools -background option? uucp: ...{rocksvax|decvax}!sunybcs!gworek csnet: gworek@buffalo.edu bitnet: gworek@sunybcs ------------------------------ Date: Sun, 7 Dec 86 14:53:18 MST From: hi!cyrus@hc.dspo.gov (Tait Cyrus) Subject: Including SUN screendumps in itroff files. Is it possible? I am looking for a way to include SUN screendumps in an itroff file. The man page I have for 'sunimp' says to do the following: screendump | sunimp > file Then use the nroff .cf command to include 'file' in the itroff output. My problem is that SUN 3.1 nroff/troff does not know what the .cf command is. I would appreciate ANY help on this matter. If I can not include SUN screendumps in an itroff file then I will have to resort to the old fashion 'cut-and-paste' method. I would REALLY prefer not to use this method. Thanks in advance for ANY, and I mean ANY, help. W. Tait Cyrus University of New Mexico Department of Electrical and Computer Engineering Hypercube Project Albuquerque, New Mexico 87131 (505) 277-0806 e-mail: cyrus@hc.dspo.gov {gatech|ucbvax|convex}!unmvax!hi!cyrus ------------------------------ Date: Sun, 7 Dec 86 23:19:50 -0100 From: H. Eidnes <H_Eidnes%vax.runit.unit.uninett@NTA-VAX.ARPA> Subject: Improper cleanup when exiting Suntools? This happens on a Sun-3/160 running v3.0 of Sun-Unix: Several times (always?) when I exit Suntools, it seems some status information is not properly written out. The symptoms are that when I run "w" after exiting, "w" shows a lot of processes logged on, but with no activity ("-") specified. The ttys are those that were used under Suntools. The sizes of the windows also seem not to be reset -- when we log in from another machine with rlogin, the termcap routines return different sizes than what is stored in the termcap file, even though the terminal type is set correctly, and "tset" is run. We have found the proper ioctl-call to reset this behaviour, and have written two small programs to get and (re)set the size of the tty as a temporary solution. To say the least, this is pretty annoying. Does anyone know what causes this behaviour, and/or have a fix for it? ------- E-Mail: <h_eidnes%vax.runit.unit.uninett@nta-vax.arpa> H}vard Eidnes (or TeXish: H\aa vard Eidnes) Division of Computer Science Norwegian Institute of Technology ------------------------------ Date: 9 Dec 86 00:36:54 GMT From: Matt Landau <mlandau@diamond.bbn.com> Subject: Sun 3.0 /bin/login doesn't set tty ownership? Can anyone give me a good reason why the Sun 3.0 and 3.2 versions of /bin/login don't set the ownership of the tty or pty so the logged in user is the owner? This breaks a number of things, including mesg (which is now unable to change the message permission mode) and the send program that was posted to mod.sources (which is no longer able to check for idle terminals be seeing who owns them). Will anything bad happen is I just install the 4.3 login instead of Suns? -- Matt Landau BBN Laboratories, Inc. mlandau@diamond.bbn.com 10 Moulton Street, Cambridge MA 02238 ...seismo!diamond.bbn.com!mlandau (617) 497-2429 ------------------------------ Date: 10 Dec 86 18:32:37 GMT From: ian@utcsri.UUCP (Ian Small) Subject: Frame Buffers/VMEbus to UNIBUS conversion woes...? We currently run an Ikonas 3000 in a VAX 11/780 environment. Because of a switchover to Sun equipment that is looming on the horizon, we are having to examine methods to make our Ikonas (a 24-bit plane 512x512 pixel frame buffer with 68000 bitslice processor) work in a VMEbus environment. Alternatively, we could elect to replace it. There are four questions which we are trying to answer. Any information that we might get from netland would help immensely. The questions are: 1) Does anybody know of a VMEbus to UNIBUS converter? There must be some way to plug UNIBUS equipment into Suns. Any information, including rumour, hard facts, names and/or numbers would be appreciated. 2) We could buy a Q-bus interface for our Ikonas, thereby allowing us to use a VMEbus to Q-bus converter. We know there exist some of these, but would be interested in any experience, advise, etc. that you may have. 3) Does there exist a 24-bit 512x512 (or better) frame buffer for VMEbus? We cannot find one of these at all. It seems that only if you have a PC do you have a wide range of choice. 4) Has anybody out there successfully hooked up an Ikonas in any fashion to a Sun? If there is sufficient interest, I will summarize responses and post to the net. Thanks in advance, -- Ian S. Small Dynamic Graphics Project Computer Systems Research Institute (416) 978-6619 University of Toronto ian@toronto.CSNET {allegra,cornell,decvax,ihnp4,linus,utzoo}!utcsri!ian ------------------------------ Date: Wed, 10 Dec 86 15:13:30 est From: allegra!mp@seismo.CSS.GOV Subject: CDC 9771 drives on Sun-2/170 or Sun-3/180? I'd like to put 4 (or more, software willing) CDC 9771's on a sun fileserver, using the resulting monster to hold remote dumps of our other 8 servers that will be done automatically overnight. Any words of advice on how the drives need to be configured? I plan to use the Xylogics 451 or Interphase 4200 controller. Mark Plotnick allegra!mp ------------------------------ Date: Thu, 11 Dec 86 16:49:40 PST From: Robert Allen <robert@spam.istc.sri.com> Subject: Protocol implementation in Sun open architecture? In perusing the Sun document "Network Implementation" I've noticed that it seems to be possible to use existing 'stubs' at the kernel level to implement new protocols. The existing structs seem generic, requiring only that one provide pointers to the appropriate functions, and certain paramater such as timeouts, etc.. I would like to know if anyone has implemented any protocols on a Sun 2 or Sun 3 using the existing kernel stubs. Also, I would like to know if such a thing is practical, or even intended (even if you haven't done it). Lastly, I'd like to know if anyone knows which ISO OSI standard layers are supported in this manner. Thanks in advance, Robert Allen, robert@sri-spam.arpa ------------------------------ Date: Fri, 12 Dec 86 15:34:02 EST From: munnari!trlamct.oz!andrew@seismo.CSS.GOV (Andrew Jennings) Subject: SunView & SunLisp? I'm in the throes of trying to hook these two together. Has anyone else tried this ? UUCP: ...!{seismo, mcvax, ucb-vision, ukc}!munnari!trlamct.trl!andrew ARPA: andrew%trlamct.trl.oz@seismo.css.gov Andrew Jennings Telecom Australia Research Laboratories, ------------------------------ Date: Thu 11 Dec 86 18:20:57-PST From: Doug Bryan <Bryan@SU-SIERRA.ARPA> Subject: mail on diskless workstations? I would like some recommendations from anyone out there who has been using diskless workstations for a while. We have 10 (diskless) 110s running off of a single 180 file server. The way it is set up now, none of the users have accounts on the 110s, rather they share the file servers /etc/passwd via yp and their home directories are on the file server via NFS. My question is: Is there an easy way to set up mail so that the users can log into any of the 110s and read their mail sent to them at the file server? doug ------- ------------------------------ Date: Fri, 12 Dec 86 19:11:36 GMT From: Richard Tobin <richard%aiva.edinburgh.ac.uk@Cs.Ucl.AC.UK> Subject: ld -A under rel 3.2? we have a program which uses ld with the -A option too dynamically load C code. under release 3.2 this produces several 'multiply defined' messages for C library functions such as fflush. the original program was linked under release 3.0; i don't know if this makes a difference because we don't have 3.2 yet ourselves. can anyone suggest an explanation/fix ? Richard Tobin, JANET: R.Tobin@uk.ac.edinburgh AI Applications Institute, ARPA: R.Tobin%uk.ac.edinburgh@ucl-cs.arpa Edinburgh University. UUCP: ...!ukc!edinburgh.ac.uk!R.Tobin ------------------------------ Date: Wed, 3 Dec 86 13:30:15 est From: astrovax.CSS.GOV!rutgers!topaz!pjt@soma.UUCP (Peter J. Teuben) Subject: sun fortran recursion? If I declare a variable to be, for example, of integer type in a recursive subroutine with sun f77, what is the correct syntax to declare that variable to be of automatic type? The compiler does not accept either of the forms integer automatic ... or automatic integer ... . ------------------------------ From: Matt Landau <mlandau@diamond.bbn.com> Date: 15 Dec 86 19:14:47 GMT Subject: MX mods for 3.2 sendmail? Now that we have Sun 3.2 sources, I'd like to modify 3.2 sendmail to handle MX records. Has anyone done this? Do the 4.2 or 4.3 diffs available from ucbarpa.berkeley.edu apply unmodified? Any hints before I start on this would be appreciated. -- Matt Landau BBN Laboratories, Inc. mlandau@diamond.bbn.com 10 Moulton Street, Cambridge MA 02238 ...seismo!diamond.bbn.com!mlandau (617) 497-2429 ------------------------------ Date: 12 Dec 86 05:18:57 GMT From: soma!sob@rice.edu (Stan Barber) Subject: Sun 4.2bsd adb annoyances? 1. Anyone know how to get adb to automagically continue from a breakpoint, e.g., subroutine+4:b ,5$c;:c ? 2. When I try to have adb read a script at a breakpoint, e.g., subroutine+4:b *(<a6+8)$<script I expect that '.' would be set to the what my first formal parameter points to. Guess again - '.' is set to _subroutine+4 !! (Evidence: first line of script is . >8 and <8 didn't have what I expected in it; though executing that same command from the terminal while at the breakpoint behaved correctly.) 3. Is anyone going to document in the UPM that all numbers to the right of the command, e.g., arr/10X are interpreted in DECIMAL?!? Since I am no longer reading the net often, I would appreciate e-mail responses (though I will not complain if you also post to the net). -- The Ice Floe of the Window Wizard {amd,decwrl,sun,idi,cbosgd,ihnp4}!qubix!lab "Can you imagine someone like Desmond Tutu in Moscow, speaking out against that government - more than once?" ------------------------------ End of SUN-Spots Digest ***********************