diff options
| author | Connor McLaughlin <stenzek@gmail.com> | 2019-06-08 19:58:37 +1000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-06-08 19:58:37 +1000 |
| commit | b7fba95cdfe10112d5ba92bee2c4c655ff7afa13 (patch) | |
| tree | cfbda701e10ab8dd0d6e6f7eae5d9b7581c39b89 /Source/Core/DiscIO/VolumeVerifier.cpp | |
| parent | f75b254d4f31e7c7b3c96f0ac6d9c8c220e2e425 (diff) | |
| parent | 55128768422710ee78c94b45262d6825479fb484 (diff) | |
Merge pull request #8166 from lioncash/mbedtls
Externals: Update mbedTLS from 2.1.1 to 2.16.1
Diffstat (limited to 'Source/Core/DiscIO/VolumeVerifier.cpp')
| -rw-r--r-- | Source/Core/DiscIO/VolumeVerifier.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/Core/DiscIO/VolumeVerifier.cpp b/Source/Core/DiscIO/VolumeVerifier.cpp index 9389ae0fbf..c86d9c498f 100644 --- a/Source/Core/DiscIO/VolumeVerifier.cpp +++ b/Source/Core/DiscIO/VolumeVerifier.cpp @@ -652,13 +652,13 @@ void VolumeVerifier::SetUpHashing() if (m_hashes_to_calculate.md5) { mbedtls_md5_init(&m_md5_context); - mbedtls_md5_starts(&m_md5_context); + mbedtls_md5_starts_ret(&m_md5_context); } if (m_hashes_to_calculate.sha1) { mbedtls_sha1_init(&m_sha1_context); - mbedtls_sha1_starts(&m_sha1_context); + mbedtls_sha1_starts_ret(&m_sha1_context); } } @@ -712,10 +712,10 @@ void VolumeVerifier::Process() } if (m_hashes_to_calculate.md5) - mbedtls_md5_update(&m_md5_context, data.data(), bytes_to_read); + mbedtls_md5_update_ret(&m_md5_context, data.data(), bytes_to_read); if (m_hashes_to_calculate.sha1) - mbedtls_sha1_update(&m_sha1_context, data.data(), bytes_to_read); + mbedtls_sha1_update_ret(&m_sha1_context, data.data(), bytes_to_read); } } @@ -773,7 +773,7 @@ bool VolumeVerifier::CheckContentIntegrity(const IOS::ES::Content& content) encrypted_data.data(), decrypted_data.data()); std::array<u8, 20> sha1; - mbedtls_sha1(decrypted_data.data(), content.size, sha1.data()); + mbedtls_sha1_ret(decrypted_data.data(), content.size, sha1.data()); return sha1 == content.sha1; } @@ -806,13 +806,13 @@ void VolumeVerifier::Finish() if (m_hashes_to_calculate.md5) { m_result.hashes.md5 = std::vector<u8>(16); - mbedtls_md5_finish(&m_md5_context, m_result.hashes.md5.data()); + mbedtls_md5_finish_ret(&m_md5_context, m_result.hashes.md5.data()); } if (m_hashes_to_calculate.sha1) { m_result.hashes.sha1 = std::vector<u8>(20); - mbedtls_sha1_finish(&m_sha1_context, m_result.hashes.sha1.data()); + mbedtls_sha1_finish_ret(&m_sha1_context, m_result.hashes.sha1.data()); } } |
