gencommit: make hash function indirect

I completely forgot why I needed this, but I'm sure I'll remember later.
gencommit: initial HMAC support

Old method remains for compatibility.
gencommit: use HMAC by default