Jump to content

手册:$wgDnsBlacklistUrls

From mediawiki.org
This page is a translated version of the page Manual:$wgDnsBlacklistUrls and the translation is 47% complete.
用户权限、访问控制和监视: $wgDnsBlacklistUrls
List of DNS blacklists to use, if $wgEnableDnsBlacklist is true.
引进版本:1.16.0 (r60506)
移除版本:仍在使用
允许的值:(数组、字符串或否) (1.19+)
(字符串数组) (1.16-1.18)
默认值:[ 'http.dnsbl.sorbs.net.', ]

详情

Sets a list of DNS blocklists to use, if $wgEnableDnsBlacklist is set to true. This replaced $wgSorbsUrl .

在1.19版本的变化

Array values can either be a string containing the URL of the DNS blocklist, or an array containing the URL of the blocklist and an associated "key" should the blocklist require one.

範例
$wgDnsBlacklistUrls = [
    'http.dnsbl.sorbs.net.', # 包含URL的字符串
    [ 'dnsbl.httpbl.net.', 'mykey' ], # Array with URL and key, for services that require a key
    [ 'dnsbl.tornevall.org.' ]  # Array with just URL. While this works, it is recommended that you just use a string as shown above
];
or
$wgDnsBlacklistUrls = [
    'xbl.spamhaus.org.',
    'dnsbl.tornevall.org.',
    'spam.dnsbl.sorbs.net.',
    'rbl.dnsbl.im.',
    'noptr.spamrats.com.',
    'all.s5h.net.',
    'z.mailspike.net.'
];

You can find DNSBL-format spam databases on DNSBL.info or other similar websites.

You should end the domain name with a "." to avoid searching your eventual domain search suffixes.

参见

  • $wgProxyList Allows to directly block an individual IP address or a list of IP addresses
  • $wgProxyWhitelist Allows to directly exempt an individual IP address or a list of IP addresses from being blocked