-
Notifications
You must be signed in to change notification settings - Fork 18
RDK-58546: [POC] T2 Thread And Curl Connection Pool Addition For Efficient Memory Utilization On Low End Devices #166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@gmail.com>
| } while(still_running); | ||
| size_t len = strlen(response->data); | ||
| T2Info("%s ; Response data size = %zu\n", __FUNCTION__, len); | ||
| if (response->data) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Dereference before null check
Null-checking "response->data" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
Medium Impact, CWE-476
REVERSE_INULL
| pool.handle_available[i] = true; | ||
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 30)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_CONNECTTIMEOUT, 10); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 10)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_CONNECTTIMEOUT, 10); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPALIVE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_CONNECTTIMEOUT, 10); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPALIVE, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPIDLE, 120L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 120L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPALIVE, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPIDLE, 120L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 60L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPIDLE, 120L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); // Connection cache size |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 5L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Set URL and payload | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Set URL and payload | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Response handling | ||
| //curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, write_callback); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
|
Yogeswaran K seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
| if(httpOutput) | ||
| { | ||
| T2Debug("Update config data in response file %s \n", HTTP_RESPONSE_FILE); | ||
| fputs(response->data, httpOutput); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Dereference after null check
Passing null pointer "response->data" to "fputs", which dereferences it.
Medium Impact, CWE-476
FORWARD_NULL
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPIDLE, 120L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 5L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| //curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); | ||
|
|
||
| // Response handling | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…etry into topic/RDK-58546
| // Response handling | ||
| if (payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
| else | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| pthread_mutex_unlock(&pool.pool_mutex); | ||
|
|
||
| T2Info("%s ++out\n", __FUNCTION__); | ||
| return ret; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity issue no longer present as of: undefined
Show issue
Coverity Issue - Resource leak
Variable "pCertFile" going out of scope leaks the storage it points to.
High Impact, CWE-404
RESOURCE_LEAK
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| } | ||
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| } | ||
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices
…cient Memory Utilization On Low End Devices
| } | ||
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } else { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // For POST, we might not need response data, use simple callback | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Handle mTLS if enabled | ||
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "P12")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->enable_mtls && T2ERROR_SUCCESS == getMtlsCerts(&pCertFile, &pPasswd)) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pCertFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pPasswd)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_SSLCERTTYPE, "P12"); | ||
| curl_easy_setopt(easy, CURLOPT_SSLCERT, pCertFile); | ||
| curl_easy_setopt(easy, CURLOPT_KEYPASSWD, pPasswd); | ||
| curl_easy_setopt(easy, CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| // POST request configuration (for sendReportOverHTTP) | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.get_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FRESH_CONNECT, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| // POST request configuration (for sendReportOverHTTP) | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.get_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FRESH_CONNECT, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| // POST request configuration (for sendReportOverHTTP) | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.get_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.get_headers); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPINTVL, 60L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FRESH_CONNECT, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| // POST request configuration (for sendReportOverHTTP) | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| if (config->payload) | ||
| { | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, config->payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(config->payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(config->payload)); | ||
| } | ||
|
|
||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, writeToFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, writeToFile)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| else | ||
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| { | ||
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, httpGetCallBack)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // GET request configuration (for doHttpGet) | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, (void *)response)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| pool.handle_available[i] = true; | ||
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 30L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_CONNECTTIMEOUT, 10L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 10L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| #endif | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FRESH_CONNECT, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| } | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| #ifdef CURLOPT_TCP_KEEPCNT | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPCNT, 15L); // Allow up to 15 probes | ||
| #endif | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 5L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| #endif | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FORBID_REUSE, 0L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_FRESH_CONNECT, 0L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 0L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| } | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| pool.handle_available[i] = true; | ||
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 30L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Set common options once | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TIMEOUT, 30L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_CONNECTTIMEOUT, 30L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 30L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_TCP_KEEPCNT, 15L); // Allow up to 15 probes | ||
| #endif | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_MAXCONNECTS, 5L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 5L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| } | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDSIZE, strlen(payload)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, strlen(payload))" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) &response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Incorrect sizeof expression
Taking the size of "&response", which is the address of an object, is suspicious.
Medium Impact, CWE-467
BAD_SIZEOF
How to fix
Did you intend the size of "response" itself?
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) &response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Incorrect sizeof expression
Taking the size of "&response", which is the address of an object, is suspicious.
Medium Impact, CWE-467
BAD_SIZEOF
How to fix
Did you intend the size of "response" itself?
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) &response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Incorrect sizeof expression
Taking the size of "&response", which is the address of an object, is suspicious.
Medium Impact, CWE-467
BAD_SIZEOF
How to fix
Did you intend the size of "response" itself?
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
…cient Memory Utilization On Low End Devices Signed-off-by: Yogeswaran K <yogeswaransky@comcast.com>
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) &response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Incorrect sizeof expression
Taking the size of "&response", which is the address of an object, is suspicious.
Medium Impact, CWE-467
BAD_SIZEOF
How to fix
Did you intend the size of "response" itself?
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPGET, 1L); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEFUNCTION, httpGetCallBack); | ||
| curl_easy_setopt(easy, CURLOPT_WRITEDATA, (void *) &response); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Incorrect sizeof expression
Taking the size of "&response", which is the address of an object, is suspicious.
Medium Impact, CWE-467
BAD_SIZEOF
How to fix
Did you intend the size of "response" itself?
| easy = pool.easy_handles[idx]; | ||
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, url)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, "POST")" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| // Configure for POST request | ||
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, pool.post_headers)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(easy, CURLOPT_URL, url); | ||
| curl_easy_setopt(easy, CURLOPT_CUSTOMREQUEST, "POST"); | ||
| curl_easy_setopt(easy, CURLOPT_HTTPHEADER, pool.post_headers); | ||
| curl_easy_setopt(easy, CURLOPT_POSTFIELDS, payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(easy, _curl_opt, payload)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| } | ||
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| // Certificate selector and SSL/TLS specific options from original code | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSL_VERIFYPEER, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, 1L)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_SSLENGINE_DEFAULT, 1L); | ||
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, curl_debug_callback_func)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
|
|
||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_VERBOSE, 1L); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGFUNCTION, curl_debug_callback_func); | ||
| curl_easy_setopt(pool.easy_handles[i], CURLOPT_DEBUGDATA, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverity Issue - Unchecked return value from library
Calling "curl_easy_setopt(pool.easy_handles[i], _curl_opt, NULL)" without checking return value. This library function may fail and return an error code.
Medium Impact, CWE-252
CHECKED_RETURN
No description provided.