Function at 0x4172fa
Capabilities:
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2178
call fcn.00612c90
mov eax, dword [0x6ffe74]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x2178], ecx
push ebx
push ebx
push 3
push ebx
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [ebp - 0x2170], edi
cmp edi, 0xffffffff
jne 0x41734a
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x417818
push ebx
push ebx
push ebx
push 2
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov ebx, eax
mov dword [ebp - 0x2174], ebx
test ebx, ebx
jne 0x417375
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x417818
xor eax, eax
push eax
push eax
push eax
push 4
push ebx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x2158], eax
test eax, eax
jne 0x417398
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x41780c
and dword [ebp - 0x215c], 0
lea eax, [ebp - 0x215c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp dword [ebp - 0x215c], 0
mov esi, eax
jne 0x4177ff
push 0x3e7
lea eax, [ebp - 0x158b]
mov byte [ebp - 0x158c], 0
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x7dc], 0
lea eax, [ebp - 0x7db]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x1d5c], 0
lea eax, [ebp - 0x1d5b]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x1974], 0
lea eax, [ebp - 0x1973]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0xfac], 0
lea eax, [ebp - 0xfab]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0xbc4], 0
lea eax, [ebp - 0xbc3]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x2144], 0
lea eax, [ebp - 0x2143]
push 0x3e7
push 0
push eax
call fcn.006390b0
add esp, 0xc
mov byte [ebp - 0x3f4], 0
lea eax, [ebp - 0x3f3]
push 0x3e7
push 0
push eax
call fcn.006390b0
mov ecx, dword [ebp - 0x2158]
add esp, 0xc
mov edx, dword [ecx]
imul eax, edx, 0xd
mov dword [ebp - 0x216c], edx
add eax, 0xc
cmp eax, esi
ja 0x417805
and dword [ebp - 0x2160], 0
add eax, ecx
mov dword [ebp - 0x2164], eax
lea eax, [ecx + 4]
test edx, edx
je 0x417750
mov esi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov edi, eax
mov ebx, dword [ebp - 0x2164]
push 0xd
lea eax, [ebp - 0x2154]
push edi
push eax
call fcn.00638b30
mov eax, dword [ebp - 0x2153]
add esp, 0xc
cmp eax, 0x8100
jb 0x417722
cmp eax, 0x8200
ja 0x41773e
mov ecx, 0x8195
cmp eax, ecx
ja 0x4175ca
je 0x4175a2
sub eax, 0x8159
je 0x41757a
sub eax, 0x20
je 0x417552
sub eax, 5
je 0x417722
dec eax
sub eax, 1
je 0x417722
sub eax, 0x14
je 0x4175ec
jmp 0x417722
mov eax, dword [ebp - 0x214f]
add eax, ebx
cmp byte [ebp - 0x2154], 3
jne 0x41756e
lea ecx, [ebp - 0x7dc]
jmp 0x4176fa
push eax
lea eax, [ebp - 0x7dc]
jmp 0x417714
mov eax, dword [ebp - 0x214f]
add eax, ebx
cmp byte [ebp - 0x2154], 3
jne 0x417596
lea ecx, [ebp - 0x158c]
jmp 0x4176fa
push eax
lea eax, [ebp - 0x158c]
jmp 0x417714
mov eax, dword [ebp - 0x214f]
add eax, ebx
cmp byte [ebp - 0x2154], 3
jne 0x4175be
lea ecx, [ebp - 0xbc4]
jmp 0x4176fa
push eax
lea eax, [ebp - 0xbc4]
jmp 0x417714
sub eax, 0x819e
je 0x4176e3
sub eax, 8
je 0x417696
sub eax, 1
je 0x417639
sub eax, 0x16
jne 0x417722
mov eax, dword [ebp - 0x214f]
xor edx, edx
add eax, ebx
mov byte [ebp - 0x3f4], dl
cmp byte [ebp - 0x2154], 3
jne 0x41761c
push edx
push edx
push 0x3e8
lea ecx, [ebp - 0x3f4]
push ecx
push 0xffffffffffffffff
push eax
push edx
push edx
call esi
jmp 0x417631
push eax
lea eax, [ebp - 0x3f4]
push 0x2710
push eax
call fcn.006494f3
add esp, 0xc
lea edx, [ebp - 0x2144]
jmp 0x417684
mov eax, dword [ebp - 0x214f]
xor edx, edx
add eax, ebx
mov byte [ebp - 0x3f4], dl
cmp byte [ebp - 0x2154], 3
jne 0x417669
push edx
push edx
push 0x3e8
lea ecx, [ebp - 0x3f4]
push ecx
push 0xffffffffffffffff
push eax
push edx
push edx
call esi
jmp 0x41767e
push eax
lea eax, [ebp - 0x3f4]
push 0x2710
push eax
call fcn.006494f3
add esp, 0xc
lea edx, [ebp - 0x1d5c]
push ecx
lea ecx, [ebp - 0x3f4]
call fcn.004171f5
pop ecx
jmp 0x417722
mov eax, dword [ebp - 0x214f]
xor edx, edx
add eax, ebx
mov byte [ebp - 0x3f4], dl
cmp byte [ebp - 0x2154], 3
jne 0x4176c6
push edx
push edx
push 0x3e8
lea ecx, [ebp - 0x3f4]
push ecx
push 0xffffffffffffffff
push eax
push edx
push edx
call esi
jmp 0x4176db
push eax
lea eax, [ebp - 0x3f4]
push 0x2710
push eax
call fcn.006494f3
add esp, 0xc
lea edx, [ebp - 0x1974]
jmp 0x417684
mov eax, dword [ebp - 0x214f]
add eax, ebx
cmp byte [ebp - 0x2154], 3
jne 0x41770d
lea ecx, [ebp - 0xfac]
xor edx, edx
push edx
push edx
push 0x3e8
push ecx
push 0xffffffffffffffff
push eax
push edx
push edx
call esi
jmp 0x417722
push eax
lea eax, [ebp - 0xfac]
push 0x2710
push eax
call fcn.006494f3
add esp, 0xc
mov eax, dword [ebp - 0x2160]
add edi, 0xd
inc eax
mov dword [ebp - 0x2160], eax
cmp eax, dword [ebp - 0x216c]
jb 0x4174e8
mov edi, dword [ebp - 0x2170]
mov ebx, dword [ebp - 0x2174]
mov ecx, dword [ebp - 0x2158]
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call esi
push edi
call esi
lea eax, [ebp - 0x7dc]
push str.imap
push eax
call fcn.00639500
test eax, eax
mov edx, str.IMAP
mov ecx, str.POP3
lea eax, [ebp - 0x11a4]
cmovne ecx, edx
push ecx
push 0x1f4
push eax
call fcn.006494f3
mov ecx, dword [ebp - 0x2178]
lea eax, [ebp - 0x1974]
add esp, 0x14
mov ebx, 0x6c5bb9
mov edi, 0x101
push 0xffffffffffffffff
push ebx
push eax
lea eax, [ebp - 0x1d5c]
push eax
lea eax, [ebp - 0x7dc]
push eax
lea eax, [ebp - 0x11a4]
push eax
push edi
push 2
call fcn.0043ee6b
push 0xffffffffffffffff
push ebx
lea eax, [ebp - 0x2144]
push eax
lea ecx, [ebp - 0xbc4]
push ecx
lea ecx, [ebp - 0xfac]
push ecx
mov ecx, dword [ebp - 0x2178]
push str.SMTP
push edi
push 2
call fcn.0043ee6b
xor eax, eax
inc eax
jmp 0x41781a
mov ecx, dword [ebp - 0x2158]
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call esi
push edi
call esi
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.006122f0
leave
ret 4