Function at 0x45a2a8
Capabilities:
Impersonate user

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffa8c
mov eax, 0x51afb0
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov ebx, dword [ebp + 0x1c]
mov esi, dword [ebp + 0xc]
call fcn.004cfcb8
mov dword [ebp - 0x34], 0x4000210
xor edx, edx
xor ecx, ecx
mov dword [ebp - 0x38], edx
mov dword [ebp - 0x3c], ecx
xor eax, eax
xor edx, edx
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x44], edx
xor ecx, ecx
xor eax, eax
mov dword [ebp - 0x48], ecx
xor edx, edx
mov dword [ebp - 0x50], eax
xor ecx, ecx
mov dword [ebp - 0x58], edx
mov dword [ebp - 0x60], ecx
mov word [ebp - 0x14], 8
mov dword [ebp - 0x5c], esi
test esi, esi
je 0x45a30e
mov al, byte [esi]
test al, al
jne 0x45a30e
xor edx, edx
mov dword [ebp - 0x5c], edx
push 0
call sub.KERNEL32.dll_Sleep
push 0x64
call sub.KERNEL32.dll_Sleep
push 0
call sub.KERNEL32.dll_Sleep
push 0xffffeeee
push 0xffffeeee
push 0x5d3a24
push 0x5d3a1f
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
call fcn.00457690
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x28]
push eax
call fcn.004576cc
pop ecx
mov dword [ebp - 0x3c], eax
push 0xffffeeee
push 0xffffeeee
push edi
push 0x5d3a43
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test edi, edi
jne 0x45a3c9
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x38], ecx
mov eax, dword [ebp - 0x38]
test eax, eax
jne 0x45a3ce
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3a4d
push 0x5d3a48
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a3be
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3a5c
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
xor ecx, ecx
mov dword [ebp - 0x38], ecx
mov eax, dword [ebp - 0x38]
test eax, eax
jne 0x45a417
mov edx, dword [ebp - 0x28]
cmp edx, 0xffffffff
je 0x45a417
mov ecx, dword [ebp - 0x28]
push ecx
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3a70
push 0x5d3a6b
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
push 0
mov edx, dword [ebp - 0x3c]
push edx
mov ecx, dword [ebp - 0x5c]
push ecx
mov eax, dword [ebp + 0x10]
push eax
push edi
call fcn.00456a70
add esp, 0x14
mov dword [ebp - 0x38], eax
mov edx, dword [ebp - 0x38]
test edx, edx
jne 0x45a45d
mov ecx, dword [ebp - 0x28]
push ecx
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3a83
push 0x5d3a7e
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
lea edx, [ebp - 0x38]
push edx
push 0
push 2
mov ecx, dword [ebp + 0x10]
push ecx
mov eax, dword [ebp - 0x5c]
push eax
push edi
call sub.ADVAPI32.dll_LogonUserA
test eax, eax
jne 0x45a45d
xor edx, edx
mov dword [ebp - 0x38], edx
mov ecx, dword [ebp - 0x38]
test ecx, ecx
jne 0x45a4a8
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3a93
push 0x5d3a8e
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a49d
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3aa1
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
xor edx, edx
xor ecx, ecx
mov dword [ebp - 0x64], edx
mov word [ebp - 0x14], 8
mov dword [ebp - 0x574], 0xc
mov dword [ebp - 0x570], ecx
mov dword [ebp - 0x56c], 1
push 0xffffeeee
push 0xffffeeee
push 0x5d3ab4
push 0x5d3aaf
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
lea edx, [ebp - 0x64]
push edx
push 1
push 2
lea ecx, [ebp - 0x574]
push ecx
push 0x2000000
mov eax, dword [ebp - 0x38]
push eax
call sub.ADVAPI32.dll_DuplicateTokenEx
mov edx, dword [ebp - 0x64]
test edx, edx
je 0x45a542
push 0xffffeeee
push 0xffffeeee
push 0x5d3ac3
push 0x5d3abe
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x38]
push eax
call sub.KERNEL32.dll_CloseHandle
mov edx, dword [ebp - 0x64]
mov dword [ebp - 0x38], edx
push 0xffffeeee
push 0xffffeeee
push 0x5d3ad2
push 0x5d3acd
mov eax, dword [ebp + 0x20]
mov esi, 0xc
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp - 0x28]
cmp edx, 0xffffffff
je 0x45a6a5
mov dword [ebp - 0x2c], 0xffffffff
lea ecx, [ebp - 0x30]
lea eax, [ebp - 0x2c]
push ecx
push 4
push eax
push esi
mov edx, dword [ebp - 0x38]
push edx
call sub.ADVAPI32.dll_GetTokenInformation
test eax, eax
jne 0x45a5af
push esi
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3ade
push 0x5d3ad9
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x28]
push eax
mov edx, dword [ebp - 0x2c]
push edx
push 0x5d3aef
push 0x5d3aea
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
push 0x5d3afa
call fcn.004036e4
pop ecx
mov dword [ebp - 0x4c], eax
push 1
push 0x5d3b09
call fcn.004038c8
add esp, 8
push 4
lea eax, [ebp - 0x28]
push eax
push esi
mov edx, dword [ebp - 0x38]
push edx
call sub.ADVAPI32.dll_SetTokenInformation
test eax, eax
jne 0x45a61d
push esi
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3b1d
push 0x5d3b18
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
jmp 0x45a63a
push esi
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3b2d
push 0x5d3b28
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp - 0x4c]
push edx
push 0x5d3b33
call fcn.004038c8
add esp, 8
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x2c], 0xffffffff
push ecx
lea eax, [ebp - 0x2c]
push 4
push eax
push esi
mov edx, dword [ebp - 0x38]
push edx
call sub.ADVAPI32.dll_GetTokenInformation
test eax, eax
jne 0x45a687
push esi
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3b47
push 0x5d3b42
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x28]
push eax
mov edx, dword [ebp - 0x2c]
push edx
push 0x5d3b59
push 0x5d3b54
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
push 0xffffeeee
push 0xffffeeee
push 0x5d3b6a
push 0x5d3b65
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
call sub.USER32.dll_GetProcessWindowStation
mov dword [ebp - 0x48], eax
test eax, eax
jne 0x45a715
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3b7c
push 0x5d3b77
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a70a
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3b8d
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3b9e
push 0x5d3b99
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
push 0x60000
push 1
push 0x5d3bac
call sub.USER32.dll_OpenWindowStationA
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x44]
test eax, eax
jne 0x45a794
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3bb9
push 0x5d3bb4
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a789
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3bcb
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3bdc
push 0x5d3bd7
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x44]
push eax
call sub.USER32.dll_SetProcessWindowStation
test eax, eax
jne 0x45a805
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3bee
push 0x5d3be9
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a7fa
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3bff
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3c10
push 0x5d3c0b
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
push 0x10000000
push 0
push 0
push 0x5d3c1c
call sub.USER32.dll_OpenDesktopA
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x40]
test eax, eax
jne 0x45a886
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3c29
push 0x5d3c24
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a87b
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3c39
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3c4a
push 0x5d3c45
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x48]
push eax
call sub.USER32.dll_SetProcessWindowStation
test eax, eax
jne 0x45a8f7
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3c60
push 0x5d3c5b
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a8ec
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3c75
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3c86
push 0x5d3c81
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp + 0x20]
lea edx, [ebp - 0x464]
push eax
push 0x400
push edx
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.00444b70
add esp, 0x10
test eax, eax
jne 0x45a97b
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3c99
push 0x5d3c94
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a970
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3caa
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
push 0xffffeeee
push 0x5d3cbb
push 0x5d3cb6
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
mov ecx, dword [ebp + 0x20]
push ecx
lea eax, [ebp - 0x464]
push eax
mov edx, dword [ebp - 0x44]
push edx
call fcn.0045ade4
add esp, 0xc
test eax, eax
jne 0x45a9ef
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3cd0
push 0x5d3ccb
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45a9ef
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3ce4
push ebx
call fcn.004d1ac0
add esp, 0xc
push 0xffffeeee
push 0xffffeeee
push 0x5d3cf5
push 0x5d3cf0
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp + 0x20]
push edx
lea ecx, [ebp - 0x464]
push ecx
mov eax, dword [ebp - 0x40]
push eax
call fcn.0045b28c
add esp, 0xc
test eax, eax
jne 0x45aa63
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d08
push 0x5d3d03
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45aa63
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d1a
push ebx
call fcn.004d1ac0
add esp, 0xc
lea ecx, [ebp - 0x54]
lea eax, [ebp - 0x568]
push ecx
push eax
mov edx, dword [ebp - 0x38]
push edx
call fcn.004459ec
add esp, 0xc
test eax, eax
jne 0x45aa9f
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d2b
push 0x5d3d26
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
push 0xffffeeee
push 0xffffeeee
push 0x5d3d42
push 0x5d3d3d
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
lea edx, [ebp - 0x50]
lea ecx, [ebp - 0x38]
push 0
push edx
push ecx
push edi
call fcn.00445740
add esp, 0x10
test eax, eax
je 0x45aaf7
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d57
push 0x5d3d52
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
push 0xffffeeee
push 0xffffeeee
push 0x5d3d70
push 0x5d3d6b
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
push 1
mov ecx, dword [ebp - 0x38]
push ecx
lea eax, [ebp - 0x58]
push eax
call fcn.004575e8
add esp, 0xc
test eax, eax
je 0x45ab57
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d81
push 0x5d3d7c
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
or dword [ebp - 0x34], 0x400
jmp 0x45ab7d
xor ecx, ecx
mov dword [ebp - 0x58], ecx
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3d9a
push 0x5d3d95
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp - 0x38]
test edx, edx
je 0x45ab8d
mov ecx, dword [ebp - 0x38]
push ecx
call sub.ADVAPI32.dll_ImpersonateLoggedOnUser
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3dbb
push 0x5d3db6
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
push 0x5d3dca
mov edx, dword [ebp - 0x58]
push edx
mov ecx, dword [ebp - 0x34]
push ecx
mov eax, dword [ebp + 0x18]
push eax
mov edx, dword [ebp + 0x14]
push edx
push 0
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.00457278
add esp, 0x1c
test eax, eax
jne 0x45ac22
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x45abe1
call sub.ADVAPI32.dll_RevertToSelf
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3ddf
push 0x5d3dda
mov edx, dword [ebp + 0x20]
push edx
call fcn.00457050
add esp, 0x14
test ebx, ebx
je 0x45ac1a
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3df2
push ebx
call fcn.004d1ac0
add esp, 0xc
mov word [ebp - 0x14], 0
jmp 0x45ac95
mov ecx, dword [ebp - 0x38]
test ecx, ecx
je 0x45ac2e
call sub.ADVAPI32.dll_RevertToSelf
mov dword [ebp - 0x60], 1
test ebx, ebx
je 0x45ac4d
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3dfe
push ebx
call fcn.004d1ac0
add esp, 0xc
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3e0f
push 0x5d3e0a
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov word [ebp - 0x14], 0
jmp 0x45ac95
push 0xffffeeee
call sub.KERNEL32.dll_GetLastError
push eax
push 0x5d3e2a
push 0x5d3e25
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov word [ebp - 0x14], 0x14
push 0xffffeeee
push 0xffffeeee
push 0x5d3e37
push 0x5d3e32
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp - 0x58]
test edx, edx
je 0x45aced
lea ecx, [ebp - 0x58]
push ecx
call fcn.00457640
pop ecx
push 0xffffeeee
push 0xffffeeee
push 0x5d3e47
push 0x5d3e42
mov eax, dword [ebp + 0x20]
push eax
call fcn.00457050
add esp, 0x14
mov edx, dword [ebp - 0x48]
test edx, edx
je 0x45ad1d
mov ecx, dword [ebp - 0x48]
push ecx
call sub.USER32.dll_SetProcessWindowStation
mov eax, dword [ebp - 0x44]
test eax, eax
je 0x45ad2d
mov edx, dword [ebp - 0x44]
push edx
call sub.USER32.dll_CloseWindowStation
mov ecx, dword [ebp - 0x40]
test ecx, ecx
je 0x45ad3d
mov eax, dword [ebp - 0x40]
push eax
call sub.USER32.dll_CloseDesktop
push 0
lea edx, [ebp - 0x50]
push edx
lea ecx, [ebp - 0x38]
push ecx
call fcn.00445764
add esp, 0xc
mov eax, dword [ebp - 0x38]
test eax, eax
je 0x45ad5f
mov edx, dword [ebp - 0x38]
push edx
call sub.KERNEL32.dll_CloseHandle
mov ecx, dword [ebp - 0x3c]
test ecx, ecx
je 0x45ad6f
mov eax, dword [ebp - 0x3c]
push eax
call sub.KERNEL32.dll_CloseHandle
mov word [ebp - 0x14], 0
jmp 0x45ad96
push 0xffffeeee
push 0xffffeeee
push 0x5d3e64
push 0x5d3e5f
mov ecx, dword [ebp + 0x20]
push ecx
call fcn.00457050
add esp, 0x14
mov eax, dword [ebp - 0x60]
mov edx, dword [ebp - 0x24]
mov dword fs:[0], edx
mov esp, ebp
mov edi, dword [ebp - 0x580]
mov esi, dword [ebp - 0x57c]
mov ebx, dword [ebp - 0x578]
pop ebp
ret