Questions tagged [ssh2]
136 questions
0
votes
0 answers
Can I connect to ssh2 without the privateKey?
I can connect to ssh2 without the privateKey
I am trying to enter a server with SFTP but when I get the following error ...
Timed out while waiting for handshake
I'm looking for an example and almost everyone uses the privateKey, is it mandatory?…

carlos
- 1
0
votes
0 answers
MYSQL tunnel through SSH on Node JS does not return any results
I am trying to tunnel mysql queries to a remote server. I am using SSH2 and MYSQL2 packages on Node.JS. I tried to adapt the sample code mentioned in another question here. Here is my code
const mysql = require('mysql2');
const { Client } =…

user3750702
- 35
- 6
0
votes
1 answer
NodeJS: SSH2 - Read last 1000 letters from stream
I have a Vue App with a component for xterm and parallel to it I'm using ssh2/shell as a client with a global Vue plugin.
I can connect via my ssh plugin to a server on my xterm component and writing my ssh stream into the xterm with the…

borsTiHD
- 253
- 3
- 17
0
votes
0 answers
I can't install SSH2 PHP extension on Centos 7
When I make the command:
yum install gcc php-devel libssh2 libssh2-devel php-pear make
Return me below:
Loaded plugins: fastestmirror, langpacks, universal-hooks
Loading mirror speeds from cached hostfile
* EA4: 104.219.172.10
*…

Marcelo F
- 1
- 3
0
votes
0 answers
Command errored out with exit status 1 when installing ssh-2
I'm using python 3.8 and OS is windows 10.
I'm trying to execute this command:
pip install ssh2-python
I get this error:
***Collecting ssh2-python
Using cached ssh2-python-0.19.0.tar.gz (1.1 MB)
Using legacy 'setup.py install' for ssh2-python,…

kobilevi
- 1
- 3
0
votes
0 answers
Is it ok to establish a new connection every time I run a new command using phpseclib?
I want to run different php scripts based on result of execution of previous script (via AJAX), but I can't implement needed logic inside one script (and one SFTP connection) because decisions on which script to run next must be made by a user.
So…

blinkapec
- 11
- 1
- 3
0
votes
1 answer
How to compile ssh2 on Windows to create a 32bits libssh2.dll
I successfully created libssh2.dll on Windows but is 64bits.
How to do the same to producce 32bits libssh2.dll ?

bruno bb
- 152
- 9
0
votes
0 answers
$ansi->getScreen(); - PHP Notice: Undefined offset
I'm using the following code to interact with an SSH session. All is fine until the last line of code.
I'm getting nice screen prints on my webpage, until the last getScreen(), when it throws the following errors. I will say that after my last…

Vacek
- 179
- 1
- 12
0
votes
2 answers
Execute Linux commands using ssh2-promise in NodeJS on remote server
I am trying to execute command yum install on a remote linux server using ssh2-promise package,
But I could not get the command response back for further processing and validation.
I have tried the following,
// Node:33528)…

cslrnr
- 694
- 1
- 8
- 24
0
votes
0 answers
PHP variable inside ssh2_exec
OS: Ubuntu 16.04
I tried to use variable inside ssh2_exec but I get this message:
PID TTY TIME CMD 12585 pts/0 05:27:05 samp03svr bash: line 1: -o: command not found
My code:
include('Net/SSH2.php');
$cmd = "sudo ps -p {$user->sshConnect()} -o…

milfman
- 1
- 4
0
votes
1 answer
How to ensure a single, private ssh connection using ssh2 with socket.io in Meteor
I am using ssh2 and socket.io to enable a real-time ssh connection to a remote server for users of my Meteor 1.8.1 app. The app runs on Ubuntu under Nginx and Phusion Passenger. Here is what the app needs to do:
Each authorised user already has an…

Little Brain
- 2,647
- 1
- 30
- 54
0
votes
1 answer
How can i resolve "throw new Error('Cannot parse privateKey: ' + privKeyInfo.message);" in Windows
When i run my tests, i get this error in my windows test client
CypressError: cy.exec('npm run -s command') failed because the command exited with a non-zero code.
Pass {failOnNonZeroExit: false} to ignore exit code failures.
Information about the…

Deeps
- 1
- 1
0
votes
1 answer
ssh2_connect(): Error starting up SSH connection(-43): Failed getting banner
Have a docker container build using php-ssh2. php version 7.2 When trying to use
$con = ssh2_connect('hostname');
I am getting Error starting up SSH connection(-43): Failed getting banner . Interesting thing is 43 here. Whats the significance of…

Kingshuk Deb
- 1,700
- 2
- 26
- 40
0
votes
0 answers
Ssh timeout in Node.JS v12.14./12.16.1
I have a meteor based nodejs application. In this application, I open multiple parallel ssh connections upto 200 max. I use nodejs based node-ssh library to establish ssh connections (Node-ssh library in-turn uses nodejs based ssh2 library). I use…

Vi Se
- 1
- 1
0
votes
0 answers
ssh2 closing connection after the first command
i have a piece of code which asks the user for a command and then makes a ssh connection to the server and outputs the result. the problem is if the user inputs the command cd /etc he navigates to that directory but if he then enters the command pwd…

albert
- 5
- 4