vps交流

发现一个github的反代


https://github.innominds.com/

这是怎么做到的?

  1. upstream github {
  2.     server github.com:443;
  3. }
  4. server
  5. {
  6.     server_name xxx.com;
  7.     listen 443 ssl http2 reuseport;
  8.     ssl_certificate /root/ssl/xxx/cert.pem;
  9.     ssl_certificate_key /root/ssl/xxx/key.pem;
  10.     ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  11.     ssl_session_timeout      1d;
  12.     ssl_ciphers EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+ECDSA+AES128:EECDH+aRSA+AES128:RSA+AES128:EECDH+ECDSA+AES256:EECDH+aRSA+AES256:RSA+AES256:EECDH+ECDSA+3DES:EECDH+aRSA+3DES:RSA+3DES:!MD5;
  13.     ssl_prefer_server_ciphers on;
  14.     ssl_session_cache        shared:SSL:50m;
  15.     ssl_session_tickets      on;
  16.     ssl_stapling             on;
  17.     if ($http_user_agent ~* "qihoobot|Baiduspider|Googlebot|Googlebot-Mobile|Googlebot-Image|Mediapartners-Google|Adsbot-Google|Feedfetcher-Google|Yahoo! Slurp|Yahoo! Slurp China|YoudaoBot|Sosospider|Sogou spider|Sogou web spider|MSNBot|ia_archiver|Tomato Bot") #防止搜索引擎收录
  18.     {
  19.         return 403;
  20.     }
  21.     location / {
  22.         proxy_set_header Accept-Encoding "";
  23.         proxy_set_header Connection "";
  24.         proxy_http_version 1.1;
  25.         proxy_connect_timeout    10s;
  26.         proxy_read_timeout       10s;
  27.         proxy_set_header Host github.com;
  28.         proxy_hide_header Strict-Transport-Security; #隐藏协议头,避免因为反向代理开启hsts
  29.         proxy_pass https://github;
  30.     }
  31. }

复制代码

这种吗 https://github.com/hunshcn/gh-proxy
443/tcp open  ssl/http nginx
怎么做到的?你不都说了是反代吗

可乐呀 发表于 2021-11-2 13:16
怎么做到的?你不都说了是反代吗

他这个反代好像不彻底

我就自己建了个 发现一个github的反代