Skip to content
Fencer Vulns
high 8.8

CVE-2017-17405 in the critical feed json

Ruby before 2.4.3 allows Net::FTP command injection.

published 2017-12-15 8 y ago modified 2026-06-17 4 mo ago also EUVD-2017-8570

cvss
8.8
version 3.0, NVD
cisa kev
Not listed
not in CISA's catalog
epss
73.8%
EPSS 73.8% chance of exploitation in 30 days, percentile 99.4%
public exploits
1
Exploit-DB

Summary

Ruby before 2.4.3 allows Net::FTP command injection. Net::FTP#get, getbinaryfile, gettextfile, put, putbinaryfile, and puttextfile use Kernel#open to open a local file. If the localfile argument starts with the "|" pipe character, the command following the pipe character is executed. The default value of localfile is File.basename(remotefile), so malicious FTP servers could cause arbitrary command execution.

Patch / fix

  • ruby2.0 Ubuntu 14.04 LTS 2.0.0.484-1ubuntu2.5
  • ruby2.3 Ubuntu 16.04 LTS 2.3.1-2~16.04.4
  • ruby1.9.1 Ubuntu 14.04 LTS 1.9.3.484-2ubuntu1.6

ubuntu advisories UBUNTU-CVE-2017-17405

Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

  • rh-ruby22-ruby RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el6
  • rh-ruby22-ruby RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el7
  • rh-ruby22-ruby-irb RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el6
  • rh-ruby22-ruby-irb RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el7
  • rh-ruby22-rubygems RHEL 3 SOFTWARE_COLLECTIONS 2.4.5.4-19.el6
  • rh-ruby22-rubygems RHEL 3 SOFTWARE_COLLECTIONS 2.4.5.4-19.el7
  • rh-ruby22-ruby-libs RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el6
  • rh-ruby22-ruby-libs RHEL 3 SOFTWARE_COLLECTIONS 2.2.9-19.el7

red hat advisories RHSA-2018:0583RHSA-2018:0585RHSA-2018:0378RHSA-2019:2806RHSA-2018:0584

  • ruby2.1 SLES for SAP 12 SP5, SLES for SAP 12 SP4, SLES for SAP 12 SP3 +14 more 2.1.9-19.3.2
  • yast2-ruby-bindings SLES for SAP 12 SP2, SLES 12 SP2-LTSS, SLES 12 SP2-BCL +1 more 3.1.53-9.8.1

suse advisories SUSE-SU-2020:1570-1

  • ruby Alpine 3.24, Alpine 3.23, Alpine 3.22 +16 more 2.4.3-r0
  • ruby Alpine 3.3 2.2.9-r0
  • ruby Alpine 3.5, Alpine 3.4 2.3.6-r0

alpine advisories ALPINE-CVE-2017-17405

Alpine secdb © Alpine Linux, from https://secdb.alpinelinux.org via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2017-17405 updated cvss 6.3

