Function at 0x559900
Capabilities:
Check if file exists
Copy file
Get file attributes
Get file size
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5cdbdc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x33ab0
call fcn.00589870
push ebx
push esi
mov esi, ecx
push edi
xor edi, edi
mov dword [ebp - 0x10], esp
mov edx, dword [esi + 0x420]
mov dword [ebp - 0x44], esi
cmp edx, edi
mov dword [ebp - 4], edi
jne 0x559d98
mov al, byte [esi + 0x9ca]
test al, al
je 0x559d98
xor ecx, ecx
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x40], ecx
mov word [ebp - 0x3c], di
mov eax, dword [esi + 0x4c]
mov edx, 0x65bf6c
test edx, edx
mov byte [ebp - 4], 1
je 0x559a2d
cmp eax, edi
je 0x559a2d
push eax
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x2c], edi
mov word [ebp - 0x30], di
call fcn.00401ee0
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
call fcn.00401070
push 0x65bf6c
lea ecx, [ebp - 0x28]
call fcn.00401e50
mov eax, dword [ebp - 0x34]
mov byte [ebp - 4], 3
cmp eax, edi
jne 0x5599b1
lea eax, [ebp - 0x30]
mov edi, dword [ebp - 0x20]
push eax
call fcn.00589432
lea ebx, [eax + edi + 2]
lea edi, [ebx + ebx]
push edi
call fcn.005a1be9
mov edx, eax
add esp, 8
test edx, edx
mov dword [ebp - 0x40], edx
je 0x559a12
mov ecx, edi
mov edi, edx
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea ecx, [ebp - 0x34]
call fcn.00401ed0
push eax
lea ecx, [ebp - 0x28]
call fcn.00401ed0
push eax
mov eax, dword [ebp - 0x40]
push ebx
push eax
call fcn.005893c2
mov ecx, dword [ebp - 0x40]
push ecx
call fcn.00589432
add esp, 0x14
mov dword [ebp - 0x38], eax
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 2
call fcn.00401070
lea ecx, [ebp - 0x34]
mov byte [ebp - 4], 1
call fcn.00401070
mov ecx, dword [ebp - 0x40]
xor ebx, ebx
cmp ecx, ebx
jne 0x559a36
lea ecx, [ebp - 0x3c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x559c10
mov eax, dword [ebp - 0x40]
cmp eax, ebx
jne 0x559a50
lea eax, [ebp - 0x3c]
add eax, 6
push 0x5c
push eax
call fcn.0058989f
add esp, 8
mov edi, eax
cmp edi, ebx
je 0x559c10
mov eax, dword [ebp - 0x40]
cmp eax, ebx
jne 0x559a72
lea eax, [ebp - 0x3c]
push eax
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x2c], ebx
mov word [ebp - 0x30], bx
call fcn.00401ee0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 4
cmp ecx, ebx
jne 0x559a93
lea ecx, [ebp - 0x30]
mov eax, dword [ebp - 0x40]
cmp eax, ebx
jne 0x559a9d
lea eax, [ebp - 0x3c]
mov edx, edi
sub edx, eax
sar edx, 1
mov word [ecx + edx*2], bx
mov eax, dword [ebp - 0x34]
cmp eax, ebx
jne 0x559ab1
lea eax, [ebp - 0x30]
push 1
push eax
call fcn.00472060
add esp, 8
cmp eax, ebx
jne 0x559bef
mov eax, dword [ebp - 0x34]
cmp eax, ebx
jne 0x559ace
lea eax, [ebp - 0x30]
push 1
push eax
call fcn.00472240
add esp, 8
cmp eax, ebx
jne 0x559bef
mov eax, dword [0x682f9c]
mov dword [ebp - 0x1c], eax
push ebx
lea ecx, [ebp - 0x14]
push ebx
push ecx
push 0x400
mov byte [ebp - 4], 5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push 0x1100
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, dword [ebp - 0x14]
mov eax, dword [0x6888ec]
push edx
lea ecx, [ebp - 0x1c]
push eax
push ecx
call fcn.0059e618
mov edx, dword [ebp - 0x14]
add esp, 0xc
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov esi, dword [ebp - 0x1c]
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x20], ebx
mov word [ebp - 0x24], bx
call fcn.00401070
cmp esi, ebx
je 0x559b8d
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x559b8d
mov edi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push eax
push eax
push 0xffffffffffffffff
push esi
push eax
push eax
call edi
test eax, eax
mov dword [ebp - 0x20], eax
je 0x559b8d
lea eax, [eax + eax + 2]
push eax
call fcn.005a1be9
add esp, 4
mov dword [ebp - 0x28], eax
test eax, eax
je 0x559b90
mov ecx, dword [ebp - 0x20]
push ecx
push eax
push 0xffffffffffffffff
push esi
push 0
push 0
call edi
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x40]
test ecx, ecx
jne 0x559b9a
lea ecx, [ebp - 0x3c]
test eax, eax
jne 0x559ba1
lea eax, [ebp - 0x24]
push 0x30
push ecx
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
lea ecx, [ebp - 0x28]
call fcn.00401070
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.005a584d
lea ecx, [ebp - 0x34]
mov byte [ebp - 4], 1
call fcn.00401070
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 0
call fcn.00401070
mov eax, 0x7546
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
add edi, 2
push 0x5c
push edi
call fcn.0058989f
add esp, 8
lea ecx, [ebp - 0x34]
mov edi, eax
mov byte [ebp - 4], 1
call fcn.00401070
jmp 0x559a60
cmp dword [esi + 0x9c0], ebx
je 0x559d8a
cmp dword [esi + 0x9c4], ebx
je 0x559d8a
lea edx, [ebp - 0x20]
lea eax, [ebp - 0x14]
push edx
mov edi, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
push eax
push 0
push 0xf003f
push 0
push 0x6874e8
push 0
push str.SoftwareDownloadManagerGrabberStsProjects_
push reloc.WSOCK32.dll_accept
call edi
test eax, eax
jne 0x559d8a
mov ecx, dword [ebp - 0x14]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push ecx
call ebx
mov edx, dword [0x682f9c]
mov dword [ebp - 0x1c], edx
mov eax, dword [esi + 0x9c0]
lea ecx, [ebp - 0x1c]
push eax
push str.SoftwareDownloadManagerGrabberStsProjects_ld_
push ecx
mov byte [ebp - 4], 6
call fcn.0059e618
add esp, 0xc
mov ecx, dword [ebp - 0x1c]
lea edx, [ebp - 0x20]
lea eax, [ebp - 0x14]
push edx
push eax
push 0
push 0xf003f
push 0
push 0x6874e8
push 0
push ecx
push reloc.WSOCK32.dll_accept
call edi
test eax, eax
jne 0x559d7e
mov edx, dword [ebp - 0x14]
push edx
call ebx
mov eax, dword [esi + 0x9c4]
mov ecx, dword [esi + 0x9c0]
push eax
push ecx
lea edx, [ebp - 0x1c]
push str.SoftwareDownloadManagerGrabberStsProjects_ld_ld_
push edx
call fcn.0059e618
add esp, 0x10
mov edx, dword [ebp - 0x1c]
lea eax, [ebp - 0x20]
lea ecx, [ebp - 0x14]
push eax
push ecx
push 0
push 0xf003f
push 0
push 0x6874e8
push 0
push edx
push reloc.WSOCK32.dll_accept
call edi
test eax, eax
jne 0x559d7e
mov eax, dword [esi + 0x50]
push eax
call fcn.00589432
mov edx, dword [esi + 0x50]
add esp, 4
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
lea ecx, [eax + eax + 1]
mov eax, dword [ebp - 0x14]
push ecx
push edx
push 1
push 0
push str.LocalFileName
push eax
call edi
mov ecx, dword [esi + 0x4c]
push ecx
call fcn.00589432
mov ecx, dword [ebp - 0x14]
add esp, 4
lea edx, [eax + eax + 1]
mov eax, dword [esi + 0x4c]
push edx
push eax
push 1
push 0
push str.LocalPath
push ecx
call edi
lea ebx, [esi + 0x450]
push ebx
call fcn.00589432
add esp, 4
lea edx, [eax + eax + 1]
mov eax, dword [ebp - 0x14]
push edx
push ebx
push 1
push 0
push str.LogFileName
push eax
call edi
mov ecx, dword [ebp - 0x14]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
call fcn.005a584d
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 0
call fcn.00401070
jmp 0x559dcc
mov al, byte [esi + 0x9b0]
test al, al
je 0x559daa
mov ecx, dword [esi + 0x9c4]
jmp 0x559dac
xor ecx, ecx
test al, al
je 0x559db8
mov eax, dword [esi + 0x9c0]
jmp 0x559dba
xor eax, eax
push ecx
push eax
push edx
lea ecx, [esi + 0x20]
call fcn.00563cf0
mov byte [esi + 0x9ca], 1
mov edx, dword [esi + 0x420]
lea ebx, [esi + 0x20]
push edx
mov ecx, ebx
call fcn.005633b0
mov eax, dword [esi + 0x18]
xor edi, edi
cmp eax, edi
je 0x559dfe
mov ecx, dword [esi + 0x420]
push ecx
push 0x13cd
push 0x111
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
push 1
mov ecx, esi
mov dword [esi + 0x9ac], edi
mov dword [esi + 0x9bc], edi
call fcn.00558ef0
lea ecx, [esi + 0x44c]
call fcn.00513310
mov al, byte [esi + 0x9ce]
test al, al
jne 0x559e49
cmp dword [esi + 4], edi
jne 0x559e41
cmp dword [esi + 8], edi
jne 0x559e41
mov ecx, esi
call fcn.0055c770
cmp eax, edi
je 0x559e41
mov al, 1
jmp 0x559e43
xor al, al
mov byte [esi + 0x9cd], al
mov edi, dword [esi + 0x38]
test edi, edi
je 0x559e63
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [ebp - 0x20], ecx
jne 0x559f74
mov eax, dword [esi + 0x44]
cmp eax, 2
je 0x559e74
cmp eax, 1
jne 0x559f74
mov eax, dword [esi + 0x24]
test eax, eax
je 0x559ea5
push str._simtelnet_
push eax
call fcn.00589520
add esp, 8
test eax, eax
je 0x559ea5
mov edx, dword [ebx]
push str.simtel.net
push edx
call fcn.00589520
add esp, 8
test eax, eax
je 0x559f74
mov eax, dword [esi + 0x9b4]
test eax, eax
jne 0x559f74
mov eax, dword [0x682f9c]
mov dword [ebp - 0x1c], eax
mov eax, dword [esi + 0x34]
mov byte [ebp - 4], 7
cmp eax, 0x50
jne 0x559ecd
cmp dword [esi + 0x44], 1
je 0x559eda
cmp eax, 0x1bb
jne 0x559eed
cmp dword [esi + 0x44], 2
jne 0x559eed
lea ecx, [ebp - 0x24]
push 0x6874e8
push ecx
call fcn.00589e0a
add esp, 8
jmp 0x559eff
push eax
lea edx, [ebp - 0x24]
push str.:_ld
push edx
call fcn.00589e0a
add esp, 0xc
mov eax, dword [esi + 0x24]
test eax, eax
mov edx, eax
jne 0x559f0d
mov edx, 0x6874e8
test eax, eax
je 0x559f1d
mov cl, byte [eax]
cmp cl, 0x2f
mov ecx, 0x6874e8
je 0x559f22
mov ecx, 0x65e468
mov eax, dword [esi + 0x44]
cmp eax, 1
mov eax, 0x65c234
je 0x559f34
mov eax, 0x65c144
push edx
mov edx, dword [ebx]
push ecx
lea ecx, [ebp - 0x24]
push ecx
push edx
push eax
lea eax, [ebp - 0x1c]
push str._s:___s_s_s_s
push eax
call fcn.0059e618
mov ecx, dword [ebp - 0x1c]
add esp, 0x1c
push ecx
mov ecx, esi
call fcn.0055baf0
lea ecx, [ebp - 0x1c]
mov byte [esi + 0x2fc], 1
mov byte [esi + 0x2fd], 1
mov byte [ebp - 4], 0
call fcn.005a584d
lea ebx, [esi + 0x9dc]
mov byte [esi + 0x2fb], 0
mov dword [esi + 0xcc], 0
mov byte [ebp - 0x15], 0
mov eax, dword [ebx]
test eax, eax
jne 0x559f98
lea eax, [ebx + 4]
push eax
call fcn.00589432
add esp, 4
test eax, eax
je 0x55a26a
mov eax, dword [ebx]
test eax, eax
jne 0x559fb2
lea eax, [ebx + 4]
push 0
push 0
push 3
push 0
push 1
push closesocket
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x55a26a
lea edx, [ebp - 0x20]
push edx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esi + 0x428], eax
mov dword [esi + 0x42c], 0
cmp dword [esi + 0x428], 0xffffffff
jne 0x55a015
mov eax, dword [esi + 0x42c]
test eax, eax
jne 0x55a015
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x55a015
xor eax, eax
mov dword [esi + 0x428], eax
jmp 0x55a03a
mov eax, dword [ebp - 0x20]
push 1
push 0
push 0
push eax
call fcn.0058bcb0
mov ecx, dword [esi + 0x428]
add ecx, eax
mov dword [esi + 0x428], ecx
mov eax, dword [esi + 0x42c]
adc eax, edx
push edi
mov dword [esi + 0x42c], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x51fc10
push fcn.0051f970
push 0x10
lea ecx, [ebp - 0x33ac0]
push 0x3328
push ecx
call fcn.00589fa3
mov edx, dword [esi]
lea eax, [esi + 0x44c]
push edx
push eax
lea eax, [esi + 0x20]
lea ecx, [esi + 0x870]
push eax
lea eax, [ebp - 0x33ac0]
push eax
push ecx
lea ecx, [ebp - 0x840]
mov byte [ebp - 4], 8
call fcn.0052dc80
mov ecx, dword [esi + 0x9b8]
lea eax, [esi + 0x18]
mov dword [ebp - 0x82c], eax
mov eax, dword [esi + 0x9b4]
lea edx, [esi + 0x1c]
push eax
mov eax, dword [esi + 0x9c0]
mov dword [ebp - 0x828], edx
mov edx, dword [esi + 0x9c4]
push ecx
push edx
mov edx, dword [esi + 0x420]
push eax
mov al, byte [esi + 0x9b0]
xor ecx, ecx
lea edi, [esi + 0x14]
test al, al
sete cl
push ecx
push edx
lea ecx, [ebp - 0x840]
mov byte [ebp - 4], 9
mov dword [ebp - 0x830], edi
mov dword [ebp - 0x788], edi
call fcn.00552650
mov eax, dword [esi + 0x42c]
mov ecx, dword [esi + 0x428]
push 1
push eax
push ecx
lea ecx, [ebp - 0x840]
call fcn.00552b40
mov al, byte [esi + 0x9b0]
test al, al
je 0x55a129
xor eax, eax
mov byte [ebp - 0x15], 1
mov dword [esi + 0x9ac], eax
mov dword [ebp - 0x14], eax
jmp 0x55a238
mov eax, dword [ebx]
test eax, eax
jne 0x55a132
lea eax, [ebx + 4]
mov edx, dword [esi + 0x50]
push 0
push edx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x55a1d8
mov edx, dword [esi + 0x428]
mov ecx, dword [esi + 0x42c]
mov eax, edx
mov dword [ebp - 0x6e4], ecx
mov dword [ebp - 0x6e8], eax
or eax, ecx
jne 0x55a179
mov dword [ebp - 0x710], 0
mov dword [ebp - 0x70c], 0
mov dword [esi + 0x430], edx
mov dword [esi + 0x434], ecx
lea ecx, [ebp - 0x840]
mov dword [esi + 0x9ac], 0
call fcn.00552900
mov dword [esi + 0x868], 3
mov eax, dword [esi + 0x5c]
test eax, eax
mov dword [ebp - 0x14], 0
mov byte [ebp - 0x15], 1
je 0x55a1d8
mov eax, dword [edi]
test eax, eax
je 0x55a1cf
push 0
push 0x1472
push 0x111
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
push 1
mov ecx, esi
call fcn.00558950
mov ecx, ebx
call fcn.00401070
mov eax, 0x6874e8
test eax, eax
je 0x55a238
mov edi, eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x55a238
mov edi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push eax
push eax
push 0xffffffffffffffff
push 0x6874e8
push eax
push eax
call edi
test eax, eax
mov dword [ebx + 8], eax
je 0x55a238
lea ecx, [eax + eax + 2]
push ecx
call fcn.005a1be9
add esp, 4
mov dword [ebx], eax
test eax, eax
je 0x55a238
mov edx, dword [ebx + 8]
push edx
push eax
push 0xffffffffffffffff
push 0x6874e8
push 0
push 0
call edi
mov dword [ebx + 8], eax
lea ecx, [ebp - 0x840]
mov byte [ebp - 4], 8
call fcn.0052dd40
push 0x51fc10
push 0x10
lea eax, [ebp - 0x33ac0]
push 0x3328
push eax
mov byte [ebp - 4], 0
call fcn.00588eb7
mov al, byte [ebp - 0x15]
test al, al
jne case.default.0x55a272
mov eax, dword [esi + 0x44]
cmp eax, 5
ja case.default.0x55a272
jmp dword [eax*4 + 0x55a31c]
mov ecx, esi
call fcn.005557c0
jmp 0x55a29b
mov ecx, esi
call fcn.00554590
jmp 0x55a29b
mov ecx, esi
call fcn.00554b60
jmp 0x55a29b
mov ecx, esi
call fcn.005550b0
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
mov byte [esi + 0x301], 0
mov byte [esi + 0x179], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret