What algorithm for HMAC?
Posted: Mon Nov 14, 2011 7:34 pm
Hi,
I am planning to implement a small tool that will encrypt large numbers of files and I find the AES file format used in AESCrypt suitable for my needs - I see no reason to reinvent the wheel there.
Anyway, all is clear to me except one thing, the HMAC.
In another thread here on the forum there is a link to Wikipedia regarding the HMAC, but that page lists "examples of HMAC" using MD5, SHA1 and SHA256. RFC 2104 also states that any iterative hash algorithm can be used.
Given the length of the HMAC fields in the file format, is SHA256 the only algorithm that can be used (HMAC-SHA-256)?
I am planning to implement a small tool that will encrypt large numbers of files and I find the AES file format used in AESCrypt suitable for my needs - I see no reason to reinvent the wheel there.
Anyway, all is clear to me except one thing, the HMAC.
In another thread here on the forum there is a link to Wikipedia regarding the HMAC, but that page lists "examples of HMAC" using MD5, SHA1 and SHA256. RFC 2104 also states that any iterative hash algorithm can be used.
Given the length of the HMAC fields in the file format, is SHA256 the only algorithm that can be used (HMAC-SHA-256)?