[PATCH v4 03/14] crypto: Fix the logic to calculate hash with authattributes set