Добрый день. Помогите разобраться с роутером, который настроен на slackware 10.2
Я знаю, что нужно читать книги, и тому подобное, читаю, изучаю, но сейчас окончательно запутался и не могу найти концов. НАстраивалось это не меньше 5 лет назад и концов сейчас не найти.
Есть две подсети. 10.10.10.x и 10.10.11.x
ИЗ 11 подсети можно законектиться только на 2 компа с адресами 10.10.10.244 и 10.10.10.240
Остальные - пингуются, но, например, на RDP подключиться невозможно.
Есть такой конфиг из файла rc.firewall. В нем ли проблема? Если да, то где? Если нет, то где искать? Заранее Спасибо.
#!/bin/sh
echo -e -n "Loading firewall rules..."
# ---------------------------------------------------------
# Defined parameters
# ---------------------------------------------------------
iptables='/usr/sbin/iptables'
int_iface='eth0'
DB_intip='10.10.10.240'
DB_extip='тут внешний ip'
PDC_intip='10.10.10.251'
PDC_extip='тут внешний ip'
TERMINAL_intip='10.10.10.244'
TERMINAL_extip='тут внешний ip'
MAILWEB_intip='10.10.10.252'
MAILWEB_extip='тут внешний ip'
USERS_extip='тут внешний ip'
RDP_intip='10.10.10.8'
RDP_extip='тут внешний ip'
# ---------------------------------------------------------
# Flush all rules
# ---------------------------------------------------------
${iptables} -F
${iptables} -t nat -F
# ---------------------------------------------------------
# Change default policies
# ---------------------------------------------------------
${iptables} -P INPUT ACCEPT
${iptables} -P FORWARD ACCEPT
${iptables} -P OUTPUT ACCEPT
${iptables} -t nat -P PREROUTING ACCEPT
${iptables} -t nat -P POSTROUTING ACCEPT
${iptables} -t nat -P OUTPUT ACCEPT
# ---------------------------------------------------------
# NAT table
# ---------------------------------------------------------
# SNAT for users
${iptables} -t nat -A POSTROUTING -s 10.10.10.0/25 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.10.128/26 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.10.192/27 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.10.224/28 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.11.0/25 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.11.128/26 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.11.192/27 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.11.224/28 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.12.0/25 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.12.128/26 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.12.192/27 -j SNAT --to-source $USERS_extip
${iptables} -t nat -A POSTROUTING -s 10.10.12.224/28 -j SNAT --to-source $USERS_extip
# SNAT for servers
${iptables} -t nat -A POSTROUTING -s $MAILWEB_intip -j SNAT --to-source $MAILWEB_extip
${iptables} -t nat -A POSTROUTING -s $DB_intip -j SNAT --to-source $DB_extip
${iptables} -t nat -A POSTROUTING -s $PDC_intip -j SNAT --to-source $PDC_extip
${iptables} -t nat -A POSTROUTING -s $TERMINAL_intip -j SNAT --to-source $TERMINAL_extip
${iptables} -t nat -A POSTROUTING -s $TEST_intip -j SNAT --to-source $TEST_extip
${iptables} -t nat -A POSTROUTING -s $RDP_intip -j SNAT --to-source $RDP_extip
# DNAT to servers
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p udp --dport 53 -j DNAT --to-destination $MAILWEB_intip
#${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 53 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 25 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 110 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 143 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 80 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 21 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 20 -j DNAT --to-destination $MAILWEB_intip
${iptables} -t nat -A PREROUTING -d $MAILWEB_extip -p tcp --dport 2222 -j DNAT --to-destination $MAILWEB_intip:22
# Redirect local HTTP traffic to SQUID
${iptables} -t nat -A PREROUTING -i $int_iface -p tcp --dport 80 -j REDIRECT --to-port 3128
${iptables} -A INPUT -p tcp --dport 22 -m state --state NEW -m recent --update --seconds 60 --hitcount 3 -j DROP
${iptables} -A INPUT -p tcp --dport 22 -m state --state NEW -m recent --set -j ACCEPT
echo -e -n " Loaded!\n"