Giter Club home page Giter Club logo

sharpsploit's Introduction

SharpSploit

SharpSploit is a .NET post-exploitation library written in C# that aims to highlight the attack surface of .NET and make the use of offensive .NET easier for red teamers.

SharpSploit is named, in part, as a homage to the PowerSploit project, a personal favorite of mine! While SharpSploit does port over some functionality from PowerSploit, my intention is not at all to create a direct port of PowerSploit. SharpSploit will be it's own project, albeit with similar goals to PowerSploit.

Intro

You'll find some details and motivations for the SharpSploit project in this introductory blog post.

Documentation

The complete SharpSploit API docfx documentation is available here.

For an easier to read, high-level quick reference and summary of SharpSploit functionality, refer to the SharpSploit - Quick Command Reference.

Credits

I owe a ton of credit to a lot of people. Nearly none of SharpSploit is truly original work. SharpSploit ports many modules written in PowerShell by others, utilizes techniques discovered by others, and borrows ideas and code from other C# projects as well. With that being said, I'd like to thank the following people for contributing to the project (whether they know they did or not :)):

sharpsploit's People

Contributors

001spartan avatar attl4s avatar aus avatar awsmhacks avatar checkymander avatar cobbr avatar daddycocoaman avatar drdinosaur avatar fuzzysecurity avatar panagioto avatar rasta-mouse avatar salu90 avatar shellfarmer avatar thewover avatar tocohot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sharpsploit's Issues

BypassUAC doesnt spawn a process

The BypassUAC Method doesnt spawns the specfied the Process and only show Access Denied when calling CreateProcesswithLogonW both normal und running as an Administrator

The same with the GetSystem Method
image

What im doing Wrong here or i am correctly using it?

windows version:
image

and using Visual Studio 2019 and the latest Version of Sharpsploit

InvalidArgument4 Error in NtFreeVirtualMemory Routine

When calling SharpSploit.Execution.DynamicInvoke.Generic.GetSyscallStub() the call to NtFreeVirtualMemory returns an NTSTATUS = STATUS_INVALID_PARAMETER_4 (0xC00000F2).

I was attempting to call "NtAllocateVirtualMemory" this way:

IntPtr pSyscall = SharpSploit.Execution.DynamicInvoke.Generic.GetSyscallStub("NtAllocateVirtualMemory");

This eventually causes this function to be called:

Native.NtFreeVirtualMemory((IntPtr)(-1), ref pImage, ref RegionSize, Execute.Win32.Kernel32.AllocationType.Reserve);

The error that was being returned was the catch-all error in Native.cs:

