You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

223 lines
11 KiB

  1. # banIP configuration, for further information
  2. # see 'https://github.com/openwrt/packages/blob/master/net/banip/files/README.md'
  3. config banip 'global'
  4. option ban_enabled '0'
  5. option ban_automatic '1'
  6. option ban_fetchutil 'uclient-fetch'
  7. option ban_iface 'wan'
  8. config banip 'extra'
  9. option ban_debug '0'
  10. option ban_maxqueue '8'
  11. config source 'whitelist'
  12. option ban_src '/etc/banip/banip.whitelist'
  13. option ban_src_6 '/etc/banip/banip.whitelist'
  14. option ban_src_desc 'Always allow these IPs (IPv4/IPv6)'
  15. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add whitelist \"\$1}'
  16. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add whitelist_6 \"\$1}'
  17. option ban_src_settype 'net'
  18. option ban_src_ruletype 'src+dst'
  19. option ban_src_on '1'
  20. option ban_src_on_6 '0'
  21. config source 'blacklist'
  22. option ban_src '/etc/banip/banip.blacklist'
  23. option ban_src_6 '/etc/banip/banip.blacklist'
  24. option ban_src_desc 'Always deny these IPs (IPv4/IPv6)'
  25. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add blacklist \"\$1}'
  26. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add blacklist_6 \"\$1}'
  27. option ban_src_settype 'net'
  28. option ban_src_ruletype 'src+dst'
  29. option ban_src_on '0'
  30. option ban_src_on_6 '0'
  31. config source 'bogon'
  32. option ban_src 'https://www.team-cymru.org/Services/Bogons/fullbogons-ipv4.txt'
  33. option ban_src_6 'https://www.team-cymru.org/Services/Bogons/fullbogons-ipv6.txt'
  34. option ban_src_desc 'Bogon prefixes, plus prefixes that have been allocated to RIRs but not yet assigned to ISPs (IPv4/IPv6)'
  35. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add bogon \"\$1}'
  36. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add bogon_6 \"\$1}'
  37. option ban_src_settype 'net'
  38. option ban_src_ruletype 'src+dst'
  39. option ban_src_on '0'
  40. option ban_src_on_6 '0'
  41. config source 'tor'
  42. option ban_src 'https://check.torproject.org/exit-addresses'
  43. option ban_src_desc 'List of Tor Exit Nodes (IPv4)'
  44. option ban_src_rset '/^(ExitAddress ([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add tor \"\$2}'
  45. option ban_src_settype 'ip'
  46. option ban_src_ruletype 'src'
  47. option ban_src_on '0'
  48. option ban_src_on_6 '0'
  49. config source 'threat'
  50. option ban_src 'https://rules.emergingthreats.net/fwrules/emerging-Block-IPs.txt'
  51. option ban_src_desc 'Emerging Threats (IPv4)'
  52. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add threat \"\$1}'
  53. option ban_src_settype 'net'
  54. option ban_src_ruletype 'src'
  55. option ban_src_on '0'
  56. config source 'debl'
  57. option ban_src 'https://www.blocklist.de/downloads/export-ips_all.txt'
  58. option ban_src_6 'https://www.blocklist.de/downloads/export-ips_all.txt'
  59. option ban_src_desc 'Fail2ban reporting service (IPv4/IPv6)'
  60. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add debl \"\$1}'
  61. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add debl_6 \"\$1}'
  62. option ban_src_settype 'ip'
  63. option ban_src_ruletype 'src'
  64. option ban_src_on '0'
  65. option ban_src_on_6 '0'
  66. config source 'myip'
  67. option ban_src 'https://www.myip.ms/files/blacklist/general/latest_blacklist.txt'
  68. option ban_src_6 'https://www.myip.ms/files/blacklist/general/latest_blacklist.txt'
  69. option ban_src_desc 'IP blacklist provided by myip.ms (IPv4/IPv6)'
  70. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add myip \"\$1}'
  71. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add myip_6 \"\$1}'
  72. option ban_src_settype 'ip'
  73. option ban_src_ruletype 'src'
  74. option ban_src_on '0'
  75. option ban_src_on_6 '0'
  76. config source 'yoyo'
  77. option ban_src 'http://pgl.yoyo.org/adservers/iplist.php?ipformat=plain&showintro=0&mimetype=plaintext'
  78. option ban_src_desc 'IP blocklist provided by Peter Lowe (IPv4)'
  79. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add yoyo \"\$1}'
  80. option ban_src_settype 'ip'
  81. option ban_src_ruletype 'src'
  82. option ban_src_on '0'
  83. config source 'zeus'
  84. option ban_src 'https://zeustracker.abuse.ch/blocklist.php?download=ipblocklist'
  85. option ban_src_desc 'Zeus Tracker by abuse.ch (IPv4)'
  86. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add zeus \"\$1}'
  87. option ban_src_settype 'ip'
  88. option ban_src_ruletype 'src'
  89. option ban_src_on '0'
  90. config source 'sslbl'
  91. option ban_src 'https://sslbl.abuse.ch/blacklist/sslipblacklist.csv'
  92. option ban_src_desc 'SSL Blacklist by abuse.ch (IPv4)'
  93. option ban_src_rset 'BEGIN{FS=\",\"}/^(([0-9]{1,3}\.){3}[0-9]{1,3},).*/{print \"add sslbl \"\$1}'
  94. option ban_src_settype 'ip'
  95. option ban_src_ruletype 'src'
  96. option ban_src_on '0'
  97. config source 'ransomware'
  98. option ban_src 'https://ransomwaretracker.abuse.ch/downloads/RW_IPBL.txt'
  99. option ban_src_desc 'Ransomware Tracker by abuse.ch (IPv4)'
  100. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add ransomware \"\$1}'
  101. option ban_src_settype 'ip'
  102. option ban_src_ruletype 'src'
  103. option ban_src_on '0'
  104. config source 'feodo'
  105. option ban_src 'https://feodotracker.abuse.ch/blocklist/?download=ipblocklist'
  106. option ban_src_desc 'Feodo Tracker by abuse.ch (IPv4)'
  107. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add feodo \"\$1}'
  108. option ban_src_settype 'ip'
  109. option ban_src_ruletype 'src'
  110. option ban_src_on '0'
  111. config source 'dshield'
  112. option ban_src 'http://feeds.dshield.org/block.txt'
  113. option ban_src_desc 'Dshield recommended IP blocklist. Contains top 20 attacking class C subnets (IPv4)'
  114. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add dshield \"\$1 \"/\"\$3}'
  115. option ban_src_settype 'net'
  116. option ban_src_ruletype 'src'
  117. option ban_src_on '0'
  118. config source 'proxy'
  119. option ban_src 'https://raw.githubusercontent.com/firehol/blocklist-ipsets/master/proxylists.ipset'
  120. option ban_src_desc 'List of Open Proxies (IPv4)'
  121. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3})([[:space:]]|$)/{print \"add proxy \"\$1}'
  122. option ban_src_settype 'ip'
  123. option ban_src_ruletype 'src'
  124. option ban_src_on '0'
  125. config source 'iblocklist'
  126. option ban_src 'http://list.iblocklist.com/?list=dgxtneitpuvgqqcpfulq&fileformat=cidr&archiveformat=gz'
  127. option ban_src_desc 'Contains advertising trackers and a short list of bad/intrusive porn sites (IPv4)'
  128. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add iblocklist \"\$1}'
  129. option ban_src_settype 'net'
  130. option ban_src_ruletype 'src'
  131. option ban_src_on '0'
  132. config source 'drop'
  133. option ban_src 'https://www.spamhaus.org/drop/drop.txt'
  134. option ban_src_6 'https://www.spamhaus.org/drop/dropv6.txt'
  135. option ban_src_desc 'Spamhaus drop compilation (IPv4/IPv6)'
  136. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add drop \"\$1}'
  137. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add drop_6 \"\$1}'
  138. option ban_src_settype 'net'
  139. option ban_src_ruletype 'src'
  140. option ban_src_on '0'
  141. option ban_src_on_6 '0'
  142. config source 'edrop'
  143. option ban_src 'https://www.spamhaus.org/drop/edrop.txt'
  144. option ban_src_desc 'Spamhaus edrop compilation (IPv4)'
  145. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add edrop \"\$1}'
  146. option ban_src_settype 'net'
  147. option ban_src_ruletype 'src'
  148. option ban_src_on '0'
  149. config source 'firehol1'
  150. option ban_src 'https://raw.githubusercontent.com/firehol/blocklist-ipsets/master/firehol_level1.netset'
  151. option ban_src_desc 'Firehol Level 1 compilation. Contains bogons, spamhaus drop and edrop, dshield and malware lists (IPv4)'
  152. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add firehol1 \"\$1}'
  153. option ban_src_settype 'net'
  154. option ban_src_ruletype 'src'
  155. option ban_src_on '0'
  156. config source 'firehol2'
  157. option ban_src 'https://raw.githubusercontent.com/firehol/blocklist-ipsets/master/firehol_level2.netset'
  158. option ban_src_desc 'Firehol Level 2 compilation. Contains blocklists that track attacks, during the last 48 hours (IPv4)'
  159. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add firehol2 \"\$1}'
  160. option ban_src_settype 'net'
  161. option ban_src_ruletype 'src'
  162. option ban_src_on '0'
  163. config source 'firehol3'
  164. option ban_src 'https://raw.githubusercontent.com/firehol/blocklist-ipsets/master/firehol_level3.netset'
  165. option ban_src_desc 'Firehol Level 3 compilation. Contains blocklists that track attacks, spyware and viruses (IPv4)'
  166. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add firehol3 \"\$1}'
  167. option ban_src_settype 'net'
  168. option ban_src_ruletype 'src'
  169. option ban_src_on '0'
  170. config source 'firehol4'
  171. option ban_src 'https://raw.githubusercontent.com/firehol/blocklist-ipsets/master/firehol_level4.netset'
  172. option ban_src_desc 'Firehol Level 4 compilation. May include a large number of false positives (IPv4)'
  173. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add firehol4 \"\$1}'
  174. option ban_src_settype 'net'
  175. option ban_src_ruletype 'src'
  176. option ban_src_on '0'
  177. config source 'country'
  178. option ban_src 'https://stat.ripe.net/data/country-resource-list/data.json?resource='
  179. option ban_src_6 'https://stat.ripe.net/data/country-resource-list/data.json?resource='
  180. option ban_src_desc 'Build a dynamic IPSet by country iso codes based on RIPE data (IPv4/IPv6)'
  181. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add country \"\$1}'
  182. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add country_6 \"\$1}'
  183. list ban_src_cat 'de'
  184. option ban_src_settype 'net'
  185. option ban_src_ruletype 'src'
  186. option ban_src_on '0'
  187. option ban_src_on_6 '0'
  188. config source 'asn'
  189. option ban_src 'https://stat.ripe.net/data/announced-prefixes/data.json?resource='
  190. option ban_src_6 'https://stat.ripe.net/data/announced-prefixes/data.json?resource='
  191. option ban_src_desc 'Build a dynamic IPSet by ASN numbers based on RIPE data (IPv4/IPv6)'
  192. option ban_src_rset '/^(([0-9]{1,3}\.){3}[0-9]{1,3}(\/[0-9]{1,2})?)([[:space:]]|$)/{print \"add asn \"\$1}'
  193. option ban_src_rset_6 '/^([0-9a-fA-F]{0,4}:){1,7}[0-9a-fA-F]{0,4}(:\/[0-9]{1,2})?([[:space:]]|$)/{print \"add asn_6 \"\$1}'
  194. list ban_src_cat '32934'
  195. option ban_src_settype 'net'
  196. option ban_src_ruletype 'src'
  197. option ban_src_on '0'
  198. option ban_src_on_6 '0'