1 <!doctype html public
"-//W3C//DTD HTML 4.01 Transitional//EN"
2 "http://www.w3.org/TR/html4/loose.dtd">
4 <meta http-equiv=
"Content-Type" content=
"text/html; charset=us-ascii">
5 <title> Postfix manual - cidr_table(
5)
</title>
7 CIDR_TABLE(
5) CIDR_TABLE(
5)
10 cidr_table - format of Postfix CIDR tables
13 <b>postmap -q
"</b><i>string</i><b>" <a href=
"cidr_table.5.html">cidr
</a>:/etc/postfix/
</b><i>filename
</i>
15 <b>postmap -q -
<a href=
"cidr_table.5.html">cidr
</a>:/etc/postfix/
</b><i>filename
</i> <<i>inputfile
</i>
18 The Postfix mail system uses optional lookup tables.
19 These tables are usually in
<b>dbm
</b> or
<b>db
</b> format. Alterna-
20 tively, lookup tables can be specified in CIDR (Classless
21 Inter-Domain Routing) form. In this case, each input is
22 compared against a list of patterns. When a match is
23 found, the corresponding result is returned and the search
26 To find out what types of lookup tables your Postfix sys-
27 tem supports use the
"<b>postconf -m</b>" command.
29 To test lookup tables, use the
"<b>postmap -q</b>" command as
30 described in the SYNOPSIS above.
33 The general form of a Postfix CIDR table is:
35 <i>network
</i><b>_
</b><i>address
</i><b>/
</b><i>network
</i><b>_
</b><i>mask result
</i>
36 When a search string matches the specified network
37 block, use the corresponding
<i>result
</i> value. Specify
38 0.0.0.0/
0 to match every IPv4 address, and ::/
0 to
39 match every IPv6 address.
41 An IPv4 network address is a sequence of four deci-
42 mal octets separated by
".", and an IPv6 network
43 address is a sequence of three to eight hexadecimal
44 octet pairs separated by
":".
46 Before comparisons are made, lookup keys and table
47 entries are converted from string to binary. There-
48 fore table entries will be matched regardless of
49 redundant zero characters.
51 Note: address information may be enclosed inside
52 "[]" but this form is not required.
54 IPv6 support is available in Postfix
2.2 and later.
56 <i>network
</i><b>_
</b><i>address result
</i>
57 When a search string matches the specified network
58 address, use the corresponding
<i>result
</i> value.
60 blank lines and comments
61 Empty lines and whitespace-only lines are ignored,
62 as are lines whose first non-whitespace character
66 A logical line starts with non-whitespace text. A
67 line that starts with whitespace continues a logi-
70 <b>TABLE SEARCH ORDER
</b>
71 Patterns are applied in the order as specified in the ta-
72 ble, until a pattern is found that matches the search
75 <b>EXAMPLE SMTPD ACCESS MAP
</b>
76 /etc/postfix/
<a href=
"postconf.5.html">main.cf
</a>:
77 <a href=
"postconf.5.html#smtpd_client_restrictions">smtpd_client_restrictions
</a> = ...
<a href=
"cidr_table.5.html">cidr
</a>:/etc/postfix/client.cidr ...
79 /etc/postfix/client.
<a href=
"cidr_table.5.html">cidr
</a>:
80 # Rule order matters. Put more specific whitelist entries
81 # before more general blacklist entries.
86 <a href=
"postmap.1.html">postmap(
1)
</a>, Postfix lookup table manager
87 <a href=
"regexp_table.5.html">regexp_table(
5)
</a>, format of regular expression tables
88 <a href=
"pcre_table.5.html">pcre_table(
5)
</a>, format of PCRE tables
91 <a href=
"DATABASE_README.html">DATABASE_README
</a>, Postfix lookup table overview
94 CIDR table support was introduced with Postfix version
2.1.
97 The CIDR table lookup code was originally written by:
99 KFKI Research Institute for Particle and Nuclear Physics
101 1525 Budapest, Hungary
103 Adopted and adapted by:
105 IBM T.J. Watson Research
107 Yorktown Heights, NY
10598, USA
110 </pre> </body> </html>