Function at 0x402380
Capabilities:
Acquire debug privileges

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x4c
push ebx
push esi
push edi
call fcn.004017c0
mov esi, eax
push esi
call fcn.00402950
push esi
push 0
push 0x1000
call dword [sym.imp.KERNEL32.dll_OpenProcess]
lea ecx, [esp + 0xc]
push ecx
push 0xf01ff
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov edi, dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
lea edx, [esp + 0x1c]
push edx
push str.SeDebugPrivilege
push 0
call edi
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
mov esi, dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push 0
push 0
push 0x10
lea edx, [esp + 0x44]
push edx
mov ebx, 1
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x1c]
push ebx
push eax
mov dword [esp + 0x50], ebx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x5c], 2
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeDebugPrivilege
push 0
mov dword [esp + 0x1c], ecx
call edi
lea edi, [ebx + 3]
test eax, eax
je 0x40244f
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeChangeNotifyPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x402499
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeTcbPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x4024e3
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeImpersonatePrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x40252d
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeLoadDriverPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x402577
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeRestorePrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x4025c1
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeBackupPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x40260b
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeSecurityPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x402655
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeSystemEnvironmentPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x40269f
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeIncreaseQuotaPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x4026e9
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeTakeOwnershipPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x402733
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeIncreaseBasePriorityPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x40277d
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeShutdownPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x4027c7
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x24]
push edx
push str.SeAssignPrimaryTokenPrivilege
push 0
mov dword [esp + 0x1c], ecx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x402811
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
push 0
push 0
push 0x10
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x20]
push 0
push eax
mov dword [esp + 0x60], ebx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x6c], edi
call esi
lea ecx, [esp + 0x2c]
xor eax, eax
xor esi, esi
mov edx, ecx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x18], esi
push edx
mov word [esp + 0x30], 0x101
mov byte [esp + 0x37], 0x10
mov dword [esp + 0x38], esi
mov dword [esp + 0x1c], 0x20
mov dword [esp + 0x18], ecx
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov ecx, dword [esp + 0xc]
add eax, 8
push eax
lea eax, [esp + 0x18]
push eax
push 0x19
push ecx
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
call fcn.00401cc0
call fcn.00401c30
call fcn.00401a50
push esi
call fcn.00409228
add esp, 4
push eax
call fcn.00408e29
add esp, 4
mov esi, 0x1d
lea ebx, [ebx]
call fcn.00408e3b
call fcn.00408e3b
sub esi, ebx
jne 0x402890
call fcn.00401ba0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10