这是 nginx 配置,其他 ok.但是点击图标还是跳转 www.google.com?
已经用 sub_filter 替换了哈~~
感谢
location / {
proxy_ssl_name www.google.com;
proxy_ssl_server_name on;
proxy_redirect off;
proxy_pass https://www.google.com;
proxy_set_header Host www.google.com;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_cookie_domain www.google.com mydomain.com; # 将 www.google.com 域名中发送的 cookie ,都重写为 mydomain.com 域名中的 cookie 。
proxy_set_header User-Agent $http_user_agent;
proxy_set_header Referer www.google.com;
proxy_set_header Accept-Encoding "";
sub_filter 'www.google.com' 'mydomain.com';
sub_filter_once off;
if ($http_user_agent ~* (baiduspider|360spider|haosouspider|googlebot|soso|bing|sogou|yahoo|sohu-search|yodao|YoudaoBot|robozilla|msnbot|MJ12bot|NHN|Twiceler)) {
return 403;
}
}
1
ysc3839 2022-12-18 14:10:04 +08:00 via Android 1
js 脚本写入的?有压缩?
个人还是不建议搞字符串替换,太多意外情况了。 |
2
jsjcjsjc OP |
3
miyuki 2022-12-18 16:42:18 +08:00 via iPhone 1
js 脚本替换的吧,字符串搜索应对不了混淆过后的 js
|
4
aphorism 2022-12-18 17:40:36 +08:00 1
|