Date: Thu, 15 Dec 2011 19:06:40 +0400 From: Solar Designer <solar@...nwall.com> To: john-dev@...ts.openwall.com Subject: Re: Bit slice implementation of DES based hashes Piyush - On Thu, Dec 15, 2011 at 05:51:14PM +0530, piyush mittal wrote: > In File DES_bs_b.c Three methods are given i.e > 1,DES_bs_crypt_LM() > 2.DES_bs_crypt_25 > 3.DES_bs_crypt() > > > > The first two is specific to Lm and Traditional DES respectively.First one > calls the S-boxes in ECB mode and for second one I don't > know.Third one i hope don't use any mode.However in oracle_fmt_plug.c > conversion we need CBC mode so how to call S Boxes in this case? You need to introduce a fourth function. I suggest that you take DES_bs_crypt_LM(), copy it to a new function, and remove the initialization of B from there (let the caller specify the initial B). This way, you get a function implementing one DES block encryption (for DES_BS_DEPTH different blocks and/or keys in parallel). As to block cipher modes, you'll implement those externally to that function (at least initially). Another question I expected from you was how to set arbitrary DES keys when the current DES_bs_set_key*() functions accept ASCII strings only. I'll answer this one without waiting for you to ask it. ;-) I suggest that you simply use DES_bs_set_key() for now, but set bit 8 in every char (OR it with 0x80) to ensure that all 8 chars (with 7 significant bits per char) are processed. We may introduce a more efficient binary key setup function later. Thanks, Alexander
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.