rapid7/metasploit-framework

View on GitHub
external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs

Summary

Maintainability
D
1 day
Test Coverage

File MainPage.xaml.cs has 384 lines of code (exceeds 250 allowed). Consider refactoring.
Open

using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.IO;
Severity: Minor
Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 5 hrs to fix

    Method MemoryDiscl has 59 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            ulong MemoryDiscl()
            {
                try
                {
                    // prepare malicious MemoryStream
    Severity: Major
    Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 2 hrs to fix

      Method Exec has 44 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

                  public override void Exec(int oldLen)
                  {
                      try {
                          // generate JIT-code for Payload()
                          Payload();
      Severity: Minor
      Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 1 hr to fix

        Method exploit has 33 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                void exploit()
                {
                    try
                    {
                        LogAdd("------------ START ------------");
        Severity: Minor
        Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 1 hr to fix

          Method MemoryDiscl has a Cognitive Complexity of 25 (exceeds 20 allowed). Consider refactoring.
          Open

                  ulong MemoryDiscl()
                  {
                      try
                      {
                          // prepare malicious MemoryStream
          Severity: Minor
          Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method Exec has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                      public virtual void Exec(int oldLen)
                      {
                          try {
                              // generate JIT-code for Payload()
                              Payload();
          Severity: Minor
          Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 1 hr to fix

            Method Exec has a Cognitive Complexity of 24 (exceeds 20 allowed). Consider refactoring.
            Open

                        public override void Exec(int oldLen)
                        {
                            try {
                                // generate JIT-code for Payload()
                                Payload();
            Severity: Minor
            Found in external/source/exploits/cve-2013-0074/SilverApp1/MainPage.xaml.cs - About 55 mins to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            There are no issues that match your filters.

            Category
            Status