[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 207/220: sspi: fix memory leaks
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 207/220: sspi: fix memory leaks |
Date: |
Thu, 12 Sep 2019 17:29:27 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit 67b30b341811cd0bc60bdaab5a7c5532fa23f623
Author: migueljcrum <miguel@localhost>
AuthorDate: Fri Sep 6 13:43:51 2019 +0000
sspi: fix memory leaks
Closes #4299
---
lib/vauth/digest_sspi.c | 5 +++++
lib/vauth/krb5_sspi.c | 5 +++++
lib/vauth/ntlm_sspi.c | 5 +++++
lib/vauth/spnego_sspi.c | 6 ++++++
4 files changed, 21 insertions(+)
diff --git a/lib/vauth/digest_sspi.c b/lib/vauth/digest_sspi.c
index 850d6262b..a1090568b 100644
--- a/lib/vauth/digest_sspi.c
+++ b/lib/vauth/digest_sspi.c
@@ -61,6 +61,11 @@ bool Curl_auth_is_digest_supported(void)
status = s_pSecFn->QuerySecurityPackageInfo((TCHAR *) TEXT(SP_NAME_DIGEST),
&SecurityPackage);
+ /* Release the package buffer as it is not required anymore */
+ if(status == SEC_E_OK) {
+ s_pSecFn->FreeContextBuffer(SecurityPackage);
+ }
+
return (status == SEC_E_OK ? TRUE : FALSE);
}
diff --git a/lib/vauth/krb5_sspi.c b/lib/vauth/krb5_sspi.c
index 6ac049eb3..98041d915 100644
--- a/lib/vauth/krb5_sspi.c
+++ b/lib/vauth/krb5_sspi.c
@@ -58,6 +58,11 @@ bool Curl_auth_is_gssapi_supported(void)
TEXT(SP_NAME_KERBEROS),
&SecurityPackage);
+ /* Release the package buffer as it is not required anymore */
+ if(status == SEC_E_OK) {
+ s_pSecFn->FreeContextBuffer(SecurityPackage);
+ }
+
return (status == SEC_E_OK ? TRUE : FALSE);
}
diff --git a/lib/vauth/ntlm_sspi.c b/lib/vauth/ntlm_sspi.c
index 28109f76a..cd6cb79c1 100644
--- a/lib/vauth/ntlm_sspi.c
+++ b/lib/vauth/ntlm_sspi.c
@@ -56,6 +56,11 @@ bool Curl_auth_is_ntlm_supported(void)
status = s_pSecFn->QuerySecurityPackageInfo((TCHAR *) TEXT(SP_NAME_NTLM),
&SecurityPackage);
+ /* Release the package buffer as it is not required anymore */
+ if(status == SEC_E_OK) {
+ s_pSecFn->FreeContextBuffer(SecurityPackage);
+ }
+
return (status == SEC_E_OK ? TRUE : FALSE);
}
diff --git a/lib/vauth/spnego_sspi.c b/lib/vauth/spnego_sspi.c
index 13e20db39..b9c2cf7d6 100644
--- a/lib/vauth/spnego_sspi.c
+++ b/lib/vauth/spnego_sspi.c
@@ -59,6 +59,12 @@ bool Curl_auth_is_spnego_supported(void)
TEXT(SP_NAME_NEGOTIATE),
&SecurityPackage);
+ /* Release the package buffer as it is not required anymore */
+ if(status == SEC_E_OK) {
+ s_pSecFn->FreeContextBuffer(SecurityPackage);
+ }
+
+
return (status == SEC_E_OK ? TRUE : FALSE);
}
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [GNUnet-SVN] [gnurl] 193/220: ROADMAP: updated after recent user poll, (continued)
- [GNUnet-SVN] [gnurl] 193/220: ROADMAP: updated after recent user poll, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 212/220: curl: make sure the parallel transfers do them all, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 199/220: RELEASE-NOTES: synced, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 217/220: update sed script, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 151/220: http: remove chunked-encoding and expect header use for HTTP/3, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 189/220: CI: remove duplicate configure flag for LGTM.com, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 195/220: smtp: check for and bail out on too short EHLO response, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 205/220: Curl_fillreadbuffer: avoid double-free trailer buf on error, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 204/220: tool_setopt: handle a libcurl build without netrc support, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 194/220: smb: init *msg to NULL in smb_send_and_recv(), gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 207/220: sspi: fix memory leaks,
gnunet <=
- [GNUnet-SVN] [gnurl] 209/220: openssl: use SSL_CTX_set_<min|max>_proto_version() when available, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 210/220: urlapi: verify the IPv6 numerical address, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 218/220: docs: curl->gnurl sed, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 220/220: doc: man 3 rename., gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 219/220: rename man 3 file, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 208/220: openssl: indent, re-organize and add comments, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 203/220: security:read_data fix bad realloc(), gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 196/220: cleanup: move functions out of url.c and make them static, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 214/220: RELEASE-NOTES: curl 7.66.0, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 216/220: Merge tag 'curl-7_66_0', gnunet, 2019/09/12