mirror of
https://github.com/3proxy/3proxy.git
synced 2025-02-24 02:55:40 +08:00
http connect parent proxy fixed
This commit is contained in:
parent
47e8ba2e8d
commit
0e9cc9e330
@ -38,11 +38,11 @@ int clientnegotiate(struct chain * redir, struct clientparam * param, struct soc
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if(*SAFAMILY(addr) == AF_INET6) buf[len++] = '[';
|
if(*SAFAMILY(addr) == AF_INET6) buf[len++] = '[';
|
||||||
len += myinet_ntop(AF_INET, SAADDR(addr), (char *)buf+8, 256);
|
len += myinet_ntop(AF_INET, SAADDR(addr), (char *)buf+len, 256);
|
||||||
if(*SAFAMILY(addr) == AF_INET6) buf[len++] = ']';
|
if(*SAFAMILY(addr) == AF_INET6) buf[len++] = ']';
|
||||||
}
|
}
|
||||||
len += sprintf((char *)buf + len,
|
len += sprintf((char *)buf + len,
|
||||||
":%hu HTTP/1.0\r\nProxy-Connection: keep-alive\r\n", *SAPORT(addr));
|
":%hu HTTP/1.0\r\nProxy-Connection: keep-alive\r\n", ntohs(*SAPORT(addr)));
|
||||||
if(user){
|
if(user){
|
||||||
unsigned char username[256];
|
unsigned char username[256];
|
||||||
len += sprintf((char *)buf + len, "Proxy-authorization: basic ");
|
len += sprintf((char *)buf + len, "Proxy-authorization: basic ");
|
||||||
@ -263,6 +263,7 @@ int handleredirect(struct clientparam * param, struct ace * acentry){
|
|||||||
default:
|
default:
|
||||||
param->redirectfunc = proxychild;
|
param->redirectfunc = proxychild;
|
||||||
}
|
}
|
||||||
|
if(cur->next)continue;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
else if(!*SAPORT(&cur->addr) && !SAISNULL(&cur->addr)) {
|
else if(!*SAPORT(&cur->addr) && !SAISNULL(&cur->addr)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user