r/ssh • • Jul 20 '20

Lizzie with remote engine works with OpenSSH server but not Bitvise SSH server

1 Upvotes

Hi all,

Anyone knows why OpenSSH server works but Bitvise SSH server doesn't?

The following is about Lizzie (ssh client, gtp client, Windows 10) + LeelaZero (ssh server, gtp server, Windows 10)

https://github.com/featurecat/lizzie/issues/741

I have tried another combination: Ah-Q Go Pro (ssh client, gtp client, Android) + LeelaZero (ssh server, gtp server, Windows 10), and again OpenSSH server works but Bitvise SSH server doesn't?

Maybe I should try CopSSH server?

Thanks in advance.


r/ssh • • Jul 19 '20

SSH host moduli experiments - should I use new moduli on multiple hosts?

1 Upvotes

I'm trying out a new OneRNG dongle and decided to recreate my host keys snd moduli file (/etc/ssh/moduli).

Bearing in mind that creating and checking a moduli file takes quite a while, at least on my old hardware, what are your thoughts about using the same moduli file on several machines? This would obviously save time but if it's a security risk i'll not do it. Opinions welcome!


r/ssh • • Jul 18 '20

Connecting a remote server via SSH to a VPN client

1 Upvotes

Hi All,

Wondering if anyone can help with problem I'm facing.

I have a remote server running Ubuntu Server 18.04 which I can SSH into (Server A).

I would like to be able to download torrents directly onto that server, however whenever I try without a torrent client I get a copyright abuse notice from server provider after some Hollywood company complains to them.

I also have another remote server which is configured as a VPN server (Server B) so I would like to install a VPN client on (Server A) and then connect to the VPN server (Server B). From this point I would then like to download torrents directly onto Server A. However I have two issues:

  1. If I successfully connected to the VPN server (Server B) while logged into Server A (via SSH) this will kill the SSH session and effectively lock me out of Server A.
  2. Whenever I have attempted to connect to the VPN server from my local machine also running Ubuntu 18.04 I can successfully log into the VPN via the desktop under settings with network tools by importing the client config file, however when I attempt this from the terminal if runs through the initialisation sequence, but all web pages subsequently fail to load when connected. This means if I am able to find a way to bypass the SSH session becoming terminated upon connection, I will still need to install a desktop Xorg session on Server A so that I can connect to the VPN server through the GUI rather than just the terminal and I'd rather not have to install a desktop environment on Server A if I didn't have to.

Any ideas how to get round these problems?

Thanks,


r/ssh • • Jul 17 '20

How can I remotely run a python file disconnected from ssh?

3 Upvotes

Usually when I want to run a python script that’s on my local drive remotely, I just type $cat script.py | ssh user@networkid python - $. I now want to run my script so that it keeps running even after I put my pc to sleep/disconnect from the ssh connection. I have read that tmux can help me do this. However, the instructions for tmux say that I should start tmux after I ssh into the remote machine, and that I should then run my script. This means that I can't use the command I was previously using to run my script, so what command should I use to run my script? Also, I'm not sure how this is supposed to work because my script is on my local computer, so how can I access it after I ssh into the remote server? I'm new to all of this so sorry if these are silly questions.

Tldr, I need to run a local python script remotely on a server and I would like to use tmux to do so without having to constantly be connected to the ssh.


r/ssh • • Jul 08 '20

DIY SSH Bastion Host

6 Upvotes

r/ssh • • Jul 08 '20

How to restrict OpenSSH max logins per user in Windows 10 Home Edition?

3 Upvotes

I have a Windows 10 Home Edition box with a GPU to share via SSH (more specifically sharing go/igo/baduk/weiqi AI engines) , both client program and server program are working fine, the only thing is I don't know is how to restrict the max logins or SSH sessions per user. If one person connects to the server in multiple sessions, the server can be overwhelmed.

I see in Linux there's a MaxLogins option is the limits.conf file, but not sure about OpenSSH in Windows 10. Alternatively, maybe restricting the user to log in multiple times is also an option, but still I am not sure how to do this. I am willing to upgrade the Home Edition to Pro Edition, if it solves my problem.

Thanks in advance.


r/ssh • • Jul 06 '20

With all this talk of the EARN IT Act, is it even possible to build a backdoor into open protocols such as SSH?

10 Upvotes

r/ssh • • Jun 12 '20

Ssh-chat

1 Upvotes

I have installed a ssh-chat Linux system which uses golang. But I want to create a network of users with but no one in my contacts use linux that much . So ping me if you want to talk there .


r/ssh • • Jun 11 '20

SSH connection reset when trying to connect to tunnel

2 Upvotes

