ssh da root olduğunu varsayıyorum
kendi makinemden örnek veriyorum
not : apf için geçerli apf zaten iptables'ın kullanıcı dostu versiyonu gibi birşey

pico /etc/apf/deny_hosts.rules yaz

Alıntı
##
# deny_hosts
#
# Trust based rule file to define addresses that are implicitly denied.
#
# Format of this file is line-seperated addresses, IP masking is supported.
# Example:
# 192.168.2.1
# 192.168.5.0/24
#
# advanced usage
#
# The trust rules can be made in advanced format with 4 options
# (proto:flowort:ip);
# 1) protocol: [packet protocol tcp/udp]
# 2) flow in/out: [packet direction, inbound or outbound]
# 3) s/d=port: [packet source or destination port]
# 4) s/d=ip(/xx) [packet source or destination address, masking supported]
#
# Syntax:
# proto:flow:[s/d]=port:[s/d]=ip(/mask)
# s - source , d - destination , flow - packet flow in/out
#
# Examples:
# inbound to destination port 22 from 192.168.2.1
# tcp:in:d=22:s=192.168.2.1
#
# outbound to destination port 23 to destination host 192.168.2.1
# out:d=23:d=192.168.2.1
#
# inbound to destination port 3306 from 192.168.5.0/24
# d=3306:s=192.168.5.0/24
#
##
# added 88.226.33.146 on 07/26/06 15:37:19
88.226.33.146
# added 88.232.70.99 on 07/26/06 16:39:34
88.232.70.99
# added 222.122.47.31 on 07/27/06 00:00:07 with comment: {bfd.sshd}
222.122.47.31
# added 81.213.250.46 on 07/27/06 09:40:03 with comment: {bfd.pure-ftpd}
81.213.250.46
bu added yanaları ve alt satırındakiler banlanan şahıslardır