{"id":"CVE-2024-42381","aliases":["EUVD-2024-39586","GHSA-phm2-c5jj-q34c"],"status":"published","title":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted...","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","severity":{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AC:H/AV:N/A:H/C:H/I:H/PR:N/S:C/UI:R","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-11","score":0.00647,"percentile":0.51478,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":false},"cwes":["CWE-830"],"published":"2024-07-31T00:00:00Z","modified":"2026-10-28T02:30:31Z","products":[{"vendor":"homebrew","product":"brew"}],"references":[{"url":"https://github.com/Homebrew/brew/tree/237d1e783f7ee261beaba7d3f6bde22da7148b0a","tags":["web"]},{"url":"https://github.com/trailofbits/publications/blob/master/reviews/2023-08-28-homebrew-securityreview.pdf","tags":["web"]},{"url":"https://blog.trailofbits.com/2024/07/30/our-audit-of-homebrew/","tags":["article"]},{"url":"https://brew.sh/2024/07/30/homebrew-security-audit/","tags":["web"]},{"url":"https://github.com/Homebrew/brew/commit/916b37388d3851a8a93a8e9b4adc38873680ead7","tags":["fix"]},{"url":"https://github.com/Homebrew/brew/releases/tag/4.2.20","tags":["web"]},{"url":"https://github.com/Homebrew/brew/pull/17136","tags":["fix"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-42381","tags":["advisory"]},{"url":"https://blog.trailofbits.com/2024/07/30/our-audit-of-homebrew"},{"url":"https://brew.sh/2024/07/30/homebrew-security-audit"},{"url":"https://github.com/advisories/GHSA-phm2-c5jj-q34c"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/42xxx/CVE-2024-42381.json","tags":["advisory"]}],"sources":{"cve":[{"id":"CVE-2024-42381","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","status":"published","published":"2024-07-31T00:00:00Z","modified":"2024-07-31T17:03:46.038Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AC:H/AV:N/A:H/C:H/I:H/PR:N/S:C/UI:R","level":"high","assessor":"cna"}],"cwes":["CWE-830"],"updated_at":"2026-11-02T14:34:03.00063Z"}],"euvd":[{"id":"EUVD-2024-39586","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","status":"published","published":"2024-07-31T00:00:00Z","modified":"2024-07-31T17:03:46Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AC:H/AV:N/A:H/C:H/I:H/PR:N/S:C/UI:R","level":"high"}],"updated_at":"2026-11-03T03:50:48.911719Z"}],"ghsa":[{"id":"GHSA-phm2-c5jj-q34c","title":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted...","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","status":"published","published":"2024-07-31T06:30:35Z","modified":"2024-08-01T15:33:24Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H","level":"high"}],"cwes":["CWE-830"],"updated_at":"2026-11-02T14:57:49.277059Z"}],"nvd":[{"id":"CVE-2024-42381","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","status":"published","published":"2024-07-31T06:15:02.13Z","modified":"2026-06-17T07:49:21.777Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H","level":"high","assessor":"secondary"}],"cwes":["CWE-830"],"updated_at":"2026-11-02T14:10:15.933769Z"}],"osv":[{"id":"CVE-2024-42381","description":"os/linux/elf.rb in Homebrew brew before 4.2.20 uses ldd to load ELF files obtained from untrusted sources, which allows attackers to achieve code execution via an ELF file with a custom .interp section. NOTE: this code execution would occur during an un-sandboxed binary relocation phase, which occurs before a user would expect execution of downloaded package content. (237d1e783f7ee261beaba7d3f6bde22da7148b0a was the tested vulnerable version.)","status":"published","published":"2024-07-31T00:00:00Z","modified":"2026-10-28T02:30:31.451248379Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AC:H/AV:N/A:H/C:H/I:H/PR:N/S:C/UI:R","level":"high"}],"updated_at":"2026-11-02T15:44:42.322107Z"}]}}
