]> arthur.barton.de Git - netatalk.git/commitdiff
quick, dirty, Sun hack to seed openssl 0.9.6 ... FIX THIS
authorrufustfirefly <rufustfirefly>
Wed, 5 Sep 2001 13:42:16 +0000 (13:42 +0000)
committerrufustfirefly <rufustfirefly>
Wed, 5 Sep 2001 13:42:16 +0000 (13:42 +0000)
etc/uams/uams_dhx_pam.c

index 6420bd52ff5604a96a56c13b8b53e5d0f06b6b09..999fae7f9fdbdcf7e0ff748a69c0a61cf07acaf1 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: uams_dhx_pam.c,v 1.15 2001-06-25 20:13:45 rufustfirefly Exp $
+ * $Id: uams_dhx_pam.c,v 1.16 2001-09-05 13:42:16 rufustfirefly Exp $
  *
  * Copyright (c) 1990,1993 Regents of The University of Michigan.
  * Copyright (c) 1999 Adrian Sun (asun@u.washington.edu) 
@@ -121,7 +121,7 @@ static int PAM_conv (int num_msg,
     case PAM_TEXT_INFO:
 #ifdef PAM_BINARY_PROMPT
     case PAM_BINARY_PROMPT:
-#endif
+#endif /* PAM_BINARY_PROMPT */
       /* ignore it... */
       break;
     case PAM_ERROR_MSG:
@@ -177,6 +177,12 @@ static int dhx_setup(void *obj, char *ibuf, int ibuflen,
     BIGNUM *bn, *gbn, *pbn;
     DH *dh;
 
+    /* TODO: seed dhx_setup properly... this is a hack */
+#ifdef sun
+       /* *SEVERE* hack... fix */
+       RAND_load_file("/var/adm/messages", KEYSIZE);
+#endif /* sun */
+
     /* get the client's public key */
     if (!(bn = BN_bin2bn(ibuf, KEYSIZE, NULL))) {
     /* Log Entry */