Skip to content
Snippets Groups Projects
Commit fc69abab authored by Jesse Norell's avatar Jesse Norell
Browse files

ispcmail: STARTTLS resets smtp connection and requires second EHLO

parent b4ab929e
No related branches found
No related tags found
No related merge requests found
......@@ -612,6 +612,9 @@ class ispcmail {
if (stream_socket_enable_crypto($this->_smtp_conn, true, $crypto_method) != true) {
return false;
}
fputs($this->_smtp_conn, 'HELO ' . $this->smtp_helo . $this->_crlf);
$response = fgets($this->_smtp_conn, 515);
}
//AUTH LOGIN
......@@ -824,8 +827,7 @@ class ispcmail {
else $rec_string .= $recip;
}
$to = $this->_encodeHeader($rec_string, $this->mail_charset);
//$result = mail($to, $subject, $this->body, implode($this->_crlf, $headers));
$result = mail($to, $enc_subject, $this->body, implode($this->_crlf, $headers));
$result = mail($to, $enc_subject, $this->body, implode($this->_crlf, $headers), "-f $this->_mail_sender");
}
// Reset the subject in case mail is resent
......
......@@ -612,6 +612,9 @@ class ispcmail {
if (stream_socket_enable_crypto($this->_smtp_conn, true, $crypto_method) != true) {
return false;
}
fputs($this->_smtp_conn, 'HELO ' . $this->smtp_helo . $this->_crlf);
$response = fgets($this->_smtp_conn, 515);
}
//AUTH LOGIN
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment