Questions tagged [openssh]

Questions about the OpenSSH implementation of the ssh protocol.

Filter by
Sorted by
Tagged with
2
votes
1answer
51 views

Is it possible to configure different ssh ports for different users?

We can change the default port settings at /etc/ssh/sshd_config but the manual does not provide any information if we can assign different ports for different users? Is setting up multiple ports for a ...
0
votes
0answers
19 views

Why does `ssh-agent -k` not kill ssh-agent (macOS), or why is `SSH_AGENT_PID` not set?

I'm trying to troubleshoot a sudden outbreak of short-lived SSH connections. These connections are initiated from my Mac (MBP, Catalina 10.15.6, zsh) to some of the Linux "appliances" that ...
0
votes
0answers
10 views

Implementing ProxyJump command using Golang

I'm trying to write an SSH server using Golang and we need to be able to redirect any incoming SSH request to an arbitrary end service. We're setting up ProxyJump so the users don't have to do it ...
4
votes
1answer
56 views

OpenSSH session is killed when from Perl a syswrite call is made with an empty variable in Solaris 11

We have a strange problem in Solaris 11.4. The problem arise when a code as the following is run from Perl my $emptystring = ""; syswrite STDOUT, $emptystring; The execution of a syswrite ...
1
vote
1answer
19 views

After Match Group block, in ForceCommand can I somehow refer to the username (etc.) in a generic fashion?

Suppose I am using Match Group and inside of that block I am using ForceCommand is there a way to refer to the name of the connecting user or the user's home folder in a similar fashion ...
0
votes
0answers
28 views

OpenSSH - jump host on HP NA is not working

I would like to ask you if someone of you have similar problem to establish remote SSH connection via HPNA bastion host. What I achieved so far is the notification on debug mode: debug1: channel 0: ...
1
vote
1answer
50 views

SSH client seems to be checking '/dev/null' instead of 'known_hosts' file when checking remote server's ECDSA key

I'd like to know why my known_hosts file doesn't seem to be checked correctly while using SSH. In short, my guess is that my SSH client is checking /dev/null instead of the known_hosts file. Details ...
1
vote
0answers
46 views

SSH Server on Ubuntu no longer working

I restarted my server today and my SSH server stopped working. Docker is still running, the database is up, but connections to the SSH server are timing out. I made sure that it’s not the firewall, ...
2
votes
0answers
16 views

OpenSSH U2F as second factor with fallback to Google Authenticator

We use Google Authenticator for 2FA SSH logins. It's configured in /etc/pam.d/sshd as follows: @include common-password auth required pam_google_authenticator.so nullok As you may know, OpenSSH 8.2 ...
0
votes
0answers
39 views

ProxyJump with inherited username

Currently my ssh setup from my local machine with username bobby is as follows $ ssh -J gateway bob@server1 . . . $ ssh -J gateway bob@server5 . . . $ ssh -J gateway bob@cluster1 . . . $ ssh -J ...
0
votes
0answers
15 views

ssh-keygen : generate public key from private key? [duplicate]

I got a pub/pri key pair generated using ssh-keygen. ssh-keygen -t rsa -b 2048 Now say, I lost the public key but have the private key. So I want to generate the public key using private key, which I ...
1
vote
0answers
56 views

How to definitively keep SSH sessions open while putting laptop to sleep?

I often have a bunch of SSH sessions open, all of which die after putting my laptop to sleep and waking it, even after only a few minutes. This is not ideal to have to reconnect all of these sessions ...
0
votes
0answers
15 views

ssh_exhance_identification, with no log information

So I am getting the error ssh_exchange_identification: read: Connection reset by peer When trying to ssh into my WSL 2 Distribution (Ubuntu 16.04). I have made sure that all the firewalls/routing is ...
1
vote
1answer
65 views

ssh fails with pam_systemd(sshd:session): Failed to create session: File exists

I have a situation where an outside ssh repeatedly (in a fast loop) connects to an OpenSSH daemon inside a Docker container that is based on Debian 10.5. Authorization is via an authorized key in $...
1
vote
3answers
271 views

Can't SSH into CentOS 8 with Public Key Auth

I can't log into a clean Centos8 install on my VPS from the terminal using public key authentication. When logging in it seems to authenticate OK, but then it times-out then returns a "Connection ...
0
votes
1answer
33 views

Custom Directory for SSH Identity Files

Is there a way to specify a different default directory for ssh identity files? Normally, the default directory is ~/.ssh, but I would like to specify (in the .ssh/config file I assume) a different ...
2
votes
1answer
45 views

