CMAC primitive and tests

I'm splitting up #931 into separate PRs for easier reviewing. This contains the CMAC primitive implementation and associated tests. 

The OpenSSL backend implementation and docs will follow in another PR.