rhealey@ub.d.umn.edu (Rob Healey) (08/10/88)
For the past few weeks, off and on, I've been trying to futts with sendmail 5.59 so it will send a message to a gateway when it finds that a site is a UUCP connection off the internet site that holds it's MX record. An example: mail joe@site.joe.com site.joe.com has a uucp connection to site.forward.edu. site.forward.edu has a CORRECT MX record for site.joe.com. Our CURRENT sendmail calls an external routeing program which tells sendmail to send all mail destend for joe.com to site.forward.edu. In sendmail -bt mode lingo: >0 joe@site.joe.com oodles of debug info: "^V" "tcp" "^W" "site" "." "forward" "." "edu" "^X" "joe" "<" "@" "site" "." "joe" "." "com" ">" When I try this on 5.59 without the aid of hacking the code to bits so it can call the external router I get: >0 joe@site.joe.com oodles of debug info: "^V" "tcp" "^W" "site" "." "joe" "." "com" "^X" "joe" "<" "@" "site" "." "joe" "." "com" ">" Obviously it thinks site.joe.com is on the internet even though it's not. I did a -d8.99 and the nameserver IS finding the MX record AND the gateway info, it's just not telling sendmail about it. B^(. When you do a $[ site $] how do you tell that a gateway is in the picture. It appears that since it finds some reference to joe.com it assumes it's a tcp destination; DEAD WRONG assumption. I guess I need to reparse the output of $[ site $] somehow, what format should I look for? The external router's output was something like <site.forward.com;site.joe.com;tcp> for gateway addresses and <site.forward.com;tcp> for sites that were an actual tcp destination. WHAT is the $[ site $] equivenlant of this??? Any help would be greatly appreciated, -Rob Healey rhealey@ub.d.umn.edu
kurt@hi.unm.edu (Kurt Zeilenga) (08/10/88)
rhealey@ub.d.umn.edu (Rob Healey) writes (edited): > > For the past few weeks, off and on, I've been trying to futts > with sendmail 5.59 so it will send a message to a gateway when > it finds that a site is a UUCP connection off the internet > site that holds it's MX record. An MX record just gives you a mail exchangers. It says nothing about how your mail will be exchanged to its dest. It could be IP (SMTP), UUCP, BITNET, DECNET, SLIP, CSNET or just about anything. Mostlikily it will be forwarded with LOCAL! Assuming that it is a UUCP connection is WRONG and should not be done! > I did a -d8.99 and the nameserver IS finding the MX record AND > the gateway info, it's just not telling sendmail about it. B^(. Sendmail doesn't need to know! > When you do a $[ site $] how do you tell that a gateway is in You don't, $[ $] are for canonicalize. > the picture. It appears that since it finds some reference to > joe.com it assumes it's a tcp destination; DEAD WRONG assumption. No. It assumes you are going to talk SMTP with the mail exchanger. Dead right good idea. > I guess I need to reparse the output of $[ site $] somehow, what No, $[ $] is going to return the canonical name for the site (if known). > Any help would be greatly appreciated, I would suggest do something similiar to what we do: 1) rewrite address into a standard form and canonicalize with named 2) check to see if it is you - deliver with "local" 3) check to see if it someone you chat with over a non-SMTP link - deliver using whatever 4) check to see if it is a psuedo-domain (.UUCP, .BITNET, etc.)) - deliver to Internet-Whatever gateway 5) Assume SMTP - deliver to lowest MX (or Addr if no MX) 6) Error if not yet delivered. If you're Internet based I see no need to use the UUCP maps for routing and would rather NOT have my domain registered with the project. Use BIND, that's what it's there for. > -Rob Healey > rhealey@ub.d.umn.edu -- Kurt
rhealey@umn-d-ub.D.UMN.EDU (Rob Healey) (08/10/88)
In article <23624@hi.unm.edu> kurt@hi.unm.edu (Kurt Zeilenga) writes: >An MX record just gives you a mail exchangers. It says nothing >about how your mail will be exchanged to its dest. It could be >IP (SMTP), UUCP, BITNET, DECNET, SLIP, CSNET or just about anything. >Mostlikily it will be forwarded with LOCAL! Assuming that it is a >UUCP connection is WRONG and should not be done! I am aware that the low level protocol doesn't matter squat and it shouldn't, that's part of the reason behind all this stuff! See next paragraph. ... >No. It assumes you are going to talk SMTP with the mail exchanger. >Dead right good idea. > Yes, I know. The trouble is it WON'T try to talk to the exchanger, it wants to talk to the non-networked site. B^(. I guess I should clearify. I'll use REAL site names. Say I want to mail to joe@bungia.mn.org. a.cs.uiuc.edu HAS an MX record for mn.org and thus can be used as a gateway to it. HOW do I tell sendmail it should contact a.cs.uiuc.edu rather than bungia.mn.org. bungia.mn.org is a CORRECT canonical name it just doesn't have an SMTP connection. CAN sendmail find out that a.cs.uiuc.edu is the mail exchanger for bungia.mn.org and, finding that out, can it talk to a.cs.uiuc.edu rather than sending out a connect request to bungia.mn.org, a site that isn't directly on the net. Right now, no matter what I try, sendmail wants to talk to the non-networked site, NOT the mail exchanger. How do I get sendmail to talk to the right machine? I thank Mr. Zeilenga for his comments and hope that my clearification explains better the question I was asking. -Rob Healey rhealey@ub.d.umn.edu
matt@oddjob.UChicago.EDU (My Name Here) (08/10/88)
(I saw Kurt's answer to Rob's question but I don't think it explained what Rob wanted to know.) In the case Rob asks about (destination host.dom.ain is not on internet, but has one or more MXs that are), the result of ruleset zero does indeed say to "connect to host.dom.ain by TCP". It is in deliver() [deliver.c], under "# ifdef MXDOMAIN" that the MX records are looked up. Then an SMTP connection is attempted to one of the hosts listed as an MX for host.dom.ain. As long as you define MXDOMAIN, I think your sendmail is going to do the right thing. The MX stuff just doesn't happen where "-bt -dxx.yy" will show it. Matt Crawford
kurt@hi.unm.edu (Kurt Zeilenga) (08/10/88)
In article <453@umn-d-ub.D.UMN.EDU> rhealey@ub.d.umn.edu (Rob Healey) writes: > Yes, I know. The trouble is it WON'T try to talk to the > exchanger, it wants to talk to the non-networked site. B^(. > > I guess I should clearify. I'll use REAL site names. Say I Thanks. I thought you were trying to find reroute hosts that had MX records. I am glad to know you are not doing that. > want to mail to joe@bungia.mn.org. a.cs.uiuc.edu HAS an MX > record for mn.org and thus can be used as a gateway to it. > HOW do I tell sendmail it should contact a.cs.uiuc.edu rather > than bungia.mn.org. bungia.mn.org is a CORRECT canonical name > it just doesn't have an SMTP connection. CAN sendmail find out > that a.cs.uiuc.edu is the mail exchanger for bungia.mn.org and, finding > that out, can it talk to a.cs.uiuc.edu rather than sending out a connect > request to bungia.mn.org, a site that isn't directly on the net. The SMTP mailer will deal with querying for MX records and delivering appropriately. No further sendmail rewriting should be done, the mailer will take it from here. If the host does have any MX records for it then it will be delivered to any known IP addresses that can be found. If no MXs and no As, then the SMTP mailer will return a host unknown error. The SMTP mailer does all this dynamically each time it attempts to deliver the mail (since status of MX'ers may change). I know of no good way of watching it decide the proper MX (does anyone?). > Right now, no matter what I try, sendmail wants to talk to the > non-networked site, NOT the mail exchanger. How do I get sendmail > to talk to the right machine? Sendmail 5.59 should run properly under named (4.8) and does have MX support. You should verify correct installation of named, the libs, and sendmail. Did you compile sendmail with "-DMXDOMAIN"? > I thank Mr. Zeilenga for his comments and hope that my clearification > explains better the question I was asking. Thanks for the clarification and I hope these comments help. > -Rob Healey > rhealey@ub.d.umn.edu
hakanson@mist.cs.orst.edu (Marion Hakanson) (08/10/88)
In article <15002@oddjob.UChicago.EDU> matt@oddjob.UChicago.EDU (My Name Here) writes: >. . . >As long as you define MXDOMAIN, I think your sendmail is going to do >the right thing. The MX stuff just doesn't happen where "-bt -dxx.yy" >will show it. > Matt Crawford Matt's right, sendmail does do what you want, even though it looks like it's trying to connect to the host itself (it's the tcp mailer in this case, not necessarily a TCP connection, BTW). In some other newsgroup recently, we were discussing the other bad effects this invisible approach can cause -- if one of the MX hosts does not have a host number, for example, sendmail says "host unknown" but with the name of the destination host, not the MX host. The only way to diagnose this kind of problem is to use nslookup to simulate what sendmail would be trying to do (look up A records for the hosts in the MX records, basically). The invisible, transparent behavior is nice when it works, but let's have some better diagnostics for MX stuff in sendmail 5.60, please? -- Marion Hakanson Domain: hakanson@cs.orst.edu UUCP : {hp-pcd,tektronix}!orstcs!hakanson