Initial import from FreeBSD RELENG_4:
[games.git] / share / man / man5 / passwd.5
1 .\" Copyright (c) 1988, 1991, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. All advertising materials mentioning features or use of this software
13 .\"    must display the following acknowledgement:
14 .\"     This product includes software developed by the University of
15 .\"     California, Berkeley and its contributors.
16 .\" 4. Neither the name of the University nor the names of its contributors
17 .\"    may be used to endorse or promote products derived from this software
18 .\"    without specific prior written permission.
19 .\"
20 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 .\" SUCH DAMAGE.
31 .\"
32 .\"     From: @(#)passwd.5      8.1 (Berkeley) 6/5/93
33 .\" $FreeBSD: src/share/man/man5/passwd.5,v 1.26.2.5 2002/02/01 15:51:18 ru Exp $
34 .\"
35 .Dd September 29, 1994
36 .Dt PASSWD 5
37 .Os
38 .Sh NAME
39 .Nm passwd
40 .Nd format of the password file
41 .Sh DESCRIPTION
42 The
43 .Nm
44 files are files consisting of newline separated records, one per user,
45 containing ten colon
46 .Pq Ql \&:
47 separated fields.  These fields are as
48 follows:
49 .Pp
50 .Bl -tag -width password -offset indent
51 .It name
52 User's login name.
53 .It password
54 User's
55 .Em encrypted
56 password.
57 .It uid
58 User's id.
59 .It gid
60 User's login group id.
61 .It class
62 User's login class.
63 .It change
64 Password change time.
65 .It expire
66 Account expiration time.
67 .It gecos
68 General information about the user.
69 .It home_dir
70 User's home directory.
71 .It shell
72 User's login shell.
73 .El
74 .Pp
75 Lines whose first non-whitespace character is a pound-sign (#)
76 are comments, and are ignored.  Blank lines which consist
77 only of spaces, tabs or newlines are also ignored.
78 .Pp
79 The
80 .Ar name
81 field is the login used to access the computer account, and the
82 .Ar uid
83 field is the number associated with it.  They should both be unique
84 across the system (and often across a group of systems) since they
85 control file access.
86 .Pp
87 While it is possible to have multiple entries with identical login names
88 and/or identical uids, it is usually a mistake to do so.  Routines
89 that manipulate these files will often return only one of the multiple
90 entries, and that one by random selection.
91 .Pp
92 The login name must never begin with a hyphen
93 .Pq Ql \&- ;
94 also, it is strongly
95 suggested that neither upper-case characters nor dots
96 .Pq Ql \&.
97 be part
98 of the name, as this tends to confuse mailers.
99 .Pp
100 The password field is the
101 .Em encrypted
102 form of the password.
103 If the
104 .Ar password
105 field is empty, no password will be required to gain access to the
106 machine.  This is almost invariably a mistake.
107 Because these files contain the encrypted user passwords, they should
108 not be readable by anyone without appropriate privileges.
109 Administrative accounts have a password field containing an asterisk
110 .Ql \&*
111 which disallows normal logins.
112 .Pp
113 The group field is the group that the user will be placed in upon login.
114 Although this system supports multiple groups (see
115 .Xr groups 1 )
116 this field indicates the user's primary group.
117 Secondary group memberships are selected in
118 .Pa /etc/group .
119 .Pp
120 The
121 .Ar class
122 field is a key for a user's login class.
123 Login classes are defined in
124 .Xr login.conf 5 ,
125 which is a
126 .Xr termcap 5
127 style database of user attributes, accounting, resource and
128 environment settings.
129 .Pp
130 The
131 .Ar change
132 field is the number in seconds,
133 .Dv GMT ,
134 from the epoch, until the
135 password for the account must be changed.
136 This field may be left empty or set to 0 to turn off the
137 password aging feature.
138 .Pp
139 The
140 .Ar expire
141 field is the number in seconds,
142 .Dv GMT ,
143 from the epoch, until the
144 account expires.
145 This field may be left empty or set to 0 to turn off the account
146 aging feature.
147 .Pp
148 The
149 .Ar gecos
150 field normally contains comma
151 .Pq Ql \&,
152 separated subfields as follows:
153 .Pp
154 .Bl -bullet -compact -offset indent
155 .It
156 user's full name
157 .It
158 user's office location
159 .It
160 user's work phone number
161 .It
162 user's home phone number
163 .El
164 .Pp
165 This information is used by the
166 .Xr finger 1
167 program, and the first field used by the system mailer.
168 If an ampersand
169 .Pq Ql \&&
170 character appears within the fullname field, programs that
171 use this field will substitute it with a capitalized version
172 of the account's login name.
173 .Pp
174 The user's home directory is the full
175 .Tn UNIX
176 path name where the user
177 will be placed on login.
178 .Pp
179 The shell field is the command interpreter the user prefers.
180 If there is nothing in the
181 .Ar shell
182 field, the Bourne shell
183 .Pq Pa /bin/sh
184 is assumed.
185 For security reasons, if the shell is set to a script that disallows
186 access to the system (the
187 .Xr nologin 8
188 script, for example), care should be taken not to import any environment
189 variables.  With
190 .Xr sh 1 ,
191 this can be done by specifying the
192 .Fl p
193 flag.
194 Check the specific shell documentation to determine how this is
195 done with other shells.
196 .Sh YP/NIS INTERACTION
197 .Ss Enabling access to NIS passwd data
198 The system administrator can configure
199 .Tn FreeBSD
200 to use NIS/YP for
201 its password information by adding special records to the
202 .Pa /etc/master.passwd
203 file.
204 These entries should be added with
205 .Xr vipw 8
206 so that the changes can be properly merged with the hashed
207 password databases and the
208 .Pa /etc/passwd
209 file (
210 .Pa /etc/passwd
211 should never be edited manually). Alternatively, the administrator
212 can modify
213 .Pa /etc/master.passwd
214 in some other way and then manually update the password databases with
215 .Xr pwd_mkdb 8 .
216 .Pp
217 The simplest way to activate NIS is to add an empty record
218 with only a plus sign
219 .Pq Ql \&+
220 in the name field, such as this:
221 .Bd -literal -offset indent
222 +:::::::::
223
224 .Ed
225 The
226 .Ql \&+
227 will tell the
228 .Xr getpwent 3
229 routines in
230 .Tn FreeBSD Ns 's
231 standard C library to begin using the NIS passwd maps
232 for lookups.
233 .Pp
234 Note that the entry shown above is known as a
235 .Em wildcard
236 entry, because it matches all users (the
237 .Ql \&+
238 without any other information
239 matches everybody) and allows all NIS password data to be retrieved
240 unaltered.
241 However, by
242 specifying a username or netgroup next to the
243 .Ql \&+
244 in the NIS
245 entry, the administrator can affect what data are extracted from the
246 NIS passwd maps and how it is interpreted.
247 Here are a few example
248 records that illustrate this feature (note that you can have several
249 NIS entries in a single
250 .Pa master.passwd
251 file):
252 .Bd -literal -offset indent
253 -mitnick:::::::::
254 +@staff:::::::::
255 +@permitted-users:::::::::
256 +dennis:::::::::
257 +ken:::::::::/bin/csh
258 +@rejected-users::32767:32767::::::/bin/false
259
260 .Ed
261 Specific usernames are listed explicitly while netgroups are signified
262 by a preceding
263 .Ql \&@ .
264 In the above example, users in the
265 .Dq staff
266 and
267 .Dq permitted-users
268 netgroups will have their password information
269 read from NIS and used unaltered.
270 In other words, they will be allowed
271 normal access to the machine.
272 Users
273 .Dq ken
274 and
275 .Dq dennis ,
276 who have
277 been named explicitly rather than through a netgroup, will also have
278 their password data read from NIS,
279 .Em except
280 that user
281 .Dq ken
282 will have his shell remapped to
283 .Pa /bin/csh .
284 This means that value for his shell specified in the NIS password map
285 will be overridden by the value specified in the special NIS entry in
286 the local
287 .Pa master.passwd
288 file.
289 User
290 .Dq ken
291 may have been assigned the csh shell because his
292 NIS password entry specified a different shell that may not be
293 installed on the client machine for political or technical reasons.
294 Meanwhile, users in the
295 .Dq rejected-users
296 netgroup are prevented
297 from logging in because their UIDs, GIDs and shells have been overridden
298 with invalid values.
299 .Pp
300 User
301 .Dq mitnick
302 will be be ignored entirely because his entry is
303 specified with a
304 .Ql \&-
305 instead of a
306 .Ql \&+ .
307 A minus entry can be used
308 to block out certain NIS password entries completely; users whose
309 password data has been excluded in this way are not recognized by
310 the system at all.
311 (Any overrides specified with minus entries are
312 also ignored since there is no point in processing override information
313 for a user that the system isn't going to recognize in the first place.)
314 In general, a minus entry is used to specifically exclude a user
315 who might otherwise be granted access because he happens to be a
316 member of an authorized netgroup.
317 For example, if
318 .Dq mitnick
319 is
320 a member of the
321 .Dq permitted-users
322 netgroup and must, for whatever
323 the reason, be permitted to remain in that netgroup (possibly to
324 retain access to other machines within the domain), the administrator
325 can still deny him access to a particular system with a minus entry.
326 Also, it is sometimes easier to explicitly list those users who are not
327 allowed access rather than generate a possibly complicated list of
328 users who are allowed access and omit the rest.
329 .Pp
330 Note that the plus and minus entries are evaluated in order from
331 first to last with the first match taking precedence.
332 This means
333 the system will only use the first entry that matches a particular user.
334 If, using the same example, there is a user
335 .Dq foo
336 who is a member of both the
337 .Dq staff
338 netgroup and the
339 .Dq rejected-users
340 netgroup, he will be admitted to
341 the system because the above example lists the entry for
342 .Dq staff
343 before the entry for
344 .Dq rejected-users .
345 If the order were reversed,
346 user
347 .Dq foo
348 would be flagged as a
349 .Dq rejected-user
350 instead and denied access.
351 .Pp
352 Lastly, any NIS password database records that do not match against
353 at least one of the users or netgroups specified by the NIS access
354 entries in the
355 .Pa /etc/master.passwd
356 file will be ignored (along with any users specified using minus
357 entries). In our example shown above, we do not have a wildcard
358 entry at the end of the list; therefore, the system will not recognize
359 anyone except
360 .Dq ken ,
361 .Dq dennis ,
362 the
363 .Dq staff
364 netgroup, and the
365 .Dq permitted-users
366 netgroup as authorized users.
367 The
368 .Dq rejected-users
369 netgroup will
370 be recognized but all members will have their shells remapped and
371 therefore be denied access.
372 All other NIS password records
373 will be ignored.
374 The administrator may add a wildcard entry to the
375 end of the list such as:
376 .Bd -literal -offset indent
377 +:::::::::/sbin/nologin
378
379 .Ed
380 This entry acts as a catch-all for all users that don't match against
381 any of the other entries.
382 This technique is sometimes useful when it is
383 desirable to have the system be able to recognize all users in a
384 particular NIS domain without necessarily granting them login access.
385 See the description of the shell field regarding security concerns when using
386 a shell script as the login shell.
387 .Pp
388 The primary use of this
389 .Pa override
390 feature is to permit the administrator
391 to enforce access restrictions on NIS client systems.
392 Users can be
393 granted access to one group of machines and denied access to other
394 machines simply by adding or removing them from a particular netgroup.
395 Since the netgroup database can also be accessed via NIS, this allows
396 access restrictions to be administered from a single location, namely
397 the NIS master server; once a host's access list has been set in
398 .Pa /etc/master.passwd ,
399 it need not be modified again unless new netgroups are created.
400 .Sh NOTES
401 .Ss Shadow passwords through NIS
402 .Tn FreeBSD
403 uses a shadow password scheme: users' encrypted passwords
404 are stored only in
405 .Pa /etc/master.passwd
406 and
407 .Pa /etc/spwd.db ,
408 which are readable and writable only by the superuser.
409 This is done
410 to prevent users from running the encrypted passwords through
411 password-guessing programs and gaining unauthorized access to
412 other users' accounts.
413 NIS does not support a standard means of
414 password shadowing, which implies that placing your password data
415 into the NIS passwd maps totally defeats the security of
416 .Tn FreeBSD Ns 's
417 password shadowing system.
418 .Pp
419 .Tn FreeBSD
420 provides a few special features to help get around this
421 problem.
422 It is possible to implement password shadowing between
423 .Tn FreeBSD
424 NIS clients and
425 .Tn FreeBSD
426 NIS servers.
427 The
428 .Xr getpwent 3
429 routines will search for a
430 .Pa master.passwd.byname
431 and
432 .Pa master.passwd.byuid
433 maps which should contain the same data found in the
434 .Pa /etc/master.passwd
435 file.
436 If the maps exist,
437 .Tn FreeBSD
438 will attempt to use them for user
439 authentication instead of the standard
440 .Pa passwd.byname
441 and
442 .Pa passwd.byuid
443 maps.
444 .Tn FreeBSD Ns 's
445 .Xr ypserv 8
446 will also check client requests to make sure they originate on a
447 privileged port.
448 Since only the superuser is allowed to bind to
449 a privileged port, the server can tell if the requesting user
450 is the superuser; all requests from non-privileged users to access
451 the
452 .Pa master.passwd
453 maps will be refused.
454 Since all user authentication programs run
455 with superuser privilege, they should have the required access to
456 users' encrypted password data while normal users will only
457 be allowed access to the standard
458 .Pa passwd
459 maps which contain no password information.
460 .Pp
461 Note that this feature cannot be used in an environment with
462 .No non- Ns Tn FreeBSD
463 systems.
464 Note also that a truly determined user with
465 unrestricted access to your network could still compromise the
466 .Pa master.passwd
467 maps.
468 .Ss UID and GID remapping with NIS overrides
469 Unlike
470 .Tn SunOS
471 and other operating systems that use Sun's NIS code,
472 .Tn FreeBSD
473 allows the user to override
474 .Pa all
475 of the fields in a user's NIS
476 .Pa passwd
477 entry.
478 For example, consider the following
479 .Pa /etc/master.passwd
480 entry:
481 .Bd -literal -offset indent
482 +@foo-users:???:666:666:0:0:0:Bogus user:/home/bogus:/bin/bogus
483
484 .Ed
485 This entry will cause all users in the `foo-users' netgroup to
486 have
487 .Pa all
488 of their password information overridden, including UIDs,
489 GIDs and passwords.
490 The result is that all `foo-users' will be
491 locked out of the system, since their passwords will be remapped
492 to invalid values.
493 .Pp
494 This is important to remember because most people are accustomed to
495 using an NIS wildcard entry that looks like this:
496 .Bd -literal -offset indent
497 +:*:0:0:::
498
499 .Ed
500 This often leads to new
501 .Tn FreeBSD
502 administrators choosing NIS entries for their
503 .Pa master.passwd
504 files that look like this:
505 .Bd -literal -offset indent
506 +:*:0:0::::::
507
508 .Ed
509 Or worse, this
510 .Bd -literal -offset indent
511 +::0:0::::::
512
513 .Ed
514 .Sy DO _NOT_ PUT ENTRIES LIKE THIS IN YOUR
515 .Pa master.passwd
516 .Sy FILE!!
517 The first tells
518 .Tn FreeBSD
519 to remap all passwords to
520 .Ql \&*
521 (which
522 will prevent anybody from logging in) and to remap all UIDs and GIDs
523 to 0 (which will make everybody appear to be the superuser). The
524 second case just maps all UIDs and GIDs to 0, which means that
525 all users will appear to be root!
526 .Pp
527 .Ss Compatibility of NIS override evaluation
528 When Sun originally added NIS support to their
529 .Xr getpwent 3
530 routines, they took into account the fact that the
531 .Tn SunOS
532 password
533 .Pa /etc/passwd
534 file is in plain
535 .Tn ASCII
536 format.
537 The
538 .Tn SunOS
539 documentation claims that
540 adding a
541 .Ql \&+
542 entry to the password file causes the contents of
543 the NIS password database to be
544 .Dq inserted
545 at the position in the file where the
546 .Ql \&+
547 entry appears.
548 If, for example, the
549 administrator places a
550 .Ql \&+::::::
551 entry in the middle of
552 .Pa /etc/passwd ,
553 then the entire contents of the NIS password map would appear
554 as though it had been copied into the middle of the password
555 file.
556 If the administrator places
557 .Ql \&+::::::
558 entries at both the middle and the end of
559 .Pa /etc/passwd ,
560 then the NIS password map would appear twice: once in the middle
561 of the file and once at the end.
562 (By using override entries
563 instead of simple wildcards, other combinations could be achieved.)
564 .Pp
565 By contrast,
566 .Fx
567 does not have a single
568 .Tn ASCII
569 password file: it
570 has a hashed password database.
571 This database does not have an
572 easily-defined beginning, middle or end, which makes it very hard
573 to design a scheme that is 100% compatible with
574 .Tn SunOS .
575 For example,
576 the
577 .Fn getpwnam
578 and
579 .Fn getpwuid
580 functions in
581 .Tn FreeBSD
582 are designed to do direct queries to the
583 hash database rather than a linear search.
584 This approach is faster
585 on systems where the password database is large.
586 However, when
587 using direct database queries, the system does not know or care
588 about the order of the original password file, and therefore
589 it cannot easily apply the same override logic used by
590 .Tn SunOS .
591 .Pp
592 Instead,
593 .Tn FreeBSD
594 groups all the NIS override entries together
595 and constructs a filter out of them.
596 Each NIS password entry
597 is compared against the override filter exactly once and
598 treated accordingly: if the filter allows the entry through
599 unaltered, it's treated unaltered; if the filter calls for remapping
600 of fields, then fields are remapped; if the filter calls for
601 explicit exclusion (i.e., the entry matches a
602 .Ql \&-
603 override), the entry is ignored; if the entry doesn't match against any
604 of the filter specifications, it's discarded.
605 .Pp
606 Again, note that the NIS
607 .Ql \&+
608 and
609 .Ql \&-
610 entries themselves are handled in the order in which they were specified
611 in the
612 .Pa /etc/master.passwd
613 file, since doing otherwise would lead to unpredictable behavior.
614 .Pp
615 The end result is that
616 .Tn FreeBSD Ns 's
617 provides a very close approximation
618 of
619 .Tn SunOS Ns 's
620 behavior while maintaining the database paradigm, though the
621 .Xr getpwent 3
622 functions do behave somewhat differently from their
623 .Tn SunOS
624 counterparts.
625 The primary differences are:
626 .Bl -bullet -offset indent
627 .It
628 Each NIS password map record can be mapped into the password
629 local password space only once.
630 .It
631 The placement of the NIS
632 .Ql \&+
633 and
634 .Ql \&-
635 entries does not necessarily
636 affect where NIS password records will be mapped into
637 the password space.
638 .El
639 .Pp
640 In 99% of all
641 .Tn FreeBSD
642 configurations, NIS client behavior will be
643 indistinguishable from that of
644 .Tn SunOS
645 or other similar systems.
646 Even
647 so, users should be aware of these architectural differences.
648 .Pp
649 .Ss Using groups instead of netgroups for NIS overrides
650 .Tn FreeBSD
651 offers the capability to do override matching based on
652 user groups rather than netgroups.
653 If, for example, an NIS entry
654 is specified as:
655 .Bd -literal -offset indent
656 +@operator:::::::::
657
658 .Ed
659 the system will first try to match users against a netgroup called
660 .Ql operator .
661 If an
662 .Ql operator
663 netgroup doesn't exist, the system
664 will try to match users against the normal
665 .Ql operator
666 group instead.
667 .Ss Changes in behavior from older versions of FreeBSD
668 There have been several bug fixes and improvements in
669 .Tn FreeBSD Ns 's
670 NIS/YP handling, some of which have caused changes in behavior.
671 While the behavior changes are generally positive, it is important
672 that users and system administrators be aware of them:
673 .Bl -enum -offset indent
674 .It
675 In versions prior to 2.0.5, reverse lookups (i.e. using
676 .Fn getpwuid )
677 would not have overrides applied, which is to say that it
678 was possible for
679 .Fn getpwuid
680 to return a login name that
681 .Fn getpwnam
682 would not recognize.
683 This has been fixed: overrides specified
684 in
685 .Pa /etc/master.passwd
686 now apply to all
687 .Xr getpwent 3
688 functions.
689 .It
690 Prior to
691 .Fx 2.0.5 ,
692 netgroup overrides did not work at
693 all, largely because
694 .Tn FreeBSD
695 did not have support for reading
696 netgroups through NIS.
697 Again, this has been fixed, and
698 netgroups can be specified just as in
699 .Tn SunOS
700 and similar NIS-capable
701 systems.
702 .It
703 .Tn FreeBSD
704 now has NIS server capabilities and supports the use
705 of
706 .Pa master.passwd
707 NIS maps in addition to the standard Sixth Edition format
708 .Pa passwd
709 maps.
710 This means that you can specify change, expiration and class
711 information through NIS, provided you use a
712 .Tn FreeBSD
713 system as
714 the NIS server.
715 .El
716 .Sh FILES
717 .Bl -tag -width /etc/master.passwd -compact
718 .It Pa /etc/passwd
719 .Tn ASCII
720 password file, with passwords removed
721 .It Pa /etc/pwd.db
722 .Xr db 3 -format
723 password database, with passwords removed
724 .It Pa /etc/master.passwd
725 .Tn ASCII
726 password file, with passwords intact
727 .It Pa /etc/spwd.db
728 .Xr db 3 -format
729 password database, with passwords intact
730 .El
731 .Sh SEE ALSO
732 .Xr chpass 1 ,
733 .Xr login 1 ,
734 .Xr passwd 1 ,
735 .Xr getpwent 3 ,
736 .Xr login_getclass 3 ,
737 .Xr login.conf 5 ,
738 .Xr adduser 8 ,
739 .Xr pw 8 ,
740 .Xr pwd_mkdb 8 ,
741 .Xr vipw 8 ,
742 .Xr yp 8
743 .Sh BUGS
744 User information should (and eventually will) be stored elsewhere.
745 .Pp
746 The YP/NIS password database makes encrypted passwords visible to
747 ordinary users, thus making password cracking easier unless you use
748 shadow passwords with the
749 .Pa master.passwd
750 maps and
751 .Tn FreeBSD Ns 's
752 .Xr ypserv 8
753 server.
754 .Pp
755 Unless you're using
756 .Tn FreeBSD Ns 's
757 .Xr ypserv 8 ,
758 which supports the use of
759 .Pa master.passwd
760 type maps,
761 the YP/NIS password database will be in old-style (Sixth Edition) format,
762 which means that site-wide values for user login class, password
763 expiration date, and other fields present in the current format
764 will not be available when a
765 .Tn FreeBSD
766 system is used as a client with
767 a standard NIS server.
768 .Sh COMPATIBILITY
769 The password file format has changed since
770 .Bx 4.3 .
771 The following awk script can be used to convert your old-style password
772 file into a new style password file.
773 The additional fields
774 .Dq class ,
775 .Dq change
776 and
777 .Dq expire
778 are added, but are turned off by default.
779 These fields can then be set using
780 .Xr vipw 8
781 or
782 .Xr pw 8 .
783 .Bd -literal -offset indent
784 BEGIN { FS = ":"}
785 { print $1 ":" $2 ":" $3 ":" $4 "::0:0:" $5 ":" $6 ":" $7 }
786 .Ed
787 .Sh HISTORY
788 A
789 .Nm
790 file format appeared in
791 .At v6 .
792 The YP/NIS functionality is modeled after
793 .Tn SunOS
794 and first appeared in
795 .Fx 1.1
796 The override capability is new in
797 .Fx 2.0 .
798 The override capability was updated to properly support netgroups
799 in
800 .Fx 2.0.5 .
801 Support for comments first appeared in
802 .Fx 3.0 .