Spectra Assure
Community
Docs
warningRisk: Hardening
Scanned: about 1 month ago

Microsoft.CodeCoverage

Microsoft.CodeCoverage package brings infra for collecting code coverage from vstest.console.exe and "dotnet test".
License: Permissive (MIT)
Published: 9 months ago


SAFE Assessment

Compliance

Licenses
No license compliance issues
Secrets
No sensitive information found

Security

Vulnerabilities
No known vulnerabilities detected
Hardening
3 execution hijacking concerns

Threats

Tampering
No evidence of software tampering
Malware
No evidence of malware inclusion

Popularity

1.3B
Total Downloads
Contributors
Declared Dependencies
36
Dependents

Top issues

Problem

Buffer overrun protection on Linux is achieved in two ways. The most common solution is to use the stack canary (also called cookie). The stack canary is a special value written onto the stack that allows the operating system to detect and terminate the program if a stack overrun occurs. In most cases, compilers will apply the stack canary conservatively in order to avoid a negative performance impact. Therefore, stack canaries are often used together with another stack overrun mitigation - fortified functions. Fortified functions are usually wrappers around standard glibc functions (such as memcpy) which perform boundary checks either at compile time or run time to determine if a memory violation has occurred. The compiler needs additional context to generate such calls (for example, array size that needs to be known at compile time). Because of this, the compiler will virtually never substitute all viable functions with their fortified counterparts in complex programs. However, when combined with the stack canary, fortified functions provide a good measure of buffer overrun protection.

Prevalence in NuGet community

0 packages
found in
Top 100
1 packages
found in
Top 1k
17 packages
found in
Top 10k
2228 packages
in community

Next steps

Presence of unfortified string functions may indicate use of unsafe programming practices, and you should avoid it if possible.
In GCC, enable fortified functions with -fstack-protector and -D_FORTIFY_SOURCE=2 flag, while using at least -O1 optimization level.

Problem

Buffer overrun protection on Linux is achieved in two ways. The most common solution is to use the stack canary (also called cookie). The stack canary is a special value written onto the stack that allows the operating system to detect and terminate the program if a stack overrun occurs. In most cases, compilers will apply the stack canary conservatively in order to avoid a negative performance impact. Therefore, stack canaries are often used together with another stack overrun mitigation - fortified functions. Fortified functions are usually wrappers around standard glibc functions (such as memcpy) which perform boundary checks either at compile time or run time to determine if a memory violation has occurred. The compiler needs additional context to generate such calls (for example, array size that needs to be known at compile time). Because of this, the compiler will virtually never substitute all viable functions with their fortified counterparts in complex programs. However, when combined with the stack canary, fortified functions provide a good measure of buffer overrun protection.

Prevalence in NuGet community

0 packages
found in
Top 100
1 packages
found in
Top 1k
19 packages
found in
Top 10k
2641 packages
in community

Next steps

Presence of unfortified memory functions may indicate use of unsafe programming practices, and you should avoid it if possible.
In GCC, enable fortified functions with -fstack-protector and -D_FORTIFY_SOURCE=2 flag, while using at least -O1 optimization level.

Problem

Buffer overrun protection on Linux is achieved in two ways. The most common solution is to use the stack canary (also called cookie). The stack canary is a special value written onto the stack that allows the operating system to detect and terminate the program if a stack overrun occurs. In most cases, compilers will apply the stack canary conservatively in order to avoid a negative performance impact. Therefore, stack canaries are often used together with another stack overrun mitigation - fortified functions. Fortified functions are usually wrappers around standard glibc functions (such as memcpy) which perform boundary checks either at compile time or run time to determine if a memory violation has occurred. The compiler needs additional context to generate such calls (for example, array size that needs to be known at compile time). Because of this, the compiler will virtually never substitute all viable functions with their fortified counterparts in complex programs. However, when combined with the stack canary, fortified functions provide a good measure of buffer overrun protection.

Prevalence in NuGet community

0 packages
found in
Top 100
1 packages
found in
Top 1k
19 packages
found in
Top 10k
2224 packages
in community

Next steps

Presence of some input functions may indicate use of unsafe programming practices, and you should avoid it if possible.
In GCC, enable fortified functions with -fstack-protector and -D_FORTIFY_SOURCE=2 flag, while using at least -O1 optimization level.

Problem

Software components contain executable code that performs actions implemented during its development. These actions are called behaviors. In the analysis report, behaviors are presented as human-readable descriptions that best match the underlying code intent. While most behaviors are benign, some are commonly abused by malicious software with the intent to cause harm. When a software package shares behavior traits with malicious software, it may become flagged by security solutions. Any detection from security solutions can cause friction for the end-users during software deployment. While the behavior is likely intended by the developer, there is a small chance this detection is true positive, and an early indication of a software supply chain attack.

Prevalence in NuGet community

0 packages
found in
Top 100
0 packages
found in
Top 1k
4 packages
found in
Top 10k
1095 packages
in community

Next steps

Investigate reported detections.
If the software intent does not relate to the reported behavior, investigate your build and release environment for software supply chain compromise.
You should delay the software release until the investigation is completed, or until the issue is risk accepted.
Consider rewriting the flagged code without using the marked behaviors.

Problem

Control Flow Guard (CFG/CFI) protects the code flow integrity by ensuring that dynamic calls are made only to vetted functions. Trusted execution paths rely on the ability of the operating system to build a list of valid function targets. Certain functions can intentionally be disallowed to prevent malicious code from deactivating vulnerability mitigation features. A list of such invalid function targets can include publicly exported symbols. Applications that enhance control flow integrity through export suppression rely on libraries to mark their publicly visible symbols as suppressed. This is done for all symbols that are considered to be sensitive functions, and to which access should be restricted. It is considered dangerous to mix applications that perform export suppression with libraries that do not.

Prevalence in NuGet community

0 packages
found in
Top 100
1 packages
found in
Top 1k
49 packages
found in
Top 10k
15484 packages
in community

Next steps

To enable this mitigation on library code, refer to your programming language toolchain documentation.
In Microsoft VisualStudio, you can enable CFG mitigation by passing the /guard:cf parameter to the compiler and linker.

Top behaviors

Prevalence in NuGet community

Behavior uncommon for this community (Uncommon)
0 packages
found in
Top 100
1 packages
found in
Top 1k
26 packages
found in
Top 10k
6500 packages
in community

Prevalence in NuGet community

Behavior uncommon for this community (Uncommon)
0 packages
found in
Top 100
1 packages
found in
Top 1k
24 packages
found in
Top 10k
6811 packages
in community

Prevalence in NuGet community

Behavior uncommon for this community (Uncommon)
0 packages
found in
Top 100
0 packages
found in
Top 1k
5 packages
found in
Top 10k
142 packages
in community

Prevalence in NuGet community

Behavior commonly used by malicious software (Important)
Behavior uncommon for this community (Uncommon)
0 packages
found in
Top 100
0 packages
found in
Top 1k
8 packages
found in
Top 10k
1061 packages
in community

Prevalence in NuGet community

Behavior uncommon for this community (Uncommon)
0 packages
found in
Top 100
1 packages
found in
Top 1k
23 packages
found in
Top 10k
3075 packages
in community

Top vulnerabilities

No vulnerabilities found.

This website uses cookies to ensure the best website experience. By continuing to use this website you are giving your consent to cookies being used. Detailed information about our use of cookies is here.