{"id":"ALPINE-CVE-2019-5477","details":"A command injection vulnerability in Nokogiri v1.10.3 and earlier allows commands to be executed in a subprocess via Ruby's `Kernel.open` method. Processes are vulnerable only if the undocumented method `Nokogiri::CSS::Tokenizer#load_file` is being called with unsafe user input as the filename. This vulnerability appears in code generated by the Rexical gem versions v1.0.6 and earlier. Rexical is used by Nokogiri to generate lexical scanner code for parsing CSS queries. The underlying vulnerability was addressed in Rexical v1.0.7 and Nokogiri upgraded to this version of Rexical in Nokogiri v1.10.4.","modified":"2026-11-03T06:31:58.389370386Z","published":"2019-08-16T16:15:10.637Z","upstream":["CVE-2019-5477"],"references":[{"type":"ADVISORY","url":"https://security.alpinelinux.org/vuln/CVE-2019-5477"}],"affected":[{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.10","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.11","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.12","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.13","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.14","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.15","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.16","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.17","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.18","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.19","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.20","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.21","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.22","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.23","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}},{"package":{"name":"ruby-nokogiri","ecosystem":"Alpine:v3.24","purl":"pkg:apk/alpine/ruby-nokogiri?arch=source"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.10.4-r0"}]}],"ecosystem_specific":{},"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2019-5477.json"}}],"schema_version":"1.9.2","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"}]}