Tag Info

Hot answers tagged

3

You can use the SSH_CONNECTION and SSH_CLIENT variables: $ echo $SSH_CONNECTION 10.0.0.1 42276 10.0.0.2 22 $ echo $SSH_CLIENT 10.0.0.1 42276 22 $ SSH_IP=${SSH_CONNECTION%% *} $ echo $SSH_IP 10.0.0.1 From man 1 ssh: SSH_CONNECTION Identifies the client and server ends of the connection. The variable contains four ...


3

I have this little script kept in ~/bin/infinite_ssh(1): #! /bin/bash -x # while :; do ssh -R 2222:localhost:22 remoteserver sleep 86400 sleep 10 done this is connecting to the remoteserver and creates a backward tunnel so that in the remote server I can ssh my desktop by using ssh -p 2222 localhost. Your application may, obviously, ...


2

refused connect from [IP-ADDRESS] ([IP-ADDRESS]) This particular message is emitted by the TCP wrappers library when it decides to reject a connection. Ubuntu's sshd is built to use TCP wrappers. Check the two files "/etc/hosts.allow" and "/etc/hosts.deny" on the ssh server. You have an entry in one of those files which causes ssh connections from that ...


2

Connecting inside your LAN: Just type in the local IP, the one output from "ifconfig" or "ip address". To have people outside your LAN connect: Forward a port to your game server's local IP address. In order to not have to adjust the forwarding all the time, you'll probably want to assign your game server a static IP address from your router. Anyone ...


1

Answer to 1 & 2: The warning is from netstat, not from grep and its about the PID/Program name column of the netstat output: $ netstat -tapen (Not all processes could be identified, non-owned process info will not be shown, you would have to be root to see it all.) Active Internet connections (servers and established) Proto Recv-Q Send-Q Local Address ...


1

This is an old thread and I just ran across this answer, I will just add what I did to solve this. ssh-keygen -f "/home/USER/.ssh/known_hosts" -R HOSTNAME I just looked at the error message that it threw at me and it said to run that command in order to remove it from the list of hosts. After that I did the following: ssh-copy-id HOSTNAME Than I ...


1

Yes you can install a ssh server on the windows guest. Options range from cygwin and several ssh servers are available. See http://www.windowsnetworking.com/articles-tutorials/windows-server-2008/install-SSH-Server-Windows-Server-2008.html You can download cygwin here - https://www.cygwin.com/ When you run the installer (cygwin.exe) you may choose what to ...


1

Lots of ssh brute force attacks taking place. It is possible you have an obsolete ssh package and they got in that way. Check for ssh failures in the logs, he maybe simply doing a brute force against you. go to /tmp and post its output from ls -al, if there is a root kit it might show up there. You can set allow users in ssh and fail2ban is useful as ...


1

Can we say with certainty that an IP from china somehow SSH'd into my machine? Even though it only accepted RSA key authorization? It is unlikely they were authenticated, unless they managed to obtain a valid key. Try connecting from a host you control without a key and check the running processes. They should be similar to what you saw. The fact the ...



Only top voted, non community-wiki answers of a minimum length are eligible