lmb@vicom.COM (Larry Blair) (02/05/89)
Reading sendmail manual (as distributed by Sun), it appears that path given to sendmail is parsed by rule 3, then 0, which determines which mailer to use. The To: address is then parsed by 3, and in the case of uucp mail, 23. The From: goes through 3, then 13. I decided that I didn't like the way my To: lines went out, so I started mucking with ruleset 5, called by 23. One of the (apparently) more important things I did was to remove the rule that generated u%h and add some that would generate u@h. I didn't touch ruleset 0, or any ruleset called by 0. While sendmail -bt says that ruleset 0 works correctly and ruleset 23 works the way I want, the value of $h!$u passed to the mailer is messed up. Specifically, if I enter a!b!c, the mailer gets a!c@b. Who's screwing it up? -- Larry Blair ames!vsi1!lmb lmb@vicom.com
gandalf@csli.STANFORD.EDU (Juergen Wagner) (02/06/89)
The process of finding a mailer/host/mailbox is not just captured by rulesets 3 and 0. The function parseaddr which "Parses an address and breaks it up into three parts: a net to transmit the message on, the host to transmit it to, and a user on that host." does the following: o parse the address into tokens; o rewrite it by ruleset #3 (canonicalization); o rewrite it by ruleset #0 (giving $# mailer $@ host $: mailbox); o call buildaddr to build an address from the resulting specification. Now, buildaddr checks the mailer and the host, and then calls ruleset #2 to do recipient rewriting, calls the mailer-specific recipient rewriting ruleset, and calls ruleset #4 to clean up everything (externalize). To summarize, there is more to it than just #3 and #0. -- Juergen Wagner gandalf@csli.stanford.edu wagner@arisia.xerox.com