rapid7/metasploit-framework

View on GitHub
external/source/exploits/CVE-2020-17136/POC_CloudFilter_ArbitraryFile_EoP/Program.cs

Summary

Maintainability
D
2 days
Test Coverage

File Program.cs has 559 lines of code (exceeds 250 allowed). Consider refactoring.
Open

using System;
using System.IO;
using System.Runtime.InteropServices;
using System.Text;

    Method Main has 73 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            static void Main(string[] args)
            {
                try
                {
                    if (!Environment.Is64BitProcess)

      Method DoTransferCallback has 35 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              static void DoTransferCallback(in CF_CALLBACK_INFO CallbackInfo, IntPtr CallbackParameters)
              {
                  var ps = Marshal.PtrToStructure<CF_CALLBACK_PARAMETERS_FETCH_DATA>(CallbackParameters);
                  Console.WriteLine("{0} {1}", CallbackInfo, ps);
      

        Method CfConvertToPlaceholder has 6 arguments (exceeds 4 allowed). Consider refactoring.
        Open

                    SafeHandle FileHandle,
                    IntPtr FileIdentity,
                    int FileIdentityLength,
                    CF_CONVERT_FLAGS ConvertFlags,
                    out long ConvertUsn,

          Method CfCreatePlaceholders has 5 arguments (exceeds 4 allowed). Consider refactoring.
          Open

                      string BaseDirectoryPath,
                      [In, Out, MarshalAs(UnmanagedType.LPArray)] CF_PLACEHOLDER_CREATE_INFO[] PlaceholderArray,
                      int PlaceholderCount,
                      CF_CREATE_FLAGS CreateFlags,
                      out int EntriesProcessed

            Method CfHydratePlaceholder has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                        SafeHandle FileHandle,
                        LargeIntegerStruct StartingOffset,
                        LargeIntegerStruct Length,
                        CF_HYDRATE_FLAGS HydrateFlags,
                        IntPtr Overlapped

              Method CfConnectSyncRoot has 5 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                          string SyncRootPath,
                          [MarshalAs(UnmanagedType.LPArray), In] CF_CALLBACK_REGISTRATION[] CallbackTable,
                          IntPtr CallbackContext,
                          CF_CONNECT_FLAGS ConnectFlags,
                          out long ConnectionKey

                There are no issues that match your filters.

                Category
                Status