Function at 0x401680
Capabilities:
Create thread
Terminate process

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x404f30
mov eax, dword fs:[0]
push eax
sub esp, 0x150
mov eax, dword [0x408018]
xor eax, esp
mov dword [esp + 0x148], eax
push ebx
push esi
push edi
mov eax, dword [0x408018]
xor eax, esp
push eax
lea eax, [esp + 0x160]
mov dword fs:[0], eax
mov esi, dword [ebp + 0xc]
xor ebx, ebx
mov edi, 0xf
mov dword [esp + 0x150], edi
mov dword [esp + 0x14c], ebx
mov byte [esp + 0x13c], bl
push str.iTunesFlash.exe_start_ok._n
mov dword [esp + 0x16c], ebx
call fcn.00401410
mov eax, dword [ebp + 8]
add esp, 4
cmp eax, 6
jne 0x401be1
mov dword [esp + 0x6c], edi
mov dword [esp + 0x68], ebx
mov byte [esp + 0x58], bl
mov dword [esp + 0x50], edi
mov dword [esp + 0x4c], ebx
mov byte [esp + 0x3c], bl
mov byte [esp + 0x168], 2
mov eax, dword [esi + 4]
xor ecx, ecx
mov word [esp + 0x90], cx
mov ecx, eax
mov dword [esp + 0xa4], 7
mov dword [esp + 0xa0], ebx
lea edi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x401743
sub ecx, edi
sar ecx, 1
push ecx
lea ecx, [esp + 0x94]
call fcn.00402180
mov byte [esp + 0x168], 3
mov eax, dword [esi + 8]
xor edx, edx
mov ecx, eax
mov dword [esp + 0xdc], 7
mov dword [esp + 0xd8], ebx
mov word [esp + 0xc8], dx
lea edi, [ecx + 2]
jmp 0x401790
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x401790
sub ecx, edi
sar ecx, 1
push ecx
lea ecx, [esp + 0xcc]
call fcn.00402180
mov byte [esp + 0x168], 4
mov eax, dword [esi + 0x10]
xor ecx, ecx
mov word [esp + 0xac], cx
mov ecx, eax
mov dword [esp + 0xc0], 7
mov dword [esp + 0xbc], ebx
lea edi, [ecx + 2]
jmp 0x4017e0
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x4017e0
sub ecx, edi
sar ecx, 1
push ecx
lea ecx, [esp + 0xb0]
call fcn.00402180
mov byte [esp + 0x168], 5
mov eax, dword [esi + 0x14]
xor edx, edx
mov ecx, eax
mov dword [esp + 0x88], 7
mov dword [esp + 0x84], ebx
mov word [esp + 0x74], dx
lea edi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x401825
sub ecx, edi
sar ecx, 1
push ecx
lea ecx, [esp + 0x78]
call fcn.00402180
mov byte [esp + 0x168], 6
mov eax, dword [esi + 4]
push eax
mov dword [esp + 0x1c], ebx
call dword [sym.imp.MSVCR100.dll__wtoi]
mov edx, dword [esi + 8]
add esp, 4
mov edi, 0x10
push edi
lea ecx, [esp + 0x1c]
push ecx
push edx
mov dword [esp + 0x20], eax
call dword [sym.imp.MSVCR100.dll__wcstoui64]
mov dword [0x408740], eax
mov eax, dword [esi + 0xc]
add esp, 0xc
push eax
lea eax, [esp + 0x5c]
mov dword [0x408744], edx
call fcn.004011c0
mov ecx, dword [esi + 0x10]
add esp, 4
push ecx
lea eax, [esp + 0x40]
call fcn.004011c0
mov edx, dword [esi + 0x14]
add esp, 4
push edx
mov eax, 0x408068
call fcn.004011c0
mov eax, dword [esp + 0x5c]
add esp, 4
cmp dword [esp + 0x6c], edi
jae 0x4018bd
lea eax, [esp + 0x58]
push eax
push str.ipsw_unzip_path:_s_n
call fcn.00401410
mov eax, dword [esp + 0x44]
add esp, 8
cmp dword [esp + 0x50], edi
jae 0x4018d9
lea eax, [esp + 0x3c]
push eax
push str.log_path:_s_n
call fcn.00401410
mov eax, dword [0x408068]
add esp, 8
cmp dword [0x40807c], edi
jae 0x4018f9
mov eax, 0x408068
push eax
push str.callback_path:_s_n
call fcn.00401410
mov eax, dword [0x408744]
mov ecx, dword [0x408740]
push eax
push ecx
push str.input_ECID:__016llx_n
call fcn.00401410
mov edi, 0xf
add esp, 0x14
mov dword [esp + 0x10c], edi
mov dword [esp + 0x108], ebx
mov byte [esp + 0xf8], bl
mov dword [esp + 0x128], edi
mov dword [esp + 0x124], ebx
mov byte [esp + 0x114], bl
lea edx, [esp + 0xe4]
push edx
mov byte [esp + 0x16c], 8
call fcn.00403b10
lea eax, [esp + 0xe4]
mov dword [0x40874c], eax
mov dword [esp + 0xe4], 0x402b80
mov dword [esp + 0xe8], 0x402d10
mov dword [esp + 0x130], ebx
mov byte [esp + 0x168], 9
lea ecx, [esp + 0x58]
mov dword [esp + 0x2c], ebx
mov byte [esp + 0x1c], bl
push ecx
or eax, 0xffffffff
xor ebx, ebx
lea ecx, [esp + 0x20]
mov dword [esp + 0x34], edi
call fcn.00401cb0
lea edx, [esp + 0x1c]
push edx
or eax, 0xffffffff
lea ecx, [esp + 0xfc]
mov byte [esp + 0x16c], 0xa
call fcn.00401cb0
mov esi, 0x10
mov byte [esp + 0x168], 9
cmp dword [esp + 0x30], esi
jb 0x4019ef
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov ecx, dword [esp + 0x14]
xor ebx, ebx
cmp dword [esp + 0x50], esi
mov esi, dword [esp + 0x3c]
mov dword [esp + 0x30], edi
mov dword [esp + 0x2c], ebx
mov byte [esp + 0x1c], bl
mov dword [esp + 0x130], ecx
jae 0x401a16
lea esi, [esp + 0x3c]
push 0x7fffffff
call dword [0x408414]
add esp, 4
push esi
call dword [0x408724]
mov edx, dword [esp + 0xe8]
add esp, 4
push ebx
push 0xdeadbeef
push edx
call dword [0x4083fc]
add esp, 0xc
mov dword [esp + 0x134], eax
lea eax, [esp + 0x14]
push eax
push ebx
push ebx
push 0x402940
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, ebx
jne 0x401a6c
push 1
call dword [sym.imp.MSVCR100.dll_exit]
call dword [sym.imp.MSVCR100.dll_getchar]
mov esi, 0x10
cmp dword [esp + 0x128], esi
jb 0x401a91
mov ecx, dword [esp + 0x114]
push ecx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [esp + 0x128], edi
mov dword [esp + 0x124], ebx
mov byte [esp + 0x114], bl
cmp dword [esp + 0x10c], esi
jb 0x401ac0
mov edx, dword [esp + 0xf8]
push edx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [esp + 0x10c], edi
mov edi, 8
mov dword [esp + 0x108], ebx
mov byte [esp + 0xf8], bl
cmp dword [esp + 0x88], edi
jb 0x401af1
mov eax, dword [esp + 0x74]
push eax
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor ecx, ecx
mov esi, 7
mov dword [esp + 0x88], esi
mov dword [esp + 0x84], ebx
mov word [esp + 0x74], cx
cmp dword [esp + 0xc0], edi
jb 0x401b25
mov edx, dword [esp + 0xac]
push edx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor eax, eax
mov dword [esp + 0xc0], esi
mov dword [esp + 0xbc], ebx
mov word [esp + 0xac], ax
cmp dword [esp + 0xdc], edi
jb 0x401b57
mov ecx, dword [esp + 0xc8]
push ecx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor edx, edx
cmp dword [esp + 0xa4], edi
mov edi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
mov dword [esp + 0xdc], esi
mov dword [esp + 0xd8], ebx
mov word [esp + 0xc8], dx
jb 0x401b8b
mov eax, dword [esp + 0x90]
push eax
call edi
add esp, 4
mov dword [esp + 0xa4], esi
xor ecx, ecx
mov esi, 0x10
mov dword [esp + 0xa0], ebx
mov word [esp + 0x90], cx
cmp dword [esp + 0x50], esi
jb 0x401bb8
mov edx, dword [esp + 0x3c]
push edx
call edi
add esp, 4
mov byte [esp + 0x168], bl
mov dword [esp + 0x50], 0xf
mov dword [esp + 0x4c], ebx
mov byte [esp + 0x3c], bl
cmp dword [esp + 0x6c], esi
jb 0x401bfd
mov eax, dword [esp + 0x58]
push eax
call edi
add esp, 4
jmp 0x401bfd
push eax
push str.iTunesFlash.exe_paramters_is_error.argc:_d_
call fcn.00401410
mov ecx, dword [ebp + 8]
push ecx
push str._2_niTunesFlash.exe_paramters_is_error.argc:_d_
call fcn.00401290
add esp, 0x10
push str.iTunesFlash.exe_exit._n
call fcn.00401410
mov edx, dword [0x408748]
add esp, 4
push edx
call dword [sym.imp.MSVCR100.dll_fclose]
add esp, 4
mov eax, 1
mov ecx, dword [esp + 0x160]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x148]
xor ecx, esp
call fcn.00404370
mov esp, ebp
pop ebp
ret