SSH over CDN HTTP-Proxy - ssh

I have a server which i'd like to connect to it using ssh. But the problem is I'm using a cdn http-proxy and have a domain name which connects to port 22 of the server.
when I try connecting i get the error:
kex_exchange_identification: Connection closed by remote host
does anyone have an idea what I could do?

Related

Connect host ldap server to local VM

I have a server installed on VM and a LDAP(opendj) server created using Apache Directory Studio on my host computer. Now, I would like to connect that LDAP server to local VM so that the VM server can pull user's information from LDAP server. is it possible to do that? I could not understand how to establish a communication between these two server.
Thanks.
Remote Port Forwarding actually does work here.
my ldap server port was 10389.
I have created a tunnel from host to vm:
ssh -R 10389:localhost:10389 root#172.16.130.132(vm-ip)
after then, vm can reach to the host through this port (10389).
Sorry, I don't have that much knowledge on ssh. But this one worked for me.

Start a WS connection on a server that's being accessed by SSH port forwarding

I have an EC2 Instance(A) and a RaspberryPi(B). I want to access a HTML page in B.
Here are the steps I did:
Created a simple index.html in B that connects to a WebSocket running on 5443 also in B
Served it with SimpleHTTPServer on port 1337
Created a port forwarding. When I access A:9000 it should redirect to B:1337. Used: ssh -f -N -R 9000:127.0.0.1:1337 A
With that I'm able to access my index.html page, however it fails when trying to connect to the WebSocket server with
WebSocket connection to 'ws://localhost:5553/' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED
When I use VNC to connect to B, and access the browser in localhost:1337 I'm able to see the page AND the WebSocket connection succeeds.
I'm not sure why it fails when I try to access it through the EC2 instance. Does anyone have any clues on what might be the problem? thanks
**All ports are open in my EC2 instance
Even though I was port forwarding, localhost:5553 wasn't the raspberry pi IP, was the EC2. I created a new port forwarding from 9001 in A to 5443 in B to tunnel the Websocket connection and it worked.

Connecting to Apache Server

After I have created my apache server, and installed LAMP, I have portforwarded port 80, and am able to reach the server on any browser using my external IP. When I go to connect to the server through ssh using my terminal on my MacBook, I can only connect to it using the servers inet (IPv4) IP address, and not the external IP address using port 80, for example, I can connect to it using: ssh root#192.168.1.204, but I cannot connect to it using: ssh -p 80 root#'external ip address'
the error I get is: ssh_exchange_identification: Connection closed by remote host
PLEASE IF ANYONE CAN HELP! I have been struggling with this for days.
Thanks
SSH is port 22, you can't use it to connect to port 80. If you added the port 80 portion to your first command as well, you should see the same error.

Connect to SSH (port 22) through tunnel opened in PuTTY on Windows

I want to connect to a remote server (host1) that accessible only from it's private network.
Another server (host2) is accessible from the Internet.
I opened a tunnel to host2 using PuTTY and tested it's working with Firefox (also checked that I got different IP address).
How can I connect to host1 using the tunnel I created?
I tried to configure proxy (to the tunnel I created - localhost) in PuTTY but it's not working.
The error I got: "Server unexpectedly closed network connection"
Pay attention that the host is the computer name in the network.
You connect to the local tunnel end directly, no "proxy" setting is needed.
This typically means that you use "localhost" as a Host Name. And a port according to your tunnel configuration.
See my guide for tunneling SFTP/SCP session. It's for WinSCP, but just use PuTTY instead of WinSCP in section Connecting through the tunnel.

Notepad++ NppFTP [SFTP] Connection failed : Error reading socket

Does anyone know why I am unable to connect to my server using the Notepad++ NppFTP plugin with SFTP?
I have a CentOS 6.4 server with SSH on port 22.
When I try and connect using NppFTP I get the following output:
[NppFTP] Everything initialized
Connecting
[SFTP] Connection failed : Error reading socket
Unable to connect
Disconnected
This used to work when I had my SSH port set to 3264 but when I changed the SSH port back to 22 NppFTP stopped working. All the settings for the profile are correct including the right IP, username, password and port (22).
I can connect with SFTP using FileZilla and WinSCP successfully with these same SFTP details and I can connect with SSH using PuTTY.
I can connect with SFTP to other servers using NppFTP so I believe there is an issue in my server config I'm just not sure where or what.
I looked at the access logs but found no attempt at a connection from NppFTP, I turned the firewall off and still nothing.
In the end I got in touch with my server company and it turns out it was a problem on their end. This is what they had to say:
"This was caused by an IPS rule inspecting the network packets coming into the infrastructure, which helps identify brute force attacks."
Very strange, but after they made the change NppFTP can now connect successfully.