mirror of
https://github.com/rapid7/metasploit-payloads
synced 2025-01-14 17:37:27 +01:00
Fix C++11 make_pair errors and U_CHAR problem
* make_pair() changed in C++11 so this change fixes the code so that the compiler doesn't complain any more. * Compiler was also complaining about redefinition of U_CHAR. Undefining before redefining resolves the issue.
This commit is contained in:
parent
89d2326901
commit
8ae670cfaf
@ -13,7 +13,7 @@ PRTL_AVL_TABLE mod_mimikatz_sekurlsa_kerberos::KerbGlobalLogonSessionTable = NUL
|
||||
bool mod_mimikatz_sekurlsa_kerberos::getKerberos(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getKerberosLogonData, wstring(L"kerberos")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getKerberosLogonData, wstring(L"kerberos")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,7 @@ mod_mimikatz_sekurlsa_livessp::PKIWI_LIVESSP_LIST_ENTRY mod_mimikatz_sekurlsa_li
|
||||
bool mod_mimikatz_sekurlsa_livessp::getLiveSSP(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getLiveSSPLogonData, wstring(L"livessp")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getLiveSSPLogonData, wstring(L"livessp")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -12,7 +12,7 @@ PULONG mod_mimikatz_sekurlsa_msv1_0::LogonSessionListCount = NULL;
|
||||
bool mod_mimikatz_sekurlsa_msv1_0::getMSV(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getMSVLogonData, wstring(L"msv1_0")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getMSVLogonData, wstring(L"msv1_0")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,7 @@ mod_mimikatz_sekurlsa_ssp::PKIWI_SSP_CREDENTIAL_LIST_ENTRY mod_mimikatz_sekurlsa
|
||||
bool mod_mimikatz_sekurlsa_ssp::getSSP(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getSSPLogonData, wstring(L"ssp")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getSSPLogonData, wstring(L"ssp")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,7 @@ PRTL_AVL_TABLE mod_mimikatz_sekurlsa_tspkg::TSGlobalCredTable = NULL; //reinterp
|
||||
bool mod_mimikatz_sekurlsa_tspkg::getTsPkg(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getTsPkgLogonData, wstring(L"tspkg")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getTsPkgLogonData, wstring(L"tspkg")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -12,7 +12,7 @@ long mod_mimikatz_sekurlsa_wdigest::offsetWDigestPrimary = 0;
|
||||
bool mod_mimikatz_sekurlsa_wdigest::getWDigest(vector<wstring> * arguments)
|
||||
{
|
||||
vector<pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>> monProvider;
|
||||
monProvider.push_back(make_pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getWDigestLogonData, wstring(L"wdigest")));
|
||||
monProvider.push_back(pair<mod_mimikatz_sekurlsa::PFN_ENUM_BY_LUID, wstring>(getWDigestLogonData, wstring(L"wdigest")));
|
||||
return mod_mimikatz_sekurlsa::getLogonData(arguments, &monProvider);
|
||||
}
|
||||
|
||||
|
@ -96,7 +96,7 @@ bool mod_mimikatz_sekurlsa::searchLSASSDatas()
|
||||
{
|
||||
if((_wcsicmp(leModule->szModule.c_str(), testModule->moduleName) == 0) && !(*testModule->pModuleEntry))
|
||||
{
|
||||
GLOB_ALL_Providers.push_back(make_pair<PFN_ENUM_BY_LUID, wstring>(testModule->enumFunc, testModule->simpleName/*wstring(L"msv1_0")*/));
|
||||
GLOB_ALL_Providers.push_back(pair<PFN_ENUM_BY_LUID, wstring>(testModule->enumFunc, testModule->simpleName/*wstring(L"msv1_0")*/));
|
||||
*testModule->pModuleEntry = new mod_process::KIWI_VERY_BASIC_MODULEENTRY(*leModule);
|
||||
break;
|
||||
}
|
||||
|
@ -22,5 +22,6 @@ BOOL WINAPI mod_windows::enumHWNDCallback(HWND hwnd, pair<DWORD, vector<mod_win
|
||||
|
||||
bool mod_windows::getHWNDsFromProcessId(vector<mod_windows::KIWI_HWND_ENTRY> * mesHWNDS, DWORD processId)
|
||||
{
|
||||
return (EnumWindows(reinterpret_cast<WNDENUMPROC>(enumHWNDCallback), reinterpret_cast<LPARAM>(&make_pair<DWORD, vector<mod_windows::KIWI_HWND_ENTRY> *>(processId, mesHWNDS))) != FALSE);
|
||||
pair<DWORD, vector<mod_windows::KIWI_HWND_ENTRY> *> enumHWNDParm(processId, mesHWNDS);
|
||||
return (EnumWindows(reinterpret_cast<WNDENUMPROC>(enumHWNDCallback), reinterpret_cast<LPARAM>(&enumHWNDParm)) != FALSE);
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <windows.h>
|
||||
#include "precomp.h"
|
||||
#include "bmp2jpeg.h"
|
||||
#pragma comment(lib, "jpeg.lib")
|
||||
|
||||
@ -91,6 +92,9 @@ following copyright:
|
||||
* (The "non-english" version can be found in the ../../srouce/jpeg-8/README file)
|
||||
*/
|
||||
|
||||
#ifdef U_CHAR
|
||||
#undef U_CHAR
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_UNSIGNED_CHAR
|
||||
typedef unsigned char U_CHAR;
|
||||
@ -99,10 +103,10 @@ typedef unsigned char U_CHAR;
|
||||
#ifdef CHAR_IS_UNSIGNED
|
||||
typedef char U_CHAR;
|
||||
#define UCH(x) ((int) (x))
|
||||
#else
|
||||
#else /* !CHAR_IS_UNSIGNED */
|
||||
typedef char U_CHAR;
|
||||
#define UCH(x) ((int) (x) & 0xFF)
|
||||
#endif
|
||||
#endif /* CHAR_IS_UNSIGNED */
|
||||
#endif /* HAVE_UNSIGNED_CHAR */
|
||||
|
||||
|
||||
|
@ -72,8 +72,10 @@ Global
|
||||
{405245AB-0071-4CB9-BFBE-ED4E2A987EFF}.Release|x64.Build.0 = Release|x64
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Debug|x64.ActiveCfg = Release|x64
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Debug|x64.Build.0 = Release|x64
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Release|x64.ActiveCfg = Release|x64
|
||||
{4DECF649-2B11-47A2-908E-031105D706F8}.Release|x64.Build.0 = Release|x64
|
||||
{37E24F8F-1BD9-490B-8CD2-4768B89E5EAB}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{37E24F8F-1BD9-490B-8CD2-4768B89E5EAB}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{37E24F8F-1BD9-490B-8CD2-4768B89E5EAB}.Debug|x64.ActiveCfg = Release|x64
|
||||
@ -100,8 +102,10 @@ Global
|
||||
{C427F6B9-C287-4BDA-A5BB-401FC19E207C}.Release|x64.Build.0 = Release|x64
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Debug|x64.ActiveCfg = Release|x64
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Debug|x64.Build.0 = Release|x64
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Release|x64.ActiveCfg = Release|x64
|
||||
{488BE203-8407-42D1-B334-8B5C3BC5AB3E}.Release|x64.Build.0 = Release|x64
|
||||
{CF56DDCC-505F-4D5C-AC2E-9787C7EF1504}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{CF56DDCC-505F-4D5C-AC2E-9787C7EF1504}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{CF56DDCC-505F-4D5C-AC2E-9787C7EF1504}.Debug|x64.ActiveCfg = Release|x64
|
||||
|
Loading…
Reference in New Issue
Block a user