mirror of
https://github.com/rofl0r/proxychains-ng.git
synced 2025-11-01 15:06:09 +00:00
fix potential buffer overflow in config file parsing
could be triggered by using username or password exceeding 255 bytes for http type proxies. closes #606
This commit is contained in:
@@ -241,7 +241,7 @@ static int proxy_from_string(const char *proxystring,
|
|||||||
ul = p-u;
|
ul = p-u;
|
||||||
p++;
|
p++;
|
||||||
pl = at-p;
|
pl = at-p;
|
||||||
if(proxytype == RS_PT_SOCKS5 && (ul > 255 || pl > 255))
|
if(ul > 255 || pl > 255)
|
||||||
return 0;
|
return 0;
|
||||||
memcpy(user_buf, u, ul);
|
memcpy(user_buf, u, ul);
|
||||||
user_buf[ul]=0;
|
user_buf[ul]=0;
|
||||||
|
|||||||
Reference in New Issue
Block a user