mirror of
https://github.com/KOP-XIAO/QuantumultX.git
synced 2026-01-25 13:05:10 +00:00
ss-obfs-host问题
This commit is contained in:
@@ -280,6 +280,32 @@ function Rule_Policy(content){ //增加、替换 policy
|
|||||||
} else{return ""}//if RuleK1 check
|
} else{return ""}//if RuleK1 check
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Vmess obfs 参数
|
||||||
|
function Pobfs(jsonl,Pcert,Ptls13){
|
||||||
|
var obfsi=[];
|
||||||
|
var cert=Pcert;
|
||||||
|
tcert= cert==0? "tls-verification=false":"tls-verification=true";
|
||||||
|
tls13= Ptls13==1? "tls13=true":"tls13=false"
|
||||||
|
if(jsonl.net=="ws" && jsonl.tls=="tls"){
|
||||||
|
obfs0="obfs=wss, "+tcert+", "+tls13+", ";
|
||||||
|
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"obfs-uri=/";
|
||||||
|
host0= jsonl.host!=""? "obfs-host="+jsonl.host+",":"";
|
||||||
|
obfsi.push(obfs0+host0+uri0)
|
||||||
|
return obfsi.join(", ")
|
||||||
|
}else if(jsonl.net=="ws"){
|
||||||
|
obfs0="obfs=ws";
|
||||||
|
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"obfs-uri=/";
|
||||||
|
host0= jsonl.host!=""? "obfs-host="+jsonl.host+",":"";
|
||||||
|
obfsi.push(obfs0,host0+uri0);
|
||||||
|
return obfsi.join(", ")
|
||||||
|
}else if(jsonl.tls=="tls"){
|
||||||
|
obfs0="obfs=over-tls, "+tcert+", "+tls13;
|
||||||
|
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"";
|
||||||
|
host0=jsonl.host!=""? ", obfs-host="+jsonl.host:"";
|
||||||
|
obfsi.push(obfs0+host0)
|
||||||
|
return obfsi.join(", ")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//V2RayN 订阅转换成 QUANX 格式
|
//V2RayN 订阅转换成 QUANX 格式
|
||||||
function V2QX(subs,Pudp,Ptfo,Pcert,Ptls13){
|
function V2QX(subs,Pudp,Ptfo,Pcert,Ptls13){
|
||||||
@@ -367,33 +393,6 @@ function filter(servers,Pin,Pout){
|
|||||||
return Nlist
|
return Nlist
|
||||||
}
|
}
|
||||||
|
|
||||||
// Vmess obfs 参数
|
|
||||||
function Pobfs(jsonl,Pcert,Ptls13){
|
|
||||||
var obfsi=[];
|
|
||||||
var cert=Pcert;
|
|
||||||
tcert= cert==0? "tls-verification=false":"tls-verification=true";
|
|
||||||
tls13= Ptls13==1? "tls13=true":"tls13=false"
|
|
||||||
if(jsonl.net=="ws" && jsonl.tls=="tls"){
|
|
||||||
obfs0="obfs=wss, "+tcert+", "+tls13+", ";
|
|
||||||
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"obfs-uri=/";
|
|
||||||
host0= jsonl.host!=""? "obfs-host="+jsonl.host+",":"";
|
|
||||||
obfsi.push(obfs0+host0+uri0)
|
|
||||||
return obfsi.join(", ")
|
|
||||||
}else if(jsonl.net=="ws"){
|
|
||||||
obfs0="obfs=ws";
|
|
||||||
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"obfs-uri=/";
|
|
||||||
host0= jsonl.host!=""? "obfs-host="+jsonl.host+",":"";
|
|
||||||
obfsi.push(obfs0,host0+uri0);
|
|
||||||
return obfsi.join(", ")
|
|
||||||
}else if(jsonl.tls=="tls"){
|
|
||||||
obfs0="obfs=over-tls, "+tcert+", "+tls13+", ";
|
|
||||||
uri0=jsonl.path!=""? "obfs-uri="+jsonl.path:"";
|
|
||||||
host0=jsonl.host!=""? "obfs-host="+jsonl.host:"";
|
|
||||||
obfsi.push(obfs0+host0)
|
|
||||||
return obfsi.join(", ")
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//SSR 转换 quanx 格式
|
//SSR 转换 quanx 格式
|
||||||
function SSR2QX(subs,Pudp,Ptfo){
|
function SSR2QX(subs,Pudp,Ptfo){
|
||||||
const $base64 = new Base64()
|
const $base64 = new Base64()
|
||||||
|
|||||||
Reference in New Issue
Block a user