public function setConfiguration($config)
    {
        $this->setHeloHostname($config['helo_hostname']);
        $this->setFrom($config['from_address'], $config['from_name']);
        $this->setHost($config['host']);
        $this->setPort($config['port']);
        $this->setSecure($config['secure']);

        $this->setAuth((int)$config['auth'] === 1);
        $this->setUser($config['username']);
        $this->setPass($config['password']);
    }