Improve valid MAC detection

Implement constant time string comparison as well as double HMAC
verification for encryption MACs.
Add security to encryption's composer file.