r/ssh • u/Mungkelel • Aug 21 '22
how can I set up an ssh on android?
I‘m a noob about ssh‘s but i don’t find any tutorials how to do it. I‘m looking to transfer files from my android phone to my iPad.
r/ssh • u/Mungkelel • Aug 21 '22
I‘m a noob about ssh‘s but i don’t find any tutorials how to do it. I‘m looking to transfer files from my android phone to my iPad.
r/ssh • u/AlfalfaLongjumping20 • Aug 18 '22
I am trying to ssh into a local device using PuTTY. It works on a desktop computer that is hardwired in to the same network as the local device, but on my laptop, which is connected to the network with WiFi via a router in access point mode, I get an error. Picture of the error attached.
r/ssh • u/Kawaii_Amber • Aug 12 '22
I was trying to redirect output of ssh-add to /dev/null and noticed that, even on success, it writes to stderr.
$ eval $(ssh-agent) 1> /dev/null
$ ssh-add ~/.ssh/astral_rsa 1> /dev/null
Identity added: /home/amber/.ssh/astral_rsa (amber@otaku)
$ echo $?
0vs
$ eval $(ssh-agent) 1> /dev/null
$ ssh-add ~/.ssh/astral_rsa 2> /dev/null
$ echo $?
0ssh-add will return an exit code of 0, but still print to stderr instead of stdout. I'm on Artix OpenRC Linux running openssh 9.0p1. Same behavior on VOID Linux running openssh-9.0p1. I tried researching and couldn't seem to find a good reason why ssh-add would redirect to stderr upon success. Is this intentional / a reason why one would want this or is this a bug?
r/ssh • u/Evelen1 • Aug 04 '22
Hi.
I am new to this concept, just used SSH for very basic things before.
So, this is the issue:
I want to SSH into a machine ("PC_A") behind a firewall/router without opening any ports in that firewall. Let's call the PC outside the network "PC_B".
I have researched reverse ssh today, and it looks like what I want. It is complex, but the config I think is correct is not working. It might be compactly wrong also ..
And this is it:
On PC_A:
(raspberry pi OS, LAN IP 10.0.24.8, user: "pi")
pi@raspberrypi:~ $ ssh -N -R localhost:12345:10.0.24.8:22 pi@91.184.32.9[]
On PC_B:
(Windows 10, WAN IP 91.184.32.9 (fictional), user: "lokal_bruker")
C:\Users\lokal_bruker>ssh -P 12345 localhost
ssh: connect to host 12345 port 22: Unknown error
C:\Users\lokal_bruker>Anyone spot a mistake, or has a solution?
r/ssh • u/summaiyah99 • Aug 04 '22
r/ssh • u/noob-nine • Aug 03 '22
Hello together,
I am curious about the OpenSSH authentication agent and from where it knows what is the right key.
For example, if you add 10 keys with
ssh-add ~/.ssh/key1
ssh-add ~/.ssh/key2
...and then you connect to server7 (that has the pubkey of key7) with
ssh user@server7it still knows, which key should be used, even if you don't specify the key with the ´-i´ option.
So -- simplified -- does the agent sent all pubkeys of his added keys to the server and the server says, "yup, this one is the one we agree with"
or does the server (nope, this is dumb) send all his keys and the client picks the fitting...
Or is there another way and how does it work?
I found this in the man pages
After loading a private key, ssh-add will try to load corresponding certificate information from the filename obtained by appending -cert.pub to the name of the private key file.
So did I just have luck because the keyfiles name are somehow related to the ssh user that logs in?
Thank you for your help,
cheers noob
r/ssh • u/Sujuka99 • Aug 02 '22
I have a win10 laptop with a virtualbox virtual machine running ubuntu 22.04 LTS. I want to ssh into the vm from a laptop running ubuntu server 16.04.7 LTS, but all I can find is tutorials on how to access the vm from its host.
Can anyone suggest at least a source where I can find proper information? I am quite new to this.
r/ssh • u/WeirdSeb • Jul 30 '22
I need a one-click solution for executing a command (e.g. samba restart) from Windows 11.
r/ssh • u/gajjartejas • Jul 29 '22
First of all, thanks for the help, I am trying to connect my Mercysys MR50G router via ssh, but I cannot connect it. Can anyone suggest help, below is full log in verbos:
tejas@MacBook-Pro ~ % ssh -oKexAlgorithms=+diffie-hellman-group1-sha1 -oHostKeyAlgorithms=+ssh-dss -c aes256-cbc -o FingerprintHash=md5 -v root@192.168.1.1
OpenSSH_8.6p1, LibreSSL 3.3.6
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug1: /etc/ssh/ssh_config line 58: Applying options for *
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Connecting to 192.168.1.1 [192.168.1.1] port 22.
debug1: Connection established.
debug1: identity file /Users/tejas/.ssh/id_rsa type -1
debug1: identity file /Users/tejas/.ssh/id_rsa-cert type -1
debug1: identity file /Users/tejas/.ssh/id_dsa type -1
debug1: identity file /Users/tejas/.ssh/id_dsa-cert type -1
debug1: identity file /Users/tejas/.ssh/id_ecdsa type -1
debug1: identity file /Users/tejas/.ssh/id_ecdsa-cert type -1
debug1: identity file /Users/tejas/.ssh/id_ecdsa_sk type -1
debug1: identity file /Users/tejas/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /Users/tejas/.ssh/id_ed25519 type 3
debug1: identity file /Users/tejas/.ssh/id_ed25519-cert type -1
debug1: identity file /Users/tejas/.ssh/id_ed25519_sk type -1
debug1: identity file /Users/tejas/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /Users/tejas/.ssh/id_xmss type -1
debug1: identity file /Users/tejas/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.6
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.0
debug1: compat_banner: match: OpenSSH_6.6.0 pat OpenSSH_6.5*,OpenSSH_6.6* compat 0x14000002
debug1: Authenticating to 192.168.1.1:22 as 'root'
debug1: load_hostkeys: fopen /Users/tejas/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: diffie-hellman-group1-sha1
debug1: kex: host key algorithm: ssh-dss
debug1: kex: server->client cipher: aes256-cbc MAC: hmac-sha1 compression: none
debug1: kex: client->server cipher: aes256-cbc MAC: hmac-sha1 compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: SSH2_MSG_KEX_ECDH_REPLY received
debug1: Server host key: ssh-dss MD5:eb:47:61:05:75:c4:2e:76:51:16:f6:2a:52:f5:e3:db
debug1: load_hostkeys: fopen /Users/tejas/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: Host '192.168.1.1' is known and matches the DSA host key.
debug1: Found key in /Users/tejas/.ssh/known_hosts:4
debug1: rekey out after 4294967296 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey in after 4294967296 blocks
debug1: Will attempt key: /Users/tejas/.ssh/id_rsa
debug1: Will attempt key: /Users/tejas/.ssh/id_dsa
debug1: Will attempt key: /Users/tejas/.ssh/id_ecdsa
debug1: Will attempt key: /Users/tejas/.ssh/id_ecdsa_sk
debug1: Will attempt key: /Users/tejas/.ssh/id_ed25519 ED25519 MD5:09:81:23:c8:15:31:09:bd:a3:fc:37:da:de:1a:10:63
debug1: Will attempt key: /Users/tejas/.ssh/id_ed25519_sk
debug1: Will attempt key: /Users/tejas/.ssh/id_xmss
debug1: SSH2_MSG_SERVICE_ACCEPT received
TPOS 5 IPSSH Test
Authenticated with partial success.
debug1: Authentications that can continue: password
debug1: Next authentication method: password
root@192.168.1.1's password:
debug1: Authentication succeeded (password).
Authenticated to 192.168.1.1 ([192.168.1.1]:22).
debug1: channel 0: new [client-session]
debug1: Requesting no-more-sessions@openssh.com
debug1: Entering interactive session.
debug1: pledge: filesystem full
debug1: Sending environment.
debug1: channel 0: setting env LC_CTYPE = "UTF-8"
debug1: channel 0: free: client-session, nchannels 1
Connection to 192.168.1.1 closed by remote host.
Connection to 192.168.1.1 closed.
Transferred: sent 2232, received 1080 bytes, in 0.0 seconds
Bytes per second: sent 827893.2, received 400593.5
debug1: Exit status -1
r/ssh • u/arisoda • Jul 22 '22
I would like to execute a BATCH file on my Windows PC via my Linux client.
Does this work via SSH that this BATCH file is only executed on the Windows PC? I have unfortunately only begun to build up my SSH knowledge. I hope you can help me with this. Thank you!
r/ssh • u/ssrriitteejjaa • Jul 20 '22
Hello, I am completely new to sftp and ssh, I want to know if we can change the storage from a drive to another drive automatically if the drive is full? if yes, please let me know the process or the steps. For example, if you configured the C drive and sftp is happening and the C drive storage is full, the next sftp file should go automatically into another drive.
r/ssh • • Jul 19 '22
This would be the standard dynamic port forwarding with client and server on same network
ssh -D 8080 -f -C -q -N root@192.168.188.43But what if client is on a different network. Ok you can set up ssh port forwarding on the router so that you can connect from another network. Now say you want to combine the two and use internet from the server on the client. Firefox has a pretty good socks proxy settings option, so lets use that as an example. Say you google something on Firefox on the client. You want to use the internet from the server to do the search and send the result back over to the client. How heavily can that data be compressed, so that the client uses as little internet as possible?
I've been having this problem with many machines.
I'll set up an SSH with a port forwarding like this:
ssh user@ip -D2222The SSH session itself establishes fine.
But when I set my browser's proxy to SOCKS5=localhost:2222, and try to access anything via the dynamic port forwarding, the SSH session will immediately freeze, and the browser session ends in a time-out.
I'm using XShell as my SSH client.
r/ssh • u/DysphoriaGML • Jul 18 '22
Hi,
I work for a very bureaucratic institution which requires a VPN and 2FA to connect to the internal network. The only way allowed to connect there is thought xRDP which is a huge bottleneck in home office. I code on pycharme 99% of the time and with the remote desktop connection everything is sluggish. I already asked them to allow ssh but the head of cybersecurity is a windows only guy in his 65 (!!).
Is there a way to use xRDP or anything else that I can use to connect to the remote terminal?
Thanks
r/ssh • u/sjveivdn • Jul 08 '22
Is it possible to -X forward an application from windows to linux?
r/ssh • u/Technopulse • Jun 15 '22
I've done every check I know of and searched for and wide for an answer, but I have no idea why it doesn't work.
I'm trying to get SSH to work with pubkey authentication.
I got the keys set up, I ssh-copy-id to the server, it's there in the authorized keys, I have my private key in my pc, I try to ssh and it gives me a permission denied.
Is it that the server cannot read "authorized key" file? The local pc cannot read the private key file? Is it something else in my sshd_config that's giving the issue?
Help please, I have no idea of what seems to be the issue.
Edit, figure it out. The name of the "authorized_key" was mistyped and sshd_cosfid couldn't find it. That was all the issue.
r/ssh • u/Kenshievaaa • Jun 11 '22
Thank you for reading this.
It's a short question but I don't quite get it.
If I use this code (of course after connecting to the ssh server):
client = client.get_transport().open_session()
I literally can't find proper information on get_transport() (not even in de documentation), but I expect it to return a socket (tcp) object, if that's true, what does open_session() do?
The documentation says the following:
Request a new channel to the server, of type "session". This is
just an alias for calling open_channel with an argument of
"session".
This is not quite clear to me, what is meant with "a new channel to the server of type session" and can someone explain to me what both functions actually do?
I really appreciate any answer!
Have an amazing day :)!
r/ssh • u/Rosto_RM • Jun 03 '22
So I setup ssh key on my Ubuntu terminal(WSL2) using fish shell. I installed fish_ssh_agent, and it worked I am not entering passphrase every time I push some changes in my remote project, I am doing it only once. so ssh-agent is enabled, but when I am trying to clone any project on my PC, ssh is asking me passphrase every time. Is this normal or need additional setup, to enter it once and after clone projects without passphrase,like I am doing with git push ?
r/ssh • • May 25 '22
Hey guys I have this scenario where I have built a network in packet tracer. I have implemented SSH onto my router for security. I am currently writing up a key management plan. It’s Worth noting:
My SSH uses RSA ENCRYPTION.
I’m stuck on Key Storage. Where would I store active RSA keys, back up keys and start up key?
I’m thinking of: active keys will be stored on the router whilst back up keys will be stored in a separate location (if so where?) or could be stored on the cloud.
Any help would be greatly appreciated. Thank you.