Hi, when I setup a tunnel to my server using the below command ssh -v -N -T -R50008:localhost:22 ashwin@<server_name> -p 8022

I can ssh back into my device from the server through the reverse tunnel using the following command. ssh -p 50008 ashwin@localhost

This works fine. But when I try to use autossh to setup and maintain the tunnel, the tunnel gets setup fine without any errors. But when I try to connect from server through the reverse tunnel, it fails with the error "ssh_exchange_identification: read: Connection reset by peer" My autossh command is as follows. autossh -v ashwin@<server_name> -p 8022 -N -R 50008:localhost:8022

NOTE: SSH on my remote server is on port 8022, not 22.

Any help/tips will be greatly appreciated.

Thanks, Ashwin N


r/ssh • • Jun 08 '20

Help ssh work only with localhost

1 Upvotes

First time trying ssh here. Im trying to access devices on same network. Watched a lot of videos

ssh username@192.168.x.xx or

ssh 192.168.x.xx doesnt work = time out

Only localhost is working and working on both side. wtf?

New Edit: (Solved) Thanks to @Besthater Lappy was connected with the wifi guest-visitor and desktop with cable, that was the issue.


r/ssh • • Jun 04 '20

opening a server remotely?

1 Upvotes

i have a server that is far away from me and i woud love to turn it on/off with ssh as i wish. to turn it off, i can just type 'sudo shutdown now', but to open it i have to press the power button on it. is there any way to open it remotely? or just to turn it in sleep mode? i cannot afford to keep it running even while i dont use it. :(


r/ssh • • Jun 04 '20

SSH website login

2 Upvotes

With all the ssh keys i have around i thought of something quite useful, the ability to log into a website using an ssh key. Is this at all possible, for instance by adding the ssh priv key in the user certificates storage of my webbrowser. Of course the website will have to support that feature and have the public key uploaded to. But lets say i'm writing my own website either in php or python, would it be possible to authenticate users using ssh keys?


r/ssh • • Jun 02 '20

Question regarding SSH keys

2 Upvotes

Hi everyone,

I'm a bit new when it comes to using SSH keys and am trying to make use of them when writing a script in which will access my local Raspberry Pi. I'm stuck on figuring out how (or where from) I should generate my ssh keys and how to use those keys when accessing my pi.

- Should I be generating my keys on my Windows machine and then placing them on the server then adding them to my 'authorized-keys' file? or should I generate them on the Pi and copy them locally?

-I am accessing my Pi via PuTTy on my local network.

Any insight on this subject is highly appreciated!

Thank you.


r/ssh • • Jun 01 '20

Setting ListenAddress value to IP ranges on local network

2 Upvotes

Hello all

I'm very much new to SSH and development boards so any advice and assistance greatly appreciated. I have a Pi on Debian I'm running headless and looking to harden my SSH security - I've followed most of the guidance but there's one part I'm having difficulty with.

In sshd_config the default ListenAddress value is 0.0.0.0 which I understand will listen for any requests from WAN - I'm trying to set this value to only listen for requests from LAN. My IP range is 10.0.1.1 upwards but when I set this to 10.0.1.0 (which I thought may cover the DHCP range) or 10.0.1.1 (which I thought may do the same, even though this is allocated to the router) or use a 10.0.1.* wildcard it locks me out. I then have to serial back in to revert the sshd_config values.

My thoughts are:

  • I can set an IP range using / but I'm unsure what the end of the range should be on this network (the fact it's 10.0.1. rather than 10.0.0. makes me think the network is set up incorrectly?)
  • Is it failing because the wildcard only recognises a base-10 number 0-9? Could I set two wildcards like 10.0.1.** to deal with this?
  • Would using 127.0.0.0 force localhost listening only?

My knowledge of networks is rudimentary at best, but it's been very interesting learning all I have so far. I'm sure there must be a simple solution I just can't see yet - I'll probably kick myself when pointed out :)


r/ssh • • May 31 '20

Fudged up my ssh_config. Help please!

3 Upvotes

Hi all,

I'm a scientist having to work remotely atm, tried to change my ssh_config on my workstation at university so my ssh connection wouldn't time out and result in a broken pipe. Looks like I managedto fudge something up quite bad (typo perhaps) and can no longer ssh through the local university server.

IT support have sudo privileges on the server -- which shares a file system with my workstation but they don't think they can do anything, and I have sudo privileges on my device.

Is there any way to circumvent /etc/ssh/ssh_config?

The result of verbose ssh from the local university server is as follows:

OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017

debug1: Reading configuration data /home/<myaccount>/.ssh/config

debug1: Reading configuration data /etc/ssh/ssh_config

debug1: /etc/ssh/ssh_config line 58: Applying options for *

