CProxy/CProxy.conf.explain

91 lines
2.2 KiB
Plaintext
Raw Normal View History

2022-04-23 21:55:24 +08:00
//global模块
global {
2022-04-23 21:55:24 +08:00
//进程UID
uid=3004;
2022-04-23 21:55:24 +08:00
//超时时间(秒)
timeout=60;
//TCP, DNS, UDP监听地址
2020-07-30 18:10:31 +08:00
tcp_listen=0124;
dns_listen=0126;
udp_listen = 10010;
}
2022-04-23 21:55:24 +08:00
//http模块
http {
2022-04-23 21:55:24 +08:00
//http模块关键字: [M], [method], [uri], [U], [V], [version], [H], [host], [port], \r, \n, \v, \f, \b, \t, \a. 如果原本请求头含有关键字也会被替换.
//[M]、[method] 原请求方法
//[U] 原请求url
//[uri] 原请求uri(http 模块)
//[V]、[version] 原请求协议版本
//[host] 原请求host
//[port] 原请求端口
//[H] 原请求[host]:[port]
//指定HTTP服务器IP
http_ip="aixiao.me";
//指定HTTP服务器端口
http_port=129;
2022-04-23 21:55:24 +08:00
//删除HTTP头字段,逗号分开
http_del="Host,";
2022-04-23 21:55:24 +08:00
//自定义HTTP请求头
http_first="[M] [U] [V]\r\nHost: [H]\r\n";
2022-04-23 21:55:24 +08:00
//字符串替换, 以"->"为分界符,"Windows NT 10.0"字符串替换为"Linux"字符串.(可以有多个)
strrep="Windows NT 10.0" -> "Linux";
strrep="Linux" -> "aixiao.me";
strrep="aixiao.me" -> "AIXIAO.ME";
2022-04-23 21:55:24 +08:00
//正则表达式替换, 以"->"为分界符,匹配到的内容"Accept-Encoding*.+?"替换为"Accept-Encoding: GZIP, deflate"字符串.(可以有多个)
regrep="Accept-Encoding*.+?" -> "Accept-Encoding: GZIP, deflate";
regrep="Connection*.+?" -> "Connection: KEEP-alive";
2022-04-23 21:55:24 +08:00
// 编码, 代码128-255要与服务端一致默认为0不编码
encode=129;
}
2022-04-23 21:55:24 +08:00
//https模块
https {
2022-04-23 21:55:24 +08:00
https_ip="aixiao.me";
https_port=129;
https_del="Host,host,x-online-host";
2022-04-23 21:55:24 +08:00
https_first="[M] [U] [V]\r\nHost: [host]:[port]\r\n";
encode=129;
}
2022-04-23 21:55:24 +08:00
//httpdns模块
2020-07-30 18:10:31 +08:00
httpdns {
2022-04-23 21:55:24 +08:00
//httpdns 模块关键字: [M], [D], [V], \r, \n, \v, \f, \b, \t, \a.
//默认 [M] 为 GET
//默认 [V] 为 HTTP/1.0
//HTTPDNS服务器IP
addr = 119.29.29.29:80;
2022-04-23 21:55:24 +08:00
//自定义HTTPDNS请求头
http_req = "[M] [U] [V]\r\nHost: [H]\r\n\r\n";
}
2022-04-23 21:55:24 +08:00
//httpudp模块
httpudp {
2022-04-23 21:55:24 +08:00
//httpudp 模块关键字: [M], [U], [V], [H].
//默认 [M] 为 CONNECT
//默认 [V] 为 HTTP/1.1
//HTTPUDP服务器IP
addr = 47.240.75.93:10010;
2022-04-23 21:55:24 +08:00
//自定义HTTPUDP请求头
http_req = "[M] [U] [V]\r\nHost: [H]\r\n";
2020-07-30 18:10:31 +08:00
}