Changeset 1413 in ExiteCMS
- Timestamp:
- 05/18/08 01:04:57 (4 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
-
edit_profile.php (modified) (1 diff)
-
includes/smtp_include.php (modified) (3 diffs)
-
register.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/edit_profile.php
r1281 r1413 96 96 $error .= sprintf($locale['489'], $email_domain)."<br><br>\n"; 97 97 } else { 98 if (!$mail-> Recipient($email)) {98 if (!$mail->CheckRecipient($email)) { 99 99 // mail server doesn't respond to RCPT TO message 100 100 $error .= sprintf($locale['490'], $email, $mailhost)."<br><br>\n"; -
trunk/includes/smtp_include.php
r1412 r1413 714 714 * Implements from rfc 821: RCPT <SP> TO:<forward-path> <CRLF> 715 715 * 716 * SMTP CODE SUCCESS: 250,251 ,450("greylisted")716 * SMTP CODE SUCCESS: 250,251 717 717 * SMTP CODE FAILURE: 550,551,552,553,450,451,452 718 718 * SMTP CODE ERROR : 500,501,503,421 … … 738 738 } 739 739 740 if($code != 250 && $code != 251 && ($code == 450 && strpos(strtolower($reply), "greylist")===false)) {740 if($code != 250 && $code != 251) { 741 741 $this->error = 742 742 array("error" => "RCPT not accepted from server", … … 750 750 } 751 751 return true; 752 } 753 754 /** 755 * Sends the command RCPT to the SMTP server with the TO: argument of $to. 756 * Returns true if the recipient was accepted false if it was rejected. 757 * 758 * Implements some extra SUCCESS codes, based on the reply text 759 * 760 * Implements from rfc 821: RCPT <SP> TO:<forward-path> <CRLF> 761 * 762 * SMTP CODE SUCCESS: 250,251 763 * SMTP CODE SUCCESS: 450 ("%greylist%") 764 * SMTP CODE FAILURE: 550,551,552,553,450,451,452 765 * SMTP CODE ERROR : 500,501,503,421 766 * @access public 767 * @return bool 768 */ 769 function CheckRecipient($to) { 770 $this->error = null; # so no confusion is caused 771 772 if(!$this->connected()) { 773 $this->error = array( 774 "error" => "Called Recipient() without being connected"); 775 return false; 776 } 777 778 fputs($this->smtp_conn,"RCPT TO:<" . $to . ">" . $this->CRLF); 779 780 $rply = $this->get_lines(); 781 $code = substr($rply,0,3); 782 783 if($this->do_debug >= 2) { 784 echo "SMTP -> FROM SERVER:" . $this->CRLF . $rply; 785 } 786 787 // standard success codes 788 if($code == 250 || $code == 251) { 789 return true; 790 } 791 792 // ESMTP Postfix greylist filter 793 if($code == 450 && strpos(strtolower($reply), "greylisted")===false) { 794 return true; 795 } 796 797 $this->error = 798 array("error" => "RCPT not accepted from server", 799 "smtp_code" => $code, 800 "smtp_msg" => substr($rply,4)); 801 if($this->do_debug >= 1) { 802 echo "SMTP -> ERROR: " . $this->error["error"] . 803 ": " . $rply . $this->CRLF; 804 } 805 return false; 752 806 } 753 807 -
trunk/register.php
r1401 r1413 99 99 $error .= sprintf($locale['413'], $email_domain)."<br /><br />\n"; 100 100 } else { 101 if (!$mail-> Recipient($email)) {101 if (!$mail->CheckRecipient($email)) { 102 102 // mail server doesn't respond to RCPT TO message 103 103 $error .= sprintf($locale['414'], $email, $mailhost)."<br /><br />\n";
Note: See TracChangeset
for help on using the changeset viewer.
