Function at 0x405670
Capabilities:
Acquire debug privileges
Terminate process

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43e3a8
mov eax, dword fs:[0]
push eax
sub esp, 0x5c
mov eax, dword [0x469644]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
sub esp, 0x1c
mov esi, esp
mov dword [ebp - 0x50], esp
xor eax, eax
xor edi, edi
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], edi
mov ebx, ecx
mov word [esi], ax
push 0x10
mov eax, 0x45d72c
mov dword [ebp - 0x5c], ebx
mov byte [ebp - 0x4a], 0
mov byte [ebp - 0x49], 1
call fcn.00404210
call fcn.00410a60
add esp, 0x1c
lea ecx, [ebp - 0x2c]
push ebx
push ecx
call fcn.004063a0
mov ecx, eax
sub esp, 0x14
mov dword [ebp - 4], edi
mov eax, esp
mov dword [ebp - 0x54], esp
push ecx
mov edx, str.ID:
call fcn.00404a00
add esp, 4
call fcn.00410b20
mov ebx, 8
add esp, 0x1c
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x18], ebx
jb 0x40571f
mov edx, dword [ebp - 0x2c]
push edx
call fcn.00426e9f
add esp, 4
lea eax, [ebp - 0x50]
push eax
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push 0x28
call edi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4058e8
call esi
cmp eax, 0x3f0
jne 0x40585d
push 2
call dword [sym.imp.ADVAPI32.dll_ImpersonateSelf]
test eax, eax
jne 0x4057e4
call esi
push eax
lea ecx, [ebp - 0x48]
push ecx
call fcn.004063a0
push eax
mov edx, 0x45d760
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 1
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], 2
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x4057b4
mov edx, dword [ebp - 0x2c]
push edx
call fcn.00426e9f
add esp, 4
xor eax, eax
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
cmp dword [ebp - 0x34], ebx
jb 0x4057e0
mov ecx, dword [ebp - 0x48]
push ecx
call fcn.00426e9f
add esp, 4
mov byte [ebp - 0x49], 0
lea edx, [ebp - 0x50]
push edx
push 0
push 0x28
call edi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
test eax, eax
jne 0x4058de
call esi
push eax
lea eax, [ebp - 0x48]
push eax
call fcn.004063a0
push eax
mov edx, str.OpenThreadToken_mit_ImpersonateSelf_fehlgeschlagen__ErrorCode:
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 3
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], 4
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x405851
mov ecx, dword [ebp - 0x2c]
push ecx
call fcn.00426e9f
add esp, 4
mov dword [ebp - 0x18], 7
jmp 0x40596e
call esi
push eax
lea ecx, [ebp - 0x48]
push ecx
call fcn.004063a0
push eax
mov edx, str.OpenThreadToken_fehlgeschlagen__ErrorCode:
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 5
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], 6
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x4058b1
mov edx, dword [ebp - 0x2c]
push edx
call fcn.00426e9f
add esp, 4
xor eax, eax
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
cmp dword [ebp - 0x34], ebx
jb 0x40598f
mov ecx, dword [ebp - 0x48]
push ecx
jmp 0x405987
cmp byte [ebp - 0x49], 0
je 0x405993
mov edi, dword [ebp - 0x50]
lea edx, [ebp - 0x58]
push edx
push str.SeDebugPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x405917
push 1
lea esi, [ebp - 0x58]
call fcn.00405b50
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
add esp, 4
test al, al
jne 0x405993
call esi
push eax
lea eax, [ebp - 0x48]
push eax
call fcn.004063a0
push eax
mov edi, 7
mov edx, str.SetPrivilege_fehlgeschlagen__ErrorCode:
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], edi
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], bl
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x40596b
mov ecx, dword [ebp - 0x2c]
push ecx
call fcn.00426e9f
add esp, 4
mov dword [ebp - 0x18], edi
xor edx, edx
mov dword [ebp - 4], 0xffffffff
mov word [ebp - 0x2c], dx
mov dword [ebp - 0x1c], edx
cmp dword [ebp - 0x34], ebx
jb 0x40598f
mov eax, dword [ebp - 0x48]
push eax
call fcn.00426e9f
add esp, 4
mov byte [ebp - 0x49], 0
mov ecx, dword [ebp - 0x5c]
push ecx
push 0
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
mov dword [ebp - 0x5c], edi
test edi, edi
je 0x405a6d
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
setne al
mov byte [ebp - 0x4a], al
test al, al
je 0x4059fa
sub esp, 0x1c
mov esi, esp
mov dword [ebp - 0x54], esp
xor edx, edx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
push 0x1c
mov eax, str.TerminateProcess_erfolgreich
mov word [esi], dx
call fcn.00404210
call fcn.00410b20
add esp, 0x1c
jmp 0x405ae6
call esi
push eax
lea eax, [ebp - 0x48]
push eax
call fcn.004063a0
push eax
mov edx, str.TerminateProcess_fehlgeschlagen__ErrorCode:
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 9
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], 0xa
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x405a4e
mov ecx, dword [ebp - 0x2c]
push ecx
call fcn.00426e9f
add esp, 4
xor edx, edx
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], dx
cmp dword [ebp - 0x34], ebx
jb 0x405ae6
mov eax, dword [ebp - 0x48]
push eax
jmp 0x405ade
call esi
push eax
lea ecx, [ebp - 0x48]
push ecx
call fcn.004063a0
push eax
mov edx, str.OpenProcess_fehlgeschlagen__ErrorCode:
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], 0xb
call fcn.00404a00
sub esp, 0x10
mov byte [ebp - 4], 0xc
mov ecx, esp
mov dword [ebp - 0x54], esp
push eax
mov eax, 0x45d75c
call fcn.0040f880
add esp, 4
call fcn.00410b20
add esp, 0x1c
cmp dword [ebp - 0x18], ebx
jb 0x405ac1
mov edx, dword [ebp - 0x2c]
push edx
call fcn.00426e9f
add esp, 4
xor eax, eax
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
cmp dword [ebp - 0x34], ebx
jb 0x405ae6
mov ecx, dword [ebp - 0x48]
push ecx
call fcn.00426e9f
add esp, 4
cmp byte [ebp - 0x49], 0
je 0x405b16
mov ebx, dword [ebp - 0x50]
lea edx, [ebp - 0x64]
push edx
push str.SeDebugPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x405b16
push 0
lea esi, [ebp - 0x64]
mov edi, ebx
call fcn.00405b50
mov edi, dword [ebp - 0x5c]
add esp, 4
mov eax, dword [ebp - 0x50]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
call esi
push edi
call esi
mov al, byte [ebp - 0x4a]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0042575d
mov esp, ebp
pop ebp
ret