]> git.ipfire.org Git - thirdparty/util-linux.git/blob - login-utils/chfn.1
hwclock: free temporary variable before return
[thirdparty/util-linux.git] / login-utils / chfn.1
1 .\"
2 .\" chfn.1 -- change your finger information
3 .\" (c) 1994 by salvatore valente <svalente@athena.mit.edu>
4 .\"
5 .\" This program is free software. You can redistribute it and
6 .\" modify it under the terms of the GNU General Public License.
7 .\" There is no warranty.
8 .\"
9 .TH CHFN 1 "November 2015" "util-linux" "User Commands"
10 .SH NAME
11 chfn \- change your finger information
12 .SH SYNOPSIS
13 .B chfn
14 .RB [ \-f
15 .IR full-name ]
16 .RB [ \-o
17 .IR office ]
18 .RB [ \-p
19 .IR office-phone ]
20 .RB [ \-h
21 .IR home-phone ]
22 .RB [ \-u ]
23 .RB [ \-v ]
24 .RI [ username ]
25 .SH DESCRIPTION
26 .B chfn
27 is used to change your finger information. This information is
28 stored in the
29 .I /etc/passwd
30 file, and is displayed by the
31 .B finger
32 program. The Linux
33 .B finger
34 command will display four pieces of information that can be changed by
35 .BR chfn :
36 your real name, your work room and phone, and your home phone.
37 .PP
38 Any of the four pieces of information can be specified on the command
39 line. If no information is given on the command line,
40 .B chfn
41 enters interactive mode.
42 .PP
43 In interactive mode,
44 .B chfn
45 will prompt for each field. At a prompt, you can enter the new information,
46 or just press return to leave the field unchanged. Enter the keyword
47 "none" to make the field blank.
48 .PP
49 .B chfn
50 supports non-local entries (kerberos, LDAP, etc.\&) if linked with libuser,
51 otherwise use \fBypchfn\fR, \fBlchfn\fR or any other implementation for
52 non-local entries.
53 .SH OPTIONS
54 .TP
55 .BR \-f , " \-\-full\-name " \fIfull-name
56 Specify your real name.
57 .TP
58 .BR \-o , " \-\-office " \fIoffice
59 Specify your office room number.
60 .TP
61 .BR \-p , " \-\-office\-phone " \fIoffice-phone
62 Specify your office phone number.
63 .TP
64 .BR \-h , " \-\-home\-phone " \fIhome-phone
65 Specify your home phone number.
66 .TP
67 .BR \-u , " \-\-help"
68 Display help text and exit.
69 .TP
70 .BR \-v , " \-\-version"
71 Display version information and exit.
72 .SH CONFIG FILE ITEMS
73 .B chfn
74 reads the
75 .IR /etc\:/login.defs (5)
76 configuration file. Note that the configuration file could be
77 distributed with another package (e.g. shadow-utils). The following
78 configuration items are relevant for
79 .BR chfn (1):
80 .PP
81 .BI CHFN_RESTRICT " string"
82 .RS 4
83 Indicate which fields are changeable by \fBchfn\fR.
84
85 The boolean setting \fB"yes"\fR means that only the Office, Office Phone and
86 Home Phone fields are changeable, and boolean setting \fB"no"\fR means that
87 also the Full Name is changeable.
88
89 Another way to specify changeable fields is by abbreviations: f = Full Name,
90 r = Office (room), w = Office (work) Phone, h = Home Phone. For example,
91 \fBCHFN_RESTRICT "wh"\fR allows changing work and home phone numbers.
92
93 If CHFN_RESTRICT is undefined, then all finger information is read-only.
94 This is the default.
95 .RE
96 .PP
97 .SH "EXIT STATUS"
98 Returns 0 if operation was successful, 1 if operation failed or command syntax was not valid.
99 .SH "SEE ALSO"
100 .BR chsh (1),
101 .BR finger (1),
102 .BR login.defs (5),
103 .BR passwd (5)
104 .SH AUTHOR
105 Salvatore Valente <svalente@mit.edu>
106 .SH AVAILABILITY
107 The chfn command is part of the util-linux package and is available from
108 https://www.kernel.org/pub/linux/utils/util-linux/.