Federico
-
Posts
23 -
Joined
-
Last visited
Posts posted by Federico
-
-
I've changed the MX-Record of my domain "fpetit.heliohost.org" to analyze what would happen, but I got this when I try to find the MX record externally when I send an e-mail to federico@fpetit.heliohost.org
Validation resultsconfidence rating: 2 - DNS
The email address passed this level of validation
before the validation stopped due to the error below.
This does not indicate a problem with the address, but
it does not guarantee a good address, either. more info
error at level 3: UnfavorableReplyCode - SMTP server returned an unfavorable reply code, preventing further progress.
canonical address: <federico@fpetit.heliohost.org>
MX records
preference exchange IP address (if included)
0 fpetit.heliohost.org [65.19.143.3]
SMTP session
[Contacting fpetit.heliohost.org [65.19.143.3]...]
[Connected]
220-stevie.heliohost.org ESMTP Exim 4.69 #1 Mon, 02 Mar 2009 14:23:14 -0800
220-We do not authorize the use of this system to transport unsolicited,
220 and/or bulk e-mail.
EHLO hexillion.com
250-stevie.heliohost.org Hello hexillion.com [70.84.211.98]
250-SIZE 52428800
250-PIPELINING
250-AUTH PLAIN LOGIN
250-STARTTLS
250 HELP
MAIL FROM:<HexValidEmail@hexillion.com>
250 OK
RCPT TO:<federico@fpetit.heliohost.org>
451 Temporary local problem - please try later
[unfavorable reply code, cannot continue]
RSET
250 Reset OK
QUIT
221 stevie.heliohost.org closing connection
[Connection closed]
As you can see, the MX record hasn't seemed to have changed, but SMTP gives an error.
-
As far as I know,
Heliohost shouldn't be blocking port25.
Please correct me if I'm wrong.
There's no other explanation. The script is correct and has no errors. A year ago this same script worked fine on Heliohost. Evidently they made some changes.
Fsockopen CANNOT open a connection on port 25.
Service scan
FTP - 21 220---------- Welcome to Pure-FTPd [TLS] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 19:56. Server port: 21.
220-This is a private system - No anonymous login
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
220 Logout.
SMTP - 25 Error: TimedOut
HTTP - 80 HTTP/1.1 200 OK
Date: Mon, 02 Mar 2009 03:56:32 GMT
Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8b mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635
Connection: close
Content-Type: text/html;charset=ISO-8859-1
POP3 - 110 +OK Hello there.
IMAP - 143 * OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION STARTTLS] Courier-IMAP ready. Copyright 1998-2008 Double Precision, Inc. See COPYING for distribution information.
-
It looks like you scripted it wrong, but I'm no expert on php. My advice? Ask a php forum to see if your code is faulty.
The problem is NOT the PHP script. The script has NO errors. Heliohost seems to be blocking port 25
-
I've written a PHP script, with no errors, and I cannot conect to ANY SMTP server using port 25. My script gives the error "Warning: fsockopen() [function.fsockopen]: unable to connect to mail.heliohost.org:25 (Connection timed out)"
The problem is NOT related to the server mail.heliohost.org, but to any other one.
Does anyone know what is going on?
Thank you in advance.
-
Did you add ssl: before it?
I cannot connect to ANY smtp server. Do you have the same problem?
Warning: fsockopen() [function.fsockopen]: unable to connect to smtp.mail.yahoo.com.ar:25 (Connection timed out) in /home/fpetit/public_html/class.smtp.php on line 122
-
Instead of smtp.gmail.com, try using ssl://smtp.gmail.com.
As I said before, no matter what SMTP server I use, I keep getting the same error:
Yahoo!: smtp.mail.yahoo.com.ar
Telered: enviar.telered.com.ar
-
I'm trying to connect to an SMTP relay with fsockopen and I always get the same error, Warning: fsockopen() [function.fsockopen]: unable to connect to smtp.gmail.com:25 (Connection timed out), despite the SMTP server specified. Has Heliohost closed port 25 ?
Thank you
-
The bouncing emails are automatically replied to the sender. I suggest you add a bogus reply-to header.
I recompiled Apache/PHP yesterday - that's probably what did it.but all of a sudden it started working!Well Thanks!
I don't know what a bogus reply is.
-
I fear it might be. Try placing it back into the public_html directory and then pointing your pipe towards it there. If that doesn't work, place it in the public_html/cgi-bin directory and let me know if that works.
Well, I don't know what happened, but all of a sudden it started working!. It seems there was huge delay with your SMTP server.
I also noticed that I can use PHPMailer, which is good for my application.
Anyway, I still receiving the bouncing e-mails.
The files are in the HOME directory.
-
How do you know if it executes when you can't access it through the web in order to execute it? You've put the file in a directory inaccessible to Apache.
I executed in the WWW directory, the I moved it to the root. That's not the point.
-
How much can you comment out before PHP throws the error? It seems the PHP is searching for an extension that we don't provide.
Well, the PHP is quite simple. It executes fine in your server. The problem comes when is executed by the piping method.
-
Hello.
I've recently installed a PHP script, which works fine, to be executed when an e-mail comes.
Unfortunatelly when I send an e-mail to the address that was forwarded to the script, I get this error:
This message was created automatically by mail delivery software. A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: pipe to |/home/fpetit/Tpersonal.php generated by federico@fpetit.heliohost.org The following text was generated during the delivery attempt: ------ pipe to |/home/fpetit/Tpersonal.php generated by federico@fpetit.heliohost.org ------ PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-zts-20060613/ixed.5.2.lin' - /usr/local/lib/php/extensions/no-debug-zts-20060613/ixed.5.2.lin: undefined symbol: executor_globals in Unknown on line 0 Error in argument 1, char 3: option not found Usage: php [-q] [-h] [-s] [-v] [-i] [-f <file>] php <file> [args...] -a Run interactively -C Do not chdir to the script's directory -c <path>|<file> Look for php.ini file in this directory -n No php.ini file will be used -d foo[=bar] Define INI entry foo with value 'bar' -e Generate extended information for debugger/profiler -f <file> Parse <file>. Implies `-q' -h This help -i PHP information -l Syntax check only (lint) -m Show compiled in modules -q Quiet-mode. Suppress HTTP Header output. -s Display colour syntax highlighted source. -v Version number -w Display source with stripped comments and whitespace. -z <file> Load Zend extension <file>.
The script to be executed is:
#!/usr/bin/php -q <?php // read from stdin $fd = fopen("php://stdin", "r"); $email = ""; while (!feof($fd)) { $email .= fread($fd, 1024); } fclose($fd); // handle email $lines = explode("\n", $email); // empty vars $from = ""; $subject = ""; $headers = ""; $message = ""; $splittingheaders = true; for ($i=0; $i < count($lines); $i++) { if(trim($lines[$i])=="") { // empty line, header section has ended $splittingheaders = false; } if($splittingheaders) { // this is a header $headers .= $lines[$i]."\n"; // look out for special headers if (preg_match("/^Subject: (.*)/", $lines[$i], $matches)) { $subject = $matches[1]; } if (preg_match("/^From: (.*)/", $lines[$i], $matches)) { $from = $matches[1]; } } else { // not a header, but message $message .= $lines[$i]."\n"; } } // $from1=strpos($from,'<')+1; // $from2=strpos($from,'>',$from1); // $from3=substr($from,$from1,$from2-$from1); //Only for WLM if (strpos(strtolower($from),'alert@mobile.live.com')!==false) { $message2=strpos($message,' '); $msncontact=substr($message,0,$message2); $cntpos=strpos($message,'):')+2; if (strpos(strtolower($msncontact),'[hotmail]')!==false) { $from=''; } else { $message=$msncontact.substr($message,$cntpos); $from='WLM Alert'; } } //Only for Y! Alert if (strpos(strtolower($from),'y-alerts@reply.yahoo.com')!==false) { $from='Y!Alert'; } // Insertamos PHPMailer $subject='Hola'; $message='Este es el mensaje. Debe llegar a tu cuenta de Yahoo!'; $to = 'federicopetit@yahoo.com.ar'; $subject = 'the subject'; $message = 'hello'; $headers = 'From: webmaster@personal.com.ar' . "\r\n" . 'Reply-To: webmaster@personal.com.ar' . "\r\n" . 'X-Mailer: PHP/' . phpversion(); mail($to, $subject, $message, $headers); return; ?>
As you can see I also included the hashbag at the beginning of the code. The script has 755 permission to be executed.
Thanks for your help
-
Your piping is not working because according to your forwarding command it looks like its not using the php app.
Hope this should solve your problem
As I had told in the original post, the forwarding to the script IS working. The only problem is the nonsense bouncing e-mail.
-
Hmm? If the script is not in your DocRoot (public_HTML/www), then how were you able to test it to confirm that it works properly?
The script captures the email and sends it to an SMS gateway to my cellphone. I'm receiving the emails in my phone, so the script and the piping is working. What it's senseless is the bouncing with NO error message.
-
cPANEL shows:
Address Forward To Functions
flp@fpetit.heliohost.org to |/home/fpetit/email.php Trace Delete
Add Forwarder
-
Just set it to 777, and give me the URL.
Which URL?
-
The user executing the script is not a member of your group. Just set it to 777, and give me the URL. Don't worry; with open_basedir and suPHP it's not much of a security risk to set permissions to 777.
The e-mail keeps bouncing
-
Try setting the script's CHMOD setting to 777.
What for??. It's actually set to 755
-
See if there is an "error_log" file in the same directory as your script.
None
-
I'm not quite sure about the functionality of that feature... what I would do is find some forums that deal with such stuff, find out what's going on by asking there, and if you need me to check or change anything just let me know.
I found very little about email piping on the internet. Very few report problems with piping to script, but in those cases there is an error message that usually is related to a configuration in the server. In my case, there's no error message. The e-mail just bounce.
-
Hello,
Your cPANEL offers the possibility to forward an e-mail to a script. I'm using this service and it's working fine...but the mails send there bounce with the following legend:
pipe to |/home/fpetit/email.phpgenerated by flp@fpetit.heliohost.org
local delivery failed
------ This is a copy of the message, including all the headers. ------
As you can see there is no message error. The PHP script executes fine without errors, so I don't have idea why this is happening.
Thank you
Port 25 (SMTP)
in Website Management and Coding
Posted
It's been months!!!