I am having this problem on both Red Hat 6.0 and SuSE6.4. I orginally sent the help request to the CGI list but there have been no takers. Since I am having the same problem on Red HAT Linux I thought I would also try this list. Basically, when I use perl script as a CGI operation and evoke sendmail or if I just evoke "sendmail -t" from the command line, my ISP SMTP mail server figures out that the mail is coming from a machine on my private network (spcl.mspt.com) and declares an error resulting in returned mail. Same thing on 3 differen't machines all running Linux. I also tried changing the "from" address to a valid email address external to my private network ([EMAIL PROTECTED]). But the ISP SMTP mail server still knows that the email is coming from a machine on my private network. I can't understand why I would be having this kind of problem and no one knows about the problem. Attached is other correspondence, a typical error message, and the perl script used as well as what I did at the bash command line. Hope someone has a helpful suggestion. Bye-thanks_TED Bye-thanks_TED
Ted Hilts wrote: > > Ted Hilts wrote: > > > > I am forwarding to the cgi-list this sendmail problem I am having in a > > perl script running from apache /usr/local/httpd/cgi-bin on a SuSE6.4 > > Linux OS. > > > > I extracted from several places in the perl script the code I thought > > was relevant just to this problem. > > > > Initially the $sender value was set to the local mail address with the > > same 553 error. At that time a friend suggested that since the local > > address was not resolvable by an external DNS that I should simply > > substitute some valid "from" address which I did, but as you can see I > > still get the same 553 error ("553 spcl.mspt.com does not exist"). This > > can't be an uncommon thing that I am trying to do as a CGI operation. > > > > The ISP DNS server still knows the mail is coming from the machine on my > > network called "spcl.mspt.com" for which it cannot find and IP address > > (at least that's what I think is happening) and I don't appear able to > > fool it otherwise. > > > > Can anyone help me to get this perl script so that it will run from > > cgi-bin under apache and somehow deal with this DNS problem (or whatever > > is the problem) so I can send mail from my private network out onto > > valid internet addresses. I know this is possible because I send and > > get internet mail using the Netscape browser. But this perl script > > problem is associated with CGI operation not Netscape operation. I need > > the operation to be automatic and the mail to be created automatically. > > The script I provided is just a test script. > > > > Any help would be appreciated. > > > > Bye-thanks_TED > > > > ------------------------------------------------------------------------ > > > > Subject: TED's WORK - Sendmail still not working > > Date: Thu, 13 Jul 2000 05:08:20 -0600 > > From: Ted Hilts <[EMAIL PROTECTED]> > > Organization: MarketShare-PT > > To: James Bourne <[EMAIL PROTECTED]> > > > > Jim: > > > > Attached please find the error message resulting from the use of the > > perl script running in cgi-bin. It is apparently being sent by > > [EMAIL PROTECTED] for which the error "553 spcl.mspt.com does not > > exist" is still occuring. > > > > Attached find the extract from my prototype code for just the sendmail > > part. I think it is complete and should be located in cgi-bin. > > > > Bye-thanks_TED > > > > ------------------------------------------------------------------------ > > >From MAILER-DAEMON Thu Jul 13 04:48:05 2000 > > Date: 13 Jul 2000 04:48:05 -0600 > > From: Mail System Internal Data <[EMAIL PROTECTED]> > > Subject: DON'T DELETE THIS MESSAGE -- FOLDER INTERNAL DATA > > X-IMAP: 0963485285 0000000000 > > Status: RO > > > > This text is part of the internal format of your mail folder, and is not > > a real message. It is created automatically by the mail system software. > > If deleted, important folder data will be lost, and it will be re-created > > with the data reset to initial values. > > > > >From [EMAIL PROTECTED] Thu Jul 13 04:40:25 2000 -0600 > > Status: R > > X-Status: > > X-Keywords: > > Return-Path: <MAILER-DAEMON> > > Received: from localhost (localhost) > > by spcl.mspt.com (8.9.3/8.9.3/SuSE Linux 8.9.3-0.1) with internal id >EAB25288; > > Thu, 13 Jul 2000 04:40:25 -0600 > > Date: Thu, 13 Jul 2000 04:40:25 -0600 > > From: Mail Delivery Subsystem <[EMAIL PROTECTED]> > > Message-Id: <[EMAIL PROTECTED]> > > To: [EMAIL PROTECTED] > > MIME-Version: 1.0 > > Content-Type: multipart/report; report-type=delivery-status; > > boundary="EAB25288.963484825/spcl.mspt.com" > > Subject: Postmaster notify: Data format error > > Auto-Submitted: auto-generated (postmaster-notification) > > > > This is a MIME-encapsulated message > > > > --EAB25288.963484825/spcl.mspt.com > > > > The original message was received at Thu, 13 Jul 2000 04:40:24 -0600 > > from wwwrun@localhost > > > > ----- The following addresses had permanent fatal errors ----- > > [EMAIL PROTECTED] > > > > ----- Transcript of session follows ----- > > ... while talking to mx01.telus.net.: > > >>> MAIL From:<[EMAIL PROTECTED]> SIZE=131 > > <<< 553 spcl.mspt.com does not exist > > 501 [EMAIL PROTECTED] Data format error > > > > --EAB25288.963484825/spcl.mspt.com > > Content-Type: message/delivery-status > > > > Reporting-MTA: dns; spcl.mspt.com > > Arrival-Date: Thu, 13 Jul 2000 04:40:24 -0600 > > > > Final-Recipient: RFC822; [EMAIL PROTECTED] > > Action: failed > > Status: 5.1.3 > > Remote-MTA: DNS; mx01.telus.net > > Diagnostic-Code: SMTP; 553 spcl.mspt.com does not exist > > Last-Attempt-Date: Thu, 13 Jul 2000 04:40:25 -0600 > > > > --EAB25288.963484825/spcl.mspt.com > > Content-Type: text/rfc822-headers > > > > Return-Path: <wwwrun> > > Received: (from wwwrun@localhost) > > by spcl.mspt.com (8.9.3/8.9.3/SuSE Linux 8.9.3-0.1) id EAA25286; > > Thu, 13 Jul 2000 04:40:24 -0600 > > Date: Thu, 13 Jul 2000 04:40:24 -0600 > > Message-Id: <[EMAIL PROTECTED]> > > To: [EMAIL PROTECTED] > > From: [EMAIL PROTECTED] > > Subject: Notification of your Resume registration > > > > --EAB25288.963484825/spcl.mspt.com-- > > > > ------------------------------------------------------------------------ > > #!/usr/bin/perl > > > > use CGI; > > > > $query = new CGI; > > > > $mailprog = '/usr/sbin/sendmail'; > > $recipient = "p-thilts\@telusplanet.net"; > > $sender = "thilts\@help-for-you.com"; > > > > ### defined above in the Variables test section $mailprog = >'/usr/sbin/sendmail'; > > ### defined above in the Variables test section $recipient = >"p-thilts\@telusplanet.net"; > > ### defined above in the Variables test section $sender = >"thilts\@help-for-you.com\n"; > > ### Netscape hangs if the internet connection is not up so will comment out until >it works properly. > > open (MAIL, "|$mailprog -t") || die "Can't open $mailprog!\n"; > > print MAIL "To: $recipient\n"; > > print MAIL "From: $sender\n"; > > print MAIL "Subject: Notification of your Resume registration\n\n"; > > print MAIL "Message from perl script. Thank You for submitting you resume >to the help-for-you database service.\n\n"; > > close (MAIL); > > ### > > Yes, the network machine (spcl) is running through a firewall which is > the machine (market). (market) does port forwarding and acts as the > private network access point to the internet via dial up modem. Any > address not found on the local network then gets routed to (market) and > out onto the internet. For example I run Netscape on (spcl) in order to > get out on the internet via (market). But using a bash prompt on > (market) I tried on the command line "/usr/sbin/sendmail -t" and then > input "To: p-thilts@telusplanet" after pressing <ENTER> the next line > was "From: [EMAIL PROTECTED]" after pressing <ENTER> the next line > was "Subject: some_text" after pressing <ENTER> the next line was "Some > kind of message" after pressing <ENTER> the next line was "." and after > pressing <ENTER> I got an immediate mail error message. So I read the > mail and got exactly the same kind of error message stuff as I did for > (spcl). As far as I know the command line stuff would be equivalent to > the perl script running in cgi-bin. > > So in my view this is not a perl script problem and maybe not even a CGI > problem but something to do with how sendmail behaves in a private > network. Like I said before, Netscape doesn't have a problem sending > and receiving mail. I realize they are two completely unrelated > packages. But how it is that Netscape can do this from a private > network and not sendmail. I know the ISP dynamically assigns an IP > address to Netscape and maybe that makes the local private network > resolvable to the ISP DNS machine. So is something like this required > for the perl script in cgi-bin to work????? This is over my head and > I've not read anything in the CGI books about it. > > Bye-thanks_TED