mirror of
https://github.com/rapid7/metasploit-payloads
synced 2024-11-20 14:39:22 +01:00
c9ca614313
Add support for loading RDI-related stuff using ordinals instead of function names. Remove exports from the extensions/etc. This is another step in the direction to make the DLLs less obvious. Extensions no longer have their own name in the library metadata. They're all "extension.dll". Metsrv is now "server.dll" and the two non-extensions are "plugin.dll". I was going for something a little less obvious. This required changes to the RDI functionality.
287 lines
16 KiB
XML
287 lines
16 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
<ItemGroup Label="ProjectConfigurations">
|
|
<ProjectConfiguration Include="r7_release|Win32">
|
|
<Configuration>r7_release</Configuration>
|
|
<Platform>Win32</Platform>
|
|
</ProjectConfiguration>
|
|
<ProjectConfiguration Include="r7_release|x64">
|
|
<Configuration>r7_release</Configuration>
|
|
<Platform>x64</Platform>
|
|
</ProjectConfiguration>
|
|
<ProjectConfiguration Include="Release|Win32">
|
|
<Configuration>Release</Configuration>
|
|
<Platform>Win32</Platform>
|
|
</ProjectConfiguration>
|
|
<ProjectConfiguration Include="Release|x64">
|
|
<Configuration>Release</Configuration>
|
|
<Platform>x64</Platform>
|
|
</ProjectConfiguration>
|
|
</ItemGroup>
|
|
<PropertyGroup Label="Globals">
|
|
<ProjectGuid>{09DF8FBC-EDFB-44E6-ACE6-9C0F5A60AB1C}</ProjectGuid>
|
|
<RootNamespace>screenshot</RootNamespace>
|
|
<Keyword>Win32Proj</Keyword>
|
|
</PropertyGroup>
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<CharacterSet>MultiByte</CharacterSet>
|
|
<WholeProgramOptimization>false</WholeProgramOptimization>
|
|
<PlatformToolset>v141_xp</PlatformToolset>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|Win32'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<CharacterSet>MultiByte</CharacterSet>
|
|
<WholeProgramOptimization>false</WholeProgramOptimization>
|
|
<PlatformToolset>v141_xp</PlatformToolset>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<CharacterSet>MultiByte</CharacterSet>
|
|
<WholeProgramOptimization>false</WholeProgramOptimization>
|
|
<PlatformToolset>v141_xp</PlatformToolset>
|
|
</PropertyGroup>
|
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|x64'" Label="Configuration">
|
|
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
|
<CharacterSet>MultiByte</CharacterSet>
|
|
<WholeProgramOptimization>false</WholeProgramOptimization>
|
|
<PlatformToolset>v141_xp</PlatformToolset>
|
|
</PropertyGroup>
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
|
<ImportGroup Label="ExtensionSettings">
|
|
<Import Project="$(VCTargetsPath)\BuildCustomizations\masm.props" />
|
|
</ImportGroup>
|
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
<Import Project="..\meterpreter.props" />
|
|
</ImportGroup>
|
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|Win32'" Label="PropertySheets">
|
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
<Import Project="..\meterpreter.props" />
|
|
</ImportGroup>
|
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
<Import Project="..\meterpreter.props" />
|
|
</ImportGroup>
|
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|x64'" Label="PropertySheets">
|
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
|
<Import Project="..\meterpreter.props" />
|
|
</ImportGroup>
|
|
<PropertyGroup Label="UserMacros" />
|
|
<PropertyGroup>
|
|
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
|
|
<OutDir>$(Configuration)\$(Platform)\</OutDir>
|
|
<IntDir>$(Configuration)\$(Platform)\</IntDir>
|
|
<LinkIncremental Condition="'$(Configuration)'=='Release'">false</LinkIncremental>
|
|
<LinkIncremental Condition="'$(Configuration)'=='r7_release'">false</LinkIncremental>
|
|
<GenerateManifest>false</GenerateManifest>
|
|
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
|
|
<CodeAnalysisRules />
|
|
<CodeAnalysisRuleAssemblies />
|
|
<TargetName>$(ProjectName).$(PlatformShortName)</TargetName>
|
|
</PropertyGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
|
<ClCompile>
|
|
<Optimization>MinSpace</Optimization>
|
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
|
<IntrinsicFunctions>false</IntrinsicFunctions>
|
|
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
|
<AdditionalIncludeDirectories>..\..\source\ReflectiveDLLInjection\common;..\..\source\common;..\..\source\jpeg-8;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;SCREENSHOT_EXPORTS;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<StringPooling>true</StringPooling>
|
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
|
<FunctionLevelLinking>false</FunctionLevelLinking>
|
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
|
<CallingConvention>Cdecl</CallingConvention>
|
|
<CompileAs>CompileAsC</CompileAs>
|
|
<BufferSecurityCheck>false</BufferSecurityCheck>
|
|
<TreatLinkerWarningAsErrors>true</TreatLinkerWarningAsErrors>
|
|
<TreatWarningAsError>true</TreatWarningAsError>
|
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
|
</ClCompile>
|
|
<Link>
|
|
<AdditionalDependencies>jpeg.$(PlatformShortName).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
<AdditionalLibraryDirectories>..\backcompat\$(Configuration);..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
|
<ManifestFile>
|
|
</ManifestFile>
|
|
<GenerateDebugInformation>false</GenerateDebugInformation>
|
|
<SubSystem>Windows</SubSystem>
|
|
<OptimizeReferences>true</OptimizeReferences>
|
|
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
|
<FixedBaseAddress>false</FixedBaseAddress>
|
|
<DataExecutionPrevention>true</DataExecutionPrevention>
|
|
<TargetMachine>MachineX86</TargetMachine>
|
|
<MinimumRequiredVersion>
|
|
</MinimumRequiredVersion>
|
|
<ModuleDefinitionFile>$(ProjectDir)..\..\source\def\plugin.def</ModuleDefinitionFile>
|
|
<AdditionalOptions>/ignore:4070 %(AdditionalOptions)</AdditionalOptions>
|
|
<ProgramDatabaseFile />
|
|
</Link>
|
|
<PostBuildEvent>
|
|
<Command>editbin.exe /NOLOGO /OSVERSION:5.0 /SUBSYSTEM:WINDOWS,4.0 "$(TargetDir)$(TargetFileName)" > NUL
|
|
IF NOT EXIST "$(ProjectDir)..\..\output\" mkdir "$(ProjectDir)..\..\output\"
|
|
copy /y "$(TargetDir)$(TargetFileName)" "$(ProjectDir)..\..\output\"</Command>
|
|
</PostBuildEvent>
|
|
</ItemDefinitionGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|Win32'">
|
|
<ClCompile>
|
|
<Optimization>MinSpace</Optimization>
|
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
|
<IntrinsicFunctions>false</IntrinsicFunctions>
|
|
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
|
<AdditionalIncludeDirectories>..\..\source\ReflectiveDLLInjection\common;..\..\source\common;..\..\source\jpeg-8;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;SCREENSHOT_EXPORTS;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<StringPooling>true</StringPooling>
|
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
|
<FunctionLevelLinking>false</FunctionLevelLinking>
|
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
|
<CallingConvention>Cdecl</CallingConvention>
|
|
<CompileAs>CompileAsC</CompileAs>
|
|
<BufferSecurityCheck>false</BufferSecurityCheck>
|
|
<TreatLinkerWarningAsErrors>true</TreatLinkerWarningAsErrors>
|
|
<TreatWarningAsError>true</TreatWarningAsError>
|
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
|
</ClCompile>
|
|
<Link>
|
|
<AdditionalDependencies>jpeg.$(PlatformShortName).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
<AdditionalLibraryDirectories>..\backcompat\$(Configuration);..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
|
<ManifestFile>
|
|
</ManifestFile>
|
|
<GenerateDebugInformation>false</GenerateDebugInformation>
|
|
<SubSystem>Windows</SubSystem>
|
|
<OptimizeReferences>true</OptimizeReferences>
|
|
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
|
<FixedBaseAddress>false</FixedBaseAddress>
|
|
<DataExecutionPrevention>true</DataExecutionPrevention>
|
|
<TargetMachine>MachineX86</TargetMachine>
|
|
<MinimumRequiredVersion>
|
|
</MinimumRequiredVersion>
|
|
<ModuleDefinitionFile>$(ProjectDir)..\..\source\def\plugin.def</ModuleDefinitionFile>
|
|
<AdditionalOptions>/ignore:4070 %(AdditionalOptions)</AdditionalOptions>
|
|
<ProgramDatabaseFile />
|
|
</Link>
|
|
<PostBuildEvent>
|
|
<Command>editbin.exe /NOLOGO /OSVERSION:5.0 /SUBSYSTEM:WINDOWS,4.0 "$(TargetDir)$(TargetFileName)" > NUL
|
|
IF NOT EXIST "$(ProjectDir)..\..\output\" mkdir "$(ProjectDir)..\..\output\"
|
|
copy /y "$(TargetDir)$(TargetFileName)" "$(ProjectDir)..\..\output\"</Command>
|
|
</PostBuildEvent>
|
|
</ItemDefinitionGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
|
<Midl>
|
|
<TargetEnvironment>X64</TargetEnvironment>
|
|
</Midl>
|
|
<ClCompile>
|
|
<Optimization>MinSpace</Optimization>
|
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
|
<IntrinsicFunctions>false</IntrinsicFunctions>
|
|
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
|
<AdditionalIncludeDirectories>..\..\source\ReflectiveDLLInjection\common;..\..\source\common;..\..\source\jpeg-8;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;SCREENSHOT_EXPORTS;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<StringPooling>true</StringPooling>
|
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
|
<FunctionLevelLinking>false</FunctionLevelLinking>
|
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
|
<CallingConvention>Cdecl</CallingConvention>
|
|
<CompileAs>CompileAsC</CompileAs>
|
|
<BufferSecurityCheck>false</BufferSecurityCheck>
|
|
<TreatLinkerWarningAsErrors>true</TreatLinkerWarningAsErrors>
|
|
<TreatWarningAsError>true</TreatWarningAsError>
|
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
|
</ClCompile>
|
|
<Link>
|
|
<AdditionalDependencies>jpeg.$(PlatformShortName).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
<AdditionalLibraryDirectories>..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
|
<ManifestFile>
|
|
</ManifestFile>
|
|
<GenerateDebugInformation>false</GenerateDebugInformation>
|
|
<SubSystem>Windows</SubSystem>
|
|
<OptimizeReferences>true</OptimizeReferences>
|
|
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
|
<FixedBaseAddress>false</FixedBaseAddress>
|
|
<DataExecutionPrevention>true</DataExecutionPrevention>
|
|
<TargetMachine>MachineX64</TargetMachine>
|
|
<MinimumRequiredVersion />
|
|
<ModuleDefinitionFile>$(ProjectDir)..\..\source\def\plugin.def</ModuleDefinitionFile>
|
|
<AdditionalOptions>/ignore:4070 %(AdditionalOptions)</AdditionalOptions>
|
|
<ProgramDatabaseFile />
|
|
</Link>
|
|
<PostBuildEvent>
|
|
<Command>editbin.exe /NOLOGO /OSVERSION:5.0 /SUBSYSTEM:WINDOWS,5.02 "$(TargetDir)$(TargetFileName)" > NUL
|
|
IF NOT EXIST "$(ProjectDir)..\..\output\" mkdir "$(ProjectDir)..\..\output\"
|
|
copy /y "$(TargetDir)$(TargetFileName)" "$(ProjectDir)..\..\output\"</Command>
|
|
</PostBuildEvent>
|
|
</ItemDefinitionGroup>
|
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='r7_release|x64'">
|
|
<Midl>
|
|
<TargetEnvironment>X64</TargetEnvironment>
|
|
</Midl>
|
|
<ClCompile>
|
|
<Optimization>MinSpace</Optimization>
|
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
|
<IntrinsicFunctions>false</IntrinsicFunctions>
|
|
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
|
<AdditionalIncludeDirectories>..\..\source\ReflectiveDLLInjection\common;..\..\source\common;..\..\source\jpeg-8;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
|
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;SCREENSHOT_EXPORTS;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
|
<StringPooling>true</StringPooling>
|
|
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
|
<FunctionLevelLinking>false</FunctionLevelLinking>
|
|
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
|
<WarningLevel>Level3</WarningLevel>
|
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
|
<CallingConvention>Cdecl</CallingConvention>
|
|
<CompileAs>CompileAsC</CompileAs>
|
|
<BufferSecurityCheck>false</BufferSecurityCheck>
|
|
<TreatLinkerWarningAsErrors>true</TreatLinkerWarningAsErrors>
|
|
<TreatWarningAsError>true</TreatWarningAsError>
|
|
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
|
</ClCompile>
|
|
<Link>
|
|
<AdditionalDependencies>jpeg.$(PlatformShortName).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
|
<AdditionalLibraryDirectories>..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
|
<ManifestFile>
|
|
</ManifestFile>
|
|
<GenerateDebugInformation>false</GenerateDebugInformation>
|
|
<SubSystem>Windows</SubSystem>
|
|
<OptimizeReferences>true</OptimizeReferences>
|
|
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
|
<RandomizedBaseAddress>true</RandomizedBaseAddress>
|
|
<FixedBaseAddress>false</FixedBaseAddress>
|
|
<DataExecutionPrevention>true</DataExecutionPrevention>
|
|
<TargetMachine>MachineX64</TargetMachine>
|
|
<MinimumRequiredVersion />
|
|
<ModuleDefinitionFile>$(ProjectDir)..\..\source\def\plugin.def</ModuleDefinitionFile>
|
|
<AdditionalOptions>/ignore:4070 %(AdditionalOptions)</AdditionalOptions>
|
|
<ProgramDatabaseFile />
|
|
</Link>
|
|
<PostBuildEvent>
|
|
<Command>editbin.exe /NOLOGO /OSVERSION:5.0 /SUBSYSTEM:WINDOWS,5.02 "$(TargetDir)$(TargetFileName)" > NUL
|
|
IF NOT EXIST "$(ProjectDir)..\..\output\" mkdir "$(ProjectDir)..\..\output\"
|
|
copy /y "$(TargetDir)$(TargetFileName)" "$(ProjectDir)..\..\output\"</Command>
|
|
</PostBuildEvent>
|
|
</ItemDefinitionGroup>
|
|
<ItemGroup>
|
|
<ClCompile Include="..\..\source\screenshot\bmp2jpeg.c" />
|
|
<ClCompile Include="..\..\source\screenshot\screenshot.c" />
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<ClInclude Include="..\..\source\screenshot\bmp2jpeg.h" />
|
|
<ClInclude Include="..\..\source\screenshot\screenshot.h" />
|
|
</ItemGroup>
|
|
<Choose>
|
|
<When Condition="'$(Platform)'=='Win32'" />
|
|
</Choose>
|
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
|
<ImportGroup Label="ExtensionTargets">
|
|
<Import Project="$(VCTargetsPath)\BuildCustomizations\masm.targets" />
|
|
</ImportGroup>
|
|
</Project> |