Prev | Current Page 559 | Next

Bryan Costales, Claus Assmann, George Jansen, Gregory Shapiro

"sendmail, 4th Edition"

h file.
The /map rule-testing command is very useful for testing databases of your own
design. If a rule that uses the database fails to work as predicted, use /map to test that
database by hand. To illustrate, consider the sampling of maps in the following
sections.
8.5.3.1 The aliases database map
The aliases map is used to convert a local address into one or more new addresses.
Using the rule-testing /map command, you can see how sendmail looks up an alias:
> /map aliases root
map_lookup: aliases (root) returns you, hans@other.site (0)
8.5.3.2 The host map
The host database behaves the same as the /canon command shown earlier. It looks
up a hostname by using sendmail??™s internal host map (?§23.4.3 on page 895) which
returns the canonical name of the looked-up host:
This is the Title of the Book, eMatter Edition
Copyright ?© 2007 O??™Reilly & Associates, Inc. All rights reserved.
8.5 Complex Actions Made Simple | 311
> /map host localhost
map_lookup: host (localhost) returns localhost.our.domain. (0)
> /map host bogus.no.domain
map_lookup: host (bogus.no.domain) no match (68)
8.5.3.3 The dequote map
The dequote map (?§23.7.5 on page 904) is not really a database at all, but a hook into
a routine that removes quotation marks from addresses:
> /map dequote "a"@"@b"
map_lookup: dequote ("a"@"@b") returns a@@b (0)
> /map dequote "a
map_lookup: dequote ("a) no match (0)
> /map dequote "map_lookup: dequote ("> /map dequote "(a"
map_lookup: dequote ("(a") no match (0)
Note in the second example that it removes only balanced quotation marks.


Pages:
547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571
pozycjonowanie dieta light szkolenia bhp warszawa życzenia szambo betonowe