以下是我的配置文件: server { server_name www.example.com; location / { proxy_pass https://www.google.com/; proxy_redirect https://www.google.com/ /; # proxy_redirect off; proxy_cookie_domain google.com www.example.com; proxy_set_header Host “www.google.com”; proxy_set_header Referer https://www.google.com; proxy_set_header Accept-Encoding “”; proxy_set_header Accept-Language “en-US”; proxy_set_header User-Agent $http_user_agent; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto https; subs_filter http://www.google.com http://www.example.com; subs_filter https://www.google.com http://www.example.com; sub_filter_once off; # 这里替换网页中的链接,因为我们的镜像站是http的,所以上面顺便把协议也一起替换了 } } 复制代码
可是只能打开 google 首页,搜索的话会显示连接已重置,求解?有没有做过的大哥解答一下呢?
湖北省网友说:记得之前有个jsproxy.ga挺好用的,可惜不知道咋没了
河南省网友说:把小鸡IPV6关掉试试,或者把相关域名的IPv4在hosts里写死
福建省网友说:你不怕域名 ip被封么
河南省网友说:Google的结果中有一大把的其他域名,需要全部替换。
云南省网友说:用http 还怎么搜,结果页动不动就是敏感词
辽宁省网友说:自行参考:https://linuxeye.com/450.html