tls-hkdf: Cleanups and refactorings