Skip to content
This repository was archived by the owner on Nov 1, 2023. It is now read-only.

Conversation

@Porges
Copy link
Member

@Porges Porges commented Jul 23, 2023

When LibFuzzerDotNetLoader loads DLLs that have dependencies, they are not currently resolved correctly, as sibling DLLs in the same directory are not considered. In order to do this, we need to provide a custom AssemblyLoadContext. This PR does so, based on the dotnet core example code.

Validated with custom fuzzer implementation; we don't yet have a full test for this in check-pr.

Closes #3326.

@codecov-commenter
Copy link

codecov-commenter commented Jul 23, 2023

Codecov Report

Merging #3325 (60cd586) into main (2ecca70) will decrease coverage by 1.41%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #3325      +/-   ##
==========================================
- Coverage   31.80%   30.40%   -1.41%     
==========================================
  Files         307      133     -174     
  Lines       37334    14285   -23049     
==========================================
- Hits        11874     4343    -7531     
+ Misses      25460     9942   -15518     

see 174 files with indirect coverage changes

@Porges Porges marked this pull request as ready for review July 24, 2023 02:10
@Porges Porges changed the title Fix resolution of sibling .NET dlls Fix resolution of sibling .NET DLLs Jul 24, 2023
Copy link
Contributor

@mgreisen mgreisen left a comment

Choose a reason for hiding this comment

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

:shipit:

@Porges Porges enabled auto-merge (squash) July 24, 2023 21:10
@Porges Porges merged commit 33e645d into main Jul 24, 2023
@Porges Porges deleted the dotnet-resolution-fix branch July 24, 2023 21:26
@AdamL-Microsoft AdamL-Microsoft mentioned this pull request Jul 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Loading .NET DLL with dependencies fails

5 participants