if (retValue != Execute.Native.NTSTATUS.Success) { // STATUS_OBJECT_TYPE_MISMATCH == 0xC0000024 throw new InvalidOperationException("There is a mismatch between the type of object that is required by the requested operation and the type of object that is specified in the request."); }

Calling this code path, there is nothing that I can do to influence the variable type being used for the call to NtFreeVirtualMemory. I was able to add in an extra condition to get it to ignore the error as a work-around. It seems to not like the "Execute.Win32.Kernel32.AllocationType" being passed?

Shell doesn't provide data written to the standard error stream

Currently, ShellExecuteWithPath only returns the standard output.

Should it also return the standard error by adding the lines that went to the standard error stream to one output string (that contains the data of both streams) in chronological order?

I don't know how common writing to standard error is and the operator may just care about standard output, so I consider this more of a design choice rather than a bug.

If you think standard error should be added, I can make a PR.

Build SharpSploit DLL from Linux

Context

One may not want to install a Windows VM + install Visual Studio just to build a tool. So I tried to build SharpSploit DLL with Mono, MSBuild, .NET SDk, and NuGet on Linux.

Prerequisites

On ArchLinux:

$ pacman -S mono-msbuild dotnet-sdk nuget
$ pikaur -S mono-git

Version

  • mono 6.13.0
  • msbuild 16.10.1.xamarinxplat.2021.05.26.14.00
  • dotnet sdk 6.0.0.sdk100
  • nuget 5.10.0

Build steps

$ git clone https://github.com/cobbr/SharpSploit
$ cd SharpSploit
$ nuget restore
$ msbuild SharpSploit.sln
Microsoft (R) Build Engine version 16.10.1 for Mono
Copyright (C) Microsoft Corporation. All rights reserved.

Building the projects in this solution one at a time. To enable parallel build, please add the "-m" switch.
Build started 12/22/2021 5:45:09 PM.
Project "/tmp/SharpSploit/SharpSploit.sln" on node 1 (default targets).
ValidateSolutionConfiguration:
  Building solution configuration "Debug|Any CPU".
Project "/tmp/SharpSploit/SharpSploit.sln" (1) is building "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (2) on node 1 (default targets).
Project "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (2) is building "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (2:2) on node 1 (Build target(s)).
GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
CoreGenerateAssemblyInfo:
Skipping target "CoreGenerateAssemblyInfo" because all output files are up-to-date with respect to the input files.
CoreCompile:
  /usr/lib/mono/msbuild/Current/bin/Roslyn/csc.exe /noconfig /unsafe- /checked- /nowarn:1701,1702,1591,1701,1702 /fullpaths /nostdlib+ /platform:AnyCPU /errorreport:prompt /warn:4 /doc:./SharpSploit.xml /define:TRACE;DEBUG;NETFRAMEWORK;NET40 /highentropyva- /reference:/tmp/SharpSploit/SharpSploit/References/net40/mscorlib.dll /reference:/usr/lib/mono/4.0-api/System.Core.dll /reference:/usr/lib/mono/4.0-api/System.Data.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.DirectoryServices.dll /reference:/usr/lib/mono/4.0-api/System.DirectoryServices.Protocols.dll /reference:/usr/lib/mono/4.0-api/System.dll /reference:/usr/lib/mono/4.0-api/System.Drawing.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.IdentityModel.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.Management.Automation.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.Management.dll /reference:/usr/lib/mono/4.0-api/System.Numerics.dll /reference:/usr/lib/mono/4.0-api/System.Runtime.Serialization.dll /reference:/usr/lib/mono/4.0-api/System.ServiceProcess.dll /reference:/usr/lib/mono/4.0-api/System.Windows.Forms.dll /reference:/usr/lib/mono/4.0-api/System.Xml.dll /reference:/usr/lib/mono/4.0-api/System.Xml.Linq.dll /debug+ /debug:portable /filealign:512 /optimize- /out:obj/Debug/net40/SharpSploit.dll /resource:Resources/powerkatz_x86.dll,SharpSploit.Resources.powerkatz_x86.dll /resource:Resources/powerkatz_x64.dll,SharpSploit.Resources.powerkatz_x64.dll /target:library /warnaserror- /utf8output /deterministic+ /langversion:7.3 Credentials/Mimikatz.cs Credentials/Tokens.cs Enumeration/Clipboard.cs Enumeration/Domain.cs Enumeration/GPO.cs Enumeration/Host.cs Enumeration/Keylogger.cs Enumeration/Network.cs Enumeration/Registry.cs Evasion/Amsi.cs Evasion/ETW.cs Execution/Assembly.cs Execution/DynamicInvoke/Generic.cs Execution/DynamicInvoke/Native.cs Execution/DynamicInvoke/Win32.cs Execution/Injection/AllocationTechnique.cs Execution/Injection/ExecutionTechnique.cs Execution/Injection/Injector.cs Execution/Injection/PayloadType.cs Execution/Injection/SectionMapAllocationTechnique.cs Execution/Injection/VirtualAllocAllocationTechnique.cs Execution/ManualMap/Map.cs Execution/ManualMap/Overload.cs Execution/ManualMap/PE.cs Execution/Native.cs Execution/PlatformInvoke/Native.cs Execution/PlatformInvoke/Win32.cs Execution/Shell.cs Execution/ShellCode.cs Execution/Win32.cs Generic/Generic.cs LateralMovement/DCOM.cs LateralMovement/PowerShellRemoting.cs LateralMovement/SCM.cs LateralMovement/WMI.cs Misc/CountdownEvent.cs Misc/Utilities.cs Persistence/Autorun.cs Persistence/COM.cs Persistence/Startup.cs Persistence/WMI.cs Pivoting/ReversePortForwarding.cs PrivilegeEscalation/Exchange.cs "obj/Debug/net40/.NETFramework,Version=v4.0.AssemblyAttributes.cs" obj/Debug/net40/SharpSploit.AssemblyInfo.cs /warnaserror+:NU1605
  Using shared compilation with compiler from directory: /usr/lib/mono/msbuild/Current/bin/Roslyn
/tmp/SharpSploit/SharpSploit/Evasion/ETW.cs(21,36): warning CS1570: XML comment has badly formed XML -- 'Whitespace is not allowed at this location.' [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
/tmp/SharpSploit/SharpSploit/Execution/Shell.cs(52,68): error CS0234: The type or namespace name 'Eventing' does not exist in the namespace 'System.Diagnostics' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
/tmp/SharpSploit/SharpSploit/Execution/DynamicInvoke/Generic.cs(191,18): warning CS0219: The variable 'Is32Bit' is assigned but its value is never used [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
CSC : warning CS1685: The predefined type 'ExtensionAttribute' is defined in multiple assemblies in the global alias; using definition from 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
Done Building Project "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target(s)) -- FAILED.
Project "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (2) is building "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (2:3) on node 1 (Build target(s)).
CoreGenerateAssemblyInfo:
Skipping target "CoreGenerateAssemblyInfo" because all output files are up-to-date with respect to the input files.
CoreCompile:
  /usr/lib/mono/msbuild/Current/bin/Roslyn/csc.exe /noconfig /unsafe- /checked- /nowarn:1701,1702,1701,1702 /fullpaths /nostdlib+ /errorreport:prompt /warn:4 /define:TRACE;DEBUG;NETFRAMEWORK;NET35 /highentropyva- /reference:/tmp/SharpSploit/SharpSploit/References/net35/mscorlib.dll /reference:/usr/lib/mono/2.0-api/System.Core.dll /reference:/usr/lib/mono/2.0-api/System.Data.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.DirectoryServices.dll /reference:/usr/lib/mono/2.0-api/System.DirectoryServices.Protocols.dll /reference:/usr/lib/mono/2.0-api/System.dll /reference:/usr/lib/mono/2.0-api/System.Drawing.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.IdentityModel.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.Management.Automation.dll /reference:/tmp/SharpSploit/SharpSploit/References/net35/System.Management.dll /reference:/usr/lib/mono/2.0-api/System.Runtime.Serialization.dll /reference:/usr/lib/mono/2.0-api/System.ServiceProcess.dll /reference:/usr/lib/mono/2.0-api/System.Windows.Forms.dll /reference:/usr/lib/mono/2.0-api/System.Xml.dll /reference:/usr/lib/mono/2.0-api/System.Xml.Linq.dll /debug+ /debug:portable /filealign:512 /optimize- /out:obj/Debug/net35/SharpSploit.dll /resource:Resources/powerkatz_x86.dll,SharpSploit.Resources.powerkatz_x86.dll /resource:Resources/powerkatz_x64.dll,SharpSploit.Resources.powerkatz_x64.dll /target:library /warnaserror- /utf8output /deterministic+ /langversion:7.3 Credentials/Mimikatz.cs Credentials/Tokens.cs Enumeration/Clipboard.cs Enumeration/Domain.cs Enumeration/GPO.cs Enumeration/Host.cs Enumeration/Keylogger.cs Enumeration/Network.cs Enumeration/Registry.cs Evasion/Amsi.cs Evasion/ETW.cs Execution/Assembly.cs Execution/DynamicInvoke/Generic.cs Execution/DynamicInvoke/Native.cs Execution/DynamicInvoke/Win32.cs Execution/Injection/AllocationTechnique.cs Execution/Injection/ExecutionTechnique.cs Execution/Injection/Injector.cs Execution/Injection/PayloadType.cs Execution/Injection/SectionMapAllocationTechnique.cs Execution/Injection/VirtualAllocAllocationTechnique.cs Execution/ManualMap/Map.cs Execution/ManualMap/Overload.cs Execution/ManualMap/PE.cs Execution/Native.cs Execution/PlatformInvoke/Native.cs Execution/PlatformInvoke/Win32.cs Execution/Shell.cs Execution/ShellCode.cs Execution/Win32.cs Generic/Generic.cs LateralMovement/DCOM.cs LateralMovement/PowerShellRemoting.cs LateralMovement/SCM.cs LateralMovement/WMI.cs Misc/CountdownEvent.cs Misc/Utilities.cs Persistence/Autorun.cs Persistence/COM.cs Persistence/Startup.cs Persistence/WMI.cs Pivoting/ReversePortForwarding.cs PrivilegeEscalation/Exchange.cs obj/Debug/net35/SharpSploit.AssemblyInfo.cs /warnaserror+:NU1605
  Using shared compilation with compiler from directory: /usr/lib/mono/msbuild/Current/bin/Roslyn
/tmp/SharpSploit/SharpSploit/Execution/Shell.cs(52,68): error CS0234: The type or namespace name 'Eventing' does not exist in the namespace 'System.Diagnostics' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
/tmp/SharpSploit/SharpSploit/Execution/DynamicInvoke/Generic.cs(191,18): warning CS0219: The variable 'Is32Bit' is assigned but its value is never used [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
Done Building Project "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target(s)) -- FAILED.
Done Building Project "/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (default targets) -- FAILED.
Project "/tmp/SharpSploit/SharpSploit.sln" (1) is building "/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj" (3) on node 1 (default targets).
ResolveAssemblyReferences:
  Primary reference "SharpSploit".
/usr/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "SharpSploit". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
          For SearchPath "/Common Files/microsoft shared/VSTT/16.0/UITestExtensionPackages".
          Considered "/Common Files/microsoft shared/VSTT/16.0/UITestExtensionPackages/SharpSploit.winmd", but it didn't exist.
          Considered "/Common Files/microsoft shared/VSTT/16.0/UITestExtensionPackages/SharpSploit.dll", but it didn't exist.
          Considered "/Common Files/microsoft shared/VSTT/16.0/UITestExtensionPackages/SharpSploit.exe", but it didn't exist.
          For SearchPath "{HintPathFromItem}".
          Considered "/tmp/SharpSploit/SharpSploit/bin/Debug/net40/SharpSploit.dll", but it didn't exist.
          For SearchPath "{TargetFrameworkDirectory}".
          Considered "/usr/lib/mono/xbuild-frameworks/.NETFramework/v4.5/SharpSploit.winmd", but it didn't exist.
          Considered "/usr/lib/mono/xbuild-frameworks/.NETFramework/v4.5/SharpSploit.dll", but it didn't exist.
          Considered "/usr/lib/mono/xbuild-frameworks/.NETFramework/v4.5/SharpSploit.exe", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/SharpSploit.winmd", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/SharpSploit.dll", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/SharpSploit.exe", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.winmd", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.dll", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.exe", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.winmd", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.dll", but it didn't exist.
          Considered "/usr/lib/mono/4.5-api/Facades/SharpSploit.exe", but it didn't exist.
          For SearchPath "{GAC}".
          Considered "SharpSploit", which was not found in the GAC.
          For SearchPath "{RawFileName}".
          Considered treating "SharpSploit, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL" as a file name, but it didn't exist.
          For SearchPath "bin/Debug/".
          Considered "bin/Debug/SharpSploit.winmd", but it didn't exist.
          Considered "bin/Debug/SharpSploit.dll", but it didn't exist.
          Considered "bin/Debug/SharpSploit.exe", but it didn't exist.
GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
CoreCompile:
  /usr/lib/mono/msbuild/Current/bin/Roslyn/csc.exe /noconfig /nowarn:1701,1702 /fullpaths /nostdlib+ /errorreport:prompt /warn:4 /define:DEBUG;TRACE /highentropyva+ /reference:/tmp/SharpSploit/packages/MSTest.TestFramework.1.3.1/lib/net45/Microsoft.VisualStudio.TestPlatform.TestFramework.dll /reference:/tmp/SharpSploit/packages/MSTest.TestFramework.1.3.1/lib/net45/Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll /reference:/usr/lib/mono/4.5-api/mscorlib.dll /reference:/usr/lib/mono/4.5-api/System.Core.dll /reference:/usr/lib/mono/4.5-api/System.DirectoryServices.dll /reference:/usr/lib/mono/4.5-api/System.dll /reference:/usr/lib/mono/4.5-api/System.ServiceProcess.dll /reference:/usr/lib/mono/4.5-api/System.Windows.Forms.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Collections.Concurrent.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Collections.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ComponentModel.Annotations.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ComponentModel.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ComponentModel.EventBasedAsync.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Diagnostics.Contracts.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Diagnostics.Debug.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Diagnostics.Tools.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Diagnostics.Tracing.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Dynamic.Runtime.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Globalization.dll /reference:/usr/lib/mono/4.5-api/Facades/System.IO.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Linq.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Linq.Expressions.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Linq.Parallel.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Linq.Queryable.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Net.NetworkInformation.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Net.Primitives.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Net.Requests.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ObjectModel.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.Emit.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.Emit.ILGeneration.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.Emit.Lightweight.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.Extensions.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Reflection.Primitives.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Resources.ResourceManager.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.Extensions.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.InteropServices.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.InteropServices.WindowsRuntime.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.Numerics.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.Serialization.Json.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.Serialization.Primitives.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Runtime.Serialization.Xml.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Security.Principal.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ServiceModel.Duplex.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ServiceModel.Http.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ServiceModel.NetTcp.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ServiceModel.Primitives.dll /reference:/usr/lib/mono/4.5-api/Facades/System.ServiceModel.Security.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Text.Encoding.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Text.Encoding.Extensions.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Text.RegularExpressions.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Threading.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Threading.Tasks.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Threading.Tasks.Parallel.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Xml.ReaderWriter.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Xml.XDocument.dll /reference:/usr/lib/mono/4.5-api/Facades/System.Xml.XmlSerializer.dll /debug+ /debug:full /filealign:512 /optimize- /out:obj/Debug/SharpSploit.Framework.Tests.dll /subsystemversion:6.00 /target:library /utf8output /langversion:7.3 Credentials/TokensTests.cs Enumeration/ClipboardTests.cs Enumeration/DomainTests.cs Enumeration/HostTests.cs Enumeration/NetworkTests.cs Enumeration/RegistryTests.cs Enumeration/KeyloggerTests.cs Evasion/AmsiTests.cs Evasion/ETWTests.cs Execution/Injection/InjectionTests.cs Execution/ManualMap/MapTests.cs Execution/ShellCodeTests.cs Execution/ShellTests.cs LateralMovement/DCOMTests.cs LateralMovement/PowerShellRemotingTests.cs LateralMovement/SCMTests.cs LateralMovement/WMITests.cs Persistence/AutorunTests.cs Pivoting/ReversePortForwardingTests.cs Persistence/StartupTests.cs Persistence/WMITests.cs Properties/AssemblyInfo.cs "obj/Debug/.NETFramework,Version=v4.5.AssemblyAttributes.cs"
  Using shared compilation with compiler from directory: /usr/lib/mono/msbuild/Current/bin/Roslyn
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Credentials/TokensTests.cs(11,19): error CS0234: The type or namespace name 'Credentials' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/ClipboardTests.cs(9,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/DomainTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/HostTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/HostTests.cs(11,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/NetworkTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/NetworkTests.cs(11,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/RegistryTests.cs(7,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/KeyloggerTests.cs(13,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/KeyloggerTests.cs(14,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Evasion/AmsiTests.cs(7,19): error CS0234: The type or namespace name 'Evasion' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Evasion/ETWTests.cs(7,19): error CS0234: The type or namespace name 'Evasion' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(6,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(7,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(8,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ManualMap/MapTests.cs(8,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellCodeTests.cs(4,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellTests.cs(11,29): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellTests.cs(10,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/DCOMTests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/PowerShellRemotingTests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/SCMTests.cs(10,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/WMITests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/AutorunTests.cs(9,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/AutorunTests.cs(10,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Pivoting/ReversePortForwardingTests.cs(10,19): error CS0234: The type or namespace name 'Pivoting' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/StartupTests.cs(9,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/WMITests.cs(10,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
Done Building Project "/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj" (default targets) -- FAILED.
Done Building Project "/tmp/SharpSploit/SharpSploit.sln" (default targets) -- FAILED.

Build FAILED.

"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (default target) (2) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target) (2:2) ->
(CoreCompile target) ->
  /tmp/SharpSploit/SharpSploit/Evasion/ETW.cs(21,36): warning CS1570: XML comment has badly formed XML -- 'Whitespace is not allowed at this location.' [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
  /tmp/SharpSploit/SharpSploit/Execution/DynamicInvoke/Generic.cs(191,18): warning CS0219: The variable 'Is32Bit' is assigned but its value is never used [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]
  CSC : warning CS1685: The predefined type 'ExtensionAttribute' is defined in multiple assemblies in the global alias; using definition from 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]


"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (default target) (2) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target) (2:3) ->
  /tmp/SharpSploit/SharpSploit/Execution/DynamicInvoke/Generic.cs(191,18): warning CS0219: The variable 'Is32Bit' is assigned but its value is never used [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]


"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj" (default target) (3) ->
(ResolveAssemblyReferences target) ->
  /usr/lib/mono/msbuild/Current/bin/Microsoft.Common.CurrentVersion.targets(2218,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "SharpSploit". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]


"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (default target) (2) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target) (2:2) ->
(CoreCompile target) ->
  /tmp/SharpSploit/SharpSploit/Execution/Shell.cs(52,68): error CS0234: The type or namespace name 'Eventing' does not exist in the namespace 'System.Diagnostics' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]


"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (default target) (2) ->
"/tmp/SharpSploit/SharpSploit/SharpSploit.csproj" (Build target) (2:3) ->
  /tmp/SharpSploit/SharpSploit/Execution/Shell.cs(52,68): error CS0234: The type or namespace name 'Eventing' does not exist in the namespace 'System.Diagnostics' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit/SharpSploit.csproj]


"/tmp/SharpSploit/SharpSploit.sln" (default target) (1) ->
"/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj" (default target) (3) ->
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Credentials/TokensTests.cs(11,19): error CS0234: The type or namespace name 'Credentials' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/ClipboardTests.cs(9,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/DomainTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/HostTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/HostTests.cs(11,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/NetworkTests.cs(10,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/NetworkTests.cs(11,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/RegistryTests.cs(7,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/KeyloggerTests.cs(13,19): error CS0234: The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Enumeration/KeyloggerTests.cs(14,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Evasion/AmsiTests.cs(7,19): error CS0234: The type or namespace name 'Evasion' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Evasion/ETWTests.cs(7,19): error CS0234: The type or namespace name 'Evasion' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(6,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(7,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/Injection/InjectionTests.cs(8,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ManualMap/MapTests.cs(8,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellCodeTests.cs(4,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellTests.cs(11,29): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Execution/ShellTests.cs(10,19): error CS0234: The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/DCOMTests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/PowerShellRemotingTests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/SCMTests.cs(10,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/LateralMovement/WMITests.cs(7,19): error CS0234: The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/AutorunTests.cs(9,19): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/AutorunTests.cs(10,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Pivoting/ReversePortForwardingTests.cs(10,19): error CS0234: The type or namespace name 'Pivoting' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/StartupTests.cs(9,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]
  /tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/Persistence/WMITests.cs(10,19): error CS0234: The type or namespace name 'Persistence' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) [/tmp/SharpSploit/SharpSploit.Tests/SharpSploit.Tests/SharpSploit.Tests.csproj]

    5 Warning(s)
    30 Error(s)

Time Elapsed 00:00:03.23

Question

How to build SharpSploit DLL from Linux?

Attempting to manually map ntdll.dll leads to a FileNotFoundException in RewriteModuleIAT

Console.WriteLine("[?] Manually map a fresh copy of a DLL (\"ntdll.dll\"), and resolve a function by walking the export table in-memory...");
SharpSploit.Execution.PE.PE_MANUAL_MAP moduleDetails = SharpSploit.Execution.ManualMap.Map.MapModuleToMemory("C:\\Windows\\System32\\ntdll.dll");
Console.WriteLine("[>] Module Base : " + string.Format("{0:X}", moduleDetails.ModuleBase.ToInt64()) + "\n");

Traceback:

Unhandled Exception: System.IO.FileNotFoundException: IIIIIIIIIIIIIIIII?9�L<Éu:�·I�E3Of.Éx4H.OA<AH�EAI%,_ÿ, unable to find the specified file.
   at SharpSploit.Execution.ManualMap.Map.RewriteModuleIAT(PE_META_DATA PEINFO, IntPtr ModuleMemoryBase)
   at SharpSploit.Execution.ManualMap.Map.MapModuleToMemory(IntPtr pModule, IntPtr pImage, PE_META_DATA PEINFO)
   at SharpSploit.Execution.ManualMap.Map.MapModuleToMemory(IntPtr pModule)
   at BaseLibraryMapper.Program.Main(String[] args) in D:\repos\BaseLibraryMapper\Program.cs:line 16

SharpSploit.Execution.PE fix

@cobbr

Do you have any view on when the SharpSploit.Execution.PE.Load() method will be fixed? Or could you or someone else provide some hints on where the issue currently is?

I honestly am not that super expert in WIN32 API's but with some hints on where the current issue is, I could at least try to hunt for a fix.

Just spent the whole afternoon in looking for a currently working option to execute PE files reflective from a C# assembly, but there seems to be no working solution. The peloader.cs which is also based on the work from subtee is also not working..

https://github.com/Arno0x/CSharpScripts/blob/master/peloader.cs

RewriteModuleIAT throws FileNotFoundException

I'm trying to implement Mimikatz into my C2 project via Module Overloading, as follows:

var pe = Overload.OverloadModule(katz, DecoyModulePath: @"C:\Windows\System32\VsGraphicsHelper.dll", LegitSigned: true);

output = (string) Generic.CallMappedDLLModuleExport(pe.PEINFO, pe.ModuleBase, "powershell_reflective_mimikatz", typeof(MimikatzType), parameters);

Even with a static decoy module, RewriteModuleIAT within the ManualMap namespace will throw a FileNotFoundException seemingly randomly. This also happens if you let it find a random decoy module for you.

Here's an example of several back-to-back attempts at executing standard::coffee

[+] Module Registered: mimikatz

[*] Tasked agent to run: mimikatz
SETUPAPI.dll, unable to find the specified file.


[*] Tasked agent to run: mimikatz
WinSCard.dll, unable to find the specified file.


[*] Tasked agent to run: mimikatz
WINSTA.dll, unable to find the specified file.


[*] Tasked agent to run: mimikatz

  .#####.   mimikatz 2.2.0 (x64) #19041 Jul  4 2020 19:14:15
 .## ^ ##.  "A La Vie, A L'Amour" - (oe.eo)
 ## / \ ##  /*** Benjamin DELPY `gentilkiwi` ( [email protected] )
 ## \ / ##       > http://blog.gentilkiwi.com/mimikatz
 '## v ##'       Vincent LE TOUX             ( [email protected] )
  '#####'        > http://pingcastle.com / http://mysmartlogon.com   ***/

mimikatz(powershell) # standard::coffee

    ( (
     ) )
  .______.
  |      |]
  \      /
   `----'

I'm using code from #51 for this but with my own build of powerkatz.

Flaw with the way API set resolution is handled

The current implementation for resolving API sets (used when rebuilding the IAT) will fail if an API set is present in the import directory and uses a patch number not included in the map. Whilst not extremely common, this happens from time to time and will likely result in a mapping failure.

If you look at the way the Windows loader does API set resolution, a binary search is used with the API_SET_HASH_ENTRY structures. The important thing here is the fact that the Hash field of this structure excludes the patch number, meaning all comparisons done during resolution are independent of the patch number.

Following this logic, api-ms-win-core-processthreads-l1-1-0.dll and api-ms-win-core-processthreads-l1-1-3.dll will map to the same DLL. In fact, any API set like api-ms-win-core-processthreads-l1-1-X.dll, will map to the same DLL.

Using the current implementation, a fix is simple enough. Instead of doing an exact match via a key lookup, do a comparison up until the patch number.

As a reference, my library uses a stripped-down version of the same resolution algorithm that the Windows loader uses, which illustrates how the patch number is excluded from lookups during resolution.

[Feature Request] CreateProcess "No WaitForExit option"

For Covenant's Grunt redundancy, I want to do the same thing as "spawn" as implemented in PowerShell Empire.

However, SharpSploit's Execute calls WaitForExit(), so control won't return until the newly started process is finished.

process.WaitForExit();
return "";

Could you add an option for the Execute and CreateProcess methods to not call WaitForExit()?

how to update powerkatz*.dll.comp

Hello, awesome tools and appreciate the sharing.
my problem trying to update latest mimikatz's dlls is that i dont get how you generate both powerkatzx64.dll.comp and powerkatzx86.dll.comp.
both original dll's are generated from the mimikatz project from benjamin delpy, using second_release build option.
on the description you describe with:
"powerkatz_x64.dll.comp // Mimikatz 64-bit dll, compressed using the built-in System.IO.Compression library"
how can you compress the dll ? the System.IO.Compression is used on C# project but not with dll's already compiled....

thanks

Create project todo list

There currently doesn't appear to be a list of desired features, improvements, bug fixes, etc. It is hard to know what is considered "in-scope" for this project and what you might think is best left to other projects. If there is a todo list, it will be easier for people to contribute.

Safely free modules after mapping or overloading

A reminder that we should add a generic function for safely cleaning manually mapped or overloaded modules from memory after they are no longer necessary. For overloaded modules, the section should be unmapped. For manually mapped modules (in dynamic memory), they can be freed with NtFreeVirtualMemory. This will require editing the data structures to include the modules range in memory and a handle to the Section for overloaded modules.

Make sure and update the Mimikatz loader to use this, since a copy of mimikatz floating in memory is quite suspicious.

Missing DLL | Mimikatz

I got this error while trying to get lsa secrets or logon passwords !
"Cabinet.dll, unable to find the specified file."

RegistryRead and RegistryWrite?

Hello I was attempting to compile another project (SharpSploitConsole) and was running into errors because these functions do not appear to exist anymore in your code however they're still listed in the API docs. I can hit up the other maintainer for the console app but just wondered if there is a workaround or different code I could use.
Example 1: var a = SharpSploit.Enumeration.Host.RegistryRead(request[1]);
Example2: var a = SharpSploit.Enumeration.Host.RegistryWrite(request[1], request[2]);

Doesn't Compile

Steps to reproduce:

Downloaded this VM.

https://developer.microsoft.com/en-us/windows/downloads/virtual-machines

Opened SharpSploit.sln in the main repository and and hit Build.

Severity | Code | Description | Project | File | Line | Suppression State
-- | -- | -- | -- | -- | -- | --
Error | CS0234 | The type or namespace name 'Credentials' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Credentials\TokensTests.cs | 11 | Active
Error | CS1566 | Error reading resource 'SharpSploit.Resources.powerkatz_x86.dll' -- 'Could not find file 'C:\Users\user\githubclones\SharpSploit\SharpSploit\Resources\powerkatz_x86.dll'.' | SharpSploit(net35) | C:\Users\user\githubclones\SharpSploit\SharpSploit\CSC | 1 | Active
Error | CS0234 | The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\DomainTests.cs | 10 | Active
Error | CS0234 | The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\HostTests.cs | 10 | Active
Error | CS0234 | The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\HostTests.cs | 11 | Active
Error | CS0234 | The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\NetworkTests.cs | 10 | Active
Error | CS0234 | The type or namespace name 'Generic' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\NetworkTests.cs | 11 | Active
Error | CS0234 | The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Execution\ShellCodeTests.cs | 4 | Active
Error | CS0234 | The type or namespace name 'Execution' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Execution\ShellTests.cs | 8 | Active
Error | CS0234 | The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\LateralMovement\DCOMTests.cs | 7 | Active
Error | CS0234 | The type or namespace name 'LateralMovement' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?) | SharpSploit.Tests | C:\Users\user\githubclones\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\LateralMovement\WMITests.cs | 7 | Active
Warning | CS1685 | The predefined type 'ExtensionAttribute' is defined in multiple assemblies in the global alias; using definition from 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' | SharpSploit(net35) | C:\Users\user\githubclones\SharpSploit\SharpSploit\CSC | 1 | Active
Warning |   | The referenced component 'Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions' could not be found. | SharpSploit.Tests |   |   |  
Warning |   | The referenced component 'Microsoft.VisualStudio.TestPlatform.TestFramework' could not be found. | SharpSploit.Tests |   |   |  
Warning |   | Could not resolve this reference. Could not locate the assembly "SharpSploit". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. | SharpSploit.Tests |   |   |  
Warning |   | The referenced component 'SharpSploit' could not be found. | SharpSploit.Tests |   |   |  
Warning | MSB3277 | Found conflicts between different versions of "System.Management" that could not be resolved.  These reference conflicts are listed in the build log when log verbosity is set to detailed. | SharpSploit | C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets | 2110 |  
Warning | MSB3277 | Found conflicts between different versions of "System.DirectoryServices" that could not be resolved.  These reference conflicts are listed in the build log when log verbosity is set to detailed. | SharpSploit | C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets | 2110 |  
Warning | MSB3270 | There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "mscorlib, version=4.0.0.0", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. | SharpSploit | C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets | 2110 |  
Warning | MSB3270 | There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "mscorlib, version=2.0.0.0", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. | SharpSploit | C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets | 2110 |  

If there are any prereqs, please share.

Can't build the project

Hi,

I've been trying to build the solution and it always fails with the errors listed below. Now, I know these are because the SharpSploit project is failing to load and these errors are from the Test project but there's nothing I've been able to do to manage the import.

1>------ Build started: Project: SharpSploit.Tests, Configuration: Debug Any CPU ------
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(2110,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "SharpSploit". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors.
1>D:\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Credentials\TokensTests.cs(11,19,11,30): error CS0234: The type or namespace name 'Credentials' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?)
1>D:\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\DomainTests.cs(10,19,10,30): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?)
1>D:\SharpSploit\SharpSploit.Tests\SharpSploit.Tests\Enumeration\HostTests.cs(10,19,10,30): error CS0234: The type or namespace name 'Enumeration' does not exist in the namespace 'SharpSploit' (are you missing an assembly reference?)
........... {more such errors but useless}

Here's the error I get upon reloading the project:
SharpSploit\SharpSploit.csproj : error : Project file is incomplete. Expected imports are missing.

I'm working with Visual Studio 2017 and .NET 4.5 (which I believe someone said the project is built using). Can someone nudge me in the right way?

PS: You can also view the Solution Explorer view in the image.

image

Can't compile

Windows7 VS 2015 community, SharpSploit project load failed.
Output Error:
\SharpSploit\SharpSploit.csproj : error : The default XML namespace of the project must be the MSBuild XML namespace. If the project is authored in the MSBuild 2003 format, please add xmlns="http://schemas.microsoft.com/developer/msbuild/2003" to the element. If the project has been authored in the old 1.0 or 1.2 format, please convert it to MSBuild 2003 format. C:\Users\user\Downloads\SharpSploit-master\SharpSploit-master\SharpSploit\SharpSploit.csproj

sharpsploit.cobbr.io certificate expired

C:\Users\admin>curl -vvv https://sharpsploit.cobbr.io/api/
*   Trying 52.14.199.185...
* TCP_NODELAY set
* Connected to sharpsploit.cobbr.io (52.14.199.185) port 443 (#0)
* schannel: SSL/TLS connection with sharpsploit.cobbr.io port 443 (step 1/3)
* schannel: checking server certificate revocation
* schannel: sending initial handshake data: sending 185 bytes...
* schannel: sent initial handshake data: sent 185 bytes
* schannel: SSL/TLS connection with sharpsploit.cobbr.io port 443 (step 2/3)
* schannel: failed to receive handshake, need more data
* schannel: SSL/TLS connection with sharpsploit.cobbr.io port 443 (step 2/3)
* schannel: encrypted data got 1784
* schannel: encrypted data buffer: offset 1784 length 4096
* schannel: next InitializeSecurityContext failed: SEC_E_CERT_EXPIRED (0x80090328) - The received certificate has expired.
* Closing connection 0
* schannel: shutting down SSL/TLS connection with sharpsploit.cobbr.io port 443
* schannel: clear security context handle
curl: (35) schannel: next InitializeSecurityContext failed: SEC_E_CERT_EXPIRED (0x80090328) - The received certificate has expired.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.