* SUMMARY: C2 password encryption
@ 1995-03-01 16:44 Andrew Pochinsky
0 siblings, 0 replies; only message in thread
From: Andrew Pochinsky @ 1995-03-01 16:44 UTC (permalink / raw)
To: tru64-unix-managers
My original question was:
> I'm looking for a procedure converting the plaintext password to the
> auth-entry password string under C2. The DEC OSF/1 Enhanced Security
> manual seems to be quite obscure on this issue. What it says is that
> the password is encrypted using the crypt(3) routine in 8-characters
> blocks. What is does not say is which salt is used in encyphering all
> blocks but the first one. I tried using the same salt and the last two
> characters from the previous block -- neither works.
>
I've got 4 replies all recommending undocumented bigcrypt(). It has
the same interface as crypt(3) but some wrapping was needed to make it
really work. The following procedure does the trick:
#include <sia.h>
#include <siad.h>
char *C2_crypt(char *txt, char *salt)
{
extern char *bigcrypt(char *, char *);
SIAENTITY *entity;
static char *argv[] = {"crypt", 0};
char *pwd;
sia_ses_init(&entity, 1, argv, NULL, "crypt", NULL, FALSE, NULL);
pwd = bigcrypt(txt, salt);
entity = NULL;
sia_ses_release(&entity);
return pwd;
}
And, of course, the security library is needed.
Thanks to:
Richard Rogers <cstrmr@staffs.ac.uk>
Clyde Hoover <clyde@motown.cc.utexas.edu>
Randy M. Hayman <haymanR@icefog.uacn.alaska.edu>
Barry Lynam <b.lynam@qut.edu.au>
--
Andrew Pochinsky
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1995-03-01 16:44 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-03-01 16:44 SUMMARY: C2 password encryption Andrew Pochinsky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox