mike@cosmos.acs.calpoly.edu (Mike Maughmer) (03/16/91)
I'm having some problems with the DES encryption library call "setkey()"
under SunOS 4.1.1 on a SPARCstation 1+.
The following program will not compile:
extern int setkey();
main()
{
setkey(/* the appropriate argument goes here */);
}
The problem is that ld complains about _setkey being an undefined symbol.
Running nm on /usr/lib/libc.a reveals that _setkey does not exist, but
that _des_setkey does. Changing setkey() to des_setkey() in the program
causes ld to bitch about _des_setkey, as well, being an undefined symbol.
Though setkey() is explained in the Sun man pages, along with crypt() and
encrypt(), is setkey() unavailable? How do I use it when ld can't even
find it? encrypt() relies upon the key set by setkey(). What am I
missing? (Did Sun simply forget to place the code for setkey() in their C
libraries?) :-)
Please mail your responses to mike@cosmos.acs.calpoly.edu. I'll post a
summary later. Thanks . . .
Mike Maughmer
Cal Poly State University
San Luis Obispo, California
mike@cosmos.acs.calpoly.edu