Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Nginx Block:
- server {
- listen 80;
- listen [::]:80;
- server_name domain.click www.domain.click;
- return 301 https://$host$request_uri;
- }
- server {
- listen 443 ssl http2 ;
- listen [::]:443 ssl http2 ipv6only=on;
- server_name domain.click www.domain.click;
- ssl_certificate /etc/ssl/certificate.pem;
- ssl_certificate_key /etc/ssl/private.key;
- ssl_protocols TLSv1.2 TLSv1.3;
- ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305;
- ssl_prefer_server_ciphers off;
- ssl_session_cache shared:SSL:50m;
- ssl_session_timeout 1d;
- allow 103.21.244.0/22;
- allow 103.22.200.0/22;
- allow 103.31.4.0/22;
- allow 104.16.0.0/13;
- allow 104.24.0.0/14;
- allow 108.162.192.0/18;
- allow 131.0.72.0/22;
- allow 141.101.64.0/18;
- allow 162.158.0.0/15;
- allow 172.64.0.0/13;
- allow 173.245.48.0/20;
- allow 188.114.96.0/20;
- allow 190.93.240.0/20;
- allow 197.234.240.0/22;
- allow 198.41.128.0/17;
- allow 2400:cb00::/32;
- allow 2606:4700::/32;
- allow 2803:f800::/32;
- allow 2405:b500::/32;
- allow 2405:8100::/32;
- allow 2a06:98c0::/29;
- allow 2c0f:f248::/32;
- deny all;
- location / {
- root /var/www/html;
- index index.html index.htm index.nginx-debian.html;
- }
- location /v2ray {
- if ($http_upgrade != "websocket") {
- return 404;
- }
- proxy_redirect off;
- proxy_pass http://127.0.0.1:10000;
- proxy_http_version 1.1;
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection "upgrade";
- proxy_set_header Host $host;
- 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 $scheme;
- proxy_set_header CF-Connecting-IP $http_cf_connecting_ip;
- proxy_set_header CF-RAY $http_cf_ray;
- proxy_set_header CF-Visitor $http_cf_visitor;
- }
- }
- ###################################################################################################
- V2ray Proxy Server Config:
- {
- "log": {
- "access": "/var/log/v2ray/access.log",
- "error": "/var/log/v2ray/error.log",
- "loglevel": "warning"
- },
- "inbounds": [
- {
- "listen": "127.0.0.1",
- "port": 10000,
- "protocol": "vless",
- "settings": {
- "clients": [
- {
- "id": "a9955fad-xxxx-437c-8ad3-9491de364045",
- "level": 1,
- "alterId": 0
- }
- ],
- "decryption": "none"
- },
- "streamSettings": {
- "network": "ws",
- "wsSettings": {
- "path": "/v2ray"
- }
- },
- "sniffing": {
- "enabled": true,
- "destOverride": [
- "http",
- "tls",
- "quic"
- ]
- }
- }
- ],
- "outbounds": [
- {
- "protocol": "freedom",
- "settings": {
- "domainStrategy": "UseIP"
- },
- "tag": "direct"
- },
- {
- "protocol": "freedom",
- "settings": {
- "domainStrategy": "UseIPv4"
- },
- "tag": "force-ipv4"
- },
- {
- "protocol": "freedom",
- "settings": {
- "domainStrategy": "UseIPv6"
- },
- "tag": "force-ipv6"
- },
- {
- "protocol": "socks",
- "settings": {
- "servers": [
- {
- "address": "127.0.0.1",
- "port": 40000
- }
- ]
- },
- "tag": "socks5-warp"
- },
- {
- "protocol": "blackhole",
- "settings": {},
- "tag": "blocked"
- }
- ],
- "dns": {
- "servers": [
- "https+local://1.1.1.1/dns-query",
- "https+local://8.8.8.8/dns-query",
- "1.1.1.1",
- "8.8.8.8",
- "1.0.0.1",
- "8.8.4.4",
- "localhost"
- ]
- },
- "routing": {
- "domainStrategy": "IPOnDemand",
- "rules": [
- {
- "type": "field",
- "port": 22,
- "outboundTag": "direct"
- },
- {
- "type": "field",
- "ip": [
- "0.0.0.0/8",
- "10.0.0.0/8",
- "100.64.0.0/10",
- "127.0.0.0/8",
- "169.254.0.0/16",
- "172.16.0.0/12",
- "192.0.0.0/24",
- "192.0.2.0/24",
- "192.168.0.0/16",
- "198.18.0.0/15",
- "198.51.100.0/24",
- "203.0.113.0/24",
- "::1/128",
- "fc00::/7",
- "fe80::/10"
- ],
- "outboundTag": "blocked"
- },
- {
- "type": "field",
- "network": "tcp,udp",
- "outboundTag": "socks5-warp"
- }
- ]
- }
- }
- ###################################################################################
- Singbox Client Connection Config:
- {
- "log": {
- "disabled": false,
- "level": "warning",
- "output": "",
- "timestamp": false
- },
- "experimental": {
- "clash_api": {
- "external_controller": "127.0.0.1:20123",
- "external_ui": "",
- "external_ui_download_url": "",
- "external_ui_download_detour": "🎯 Direct",
- "secret": "ID_b6r0wfyp",
- "default_mode": "rule",
- "access_control_allow_origin": [
- "*"
- ],
- "access_control_allow_private_network": false
- },
- "cache_file": {
- "enabled": true,
- "path": "cache.db",
- "cache_id": "",
- "store_fakeip": true,
- "store_rdrc": true,
- "rdrc_timeout": "7d"
- }
- },
- "inbounds": [
- {
- "type": "mixed",
- "tag": "mixed-in",
- "listen": "127.0.0.1",
- "listen_port": 20122,
- "tcp_fast_open": false,
- "tcp_multi_path": false,
- "udp_fragment": false
- },
- {
- "type": "tun",
- "tag": "tun-in",
- "interface_name": "",
- "address": [
- "172.18.0.1/30",
- "fdfe:dcba:9876::1/126"
- ],
- "mtu": 1500,
- "auto_route": true,
- "strict_route": true,
- "endpoint_independent_nat": false,
- "stack": "mixed"
- }
- ],
- "outbounds": [
- {
- "type": "selector",
- "tag": "🚀 Select",
- "interrupt_exist_connections": true,
- "outbounds": [
- "🎈 Auto",
- "USA"
- ]
- },
- {
- "type": "urltest",
- "tag": "🎈 Auto",
- "url": "https://www.gstatic.com/generate_204",
- "interval": "3m",
- "tolerance": 150,
- "interrupt_exist_connections": true,
- "outbounds": [
- "USA"
- ]
- },
- {
- "type": "direct",
- "tag": "🎯 Direct"
- },
- {
- "type": "selector",
- "tag": "🐟 Fallback",
- "interrupt_exist_connections": true,
- "outbounds": [
- "🚀 Select",
- "🎯 Direct",
- "USA"
- ]
- },
- {
- "type": "selector",
- "tag": "GLOBAL",
- "interrupt_exist_connections": true,
- "outbounds": [
- "🚀 Select",
- "🎈 Auto",
- "🎯 Direct",
- "🐟 Fallback",
- "USA"
- ]
- },
- {
- "tag": "USA",
- "type": "vless",
- "server": "domain.click",
- "server_port": 443,
- "uuid": "ce798037-xxxx-48b4-985d-eb51d7193965",
- "tls": {
- "enabled": true,
- "server_name": "domain.click",
- "insecure": false
- },
- "transport": {
- "type": "ws",
- "headers": {},
- "path": "/v2ray"
- }
- }
- ],
- "route": {
- "rules": [
- {
- "action": "sniff",
- "inbound": "tun-in"
- },
- {
- "action": "hijack-dns",
- "protocol": "dns"
- },
- {
- "action": "route",
- "clash_mode": "direct",
- "outbound": "🎯 Direct"
- },
- {
- "action": "route",
- "clash_mode": "global",
- "outbound": "GLOBAL"
- },
- {
- "action": "reject",
- "protocol": "quic"
- },
- {
- "action": "reject",
- "rule_set": [
- "Category-Ads"
- ]
- },
- {
- "action": "reject",
- "rule_set": [
- "GeoSite-Private"
- ]
- },
- {
- "action": "reject",
- "rule_set": [
- "GeoIP-Private"
- ]
- }
- ],
- "rule_set": [
- {
- "tag": "Category-Ads",
- "type": "remote",
- "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/category-ads-all.srs",
- "format": "binary",
- "download_detour": "🎯 Direct"
- },
- {
- "tag": "GeoIP-Private",
- "type": "remote",
- "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geoip/private.srs",
- "format": "binary",
- "download_detour": "🎯 Direct"
- },
- {
- "tag": "GeoSite-Private",
- "type": "remote",
- "url": "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@sing/geo/geosite/private.srs",
- "format": "binary",
- "download_detour": "🎯 Direct"
- }
- ],
- "auto_detect_interface": true,
- "final": "🐟 Fallback"
- },
- "dns": {
- "servers": [
- {
- "tag": "Local-Bootstrap-DNS",
- "address": "https://1.1.1.1/dns-query",
- "address_resolver": "Local-DNS-Resolver",
- "detour": "🎯 Direct"
- },
- {
- "tag": "Local-DNS-Resolver",
- "address": "1.1.1.1",
- "detour": "🎯 Direct"
- },
- {
- "tag": "Remote-DNS",
- "address": "tls://1.1.1.1",
- "address_resolver": "Local-DNS-Resolver",
- "detour": "🚀 Select"
- }
- ],
- "rules": [
- {
- "action": "route",
- "server": "Local-Bootstrap-DNS",
- "domain": ["domain.click"]
- },
- {
- "action": "route",
- "server": "Local-DNS",
- "clash_mode": "direct"
- },
- {
- "action": "route",
- "server": "Remote-DNS",
- "clash_mode": "global"
- }
- ],
- "fakeip": {
- "enabled": false,
- "inet4_range": "198.18.0.0/15",
- "inet6_range": "fc00::/18"
- },
- "disable_cache": false,
- "disable_expire": false,
- "independent_cache": false,
- "final": "Remote-DNS",
- "strategy": "ipv4_only"
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement