From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,117505c236239773 X-Google-Attributes: gidfee84,public From: Steve VanDevender Subject: Re: putting passwords in auth.db Date: 1996/10/09 Message-ID: #1/1 X-Deja-AN: 188345747 references: organization: University of Oregon newsgroups: comp.unix.osf.osf1 I've succeded in writing a program that takes more-or-less standard /etc/passwd and /etc/shadow files and stuffs the passwords into the protected password database used by Digital UNIX in ENHANCED security mode, using the getprpwnam() and putprpwnam() functions. It's currently being tested on one of our Digital UNIX hosts with good results so far; it accepts /etc/passwd and /etc/shadow from a Solaris host and everyone we've tried so far is able to log in. After I've had it running for a while longer and am more confident about showing it to the world, I should be able to release the code. The most interesting gotcha is that in ENHANCED security mode, Digital UNIX treats characters in a password after the 8th as significant, instead of truncating passwords to 8 characters before encrypting them for comparison during login. An early version of the program worked for all but one of the testers, who happened to use a 9-character password. Fortunately a semi-documented item in the pr_passwd structure, ufld.fd_oldcrypt, can be used to set which kind of password encryption you want to use, including the old truncate-to-8-chars-and-crypt() behavior that is compatible with Solaris (and probably most other UNIXen). The default in Digital UNIX is apparently to encrypt passwords in 8-character blocks and store all of the blocks.