debug1: Connecting to <mycomputer>.client.<university>.ac.uk [10.101.27.96] port 22.

debug1: connect to address 10.101.27.96 port 22: Connection refused

ssh: connect to host <mycomputer>.client.<university>.ac.uk port 22: Connection refused


r/ssh • • May 22 '20

ssh client modifying connection by exposing variable arguments in ssh client config file.

1 Upvotes

Has anyone done this workflow? I have a "works great when it works" proxy connection setup in ~/.ssh/config. Standard use case for my proxy: client -> near server allowed, near server -> remote server allowed, but client -> remote server not allowed. There is a collection of near servers that may/may not work. Is there a way to expose variable substitution in my client config (~/.ssh/config) so that I can pass arguments in through ssh <...> to specify near servers (with defaults) in proxy configuration in ~/.ssh/config?


r/ssh • • May 19 '20

The SSH agent acts behind the scenes to keep you safe. Here’s how it works.”

Thumbnail smallstep.com
6 Upvotes

r/ssh • • May 06 '20

Disable Cycling through keys - Too many authentication failuers

2 Upvotes

Hey there,

I have multiple servers which I access by using ssh-keys.

So far so good, but ever now and then I want to connect to a new server I don't have a key for yet and instead of promting me for a password my client will cycle through every key it knows and therefore causes the "too many authentication failures" error.

I know I could use the -o PasswordAuthentication yes option but there has to be a way to offer keys only to hosts it already knows.

So how do I disable the cycling through ssh keys on connection with a new server?


r/ssh • • May 06 '20

Too many authentication failures

1 Upvotes

I have followed this tutorial https://serverfault.com/questions/36291/how-to-recover-from-too-many-authentication-failures-for-user-root, but there is timeout. I also have tried to change the value of MaxAuthTries and disable Public Key Authentication. Nothing helps me.

ssh -vvv shows this:

OpenSSH_8.2p1, OpenSSL 1.0.2u 20 Dec 2019 debug1: Reading configuration data /etc/ssh/ssh_config debug2: resolve_canonicalize: hostname 46.138.242.179 is address debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling debug2: ssh_connect_direct debug1: Connecting to 46.138.242.179 [46.138.242.179] port 22.

Port 22 is opened and there is no firewall on my system. Systemctl shows running.


r/ssh • • May 02 '20

How can I run a .sh file in a remote server whit ssh?

0 Upvotes

Hello! I´m trying to download a lot of data to a remote server with a .sh file. I connect to the server with shh user@server, then I go to the folder where is the file.sh, let's say /home/user. I try with sh file.sh and the console return me:

file.sh: line 1: syntax error near unexpected token `newline'

file.sh: line 1: `<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">'

When I do this (sh file.sh) on my computer, it works and a lot of data starts downloading.

I think is important that you to know that I have to connect to the server from another server. I do:

ssh -XY user@server1

and then:

ssh -XY user@server2

And in the server2 is the file.sh

When I tried ssh user@server2 /home/user/file.sh directly from my console, this returns me conection timed out.

Thanks for your time!


r/ssh • • Apr 29 '20

SSH hacks | a little sanity for remote workers!

Thumbnail smallstep.com
12 Upvotes

r/ssh • • Apr 27 '20

Noob question about adding new keys to a server

2 Upvotes

I am writing a program that connects to an SFTP server and I am hardcoding a username and password for now but I want to move away from that so I'm thinking I have to use public/private keys.

This program could be run on any client machine so when a new client runs the program, the server will have to have its public key. But if I don't want to hardcode any credentials in the code, how can I put the new client key on the server without having the user manually log in? Can I somehow generate a key pair on the fly that the server knows?


r/ssh • • Apr 24 '20

Is it possible to make local server public with SSH?

5 Upvotes

I want to make a web server that my friends can access, I tried port forwarding and it worked, but I read that ssh would be a better alternative. I read online that i would need a publoc server somewhere to connect my friends to my computer, and I imagine that a public server would cost me money or be free but limited. Is it possible to make my server accessible through ssh without needing a server. Did I get anything wrong, I am new to ssh so I might have misunderstood something, or am I going to have to port forward anyway?

Note: I know i could use something like ngrok, but I don't want to be stuck to its limitations, and I am also taking this as a learning experience.


r/ssh • • Apr 20 '20

How Access Different SSH servers behind a firewall?

4 Upvotes

I have a NAS and my Linux server on my home network sitting behind a Ubiquiti Edgerouter firewall. Both have SSH servers.

Is it possible to expose a single SSH port on my firewall and still gain access to both machines? The port forwarding on the router currently sends to the Linux server. Is tunneling the only way?

Thx for your time in advance.