Skip to Content
Mac OS X in a Nutshell
book

Mac OS X in a Nutshell

by Jason McIntosh, Chuck Toporek, Chris Stone
January 2003
Intermediate to advanced
832 pages
32h 40m
English
O'Reilly Media, Inc.
Content preview from Mac OS X in a Nutshell

Name

chkpasswd

Synopsis

chkpasswd [-c] [-i infosystem] [-l location] [username]

Useful for scripts, this prompts for a password that is then compared against the appropriate directory service for the user specified. If the password is incorrect, the string Sorry is output. (Strangely, chkpasswd appears to have a return value of 0 in either case.)

Options

-c

User input is compared with the password hash directly, rather than running it through the crypt algorithm first.

-i

Specifies the directory service to use, and may be file, netinfo (the default), or nis.

-l

Depending on the directory service being used, it’s either a filename (defaults to /etc/master.passwd), a NetInfo domain name or server/tag combo, or an NIS domain name.

username

Designates whose password will be checked. It defaults to that of the user running the command.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mac OS X Internals: A Systems Approach

Mac OS X Internals: A Systems Approach

Amit Singh
C++ In a Nutshell

C++ In a Nutshell

Ray Lischner
Linux Shell Scripting Cookbook - Third Edition

Linux Shell Scripting Cookbook - Third Edition

Clif Flynt, Sarath Lakshman, Shantanu Tushar
Optimized C++

Optimized C++

Kurt Guntheroth

Publisher Resources

ISBN: 0596003706Supplemental ContentCatalog PageErrata