]> granicus.if.org Git - apache/blob - docs/manual/programs/dbmmanage.html.en
update transformation
[apache] / docs / manual / programs / dbmmanage.html.en
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
4         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
5               This file is generated from xml source: DO NOT EDIT
6         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
7       -->
8 <title>dbmmanage - Manage user authentication files in DBM format - Apache HTTP Server</title>
9 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
10 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
11 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
12 <link href="../images/favicon.ico" rel="shortcut icon" /></head>
13 <body id="manual-page"><div id="page-header">
14 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
15 <p class="apache">Apache HTTP Server Version 2.1</p>
16 <img alt="" src="../images/feather.gif" /></div>
17 <div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
18 <div id="path">
19 <a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP Server</a> &gt; <a href="http://httpd.apache.org/docs-project/">Documentation</a> &gt; <a href="../">Version 2.1</a> &gt; <a href="./">Programs</a></div><div id="page-content"><div id="preamble"><h1>dbmmanage - Manage user authentication files in DBM format</h1>
20 <div class="toplang">
21 <p><span>Available Languages: </span><a href="../en/programs/dbmmanage.html" title="English">&nbsp;en&nbsp;</a></p>
22 </div>
23
24     <p><code>dbmmanage</code> is used to create and update the DBM format files
25     used to store usernames and password for basic authentication of HTTP users.
26     Resources available from the Apache HTTP server can be restricted to just
27     the users listed in the files created by <code>dbmmanage</code>. This
28     program can only be used when the usernames are stored in a DBM file. To
29     use a flat-file database see <a href="htpasswd.html">htpasswd</a>.</p>
30
31     <p>This manual page only lists the command line arguments. For details of
32     the directives necessary to configure user authentication in
33     <a href="httpd.html">httpd</a> see the httpd manual, which is part of
34     the Apache distribution or can be found at <a href="http://httpd.apache.org/">http://httpd.apache.org/</a>.</p>
35 </div>
36 <div id="quickview"><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#synopsis">Synopsis</a></li>
37 <li><img alt="" src="../images/down.gif" /> <a href="#options">Options</a></li>
38 <li><img alt="" src="../images/down.gif" /> <a href="#bugs">Bugs</a></li>
39 </ul><h3>See also</h3><ul class="seealso"><li><a href="httpd.html">httpd</a></li><li><code class="module"><a href="../mod/mod_authn_dbm.html">mod_authn_dbm</a></code></li><li><code class="module"><a href="../mod/mod_authz_dbm.html">mod_authz_dbm</a></code></li></ul></div>
40 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
41 <div class="section">
42 <h2><a name="synopsis" id="synopsis">Synopsis</a></h2>
43     <p><code><strong>dbmmanage</strong> [ <var>encoding</var> ]
44     <var>filename</var> add|adduser|check|delete|update
45     <var>username</var>
46     [ <var>encpasswd</var>
47       [ <var>group</var>[,<var>group</var>...]
48         [ <var>comment</var> ] ] ]</code></p>
49
50     <p><code><strong>dbmmanage</strong> <var>filename</var>
51     view [ <var>username</var> ]</code></p>
52
53     <p><code><strong>dbmmanage</strong> <var>filename</var> import</code></p>
54 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
55 <div class="section">
56 <h2><a name="options" id="options">Options</a></h2>
57     <dl>
58     <dt><code><var>filename</var></code></dt>
59     <dd>The filename of the DBM format file. Usually without the extension
60     <code>.db</code>, <code>.pag</code>, or <code>.dir</code>.</dd>
61
62     <dt><code><var>username</var></code></dt>
63     <dd>The user for which the operations are performed. The <var>username</var>
64     may not contain a colon (<code>:</code>).</dd>
65
66     <dt><code><var>encpasswd</var></code></dt>
67     <dd>This is the already encrypted password to use for the
68     <code>update</code> and <code>add</code> commands. You may use a hyphen
69     (<code>-</code>) if you want to get prompted for the password, but fill
70     in the fields afterwards. Additionally when using the <code>update</code>
71     command, a period (<code>.</code>) keeps the original password
72     untouched.</dd>
73
74     <dt><code><var>group</var></code></dt>
75     <dd>A group, which the user is member of. A groupname may not contain a
76     colon (<code>:</code>). You may use a hyphen (<code>-</code>) if you don't
77     want to assign the user to a group, but fill in the comment field.
78     Additionally when using the <code>update</code> command, a period
79     (<code>.</code>) keeps the original groups untouched.</dd>
80
81     <dt><code><var>comment</var></code></dt>
82     <dd>This is the place for your opaque comments about the user, like
83     realname, mailaddress or such things. The server will ignore this
84     field.</dd>
85     </dl>
86
87     <h3><a name="options.encodings" id="options.encodings">Encodings</a></h3>
88       <dl>
89       <dt><code>-d</code></dt>
90       <dd>crypt encryption (default, except on Win32, Netware)</dd>
91
92       <dt><code>-m</code></dt>
93       <dd>MD5 encryption (default on Win32, Netware)</dd>
94
95       <dt><code>-s</code></dt>
96       <dd>SHA1 encryption</dd>
97
98       <dt><code>-p</code></dt>
99       <dd>plaintext (<em>not recommended</em>)</dd>
100       </dl>
101     
102
103     <h3><a name="options.commands" id="options.commands">Commands</a></h3>
104       <dl>
105       <dt><code>add</code></dt>
106       <dd>Adds an entry for <var>username</var> to <var>filename</var> using the
107       encrypted password <var>encpasswd</var>.</dd>
108
109       <dt><code>adduser</code></dt>
110       <dd>Asks for a password and then adds an entry for <var>username</var> to
111       <var>filename</var>.</dd>
112
113       <dt><code>check</code></dt>
114       <dd>Asks for a password and then checks if <var>username</var> is in
115       <var>filename</var> and if it's password matches the specified one.</dd>
116
117       <dt><code>delete</code></dt>
118       <dd>Deletes the <var>username</var> entry from <var>filename</var>.</dd>
119
120       <dt><code>import</code></dt>
121       <dd>Reads <code><var>username</var>:<var>password</var></code> entries
122       (one per line) from <code>STDIN</code> and adds them to
123       <var>filename</var>. The passwords already have to be crypted.</dd>
124
125       <dt><code>update</code></dt>
126       <dd>Same as the <code>adduser</code> command, except that it makes
127       sure <var>username</var> already exists in <var>filename</var>.</dd>
128
129       <dt><code>view</code></dt>
130       <dd>Just displays the contents of the DBM file. If you specify a
131       <var>username</var>, it displays the particular record only.</dd>
132       </dl>
133     
134 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
135 <div class="section">
136 <h2><a name="bugs" id="bugs">Bugs</a></h2>
137     <p>One should be aware that there are a number of different DBM file formats
138     in existence, and with all likelihood, libraries for more than one format
139     may exist on your system. The three primary examples are SDBM, NDBM, the GNU
140     project's GDBM, and Berkeley DB 2. Unfortunately, all these libraries use
141     different file formats, and you must make sure that the file format used
142     by <var>filename</var> is the same format that <code>dbmmanage</code>
143     expects to see. <code>dbmmanage</code> currently has no way of determining
144     what type of DBM file it is looking at. If used against the wrong format,
145     will simply return nothing, or may create a different DBM file with a
146     different name, or at worst, it may corrupt the DBM file if you were
147     attempting to write to it.</p>
148
149     <p><code>dbmmanage</code> has a list of DBM format preferences, defined by
150     the <code>@AnyDBM::ISA</code> array near the beginning of the program. Since
151     we prefer the Berkeley DB 2 file format, the order in which
152     <code>dbmmanage</code> will look for system libraries is Berkeley DB 2,
153     then NDBM, then GDBM and then SDBM. The first library found will be the
154     library <code>dbmmanage</code> will attempt to use for all DBM file
155     transactions. This ordering is slightly  different than the standard
156     <code>@AnyDBM::ISA</code> ordering in perl, as well as the ordering used by
157     the simple <code>dbmopen()</code> call in Perl, so if you use any other
158     utilities to manage your DBM files, they must also follow this preference
159     ordering. Similar care must be taken if using programs in other languages,
160     like C, to access these files.</p>
161
162     <p>One can usually use the <code>file</code> program supplied with most
163     Unix systems to see what format a DBM file is in.</p>
164 </div></div>
165 <div class="bottomlang">
166 <p><span>Available Languages: </span><a href="../en/programs/dbmmanage.html" title="English">&nbsp;en&nbsp;</a></p>
167 </div><div id="footer">
168 <p class="apache">Maintained by the <a href="http://httpd.apache.org/docs-project/">Apache HTTP Server Documentation Project</a></p>
169 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div>
170 </body></html>