DBMMANAGE(1)
π DBMMANAGE(1) π
okay bestie, so this page is from dbmmanage β the manual for that little Apache tool that handles your DBM-format password files β¨
πΈ NAME πΈ
dbmmanage β literally the tool that manages your user authentication files in DBM format π«Ά
β¨ SYNOPSIS β¨
dbmmanage [ encoding ] filename add|adduser|check|delete|update username
[ encpasswd [ group[,group...] [ comment ] ] ]
dbmmanage filename view [ username ]
dbmmanage filename import
π SUMMARY π
So dbmmanage is the girlboss that creates and updates DBM format files β the ones that store usernames and passwords for basic authentication of HTTP users via mod_authn_dbm. Resources served by the Apache HTTP server can be locked down to just the users listed in the files this cutie makes π
Important vibe check though: this program can only be used when usernames are stored in a DBM file. If you're on a flat-file database situation, go see htpasswd instead, iykyk.
Another tool for maintaining a DBM password database is htdbm β good to know, bestie.
This manual page only lists the command line arguments, jsyk. For all the deets on the directives you need to configure user authentication in httpd, check the httpd manual β it comes with the Apache distribution or you can find it at http://httpd.apache.org/ π
π¦ OPTIONS π¦
filenameβ the filename of the DBM format file, bestie. Usually without the.db,.pag, or.dirextension β¨usernameβ the user the operations are performed on. Fair warning: the username may not contain a colon (:).encpasswdβ this is the already hashed password used for theupdateandaddcommands. You can drop a hyphen (-) if you want to get prompted for the password but fill in the fields afterwards π Also, when using theupdatecommand, a period (.) keeps the original password untouched.groupβ a group that the user is a member of. Groupnames may not contain a colon (:). You can use a hyphen (-) if you don't want to assign the user to a group but still want to fill in the comment field. And when using theupdatecommand, a period (.) keeps the original groups untouched β¨commentβ the place for your totally opaque comments about the user, like realname, mailaddress, whatever. The server will ignore this field entirely, it's just for you π
π Encodings π
-dβcrypthashing (default, except on Win32, Netware)-mβ MD5 hashing (default on Win32, Netware)-sβ SHA1 hashing-pβ plaintext (not recommended, bestie, no cap π)
π Commands π
addβ adds an entry forusernametofilenameusing the hashed passwordencpasswd. Like this:
dbmmanage passwords.dat add rbowen foKntnEF3KSXA
adduserβ asks for a password and then adds an entry forusernametofilename. Obsessed with this flow fr:
dbmmanage passwords.dat adduser krietz
checkβ asks for a password and then checks ifusernameis infilenameand if its password matches the one you gave. Slay π
dbmmanage passwords.dat check rbowen
deleteβ deletes theusernameentry fromfilename. Iconic and clean:
dbmmanage passwords.dat delete rbowen
importβ readsusername:passwordentries (one per line) from STDIN and adds them tofilename. Heads up: the passwords already have to be crypted β¨updateβ same as theaddusercommand, except it makes sureusernamealready exists infilename. Gotta be there first, bestie:
dbmmanage passwords.dat update rbowen
viewβ just displays the contents of the DBM file. If you specify ausername, it shows that particular record only π
dbmmanage passwords.dat view
π BUGS π
Okay so this is the dramatic part, bestie β pay attention π
You should be aware that there are a number of different DBM file formats in existence, and with all likelihood, libraries for more than one format may exist on your system. The three primary examples are SDBM, NDBM, the GNU project's GDBM, and Berkeley DB 2. Unfortunately, all these libraries use different file formats, and you must make sure that the file format used by filename is the same format that dbmmanage expects to see π¬
dbmmanage currently has no way of determining what type of DBM file it's looking at. If used against the wrong format, it will simply return nothing, or may create a different DBM file with a different name, or β at worst β it may corrupt the DBM file if you were attempting to write to it. Literally be careful π
dbmmanage has a list of DBM format preferences, defined by the @AnyDBM::ISA array near the beginning of the program. Since we prefer the Berkeley DB 2 file format, the order in which dbmmanage will look for system libraries is Berkeley DB 2, then NDBM, then GDBM and then SDBM. The first library found will be the library dbmmanage will attempt to use for all DBM file transactions π«Ά
This ordering is slightly different than the standard @AnyDBM::ISA ordering in Perl, as well as the ordering used by the simple dbmopen() call in Perl β so if you use any other utilities to manage your DBM files, they must also follow this preference ordering. Similar care must be taken if using programs in other languages, like C, to access these files π
One can usually use the file program supplied with most Unix systems to see what format a DBM file is in β a little detective work never hurt nobody π
and that's the whole page, bestie π this manual page belongs to the Apache HTTP Server and is dated 2026-04-30 β go off and manage those DBM files responsibly, mwah πβ¨
π¦ where this page comes from
- alpine 3.22: apache2-doc 2.4.69-r0 Β· Apache-2.0
- alpine 3.23: apache2-doc 2.4.69-r0 Β· Apache-2.0
- alpine 3.24: apache2-doc 2.4.69-r0 Β· Apache-2.0
- arch rolling: apache 2.4.69-1 Β· Apache-2.0
- nixpkgs unstable: apache-httpd 2.4.69
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms