mirror of
https://github.com/curl/curl.git
synced 2026-08-25 02:33:31 +03:00
src: safely clear certain buffers
Credits-to: Daniel Gustafsson
Ref: #13589 (original attempt)
Follow-up to 066478f634 #21598
safe clear more password buffers
tool_cfgable.c more
drop using dropped wrappers
creds.h copy comment suggested by LLM
This commit is contained in:
parent
70666b9be8
commit
f600501916
9 changed files with 37 additions and 4 deletions
|
|
@ -154,6 +154,7 @@ static CURLcode setstropt_userpwd(const char *option, char **userp,
|
|||
curlx_free(*userp);
|
||||
*userp = user;
|
||||
|
||||
curlx_strzero(*passwdp);
|
||||
curlx_free(*passwdp);
|
||||
*passwdp = passwd;
|
||||
|
||||
|
|
@ -1657,6 +1658,7 @@ static CURLcode setopt_cptr_proxy(struct Curl_easy *data, CURLoption option,
|
|||
result = Curl_urldecode(p, 0, &s->str[STRING_PROXYPASSWORD], NULL,
|
||||
REJECT_ZERO);
|
||||
curlx_free(u);
|
||||
curlx_strzero(p);
|
||||
curlx_free(p);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue