[8230] in Athena Bugs

home help back first fref pref prev next nref lref last post

crypt for RIOS

daemon@ATHENA.MIT.EDU (Mark Rosenstein)
Wed Sep 18 13:31:17 1991

Date: Wed, 18 Sep 91 13:31:46 -0400
From: Mark Rosenstein <mar@MIT.EDU>
To: bugs@MIT.EDU
Cc: probe@MIT.EDU

First see that the BSD /usr/lib/makekey is compiled and installed in
/usr/athena/lib/makekey.  Then apply the diff to crypt.c, and compile
without needing any BSD compatibility.
					-Mark

*** crypt.c     Wed Sep 18 13:28:57 1991
--- /source/bsd-4.3/common/usr.bin/crypt.c      Fri Jan 25 20:08:39 1985
***************
*** 35,41 ****
                close(1);
                dup(pf[0]);
                dup(pf[1]);
-               execl("/usr/athena/lib/makekey", "-", 0);
                execl("/usr/lib/makekey", "-", 0);
                execl("/lib/makekey", "-", 0);
                exit(1);
--- 35,40 ----
***************
*** 85,108 ****
                secureflg = 1;
        }
        if (argc != 2){
- #ifdef _AIX
-               /* getpass() in AIX will read from file descriptor 0 rather
-                * than /dev/tty.  Since crypt reads the input file from
-                * stdin, we have to play file descriptor games here.
-                */
-
-               int fd;
-
-               fd = dup(0);
-               close(0);
-               dup(1);
- #endif
                setup(getpass("Enter key:"));
- #ifdef _AIX
-               close(0);
-               dup(fd);
-               close(fd);
- #endif
        }
        else
                setup(argv[1]);
--- 84,90 ----

home help back first fref pref prev next nref lref last post