Function at 0x402940
Capabilities:
Print debug messages
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1b88
call fcn.0042cd90
mov eax, dword [0x44a044]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor esi, esi
push 0x206
lea edx, [ebp - 0x103a]
xor ecx, ecx
push esi
push edx
mov dword [ebp - 0x1b88], eax
mov dword [ebp - 0x1b68], esi
mov dword [ebp - 0x1b54], esi
mov word [ebp - 0x103c], cx
call fcn.00427f40
add esp, 0xc
push 0x206
lea ecx, [ebp - 0x42a]
xor eax, eax
push esi
push ecx
mov word [ebp - 0x42c], ax
call fcn.00427f40
add esp, 0xc
push 0x206
lea eax, [ebp - 0x1242]
xor edx, edx
push esi
push eax
mov word [ebp - 0x1244], dx
call fcn.00427f40
add esp, 0xc
push 0x206
lea edx, [ebp - 0xe32]
xor ecx, ecx
push esi
push edx
mov word [ebp - 0xe34], cx
call fcn.00427f40
add esp, 0xc
push 0x206
lea ecx, [ebp - 0x222]
xor eax, eax
push esi
push ecx
mov word [ebp - 0x224], ax
call fcn.00427f40
add esp, 0xc
push 0x7fe
lea eax, [ebp - 0xc2a]
xor edx, edx
push esi
push eax
mov word [ebp - 0xc2c], dx
call fcn.00427f40
add esp, 0xc
push 0x7fe
lea edx, [ebp - 0x1a42]
xor ecx, ecx
push esi
push edx
mov word [ebp - 0x1a44], cx
call fcn.00427f40
add esp, 0xc
push 0x104
lea eax, [ebp - 0x103c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
xor eax, eax
jmp 0x402a60
movzx ecx, word [ebp + eax - 0x103c]
mov word [ebp + eax - 0x42c], cx
add eax, 2
cmp cx, si
jne 0x402a60
lea ecx, [ebp - 0x42c]
push 0x5c
push ecx
call fcn.00421cfc
add esp, 8
test eax, eax
je 0x402aa3
lea edx, [ebp - 0x42c]
push 0x5c
push edx
call fcn.00421cfc
add esp, 8
xor ecx, ecx
mov word [eax], cx
lea edx, [ebp - 0x103c]
push 0x5c
push edx
call fcn.00421cfc
add eax, 2
lea edx, [ebp - 0x1244]
add esp, 8
sub edx, eax
nop
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
cmp cx, si
jne 0x402ac0
xor eax, eax
jmp 0x402ae0
movzx ecx, word [ebp + eax - 0x1244]
mov word [ebp + eax - 0xe34], cx
add eax, 2
cmp cx, si
jne 0x402ae0
lea eax, [ebp - 0xe34]
push 0x2e
push eax
call fcn.00421cfc
add esp, 8
test eax, eax
je 0x402b23
lea ecx, [ebp - 0xe34]
push 0x2e
push ecx
call fcn.00421cfc
add esp, 8
xor edx, edx
mov word [eax], dx
push 0xd0
lea eax, [ebp - 0x1b14]
push esi
push eax
mov dword [ebp - 0x1b1c], esi
call fcn.00427f40
add esp, 0xc
lea esi, [ebp - 0x1b14]
mov edi, 0x44c414
lea esp, [esp]
mov ecx, dword [edi]
mov ebx, dword [sym.imp.USER32.dll_wsprintfW]
push ecx
lea edx, [ebp - 0x42c]
push edx
lea eax, [ebp - 0x224]
push 0x43aff8
push eax
call ebx
lea ecx, [ebp - 0x224]
push 0
push ecx
call fcn.00422010
add esp, 0x18
test eax, eax
jne 0x402bc2
inc dword [ebp - 0x1b68]
lea edx, [ebp - 0x1b4c]
push edx
lea eax, [ebp - 0x224]
push eax
call fcn.0042189e
add esp, 8
test eax, eax
jne 0x402c17
mov ecx, dword [ebp - 0x1b2c]
mov edx, dword [ebp - 0x1b28]
mov eax, dword [ebp - 0x1b38]
add dword [ebp - 0x1b54], eax
mov dword [esi], ecx
mov dword [esi + 4], edx
jmp 0x402bcf
xor eax, eax
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov dword [esi - 8], eax
add edi, 4
add esi, 0x18
cmp edi, 0x44c438
jl 0x402b50
cmp dword [ebp - 0x1b68], 0
jne 0x402c5b
push 0x40000
push 0x43b024
push 0x43b02c
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x224]
push eax
lea ecx, [ebp - 0xc2c]
push str._s_r_n_r_n
push ecx
call ebx
add esp, 0xc
push 0x40010
push 0x43adfc
lea edx, [ebp - 0xc2c]
push edx
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x1b1c], 0
jne 0x402c8e
push 0x40030
push 0x43b040
push 0x43b04c
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x1b54]
mov ebx, dword [ebp - 0x1b88]
push 0x80
add eax, 0xe8
push ebx
mov dword [ebp - 0x1b6c], eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
call fcn.00401080
test eax, eax
je 0x402c48
mov ecx, dword [str.KfhliQbpiGjbp]
mov edx, dword [0x43add4]
xor eax, eax
mov dword [ebp - 0x1b], eax
mov dword [ebp - 0x17], eax
mov dword [ebp - 0x13], eax
mov dword [ebp - 0xf], eax
mov eax, dword [0x43add8]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [0x43addc]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x10], ecx
xor eax, eax
lea ecx, [ecx]
add byte [ebp + eax - 0x1c], 6
inc eax
cmp eax, 0x10
jb 0x402cf0
push 0x43b094
push ebx
call fcn.0042178a
mov edi, eax
add esp, 8
mov dword [ebp - 0x1b50], edi
test edi, edi
jne 0x402d54
push ebx
lea edx, [ebp - 0xc2c]
push 0x43b09c
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
push 0x10
push str.L_eQ_
lea eax, [ebp - 0xc2c]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
push 2
push 0
push edi
call fcn.0042251b
add esp, 0xc
push edi
call fcn.0042242c
add esp, 4
push edi
mov esi, eax
call fcn.00421371
add esp, 4
push esi
call fcn.004212dd
add esp, 4
mov ebx, eax
push edi
test ebx, ebx
jne 0x402db3
call fcn.00422655
add esp, 4
push 0x10
push str.L_eQ_
push 0x43b0cc
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
push esi
push 1
push ebx
call fcn.00421f74
add esp, 0x10
cmp eax, esi
je 0x402dfc
push edi
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
add esp, 4
push 0x10
push str.L_eQ_
push 0x43b0e0
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
push esi
push ebx
lea esi, [ebp - 0x1c]
call section..text
cdq
push ebx
mov dword [ebp - 0x1b84], eax
mov dword [ebp - 0x1b80], edx
call fcn.004212a3
mov esi, dword [ebp - 0x1b6c]
add esp, 0xc
push esi
call fcn.004212dd
mov ebx, eax
add esp, 4
mov dword [ebp - 0x1b6c], ebx
test ebx, ebx
jne 0x402e7e
push edi
call fcn.00422655
add esp, 4
push esi
lea ecx, [ebp - 0xc2c]
push 0x43b0f4
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
push 0x10
push str.L_eQ_
lea edx, [ebp - 0xc2c]
push edx
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00421294
mov esp, ebp
pop ebp
ret
push esi
push 0
push ebx
call fcn.00427f40
mov eax, dword [ebp - 0x1c]
mov dword [ebx], eax
mov ecx, dword [ebp - 0x18]
mov dword [ebx + 4], ecx
mov edx, dword [ebp - 0x14]
mov dword [ebx + 8], edx
mov eax, dword [ebp - 0x10]
lea edi, [ebx + 0x10]
mov ecx, 0x36
lea esi, [ebp - 0x1b1c]
add esp, 0xc
mov dword [ebx + 0xc], eax
xor eax, eax
rep movsd dword es:[edi], dword [esi]
lea ecx, [ebp - 0x1b1c]
mov dword [ebp - 0x1b7c], eax
mov dword [ebp - 0x1b78], eax
mov dword [ebp - 0x1b54], 0xe8
mov dword [ebp - 0x1b58], eax
mov dword [ebp - 0x1b70], ecx
mov edx, dword [ebp - 0x1b70]
mov esi, dword [edx]
mov dword [ebp - 0x1b64], esi
test esi, esi
je 0x4030ae
mov eax, dword [eax*4 + 0x44c414]
mov edi, dword [sym.imp.USER32.dll_wsprintfW]
push eax
lea ecx, [ebp - 0x42c]
push ecx
lea edx, [ebp - 0x224]
push 0x43aff8
push edx
call edi
lea eax, [ebp - 0x224]
push 0x43b120
push eax
call fcn.0042178a
add esp, 0x18
mov dword [ebp - 0x1b5c], eax
test eax, eax
je 0x403101
push esi
call fcn.004212dd
mov edi, eax
add esp, 4
test edi, edi
je 0x403133
push esi
push 0
push edi
call fcn.00427f40
mov ecx, dword [ebp - 0x1b5c]
add esp, 0xc
push ecx
push esi
push 1
push edi
call fcn.00421f74
add esp, 0x10
mov dword [ebp - 0x1b60], eax
cmp eax, esi
jne 0x40319b
lea eax, [esi + esi]
push eax
mov dword [ebp - 0x1b60], eax
call fcn.004212dd
mov esi, eax
add esp, 4
test esi, esi
je 0x403212
mov edx, dword [ebp - 0x1b60]
push edx
push 0
push esi
call fcn.00427f40
mov ecx, dword [ebp - 0x1b64]
lea eax, [ebp - 0x1b60]
add esp, 0xc
push eax
mov eax, edi
mov edx, esi
call fcn.0041bcb0
add esp, 4
mov dword [ebp - 0x1b64], eax
cmp eax, 0xfffffffb
je 0x40327f
test eax, eax
jne 0x4032f0
mov ebx, dword [ebp - 0x1b60]
mov eax, dword [ebp - 0x1b70]
mov ecx, dword [ebp - 0x1b7c]
mov edx, dword [ebp - 0x1b6c]
push ebx
mov dword [eax + 0x10], ebx
mov dword [eax + 0x14], ecx
lea eax, [ecx + edx + 0xe8]
push esi
push eax
call fcn.004282e0
mov ecx, dword [ebp - 0x1b5c]
add esp, 0xc
add dword [ebp - 0x1b7c], ebx
push ecx
adc dword [ebp - 0x1b78], 0
add dword [ebp - 0x1b54], ebx
call fcn.00422655
add esp, 4
push edi
call fcn.004212a3
add esp, 4
push esi
call fcn.004212a3
mov edx, dword [ebp - 0x1b58]
mov eax, dword [edx*4 + 0x44c414]
add esp, 4
mov ecx, eax
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x403047
lea edi, [ebp - 0x1a44]
sub eax, ecx
mov esi, ecx
add edi, 0xfffffffe
nop
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x403060
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
lea eax, [ebp - 0x1a44]
rep movsb byte es:[edi], byte [esi]
add eax, 0xfffffffe
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x403083
mov ecx, dword [0x43b254]
mov dx, word [0x43b258]
mov ebx, dword [ebp - 0x1b6c]
mov dword [eax], ecx
mov word [eax + 4], dx
mov eax, dword [ebp - 0x1b58]
add dword [ebp - 0x1b70], 0x18
inc eax
mov dword [ebp - 0x1b58], eax
cmp eax, 9
jl 0x402edb
mov ecx, 0x36
lea esi, [ebp - 0x1b1c]
lea edi, [ebx + 0x10]
rep movsd dword es:[edi], dword [esi]
mov esi, dword [ebp - 0x1b84]
mov ecx, esi
and ecx, dword [ebp - 0x1b80]
cmp ecx, 0xffffffff
jne 0x403358
mov edi, dword [ebp - 0x1b50]
push 2
push 0
push edi
call fcn.0042251b
jmp 0x40336d
mov eax, dword [ebp - 0x1b50]
push eax
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
add esp, 4
lea ecx, [ebp - 0x224]
push ecx
lea edx, [ebp - 0xc2c]
push 0x43b09c
push edx
call edi
jmp 0x402d28
mov ecx, dword [ebp - 0x1b50]
push ecx
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov edx, dword [ebp - 0x1b5c]
add esp, 4
push edx
call fcn.00422655
mov eax, dword [ebp - 0x1b58]
lea ecx, [eax + eax*2]
mov edx, dword [ebp + ecx*8 - 0x1b1c]
mov eax, dword [eax*4 + 0x44c414]
add esp, 4
push edx
push eax
lea ecx, [ebp - 0xc2c]
push 0x43b128
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push 0x10
push str.L_eQ_
lea edx, [ebp - 0xc2c]
push edx
jmp 0x402d39
mov eax, dword [ebp - 0x1b50]
push eax
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov ecx, dword [ebp - 0x1b5c]
add esp, 4
push ecx
call fcn.00422655
add esp, 4
push edi
call fcn.004212a3
mov eax, dword [ebp - 0x1b58]
mov edx, dword [ebp - 0x1b60]
add esp, 4
push edx
lea eax, [eax + eax*2]
mov ecx, dword [ebp + eax*8 - 0x1b1c]
push ecx
lea edx, [ebp - 0x224]
push edx
lea eax, [ebp - 0xc2c]
push 0x43b158
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x14
push 0x10
push str.L_eQ_
lea ecx, [ebp - 0xc2c]
push ecx
jmp 0x402d39
mov edx, dword [ebp - 0x1b50]
push edx
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov eax, dword [ebp - 0x1b5c]
add esp, 4
push eax
call fcn.00422655
add esp, 4
push edi
call fcn.004212a3
mov ecx, dword [ebp - 0x1b60]
mov edx, dword [ebp - 0x1b58]
mov eax, dword [edx*4 + 0x44c414]
add esp, 4
push ecx
push eax
lea ecx, [ebp - 0xc2c]
push 0x43b1a4
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push 0x10
push str.L_eQ_
lea edx, [ebp - 0xc2c]
push edx
jmp 0x402d39
mov eax, dword [ebp - 0x1b50]
push eax
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov ecx, dword [ebp - 0x1b5c]
add esp, 4
push ecx
call fcn.00422655
add esp, 4
push edi
call fcn.004212a3
add esp, 4
push esi
call fcn.004212a3
mov edx, dword [ebp - 0x1b58]
mov eax, dword [edx*4 + 0x44c414]
add esp, 4
push 0xfffffffffffffffb
push eax
lea ecx, [ebp - 0xc2c]
push 0x43b1d0
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push 0x10
push str.L_eQ_
lea edx, [ebp - 0xc2c]
push edx
jmp 0x402d39
mov eax, dword [ebp - 0x1b50]
push eax
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov ecx, dword [ebp - 0x1b5c]
add esp, 4
push ecx
call fcn.00422655
add esp, 4
push edi
call fcn.004212a3
add esp, 4
push esi
call fcn.004212a3
mov edx, dword [ebp - 0x1b64]
mov eax, dword [ebp - 0x1b58]
mov ecx, dword [eax*4 + 0x44c414]
add esp, 4
push edx
push ecx
lea edx, [ebp - 0xc2c]
push 0x43b218
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
jmp 0x402d2b
mov edx, dword [ebp - 0x1b50]
push 0
push esi
push edx
call fcn.0042251b
mov edi, dword [ebp - 0x1b50]
mov eax, dword [ebp - 0x1b08]
mov ecx, dword [ebp - 0x1b0c]
mov edx, dword [ebp - 0x1b10]
add esp, 0xc
push eax
mov eax, dword [ebp - 0x1b14]
push ecx
mov ecx, dword [ebp - 0x1b1c]
push edx
push eax
push ecx
lea edx, [ebp - 0xc2c]
push str.Client.cab___lu____I64d____lu____lu_
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x1c
lea eax, [ebp - 0xc2c]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 0x1b54]
push edi
push ecx
push 1
push ebx
call fcn.0042221e
and esi, dword [ebp - 0x1b80]
add esp, 0x10
mov dword [ebp - 0x1b64], eax
cmp esi, 0xffffffff
je 0x403451
push edi
call fcn.0042242c
cdq
add esp, 4
push edi
mov esi, eax
mov dword [ebp - 0x1b80], edx
call fcn.004220a1
mov edx, dword [ebp - 0x1b80]
add esp, 4
push edx
push esi
push eax
call fcn.004215e5
add esp, 0xc
test eax, eax
je 0x403451
push edi
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc2c]
push 0x43b2ac
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
push 0x40010
push 0x43adfc
lea ecx, [ebp - 0xc2c]
push ecx
jmp 0x402d39
push edi
call fcn.00422655
add esp, 4
push ebx
call fcn.004212a3
mov eax, dword [ebp - 0x1b64]
mov ecx, dword [ebp - 0x1b54]
add esp, 4
cmp eax, ecx
je 0x40348f
push ecx
push eax
lea edx, [ebp - 0xc2c]
push 0x43b2dc
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
jmp 0x402d2b
lea eax, [ebp - 0x1a44]
lea edx, [eax + 2]
jmp 0x4034a0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4034a0
mov ecx, dword [ebp - 0x1b88]
sub eax, edx
mov edx, dword [ebp - 0x1b68]
push ecx
push edx
sar eax, 1
lea eax, [ebp + eax*2 - 0x1a44]
push 0x43b310
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea ecx, [ebp - 0x1a44]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
mov eax, 1
pop ebx
call fcn.00421294
mov esp, ebp
pop ebp
ret