Intel

AIKIDO-2026-719101

net-ssh is vulnerable to OS Command Injection

OS Command InjectionGHSA-3x7f-q7wf-fp73 Published Yesterday

59

Medium Risk

This Affects:

RUBYnet-ssh
0.0.1 - 7.3.4
Fixed in 7.3.5
Are you affected? Scan for Free

TL;DR

Net::SSH::Proxy::Command and Net::SSH::Proxy::Jump substitute the proxy host, port, and remote_user values into a command line template and run the result through IO.popen, which passes the string to /bin/sh -c without escaping any of those values. An application that passes externally influenced host, port, or user data to Net::SSH.start with a proxy configured, or to Proxy::Jump.new, lets shell metacharacters in that data run arbitrary commands on the SSH client host. The fix validates or escapes these values before they reach the shell.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and your application passes externally influenced host, port, or user values into a configured SSH proxy command.

Background info

net-ssh is vulnerable to OS Command Injection in versions 0.0.1 - 7.3.4.

How to fix this

Upgrade the net-ssh library to the patch version.

Are You Affected?

Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.

Free. No credit card required.

Aikido Platform