Failed to start OpenSSH server daemon loop preventing boot Centos 8

I attempted to allow a usergroup "students" to use password log in over ssh by adding the lines: Match Group students PasswordAuthentication yes to the end of my /etc/ssh/sshd_config ...
0
votes
2answers
37 views

OpenSSH: How to run a command upon ssh connection

I need to customize OpenSSH server, so that when a new SSH connection is being made to the server, it runs some command (like running a bash script). This command is supposed to "prepare" ...
2
votes
2answers
30 views

Change keys on ssh server

I just re-installes openssh server on my Linux, and I need to generate new keys, BUT I can't find anywhere how to do it? When I'm searching they are only taking about keys to login, and how to create ...
1
vote
1answer
62 views

sshd_config using a match statement inside an included file

I have the following sshd configuration files: /etc/ssh/sshd_config: Include /etc/ssh/sshd_config.local Protocol 2 PermitRootLogin no StrictModes no PasswordAuthentication no PrintMotd no Banner /...
1
vote
1answer
21 views

upgrading openssh on debian

I’m running a site on Google Cloud Computing, which uses debian distrib. We recently had a security audit, and one recommendation was to upgrade to OpenSSH from 7.4 to 7.8 or later. apt is showing ...
2
votes
1answer
41 views

How to Configure OpenSSH Server to connect to an isolated computer's console via a serial port?

Imagine the following scenario: "Client" and "Connected" both exist on a network. A third computer, "Isolated," is not on any network but exposes a console over a serial ...
1
vote
0answers
73 views

ssh-keyscan reports no key on libssh-based server

A vendor decided to start using libssh as the ssh server of an appliance. While openssh and putty connect to this appliance without problems, ssh-keyscan returns no keys. Any idea why? Output from the ...
0
votes
1answer
22 views

Cannot open new SSH connections after a certain amount of time

I have a web server running Alpine linux and OpenSSH. When I power on the server, for about an hour or two I am able to open SSH connections and send commands fine. However, after that, even though ...
0
votes
1answer
174 views

ssh client not trying publickey authentication on port 22

I am trying to ssh from an Ubuntu machine ( VM on Win 10) to a linux server using public keys (DSA). However the OpenSSH client on the Ubuntu does not try public keys as authentication method even ...
0
votes
1answer
93 views

OpenSSH: Cannot disable weak algorithms

I am on an RHEL 7.5 and I would like to disable weak crypto algorithms (i.e. CBC-based ciphers, weak MACs, etc.). Hence, I modified /etc/ssh/sshd_config, especially the lines starting with ciphers and ...
2
votes
0answers
133 views

PermitListen option in sshd_config does not work

I'm trying to put the following into my sshd_config file: Match User apricot PermitListen 53000 Restarting OpenSSH server via the service sshd restart command fails. The command journalctl -...
1
vote
3answers
269 views

How can I restrict SSH to only listen for requests from my local network?

I am a beginner and new to development boards and Linux as a whole, and have been using the wonderful SSH package with Debian (I believe this is OpenSSH) to tinker around and learn more without the ...
1
vote
0answers
26 views

ssh keys in /etc/ssh keep being regenerated on startup

I have set up a Raspian Buster OS with /etc in its own partition. Whenever I reboot the machine, the ssh keys in /etc/ssh keep being regenerated. I have checked jounrnalctl log, but it doesn't show ...
2
votes
0answers
55 views

X11 forwarding gnuradio-companion issue

I am trying to use gnuradio-companion on a remote compute node running ubuntu 18.04.1 LTS. I ssh into the server with the command: ssh -p 22 address.net -X And when I open gnuradio-companion, the ...
2
votes
1answer
105 views

Why is bash sourcing .bashrc in non-interactive mode when working via ssh?

I have a CentOS VM to which I log in using SSH. I appended the following line to .bashrc echo "from ~/.bashrc: (pid $$)" and the following line to .bash_profile echo "from ~/.bash_profile" When I ...
1
vote
2answers
60 views

Can a user with no password set login with ssh?

First, I want to be clear, I am not asking about just using public key authentication without a prompt. I have a use case where a user must only be allowed access through SSH public key authentication....
0
votes
0answers
19 views

Use same credentials in GNOME Files and SSH

With GNOME Files, I use a password to access a CIFS (Samba) share. For the remainder of the session, GNOME maintains my credentials and I don't have to enter the password again, even after suspending ...
0
votes
3answers
41 views

