Replace nonce with hmac.