lib: introduce module hash_debug

Signed-off-by: Jean Privat <jean@pryen.org>