{"id":"CVE-2026-107704","summary":"image_optimizer 1.3.0 through 1.9.0 OS Command Injection via identify_format","details":"The image_optimizer Ruby gem 1.3.0 through 1.9.0 contains an OS command injection vulnerability in ImageOptimizer#identify_format that allows attackers to execute commands by supplying a crafted image path when the identify option is enabled. Attackers controlling the path, such as an uploaded file name, can append shell metacharacters like ';' that are executed via Ruby backticks with the Ruby process privileges.","modified":"2026-10-11T02:30:59.648453560Z","published":"2026-10-08T18:36:37.394Z","database_specific":{"cwe_ids":["CWE-78"],"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/107xxx/CVE-2026-107704.json","cna_assigner":"VulnCheck"},"references":[{"type":"WEB","url":"https://rubygems.org/gems/image_optimizer"},{"type":"ADVISORY","url":"https://gist.github.com/R3tro16/a99a058d24a06692721a6a3fade9649d"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/107xxx/CVE-2026-107704.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-107704"},{"type":"ADVISORY","url":"https://www.vulncheck.com/advisories/image-optimizer-1.3.0-through-1.9.0-os-command-injection-via-identify-format"},{"type":"PACKAGE","url":"https://github.com/jtescher/image_optimizer"},{"type":"ARTICLE","url":"https://github.com/jtescher/image_optimizer/blob/v1.9.0/lib/image_optimizer.rb#L37-L47"},{"type":"ARTICLE","url":"https://github.com/jtescher/image_optimizer/blob/v1.9.0/lib/image_optimizer/shell.rb#L30-L32"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/jtescher/image_optimizer","events":[{"introduced":"185be837597be715637e9dab6b6ef8d1c47bcc01"},{"fixed":"07548c6499186e3bd100aae7026d6aead3902327"}],"database_specific":{"source":["AFFECTED_FIELD","DESCRIPTION"],"extracted_events":[{"introduced":"1.3.0"},{"last_affected":"1.9.0"},{"fixed":"1.9.0"}]}}],"versions":["v1.8.0","v1.7.2","v1.7.1","v1.7.0","v1.6.1","v1.6.0","v1.5.0","v1.4.0","v1.3.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-107704.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"}]}