|
|
|
|
@ -23,9 +23,7 @@ import java.math.BigInteger; |
|
|
|
|
import java.security.MessageDigest; |
|
|
|
|
import java.security.NoSuchAlgorithmException; |
|
|
|
|
import java.text.SimpleDateFormat; |
|
|
|
|
import java.util.Arrays; |
|
|
|
|
import java.util.HashMap; |
|
|
|
|
import java.util.List; |
|
|
|
|
import java.util.Map; |
|
|
|
|
|
|
|
|
|
public class Utils { |
|
|
|
|
@ -82,12 +80,6 @@ public class Utils { |
|
|
|
|
return Sniffer.RULE.matcher(url).find(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public static boolean isVip(String url) { |
|
|
|
|
List<String> hosts = Arrays.asList("iqiyi.com", "v.qq.com", "youku.com", "le.com", "tudou.com", "mgtv.com", "sohu.com", "acfun.cn", "bilibili.com", "baofeng.com", "pptv.com"); |
|
|
|
|
for (String host : hosts) if (url.contains(host)) return true; |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public static String checkProxy(String url) { |
|
|
|
|
if (url.startsWith("proxy://")) return url.replace("proxy://", Server.get().getAddress("proxy?")); |
|
|
|
|
return url; |
|
|
|
|
|