Set initial values to remove build warnings
authorDongsun Lee <ds73.lee@samsung.com>
Mon, 21 Aug 2023 01:16:45 +0000 (10:16 +0900)
committerDariusz Michaluk <d.michaluk@samsung.com>
Mon, 21 Aug 2023 12:21:07 +0000 (14:21 +0200)
Change-Id: Icf793bed432aeb72de8471bd770feb9326450936

src/manager/crypto/tz-backend/internals.cpp

index 1d14e08..b97a70f 100644 (file)
@@ -852,9 +852,9 @@ void deriveKBKDF(const RawBuffer &secretId,
                                 const RawBuffer &keyHash)
 {
        RawBuffer label, context, fixed;
-       KbkdfCounterLocation counterLocation;
-       KdfPrf prf;
-       KbkdfMode mode;
+       KbkdfCounterLocation counterLocation = KbkdfCounterLocation::BEFORE_FIXED;
+       KdfPrf prf = KdfPrf::HMAC_SHA256;
+       KbkdfMode mode = KbkdfMode::COUNTER;
        size_t length, rlenBits = 32, llenBits = 32, tmp;
        bool hasLabel = alg.getParam(ParamName::KBKDF_LABEL, label);
        bool hasContext = alg.getParam(ParamName::KBKDF_CONTEXT, context);