source: branches/samba-3.2.x/docs/manpages/smbpasswd.8@ 202

Last change on this file since 202 was 201, checked in by Herwig Bauernfeind, 17 years ago

Update to Samba 3.2.3

File size: 12.7 KB
Line 
1.\" Title: smbpasswd
2.\" Author:
3.\" Generator: DocBook XSL Stylesheets v1.73.1 <http://docbook.sf.net/>
4.\" Date: 08/27/2008
5.\" Manual: System Administration tools
6.\" Source: Samba 3.2
7.\"
8.TH "SMBPASSWD" "8" "08/27/2008" "Samba 3\.2" "System Administration tools"
9.\" disable hyphenation
10.nh
11.\" disable justification (adjust text to left margin only)
12.ad l
13.SH "NAME"
14smbpasswd - change a user's SMB password
15.SH "SYNOPSIS"
16.HP 1
17smbpasswd [\-a] [\-c\ <config\ file>] [\-x] [\-d] [\-e] [\-D\ debuglevel] [\-n] [\-r\ <remote\ machine>] [\-R\ <name\ resolve\ order>] [\-m] [\-U\ username[%password]] [\-h] [\-s] [\-w\ pass] [\-W] [\-i] [\-L] [username]
18.SH "DESCRIPTION"
19.PP
20This tool is part of the
21\fBsamba\fR(7)
22suite\.
23.PP
24The smbpasswd program has several different functions, depending on whether it is run by the
25\fIroot\fR
26user or not\. When run as a normal user it allows the user to change the password used for their SMB sessions on any machines that store SMB passwords\.
27.PP
28By default (when run with no arguments) it will attempt to change the current user\'s SMB password on the local machine\. This is similar to the way the
29passwd(1)
30program works\.
31smbpasswd
32differs from how the passwd program works however in that it is not
33\fIsetuid root\fR
34but works in a client\-server mode and communicates with a locally running
35\fBsmbd\fR(8)\. As a consequence in order for this to succeed the smbd daemon must be running on the local machine\. On a UNIX machine the encrypted SMB passwords are usually stored in the
36\fBsmbpasswd\fR(5)
37file\.
38.PP
39When run by an ordinary user with no options, smbpasswd will prompt them for their old SMB password and then ask them for their new password twice, to ensure that the new password was typed correctly\. No passwords will be echoed on the screen whilst being typed\. If you have a blank SMB password (specified by the string "NO PASSWORD" in the smbpasswd file) then just press the <Enter> key when asked for your old password\.
40.PP
41smbpasswd can also be used by a normal user to change their SMB password on remote machines, such as Windows NT Primary Domain Controllers\. See the (\fI\-r\fR) and
42\fI\-U\fR
43options below\.
44.PP
45When run by root, smbpasswd allows new users to be added and deleted in the smbpasswd file, as well as allows changes to the attributes of the user in this file to be made\. When run by root,
46smbpasswd
47accesses the local smbpasswd file directly, thus enabling changes to be made even if smbd is not running\.
48.SH "OPTIONS"
49.PP
50\-a
51.RS 4
52This option specifies that the username following should be added to the local smbpasswd file, with the new password typed (type <Enter> for the old password)\. This option is ignored if the username following already exists in the smbpasswd file and it is treated like a regular change password command\. Note that the default passdb backends require the user to already exist in the system password file (usually
53\fI/etc/passwd\fR), else the request to add the user will fail\.
54.sp
55This option is only available when running smbpasswd as root\.
56.RE
57.PP
58\-c
59.RS 4
60This option can be used to specify the path and file name of the
61\fIsmb\.conf\fR
62configuration file when it is important to use other than the default file and / or location\.
63.RE
64.PP
65\-x
66.RS 4
67This option specifies that the username following should be deleted from the local smbpasswd file\.
68.sp
69This option is only available when running smbpasswd as root\.
70.RE
71.PP
72\-d
73.RS 4
74This option specifies that the username following should be
75\fBdisabled\fR
76in the local smbpasswd file\. This is done by writing a
77\fB\'D\'\fR
78flag into the account control space in the smbpasswd file\. Once this is done all attempts to authenticate via SMB using this username will fail\.
79.sp
80If the smbpasswd file is in the \'old\' format (pre\-Samba 2\.0 format) there is no space in the user\'s password entry to write this information and the command will FAIL\. See
81\fBsmbpasswd\fR(5)
82for details on the \'old\' and new password file formats\.
83.sp
84This option is only available when running smbpasswd as root\.
85.RE
86.PP
87\-e
88.RS 4
89This option specifies that the username following should be
90\fBenabled\fR
91in the local smbpasswd file, if the account was previously disabled\. If the account was not disabled this option has no effect\. Once the account is enabled then the user will be able to authenticate via SMB once again\.
92.sp
93If the smbpasswd file is in the \'old\' format, then
94smbpasswd
95will FAIL to enable the account\. See
96\fBsmbpasswd\fR(5)
97for details on the \'old\' and new password file formats\.
98.sp
99This option is only available when running smbpasswd as root\.
100.RE
101.PP
102\-D debuglevel
103.RS 4
104\fIdebuglevel\fR
105is an integer from 0 to 10\. The default value if this parameter is not specified is zero\.
106.sp
107The higher this value, the more detail will be logged to the log files about the activities of smbpasswd\. At level 0, only critical errors and serious warnings will be logged\.
108.sp
109Levels above 1 will generate considerable amounts of log data, and should only be used when investigating a problem\. Levels above 3 are designed for use only by developers and generate HUGE amounts of log data, most of which is extremely cryptic\.
110.RE
111.PP
112\-n
113.RS 4