Return to BSD News archive
Newsgroups: comp.bugs.2bsd Path: euryale.cc.adfa.oz.au!platinum.sge.net!como.dpie.gov.au!news.gan.net.au!act.news.telstra.net!vic.news.telstra.net!news.mira.net.au!news.vbc.net!vbcnet-west!bulb.garlic.com!news.scruz.net!kithrup.com!news.Stanford.EDU!su-news-hub1.bbnplanet.com!cpk-news-hub1.bbnplanet.com!news.bbnplanet.com!news-peer.sprintlink.net!news-pull.sprintlink.net!news-in-east.sprintlink.net!news.sprintlink.net!Sprint!130.207.244.18!gatech!nntp.netrex.net!wlbr!moe.2bsd.com!sms From: sms@moe.2bsd.com (Steven M. Schultz) Subject: id(1) replaces groups(1) and whoami(1) (#375) Organization: 2BSD, Simi Valley CA USA Message-ID: <ECGzvG.LI5@moe.2bsd.com> Date: Sat, 28 Jun 1997 05:14:04 GMT Lines: 1353 Xref: euryale.cc.adfa.oz.au comp.bugs.2bsd:803 Subject: id(1) replaces groups(1) and whoami(1) (#375) Index: usr.bin/id,ucb/whoami,groups.c 2.11BSD Description: The id(1) program has been ported from 4.4-Lite2. Repeat-By: Become accustomed to typing 'id' to see which userid you're currently using, then login to a 2.11 system and type 'id'. Observe the: id: Command not found error. Fix: In the course of using 4.4BSD derived systems I've become used to having the 'id' program present. The groups(1) and whoami(1) programs are now shell scripts which invoke the new id(1) program. Contained in the shar file below are the following items: 375.shar - a shar file of new programs being added to the system 375.rm - a shell script to remove files no longer needed in the system 375.patch - a patch file which updates Makefiles To install the id(1) program cut where indicated, saving to a file (/tmp/375). Then: cd /tmp sh 375 sh 375.shar patch -p0 < 375.patch At this point part of the C library (libc.a) must be recompiled and installed into libc.a: cd /usr/src/lib/libc/gen make ar r /lib/libc.a *.o cd profiled ar r /usr/lib/libc_p.a *.o ranlib /lib/libc.a /usr/lib/libc_p.a cd .. make clean The new manpage needs to be formatted and installed: cd /usr/src/man/man3 /usr/man/manroff getgrouplist.3 > getgrouplist.0 install -m 444 getgrouplist.0 /usr/man/cat3 Next the id(1) program is compiled and installed: cd /usr/src/usr.bin/id make make install make clean Finally the old programs and their manpages (/usr/ucb/groups, groups.1, etc) are removed from the system: cd /tmp sh 375.rm And a bit of cleanup: rm 375 375.rm 375.patch 375.shar That's all there is to it. Enjoy. As always this and previous updates to 2.11BSD are available via anonymous FTP to either FTP.IIPO.GTEGSC.COM or MOE.2BSD.COM in the directory /pub/2.11BSD. --------------------------cut here----------------------------- #! /bin/sh # This is a shell archive, meaning: # 1. Remove everything above the #! /bin/sh line. # 2. Save the resulting text in a file. # 3. Execute the file with /bin/sh (not csh) to create: # 375.shar # 375.rm # 375.patch # This archive created: Fri Jun 27 21:00:32 1997 export PATH; PATH=/bin:/usr/bin:$PATH if test -f '375.shar' then echo shar: "will not over-write existing file '375.shar'" else sed 's/^Z//' << \SHAR_EOF > '375.shar' Z#! /bin/sh Z# This is a shell archive, meaning: Z# 1. Remove everything above the #! /bin/sh line. Z# 2. Save the resulting text in a file. Z# 3. Execute the file with /bin/sh (not csh) to create: Z# /usr/src/lib/libc/gen/getgrouplist.c Z# /usr/src/man/man3/getgrouplist.3 Z# /usr/src/usr.bin/id Z# This archive created: Fri Jun 27 20:44:16 1997 Zexport PATH; PATH=/bin:/usr/bin:$PATH Zif test -f '/usr/src/lib/libc/gen/getgrouplist.c' Zthen Z echo shar: "will not over-write existing file '/usr/src/lib/libc/gen/getgrouplist.c'" Zelse Zsed 's/^V//' << \SHAR_EOF > '/usr/src/lib/libc/gen/getgrouplist.c' ZV/* ZV * Copyright (c) 1991, 1993 ZV * The Regents of the University of California. All rights reserved. ZV * ZV * Redistribution and use in source and binary forms, with or without ZV * modification, are permitted provided that the following conditions ZV * are met: ZV * 1. Redistributions of source code must retain the above copyright ZV * notice, this list of conditions and the following disclaimer. ZV * 2. Redistributions in binary form must reproduce the above copyright ZV * notice, this list of conditions and the following disclaimer in the ZV * documentation and/or other materials provided with the distribution. ZV * 3. All advertising materials mentioning features or use of this software ZV * must display the following acknowledgement: ZV * This product includes software developed by the University of ZV * California, Berkeley and its contributors. ZV * 4. Neither the name of the University nor the names of its contributors ZV * may be used to endorse or promote products derived from this software ZV * without specific prior written permission. ZV * ZV * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV * SUCH DAMAGE. ZV */ ZV ZV#if defined(LIBC_SCCS) && !defined(lint) ZVstatic char sccsid[] = "@(#)getgrouplist.c 8.2.1 (2.11BSD) 1997/6/25"; ZV#endif /* LIBC_SCCS and not lint */ ZV ZV/* ZV * get credential ZV */ ZV#include <sys/types.h> ZV#include <string.h> ZV#include <grp.h> ZV ZVint ZVgetgrouplist(uname, agroup, groups, grpcnt) ZV char *uname; ZV gid_t agroup; ZV register gid_t *groups; ZV int *grpcnt; ZV{ ZV register struct group *grp; ZV int i, ngroups, ret, maxgroups; ZV ZV ret = 0; ZV ngroups = 0; ZV maxgroups = *grpcnt; ZV /* ZV * When installing primary group, duplicate it; ZV * the first element of groups is the effective gid ZV * and will be overwritten when a setgid file is executed. ZV */ ZV groups[ngroups++] = agroup; ZV if (maxgroups > 1) ZV groups[ngroups++] = agroup; ZV /* ZV * Scan the group file to find additional groups. ZV */ ZV setgrent(); ZV while (grp = getgrent()) { ZV if (grp->gr_gid == agroup) ZV continue; ZV for (i = 0; grp->gr_mem[i]; i++) { ZV if (!strcmp(grp->gr_mem[i], uname)) { ZV if (ngroups >= maxgroups) { ZV ret = -1; ZV break; ZV } ZV groups[ngroups++] = grp->gr_gid; ZV break; ZV } ZV } ZV } ZV endgrent(); ZV *grpcnt = ngroups; ZV return (ret); ZV} ZSHAR_EOF Zchmod 644 '/usr/src/lib/libc/gen/getgrouplist.c' Zfi Zif test -f '/usr/src/man/man3/getgrouplist.3' Zthen Z echo shar: "will not over-write existing file '/usr/src/man/man3/getgrouplist.3'" Zelse Zsed 's/^V//' << \SHAR_EOF > '/usr/src/man/man3/getgrouplist.3' ZV.\" Copyright (c) 1991, 1993 ZV.\" The Regents of the University of California. All rights reserved. ZV.\" ZV.\" Redistribution and use in source and binary forms, with or without ZV.\" modification, are permitted provided that the following conditions ZV.\" are met: ZV.\" 1. Redistributions of source code must retain the above copyright ZV.\" notice, this list of conditions and the following disclaimer. ZV.\" 2. Redistributions in binary form must reproduce the above copyright ZV.\" notice, this list of conditions and the following disclaimer in the ZV.\" documentation and/or other materials provided with the distribution. ZV.\" 3. All advertising materials mentioning features or use of this software ZV.\" must display the following acknowledgement: ZV.\" This product includes software developed by the University of ZV.\" California, Berkeley and its contributors. ZV.\" 4. Neither the name of the University nor the names of its contributors ZV.\" may be used to endorse or promote products derived from this software ZV.\" without specific prior written permission. ZV.\" ZV.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV.\" SUCH DAMAGE. ZV.\" ZV.\" @(#)getgrouplist.3 8.1.1 (2.11BSD) 1997/6/25 ZV.\" ZV.TH GETGROUPLIST 3 "June 25, 1997" ZV.UC 4 ZV.SH NAME ZVgetgrouplist \- calculate group access list ZV.SH SYNOPSIS ZV.nf ZV.B #include <unistd.h> ZV.B int ZV\fBgetgrouplist\fP(\fIname, basegid, groups, ngroups\fP) ZV\ \ \ \ \ \ \ \ \ \ \ \ \ char\ *name; ZV\ \ \ \ \ \ \ \ \ \ \ \ \ gid_t basegid; ZV\ \ \ \ \ \ \ \ \ \ \ \ \ gid_t *groups; ZV\ \ \ \ \ \ \ \ \ \ \ \ \ int\ \ \ *ngroups; ZV.SH DESCRIPTION ZVThe ZV.B getgrouplist ZVfunction reads through the group file and calculates ZVthe group access list for the user specified in ZV.IR name . ZVThe ZV.I basegid ZVis automatically included in the groups list. ZVTypically this value is given as ZVthe group number from the password file. ZV.PP ZVThe resulting group list is returned in the integer array pointed to by ZV.IR groups . ZVThe caller specifies the size of the ZV.IR groups ZVarray in the integer pointed to by ZV.IR ngroups ; ZVthe actual number of groups found is returned in ZV.IR ngroups . ZV.SH RETURN VALUES ZVThe ZV.B getgrouplist ZVfunction ZVreturns \-1 if the size of the group list is too small to ZVhold all the user's groups. ZVHere, the group array will be filled with as many groups as will fit. ZV.SH FILES ZV.TP 12 ZV/etc/group ZVgroup membership list ZV.SH SEE ALSO ZVsetgroups(2), ZVinitgroups(3) ZV.SH HISTORY ZVThe ZV.B getgrouplist ZVfunction first appeared in 4.4BSD. ZV.SH BUGS ZVThe ZV.B getgrouplist ZVfunction ZVuses the routines based on ZVgetgrent(3). ZVIf the invoking program uses any of these routines, ZVthe group structure will ZVbe overwritten in the call to ZV.BR getgrouplist . ZSHAR_EOF Zchmod 644 '/usr/src/man/man3/getgrouplist.3' Zfi Zif test ! -d '/usr/src/usr.bin/id' Zthen Z mkdir '/usr/src/usr.bin/id' Zfi Zcd '/usr/src/usr.bin/id' Zif test -f 'groups.1' Zthen Z echo shar: "will not over-write existing file 'groups.1'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'groups.1' ZV.\" Copyright (c) 1991, 1993 ZV.\" The Regents of the University of California. All rights reserved. ZV.\" ZV.\" Redistribution and use in source and binary forms, with or without ZV.\" modification, are permitted provided that the following conditions ZV.\" are met: ZV.\" 1. Redistributions of source code must retain the above copyright ZV.\" notice, this list of conditions and the following disclaimer. ZV.\" 2. Redistributions in binary form must reproduce the above copyright ZV.\" notice, this list of conditions and the following disclaimer in the ZV.\" documentation and/or other materials provided with the distribution. ZV.\" 3. All advertising materials mentioning features or use of this software ZV.\" must display the following acknowledgement: ZV.\" This product includes software developed by the University of ZV.\" California, Berkeley and its contributors. ZV.\" 4. Neither the name of the University nor the names of its contributors ZV.\" may be used to endorse or promote products derived from this software ZV.\" without specific prior written permission. ZV.\" ZV.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV.\" SUCH DAMAGE. ZV.\" ZV.\" @(#)groups.1 8.1.1 (2.11BSD) 1997/6/25 ZV.\" ZV.TH GROUPS 1 "June 25, 1997" ZV.UC 4 ZV.SH NAME ZVgroups \- show group memberships ZV.SH SYNOPSIS ZV.B groups [\fIuser\fP] ZV.SH DESCRIPTION ZVThe ZV.B groups ZVutility has been obsoleted by the ZVid(1) ZVutility, and is equivalent to ``\fBid \-Gn\fP [\fIuser\fP]''. ZVThe command ZV.br ZV``\fBid \-p\fP'' ZVis suggested for normal interactive use. ZV.PP ZVThe ZV.B groups ZVutility displays the groups to which you (or the optionally specified user) ZVbelong. ZV.PP ZVThe ZV.B groups ZVutility exits 0 on success, and >0 if an error occurs. ZV.SH SEE ALSO ZVid(1) ZSHAR_EOF Zchmod 644 'groups.1' Zfi Zif test -f 'groups.sh' Zthen Z echo shar: "will not over-write existing file 'groups.sh'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'groups.sh' ZV#!/bin/sh - ZV# ZV# Copyright (c) 1991, 1993 ZV# The Regents of the University of California. All rights reserved. ZV# ZV# Redistribution and use in source and binary forms, with or without ZV# modification, are permitted provided that the following conditions ZV# are met: ZV# 1. Redistributions of source code must retain the above copyright ZV# notice, this list of conditions and the following disclaimer. ZV# 2. Redistributions in binary form must reproduce the above copyright ZV# notice, this list of conditions and the following disclaimer in the ZV# documentation and/or other materials provided with the distribution. ZV# 3. All advertising materials mentioning features or use of this software ZV# must display the following acknowledgement: ZV# This product includes software developed by the University of ZV# California, Berkeley and its contributors. ZV# 4. Neither the name of the University nor the names of its contributors ZV# may be used to endorse or promote products derived from this software ZV# without specific prior written permission. ZV# ZV# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV# SUCH DAMAGE. ZV# ZV# @(#)groups.sh 8.1 (Berkeley) 6/6/93 ZV# ZV ZVid -Gn $* ZSHAR_EOF Zchmod 644 'groups.sh' Zfi Zif test -f 'id.1' Zthen Z echo shar: "will not over-write existing file 'id.1'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'id.1' ZV.\" Copyright (c) 1991, 1993, 1994 ZV.\" The Regents of the University of California. All rights reserved. ZV.\" ZV.\" This code is derived from software contributed to Berkeley by ZV.\" the Institute of Electrical and Electronics Engineers, Inc. ZV.\" ZV.\" Redistribution and use in source and binary forms, with or without ZV.\" modification, are permitted provided that the following conditions ZV.\" are met: ZV.\" 1. Redistributions of source code must retain the above copyright ZV.\" notice, this list of conditions and the following disclaimer. ZV.\" 2. Redistributions in binary form must reproduce the above copyright ZV.\" notice, this list of conditions and the following disclaimer in the ZV.\" documentation and/or other materials provided with the distribution. ZV.\" 3. All advertising materials mentioning features or use of this software ZV.\" must display the following acknowledgement: ZV.\" This product includes software developed by the University of ZV.\" California, Berkeley and its contributors. ZV.\" 4. Neither the name of the University nor the names of its contributors ZV.\" may be used to endorse or promote products derived from this software ZV.\" without specific prior written permission. ZV.\" ZV.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV.\" SUCH DAMAGE. ZV.\" ZV.\" @(#)id.1 8.2.1 (2.11BSD) 1997/6/25 ZV.\" ZV.TH ID 1 "June 25, 1997" ZV.UC 4 ZV.SH NAME ZVid \- return user identity ZV.SH SYNOPSIS ZV\fBid\fP [\fIuser\fP] ZV.br ZV.B id \-G ZV[\fB\-n\fP] ZV[\fIuser\fP] ZV.br ZV.B id \-g ZV[\fB\-nr\fP] ZV[\fIuser\fP] ZV.br ZV.B id \-p ZV.br ZV.B id \-u ZV[\fB\-nr\fP] ZV[\fIuser\fP] ZV.SH DESCRIPTION ZVThe ZV.B id ZVutility displays the user and group names and numeric IDs, of the ZVcalling process, to the standard output. ZVIf the real and effective IDs are different, both are displayed, ZVotherwise only the real ID is displayed. ZV.PP ZVIf a ZV.I user ZV(login name or user ID) ZVis specified, the user and group IDs of that user are displayed. ZVIn this case, the real and effective IDs are assumed to be the same. ZV.PP ZVThe options are as follows: ZV.TP 10 ZV.B \-G ZVDisplay the different group IDs (effective, real and supplementary) ZVas white-space separated numbers, in no particular order. ZV.TP 10 ZV.B \-g ZVDisplay the effective group ID as a number. ZV.TP 10 ZV.B \-n ZVDisplay the name of the user or group ID for the ZV\fB\-G\P, \fB\-g\fP and \fB\-u\fP ZVoptions instead of the number. ZVIf any of the ID numbers cannot be mapped into names, the number will be ZVdisplayed as usual. ZV.TP 10 ZV.B \-p ZVMake the output human-readable. ZVIf the user name returned by ZVgetlogin(2) ZVis different from the login name referenced by the user ID, the name ZVreturned by ZVgetlogin(2) ZVis displayed, preceded by the keyword ``login''. ZVThe user ID as a name is displayed, preceded by the keyword ``uid''. ZVIf the effective user ID is different from the real user ID, the real user ZVID is displayed as a name, preceded by the keyword ``euid''. ZVIf the effective group ID is different from the real group ID, the real group ZVID is displayed as a name, preceded by the keyword ``rgid''. ZVThe list of groups to which the user belongs is then displayed as names, ZVpreceded by the keyword ``groups''. ZVEach display is on a separate line. ZV.TP 10 ZV.B \-r ZVDisplay the real ID for the \fB\-g\fP and \fB\-u\fP ZVoptions instead of the effective ID. ZV.TP 10 ZV.B \-u ZVDisplay the effective user ID as a number. ZV.PP ZVThe ZV.B id ZVutility exits 0 on success, and >0 if an error occurs. ZV.SH SEE ALSO ZVwho(1) ZV.SH STANDARDS ZVThe ZV.B id ZVfunction is expected to conform to ZVIEEE Std1003.2 (``POSIX''). ZV.SH HISTORY ZVThe ZVhistoric ZVgroups(1) command is equivalent to ZV``\fBid \-Gn\fP [\fBuser\fP]''. ZV.PP ZVThe ZVhistoric ZVwhoami(1) ZVcommand is equivalent to ZV``\fBid \-un\fP''. ZV.PP ZVThe ZV.B id ZVcommand first appeared in 4.4BSD. ZSHAR_EOF Zchmod 644 'id.1' Zfi Zif test -f 'id.c' Zthen Z echo shar: "will not over-write existing file 'id.c'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'id.c' ZV/*- ZV * Copyright (c) 1991, 1993 ZV * The Regents of the University of California. All rights reserved. ZV * ZV * Redistribution and use in source and binary forms, with or without ZV * modification, are permitted provided that the following conditions ZV * are met: ZV * 1. Redistributions of source code must retain the above copyright ZV * notice, this list of conditions and the following disclaimer. ZV * 2. Redistributions in binary form must reproduce the above copyright ZV * notice, this list of conditions and the following disclaimer in the ZV * documentation and/or other materials provided with the distribution. ZV * 3. All advertising materials mentioning features or use of this software ZV * must display the following acknowledgement: ZV * This product includes software developed by the University of ZV * California, Berkeley and its contributors. ZV * 4. Neither the name of the University nor the names of its contributors ZV * may be used to endorse or promote products derived from this software ZV * without specific prior written permission. ZV * ZV * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV * SUCH DAMAGE. ZV */ ZV ZV#if !defined(lint) && defined(DOSCCS) ZVstatic char copyright[] = ZV"@(#) Copyright (c) 1991, 1993\n\ ZV The Regents of the University of California. All rights reserved.\n"; ZV ZVstatic char sccsid[] = "@(#)id.c 8.3.1 (2.11BSD) 97/6/25"; ZV#endif ZV ZV#include <sys/param.h> ZV ZV/* #include <err.h> */ ZV#include <errno.h> ZV#include <grp.h> ZV#include <pwd.h> ZV#include <stdio.h> ZV#include <stdlib.h> ZV#include <string.h> ZV#include <unistd.h> ZV ZV#define __P(protos) () ZV ZVvoid current __P((void)); ZVvoid pretty __P((struct passwd *)); ZVvoid group __P((struct passwd *, int)); ZVvoid usage __P((void)); ZVvoid user __P((struct passwd *)); ZVstruct passwd * ZV who __P((char *)); ZV ZVint ZVmain(argc, argv) ZV int argc; ZV char *argv[]; ZV{ ZV struct group *gr; ZV struct passwd *pw; ZV int Gflag, ch, gflag, id, nflag, pflag, rflag, uflag; ZV ZV Gflag = gflag = nflag = pflag = rflag = uflag = 0; ZV while ((ch = getopt(argc, argv, "Ggnpru")) != EOF) ZV switch(ch) { ZV case 'G': ZV Gflag = 1; ZV break; ZV case 'g': ZV gflag = 1; ZV break; ZV case 'n': ZV nflag = 1; ZV break; ZV case 'p': ZV pflag = 1; ZV break; ZV case 'r': ZV rflag = 1; ZV break; ZV case 'u': ZV uflag = 1; ZV break; ZV case '?': ZV default: ZV usage(); ZV } ZV argc -= optind; ZV argv += optind; ZV ZV switch(Gflag + gflag + pflag + uflag) { ZV case 1: ZV break; ZV case 0: ZV if (!nflag && !rflag) ZV break; ZV /* FALLTHROUGH */ ZV default: ZV usage(); ZV } ZV ZV pw = *argv ? who(*argv) : NULL; ZV ZV if (gflag) { ZV id = pw ? pw->pw_gid : rflag ? getgid() : getegid(); ZV if (nflag && (gr = getgrgid(id))) ZV (void)printf("%s\n", gr->gr_name); ZV else ZV (void)printf("%u\n", id); ZV exit(0); ZV } ZV ZV if (uflag) { ZV id = pw ? pw->pw_uid : rflag ? getuid() : geteuid(); ZV if (nflag && (pw = getpwuid(id))) ZV (void)printf("%s\n", pw->pw_name); ZV else ZV (void)printf("%u\n", id); ZV exit(0); ZV } ZV ZV if (Gflag) { ZV group(pw, nflag); ZV exit(0); ZV } ZV ZV if (pflag) { ZV pretty(pw); ZV exit(0); ZV } ZV ZV if (pw) ZV user(pw); ZV else ZV current(); ZV exit(0); ZV} ZV ZVvoid ZVpretty(pw) ZV struct passwd *pw; ZV{ ZV struct group *gr; ZV u_int eid, rid; ZV char *login; ZV ZV if (pw) { ZV (void)printf("uid\t%s\n", pw->pw_name); ZV (void)printf("groups\t"); ZV group(pw, 1); ZV } else { ZV if ((login = getlogin()) == NULL) ZV err(1, "getlogin"); ZV ZV pw = getpwuid(rid = getuid()); ZV if (pw == NULL || strcmp(login, pw->pw_name)) ZV (void)printf("login\t%s\n", login); ZV if (pw) ZV (void)printf("uid\t%s\n", pw->pw_name); ZV else ZV (void)printf("uid\t%u\n", rid); ZV ZV if ((eid = geteuid()) != rid) ZV if (pw = getpwuid(eid)) ZV (void)printf("euid\t%s", pw->pw_name); ZV else ZV (void)printf("euid\t%u", eid); ZV if ((rid = getgid()) != (eid = getegid())) ZV if (gr = getgrgid(rid)) ZV (void)printf("rgid\t%s\n", gr->gr_name); ZV else ZV (void)printf("rgid\t%u\n", rid); ZV (void)printf("groups\t"); ZV group(NULL, 1); ZV } ZV} ZV ZVvoid ZVcurrent() ZV{ ZV struct group *gr; ZV struct passwd *pw; ZV int cnt, id, eid, lastid, ngroups; ZV gid_t groups[NGROUPS]; ZV char *fmt; ZV ZV id = getuid(); ZV (void)printf("uid=%u", id); ZV if (pw = getpwuid(id)) ZV (void)printf("(%s)", pw->pw_name); ZV if ((eid = geteuid()) != id) { ZV (void)printf(" euid=%u", eid); ZV if (pw = getpwuid(eid)) ZV (void)printf("(%s)", pw->pw_name); ZV } ZV id = getgid(); ZV (void)printf(" gid=%u", id); ZV if (gr = getgrgid(id)) ZV (void)printf("(%s)", gr->gr_name); ZV if ((eid = getegid()) != id) { ZV (void)printf(" egid=%u", eid); ZV if (gr = getgrgid(eid)) ZV (void)printf("(%s)", gr->gr_name); ZV } ZV ngroups = getgroups(NGROUPS, groups); ZV if (ngroups > 0) ZV for (fmt = " groups=%u", lastid = -1, cnt = 0; cnt < ngroups; ZV fmt = ", %u", lastid = id) { ZV id = groups[cnt++]; ZV if (lastid == id) ZV continue; ZV (void)printf(fmt, id); ZV if (gr = getgrgid(id)) ZV (void)printf("(%s)", gr->gr_name); ZV } ZV (void)printf("\n"); ZV} ZV ZVvoid ZVuser(pw) ZV register struct passwd *pw; ZV{ ZV struct group *gr; ZV gid_t groups[NGROUPS + 1]; ZV int cnt, id, lastid, ngroups; ZV char *fmt; ZV ZV id = pw->pw_uid; ZV (void)printf("uid=%u(%s)", id, pw->pw_name); ZV (void)printf(" gid=%u", pw->pw_gid); ZV if ((gr = getgrgid(pw->pw_gid)) != NULL) ZV (void)printf("(%s)", gr->gr_name); ZV ngroups = NGROUPS + 1; ZV (void) getgrouplist(pw->pw_name, pw->pw_gid, groups, &ngroups); ZV fmt = " groups=%u"; ZV for (lastid = -1, cnt = 0; cnt < ngroups; ++cnt) { ZV if (lastid == (id = groups[cnt])) ZV continue; ZV (void)printf(fmt, id); ZV fmt = " %u"; ZV if (gr = getgrgid(id)) ZV (void)printf("(%s)", gr->gr_name); ZV lastid = id; ZV } ZV (void)printf("\n"); ZV} ZV ZVvoid ZVgroup(pw, nflag) ZV struct passwd *pw; ZV int nflag; ZV{ ZV struct group *gr; ZV int cnt, id, lastid, ngroups; ZV gid_t groups[NGROUPS + 1]; ZV char *fmt; ZV ZV if (pw) { ZV ngroups = NGROUPS + 1; ZV (void) getgrouplist(pw->pw_name, pw->pw_gid, groups, &ngroups); ZV } else { ZV groups[0] = getgid(); ZV ngroups = getgroups(NGROUPS, groups + 1) + 1; ZV } ZV fmt = nflag ? "%s" : "%u"; ZV for (lastid = -1, cnt = 0; cnt < ngroups; ++cnt) { ZV if (lastid == (id = groups[cnt])) ZV continue; ZV if (nflag) { ZV if (gr = getgrgid(id)) ZV (void)printf(fmt, gr->gr_name); ZV else ZV (void)printf(*fmt == ' ' ? " %u" : "%u", ZV id); ZV fmt = " %s"; ZV } else { ZV (void)printf(fmt, id); ZV fmt = " %u"; ZV } ZV lastid = id; ZV } ZV (void)printf("\n"); ZV} ZV ZVstruct passwd * ZVwho(u) ZV char *u; ZV{ ZV struct passwd *pw; ZV long id; ZV char *ep; ZV ZV /* ZV * Translate user argument into a pw pointer. First, try to ZV * get it as specified. If that fails, try it as a number. ZV */ ZV if (pw = getpwnam(u)) ZV return(pw); ZV id = strtol(u, &ep, 10); ZV if (*u && !*ep && (pw = getpwuid(id))) ZV return(pw); ZV errx(1, "%s: No such user", u); ZV} ZV ZVvoid ZVusage() ZV{ ZV (void)fprintf(stderr, "usage: id [user]\n"); ZV (void)fprintf(stderr, " id -G [-n] [user]\n"); ZV (void)fprintf(stderr, " id -g [-nr] [user]\n"); ZV (void)fprintf(stderr, " id -u [-nr] [user]\n"); ZV exit(1); ZV} ZSHAR_EOF Zchmod 644 'id.c' Zfi Zif test -f 'Makefile' Zthen Z echo shar: "will not over-write existing file 'Makefile'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'Makefile' ZV# ZV# 1997/6/25 - Steven Schultz ZV# ZV# @(#)Makefile 1.0 (2.11BSD) 1997/6/25 ZV# ZVCFLAGS= -O ZVSEPFLAG= -i ZVSRCS= id.c ZVOBJS= id.o ZVMAN= id.0 groups.0 whoami.0 ZV ZV.SUFFIXES: .0 .1 ZV ZV.1.0: ZV /usr/man/manroff $*.1 > $@ ZV ZVall: id ${MAN} ZV ZVid: ${OBJS} ZV ${CC} ${CFLAGS} ${SEPFLAG} -o $@ ${OBJS} ZV ZVclean: ZV rm -f ${OBJS} ${MAN} id tags ZV ZVdepend: ${SRCS} ZV mkdep ${CFLAGS} ${SRCS} ZV ZVinstall: id ZV install -c -o bin -g bin -m 444 ${MAN} ${DESTDIR}/usr/man/cat1 ZV install -s -o root -g bin -m 755 id ${DESTDIR}/usr/bin/id ZV install -c -o bin -g bin -m 755 groups.sh ${DESTDIR}/usr/bin/groups ZV install -c -o bin -g bin -m 755 whoami.sh ${DESTDIR}/usr/bin/whoami ZV ZVlint: ${SRCS} ZV lint -hax ${SRCS} ZV ZVtags: ${SRCS} ZV ctags ${SRCS} ZV# DO NOT DELETE THIS LINE -- mkdep uses it. ZV# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. ZSHAR_EOF Zchmod 644 'Makefile' Zfi Zif test -f 'whoami.1' Zthen Z echo shar: "will not over-write existing file 'whoami.1'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'whoami.1' ZV.\" Copyright (c) 1991, 1993 ZV.\" The Regents of the University of California. All rights reserved. ZV.\" ZV.\" Redistribution and use in source and binary forms, with or without ZV.\" modification, are permitted provided that the following conditions ZV.\" are met: ZV.\" 1. Redistributions of source code must retain the above copyright ZV.\" notice, this list of conditions and the following disclaimer. ZV.\" 2. Redistributions in binary form must reproduce the above copyright ZV.\" notice, this list of conditions and the following disclaimer in the ZV.\" documentation and/or other materials provided with the distribution. ZV.\" 3. All advertising materials mentioning features or use of this software ZV.\" must display the following acknowledgement: ZV.\" This product includes software developed by the University of ZV.\" California, Berkeley and its contributors. ZV.\" 4. Neither the name of the University nor the names of its contributors ZV.\" may be used to endorse or promote products derived from this software ZV.\" without specific prior written permission. ZV.\" ZV.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV.\" SUCH DAMAGE. ZV.\" ZV.\" @(#)whoami.1 8.1.1 (2.11BSD) 1997/6/25 ZV.\" ZV.TH WHOAMI 1 "June 25, 1997" ZV.UC 4 ZV.SH NAME ZVwhoami \- display effective user id ZV.SH SYNOPSIS ZV.B whoami ZV.SH DESCRIPTION ZVThe ZV.B whoami ZVutility has been obsoleted by the ZVid(1) ZVutility, and is equivalent to ZV``\fBid \-un\fP''. ZVThe command ZV``\fBid \-p\fP'' ZVis suggested for normal interactive use. ZV.PP ZVThe ZV.B whoami ZVutility displays your effective user ID as a name. ZV.PP ZVThe ZV.B whoami ZVutility exits 0 on success, and >0 if an error occurs. ZV.SH SEE ALSO ZVid(1) ZSHAR_EOF Zchmod 644 'whoami.1' Zfi Zif test -f 'whoami.sh' Zthen Z echo shar: "will not over-write existing file 'whoami.sh'" Zelse Zsed 's/^V//' << \SHAR_EOF > 'whoami.sh' ZV#!/bin/sh - ZV# ZV# Copyright (c) 1991, 1993 ZV# The Regents of the University of California. All rights reserved. ZV# ZV# Redistribution and use in source and binary forms, with or without ZV# modification, are permitted provided that the following conditions ZV# are met: ZV# 1. Redistributions of source code must retain the above copyright ZV# notice, this list of conditions and the following disclaimer. ZV# 2. Redistributions in binary form must reproduce the above copyright ZV# notice, this list of conditions and the following disclaimer in the ZV# documentation and/or other materials provided with the distribution. ZV# 3. All advertising materials mentioning features or use of this software ZV# must display the following acknowledgement: ZV# This product includes software developed by the University of ZV# California, Berkeley and its contributors. ZV# 4. Neither the name of the University nor the names of its contributors ZV# may be used to endorse or promote products derived from this software ZV# without specific prior written permission. ZV# ZV# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ZV# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE ZV# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ZV# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE ZV# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL ZV# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS ZV# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ZV# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT ZV# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY ZV# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ZV# SUCH DAMAGE. ZV# ZV# @(#)whoami.sh 8.1 (Berkeley) 6/6/93 ZV# ZV ZVid -un ZSHAR_EOF Zchmod 644 'whoami.sh' Zfi Zchmod 755 . Zcd .. Zexit 0 Z# End of shell archive SHAR_EOF chmod 644 '375.shar' fi if test -f '375.rm' then echo shar: "will not over-write existing file '375.rm'" else sed 's/^Z//' << \SHAR_EOF > '375.rm' Zrm -f /usr/ucb/groups Zrm -f /usr/ucb/whoami Zrm -f /usr/src/man/man1/whoami.1 Zrm -f /usr/src/man/man1/groups.1 Zrm -f /usr/src/ucb/Mail/mail.1 Zrm -f /usr/src/ucb/whoami.c Zrm -f /usr/src/ucb/groups.c SHAR_EOF chmod 755 '375.rm' fi if test -f '375.patch' then echo shar: "will not over-write existing file '375.patch'" else sed 's/^Z//' << \SHAR_EOF > '375.patch' Z*** /usr/src/lib/libc/gen/Makefile.old Wed Mar 20 20:40:13 1996 Z--- /usr/src/lib/libc/gen/Makefile Fri Jun 27 19:46:46 1997 Z*************** Z*** 3,9 **** Z # All rights reserved. The Berkeley software License Agreement Z # specifies the terms and conditions for redistribution. Z # Z! # @(#)Makefile 5.7.6 (2.11BSD) 1996/03/20 Z # Z # Several routines have been rewritten in assembly language for the VAX and Z # the PDP. If you are not running on a VAX or PDP, you should use the Z--- 3,9 ---- Z # All rights reserved. The Berkeley software License Agreement Z # specifies the terms and conditions for redistribution. Z # Z! # @(#)Makefile 5.7.7 (2.11BSD) 1997/06/27 Z # Z # Several routines have been rewritten in assembly language for the VAX and Z # the PDP. If you are not running on a VAX or PDP, you should use the Z*************** Z*** 17,22 **** Z--- 17,23 ---- Z ctime.c ctype_.c daemon.c devname.c disklabel.c err.c \ Z execvp.c fakcu.c \ Z fstab.c gcvt.c getenv.c getgrent.c getgrgid.c getgrnam.c getlogin.c \ Z+ getgrouplist.c \ Z getpass.c getpwent.c getloadavg.c getmntinfo.c \ Z getttyent.c getttynam.c getusershell.c getwd.c \ Z initgroups.c isatty.c malloc.c mktemp.c ndbm.c nlist.c \ Z*************** Z*** 32,37 **** Z--- 33,39 ---- Z ctime.o ctype_.o daemon.o devname.o disklabel.o err.o \ Z execvp.o fakcu.o \ Z fstab.o gcvt.o getenv.o getgrent.o getgrgid.o getgrnam.o getlogin.o \ Z+ getgrouplist.o \ Z getpass.o getpwent.o getloadavg.o getmntinfo.o \ Z getttyent.o getttynam.o getusershell.o getwd.o \ Z initgroups.o isatty.o malloc.o mktemp.o ndbm.o nlist.o \ Z*** /usr/src/man/man1/Makefile.old Fri Mar 28 19:30:21 1997 Z--- /usr/src/man/man1/Makefile Fri Jun 27 20:19:13 1997 Z*************** Z*** 14,20 **** Z # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED Z # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. Z # Z! # @(#)Makefile 1.7 (2.11BSD) 1997/3/27 Z # Z MDIR= /usr/man/cat1 Z SRCS= adb.1 addbib.1 apply.1 apropos.1 as.1 at.1 atq.1 atrm.1 \ Z--- 14,20 ---- Z # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED Z # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. Z # Z! # @(#)Makefile 1.8 (2.11BSD) 1997/6/27 Z # Z MDIR= /usr/man/cat1 Z SRCS= adb.1 addbib.1 apply.1 apropos.1 as.1 at.1 atq.1 atrm.1 \ Z*************** Z*** 24,30 **** Z dd.1 deroff.1 df.1 diction.1 diff.1 diff3.1 du.1 echo.1 ed.1 \ Z efl.1 eqn.1 error.1 ex.1 expand.1 expr.1 f77.1 false.1 file.1 \ Z find.1 fmt.1 fold.1 fpr.1 from.1 fsplit.1 gcore.1 \ Z! graph.1 grep.1 groups.1 head.1 hostid.1 indent.1 \ Z intro.1 iostat.1 join.1 kill.1 last.1 lastcomm.1 ld.1 \ Z learn.1 leave.1 lex.1 lint.1 lisp.1 ln.1 logger.1 login.1 \ Z look.1 lookbib.1 lorder.1 lpq.1 lpr.1 lprm.1 lptest.1 ls.1 \ Z--- 24,30 ---- Z dd.1 deroff.1 df.1 diction.1 diff.1 diff3.1 du.1 echo.1 ed.1 \ Z efl.1 eqn.1 error.1 ex.1 expand.1 expr.1 f77.1 false.1 file.1 \ Z find.1 fmt.1 fold.1 fpr.1 from.1 fsplit.1 gcore.1 \ Z! graph.1 grep.1 head.1 hostid.1 indent.1 \ Z intro.1 iostat.1 join.1 kill.1 last.1 lastcomm.1 ld.1 \ Z learn.1 leave.1 lex.1 lint.1 lisp.1 ln.1 logger.1 login.1 \ Z look.1 lookbib.1 lorder.1 lpq.1 lpr.1 lprm.1 lptest.1 ls.1 \ Z*************** Z*** 43,49 **** Z tsort.1 tty.1 ul.1 unifdef.1 uniq.1 units.1 uptime.1 users.1 \ Z uucp.1 uuencode.1 uulog.1 uuname.1 uuq.1 uusend.1 uux.1 \ Z vacation.1 vgrind.1 vi.1 vmstat.1 vwidth.1 w.1 wait.1 wall.1 wc.1 \ Z! what.1 whatis.1 which.1 who.1 whoami.1 whois.1 window.1 \ Z write.1 xstr.1 yacc.1 yes.1 Z OBJS1= adb.0 addbib.0 apply.0 apropos.0 as.0 at.0 atq.0 atrm.0 \ Z awk.0 basename.0 bc.0 biff.0 binmail.0 cal.0 calendar.0 cat.0 \ Z--- 43,49 ---- Z tsort.1 tty.1 ul.1 unifdef.1 uniq.1 units.1 uptime.1 users.1 \ Z uucp.1 uuencode.1 uulog.1 uuname.1 uuq.1 uusend.1 uux.1 \ Z vacation.1 vgrind.1 vi.1 vmstat.1 vwidth.1 w.1 wait.1 wall.1 wc.1 \ Z! what.1 whatis.1 which.1 who.1 whois.1 window.1 \ Z write.1 xstr.1 yacc.1 yes.1 Z OBJS1= adb.0 addbib.0 apply.0 apropos.0 as.0 at.0 atq.0 atrm.0 \ Z awk.0 basename.0 bc.0 biff.0 binmail.0 cal.0 calendar.0 cat.0 \ Z*************** Z*** 52,58 **** Z dd.0 deroff.0 df.0 diction.0 diff.0 diff3.0 du.0 echo.0 ed.0 \ Z efl.0 eqn.0 error.0 ex.0 expand.0 expr.0 f77.0 false.0 file.0 \ Z find.0 fmt.0 fold.0 fpr.0 from.0 fsplit.0 gcore.0 \ Z! graph.0 grep.0 groups.0 head.0 hostid.0 indent.0 \ Z intro.0 iostat.0 join.0 kill.0 last.0 lastcomm.0 ld.0 \ Z learn.0 leave.0 lex.0 lint.0 lisp.0 ln.0 logger.0 login.0 \ Z look.0 lookbib.0 lorder.0 lpq.0 lpr.0 lprm.0 lptest.0 ls.0 \ Z--- 52,58 ---- Z dd.0 deroff.0 df.0 diction.0 diff.0 diff3.0 du.0 echo.0 ed.0 \ Z efl.0 eqn.0 error.0 ex.0 expand.0 expr.0 f77.0 false.0 file.0 \ Z find.0 fmt.0 fold.0 fpr.0 from.0 fsplit.0 gcore.0 \ Z! graph.0 grep.0 head.0 hostid.0 indent.0 \ Z intro.0 iostat.0 join.0 kill.0 last.0 lastcomm.0 ld.0 \ Z learn.0 leave.0 lex.0 lint.0 lisp.0 ln.0 logger.0 login.0 \ Z look.0 lookbib.0 lorder.0 lpq.0 lpr.0 lprm.0 lptest.0 ls.0 \ Z*************** Z*** 71,77 **** Z tsort.0 tty.0 ul.0 unifdef.0 uniq.0 units.0 uptime.0 users.0 \ Z uucp.0 uuencode.0 uulog.0 uuname.0 uuq.0 uusend.0 uux.0 \ Z vacation.0 vgrind.0 vi.0 vmstat.0 vwidth.0 w.0 wait.0 wall.0 wc.0 \ Z! what.0 whatis.0 which.0 who.0 whoami.0 whois.0 window.0 \ Z write.0 xstr.0 yacc.0 yes.0 Z Z .SUFFIXES: .1 .0 Z--- 71,77 ---- Z tsort.0 tty.0 ul.0 unifdef.0 uniq.0 units.0 uptime.0 users.0 \ Z uucp.0 uuencode.0 uulog.0 uuname.0 uuq.0 uusend.0 uux.0 \ Z vacation.0 vgrind.0 vi.0 vmstat.0 vwidth.0 w.0 wait.0 wall.0 wc.0 \ Z! what.0 whatis.0 which.0 who.0 whois.0 window.0 \ Z write.0 xstr.0 yacc.0 yes.0 Z Z .SUFFIXES: .1 .0 Z*** /usr/src/man/man3/Makefile.old Thu Mar 28 21:31:08 1996 Z--- /usr/src/man/man3/Makefile Fri Jun 27 19:48:56 1997 Z*************** Z*** 14,20 **** Z # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED Z # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. Z # Z! # @(#)Makefile 5.4.10 (2.11BSD) 1996/3/20 Z # Z MDIR= /usr/man/cat3 Z SRCS1= abort.3 abs.3 alarm.3 asinh.3 assert.3 atof.3 bstring.3 byteorder.3 \ Z--- 14,20 ---- Z # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED Z # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. Z # Z! # @(#)Makefile 5.4.11 (2.11BSD) 1997/6/27 Z # Z MDIR= /usr/man/cat3 Z SRCS1= abort.3 abs.3 alarm.3 asinh.3 assert.3 atof.3 bstring.3 byteorder.3 \ Z*************** Z*** 23,29 **** Z exp.3 fclose.3 ferror.3 floor.3 \ Z fopen.3 fread.3 frexp.3 fseek.3 getc.3 getdisk.3 getenv.3 getfsent.3 \ Z getgrent.3 gethostbyname.3 getlogin.3 getnetent.3 getopt.3 getpass.3 \ Z! getloadavg.3 getmntinfo.3 getsubopt.3 \ Z getprotoent.3 getpwent.3 gets.3 getservent.3 getttyent.3 \ Z getusershell.3 getwd.3 hypot.3 ieee.3 inet.3 infnan.3 initgroups.3 Z SRCS2= insque.3 intro.3 j0.3 l3tol.3 ldfps.3 lgamma.3 lib2648.3 \ Z--- 23,29 ---- Z exp.3 fclose.3 ferror.3 floor.3 \ Z fopen.3 fread.3 frexp.3 fseek.3 getc.3 getdisk.3 getenv.3 getfsent.3 \ Z getgrent.3 gethostbyname.3 getlogin.3 getnetent.3 getopt.3 getpass.3 \ Z! getgrouplist.3 getloadavg.3 getmntinfo.3 getsubopt.3 \ Z getprotoent.3 getpwent.3 gets.3 getservent.3 getttyent.3 \ Z getusershell.3 getwd.3 hypot.3 ieee.3 inet.3 infnan.3 initgroups.3 Z SRCS2= insque.3 intro.3 j0.3 l3tol.3 ldfps.3 lgamma.3 lib2648.3 \ Z*************** Z*** 45,51 **** Z fopen.0 fread.0 frexp.0 fseek.0 getc.0 getdisk.0 getenv.0 getfsent.0 \ Z getgrent.0 gethostbyname.0 getlogin.0 getnetent.0 getopt.0 getpass.0 \ Z getprotoent.0 getpwent.0 gets.0 getservent.0 getttyent.0 \ Z! getloadavg.0 getmntinfo.0 getsubopt.0 \ Z getusershell.0 getwd.0 hypot.0 ieee.0 inet.0 infnan.0 initgroups.0 Z OBJS2= insque.0 intro.0 j0.0 l3tol.0 ldfps.0 lgamma.0 lib2648.0 \ Z malloc.0 math.0 mktemp.0 monitor.0 mp.0 ndbm.0 nice.0 nlist.0 ns.0 \ Z--- 45,51 ---- Z fopen.0 fread.0 frexp.0 fseek.0 getc.0 getdisk.0 getenv.0 getfsent.0 \ Z getgrent.0 gethostbyname.0 getlogin.0 getnetent.0 getopt.0 getpass.0 \ Z getprotoent.0 getpwent.0 gets.0 getservent.0 getttyent.0 \ Z! getgrouplist.0 getloadavg.0 getmntinfo.0 getsubopt.0 \ Z getusershell.0 getwd.0 hypot.0 ieee.0 inet.0 infnan.0 initgroups.0 Z OBJS2= insque.0 intro.0 j0.0 l3tol.0 ldfps.0 lgamma.0 lib2648.0 \ Z malloc.0 math.0 mktemp.0 monitor.0 mp.0 ndbm.0 nice.0 nlist.0 ns.0 \ Z*** /usr/src/ucb/Makefile.old Wed Nov 27 21:33:34 1996 Z--- /usr/src/ucb/Makefile Fri Jun 27 19:50:46 1997 Z*************** Z*** 3,9 **** Z # All rights reserved. The Berkeley software License Agreement Z # specifies the terms and conditions for redistribution. Z # Z! # @(#)Makefile 5.17.3 (2.11BSD GTE) 1996/11/27 Z # Z DESTDIR= Z CFLAGS= -O Z--- 3,9 ---- Z # All rights reserved. The Berkeley software License Agreement Z # specifies the terms and conditions for redistribution. Z # Z! # @(#)Makefile 5.17.4 (2.11BSD GTE) 1997/6/27 Z # Z DESTDIR= Z CFLAGS= -O Z*************** Z*** 23,32 **** Z # explicit make lines. Z # Z STD= apply biff checknr colcrt colrm ctags expand fold \ Z! from gprof grep groups head last lastcomm leave logger mkstr \ Z printenv ruptime rwho sccs script soelim strings strcompact \ Z symcompact symdump symorder tail tcopy telnet unexpand unifdef users \ Z! whoami whois what wc xstr yes Z Z # C programs that live in the current directory and need explicit make lines. Z # Z--- 23,32 ---- Z # explicit make lines. Z # Z STD= apply biff checknr colcrt colrm ctags expand fold \ Z! from gprof grep head last lastcomm leave logger mkstr \ Z printenv ruptime rwho sccs script soelim strings strcompact \ Z symcompact symdump symorder tail tcopy telnet unexpand unifdef users \ Z! whois what wc xstr yes Z Z # C programs that live in the current directory and need explicit make lines. Z # Z*** /usr/src/usr.bin/Makefile.old Fri Jan 10 22:00:55 1997 Z--- /usr/src/usr.bin/Makefile Fri Jun 27 19:44:59 1997 Z*************** Z*** 1,4 **** Z! # Makefile 1.7 (2.11BSD GTE) 1997/1/10 Z # Z DESTDIR= Z CFLAGS= -O Z--- 1,4 ---- Z! # Makefile 1.8 (2.11BSD GTE) 1997/6/27 Z # Z DESTDIR= Z CFLAGS= -O Z*************** Z*** 6,12 **** Z Z # Programs that live in subdirectories, and have makefiles of their own. Z # Z! SUBDIR= at calendar dc diction diff3 eqn fstat f77 find graph learn lex lint \ Z m4 neqn plot printf prof ranlib ratfor refer roff spell struct tbl \ Z mkerrlst patch \ Z renice shar tip uucp uname whereis yacc xargs xinstall Z--- 6,13 ---- Z Z # Programs that live in subdirectories, and have makefiles of their own. Z # Z! SUBDIR= at calendar dc diction diff3 eqn fstat f77 find graph id learn Z! lex lint \ Z m4 neqn plot printf prof ranlib ratfor refer roff spell struct tbl \ Z mkerrlst patch \ Z renice shar tip uucp uname whereis yacc xargs xinstall Z*** /VERSION.old Sat May 31 16:40:01 1997 Z--- /VERSION Fri Jun 27 20:24:54 1997 Z*************** Z*** 1,5 **** Z! Current Patch Level: 374 Z! Date: May 31, 1997 Z Z 2.11 BSD Z ============ Z--- 1,5 ---- Z! Current Patch Level: 375 Z! Date: June 27, 1997 Z Z 2.11 BSD Z ============ SHAR_EOF chmod 644 '375.patch' fi exit 0 # End of shell archive