Added MD5 digest.
Security and debugging improvements