From f919d19be0a2186f54b13ad56bec50b9c9243139 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Tue, 11 Apr 2000 16:01:42 +0000 Subject: [PATCH] Change keygen-type generation so that salt is supplied in the call to MHASH-KEYGEN, if needed. This is desirable because the salt is usually unique for each passphrase. --- v7/src/runtime/crypto.scm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/v7/src/runtime/crypto.scm b/v7/src/runtime/crypto.scm index d31d70f73..3b37a9dc4 100644 --- a/v7/src/runtime/crypto.scm +++ b/v7/src/runtime/crypto.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Id: crypto.scm,v 14.8 2000/04/11 16:00:12 cph Exp $ +$Id: crypto.scm,v 14.9 2000/04/11 16:01:42 cph Exp $ Copyright (c) 2000 Massachusetts Institute of Technology @@ -140,7 +140,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. (if (or (default-object? salt) (not salt)) (error "Salt required:" (vector-ref mhash-keygen-names id))) - (let ((n (mhash-keygen-salt-size name))) + (let ((n + ((ucode-primitive mhash_get_keygen_salt_size 1) + id))) (if (not (or (= n 0) (= n (string-length salt)))) (error "Salt size incorrect:" -- 2.25.1