Skip to content

fix: DLL hijacking vulnerability in c2patool (CAI-8608)#2031

Open
scouten-adobe wants to merge 3 commits into
mainfrom
CAI-8608/dll-hijacking-vuln
Open

fix: DLL hijacking vulnerability in c2patool (CAI-8608)#2031
scouten-adobe wants to merge 3 commits into
mainfrom
CAI-8608/dll-hijacking-vuln

Conversation

@scouten-adobe
Copy link
Copy Markdown
Collaborator

No description provided.

@scouten-adobe scouten-adobe requested a review from gpeacock April 9, 2026 22:30
@scouten-adobe scouten-adobe self-assigned this Apr 9, 2026
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq Bot commented Apr 9, 2026

Merging this PR will not alter performance

✅ 32 untouched benchmarks
⏩ 2 skipped benchmarks1


Comparing CAI-8608/dll-hijacking-vuln (cfef630) with main (1982f5e)

Open in CodSpeed

Footnotes

  1. 2 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 9, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.70%. Comparing base (1982f5e) to head (cfef630).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2031   +/-   ##
=======================================
  Coverage   77.70%   77.70%           
=======================================
  Files         176      176           
  Lines       44645    44645           
=======================================
  Hits        34691    34691           
  Misses       9954     9954           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread cli/src/main.rs Outdated
#[cfg(windows)]
// SAFETY: no invariants to uphold; the argument is a valid constant.
unsafe {
windows_sys::Win32::System::LibraryLoader::SetDefaultDllDirectories(
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://learn.microsoft.com/en-us/windows/win32/api/libloaderapi/nf-libloaderapi-setdefaultdlldirectories

SetDefaultDllDirectories has a return value, a bool indicating success. Shouldn't the result of this call be checked then?

Should not fail, but while hardening...

…ediately with an error rather than silently continuing with an insecure DLL search path
@scouten-adobe scouten-adobe requested a review from tmathern April 10, 2026 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants