Implement "slow equals" in check(), for protection against timing attacks, fixes #21