microsoft / microsoft/ApplicationInspector

Reflection Detection

Open
#288 0 comments 2 reactions 2 assignees View on GitHub

@gfs is already working on this.

Since Feb 14, 2026.

rule
Dominant language
C#
Stars
4.4k
Forks
366
Avg merge
6d 7h
Merged PRs (30d)
3

Description

I'm not sure how exactly this applies to other languages but this is a particular issue in C#.

Using Reflection can allow for dynamic behavior at runtime, including dynamic access to APIs which are not discernable at static analysis time. Application Inspector should report when an app using reflection in a way that would allow such behavior.

If you want a project to test reflection rules against see OAT.

Proposal:

I don't think we want to overgrab here, so there are some things that seem okay.

Check the Version Number by reflecting the assembly information from a type.
Read an embedded file

And things that are less common that might be interesting:

Create an object using invoke/constructorinfo
Loading assemblies at runtime
Invoke a method (for example using invoke method)
etc.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.