TP-00123 | Release String UTF after sha (#9625)

This commit is contained in:
rahul bhat
2024-02-05 14:33:29 +05:30
committed by GitHub
parent 178f90cbdc
commit f089abcdf1

View File

@@ -141,11 +141,13 @@ Java_com_navi_base_security_interceptor_EncryptionHashInterceptor_getKey(
mid_StringBuilder_toString);
const char *hashKeyChars = env->GetStringUTFChars(encodedKey, nullptr);
std::string finalHashString = SHA256Hashing(hashKeyChars);
env->
ReleaseStringUTFChars(encodedKey, hashKeyChars
);
std::string finalHashString = SHA256Hashing(hashKeyChars);
return env->
NewStringUTF(finalHashString
.