Function at 0x40e310
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x4a8
mov edi, edx
mov esi, ecx
lea ebx, [ecx + 1]
test byte [ecx], 1
mov eax, ebx
je 0x40e330
mov eax, dword [esi + 8]
push 4
push eax
call sub.api_ms_win_crt_filesystem_l1_1_0.dll__access
add esp, 8
test eax, eax
jne 0x40ebcb
mov dword [esp + 0x64], 0
lea eax, [esp + 0x64]
push esi
push eax
call fcn.00484b90
add esp, 8
cmp dword [esp + 0x64], 0
je 0x40ebde
mov dword [esp + 0x54], 0
mov dword [esp + 0x50], 0
mov dword [esp + 0x58], 0
lea ecx, [esp + 0x50]
push edi
call fcn.00424040
movzx eax, byte [esp + 0x50]
test al, 1
je 0x40e395
mov eax, dword [esp + 0x54]
jmp 0x40e397
shr eax, 1
lea esi, [esp + 0xa0]
test eax, eax
jne 0x40e3ee
push esi
call fcn.00403090
add esp, 4
test byte [esp + 0x50], 1
je 0x40e3d4
mov eax, dword [esp + 0x58]
mov byte [eax], 0
mov dword [esp + 0x54], 0
test byte [esp + 0x50], 1
je 0x40e3d4
push dword [esp + 0x58]
call fcn.00420e70
add esp, 4
mov eax, dword [esp + 0xa8]
mov dword [esp + 0x58], eax
movsd xmm0, qword [esp + 0xa0]
movsd qword [esp + 0x50], xmm0
mov dword [esp + 0x7c], 0
mov dword [esp + 0x78], 0
mov dword [esp + 0x80], 0
mov edi, dword [esp + 0x64]
push edi
call fcn.0048f7d0
add esp, 4
mov dword [esp + 0x4c], edi
mov edi, dword [edi + 0x30]
mov dword [esp + 0x6c], 0
mov dword [esp + 0x68], 0
mov dword [esp + 0x70], 0
lea ecx, [esp + 0x68]
push eax
push ecx
call fcn.00493930
add esp, 8
movzx eax, byte [esp + 0x68]
test al, 1
je 0x40e457
mov eax, dword [esp + 0x6c]
cmp eax, 5
je 0x40e45e
jmp 0x40e476
shr eax, 1
cmp eax, 5
jne 0x40e476
lea ecx, [esp + 0x68]
push 5
push 0x5803a9
push 0xffffffffffffffff
push 0
call fcn.00425f30
test eax, eax
je 0x40e4ec
mov esi, dword [0x5b12f0]
push 0x20
call fcn.00420cd0
add esp, 4
mov dword [esp + 0xa8], eax
mov dword [esp + 0xa0], 0x21
mov dword [esp + 0xa4], 0x15
movsd xmm0, qword [0x5834df]
movsd qword [eax + 0xd], xmm0
movups xmm0, xmmword [str.oem_allow_flash_super]
movups xmmword [eax], xmm0
mov byte [eax + 0x15], 0
mov ecx, esi
lea esi, [esp + 0xa0]
push 0
push 0
push 0
push esi
call fcn.00477520
test byte [esp + 0xa0], 1
je 0x40e4ec
push dword [esp + 0xa8]
call fcn.00420e70
add esp, 4
push 0x401
push 0
push esi
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
add esp, 0xc
mov ecx, esi
call fcn.00429f60
mov ecx, dword [esp + 0x4c]
mov eax, dword [ecx + 0x15c]
sub eax, dword [ecx + 0x158]
cmp eax, 0x41
jb 0x40e566
mov dword [esp + 0x34], 0
mov dword [esp + 0x30], 0
mov dword [esp + 0x38], 0
push esi
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
cmp eax, 0xfffffff0
jae 0x40ebc2
mov ebx, eax
cmp eax, 0xb
jae 0x40e6a7
mov eax, ebx
add al, bl
mov byte [esp + 0x30], al
lea esi, [esp + 0x31]
test ebx, ebx
jne 0x40e6d3
jmp 0x40e6e5
mov dword [esp + 0x20], 0
mov dword [esp + 0x24], 0
mov dword [esp + 0x28], 0
mov word [esp + 0x20], 0x2f02
lea ecx, [esp + 0x20]
push esi
push 0
call fcn.004250b0
mov ecx, dword [eax + 8]
mov dword [esp + 8], ecx
movsd xmm0, qword [eax]
movsd qword [esp], xmm0
mov dword [eax], 0
mov dword [eax + 4], 0
mov dword [eax + 8], 0
movzx eax, byte [esp + 0x68]
test al, 1
je 0x40e5c8
mov edx, dword [esp + 0x70]
mov eax, dword [esp + 0x6c]
jmp 0x40e5ce
shr eax, 1
lea edx, [esp + 0x69]
mov ecx, esp
push eax
push edx
call fcn.004248f0
mov ecx, dword [eax + 8]
mov dword [esp + 0x18], ecx
movsd xmm0, qword [eax]
movsd qword [esp + 0x10], xmm0
mov dword [eax], 0
mov dword [eax + 8], 0
mov dword [eax + 4], 0
lea esi, [esp + 0x10]
mov ecx, esi
push 0x58095c
call fcn.00424b40
mov ecx, dword [eax + 8]
mov dword [esp + 0x38], ecx
movsd xmm0, qword [eax]
movsd qword [esp + 0x30], xmm0
mov dword [eax + 4], 0
mov dword [eax + 8], 0
mov dword [eax], 0
test byte [esp + 0x10], 1
jne 0x40e680
test byte [esp], 1
jne 0x40e692
test byte [esp + 0x20], 1
je 0x40e651
push dword [esp + 0x28]
call fcn.00420e70
add esp, 4
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x10], eax
lea eax, [esp + 0x30]
push 1
push esi
push edi
push dword [esp + 0x58]
push eax
call fcn.00486ed0
jmp 0x40e717
push dword [esp + 0x18]
call fcn.00420e70
add esp, 4
test byte [esp], 1
je 0x40e63e
push dword [esp + 8]
call fcn.00420e70
add esp, 4
test byte [esp + 0x20], 1
jne 0x40e645
jmp 0x40e651
mov dword [esp + 0x60], edi
mov edi, ebx
or ebx, 0xf
lea eax, [ebx + 1]
push eax
call fcn.00420cd0
add esp, 4
mov esi, eax
mov dword [esp + 0x38], eax
add ebx, 2
mov dword [esp + 0x30], ebx
mov ebx, edi
mov edi, dword [esp + 0x60]
mov dword [esp + 0x34], ebx
push ebx
lea eax, [esp + 0xa4]
push eax
push esi
call sub.api_ms_win_crt_private_l1_1_0.dll_memcpy
add esp, 0xc
mov byte [esi + ebx], 0
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x10], eax
lea esi, [esp + 0x10]
lea eax, [esp + 0x30]
push 1
push esi
push edi
push dword [esp + 0x58]
push eax
call fcn.00486f60
add esp, 0x14
mov ebx, eax
mov ecx, esi
push dword [esp + 0x14]
call fcn.004148a0
test byte [esp + 0x30], 1
je 0x40e73a
push dword [esp + 0x38]
call fcn.00420e70
add esp, 4
test bl, bl
je 0x40eb4a
mov eax, dword [esp + 0x4c]
mov edi, dword [eax + 0x158]
mov ecx, dword [eax + 0x15c]
mov al, 1
mov dword [esp + 0x74], eax
mov dword [esp + 0x98], ecx
cmp edi, ecx
je 0x40eb60
lea ebx, [esp + 0x10]
lea esi, [esp + 0x30]
jmp 0x40e790
add edi, 0x40
cmp edi, dword [esp + 0x98]
je 0x40eb60
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0x18], 0
push edi
push ebx
call fcn.00493930
add esp, 8
mov edx, dword [edi + 0x3c]
mov dword [esp + 4], 0
mov dword [esp], 0
mov dword [esp + 8], 0
mov ecx, dword [esp + 0x4c]
mov eax, dword [ecx + 0x15c]
sub eax, dword [ecx + 0x158]
cmp eax, 0x41
mov dword [esp + 0x60], edi
mov dword [esp + 0x9c], edx
jb 0x40e8a0
push ebx
push 0x583518
push esi
call fcn.00428410
add esp, 0xc
mov ecx, esi
push 0x58095c
call fcn.00424b40
movzx ebx, byte [eax]
mov ecx, dword [eax + 4]
mov dword [esp + 0x23], ecx
mov ecx, dword [eax + 1]
mov dword [esp + 0x20], ecx
mov edi, dword [eax + 8]
mov dword [eax + 4], 0
mov dword [eax], 0
mov dword [eax + 8], 0
test byte [esp], 1
je 0x40e85a
mov eax, dword [esp + 8]
mov byte [eax], 0
mov dword [esp + 4], 0
test byte [esp], 1
je 0x40e85a
push dword [esp + 8]
call fcn.00420e70
add esp, 4
mov byte [esp], bl
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x23]
lea edx, [esp + 1]
mov dword [edx + 3], ecx
mov dword [edx], eax
mov dword [esp + 8], edi
test byte [esp + 0x30], 1
je 0x40e885
push dword [esp + 0x38]
call fcn.00420e70
add esp, 4
mov edi, dword [esp + 0x60]
lea ebx, [esp + 0x10]
lea esi, [esp + 0x30]
jmp 0x40e987
mov dword [esp + 0x34], 0
mov dword [esp + 0x30], 0
mov dword [esp + 0x38], 0
movzx ebx, byte [esp + 0x10]
test bl, 1
je 0x40e8d0
mov ebx, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
jmp 0x40e8d6
shr ebx, 1
lea ecx, [esp + 0x11]
lea esi, [ebx + 4]
cmp esi, 0xfffffff0
jae 0x40ebc2
cmp esi, 0xb
jae 0x40e900
mov eax, ebx
add al, bl
mov byte [esp + 0x30], al
lea edi, [esp + 0x31]
test ebx, ebx
jne 0x40e924
jmp 0x40e92f
or esi, 0xf
lea eax, [esi + 1]
push eax
mov edi, ecx
call fcn.00420cd0
mov ecx, edi
add esp, 4
mov edi, eax
mov dword [esp + 0x38], eax
add esi, 2
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], ebx
push ebx
push ecx
push edi
call sub.api_ms_win_crt_private_l1_1_0.dll_memcpy
add esp, 0xc
mov byte [edi + ebx], 0
lea esi, [esp + 0x30]
mov ecx, esi
push 4
push 0x58095c
call fcn.004248f0
test byte [esp], 1
je 0x40e96c
mov eax, dword [esp + 8]
mov byte [eax], 0
mov dword [esp + 4], 0
test byte [esp], 1
je 0x40e96c
push dword [esp + 8]
call fcn.00420e70
add esp, 4
mov eax, dword [esp + 0x38]
mov dword [esp + 8], eax
movsd xmm0, qword [esp + 0x30]
movsd qword [esp], xmm0
mov edi, dword [esp + 0x60]
lea ebx, [esp + 0x10]
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x28], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov dword [esp + 0x90], 0
mov word [esp + 0x88], 0x2f02
lea ecx, [esp + 0x88]
lea eax, [esp + 0xa0]
push eax
push 0
call fcn.004250b0
mov ecx, dword [eax + 8]
mov dword [esp + 0x38], ecx
movsd xmm0, qword [eax]
movsd qword [esp + 0x30], xmm0
mov dword [eax], 0
mov dword [eax + 4], 0
mov dword [eax + 8], 0
movzx eax, byte [esp]
test al, 1
je 0x40ea20
mov edx, dword [esp + 8]
mov eax, dword [esp + 4]
jmp 0x40ea26
shr eax, 1
lea edx, [esp + 1]
mov ecx, esi
push eax
push edx
call fcn.004248f0
mov ecx, dword [eax + 8]
mov dword [esp + 0x28], ecx
movsd xmm0, qword [eax]
movsd qword [esp + 0x20], xmm0
mov dword [eax + 4], 0
mov dword [eax + 8], 0
mov dword [eax], 0
test byte [esp + 0x30], 1
je 0x40ea67
push dword [esp + 0x38]
call fcn.00420e70
add esp, 4
test byte [esp + 0x88], 1
je 0x40ea80
push dword [esp + 0x90]
call fcn.00420e70
add esp, 4
mov ecx, dword [esp + 0x9c]
and ecx, 1
mov dword [esp + 0x30], 0x583528
lea eax, [esp + 0x20]
mov dword [esp + 0x34], eax
mov dword [esp + 0x40], esi
push ecx
push esi
lea eax, [esp + 0x58]
push eax
push ebx
call fcn.00403270
add esp, 0x10
mov ecx, dword [esp + 0x40]
cmp ecx, esi
je 0x40ead0
test ecx, ecx
je 0x40eadb
mov eax, dword [ecx]
add eax, 0x14
jmp 0x40ead9
mov eax, dword [esp + 0x30]
add eax, 0x10
mov ecx, esi
call dword [eax]
test byte [esp + 0x20], 1
lea eax, [esp + 0x21]
je 0x40eaea
mov eax, dword [esp + 0x28]
push eax
call sub.api_ms_win_crt_filesystem_l1_1_0.dll__unlink
add esp, 4
test byte [esp + 0x20], 1
jne 0x40eb10
test byte [esp], 1
jne 0x40eb22
test byte [esp + 0x10], 1
je 0x40e780
jmp 0x40eb39
push dword [esp + 0x28]
call fcn.00420e70
add esp, 4
test byte [esp], 1
je 0x40eb00
push dword [esp + 8]
call fcn.00420e70
add esp, 4
test byte [esp + 0x10], 1
je 0x40e780
push dword [esp + 0x18]
call fcn.00420e70
add esp, 4
jmp 0x40e780
lea ecx, [esp + 0x78]
push str.Could_not_generate_a_flashable_super_image_file
call fcn.00424d80
mov dword [esp + 0x74], 0
lea ecx, [esp + 0xa0]
call fcn.0042a240
test byte [esp + 0x68], 1
je 0x40eb7f
push dword [esp + 0x70]
call fcn.00420e70
add esp, 4
cmp byte [esp + 0x74], 0
je 0x40ebf1
test byte [esp + 0x78], 1
je 0x40eb9c
push dword [esp + 0x80]
call fcn.00420e70
add esp, 4
test byte [esp + 0x50], 1
je 0x40ebaf
push dword [esp + 0x58]
call fcn.00420e70
add esp, 4
lea ecx, [esp + 0x64]
push 0
call fcn.004149c0
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
lea ecx, [esp + 0x30]
call fcn.00423df0
test byte [esi], 1
je 0x40ebd3
mov ebx, dword [esi + 8]
push ebx
push str.Could_not_read_image:__s
call fcn.004291c0
test byte [esi], 1
je 0x40ebe6
mov ebx, dword [esi + 8]
push ebx
push str.Could_not_parse_image:__s
call fcn.004291c0
lea eax, [esp + 0x78]
push eax
call fcn.00429220
nop dword [eax + eax]