Skip to content
This repository has been archived by the owner on May 2, 2024. It is now read-only.

Commit

Permalink
v3.0.5
Browse files Browse the repository at this point in the history
Author: @AisukaYuki
1. 修改 proxy 相关语句
2. 下架黑名单替换的葫芦娃
3. 上架天线宝宝
  • Loading branch information
david082321 authored May 18, 2021
2 parents 21591a5 + ff30431 commit bd54260
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
8 changes: 5 additions & 3 deletions config.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

// 封锁
define('BLOCK_TYPE','blacklist'); // 封锁类型:blacklist 黑名单, whitelist 本地白名单, 不是填写前面两个就是不封锁
define('REPLACE_TYPE', 'tom'); // 是否替换视频(仅黑/白名单时生效)。hlw 葫芦娃, tom 猫和老鼠, xyy 喜羊羊, all 随机
define('REPLACE_TYPE', 'tom'); // 是否替换视频(仅黑/白名单时生效)。txbb 天线宝宝, tom 猫和老鼠, xyy 喜羊羊, all 随机
define('NEED_LOGIN', 0); //是否要登录用户才能用。0 否, 1 是
define('BILIROAMING', 1); //是否要用哔哩漫游才能使用。0 否, 1 是
define('WEB_ON', 0);//是否开启web接口 0 否, 1 是 目前Web接口不受哔哩漫游请求头影响,且不受服务器锁区影响(待更新)
Expand Down Expand Up @@ -66,8 +66,10 @@
// define('CUSTOM_HOST_TW', $tw_api[$tw_sum]); //随机调用TW 启用要注释上方默认api

// 指定socks5
define('SOCKS5_PROXY', 0); // 开启功能。0 否, 1 是
define('SOCKS5_PROXY_IP', "http://127.0.0.1:1234"); // 自行修改地址
define('PROXY_ON', 0); // 开启功能。0 否, 1 是
//define('PROXYTYPE', "CURLPROXY_HTTP"); // 使用HTTP代理
define('PROXY_TYPE', "CURLPROXY_SOCKS5"); // 使用SOCKS5代理
define('PROXY_IP', "127.0.0.1:1234"); // 自行修改地址

// 指定ip回源
define('IP_RESOLVE', 0); // 开启功能。0 否, 1 是
Expand Down
7 changes: 4 additions & 3 deletions index.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
// 防止外部破解
define('SYSTEM', TRUE);
define('VERSION', '3.0.4');
define('VERSION', '3.0.5');
// 加载配置
include ("config.php");
// 处理用户传入参数
Expand Down Expand Up @@ -127,8 +127,9 @@
function get_webpage($url,$host="",$ip="") {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
if (SOCKS5_PROXY == 1) { // 指定socks5
curl_setopt($ch, CURLOPT_PROXY, SOCKS5_PROXY_IP);
if (PROXY_ON == 1) { // 指定代理
curl_setopt($ch, CURLOPT_PROXYTYPE, PROXY_TYPE);
curl_setopt($ch, CURLOPT_PROXY, PROXY_IP);
}
if (IP_RESOLVE == 1) { // 指定ip回源
curl_setopt($ch, CURLOPT_RESOLVE,[$host.":443:".$ip]);
Expand Down
8 changes: 4 additions & 4 deletions replace.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ function replace() {
$type = "web";
}

if (REPLACE_TYPE == "hlw") {
$url = 'https://black.qimo.ink/hlw.php?type='.$type;
if (REPLACE_TYPE == "txbb") {
$url = 'https://bili.tuturu.top/txbb.php?type='.$type;
}else if (REPLACE_TYPE == "tom") {
$url = 'https://black.qimo.ink/TandJ.php?type='.$type;
}else if (REPLACE_TYPE == "xyy") {
$url = 'https://bili.tuturu.top/xyyjson.php?type='.$type;
}else{
$urls = array('https://black.qimo.ink/hlw.php?type=','https://black.qimo.ink/TandJ.php?type=','https://bili.tuturu.top/xyyjson.php?type=');
$urls = array('https://bili.tuturu.top/txbb.php?type=','https://black.qimo.ink/TandJ.php?type=','https://bili.tuturu.top/xyyjson.php?type=');
$url = $urls[array_rand($urls)].$type;
}
$output = get_webpage($url);
Expand Down Expand Up @@ -91,4 +91,4 @@ function replace() {
$output3 = str_replace("\/","/",$output3);
exit($output3);
}
?>
?>

0 comments on commit bd54260

Please sign in to comment.