Compare commits

...

1 Commits

Author SHA1 Message Date
zwx 04af4827d1 feat(mbedtls): cherry-pick #9492 manually. 2023-10-10 11:23:58 +08:00
3 changed files with 11 additions and 1 deletions
+1 -1
View File
@@ -132,7 +132,7 @@ jobs:
- uses: actions/checkout@v2
with:
repository: ARMmbed/mbedtls
ref: v3.2.1
ref: v3.5.0
path: third_party/mbedtls/repo
- name: Build
run: |
+4
View File
@@ -52,7 +52,11 @@ void GenerateKey(const uint8_t *aPassword,
uint16_t aKeyLen,
uint8_t * aKey)
{
#if (MBEDTLS_VERSION_NUMBER >= 0x03050000)
const size_t kBlockSize = MBEDTLS_CMAC_MAX_BLOCK_SIZE;
#else
const size_t kBlockSize = MBEDTLS_CIPHER_BLKSIZE_MAX;
#endif
uint8_t prfInput[kMaxSaltLength + 4]; // Salt || INT(), for U1 calculation
long prfOne[kBlockSize / sizeof(long)];
long prfTwo[kBlockSize / sizeof(long)];
+6
View File
@@ -141,6 +141,12 @@
#include MBEDTLS_USER_CONFIG_FILE
#endif
#include "mbedtls/version.h"
// Include in the legacy config name adjustment file for mbedtls >= 3.5.0
#if (MBEDTLS_VERSION_NUMBER >= 0x03050000)
#include "mbedtls/config_adjust_legacy_crypto.h"
#endif
#include "mbedtls/check_config.h"
#endif /* MBEDTLS_CONFIG_H */