On Wed, 2007-20-06 at 15:21 +1000, Donald Bruce Stewart wrote:
    -- unsigned char *MD5(const unsigned char *d, unsigned long n, unsigned char *md);
    foreign import ccall "openssl/md5.h MD5" c_md5
        :: Ptr CChar -> CULong -> Ptr CChar -> IO (Ptr Word8)

ByteStrings were designed for this zero-copy passing of big data to C,
by the way, so its a perfect fit.

I'm not so sure I like the idea of having to do this by passing it over to C.  Crypto sounds like exactly the kind of application that would require the certainty of FP reasoning.  Is there no way to make it work reasonably efficiently in Haskell proper?

--
Michael T. Richter <ttmrichter@gmail.com> (GoogleTalk: ttmrichter@gmail.com)
I can see computers everywhere - except in the productivity statistics! (Robert Solow)