亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? class.smtp.php

?? 一個bug追蹤工具的PHP編寫的源代碼
?? PHP
?? 第 1 頁 / 共 3 頁
字號:
<?php////////////////////////////////////////////////////// SMTP - PHP SMTP class//// Version 1.02//// Define an SMTP class that can be used to connect// and communicate with any SMTP server. It implements// all the SMTP functions defined in RFC821 except TURN.//// Author: Chris Ryan//// License: LGPL, see LICENSE/////////////////////////////////////////////////////** * SMTP is rfc 821 compliant and implements all the rfc 821 SMTP * commands except TURN which will always return a not implemented * error. SMTP also provides some utility methods for sending mail * to an SMTP server. * @package PHPMailer * @author Chris Ryan */class SMTP{    /**     *  SMTP server port     *  @var int     */    var $SMTP_PORT = 25;    /**     *  SMTP reply line ending     *  @var string     */    var $CRLF = "\r\n";    /**     *  Sets whether debugging is turned on     *  @var bool     */    var $do_debug;       # the level of debug to perform    /**#@+     * @access private     */    var $smtp_conn;      # the socket to the server    var $error;          # error if any on the last call    var $helo_rply;      # the reply the server sent to us for HELO    /**#@-*/    /**     * Initialize the class so that the data is in a known state.     * @access public     * @return void     */    function SMTP() {        $this->smtp_conn = 0;        $this->error = null;        $this->helo_rply = null;        $this->do_debug = 0;    }    /*************************************************************     *                    CONNECTION FUNCTIONS                  *     ***********************************************************/    /**     * Connect to the server specified on the port specified.     * If the port is not specified use the default SMTP_PORT.     * If tval is specified then a connection will try and be     * established with the server for that number of seconds.     * If tval is not specified the default is 30 seconds to     * try on the connection.     *     * SMTP CODE SUCCESS: 220     * SMTP CODE FAILURE: 421     * @access public     * @return bool     */    function Connect($host,$port=0,$tval=30) {        # set the error val to null so there is no confusion        $this->error = null;        # make sure we are __not__ connected        if($this->connected()) {            # ok we are connected! what should we do?            # for now we will just give an error saying we            # are already connected            $this->error =                array("error" => "Already connected to a server");            return false;        }        if(empty($port)) {            $port = $this->SMTP_PORT;        }        #connect to the smtp server        $this->smtp_conn = fsockopen($host,    # the host of the server                                     $port,    # the port to use                                     $errno,   # error number if any                                     $errstr,  # error message if any                                     $tval);   # give up after ? secs        # verify we connected properly        if(empty($this->smtp_conn)) {            $this->error = array("error" => "Failed to connect to server",                                 "errno" => $errno,                                 "errstr" => $errstr);            if($this->do_debug >= 1) {                echo "SMTP -> ERROR: " . $this->error["error"] .                         ": $errstr ($errno)" . $this->CRLF;            }            return false;        }        # sometimes the SMTP server takes a little longer to respond        # so we will give it a longer timeout for the first read        // Windows still does not have support for this timeout function        if(substr(PHP_OS, 0, 3) != "WIN")           socket_set_timeout($this->smtp_conn, $tval, 0);        # get any announcement stuff        $announce = $this->get_lines();        # set the timeout  of any socket functions at 1/10 of a second        //if(function_exists("socket_set_timeout"))        //   socket_set_timeout($this->smtp_conn, 0, 100000);        if($this->do_debug >= 2) {            echo "SMTP -> FROM SERVER:" . $this->CRLF . $announce;        }        return true;    }    /**     * Performs SMTP authentication.  Must be run after running the     * Hello() method.  Returns true if successfully authenticated.     * @access public     * @return bool     */    function Authenticate($username, $password) {        // Start authentication        fputs($this->smtp_conn,"AUTH LOGIN" . $this->CRLF);        $rply = $this->get_lines();        $code = substr($rply,0,3);        if($code != 334) {            $this->error =                array("error" => "AUTH not accepted from server",                      "smtp_code" => $code,                      "smtp_msg" => substr($rply,4));            if($this->do_debug >= 1) {                echo "SMTP -> ERROR: " . $this->error["error"] .                         ": " . $rply . $this->CRLF;            }            return false;        }        // Send encoded username        fputs($this->smtp_conn, base64_encode($username) . $this->CRLF);        $rply = $this->get_lines();        $code = substr($rply,0,3);        if($code != 334) {            $this->error =                array("error" => "Username not accepted from server",                      "smtp_code" => $code,                      "smtp_msg" => substr($rply,4));            if($this->do_debug >= 1) {                echo "SMTP -> ERROR: " . $this->error["error"] .                         ": " . $rply . $this->CRLF;            }            return false;        }        // Send encoded password        fputs($this->smtp_conn, base64_encode($password) . $this->CRLF);        $rply = $this->get_lines();        $code = substr($rply,0,3);        if($code != 235) {            $this->error =                array("error" => "Password not accepted from server",                      "smtp_code" => $code,                      "smtp_msg" => substr($rply,4));            if($this->do_debug >= 1) {                echo "SMTP -> ERROR: " . $this->error["error"] .                         ": " . $rply . $this->CRLF;            }            return false;        }        return true;    }    /**     * Returns true if connected to a server otherwise false     * @access private     * @return bool     */    function Connected() {        if(!empty($this->smtp_conn)) {            $sock_status = socket_get_status($this->smtp_conn);            if($sock_status["eof"]) {                # hmm this is an odd situation... the socket is                # valid but we aren't connected anymore                if($this->do_debug >= 1) {                    echo "SMTP -> NOTICE:" . $this->CRLF .                         "EOF caught while checking if connected";                }                $this->Close();                return false;            }            return true; # everything looks good        }        return false;    }    /**     * Closes the socket and cleans up the state of the class.     * It is not considered good to use this function without     * first trying to use QUIT.     * @access public     * @return void     */    function Close() {        $this->error = null; # so there is no confusion        $this->helo_rply = null;        if(!empty($this->smtp_conn)) {            # close the connection and cleanup            fclose($this->smtp_conn);            $this->smtp_conn = 0;        }    }    /***************************************************************     *                        SMTP COMMANDS                       *     *************************************************************/    /**     * Issues a data command and sends the msg_data to the server     * finializing the mail transaction. $msg_data is the message     * that is to be send with the headers. Each header needs to be     * on a single line followed by a <CRLF> with the message headers     * and the message body being seperated by and additional <CRLF>.     *     * Implements rfc 821: DATA <CRLF>     *     * SMTP CODE INTERMEDIATE: 354     *     [data]     *     <CRLF>.<CRLF>     *     SMTP CODE SUCCESS: 250     *     SMTP CODE FAILURE: 552,554,451,452     * SMTP CODE FAILURE: 451,554     * SMTP CODE ERROR  : 500,501,503,421     * @access public     * @return bool     */    function Data($msg_data) {        $this->error = null; # so no confusion is caused        if(!$this->connected()) {            $this->error = array(                    "error" => "Called Data() without being connected");            return false;        }        fputs($this->smtp_conn,"DATA" . $this->CRLF);        $rply = $this->get_lines();        $code = substr($rply,0,3);        if($this->do_debug >= 2) {            echo "SMTP -> FROM SERVER:" . $this->CRLF . $rply;        }        if($code != 354) {            $this->error =                array("error" => "DATA command not accepted from server",                      "smtp_code" => $code,                      "smtp_msg" => substr($rply,4));            if($this->do_debug >= 1) {                echo "SMTP -> ERROR: " . $this->error["error"] .                         ": " . $rply . $this->CRLF;            }            return false;        }        # the server is ready to accept data!        # according to rfc 821 we should not send more than 1000        # including the CRLF        # characters on a single line so we will break the data up        # into lines by \r and/or \n then if needed we will break        # each of those into smaller lines to fit within the limit.        # in addition we will be looking for lines that start with        # a period '.' and append and additional period '.' to that        # line. NOTE: this does not count towards are limit.        # normalize the line breaks so we know the explode works        $msg_data = str_replace("\r\n","\n",$msg_data);        $msg_data = str_replace("\r","\n",$msg_data);        $lines = explode("\n",$msg_data);        # we need to find a good way to determine is headers are        # in the msg_data or if it is a straight msg body        # currently I'm assuming rfc 822 definitions of msg headers        # and if the first field of the first line (':' sperated)        # does not contain a space then it _should_ be a header        # and we can process all lines before a blank "" line as        # headers.        $field = substr($lines[0],0,strpos($lines[0],":"));        $in_headers = false;        if(!empty($field) && !strstr($field," ")) {            $in_headers = true;        }        $max_line_length = 998; # used below; set here for ease in change        while(list(,$line) = @each($lines)) {            $lines_out = null;            if($line == "" && $in_headers) {                $in_headers = false;            }            # ok we need to break this line up into several            # smaller lines            while(strlen($line) > $max_line_length) {                $pos = strrpos(substr($line,0,$max_line_length)," ");                $lines_out[] = substr($line,0,$pos);                $line = substr($line,$pos + 1);                # if we are processing headers we need to                # add a LWSP-char to the front of the new line                # rfc 822 on long msg headers                if($in_headers) {                    $line = "\t" . $line;                }            }            $lines_out[] = $line;            # now send the lines to the server            while(list(,$line_out) = @each($lines_out)) {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
五月婷婷激情综合| 成人h动漫精品一区二区| 欧美日本乱大交xxxxx| 亚洲一区二区高清| 欧美中文字幕久久| 麻豆精品视频在线| 亚洲国产精品久久久久秋霞影院 | 精品在线一区二区| 欧美一区二区高清| 国产91高潮流白浆在线麻豆| 欧美激情综合五月色丁香小说| 精品亚洲成av人在线观看| 欧美成人aa大片| 国产原创一区二区三区| 久久久www成人免费毛片麻豆| 国产精品1024久久| 综合中文字幕亚洲| 欧美精品v国产精品v日韩精品| 丝袜诱惑制服诱惑色一区在线观看| 91精品国产综合久久久久久久久久 | 欧美日韩久久久一区| 日韩国产欧美在线观看| 欧美成人一区二区三区在线观看| 美女视频黄 久久| 国产精品免费丝袜| 欧美疯狂做受xxxx富婆| 国产成人精品免费| 麻豆专区一区二区三区四区五区| 欧美国产丝袜视频| 日韩午夜在线观看| 91久久国产最好的精华液| 精彩视频一区二区| 免费一级片91| 精品亚洲欧美一区| 韩国毛片一区二区三区| 日韩av中文在线观看| 天堂精品中文字幕在线| 亚洲成人久久影院| 一片黄亚洲嫩模| 夜夜揉揉日日人人青青一国产精品| 成人欧美一区二区三区小说| 亚洲欧美综合在线精品| 亚洲狠狠丁香婷婷综合久久久| 欧美欧美欧美欧美首页| 欧美日韩午夜在线| 欧美一区二区三区视频免费| 欧美一区二区三区系列电影| 欧美丰满少妇xxxbbb| 日韩一级免费观看| 精品国产91乱码一区二区三区| 日韩天堂在线观看| 久久伊人中文字幕| 国产欧美视频一区二区| 国产精品久久久久影院亚瑟| 一区二区三区中文字幕电影| 夜夜嗨av一区二区三区网页| 日韩不卡在线观看日韩不卡视频| 日韩国产精品大片| 国产suv一区二区三区88区| 成人动漫精品一区二区| 在线观看日韩精品| 日韩女优av电影在线观看| 国产欧美精品一区二区色综合朱莉| 国产精品久99| 亚洲成人免费在线观看| 国产福利一区在线| 欧美三级中文字幕在线观看| 欧美成人女星排行榜| 1024亚洲合集| 日本中文一区二区三区| 99在线精品一区二区三区| 日韩三级在线免费观看| 国产精品国产三级国产普通话蜜臀| 亚洲狼人国产精品| 加勒比av一区二区| 欧美三级在线播放| 最新中文字幕一区二区三区 | 精品剧情在线观看| 一级中文字幕一区二区| 国产剧情在线观看一区二区| 欧美精品色一区二区三区| 综合色天天鬼久久鬼色| 狠狠色丁香婷综合久久| 欧美一区二区三区不卡| 亚洲精品菠萝久久久久久久| 高清在线不卡av| 久久久蜜桃精品| 韩国女主播成人在线| 日韩一二三四区| 免费观看在线综合| 日韩一区二区三| 蜜桃av一区二区三区电影| 欧美喷水一区二区| 性感美女极品91精品| 在线91免费看| 久久精品国产亚洲高清剧情介绍 | 欧美日韩高清影院| 婷婷开心激情综合| 91精品欧美综合在线观看最新| 午夜视频久久久久久| 3d动漫精品啪啪| 欧美96一区二区免费视频| 日韩你懂的在线播放| 国产在线播放一区三区四| 国产亚洲精品bt天堂精选| 99在线精品视频| 午夜伊人狠狠久久| 精品久久久久久久久久久久久久久 | 国产精品久久久久影院老司| 一本久久a久久免费精品不卡| 日日摸夜夜添夜夜添国产精品| 欧美精品在欧美一区二区少妇| 麻豆久久久久久久| 国产精品久久久久久福利一牛影视| 欧美午夜寂寞影院| 成人开心网精品视频| 亚洲国产三级在线| 日本一区二区三区视频视频| 在线视频一区二区三区| 国产在线观看一区二区| 国产在线精品一区在线观看麻豆| 国产精品麻豆久久久| 欧美色图片你懂的| 国产99一区视频免费| 婷婷开心久久网| 亚洲乱码中文字幕综合| 久久美女高清视频| 欧美一区二区三区在线视频| 99国产精品国产精品毛片| 国产麻豆午夜三级精品| 午夜激情综合网| 亚洲国产日韩在线一区模特| 18涩涩午夜精品.www| 国产精品三级在线观看| 久久精品一区二区三区av| 日韩欧美一二三区| 91精品国产综合久久久久久漫画| 在线日韩一区二区| 色偷偷88欧美精品久久久| 一本大道av伊人久久综合| 懂色av一区二区夜夜嗨| 99国产一区二区三精品乱码| 成人综合日日夜夜| 91色综合久久久久婷婷| 日本韩国一区二区| 欧美性xxxxxxxx| 69堂亚洲精品首页| 日韩欧美电影在线| 国产亚洲欧美日韩日本| 最近中文字幕一区二区三区| 亚洲桃色在线一区| 香蕉久久一区二区不卡无毒影院| 免费美女久久99| 国产精品一区二区黑丝| www.日韩av| 在线观看欧美黄色| 6080国产精品一区二区| 久久久久成人黄色影片| 一区二区三区在线免费播放| 亚洲成人精品影院| 国产xxx精品视频大全| 在线观看av一区二区| 日韩西西人体444www| 国产精品夫妻自拍| 蜜臀国产一区二区三区在线播放 | 92精品国产成人观看免费 | 精品国产91乱码一区二区三区| 久久综合丝袜日本网| 亚洲一区视频在线观看视频| 国产综合色在线| 欧美日韩免费在线视频| 国产欧美精品在线观看| 日韩精品电影在线观看| 99re在线精品| 欧美激情一区二区| 国产专区综合网| 在线观看91av| 亚洲尤物在线视频观看| 99精品视频免费在线观看| 日韩女优av电影在线观看| 亚洲电影在线免费观看| 色视频成人在线观看免| 国产人妖乱国产精品人妖| 精品一区二区免费视频| 日韩一区二区麻豆国产| 亚洲成人在线网站| 欧美日韩精品一区二区三区 | 欧美在线免费播放| 亚洲婷婷综合色高清在线| 国产成人精品aa毛片| 国产亚洲精品资源在线26u| 国产精品一区二区三区网站| 欧美变态凌虐bdsm| 国产在线日韩欧美| 国产女主播在线一区二区| 成人免费视频caoporn| 亚洲天堂精品在线观看| 在线视频国内一区二区| 亚洲成人av电影在线| 日韩一区二区影院|