[Haskell] Haskell binding to the LibTomCrypt library

Don Stewart dons at galois.com
Sat Nov 17 16:37:17 EST 2007


bulat.ziganshin:
> Hello haskell,
> 
> as part of my archiver [1], i've made some FFI bindings to the
> open-source, public license cryptographic library LibTomCrypt [2]
> 
> this currently includes
> * AES, Blowfish, Twofish and Serpent encryption algorithms
> * CTR and CFB streaming modes
> * SHA-512 hash
> * FORTUNE cryptographic random numbers generator
> * PKCS5#2 password-based key derivation algorithm
> but may easily be extended to everything else included in the
> LibTomCrypt library
> 
> you may just download my sources and use it as is, but it will be a
> real pain. Don Stewart suggested to cabalize the binding and upload
> it to hackage as separate lib. i may do it if there are real users for
> such package. for the supposed API look at [3], encryption API will be
> essentially the same - using callbacks to read/write data.
> 
> because my program targeted to the same niche as winzip, the binding
> provides almost the same service - i.e. ability to encrypt/decrypt
> stream of data with password using cryptographically sound algorithms.
> you will be able to use it like this:
> 
> encrypt "aes" password (hGetBuf infile) (hPutBuf outfile)
> decrypt password (hGetBuf infile) (hPutBuf outfile)
> 
> if you need such library - please yell me. i will work on it only if
> there will be enough real users
> 

I guess my point was more to ensure we don't lose the code you worked so
hard on :) It would be pretty easy to cabalise, perhaps just use the
'mkcabal' program?

-- Don


More information about the Haskell mailing list