Aleksander Machniak
2016-01-07 4e1aa60c167b3593b8a1081c1ff60557e90c2d0f
Make possible to disable authentication via rcube_smtp::connect() arguments (#1490621)
1 files modified
6 ■■■■ changed files
program/lib/Roundcube/rcube_smtp.php 6 ●●●● patch | view | raw | blame | history
program/lib/Roundcube/rcube_smtp.php
@@ -47,7 +47,7 @@
     *
     * @return bool  Returns true on success, or false on error
     */
    public function connect($host=null, $port=null, $user=null, $pass=null)
    public function connect($host = null, $port = null, $user = null, $pass = null)
    {
        $rcube = rcube::get_instance();
@@ -61,8 +61,8 @@
        $CONFIG = $rcube->plugins->exec_hook('smtp_connect', array(
            'smtp_server'    => $host ?: $rcube->config->get('smtp_server'),
            'smtp_port'      => $port ?: $rcube->config->get('smtp_port', 25),
            'smtp_user'      => $user ?: $rcube->config->get('smtp_user'),
            'smtp_pass'      => $pass ?: $rcube->config->get('smtp_pass'),
            'smtp_user'      => $user !== null ? $user : $rcube->config->get('smtp_user'),
            'smtp_pass'      => $pass !== null ? $pass : $rcube->config->get('smtp_pass'),
            'smtp_auth_cid'  => $rcube->config->get('smtp_auth_cid'),
            'smtp_auth_pw'   => $rcube->config->get('smtp_auth_pw'),
            'smtp_auth_type' => $rcube->config->get('smtp_auth_type'),