# SSH Node to Legacy Systems

**URL:** <https://community.n8n.io/t/ssh-node-to-legacy-systems/57703>\
**Category:** Questions\
**Tags:** node\
**Created:** [October 15, 2024, 2:14pm UTC](https://community.n8n.io/t/ssh-node-to-legacy-systems/57703 "2024-10-15T14:14:54Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mulen](https://avatars.discourse-cdn.com/v4/letter/m/5fc32e/32.png) [@Mulen](https://community.n8n.io/u/Mulen)\
**Post date:** [October 15, 2024, 2:14pm UTC](https://community.n8n.io/t/ssh-node-to-legacy-systems/57703/1 "2024-10-15T14:14:54Z")

</div>

Hello.

We want to use the SSH node to connect to old legacy Linux systems via SSH node.

To make this happen we have to use this guide below

> **[SSH from RHEL 9 to RHEL 5 or RHEL 6](https://rwmj.wordpress.com/2022/08/08/ssh-from-rhel-9-to-rhel-5-or-rhel-6/)**
>
> RHEL 9 no longer lets you ssh to RHEL ≤ 6 hosts out of the box. You can weaken security of the whole system but there’s no easy way to set security policy per remote host. Here’s how to…

We have to create a `.ssh/config` file add the below config

```auto
Host rhel5or6-host
KexAlgorithms +diffie-hellman-group14-sha1
MACs +hmac-sha1
HostKeyAlgorithms +ssh-rsa
PubkeyAcceptedKeyTypes +ssh-rsa
PubkeyAcceptedAlgorithms +ssh-rsa

```

Then create another config file `/tmp/openssl.cnf ` and add

```auto
.include /etc/ssl/openssl.cnf
[openssl_init]
alg_section = evp_properties
[evp_properties]
rh-allow-sha1-signatures = yes

```

Finally you can connect like this

`OPENSSL_CONF=/tmp/openssl.cnf ssh rhel5or6-host`

Is there a way to define this steps somehow via .env variables when the docker container starts so that SSH node can connect to these legacy systems?

Now we are getting an error from the node

`SSH connection failed: Handshake failed: no matching key exchange algorithm`

---

<div class="post-metadata">

**Author:** ![n8n](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/n8n/32/196425_2.png) [@n8n](https://community.n8n.io/u/n8n)\
**Post date:** [October 15, 2024, 2:14pm UTC](https://community.n8n.io/t/ssh-node-to-legacy-systems/57703/2 "2024-10-15T14:14:56Z")

</div>

It looks like your topic is missing some important information. Could you provide the following if applicable.

- **n8n version:**
- **Database (default: SQLite):**
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):**
- **Operating system:**

---

<div class="post-metadata">

**Author:** ![Jon](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/jon/32/40174_2.png) [@Jon](https://community.n8n.io/u/Jon)\
**Post date:** [October 15, 2024, 3:06pm UTC](https://community.n8n.io/t/ssh-node-to-legacy-systems/57703/3 "2024-10-15T15:06:22Z")

</div>

Hey @Mulen,

At the moment there is no option in the node to allow support for legacy key ciphers, The best option I can think of would be to create a jump box somewhere that can connect to them that you can lock down then use the SSH node to connect to that box first then move on to one of the older systems.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [January 13, 2025, 3:06pm UTC](https://community.n8n.io/t/ssh-node-to-legacy-systems/57703/4 "2025-01-13T15:06:27Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
