> I tried to use openssl command to generate an HMAC with a key
> contains '\0', but failed.
> >openssl dgst -sha1 -hmac `cat <key-file>` <input-file>
> I'm happy if dgst command supports binary format like enc command.
> So I appended -hmachex <key in hex> option as the followings:
> >openssl dgst -sha1 -hmachex aabbcc0011223344 <input-file>
> How about this patch?
You can achieve this using the generalised MAC interface to HMAC like this: