Инструменты пользователя

Инструменты сайта


asus_ax4200_proxy

Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

Предыдущая версия справа и слеваПредыдущая версия
Следующая версия
Предыдущая версия
asus_ax4200_proxy [2026/09/17 10:24] – bonterkozasus_ax4200_proxy [2026/10/19 20:42] (текущий) – bonterkoz
Строка 1: Строка 1:
 ====== ASUS AX4200 Proxy (Socks5) на порту 2080 ====== ====== ASUS AX4200 Proxy (Socks5) на порту 2080 ======
 +
 +<code>
 +[SwitchyOmega Conditions]
 +@with result
 +
 +*.kaspersky-labs.com +direct
 +*.yandex.ru +direct
 +*.dokuwiki.org +proxy
 +*.chatgpt.com +proxy
 +*.openai.com +proxy
 +*.oaistatic.com +proxy
 +*.oaiusercontent.com +proxy
 +*.chat.com +proxy
 +*.claude.ai +proxy
 +*.claude.com +proxy
 +*.anthropic.com +proxy
 +*.claudeusercontent.com +proxy
 +*.youtube.com +proxy
 +*.googlevideo.com +proxy
 +*.ytimg.com +proxy
 +*.grok.com +proxy
 +
 +* +direct
 +</code>
 +
 +
 +<code>
 +cat >> /etc/sysctl.conf <<'EOF'
 +net.ipv6.conf.all.disable_ipv6 = 1
 +net.ipv6.conf.default.disable_ipv6 = 1
 +EOF
 +sysctl -p
 +
 +sysctl -w net.ipv6.conf.all.disable_ipv6=1
 +sysctl -w net.ipv6.conf.default.disable_ipv6=1
 +
 +Чтобы пережило перезагрузку, пропишите это в /etc/sysctl.conf
 +cat > /etc/sysctl.d/99-disable-ipv6.conf << 'EOF'
 +net.ipv6.conf.all.disable_ipv6 = 1
 +net.ipv6.conf.default.disable_ipv6 = 1
 +EOF
 +
 +sysctl --system
 +
 +
 +
 +В конфиге Xray на FIN-ноде (или в 3x-ui: Настройки Xray → Outbounds → direct):
 +{
 +  "protocol": "freedom",
 +  "tag": "direct",
 +  "settings": { "domainStrategy": "UseIPv4" }
 +}
 +
 +Если на FIN стоит sing-box (версия 1.12+), в direct-outbound:
 +"domain_resolver": { "server": "local", "strategy": "ipv4_only" }
 +</code>
  
 <code> <code>
Строка 41: Строка 97:
  
 <code> <code>
-[SwitchyOmega Conditions] +1. Проверьте WAN-адрес роутера 
-@with result+ifstatus wan | grep -A2 '"ipv4-address"' 
 +Должен быть 192.168.99.179. Если адрес другой, используйте его или закрепите .179 арендой на MikroTik.
  
-*.chatgpt.com +proxy +2. Проверьте, что проброс применился 
-*.openai.com +proxy +nft list chain inet fw4 dstnat_wan 
-*.oaistatic.com +proxy +nft list chain inet fw4 input_wan 
-*.oaiusercontent.com +proxy +В dstnat_wan должна быть строка с tcp dport 2080 ... dnat ip to 192.168.7.1:2080, в input_wan — ct status dnat accept.
-*.chat.com +proxy +
-*.claude.ai +proxy +
-*.claude.com +proxy +
-*.anthropic.com +proxy +
-*.claudeusercontent.com +proxy +
-*.youtube.com +proxy +
-*.googlevideo.com +proxy +
-*.ytimg.com +proxy +
-*.grok.com +proxy+
  
-* +direct+Причина нашлась: цепочки dstnat_wan нет, а в input_wan нет строки ct status dnat accept. Значит, правило проброса 2080 в firewall не попало. Правило для SSH и web при этом работает: в нём уже 8 пакетов. 
 + 
 +Проверьте, сохранилось ли правило в конфиге: 
 +uci show firewall | grep -A10 redirect 
 + 
 +Если вывод пустой, правило не сохранилось. Добавьте его заново одним блоком: 
 +uci add firewall redirect 
 +uci set firewall.@redirect[-1].name='Proxy-2080-from-homeLAN' 
 +uci set firewall.@redirect[-1].src='wan' 
 +uci set firewall.@redirect[-1].src_ip='192.168.99.0/24' 
 +uci set firewall.@redirect[-1].src_dport='2080' 
 +uci set firewall.@redirect[-1].dest='lan' 
 +uci set firewall.@redirect[-1].dest_ip='192.168.7.1' 
 +uci set firewall.@redirect[-1].dest_port='2080' 
 +uci set firewall.@redirect[-1].proto='tcp' 
 +uci set firewall.@redirect[-1].target='DNAT' 
 +uci commit firewall 
 +/etc/init.d/firewall restart 
 + 
 +Если правило в конфиге есть, значит fw4 его отбросил. Причину покажет: 
 +fw4 check 
 +logread -e firewall | tail -20 
 + 
 +После перезапуска проверьте, что проброс применился: 
 +nft list chain inet fw4 dstnat_wan 
 +Там должна быть строка tcp dport 2080 ... dnat ip to 192.168.7.1:2080. Затем снова запустите с ПК: 
 +curl.exe -x socks5h://192.168.99.179:2080 https://ifconfig.me
 </code> </code>
 +
 +<code>
 +Чтобы ASUS раздавал адреса 192.168.7.x, выполните по SSH:
 +uci set network.lan.ipaddr='192.168.7.1'
 +uci set network.lan.netmask='255.255.255.0'
 +uci set dhcp.lan.start='100'
 +uci set dhcp.lan.limit='150'
 +uci set dhcp.lan.leasetime='12h'
 +uci commit network
 +uci commit dhcp
 +/etc/init.d/network restart
 +/etc/init.d/dnsmasq restart
 +
 +
 +статический адрес на самом OpenWrt:
 +uci set network.wan.proto='static'
 +uci set network.wan.ipaddr='192.168.99.181'
 +uci set network.wan.netmask='255.255.255.0'
 +uci set network.wan.gateway='192.168.99.1'
 +uci set network.wan.dns='192.168.99.1'
 +uci commit network && /etc/init.d/network restart
 +LAN самого ASUS должен быть в другой подсети. Дефолтный 192.168.1.1 подходит.
 +
 +Разрешить web и SSH из 192.168.99.0/24
 +uci add firewall rule
 +uci set firewall.@rule[-1].name='Allow-mgmt-from-homeLAN'
 +uci set firewall.@rule[-1].src='wan'
 +uci set firewall.@rule[-1].src_ip='192.168.99.0/24'
 +uci set firewall.@rule[-1].proto='tcp'
 +uci set firewall.@rule[-1].dest_port='22 80 443'
 +uci set firewall.@rule[-1].family='ipv4'
 +uci set firewall.@rule[-1].target='ACCEPT'
 +uci commit firewall && /etc/init.d/firewall restart
 +</code>
 +
asus_ax4200_proxy.1789629896.txt.gz · Последнее изменение: — bonterkoz

Если не указано иное, содержимое этой вики предоставляется на условиях следующей лицензии: CC Attribution 4.0 International
CC Attribution 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki