tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* Passwords encryption on Digital Unix
@ 1996-02-22  4:57 Andrew Moar
  0 siblings, 0 replies; only message in thread
From: Andrew Moar @ 1996-02-22  4:57 UTC (permalink / raw)
  To: tru64-unix-managers

Dear OSF Managers,

	We have just recently upgraded one of our machines running Ultrix to an 
Alpha running Digital Unix 3.2d.  This all went (fairly) smoothly.

The problem we are having is that we had a program on our Ultrix machine that 
created user accounts for single students and classes in the University.  This 
allowed us to automate the process of creating user accounts somewhat by 
updating the /etc/passwd and /etc/group files and creating initial login scripts 
in their accounts rather than using the adduser command.

We were using a C program to encrypt the passwords, using the crypt16 algorithm.
Unfortunately it appears that the encryption algorithm is different in Digital 
Unix as user get an invalid password message when they attempt to log in.

I guess my question is what encryption algorithm should I be using?  We are 
running base (not enhanced) security.

This is the old code:

#include <stdio.h>

char    *crypt16();
char    *pw;
char    pwbuf[10];


main (argc, argv)
        int argc;
        char *argv[];
{
        int i;
        char saltc[2];
        long salt;
        int c;

        salt += getpid();
        saltc[0] = salt & 077;
        saltc[1] = (salt >> 6) & 077;
        for (i=0; i<2; i++) {
                c = saltc[i] + '.';
                if (c>'9') c += 7;
                if (c>'Z') c += 6;
                saltc[i] = c;
        }
        strcpy(pwbuf, argv[1]);
        pw = crypt16(pwbuf, saltc);
        printf("%s\n", pw);
}


Thanks,

Andrew Moar
Latrobe University
Melbourne
email: A.Moar@latrobe.edu.au

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1996-02-22  4:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-02-22  4:57 Passwords encryption on Digital Unix Andrew Moar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox