protected function initializeSsh()
    {
        try {

            $this->ssh = $this->getSsh2SftpConnectionFactory()
                ->make(
                    Ssh2SftpConnectionInterface::class,
                    $this->request->getLocation(),
                    $this->request->getCredentials()['name'],
                    $this->request->getCredentials()['password'],
                    $this->request->getPort() ?: 22,
                    $this->request->getFingerprint()
                );

        } catch (Ssh2ConnectionException $e) {

            throw new CouldNotConnectException($e->getMessage(), 0, $e);
        }
    }