ruby: Command injection vulnerability in Net::FTP

  • Red Hat CloudForms Management Engine 5 ruby-200-ruby, rh-ruby22-ruby
    affected: no fix available
  • Red Hat Enterprise Linux 5 ruby Red Hat Enterprise Linux 6 ruby, ruby-ri, ruby-irb, ruby-libs, ruby-rdoc, ruby-tcltk
    affected: no fix planned “Will not fix”
  • Red Hat Subscription Asset Manager ruby193-ruby
    affected: no fix available
  • Red Hat Enterprise Linux Client (v. 7) ruby 2.0.0.648-33.el7_4, rubygems 2.0.14.1-33.el7_4, ruby-irb 2.0.0.648-33.el7_4, rubygem-json 1.7.7-33.el7_4, rubygem-rdoc 4.0.0-33.el7_4, ruby-libs 2.0.0.648-33.el7_4, +3 more Red Hat Enterprise Linux Client Optional (v. 7) rubygem-rake 0.9.6-33.el7_4, ruby-tcltk 2.0.0.648-33.el7_4, rubygem-minitest 4.3.2-33.el7_4 Red Hat Enterprise Linux ComputeNode (v. 7) ruby 2.0.0.648-33.el7_4, rubygems 2.0.14.1-33.el7_4, ruby-irb 2.0.0.648-33.el7_4, rubygem-json 1.7.7-33.el7_4, rubygem-rdoc 4.0.0-33.el7_4, ruby-libs 2.0.0.648-33.el7_4, +3 more Red Hat Enterprise Linux ComputeNode Optional (v. 7) rubygem-rake 0.9.6-33.el7_4, ruby-tcltk 2.0.0.648-33.el7_4, rubygem-minitest 4.3.2-33.el7_4 Red Hat Enterprise Linux for ARM and IBM Power LE (POWER9) Server (v. 7) ruby 2.0.0.648-33.el7_4, rubygems 2.0.14.1-33.el7_4, ruby-irb 2.0.0.648-33.el7_4, rubygem-json 1.7.7-33.el7_4, rubygem-rdoc 4.0.0-33.el7_4, ruby-libs 2.0.0.648-33.el7_4, +3 more Red Hat Enterprise Linux for ARM and IBM Power LE (POWER9) Server Optional (v. 7) rubygem-rake 0.9.6-33.el7_4, ruby-tcltk 2.0.0.648-33.el7_4, rubygem-minitest 4.3.2-33.el7_4
    +1 more products
    Red Hat Enterprise Linux Server (v. 7) ruby 2.0.0.648-33.el7_4, rubygems 2.0.14.1-33.el7_4, ruby-irb 2.0.0.648-33.el7_4, rubygem-json 1.7.7-33.el7_4, rubygem-rdoc 4.0.0-33.el7_4, ruby-libs 2.0.0.648-33.el7_4, +3 more
    fixed: vendor fix RHSA-2018:0378
  • Red Hat Enterprise Linux Server AUS (v. 7.3) ruby 2.0.0.648-30.el7_3, rubygems 2.0.14.1-30.el7_3, ruby-irb 2.0.0.648-30.el7_3, rubygem-json 1.7.7-30.el7_3, rubygem-rdoc 4.0.0-30.el7_3, ruby-libs 2.0.0.648-30.el7_3, +3 more Red Hat Enterprise Linux Server E4S (v. 7.3) ruby 2.0.0.648-30.el7_3, rubygems 2.0.14.1-30.el7_3, ruby-irb 2.0.0.648-30.el7_3, rubygem-json 1.7.7-30.el7_3, rubygem-rdoc 4.0.0-30.el7_3, ruby-libs 2.0.0.648-30.el7_3, +3 more
    fixed: vendor fix RHSA-2019:2806
  • Red Hat Enterprise Linux Server Optional (v. 7) rubygem-rake 0.9.6-33.el7_4, ruby-tcltk 2.0.0.648-33.el7_4, rubygem-minitest 4.3.2-33.el7_4
    fixed: vendor fix RHSA-2018:0378
  • Red Hat Enterprise Linux Server Optional AUS (v. 7.3) rubygem-rake 0.9.6-30.el7_3, ruby-tcltk 2.0.0.648-30.el7_3, rubygem-minitest 4.3.2-30.el7_3 Red Hat Enterprise Linux Server Optional E4S (v. 7.3) rubygem-rake 0.9.6-30.el7_3, ruby-tcltk 2.0.0.648-30.el7_3, rubygem-minitest 4.3.2-30.el7_3 Red Hat Enterprise Linux Server Optional TUS (v. 7.3) rubygem-rake 0.9.6-30.el7_3, ruby-tcltk 2.0.0.648-30.el7_3, rubygem-minitest 4.3.2-30.el7_3 Red Hat Enterprise Linux Server TUS (v. 7.3) ruby 2.0.0.648-30.el7_3, rubygems 2.0.14.1-30.el7_3, ruby-irb 2.0.0.648-30.el7_3, rubygem-json 1.7.7-30.el7_3, rubygem-rdoc 4.0.0-30.el7_3, ruby-libs 2.0.0.648-30.el7_3, +3 more
    fixed: vendor fix RHSA-2019:2806
  • Red Hat Enterprise Linux Workstation (v. 7) ruby 2.0.0.648-33.el7_4, rubygems 2.0.14.1-33.el7_4, ruby-irb 2.0.0.648-33.el7_4, rubygem-json 1.7.7-33.el7_4, rubygem-rdoc 4.0.0-33.el7_4, ruby-libs 2.0.0.648-33.el7_4, +3 more Red Hat Enterprise Linux Workstation Optional (v. 7) rubygem-rake 0.9.6-33.el7_4, ruby-tcltk 2.0.0.648-33.el7_4, rubygem-minitest 4.3.2-33.el7_4
    fixed: vendor fix RHSA-2018:0378
show 1 more
  • Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 6) rh-ruby22-ruby 2.2.9-19.el6, rh-ruby23-ruby 2.3.6-67.el6, rh-ruby24-ruby 2.4.3-90.el6, rh-ruby22-ruby-irb 2.2.9-19.el6, rh-ruby23-ruby-irb 2.3.6-67.el6, rh-ruby24-ruby-irb 2.4.3-90.el6, +41 more Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) rh-ruby22-ruby 2.2.9-19.el7, rh-ruby23-ruby 2.3.6-67.el7, rh-ruby24-ruby 2.4.3-90.el7, rh-ruby22-ruby-irb 2.2.9-19.el7, rh-ruby23-ruby-irb 2.3.6-67.el7, rh-ruby24-ruby-irb 2.4.3-90.el7, +41 more Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 6.7) rh-ruby22-ruby 2.2.9-19.el6, rh-ruby23-ruby 2.3.6-67.el6, rh-ruby24-ruby 2.4.3-90.el6, rh-ruby22-ruby-irb 2.2.9-19.el6, rh-ruby23-ruby-irb 2.3.6-67.el6, rh-ruby24-ruby-irb 2.4.3-90.el6, +41 more Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.3) rh-ruby22-ruby 2.2.9-19.el7, rh-ruby23-ruby 2.3.6-67.el7, rh-ruby24-ruby 2.4.3-90.el7, rh-ruby22-ruby-irb 2.2.9-19.el7, rh-ruby23-ruby-irb 2.3.6-67.el7, rh-ruby24-ruby-irb 2.4.3-90.el7, +41 more Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) rh-ruby22-ruby 2.2.9-19.el7, rh-ruby23-ruby 2.3.6-67.el7, rh-ruby24-ruby 2.4.3-90.el7, rh-ruby22-ruby-irb 2.2.9-19.el7, rh-ruby23-ruby-irb 2.3.6-67.el7, rh-ruby24-ruby-irb 2.4.3-90.el7, +41 more Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 6) rh-ruby22-ruby 2.2.9-19.el6, rh-ruby23-ruby 2.3.6-67.el6, rh-ruby24-ruby 2.4.3-90.el6, rh-ruby22-ruby-irb 2.2.9-19.el6, rh-ruby23-ruby-irb 2.3.6-67.el6, rh-ruby24-ruby-irb 2.4.3-90.el6, +41 more
    +1 more products
    Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) rh-ruby22-ruby 2.2.9-19.el7, rh-ruby23-ruby 2.3.6-67.el7, rh-ruby24-ruby 2.4.3-90.el7, rh-ruby22-ruby-irb 2.2.9-19.el7, rh-ruby23-ruby-irb 2.3.6-67.el7, rh-ruby24-ruby-irb 2.4.3-90.el7, +41 more
    fixed: vendor fix RHSA-2018:0583

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Timeline

  1. First public exploit (EDB-43381)
  2. Published

Exploit prediction

73.83% chance of exploitation in the next 30 days, higher than 99.4% of all scored CVEs (FIRST EPSS, 2026-11-08).

Exploits and checks

  • EDB-43381 Ruby < 2.2.8 / < 2.3.5 / < 2.4.2 / < 2.5.0-preview1 - 'NET::Ftp' Command Injection local, 2017-12-02

CVSS scores

assigned by version score vector
NVD 3.0 8.8 CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
NVD 2.0 9.3 AV:N/AC:M/Au:N/C:C/I:C/A:C

Classification

Weakness
  • CWE-78 Improper Neutralization of Special Elements used in an OS Command

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.