gnu-crypto-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNU Crypto] PBE


From: Casey Marshall
Subject: [GNU Crypto] PBE
Date: 08 Mar 2003 13:53:24 -0800

Hi,

I was looking into implementing password-based encryption (PKCS #5) in
GNU Crypto -- mostly in relation to the encrypted JAR file stuff
mentioned earlier -- and wanted to get some opinions about how to
implement such a thing.

So far I've come up with the following possibilities:

   * Create a PBECipher class that implements IBlockCipher (or IMode)
     that takes in its attributes map additional parameters for the
     password and salt, and generates the key and IV within the init()
     method.

   * A separate class (and a surrounding interface) that just implements
     the key derivation function, leaving it up to the programmer to
     wrap the generated bytes into a form suitable for sending to a
     cipher or MAC.

So the question here is to have a simpler API, or a simpler
implementation. I am leaning towards the second, for its flexibility.

Also: PKCS #5 v.2 seems to require a MAC that can take keys shorter than
the digest length, which is strictly prohibited in our current HMAC
implementation.

-- 
Casey Marshall || address@hidden

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]