diff options
| author | heas <heas@NetBSD.org> | 2007-05-19 16:27:18 +0000 |
|---|---|---|
| committer | heas <heas@NetBSD.org> | 2007-05-19 16:27:18 +0000 |
| commit | a92486476636c4e9fe3583290c6466524472a1c3 (patch) | |
| tree | 4562082c58210a6f4df616bf30e1a882082051ab /gnu/dist/postfix/html/pgsql_table.5.html | |
| parent | a118ee6dde2e34601c4502f218098cfce016d1ab (diff) | |
postfix 2.4.1
Diffstat (limited to 'gnu/dist/postfix/html/pgsql_table.5.html')
| -rw-r--r-- | gnu/dist/postfix/html/pgsql_table.5.html | 122 |
1 files changed, 60 insertions, 62 deletions
diff --git a/gnu/dist/postfix/html/pgsql_table.5.html b/gnu/dist/postfix/html/pgsql_table.5.html index 13152c9a5e1..39904c4ab33 100644 --- a/gnu/dist/postfix/html/pgsql_table.5.html +++ b/gnu/dist/postfix/html/pgsql_table.5.html @@ -21,27 +21,27 @@ PGSQL_TABLE(5) PGSQL_TABLE(5) Alternatively, lookup tables can be specified as Post- greSQL databases. In order to use PostgreSQL lookups, - define a PostgreSQL source as a lookup table in main.cf, + define a PostgreSQL source as a lookup table in <a href="postconf.5.html">main.cf</a>, for example: <a href="postconf.5.html#alias_maps">alias_maps</a> = <a href="pgsql_table.5.html">pgsql</a>:/etc/pgsql-aliases.cf The file /etc/postfix/pgsql-aliases.cf has the same format - as the Postfix main.cf file, and can specify the parame- + as the Postfix <a href="postconf.5.html">main.cf</a> file, and can specify the parame- ters described below. <b>BACKWARDS COMPATIBILITY</b> For compatibility with other Postfix lookup tables, Post- - greSQL parameters can also be defined in main.cf. In + greSQL parameters can also be defined in <a href="postconf.5.html">main.cf</a>. In order to do that, specify as PostgreSQL source a name that doesn't begin with a slash or a dot. The PostgreSQL parameters will then be accessible as the name you've given the source in its definition, an underscore, and the name of the parameter. For example, if the map is speci- fied as "<a href="pgsql_table.5.html">pgsql</a>:<i>pgsqlname</i>", the parameter "hosts" below - would be defined in main.cf as "<i>pgsqlname</i>_hosts". + would be defined in <a href="postconf.5.html">main.cf</a> as "<i>pgsqlname</i>_hosts". Note: with this form, the passwords for the PostgreSQL - sources are written in main.cf, which is normally world- + sources are written in <a href="postconf.5.html">main.cf</a>, which is normally world- readable. Support for this form will be removed in a future Postfix version. @@ -121,132 +121,130 @@ PGSQL_TABLE(5) PGSQL_TABLE(5) <b>query</b> The SQL query template used to search the database, where <b>%s</b> is a substitute for the address Postfix is trying to resolve, e.g. - query = SELECT replacement FROM aliases WHERE - mailbox = '%s' + query = SELECT replacement FROM aliases WHERE mailbox = '%s' - This parameter supports the following '%' expan- + This parameter supports the following '%' expan- sions: <b>%%</b> This is replaced by a literal '%' character. (Postfix 2.2 and later) - <b>%s</b> This is replaced by the input key. SQL - quoting is used to make sure that the input - key does not add unexpected metacharacters. + <b>%s</b> This is replaced by the input key. SQL + quoting is used to make sure that the input + key does not add unexpected metacharacters. <b>%u</b> When the input key is an address of the form user@domain, <b>%u</b> is replaced by the SQL - quoted local part of the address. Other- - wise, <b>%u</b> is replaced by the entire search - string. If the localpart is empty, the - query is suppressed and returns no results. + quoted local part of the address. Other- + wise, <b>%u</b> is replaced by the entire search + string. If the localpart is empty, the + query is suppressed and returns no results. <b>%d</b> When the input key is an address of the form user@domain, <b>%d</b> is replaced by the SQL - quoted domain part of the address. Other- + quoted domain part of the address. Other- wise, the query is suppressed and returns no results. <b>%[SUD]</b> The upper-case equivalents of the above - expansions behave in the <b>query</b> parameter + expansions behave in the <b>query</b> parameter identically to their lower-case counter- parts. With the <b>result_format</b> parameter (see below), they expand the input key rather than the result value. - The above %S, %U and %D expansions are + The above %S, %U and %D expansions are available with Postfix 2.2 and later - <b>%[1-9]</b> The patterns %1, %2, ... %9 are replaced by + <b>%[1-9]</b> The patterns %1, %2, ... %9 are replaced by the corresponding most significant component - of the input key's domain. If the input key + of the input key's domain. If the input key is <i>user@mail.example.com</i>, then %1 is <b>com</b>, %2 - is <b>example</b> and %3 is <b>mail</b>. If the input key + is <b>example</b> and %3 is <b>mail</b>. If the input key is unqualified or does not have enough - domain components to satisfy all the speci- - fied patterns, the query is suppressed and + domain components to satisfy all the speci- + fied patterns, the query is suppressed and returns no results. - The above %1, ... %9 expansions are avail- + The above %1, ... %9 expansions are avail- able with Postfix 2.2 and later - The <b>domain</b> parameter described below limits the - input keys to addresses in matching domains. When - the <b>domain</b> parameter is non-empty, SQL queries for - unqualified addresses or addresses in non-matching + The <b>domain</b> parameter described below limits the + input keys to addresses in matching domains. When + the <b>domain</b> parameter is non-empty, SQL queries for + unqualified addresses or addresses in non-matching domains are suppressed and return no results. - The precedence of this parameter has changed with - Postfix 2.2, in prior releases the precedence was, - from highest to lowest, <b>select_function</b>, <b>query</b>, + The precedence of this parameter has changed with + Postfix 2.2, in prior releases the precedence was, + from highest to lowest, <b>select_function</b>, <b>query</b>, <b>select_field</b>, ... - With Postfix 2.2 the <b>query</b> parameter has highest + With Postfix 2.2 the <b>query</b> parameter has highest precedence, see COMPATIBILITY above. NOTE: DO NOT put quotes around the <b>query</b> parameter. <b>result_format (default: %s</b>) - Format template applied to result attributes. Most - commonly used to append (or prepend) text to the - result. This parameter supports the following '%' + Format template applied to result attributes. Most + commonly used to append (or prepend) text to the + result. This parameter supports the following '%' expansions: <b>%%</b> This is replaced by a literal '%' character. - <b>%s</b> This is replaced by the value of the result - attribute. When result is empty it is + <b>%s</b> This is replaced by the value of the result + attribute. When result is empty it is skipped. - <b>%u</b> When the result attribute value is an + <b>%u</b> When the result attribute value is an address of the form user@domain, <b>%u</b> is - replaced by the local part of the address. + replaced by the local part of the address. When the result has an empty localpart it is skipped. - <b>%d</b> When a result attribute value is an address - of the form user@domain, <b>%d</b> is replaced by + <b>%d</b> When a result attribute value is an address + of the form user@domain, <b>%d</b> is replaced by the domain part of the attribute value. When the result is unqualified it is skipped. <b>%[SUD1-9]</b> - The upper-case and decimal digit expansions + The upper-case and decimal digit expansions interpolate the parts of the input key - rather than the result. Their behavior is - identical to that described with <b>query</b>, and - in fact because the input key is known in - advance, queries whose key does not contain - all the information specified in the result - template are suppressed and return no + rather than the result. Their behavior is + identical to that described with <b>query</b>, and + in fact because the input key is known in + advance, queries whose key does not contain + all the information specified in the result + template are suppressed and return no results. For example, using "result_format = <a href="smtp.8.html">smtp</a>:[%s]" allows one to use a mailHost attribute as the basis - of a <a href="transport.5.html">transport(5)</a> table. After applying the result - format, multiple values are concatenated as comma - separated strings. The expansion_limit and parame- + of a <a href="transport.5.html">transport(5)</a> table. After applying the result + format, multiple values are concatenated as comma + separated strings. The expansion_limit and parame- ter explained below allows one to restrict the num- - ber of values in the result, which is especially + ber of values in the result, which is especially useful for maps that must return at most one value. - The default value <b>%s</b> specifies that each result + The default value <b>%s</b> specifies that each result value should be used as is. - This parameter is available with Postfix 2.2 and + This parameter is available with Postfix 2.2 and later. NOTE: DO NOT put quotes around the result format! <b>domain (default: no domain list)</b> - This is a list of domain names, paths to files, or - dictionaries. When specified, only fully qualified - search keys with a *non-empty* localpart and a - matching domain are eligible for lookup: 'user' - lookups, bare domain lookups and "@domain" lookups - are not performed. This can significantly reduce + This is a list of domain names, paths to files, or + dictionaries. When specified, only fully qualified + search keys with a *non-empty* localpart and a + matching domain are eligible for lookup: 'user' + lookups, bare domain lookups and "@domain" lookups + are not performed. This can significantly reduce the query load on the PostgreSQL server. - domain = postfix.org, hash:/etc/postfix/search- - domains + domain = postfix.org, hash:/etc/postfix/searchdomains It is best not to use SQL to store the domains eli- gible for SQL lookups. |
