Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
dcamper committed Jan 6, 2025
1 parent f8a60c3 commit 0fb9b31
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions ecllibrary/teststd/Crypto/TestCrypto_SKE.ecl
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,10 @@ EXPORT TestCrypto_SKE := MODULE
EXPORT DATA dat2 := mod.Encrypt( (DATA)'0123456789~`!@#$%^&*()-_=+|][}{;:?.>,<');
EXPORT TS05 := ASSERT(mod.Decrypt(dat2) = (DATA)'0123456789~`!@#$%^&*()-_=+|][}{;:?.>,<');
END;

EXPORT TestSKE05 := MODULE // HPCC-33157
EXPORT mod := Std.Crypto.SymmetricEncryption('aes-256-cbc', '01234567890123456789012345678901');
EXPORT TS05 := ASSERT(mod.Decrypt((DATA)'') = (DATA)'');
END;
END;

4 changes: 4 additions & 0 deletions plugins/cryptolib/cryptolib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,10 @@ static void symmDeserialize(size32_t lenPBuffer, const void * pBuffer, StringBuf

sbCipher.append(len, finger);//extract cipher name
}
else
{
*lenPlainText = 0;
}
}

static void symmSerialize(void * & result, size32_t & lenResult, const char * pIV, size32_t lenIV, size32_t lenPlainText, size32_t lenCipherBuff, const void * pCipherBuff)
Expand Down

0 comments on commit 0fb9b31

Please sign in to comment.