Does ssh client need public key, also?

My understanding is that openssh client requires only private key, the corresponding public key must be in the Server. However, I see the following in the ssh client when I increase the verbosity ...
0
votes
2answers
66 views

Ssh without password shows error?

I have two debian machine virtual box running Debian GNU/Linux 9. I have tried using the following process but I still get the password asked for? It fails and it says - Postponed publickey for test ...
0
votes
2answers
41 views

How can I configure ~/.ssh/config such that `ssh foo.bar` results in a connection to `foo.internal.bar`?

I have a system with both a public (e.g server1.foo.bar) and privately-resolvable (e.g. server1.internal.foo.bar) DNS name. SSH connections are only possible via the private IP, but I always think of ...
1
vote
1answer
8k views

SSH “kex_exchange_identification: read: Connection reset by peer”

The setup: Raspberry 3B running Raspbian Stretch 9 on an external HDD and using ZRAM Raspi used as a webserver running LAMP and MERN stacks and accessed remotely via SSH with 1 IDE (Coda for Mac OS) ...
0
votes
1answer
42 views

System-wide known-hosts file?

I am trying to do a github-git pull from a php script as a www-data user and i am getting "Host key verification failed.". My main user has the host key registered, but my www-data does not as it ...
0
votes
0answers
37 views

SSH not accepting the correct passwords

I installed Debian 10 on a second drive inside my main pc, the installer gave me the option of installing SSH, which I did. I checked the drive booted still on my main pc which it did (and I was able ...
0
votes
0answers
75 views

How to implement dynamic file permissions

I have application that creates a "records" of data. Every record has a directory with "attachments". User creates a record (via app web interface), my applications creates attachments directory and ...
2
votes
1answer
150 views

SSH connection freezes on 4G Hotspot but not on any Wifi

Short Description I have been seeing an strange behaviour on my SSH connection for years but never thought of raising a question until today. I tried to search a lot about this but couldn't find any ...
1
vote
1answer
1k views

“Warning: untrusted X11 forwarding setup failed” on nested ssh

I have a gateway to ssh into from the bad world wide web. No problem, I get: remote ~$ ssh -X ingo@gateway Debian GNU/Linux 10 (buster) 0:ingo@gateway ~$ Now I manage my other hosts, for example the ...
2
votes
1answer
69 views

OpenSSH not respecting $HOME when searching for ssh config files

I'm writing some integration tests, that test SSH connections between servers. For the time being the tests are run from people's laptops. In order not to muck around in the user's (the user running ...
0
votes
1answer
14 views

Access NATed remote system through an existing ssh connection

There is a machine RemoteA that is behind a NAT somewhere on the internet. It can connect to an ssh server. There is another machine called RemoteB that also has a connection to the same ssh server. ...
0
votes
0answers
40 views

Double hop scp - OpenSSH error [duplicate]

I am trying to copy a file from my local machine A to a server C through server B using scp. I have read a couple of things on this, and came up with this: scp -o ProxyCommand="ssh -J user@serverB:...
0
votes
1answer
331 views

What kind of an sshd attack is this?

I have never seen this before in my sshd logs: Mar 16 17:21:48 x-server sshd[9848]: Bad protocol version identification '\026\003\001' from 45.143.221.50 port 35026 Mar 16 17:21:48 x-server sshd[9849]...
0
votes
0answers
52 views

How to install OpenSSH on stripped down Linux OS without a package manager

I have a satellite box that uses a stripped down version of linux OS. It runs enigma2 SVN-2860 based on GIT-5580 used for watching satellite and terrestrial digital tv. It's a PKT Hyperion enigma2 ...
1
vote
2answers
177 views

How to remove (not override, not create new) options from systemd unit files?

How are lines removed from a standard (system) systemd unit file? Here are the details: ls -la /etc/ssh/ssh_host_*key* This shows I have unused and unwanted host key types. They are not configured ...
1
vote
1answer
46 views

Can you use both + and - to edit sshd_config option

The answers here helped me a lot. However, in my case, I want to disable some MACs and add a few new ones. Is there a way to do this without hardcoding the options? The following doesn't work. MACs ...
0
votes
0answers
16 views

OpenSSH Http proxy can't connect

I am using Kitty for my SSH connection with HTTP proxy. The telnet command used is: connect %host %port\n I want to use OpenSSH, but I am struggling to make .config work. I even tried netcat but ...

1
2 3 4 5
12