mirror of
https://github.com/3proxy/3proxy.git
synced 2025-06-07 20:14:47 +08:00
Compare commits
2 Commits
f70d09bb96
...
090faef8c0
Author | SHA1 | Date | |
---|---|---|---|
![]() |
090faef8c0 | ||
![]() |
dc4e8d3427 |
11
src/auto.c
11
src/auto.c
@ -22,8 +22,15 @@ void * autochild(struct clientparam* param) {
|
||||
param->res = 801;
|
||||
dolog(param, (unsigned char *)"");
|
||||
}
|
||||
if(*param->clibuf == 4 || *param->clibuf == 5) return sockschild(param);
|
||||
if(*param->clibuf == 22) return tlsprchild(param);
|
||||
if(*param->clibuf == 4 || *param->clibuf == 5) {
|
||||
param->service = S_SOCKS;
|
||||
return sockschild(param);
|
||||
}
|
||||
if(*param->clibuf == 22) {
|
||||
param->service = S_TLSPR;
|
||||
return tlsprchild(param);
|
||||
}
|
||||
param->service = S_PROXY;
|
||||
return proxychild(param);
|
||||
}
|
||||
|
||||
|
@ -190,7 +190,7 @@ int dobuf2(struct clientparam * param, unsigned char * buf, const unsigned char
|
||||
break;
|
||||
|
||||
case 'N':
|
||||
if(param->service < 15) {
|
||||
if(param->service <= MAX_SERVICE) {
|
||||
len = (conf.stringtable)? (int)strlen((char *)conf.stringtable[SERVICES + param->service]) : 0;
|
||||
if(len > 20) len = 20;
|
||||
memcpy(buf+i, (len)?conf.stringtable[SERVICES + param->service]:(unsigned char*)"-", (len)?len:1);
|
||||
|
@ -28,9 +28,9 @@ unsigned char * strings[] = {
|
||||
/* 15 */ (unsigned char *)"DNSPR",
|
||||
/* 16 */ (unsigned char *)"FTPPR",
|
||||
/* 17 */ (unsigned char *)"SMTPP",
|
||||
/* 18 */ (unsigned char *)"ZOMBIE",
|
||||
/* 19 */ NULL,
|
||||
/* 20 */ NULL,
|
||||
/* 18 */ (unsigned char *)"AUTO",
|
||||
/* 19 */ (unsigned char *)"TLSPR",
|
||||
/* 20 */ (unsigned char *)"ZOMBIE",
|
||||
/* 21 */ NULL,
|
||||
/* 22 */ NULL,
|
||||
/* 23 */ NULL,
|
||||
|
@ -181,13 +181,14 @@ typedef enum {
|
||||
S_DNSPR,
|
||||
S_FTPPR,
|
||||
S_SMTPP,
|
||||
S_REVLI,
|
||||
S_REVCO,
|
||||
S_ZOMBIE,
|
||||
S_AUTO,
|
||||
S_TLSPR
|
||||
S_TLSPR,
|
||||
S_ZOMBIE
|
||||
}PROXYSERVICE;
|
||||
|
||||
#define MAX_SERVICE S_ZOMBIE
|
||||
|
||||
|
||||
struct clientparam;
|
||||
struct node;
|
||||
struct symbol;
|
||||
|
Loading…
Reference in New Issue
Block a user