I am trying to understand under which circumstances CVE-2024-38095 applies. When reading the advisory (https://github.com/dotnet/runtime/security/advisories/GHSA-447r-wph3-92pm), one finds the following statements:
- Affected software: Any .NET 8.0 application running on .NET 8.0.6 or earlier.
- The vulnerability affects any Microsoft .NET Core project if it uses any of affected packages versions listed below
- Affected Packages: System.Formats.Asn1 < 8.0.1 (shortened)
- If you have a runtime or SDK with a version listed, or an affected package listed in affected software or affected packages, you're exposed to the vulnerability.
- To fix the issue please install the latest version of .NET 8.0 or .NET 7.0 or .NET 6.0
These statements seem to contradict each other at least a bit. On the one hand, they say if using an old .Net SDK OR the package one is vulnerable, on the other hand the fix only suggests to update the SDK itself.
Why I am trying to understand is: Which combinations of the .Net SDK and System.Formats.Asn1 are vulnerable. For example, if I follow the suggested fix and use a .Ne SDK > 8.0.6, but my package.lock.json still shows that System.Formats.Asn1 8.0.0 is being used, is the application vulnerable?
EDIT: I realized that they use .Net when specifiying the vulnerable SDK, but use .Net Core when talking about vulnerable packages. Maybe thats where the difference lies, i. e. you are safe if you either use the .Net SDK OR If you use .Net Core and an up to date package version.
Thank you for your insights!