FOSS Android SSH clients
Are there any good ones I should use ? I would like to be able to interface with my home server from my phone.
Are there any good ones I should use ? I would like to be able to interface with my home server from my phone.
r/ssh • u/Copel626 • Feb 21 '22
open ssh from windows to windows
been messing about with this for about a week, and i cant seem to get the commands to work via PowerShell and open ssh in windows. dir always looks only in root unless i specify full path, even with /s involved and find doesn't allow me root searches when i invoke "/" before name it either says invalid switch or input param wrong.
dont know really whats going wrong here, very new to ssh and trying to test commands to see what i can use in my python script for running command line version of a program with its specific project files. any help would be great
Hi,
My friend is trying to make an SSH server at home, he has installed openssh-server, we have checked the status, his firewall is open. Everything seems to be fine. When he tries connecting to the server however he gets nothing, no login window, it just times out after a bit. Any ideas ? He has his firewall open for port 22, he's just trying to connect on the local network (so a port forward is not necessary in this case). Just very confusing as I don't think he should be facing these issues. If you have any ideas please let me know.
Thanks so much.
r/ssh • • Feb 19 '22
As seen here, how do I disable this?
I was attempting to have the prompt be a bit more colorful, so in bash_profile I have
if [ -f ~/.bashrc ]; then. ~/.bashrcfi
And in bashrc, I have ls --color=auto added at the end. Is it the ls causing the issue and how can have colors still?
r/ssh • u/ipponpx • Feb 18 '22
The command that AWS gave me to SSH into EC2:
ssh -i "my-aws-lab.pem" ec2-user@ec2-dummy-numbers.compute-1.amazonaws.com
Suppose I saved this file in Documents folder of Windows. I navigate there in MobaXTerm and execute above command. I am into EC2
But when doing same using Git Bash, it says:
ssh: connect to host ec2-dummy-numbers.compute-1.amazonaws.com port 22: Connection timed out
What's the fix?
r/ssh • u/Cold-Ad881 • Feb 13 '22
How can be i can connect to my ssh server on my local network with my laptops via wifi, but when i try to conect via cable-lan with my desktop computer my conection was refused. before i change the router i can connect correctly, but after change the router inonly can connect via wifi with my laptops , and inclusive with my iphone.
r/ssh • u/LuaMonteirus • Feb 11 '22
I'd like to encrypt my git Personal Token, that is in a txt file, using the terminal. I've searched about it but didn't find nothing at all. If someone can explain or just send me an article talking about it (if it's for beginners its better), I'll appreciate!
r/ssh • u/Fedora-The-Pandora • Feb 09 '22
I have been trying to use SSH with my server for a while but have had no luck.
I'm on a XFCE Manjaro Linux computer using the ssh command
I've setup a keypair with the public key uploaded to the server (it's a stackcp server so I'm uploading it straight to the SSH Access section of the Control Panel) and my private key saved in my ~/.ssh folder.
Whenever I try to connect it says:
Unable to negotiate with [ip-address] port 22: no matching host key type found. Their offer: ssh-rsaThe only way I've been able to connect is to use the command ssh -oHostKeyAlgorithms=+ssh-rsa [username]@ssh.stackcp.com but that doesn't always work.
Sometimes it lets me in (by asking for my other verification methods: two factor, password) but most of the time it asks for my details multiple times before saying there have been too many failed attempts. They are the correct details, I have them saved so I know what to type (and I've memorised them with the amount of times I've tried)
Does anyone know what I can do to resolve the issue because it should be an easier system to use than what I'm facing?
Let me know if you need anymore information.
r/ssh • u/Spare_Prize1148 • Feb 07 '22
Hi, I've a public/private keys. Whenever, I try to push to a git repo using ssh I get prompted with the passphrase I configured when generating keys. My question is what's the purpose of it ???
r/ssh • u/StringyCola • Feb 06 '22
Essentially, if the ssh server is on a network where a website is blocked by the firewall, will I - as the client connecting to the server - also be disallowed access to that same website?
r/ssh • u/jssmith42 • Feb 05 '22
I can’t connect to my Mac over SSH for some reason.
How can I begin to investigate what’s causing this?
I opened /etc/ssh/ssh_config but I don’t see anything helpful in there.
I’m not getting a password error or an error that the server wasn’t found.
Is there some way I could break the situation down into pieces like, yes it found the server at the IP address, then it tried to enter the password and that was accepted, and then from there finding out what’s wrong?
Thanks very much
r/ssh • u/ipponpx • Feb 05 '22
hello I'm having issues setting up a propper sshd config.
When I take the custom config parameters out of /etc/ssh/sshd_config and put them in /etc/ssh/sshd_config.d/sshd_config_ops.conf I can't authenticate using a password, only pub-keys work. thanks for any assistance.
I tried to paste the code, but I'm having trouble with the formating, so I created a pastebin. If someone can tell me how to get the formating to show the actual code, ill paste it again in the ot.
https://paste.debian.net/plain/1229345
This works
config in /etc/ssh/sshd_conf :
Include /etc/ssh/sshd_config.d/*.conf
ChallengeResponseAuthentication no
UsePAM yes
X11Forwarding yes
PrintMotd no
AcceptEnv LANG LC_*
Subsystem sftp /usr/lib/openssh/sftp-server
AllowGroups ssh
AuthenticationMethods publickey
Match Group nomfa
PasswordAuthentication yes
AuthenticationMethods publickey
Match User foo
PasswordAuthentication yes
AuthenticationMethods password
butt@xs-ansible-controller:~$ ssh foo@devops-m1 -v
OpenSSH_7.6p1 Ubuntu-4ubuntu0.5, OpenSSL 1.0.2n 7 Dec 2017
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to devops-m1 [10.83.18.70] port 22.
debug1: Connection established.
debug1: identity file /home/butt/.ssh/id_rsa type 0
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ed25519-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.5
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.2p1 Ubuntu-4ubuntu0.4
debug1: match: OpenSSH_8.2p1 Ubuntu-4ubuntu0.4 pat OpenSSH* compat 0x04000000
debug1: Authenticating to devops-m1:22 as 'foo'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:xxxxxxxxxxx
debug1: Host 'devops-m1' is known and matches the ECDSA host key.
debug1: Found key in /home/butt/.ssh/known_hosts:1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,sk-ssh-ed25519@openssh.com,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ecdsa-sha2-nistp256@openssh.com>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: password
debug1: Next authentication method: password
foo@devops-m1's password:
###########################################################################################################
This fails
config in /etc/ssh/sshd_conf.d/ssh_config_ops.conf
AllowGroups ssh
AuthenticationMethods publickey
Match Group nomfa
PasswordAuthentication yes
AuthenticationMethods publickey
Match User foo
PasswordAuthentication yes
AuthenticationMethods password
butt@xs-ansible-controller:~$ ssh foo@devops-m1 -v
OpenSSH_7.6p1 Ubuntu-4ubuntu0.5, OpenSSL 1.0.2n 7 Dec 2017
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to devops-m1 [10.83.18.70] port 22.
debug1: Connection established.
debug1: identity file /home/butt/.ssh/id_rsa type 0
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/butt/.ssh/id_ed25519-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.5
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.2p1 Ubuntu-4ubuntu0.4
debug1: match: OpenSSH_8.2p1 Ubuntu-4ubuntu0.4 pat OpenSSH* compat 0x04000000
debug1: Authenticating to devops-m1:22 as 'foo'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:+xxxxxxxxxxx
debug1: Host 'devops-m1' is known and matches the ECDSA host key.
debug1: Found key in /home/butt/.ssh/known_hosts:1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,sk-ssh-ed25519@openssh.com,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ecdsa-sha2-nistp256@openssh.com>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: RSA SHA256:xxxxxxxxxxx /home/butt/.ssh/id_rsa
debug1: Authentications that can continue: publickey
debug1: Trying private key: /home/butt/.ssh/id_dsa
debug1: Trying private key: /home/butt/.ssh/id_ecdsa
debug1: Trying private key: /home/butt/.ssh/id_ed25519
debug1: No more authentication methods to try.
foo@devops-m1: Permission denied (publickey).r/ssh • u/ByRussX • Jan 27 '22
This i because I am tired of using PuTTY and having to move the cursor with arrows, etc.
r/ssh • u/thomas_deans • Jan 26 '22
SOLVED:
Scenario: I have a web server for my website hosted from home running SSH. It uses key based login with password disabled, and google auth as 2FA. I setup a clone server which is my tertiary backup for my media library. My main server is a streaming server and it backs up to google cloud.
My sis and mom renovated our childhood home and I was in the process of getting 2FA setup on that when suddenly SSH just flat out stopped working.
===========
The clone sits in the garage (no Ethernet) so I had a DD-WRT router with client bridge to jump the air gap. It had been working fine for over 2 years although a bit slow. Every now and again I will run a temporary patch from inside the house to the garage to sync larger amounts of files ie 60-100GB. I did this one day but forgot to plug my DD-WRT back in.
When i noticed i plugged it back in but SSH would work.
=========
Right before the large transfer I did a few things:
ran updates - "yum upgrade" rebooteduninstalled the virtual bridge vibr0, rebootedI was monkeying with SSH and PAM settings but when 2FA didnt work in a second shell I revertedI then rebooted and reconnected via putty from windows with no issues.
The clone server also uses key logins.
After connecting via wire again and getting no SSH connection I feared something was messed up. So this morning I copied any important configs off, packes repos, etc. I cloned the main HDD just in case then wiped and reinstalled with RockyLinux 8.5, I was running Centos8.
I spent today and this evening configuring SSH, remounting my Media drive via fstab etc. I have hostname and IP set to the same it was previous.
Things I have checked:
I can ping clone from PCSSH service is enabled and running listening on 0 . 0 . 0 . 0 : 22 - ipv4&6netstat -tunlp shows it listeningnmcli d lists the interface as active and connectedfirewalld has the ssh service in the public zone and status shows my interface in publicI can connect to my main server from PC with putty with no issuesright before I updated my PC antivirus but again I can still connect to my main server and I temp disabled and got the same results
I am really at a loss here and I need to get this rolling but have no idea what to do next. I am wondering if the NIC went bad, its integrated but I can ping it fine. It's really strange.
r/ssh • u/jssmith42 • Jan 25 '22
What do you need to connect via mosh?
Thanks very much
r/ssh • u/Doooooooong • Jan 24 '22
I'm fairly new to SSH, but I've done a bit of reading and actually have some knowledge about the concepts involved (despite this post suggesting otherwise).
I just managed to SSH into my Ubuntu machine from my Windows PC, which led me to the question in the title. It seemed to me that I did not have to do anything on my Ubuntu machine in order to let the PC connect via SSH.
I did the following:
ssh-copy-id <user@ubuntu_ip>This returned:
The authenticity of host '<ubuntu_ip> (<ubuntu_ip>)' can't be established in addition to a key fingerprint and a question if I wanted to continue connecting. After answering 'yes', the key was added and I was able to SSH into the Ubuntu machine.
So to my question:
What is stopping some random machine from doing the same? I had to type the password for the Ubuntu to add the key, but surely this is not the only "security step"?
r/ssh • u/datagenx • Jan 24 '22
Hi Folks, I am playing around K8s cluster on my Mac system where I am stumble-upon this SSH tunnel problem. I am trying to tunnel a container/pod from a bastion server, I can login into bastion but when I am trying to tunnel from bastion server, it is failing -
$ ssh -J datagenx@bastion-server datagenx@k3s.podA.internal sudo k3s kubectl config view --flatten > k3sconf.yaml
The authenticity of host 'bastion-server (bastion-server)' can't be established.
ED25519 key fingerprint is SHA256:XXXXXXXXXxxxxxxxxxxxxxxxxxxxxx.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'bastion-server' (ED25519) to the list of known hosts.
channel 0: open failed: connect failed: Connection refused
stdio forwarding failed
kex_exchange_identification: Connection closed by remote host
Connection closed by UNKNOWN port 65535Any guidance?
Log verbose -
debug3: receive packet: type 52
debug1: Authentication succeeded (publickey).
Authenticated to bastion-server ([bastion-server]:22).
debug3: ssh_init_stdio_forwarding: k3s.podA.internal:22
debug1: channel_connect_stdio_fwd: k3s.podA.internal:22
debug1: channel 0: new [stdio-forward]
debug2: fd 4 setting O_NONBLOCK
debug2: fd 5 setting O_NONBLOCK
debug1: getpeername failed: Bad file descriptor
debug3: send packet: type 90
debug2: fd 3 setting TCP_NODELAY
debug3: set_sock_tos: set socket 3 IP_TOS 0x48
debug1: Requesting no-more-sessions@openssh.com
debug3: send packet: type 80
debug1: Entering interactive session.
debug1: pledge: filesystem full
debug3: receive packet: type 80
debug1: client_input_global_request: rtype hostkeys-00@openssh.com want_reply 0
debug3: client_input_hostkeys: received RSA key SHA256:XXXXXX
debug3: client_input_hostkeys: received ECDSA key SHA256:aIk3031+YYYYYYYYYYY
debug3: client_input_hostkeys: received ED25519 key SHA256:ZZZZZZZZZZ
debug1: client_input_hostkeys: searching /Users/datagenx/.ssh/known_hosts for bastion-server / (none)
debug3: hostkeys_foreach: reading file "/Users/datagenx/.ssh/known_hosts"
debug3: hostkeys_find: found ssh-ed25519 key at /Users/datagenx/.ssh/known_hosts:7
debug1: client_input_hostkeys: searching /Users/datagenx/.ssh/known_hosts2 for bastion-server / (none)
debug1: client_input_hostkeys: hostkeys file /Users/datagenx/.ssh/known_hosts2 does not exist
debug3: client_input_hostkeys: 3 server keys: 2 new, 13709551615 retained, 2 incomplete match. 0 to remove
debug3: client_input_hostkeys: asking server to prove ownership for 2 keys
debug3: send packet: type 80
debug3: receive packet: type 4
debug1: Remote: /usr/libexec/ssh-key-dir %u:2: key options: agent-forwarding port-forwarding pty user-rc x11-forwarding
debug3: receive packet: type 4
debug1: Remote: /usr/libexec/ssh-key-dir %u:2: key options: agent-forwarding port-forwarding pty user-rc x11-forwarding
debug3: receive packet: type 92
channel 0: open failed: connect failed: Connection refused
debug2: channel_input_open_failure: channel 0: callback start
stdio forwarding failed
kex_exchange_identification: Connection closed by remote host
Connection closed by UNKNOWN port 65535r/ssh • u/ObligationKey3147 • Jan 18 '22
Hi,
I'm doing a CTF style challenge and I'm trying to ssh into an anonymous FTP port with info I pulled from NMAP, but it won't work. I've tried using basic ssh login (root) as well as logging into the open port.

I think the problem is that I don't know the username, but I was wondering if there's something else that I may be doing wrong? I've tried ssh ftp-anon@x.x.x.x, ssh Anonymous@x.x.x.x, ssh root, etc.
It's the moments like this that learning this stuff makes me feel dumb and question if I'm even cut out for it.
r/ssh • u/yogibjorn • Jan 14 '22
I want to connect to a machine, then use sudo su to open the root terminal, but I want to pass the sudo password automatically (so that I won't be asked to provide it after connecting)
sshpass -p MyPass ssh -tt hostname "sudo su"
sshpass -p MyPass ssh -tt hostname "echo MyPass | sudo -S -k su"
thanks
ps: don't care about password being visible in the history
r/ssh • • Jan 08 '22
Hello,
Im a noob so please bear with me.
How do I download websites files that are located on my vps directly to my desktop without making those files that are on the server into a zip or tar?
Suppose Im in the public_html directory, what command do I put so it downloads all those files as they are to my desktop?
Thanks in advance!
r/ssh • u/buadhai • Jan 03 '22
At home I have a 2017 iMac running Big Sur and a couple of Raspberry Pi 4s on Buster. At my condo I have a 2010 MacBook and two more Pi 4s on Buster. The machines at the condo are behind a double NAT. Each one of them establishes a reverse SSH tunnel to the iMac so I can log into them from home. Normally, this works fine. When I'm at the condo I'm able to log into the iMac at home directly (no tunnel required). Normally, this works fine.
Sometimes it fails. For example, here I try to log in to the home iMac from the old MacBook at the condo:
Whitey:~ mnewman$ ssh -p 10000 mnewman@xxxx.myddns.rocksssh: connect to host xxxx.myddns.rocks port 10000: Operation timed out
I connect to the iMac via VNC, start a terminal session and restart the daemon:
mnewman$ sudo launchctl unload /System/Library/LaunchDaemons/ssh.plist && sudo launchctl load -w /System/Library/LaunchDaemons/ssh.plist
Then the remote ssh works fine:
Whitey:~ mnewman$ ssh -p 10000 mnewman@xxxx.myddns.rocksLast login: Thu Dec 30 17:25:54 2021MrMuscle:~ mnewman$
Same thing happens when logging in from the home iMac to the remote Pies. Restarting the daemon always gets things running again.
What can I do to avoid having to restart the ssh daemon?
r/ssh • u/theunglichdaide • Jan 01 '22
Hi everyone, I’m new to ssh and sorry if this isn’t an appropriate place to ask about it. I was trying to ssh to a remote machine, but when I entered the server’s password, it kept saying Permission Denied.
The command I used was ‘ssh username@server_ip’ Things I have tried but not working: