8.1
CWE
94
Advisory Published
CVE Published
Updated

CVE-2019-16255: Code Injection

First published: Wed Nov 20 2019(Updated: )

Ruby through 2.4.7, 2.5.x through 2.5.6, and 2.6.x through 2.6.4 allows code injection if the first argument (aka the "command" argument) to Shell#[] or Shell#test in lib/shell.rb is untrusted data. An attacker can exploit this to call an arbitrary Ruby method.

Credit: cve@mitre.org cve@mitre.org

Affected SoftwareAffected VersionHow to fix
redhat/rh-ruby25-ruby<0:2.5.9-9.el7
0:2.5.9-9.el7
redhat/rh-ruby26-ruby<0:2.6.7-119.el7
0:2.6.7-119.el7
redhat/ruby<2.4.8
2.4.8
redhat/ruby<2.5.7
2.5.7
redhat/ruby<2.6.5
2.6.5
redhat/ruby<2.7.0
2.7.0
ubuntu/jruby<1.5.6-9+
1.5.6-9+
ubuntu/ruby2.3<2.3.1-2~ubuntu16.04.14
2.3.1-2~ubuntu16.04.14
ubuntu/ruby2.5<2.5.1-1ubuntu1.6
2.5.1-1ubuntu1.6
ubuntu/ruby2.5<2.5.5-1ubuntu1.1
2.5.5-1ubuntu1.1
ubuntu/ruby2.5<2.5.5-4ubuntu2.1
2.5.5-4ubuntu2.1
ubuntu/ruby2.5<2.5.7-1
2.5.7-1
debian/jruby
9.3.9.0+ds-8
9.4.8.0+ds-1
ruby-lang Ruby>=2.4.0<=2.4.7
ruby-lang Ruby>=2.5.0<=2.5.6
ruby-lang Ruby>=2.6.0<=2.6.4
Debian Debian Linux=8.0
Debian Debian Linux=9.0
openSUSE=15.1
Oracle GraalVM Enterprise Edition=19.3.0.2

Never miss a vulnerability like this again

Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.

Reference Links

Frequently Asked Questions

  • What is CVE-2019-16255?

    CVE-2019-16255 is a vulnerability in Ruby versions 2.4.7 through 2.6.4 that allows code injection if untrusted data is passed as the first argument to Shell#[] or Shell#test.

  • How severe is CVE-2019-16255?

    CVE-2019-16255 has a severity score of 8.1 (high).

  • What is the affected software of CVE-2019-16255?

    The affected software of CVE-2019-16255 includes Ruby versions 2.4.7 to 2.6.4.

  • How can an attacker exploit CVE-2019-16255?

    An attacker can exploit CVE-2019-16255 by passing untrusted data as the first argument to Shell#[] or Shell#test.

  • Are there any remediation steps for CVE-2019-16255?

    Yes, the recommended remediation steps for CVE-2019-16255 are to upgrade Ruby to version 2.4.8, 2.5.7, or 2.6.5.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2025 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203