Function at 0x515bd0
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov dword [ebp - 0x3c], ecx
mov eax, dword [ebp - 0x3c]
cmp dword [eax + 0x14], 0
jne 0x515be9
xor eax, eax
jmp 0x5160d0
mov ecx, dword [ebp - 0x3c]
add ecx, 0x70
call fcn.005134f0
test eax, eax
jne 0x515bff
xor eax, eax
jmp 0x5160d0
push 0
push 0
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 8], eax
mov edx, dword [ebp - 0x3c]
cmp dword [edx + 8], 0
jne 0x515c23
xor eax, eax
jmp 0x5160d0
push 0
push 0
mov eax, dword [ebp - 0x3c]
push eax
push 0x519af0
push 0
push 0
call fcn.005361ba
add esp, 0x18
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x515c51
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x515c6f
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 8], 0
xor eax, eax
jmp 0x5160d0
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x68], eax
mov eax, dword [ebp - 0x3c]
cmp dword [eax + 0x68], 0
jne 0x515caa
mov ecx, dword [ebp - 0x3c]
mov edx, dword [ecx + 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x3c]
mov dword [eax + 8], 0
xor eax, eax
jmp 0x5160d0
push 0
push 0
mov ecx, dword [ebp - 0x3c]
push ecx
push 0x51a9c0
push 0
push 0
call fcn.005361ba
add esp, 0x18
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x515cd8
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x515d0d
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x68]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x68], 0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 8], 0
xor eax, eax
jmp 0x5160d0
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0x16c], eax
mov edx, dword [ebp - 0x3c]
cmp dword [edx + 0x16c], 0
jne 0x515d65
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 8], 0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x68]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x68], 0
xor eax, eax
jmp 0x5160d0
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0x190], eax
mov edx, dword [ebp - 0x3c]
cmp dword [edx + 0x190], 0
jne 0x515dda
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 8], 0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x68]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x68], 0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x16c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x16c], 0
xor eax, eax
jmp 0x5160d0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp + 8]
mov dword [eax + 0x170], ecx
mov edx, dword [ebp - 0x3c]
mov eax, dword [ebp + 0xc]
mov dword [edx + 0x174], eax
push str.192.168.0.1
call dword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0xe4], eax
push str.192.168.0.100
call dword [sym.imp.WS2_32.dll_inet_addr]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0xe8], eax
push 0x57cbd8
call dword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0xec], eax
push str.192.168.1.1
call dword [sym.imp.WS2_32.dll_inet_addr]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0xf0], eax
push str.192.168.1.100
call dword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0xf4], eax
push str.255.255.255.0
call dword [sym.imp.WS2_32.dll_inet_addr]
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0xf8], eax
mov dword [ebp - 0x18], 0
jmp 0x515e7c
mov eax, dword [ebp - 0x18]
add eax, 1
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 6
jge 0x515f19
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
je 0x515f14
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x3c]
lea eax, [edx + ecx*8 + 0x80]
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
mov dword [ecx], edx
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x3c]
mov dword [eax + 4], ecx
push 0
push 0
mov edx, dword [ebp - 0x20]
push edx
push 0x516ca0
push 0
push 0
call fcn.005361ba
add esp, 0x18
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
je 0x515f14
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x134]
add ecx, 1
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x134], ecx
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x130]
add ecx, 1
mov edx, dword [ebp - 0x3c]
mov dword [edx + 0x130], ecx
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x515e73
mov dword [ebp - 0x28], 0
jmp 0x515f2b
mov ecx, dword [ebp - 0x28]
add ecx, 1
mov dword [ebp - 0x28], ecx
cmp dword [ebp - 0x28], 4
jge 0x515f5f
push 0
push 0
mov edx, dword [ebp - 0x3c]
push edx
push 0x517a40
push 0
push 0
call fcn.005361ba
add esp, 0x18
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
je 0x515f5d
mov eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x515f22
push 0
push 0
mov ecx, dword [ebp - 0x3c]
push ecx
push 0x51b020
push 0
push 0
call fcn.005361ba
add esp, 0x18
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
je 0x515f8b
mov edx, dword [ebp - 0x30]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x10], 0
lea ecx, [ebp - 4]
call fcn.0051df80
lea ecx, [ebp - 4]
call fcn.0051dfd0
push eax
push 0x575ac0
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x14]
call ecx
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jl 0x516022
push 0
lea ecx, [ebp - 4]
call fcn.0051dff0
movzx edx, al
test edx, edx
je 0x516022
lea ecx, [ebp - 4]
call fcn.0051dfe0
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x3c]
add eax, 0x22c
push eax
push 0x575af0
mov ecx, dword [ebp - 0x40]
push ecx
mov edx, dword [ebp - 0x40]
mov eax, dword [edx]
mov ecx, dword [eax]
call ecx
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jl 0x516022
mov edx, dword [ebp - 0x3c]
cmp dword [edx + 0x22c], 0
je 0x516022
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x22c]
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 0x22c]
mov ecx, dword [ecx]
push eax
mov edx, dword [ecx + 0x14]
call edx
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x51609d
mov eax, dword [ebp - 0x3c]
cmp dword [eax + 0x22c], 0
je 0x51605b
mov ecx, dword [ebp - 0x3c]
mov edx, dword [ecx + 0x22c]
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x22c]
mov edx, dword [edx]
push ecx
mov eax, dword [edx + 8]
call eax
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0x22c], 0
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 8], 0
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx + 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x3c]
mov dword [ecx + 0x68], 0
mov dword [ebp - 0x34], 0
lea ecx, [ebp - 4]
call fcn.0051bf30
mov eax, dword [ebp - 0x34]
jmp 0x5160d0
mov edx, dword [ebp - 0x3c]
add edx, 0x234
push edx
push 0x575a90
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax + 0x14]
call ecx
mov edx, dword [ebp - 0x3c]
mov dword [edx + 4], 1
mov dword [ebp - 0x38], 1
lea ecx, [ebp - 4]
call fcn.0051bf30
mov eax, dword [ebp - 0x38]
mov esp, ebp
pop ebp
ret 8