Function at 0x405120
Capabilities:
Create thread
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48d930
mov eax, dword fs:[0]
push eax
sub esp, 0x80
mov eax, dword [0x5a7f20]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0xc]
xor esi, esi
mov dword [ebp - 0x8c], eax
mov ebx, 0x5a9d70
mov dword [ebp - 0x80], esi
mov dword [ebp - 4], esi
call fcn.00404440
call fcn.004044c0
push 0x404068
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov dword [ebp - 0x7c], eax
cmp eax, esi
je 0x40558d
mov ecx, dword [0x404074]
mov dword [ebp - 0x2c], ecx
mov cx, word [0x404080]
mov edx, dword [0x404078]
mov word [ebp - 0x20], cx
mov eax, dword [0x40407c]
mov ecx, 5
mov esi, 0x40408c
lea edi, [ebp - 0x5c]
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [0x4040a4]
movsw word es:[edi], word [esi]
mov dword [ebp - 0x44], ecx
mov ecx, dword [0x4040b0]
movsb byte es:[edi], byte [esi]
mov dword [ebp - 0x38], ecx
mov ecx, 6
mov esi, 0x4040bc
lea edi, [ebp - 0x78]
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x28], edx
mov edx, dword [0x404084]
mov dword [ebp - 0x24], eax
mov eax, dword [0x404088]
mov dword [ebp - 0x1c], edx
mov edx, dword [0x4040a8]
mov dword [ebp - 0x18], eax
mov eax, dword [0x4040ac]
mov dword [ebp - 0x40], edx
mov edx, dword [0x4040b4]
mov dword [ebp - 0x3c], eax
mov al, byte [0x4040b8]
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x34], edx
mov byte [ebp - 0x30], al
movsw word es:[edi], word [esi]
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x405220
sub ecx, edx
lea esi, [ebp + ecx - 0x2c]
lea ecx, [ebp - 0x2c]
cmp ecx, esi
je 0x405244
dec esi
cmp ecx, esi
je 0x405244
mov al, byte [ecx]
mov dl, byte [esi]
mov byte [ecx], dl
mov byte [esi], al
inc ecx
jmp 0x405230
lea ecx, [ebp - 0x1c]
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x405250
sub ecx, edx
lea esi, [ebp + ecx - 0x1c]
lea ecx, [ebp - 0x1c]
cmp ecx, esi
je 0x405274
dec esi
cmp ecx, esi
je 0x405274
mov al, byte [ecx]
mov dl, byte [esi]
mov byte [ecx], dl
mov byte [esi], al
inc ecx
jmp 0x405260
lea ecx, [ebp - 0x5c]
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x405280
sub ecx, edx
lea esi, [ebp + ecx - 0x5c]
lea ecx, [ebp - 0x5c]
cmp ecx, esi
je 0x4052a4
dec esi
cmp ecx, esi
je 0x4052a4
mov al, byte [ecx]
mov dl, byte [esi]
mov byte [ecx], dl
mov byte [esi], al
inc ecx
jmp 0x405290
lea ecx, [ebp - 0x44]
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4052b0
sub ecx, edx
lea esi, [ebp + ecx - 0x44]
lea ecx, [ebp - 0x44]
cmp ecx, esi
je 0x4052d4
dec esi
cmp ecx, esi
je 0x4052d4
mov al, byte [ecx]
mov dl, byte [esi]
mov byte [ecx], dl
mov byte [esi], al
inc ecx
jmp 0x4052c0
lea ecx, [ebp - 0x78]
lea edx, [ecx + 1]
lea ebx, [ebx]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4052e0
sub ecx, edx
lea esi, [ebp + ecx - 0x78]
lea ecx, [ebp - 0x78]
cmp ecx, esi
je 0x405304
dec esi
cmp ecx, esi
je 0x405304
mov dl, byte [ecx]
mov al, byte [esi]
mov byte [ecx], al
mov byte [esi], dl
inc ecx
jmp 0x4052f0
mov edx, dword [ebp - 0x7c]
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
lea ecx, [ebp - 0x2c]
push ecx
push edx
call esi
mov edi, dword [ebp - 0x7c]
mov dword [ebx], eax
lea eax, [ebp - 0x1c]
push eax
push edi
call esi
lea ecx, [ebp - 0x5c]
push ecx
push edi
mov dword [ebx + 4], eax
call esi
lea edx, [ebp - 0x44]
push edx
push edi
mov dword [ebx + 8], eax
call esi
mov dword [ebx + 0xc], eax
lea eax, [ebp - 0x78]
push eax
push edi
call esi
xor esi, esi
mov dword [ebx + 0x10], eax
cmp dword [ebx], esi
je 0x40558d
cmp dword [ebx + 4], esi
je 0x40558d
cmp dword [ebx + 8], esi
je 0x40558d
cmp dword [ebx + 0xc], esi
je 0x40558d
cmp eax, esi
je 0x40558d
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
lea ecx, [ebp - 0x88]
push ecx
push eax
mov dword [ebx + 0x58], eax
mov dword [ebp - 0x88], esi
call dword [sym.imp.KERNEL32.dll_ProcessIdToSessionId]
test eax, eax
je 0x40558d
lea eax, [ebx + 0x5c]
push eax
call fcn.004045c0
cmp eax, esi
je 0x40558d
mov eax, 1
mov dword [ebp - 0x7c], eax
xor edi, edi
mov dword [ebp - 0x84], edi
cmp edi, dword [ebx + 0x60]
jae 0x405582
cmp eax, esi
je 0x40558d
cmp dword [ebp + 8], esi
jne 0x4053e3
mov eax, edi
lea ecx, [ebx + 0x5c]
call fcn.00405f80
mov edx, dword [eax + 0xc]
cmp edx, dword [ebp - 0x88]
jne 0x405577
cmp edi, dword [ebx + 0x60]
jb 0x4053f2
push 0x80070057
call fcn.004062b0
mov ecx, dword [ebx + 0x5c]
lea eax, [edi + edi*2]
add eax, eax
add eax, eax
add eax, eax
mov ecx, dword [ecx + eax]
mov dword [ebx + 0x54], ecx
cmp edi, dword [ebx + 0x60]
jb 0x405413
push 0x80070057
call fcn.004062b0
mov ecx, dword [ebx + 0x5c]
mov edx, dword [ecx + eax + 0x10]
mov dword [ebx + 0x6c], edx
cmp edi, dword [ebx + 0x60]
jb 0x40542c
push 0x80070057
call fcn.004062b0
mov ecx, dword [ebx + 0x5c]
mov edx, dword [eax + ecx + 0x14]
push esi
push esi
push ebx
push 0x404cc0
push esi
push esi
mov dword [ebx + 0x70], edx
mov dword [ebx + 0x50], esi
mov dword [ebx + 0x34], esi
call fcn.00482014
mov esi, dword [ebp - 0x8c]
push 0
push 0
push ebx
push 0x404d90
push 0
push 0
mov dword [esi], eax
call fcn.00482014
mov ecx, dword [esi]
add esp, 0x30
mov dword [esi + 4], eax
test ecx, ecx
je 0x405477
cmp ecx, 0xffffffff
jne 0x405488
test eax, eax
je 0x405524
cmp eax, 0xffffffff
je 0x405524
mov edi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0x1388
push eax
call edi
test eax, eax
je 0x4054a1
mov dword [ebp - 0x7c], 0
push 0
push 0
push ebx
push 0x404ea0
push 0
push 0
call fcn.00482014
add esp, 0x18
mov dword [esi + 8], eax
test eax, eax
je 0x4054cf
cmp eax, 0xffffffff
je 0x4054cf
push 0x1388
push eax
call edi
test eax, eax
je 0x4054d6
mov dword [ebp - 0x7c], 0
lea edi, [ebx + 0x38]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push edi
mov dword [ebx + 0x50], 1
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea edi, [ebx + 0x1c]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push edi
mov dword [ebx + 0x34], 1
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0xffffffffffffffff
push 1
push esi
push 3
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov eax, dword [ebx + 0x54]
push eax
call fcn.00404c10
mov edi, dword [ebp - 0x84]
jmp 0x40552b
mov dword [ebp - 0x7c], 0
mov eax, dword [esi + 8]
test eax, eax
je 0x405545
cmp eax, 0xffffffff
je 0x405545
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 8], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x40555f
cmp eax, 0xffffffff
je 0x40555f
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 4], 0
mov eax, dword [esi]
test eax, eax
je 0x405577
cmp eax, 0xffffffff
je 0x405577
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi], 0
mov eax, dword [ebp - 0x7c]
inc edi
xor esi, esi
jmp 0x4053ae
cmp eax, esi
je 0x40558d
mov dword [ebp - 0x80], 1
mov eax, dword [ebp - 0x80]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00480aee
mov esp, ebp
pop ebp
ret 8