SSH 공격 대비한 iptables 설정관련 질문
안녕하세요~ 리눅스 초보입니다.
SSH 무작위 공격 대비와 관련된 방법을 알아보던 중에 아래 iptables 설정방법 정보가 있길래 따라해보았습니다.
iptables -N SSH_WHITELIST
iptables -A SSH_WHITELIST -s TRUSTED_HOST_IP -m recent --remove --name SSH -j ACCEPT
iptables -A INPUT -p tcp --dport 22 -m state --state NEW -m recent --set --name SSH
iptables -A INPUT -p tcp --dport 22 -m state --state NEW -j SSH_WHITELIST
iptables -A INPUT -p tcp --dport 22 -m state --state NEW -m recent --update --seconds 60 --hitcount 5 --rttl --name SSH -j ULOG --ulog-prefix SSH_brute_force
iptables -A INPUT -p tcp --dport 22 -m state --state NEW -m recent --update --seconds 60 --hitcount 5 --rttl --name SSH -j DROP: 10 TTL-Match name: SSH side: source
나와있는대로 따라해보았더니 SSH_WHITELIST 라는 체인이 하나 생겼고,
그 안에 61.78.35.213 라는 낯선 아이피가 하나 등록되어 있네요.
ACCEPT all -- 61.78.35.231 anywhere recent: REMOVE name: SSH side: source
이 아이피의 정체와, 이게 왜 등록이 되어있는지 궁금합니다.
위에서 입력한 TRUSTED_HOST_IP 와 관련이 있는건가요?
답변 부탁드립니다~
댓글 달기