Function at 0x4032c0
Capabilities:
Connect socket
Initialize winsock library
Resolve dns
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44286d
mov eax, dword fs:[0]
push eax
sub esp, 0x49c
mov eax, dword [0x45a070]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x2a0], eax
mov dword [ebp - 0x304], 0
mov dword [ebp - 0x300], 0
mov dword [ebp - 0x2fc], 0
push ecx
lea ecx, [ebp - 0x4a8]
mov dword [ebp - 4], 0
call fcn.00404f30
xor esi, esi
xor edi, edi
mov dword [ebp - 0x2b4], edi
mov dword [ebp - 0x2b0], esi
mov dword [ebp - 0x2ac], esi
mov eax, dword [ebp + 8]
xor edx, edx
mov byte [ebp - 4], 2
mov dword [ebp - 0x29c], edx
test eax, eax
jle 0x40351c
mov dword [ebp - 0x2a8], edx
nop word [eax + eax]
mov eax, dword [ebp - 0x2a0]
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
mov edx, dword [eax + edx*4]
cmp byte [edx], 0
jne 0x403384
xor ecx, ecx
jmp 0x40339d
mov ecx, edx
lea eax, [ecx + 1]
mov dword [ebp - 0x2b8], eax
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403390
sub ecx, dword [ebp - 0x2b8]
push ecx
push edx
lea ecx, [ebp - 0x28]
call fcn.00407c90
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 3
cmp eax, esi
jae 0x4033f7
cmp edi, eax
ja 0x4033f7
mov ecx, eax
mov eax, 0x2aaaaaab
sub ecx, edi
imul ecx
sar edx, 2
mov edi, edx
shr edi, 0x1f
add edi, edx
cmp esi, dword [ebp - 0x2ac]
jne 0x4033e5
push ecx
lea ecx, [ebp - 0x2b4]
call fcn.00406f80
mov esi, dword [ebp - 0x2b0]
lea eax, [edi + edi*2]
mov edi, dword [ebp - 0x2b4]
lea eax, [edi + eax*8]
test esi, esi
je 0x403426
jmp 0x40341e
cmp esi, dword [ebp - 0x2ac]
jne 0x403417
push ecx
lea ecx, [ebp - 0x2b4]
call fcn.00406f80
mov esi, dword [ebp - 0x2b0]
mov edi, dword [ebp - 0x2b4]
test esi, esi
je 0x403426
lea eax, [ebp - 0x28]
push eax
mov ecx, esi
call fcn.00404e50
add esi, 0x18
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x2b0], esi
cmp eax, 0x10
jb 0x403479
mov ecx, dword [ebp - 0x28]
inc eax
cmp eax, 0x1000
jb 0x403470
test cl, 0x1f
jne 0x403532
mov eax, dword [ecx - 4]
cmp eax, ecx
jae 0x403532
sub ecx, eax
cmp ecx, 4
jb 0x403532
cmp ecx, 0x23
ja 0x403532
mov ecx, eax
push ecx
call fcn.0040f89a
add esp, 4
mov edx, dword [ebp - 0x29c]
cmp edx, 3
je 0x403503
add edi, dword [ebp - 0x2a8]
cmp dword [edi + 0x14], 0x10
jb 0x40349e
mov eax, dword [edi]
mov dword [ebp - 0x2d4], eax
jmp 0x4034a4
mov dword [ebp - 0x2d4], edi
cmp dword [edi + 0x14], 0x10
jb 0x4034ae
mov ecx, dword [edi]
jmp 0x4034b0
mov ecx, edi
mov eax, dword [edi + 0x10]
add eax, ecx
cmp dword [edi + 0x14], 0x10
jb 0x4034bd
mov edi, dword [edi]
xor esi, esi
mov ecx, eax
sub ecx, edi
cmp edi, eax
cmova ecx, esi
mov dword [ebp - 0x2b8], ecx
test ecx, ecx
je 0x4034f7
movsx eax, byte [esi + edi]
push eax
call fcn.0042af7d
mov ecx, dword [ebp - 0x2d4]
add esp, 4
mov byte [esi + ecx], al
inc esi
cmp esi, dword [ebp - 0x2b8]
jne 0x4034d2
mov edx, dword [ebp - 0x29c]
mov edi, dword [ebp - 0x2b4]
mov esi, dword [ebp - 0x2b0]
add dword [ebp - 0x2a8], 0x18
inc edx
mov eax, dword [ebp + 8]
mov dword [ebp - 0x29c], edx
cmp edx, eax
jl 0x403360
cmp eax, 1
jle 0x403622
cmp dword [edi + 0x2c], 0x10
lea eax, [edi + 0x18]
jb 0x403537
mov edx, dword [eax]
jmp 0x403539
call fcn.0042c649
mov edx, eax
mov esi, dword [eax + 0x10]
mov ecx, 9
cmp esi, ecx
mov dword [ebp - 0x2a0], esi
cmovb ecx, esi
test ecx, ecx
je 0x4035b9
mov esi, str.__version
sub ecx, 4
jb 0x403571
nop word [eax + eax]
mov eax, dword [edx]
cmp eax, dword [esi]
jne 0x403576
add edx, 4
add esi, 4
sub ecx, 4
jae 0x403560
cmp ecx, 0xfffffffc
je 0x4035aa
mov al, byte [edx]
cmp al, byte [esi]
jne 0x4035a3
cmp ecx, 0xfffffffd
je 0x4035aa
mov al, byte [edx + 1]
cmp al, byte [esi + 1]
jne 0x4035a3
cmp ecx, 0xfffffffe
je 0x4035aa
mov al, byte [edx + 2]
cmp al, byte [esi + 2]
jne 0x4035a3
cmp ecx, 0xffffffff
je 0x4035aa
mov al, byte [edx + 3]
cmp al, byte [esi + 3]
je 0x4035aa
sbb eax, eax
or eax, 1
jmp 0x4035ac
xor eax, eax
test eax, eax
lea eax, [edi + 0x18]
jne 0x4035c0
mov esi, dword [ebp - 0x2a0]
cmp esi, 9
jb 0x4035c0
jbe 0x4035e2
cmp dword [eax + 0x14], 0x10
lea edx, [eax + 0x10]
jb 0x4035cb
mov eax, dword [eax]
mov edx, dword [edx]
mov ecx, eax
push 4
push str._ver
call fcn.00407a90
add esp, 8
test eax, eax
jne 0x40361f
mov edx, 0x45252c
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, 0x452630
mov ecx, eax
call fcn.0040a8d0
mov edx, 0x452538
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
xor esi, esi
jmp 0x403a29
mov eax, dword [ebp + 8]
cmp eax, 3
jle 0x40392b
cmp dword [edi + 0x5c], 0x10
lea ecx, [edi + 0x48]
jb 0x403636
mov ecx, dword [ecx]
lea eax, [ebp - 0x2e0]
push eax
lea eax, [ebp - 0x304]
push eax
lea edx, [ebp - 0x2c4]
call fcn.0040c5a0
add esp, 8
test al, al
jne 0x403679
mov edx, str.could_not_open_read_firmware_file_or_firmware_file_is_broken
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
jmp 0x403a24
mov edi, 4
mov byte [ebp - 0x2a4], 0
mov byte [ebp - 0x2d4], 0
mov byte [ebp - 0x28e], 0
mov byte [ebp - 0x28d], 0
mov byte [ebp - 0x290], 0
mov byte [ebp - 0x28f], 0
mov byte [ebp - 0x2a1], 0
mov dword [ebp - 0x2b8], 0xffffffff
mov dword [ebp - 0x308], 0xffffffff
mov byte [ebp - 0x286], 0
cmp dword [ebp + 8], edi
jle 0x403cbd
mov esi, dword [ebp - 0x2b4]
nop dword [eax]
lea eax, [edi + edi*2]
mov byte [ebp - 0x285], 0
shl eax, 3
add esi, eax
mov dword [ebp - 0x294], eax
cmp dword [esi + 0x14], 0x10
jb 0x4036ff
mov ecx, dword [esi]
jmp 0x403701
mov ecx, esi
mov edx, dword [esi + 0x10]
push 6
push str._force
call fcn.00407a90
add esp, 8
test eax, eax
je 0x40373a
cmp dword [esi + 0x14], 0x10
jb 0x403721
mov ecx, dword [esi]
jmp 0x403723
mov ecx, esi
push 2
push 0x452818
call fcn.00407a90
add esp, 8
test eax, eax
jne 0x403816
mov eax, dword [ebp + 8]
dec eax
cmp edi, eax
jge 0x403816
add esi, 0x18
cmp dword [esi + 0x14], 0x10
jb 0x403753
mov ecx, dword [esi]
jmp 0x403755
mov ecx, esi
mov edx, dword [esi + 0x10]
push 3
push 0x45281c
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403803
cmp dword [esi + 0x14], 0x10
jb 0x403779
mov ecx, dword [esi]
jmp 0x40377b
mov ecx, esi
push 1
push 0x452820
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403803
cmp dword [esi + 0x14], 0x10
lea edx, [esi + 0x10]
jb 0x403799
mov esi, dword [esi]
mov edx, dword [edx]
mov ecx, esi
push 6
push str.server
call fcn.00407a90
add esp, 8
test eax, eax
je 0x4037f7
mov ecx, dword [ebp - 0x294]
mov edx, 0x45282c
mov esi, dword [ebp - 0x2b4]
add ecx, 0x18
add esi, ecx
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x4037f7
mov edx, str.repeater
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x40380a
mov edx, 0x45283c
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x40380a
dec edi
jmp 0x40391d
mov byte [ebp - 0x28e], 1
jmp 0x403916
mov byte [ebp - 0x28e], 1
mov byte [ebp - 0x28d], 1
jmp 0x403916
cmp dword [esi + 0x14], 0x10
jb 0x403820
mov ecx, dword [esi]
jmp 0x403822
mov ecx, esi
push 7
push str._ignore
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403858
cmp dword [esi + 0x14], 0x10
jb 0x40383f
mov ecx, dword [esi]
jmp 0x403841
mov ecx, esi
push 2
push 0x452848
call fcn.00407a90
add esp, 8
test eax, eax
jne 0x403a67
mov eax, dword [ebp + 8]
dec eax
cmp edi, eax
jge 0x403a67
add esi, 0x18
cmp dword [esi + 0x14], 0x10
jb 0x403871
mov ecx, dword [esi]
jmp 0x403873
mov ecx, esi
mov edx, dword [esi + 0x10]
push 3
push 0x45281c
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403908
cmp dword [esi + 0x14], 0x10
lea edx, [esi + 0x10]
jb 0x403894
mov esi, dword [esi]
mov edx, dword [edx]
mov ecx, esi
push 1
push 0x452820
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403908
mov ecx, dword [ebp - 0x294]
mov edx, str.server
mov esi, dword [ebp - 0x2b4]
add ecx, 0x18
add esi, ecx
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x4038ff
mov edx, 0x45282c
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x4038ff
mov edx, str.repeater
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x40390f
mov edx, 0x45283c
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x40390f
dec edi
jmp 0x40391d
mov byte [ebp - 0x290], 1
jmp 0x403916
mov byte [ebp - 0x290], 1
mov byte [ebp - 0x28f], 1
mov byte [ebp - 0x285], 1
inc edi
cmp byte [ebp - 0x285], 0
jne 0x403cad
mov edx, str.usage:
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, 0x45252c
mov ecx, eax
call fcn.0040a8d0
mov edx, str._ipurl_port51117_firmware_file__options_
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
mov edx, str.options:
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.____f_orce__a_ll_s_erver_r_epeater_
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.____i_gnore__a_ll_s_erver_r_epeater_
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.____r_estart__s_erver_r_epeater__x_seconds__default_30s_
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.____d_evice__single_device_id
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov ecx, eax
mov edx, str.____a_llowdowngrade_
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.____n_oupdate_
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
mov edx, str.return_values
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.___0__success__1__programming_parameter_error__2__network_error
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov edx, str.___3__success__server_power_cycle_scheduled
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 0x38
mov esi, 1
lea ecx, [ebp - 0x2b4]
call fcn.00404b50
lea ecx, [ebp - 0x4a8]
call fcn.00404a60
lea ecx, [ebp - 0x304]
call fcn.004078c0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040f3ad
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0x14], 0x10
jb 0x403a71
mov ecx, dword [esi]
jmp 0x403a73
mov ecx, esi
push 8
push str._restart
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403aa9
cmp dword [esi + 0x14], 0x10
jb 0x403a90
mov ecx, dword [esi]
jmp 0x403a92
mov ecx, esi
push 2
push 0x452858
call fcn.00407a90
add esp, 8
test eax, eax
jne 0x403b84
mov eax, dword [ebp + 8]
add eax, 0xfffffffe
cmp edi, eax
jge 0x403b84
mov esi, dword [ebp - 0x2b4]
add edi, 2
lea eax, [edi + edi*2]
cmp dword [esi + eax*8 + 0x14], 0x10
lea eax, [esi + eax*8]
jb 0x403acf
mov eax, dword [eax]
push 0xa
push 0
push eax
call fcn.0042d541
add esp, 0xc
mov dword [ebp - 0x29c], eax
test eax, eax
je 0x403ceb
cmp eax, 0xe10
jg 0x40392b
cmp eax, 1
jl 0x40392b
lea ecx, [esi + 0x18]
mov edx, str.server
add ecx, dword [ebp - 0x294]
call fcn.0040ab80
test al, al
jne 0x403b73
lea ecx, [esi + 0x18]
mov edx, 0x45282c
add ecx, dword [ebp - 0x294]
call fcn.0040ab80
test al, al
jne 0x403b73
mov ecx, dword [ebp - 0x294]
mov edx, str.repeater
add ecx, 0x18
add ecx, esi
call fcn.0040ab80
test al, al
jne 0x403b62
mov ecx, dword [ebp - 0x294]
mov edx, 0x45283c
add ecx, 0x18
add ecx, esi
call fcn.0040ab80
test al, al
je 0x40392b
mov ecx, dword [ebp - 0x29c]
mov dword [ebp - 0x308], ecx
jmp 0x403cb3
mov ecx, dword [ebp - 0x29c]
mov dword [ebp - 0x2b8], ecx
jmp 0x403cb3
cmp dword [esi + 0x14], 0x10
jb 0x403b8e
mov ecx, dword [esi]
jmp 0x403b90
mov ecx, esi
push 7
push str._device
call fcn.00407a90
add esp, 8
test eax, eax
je 0x403c2a
cmp dword [esi + 0x14], 0x10
jb 0x403bb1
mov ecx, dword [esi]
jmp 0x403bb3
mov ecx, esi
push 2
push 0x452864
call fcn.00407a90
add esp, 8
test eax, eax
jne 0x403bce
mov eax, dword [ebp + 8]
dec eax
cmp edi, eax
jl 0x403c2a
mov edx, str._allowdowngrade
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x403c1e
mov edx, 0x452878
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x403c1e
mov edx, str._noupdate
mov ecx, esi
call fcn.0040ab80
test al, al
jne 0x403c12
mov edx, 0x452888
mov ecx, esi
call fcn.0040ab80
test al, al
je 0x40392b
mov byte [ebp - 0x2a4], 1
jmp 0x403cad
mov byte [ebp - 0x2a1], 1
jmp 0x403cad
cmp dword [esi + 0x2c], 0x10
lea ecx, [esi + 0x18]
mov byte [ebp - 0x286], 0
jb 0x403c3e
mov edx, dword [ecx]
jmp 0x403c40
mov edx, ecx
mov eax, dword [ecx + 0x10]
cmp byte [eax + edx - 1], 0x73
jne 0x403c6e
dec eax
cmp dword [ecx + 0x10], eax
jb 0x403cf5
cmp dword [ecx + 0x14], 0x10
mov dword [ecx + 0x10], eax
jb 0x403c61
mov edx, dword [ecx]
jmp 0x403c63
mov edx, ecx
mov byte [edx + eax], 0
mov byte [ebp - 0x286], 1
cmp dword [ecx + 0x14], 0x10
jb 0x403c76
mov ecx, dword [ecx]
lea edx, [ebp - 0x2a0]
call fcn.0040d0e0
test al, al
je 0x40392b
mov ecx, dword [ebp - 0x2a0]
lea eax, [ecx - 1]
cmp eax, 0xe
ja 0x40392b
mov dl, byte [ebp - 0x286]
shl dl, 4
or dl, cl
inc edi
mov byte [ebp - 0x286], dl
mov esi, dword [ebp - 0x2b4]
inc edi
cmp edi, dword [ebp + 8]
jl 0x4036e0
push ecx
lea ecx, [ebp - 0x304]
call fcn.0040c450
add esp, 4
mov dword [ebp - 0x2e0], eax
mov edx, str.updating_to_firmware_v
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, eax
test edx, edx
jne 0x403cfa
xor ecx, ecx
jmp 0x403d01
call fcn.0042cb9a
jmp 0x40392b
call fcn.00409e60
mov eax, dword [edx]
mov ecx, dword [eax + 4]
add ecx, edx
mov eax, dword [ecx + 0x14]
and eax, 0xfffff3ff
or eax, 0x200
mov dword [ecx + 0x14], eax
mov ecx, edx
movzx eax, word [ebp - 0x2c4]
push eax
movzx eax, word [ebp - 0x2c0]
push eax
movzx eax, byte [ebp - 0x2c1]
push eax
movzx eax, byte [ebp - 0x2c2]
push eax
call fcn.00406180
mov edx, 0x4528a0
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.00406180
mov edx, str._build
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.00406180
mov edx, str.__id
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.00406180
mov edx, 0x45288c
mov ecx, eax
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push 0x45d568
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x403dc2
mov edx, str.networking_error
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
add esp, 4
mov esi, 2
jmp 0x403a29
mov eax, dword [ebp - 0x2b4]
xorps xmm0, xmm0
movups xmmword [ebp - 0x33c], xmm0
lea ecx, [eax + 0x30]
mov dword [ebp - 0x324], 0
movq qword [ebp - 0x32c], xmm0
mov dword [ebp - 0x33c], 0
mov dword [ebp - 0x338], 1
mov dword [ebp - 0x340], 8
cmp dword [ecx + 0x14], 0x10
jb 0x403e0d
mov ecx, dword [ecx]
cmp dword [eax + 0x2c], 0x10
lea esi, [eax + 0x18]
mov dword [ebp - 0x2a0], esi
jb 0x403e20
mov eax, dword [esi]
jmp 0x403e22
mov eax, esi
lea edx, [ebp - 0x30c]
push edx
lea edx, [ebp - 0x340]
push edx
push ecx
push eax
call dword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
je 0x403e52
mov edx, str.could_not_resolve
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, esi
jmp 0x403ecf
mov esi, dword [ebp - 0x30c]
or edi, 0xffffffff
mov dword [ebp - 0x294], edi
test esi, esi
je 0x403eaf
push dword [esi + 0xc]
push dword [esi + 8]
push dword [esi + 4]
call dword [sym.imp.WS2_32.dll_socket]
mov edi, eax
mov dword [ebp - 0x294], edi
test edi, edi
js 0x403ea2
push dword [esi + 0x10]
push dword [esi + 0x18]
push edi
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jg 0x403ea9
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
or edi, 0xffffffff
mov dword [ebp - 0x294], edi
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x403e65
mov esi, dword [ebp - 0x30c]
push esi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test edi, edi
jns 0x403ef5
mov edx, str.could_not_establish_connection_to_middleware_on
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, dword [ebp - 0x2a0]
mov ecx, eax
call fcn.0040ac00
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov esi, 2
jmp 0x403a29
mov eax, dword [ebp - 0x300]
lea ecx, [ebp - 0xa0]
sub eax, dword [ebp - 0x304]
shr eax, 8
push eax
call fcn.004024b0
mov byte [ebp - 4], 4
mov dword [ebp - 0x60], 0
mov dword [ebp - 0x5c], 0
call fcn.0040a280
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x58]
push 2
push eax
call fcn.0040d89d
lea eax, [ebp - 0x154]
mov byte [ebp - 0x158], 0
push eax
call fcn.0040d4e2
lea eax, [ebp - 0x12c]
push 2
push eax
call fcn.0040d89d
lea eax, [ebp - 0xf8]
mov byte [ebp - 0xfc], 0
push eax
call fcn.0040d4e2
lea eax, [ebp - 0xd0]
push 2
push eax
call fcn.0040d89d
mov byte [ebp - 4], 7
lea eax, [ebp - 0xfc]
mov dword [ebp - 0x2a0], eax
lea ecx, [ebp - 0x298]
lea eax, [ebp - 0x158]
mov edx, 0x4027c0
mov dword [ebp - 0x28c], eax
lea eax, [ebp - 0x60]
mov dword [ebp - 0x29c], eax
lea eax, [ebp - 0xa0]
mov dword [ebp - 0x2a8], eax
lea eax, [ebp - 0x2a0]
push eax
lea eax, [ebp - 0x28c]
push eax
lea eax, [ebp - 0x29c]
push eax
lea eax, [ebp - 0x2a8]
push eax
lea eax, [ebp - 0x294]
push eax
call fcn.0040b960
add esp, 0x34
mov edx, eax
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x2f0]
call fcn.0040b9c0
mov eax, dword [ebp - 0x298]
test eax, eax
je 0x404004
push 0x18
push eax
call fcn.0040f89f
add esp, 8
mov byte [ebp - 4], 9
mov ecx, dword [ebp - 0x2ec]
test ecx, ecx
setne al
test al, al
jne 0x404027
push 1
call fcn.0040dbc5
mov ecx, dword [ebp - 0x2ec]
add esp, 4
push ecx
push dword [ebp - 0x2f0]
call fcn.0040e608
add esp, 8
test eax, eax
je 0x404043
push eax
call fcn.0040db98
add esp, 4
mov edi, dword [ebp - 0x294]
lea eax, [ebp - 0x2d0]
mov esi, dword [sym.imp.WS2_32.dll_send]
push 0
push 8
push eax
push edi
mov dword [ebp - 0x2f0], 0
mov dword [ebp - 0x2ec], 0
mov dword [ebp - 0x2d0], 0x57525121
mov dword [ebp - 0x2cc], 0xe0ff0008
call esi
test eax, eax
js 0x4040fb
push 0
push 8
lea eax, [ebp - 0x2d0]
mov dword [ebp - 0x2d0], 0x57525121
push eax
push edi
mov dword [ebp - 0x2cc], 0xe1ff0008
call esi
test eax, eax
js 0x4040fb
push 0
push 8
lea eax, [ebp - 0x2d0]
mov dword [ebp - 0x2d0], 0x57525121
push eax
push edi
mov dword [ebp - 0x2cc], 0xe2ff0008
call esi
test eax, eax
js 0x4040fb
push 0
push 8
lea eax, [ebp - 0x2d0]
mov dword [ebp - 0x2d0], 0x57525121
push eax
push edi
mov dword [ebp - 0x2cc], 0x20ff0008
call esi
test eax, eax
jns 0x404130
mov edx, str.networking_error
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov esi, 2
jmp 0x404955
lea ecx, [ebp - 0x2f8]
call fcn.00401310
nop dword [eax + eax]
lea ecx, [ebp - 0x320]
call fcn.00401310
lea edx, [ebp - 0x2f8]
mov ecx, eax
call fcn.00402dd0
cmp eax, 0xfa0
jb 0x404140
lea eax, [ebp - 0x58]
push eax
mov dword [ebp - 0x2f8], eax
call fcn.0040d8be
add esp, 4
test eax, eax
je 0x40417e
push eax
call fcn.0040db98
add esp, 4
mov byte [ebp - 0x2f4], 1
mov byte [ebp - 4], 0xa
cmp dword [ebp - 0x5c], 0
jne 0x4041c1
mov edx, str.no_devices_found
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
xor esi, esi
jmp 0x40492d
lea ecx, [ebp - 0x2f8]
call fcn.00404c70
push 0
push 8
lea eax, [ebp - 0x318]
mov dword [ebp - 0x318], 0x57525521
push eax
push edi
mov dword [ebp - 0x314], 0xe0ff0008
call esi
test eax, eax
jns 0x404227
mov edx, str.networking_error
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov esi, 2
jmp 0x40492d
lea eax, [ebp - 0x58]
push eax
lea ecx, [ebp - 0x2dc]
call fcn.00404d90
mov byte [ebp - 4], 0xb
mov esi, dword [ebp - 0x60]
mov dword [ebp - 0x29c], esi
cmp esi, dword [esi]
je 0x4048db
nop dword [eax + eax]
lea ecx, [ebp - 0x298]
mov dword [ebp - 0x298], esi
call fcn.00409a80
mov eax, dword [ebp - 0x298]
cmp byte [eax + 0x15], 0
jne 0x40488c
lea ecx, [ebp - 0x298]
mov dword [ebp - 0x298], esi
call fcn.00409a80
mov eax, dword [ebp - 0x298]
lea ecx, [ebp - 0x298]
mov dword [ebp - 0x298], esi
mov al, byte [eax + 0xe]
mov byte [ebp - 0x2a8], al
call fcn.00409a80
mov eax, dword [ebp - 0x298]
mov ecx, dword [eax + 0xf]
mov dword [ebp - 0x2a0], ecx
mov dword [ebp - 0x2e8], ecx
mov cx, word [eax + 0x13]
mov al, byte [eax + 0x15]
mov word [ebp - 0x296], cx
mov word [ebp - 0x2e4], cx
lea ecx, [ebp - 0x2dc]
mov byte [ebp - 0x2b9], al
mov byte [ebp - 0x2e2], al
call fcn.00404c70
sub esp, 8
lea ecx, [ebp - 0x3f0]
call fcn.00405a90
mov byte [ebp - 4], 0xc
mov cl, byte [ebp - 0x2a8]
mov al, cl
and al, 0xf
cmp al, 1
jbe 0x404328
test cl, 0x10
je 0x404328
movzx eax, cl
lea ecx, [ebp - 0x3e0]
and eax, 0xf
push eax
call fcn.00406180
mov edx, 0x45292c
mov ecx, eax
call fcn.0040a8d0
jmp 0x40433a
movzx eax, cl
lea ecx, [ebp - 0x3e0]
and eax, 0xf
push eax
call fcn.00406180
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x3f0]
call fcn.00405980
mov edi, eax
mov byte [ebp - 4], 0xd
mov ecx, dword [0x45c488]
push dword [ebp - 0x2a0]
movzx eax, byte [ebp - 0x2e5]
push dword [ebp - 0x2e4]
mov edx, dword [ecx + 4]
add edx, 0x45c488
push eax
movzx eax, byte [ebp - 0x2e6]
push eax
mov ecx, dword [edx + 0x14]
and ecx, 0xfffff3ff
or ecx, 0x200
mov dword [edx + 0x14], ecx
mov edx, 0x452940
mov ecx, 0x45c488
call fcn.0040a8d0
mov edx, edi
mov ecx, eax
call fcn.0040ac00
mov edx, str.__from_v
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.00406180
mov edx, 0x4528a0
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.00406180
mov edx, 0x452930
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.004064c0
mov edx, str.__id
mov ecx, eax
call fcn.0040a8d0
mov ecx, eax
call fcn.004064c0
mov edx, 0x45288c
mov ecx, eax
call fcn.0040a8d0
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0xc
call fcn.00404de0
mov al, byte [ebp - 0x2e6]
mov ah, byte [ebp - 0x2c2]
mov dl, byte [ebp - 0x2e5]
mov ch, byte [ebp - 0x2c1]
mov di, word [ebp - 0x296]
cmp ah, al
jne 0x40443c
cmp ch, dl
jne 0x40443c
cmp word [ebp - 0x2c0], di
jne 0x40443c
mov cl, 1
jmp 0x40443e
xor cl, cl
cmp ah, al
jb 0x404455
jne 0x404448
cmp ch, dl
jb 0x404455
cmp word [ebp - 0x2c0], di
jb 0x404455
xor al, al
jmp 0x404457
mov al, 1
test cl, cl
jne 0x404470
cmp byte [ebp - 0x2a1], cl
jne 0x404467
test al, al
jne 0x404470
mov byte [ebp - 0x2a2], 0
jmp 0x404477
mov byte [ebp - 0x2a2], 1
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jbe 0x40449d
cmp byte [ebp - 0x28d], 0
jne 0x4044c3
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jne 0x4044cc
cmp byte [ebp - 0x28e], 0
je 0x4044cc
mov byte [ebp - 0x2a3], 1
jmp 0x4044d3
mov byte [ebp - 0x2a3], 0
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jbe 0x4044f9
cmp byte [ebp - 0x28f], 0
jne 0x40451f
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jne 0x404528
cmp byte [ebp - 0x290], 0
je 0x404528
mov byte [ebp - 0x285], 1
jmp 0x404552
cmp byte [ebp - 0x286], 0
mov byte [ebp - 0x285], 0
je 0x404552
lea ecx, [ebp - 0x29c]
call fcn.00404bf0
mov cl, byte [ebp - 0x286]
cmp byte [eax], cl
setne byte [ebp - 0x285]
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
mov edi, 0x1e
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jbe 0x404582
mov eax, dword [ebp - 0x308]
test eax, eax
js 0x404582
mov edi, eax
jmp 0x4045aa
lea ecx, [ebp - 0x28c]
mov dword [ebp - 0x28c], esi
call fcn.00409a80
mov eax, dword [ebp - 0x28c]
cmp byte [eax + 0xe], 1
jne 0x4045aa
mov eax, dword [ebp - 0x2b8]
test eax, eax
cmovns edi, eax
mov ax, word [ebp - 0x2c4]
cmp ax, word [ebp - 0x2e8]
je 0x4045c4
mov edx, str.__id_mismatch__skip_update
jmp 0x4046e4
cmp byte [ebp - 0x2a2], 0
je 0x4045e9
cmp byte [ebp - 0x2a3], 0
je 0x4045df
cmp byte [ebp - 0x285], 0
je 0x4045fc
mov edx, str.__firmware_is_up_to_date
jmp 0x4046e4
cmp byte [ebp - 0x285], 0
je 0x4045fc
mov edx, str.__ignore_device
jmp 0x4046e4
lea eax, [ebp - 0xa0]
push eax
call fcn.0040d8be
add esp, 4
test eax, eax
je 0x404618
push eax
call fcn.0040db98
add esp, 4
mov al, byte [ebp - 0x2a8]
lea ecx, [ebp - 0xa0]
mov byte [ebp - 0x68], al
call fcn.00402720
lea eax, [ebp - 0xa0]
push eax
call fcn.0040d8e3
add esp, 4
test eax, eax
je 0x404648
push eax
call fcn.0040db98
add esp, 4
cmp byte [ebp - 0x2a4], 0
mov ecx, 0x45c488
je 0x404736
mov edx, str.___noupdate
call fcn.0040a8d0
push eax
call fcn.0040abc0
mov dl, 0x20
mov ecx, eax
call fcn.0040a610
mov dl, byte [ebp - 0x2a8]
lea ecx, [ebp - 0x284]
push 0
push edi
push 0x20
call fcn.00402430
add esp, 0x10
lea ecx, [ebp - 0xfc]
push 1
call fcn.00402340
xor esi, esi
nop dword [eax + eax]
movzx eax, word [ebp - 0x280]
inc esi
push 0
push eax
lea eax, [ebp - 0x284]
push eax
push dword [ebp - 0x294]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
js 0x404967
push 0x12c
lea ecx, [ebp - 0xfc]
call fcn.00402340
test al, al
jne 0x404702
cmp esi, 0xa
jl 0x4046a0
mov edx, str.device_did_not_respond_properly
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
jmp 0x404808
push edi
mov edx, str.device_is_restarting_in
mov ecx, 0x45c488
call fcn.0040a8d0
mov ecx, eax
call fcn.00406320
mov dl, 0x73
mov ecx, eax
call fcn.0040a610
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
jmp 0x404808
mov edx, str.__programming
call fcn.0040a8d0
push eax
call fcn.0040abc0
add esp, 4
mov dl, 0x20
mov ecx, eax
call fcn.0040a610
mov ecx, dword [ebp - 0x2a0]
lea eax, [ebp - 0x304]
push edi
push eax
push dword [ebp - 0x2e0]
mov esi, dword [ebp - 0x294]
lea edx, [ebp - 0xa0]
sub esp, 8
mov eax, esp
push dword [ebp - 0x2a8]
mov dword [eax], ecx
mov cx, word [ebp - 0x296]
mov word [eax + 4], cx
mov cl, byte [ebp - 0x2b9]
mov byte [eax + 6], cl
lea eax, [ebp - 0xfc]
push eax
lea eax, [ebp - 0x158]
push eax
push ecx
mov ecx, esi
call fcn.00402e00
add esp, 0x24
mov ecx, 0x45c488
test al, al
je 0x4049ac
push edi
mov edx, str.update_ok__device_restarting_in
call fcn.0040a8d0
mov ecx, eax
call fcn.00406320
mov dl, 0x73
mov ecx, eax
call fcn.0040a610
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
lea ecx, [ebp - 0x29c]
call fcn.00404bf0
mov ecx, dword [ebp - 0x2d4]
movzx ecx, cl
cmp byte [eax], 1
mov eax, 1
cmove ecx, eax
mov dword [ebp - 0x2d4], ecx
lea ecx, [ebp - 0x2dc]
call fcn.00407930
push dword [ebp - 0x2dc]
call fcn.0040d8be
add esp, 4
test eax, eax
je 0x40482e
push eax
call fcn.0040db98
add esp, 4
lea eax, [ebp - 0x2a8]
mov byte [ebp - 0x2d8], 1
push eax
lea eax, [ebp - 0x320]
push eax
lea ecx, [ebp - 0x60]
call fcn.0040bab0
mov eax, dword [ebp - 0x320]
lea ecx, [ebp - 0x2dc]
mov byte [eax + 0x15], 1
call fcn.00404c70
lea ecx, [ebp - 0x388]
call fcn.004059a0
lea eax, [ebp - 0x388]
mov byte [ebp - 4], 0xe
push eax
mov dword [ebp - method.std::ios_base.virtual_0], vtable.std::ios_base.0
call fcn.0040e291
add esp, 4
mov byte [ebp - 4], 0xb
lea ecx, [ebp - 0x2dc]
call fcn.00407930
push dword [ebp - 0x2dc]
call fcn.0040d8be
add esp, 4
test eax, eax
je 0x4048b2
push eax
call fcn.0040db98
add esp, 4
lea ecx, [ebp - 0x29c]
mov byte [ebp - 0x2d8], 1
call fcn.00409a80
mov eax, dword [ebp - 0x60]
mov esi, dword [ebp - 0x29c]
cmp esi, dword [eax]
jne 0x404250
mov edi, dword [ebp - 0x294]
lea ecx, [ebp - 0x2dc]
call fcn.00404c70
mov edx, str.all_detected_devices_checked_or_updated__no_errors_detected
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
xor esi, esi
mov eax, 3
cmp byte [ebp - 0x2d4], 0
cmovne esi, eax
lea ecx, [ebp - 0x2dc]
call fcn.00404d40
mov byte [ebp - 4], 0xf
cmp byte [ebp - 0x2f4], 0
je 0x404955
push dword [ebp - 0x2f8]
call fcn.0040d8e3
add esp, 4
test eax, eax
je 0x404955
push eax
call fcn.0040db98
add esp, 4
cmp dword [ebp - 0x2ec], 0
je 0x4049e1
call fcn.0042c699
mov edx, str.networking_error
mov ecx, 0x45c488
call fcn.0040a8d0
push eax
call fcn.0040abc0
push eax
call fcn.0040abc0
add esp, 8
push dword [ebp - 0x294]
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
lea ecx, [ebp - 0x3f0]
mov esi, 2
call fcn.00404af0
jmp 0x404922
mov edx, str.error_while_programming_device
call fcn.0040a8d0
push eax
call fcn.0040abc0
add esp, 4
push esi
call dword [sym.imp.WS2_32.dll_closesocket]
call dword [sym.imp.WS2_32.dll_WSACleanup]
lea ecx, [ebp - 0x3f0]
mov esi, 1
call fcn.00404af0
jmp 0x404922
lea eax, [ebp - 0xd0]
push eax
call fcn.0040d842
lea eax, [ebp - 0xf8]
push eax
call fcn.0040d498
lea eax, [ebp - 0x12c]
push eax
call fcn.0040d842
lea eax, [ebp - 0x154]
push eax
call fcn.0040d498
lea eax, [ebp - 0x58]
push eax
call fcn.0040d842
mov eax, dword [ebp - 0x60]
lea ecx, [ebp - 0x60]
add esp, 0x14
push eax
push dword [eax]
lea eax, [ebp - 0x2e0]
push eax
call fcn.00409640
push 0x18
push 1
push dword [ebp - 0x60]
call fcn.004012b0
add esp, 0xc
lea ecx, [ebp - 0xa0]
call fcn.00402590
jmp 0x403a29