Function at 0x140015440
Capabilities:
Delete file

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f]
sub rsp, 0xa8
mov rax, qword [0x14002e008]
xor rax, rsp
mov qword [rbp + 7], rax
xor eax, eax
mov qword [rbp - 0x49], rcx
lea rcx, str.About_to_send_BasebandData..._n
mov qword [rbp - 0x19], rax
mov rbx, r9
mov qword [rbp - 9], rax
mov r13, r8
mov qword [rbp - 0x11], rax
lea r15, [rax - 1]
mov qword [rbp - 0x39], rax
mov r14, rdx
mov qword [rbp - 0x29], rax
mov qword [rbp - 0x21], rax
mov esi, eax
mov r12d, eax
mov qword [rbp - 0x51], rax
call fcn.140002320
lea rdx, str.Arguments
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_dict_get_item]
mov rbx, rax
test rax, rax
je 0x1400155a9
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 5
jne 0x1400155a9
lea rdx, str.ChipID
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_dict_get_item]
mov rdi, rax
test rax, rax
je 0x140015508
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 1
jne 0x140015508
lea rdx, [rbp - 0x21]
mov rcx, rdi
call qword [sym.imp.plist.dll_plist_get_uint_val]
lea rdx, str.CertID
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_dict_get_item]
mov rdi, rax
test rax, rax
je 0x14001553b
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 1
jne 0x14001553b
lea rdx, [rbp - 0x19]
mov rcx, rdi
call qword [sym.imp.plist.dll_plist_get_uint_val]
lea rdx, str.ChipSerialNo
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_dict_get_item]
mov rdi, rax
test rax, rax
je 0x140015572
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 7
jne 0x140015572
lea r8, [rbp - 0x11]
mov rcx, rdi
lea rdx, [rbp - 9]
call qword [sym.imp.plist.dll_plist_get_data_val]
lea rdx, str.Nonce
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_dict_get_item]
mov rbx, rax
test rax, rax
je 0x1400155a9
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 7
jne 0x1400155a9
lea r8, [rbp - 0x29]
mov rcx, rbx
lea rdx, [rbp - 0x39]
call qword [sym.imp.plist.dll_plist_get_data_val]
cmp qword [rbp - 0x39], rsi
je 0x1400155bd
mov rax, qword [r14 + 0x68]
cmp qword [rax + 8], rsi
jne 0x140015834
call qword [sym.imp.plist.dll_plist_new_dict]
mov rcx, qword [r14 + 0x20]
mov rbx, rax
call qword [sym.imp.plist.dll_plist_new_uint]
lea rdx, str.ApECID
mov rcx, rbx
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rcx, qword [rbp - 0x39]
test rcx, rcx
je 0x140015609
mov rdx, qword [rbp - 0x29]
call qword [sym.imp.plist.dll_plist_new_data]
lea rdx, str.BbNonce
mov rcx, rbx
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rcx, qword [rbp - 0x21]
call qword [sym.imp.plist.dll_plist_new_uint]
lea rdx, str.BbChipID
mov rcx, rbx
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rcx, qword [rbp - 0x19]
call qword [sym.imp.plist.dll_plist_new_uint]
lea rdx, str.BbGoldCertId
mov rcx, rbx
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rdx, qword [rbp - 0x11]
mov rcx, qword [rbp - 9]
call qword [sym.imp.plist.dll_plist_new_data]
lea rdx, str.BbSNUM
mov rcx, rbx
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rdx, r13
mov rcx, rbx
call fcn.140018e50
call fcn.140018d70
mov rdi, rax
test rax, rax
jne 0x140015690
lea rcx, str.ERROR:_Unable_to_create_Baseband_TSS_request_n
call fcn.1400023a0
mov rcx, rbx
jmp 0x140015a98
xor r8d, r8d
mov rdx, rbx
mov rcx, rdi
call fcn.140019970
mov rdx, rbx
mov rcx, rdi
call fcn.14001a110
lea r9, str.FDRSupport
mov edx, 2
lea r8, str.Info
mov rcx, r13
call qword [sym.imp.plist.dll_plist_access_path]
mov rsi, rax
test rax, rax
je 0x140015727
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
test eax, eax
jne 0x140015727
lea rdx, [rbp - 1]
mov byte [rbp - 1], r12b
mov rcx, rsi
call qword [sym.imp.plist.dll_plist_get_bool_val]
cmp byte [rbp - 1], r12b
je 0x140015727
mov cl, 1
call qword [sym.imp.plist.dll_plist_new_bool]
lea rdx, str.ApProductionMode
mov rcx, rdi
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov cl, 1
call qword [sym.imp.plist.dll_plist_new_bool]
lea rdx, str.ApSecurityMode
mov rcx, rdi
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
cmp dword [0x14002eae0], r12d
je 0x140015786
xor eax, eax
lea r8, [rbp + 3]
lea rdx, [rbp - 0x41]
mov dword [rbp + 3], eax
mov rcx, rdi
mov qword [rbp - 0x41], rax
call qword [sym.imp.plist.dll_plist_to_xml]
mov r8d, dword [rbp + 3]
lea rdx, str.d:_a1_sidevicerestore_srccommon.c
cmp r8d, 0x10000
ja 0x140015770
mov r9, qword [rbp - 0x41]
lea rcx, str._s:printing__i_bytes_plist:_n_s
call fcn.140002320
jmp 0x14001577c
lea rcx, str._s:supressed_printing__i_bytes_plist..._n
call fcn.140002320
mov rcx, qword [rbp - 0x41]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rcx, str.Sending_Baseband_TSS_request..._n
call fcn.140002320
mov rdx, qword [r14 + 0x10]
mov rcx, rdi
call fcn.14001ba30
mov rcx, rdi
mov rsi, rax
call qword [sym.imp.plist.dll_plist_free]
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_free]
test rsi, rsi
jne 0x1400157c9
lea rcx, str.ERROR:_Unable_to_fetch_Baseband_TSS_n
call fcn.1400023a0
jmp 0x140015a9e
lea rcx, str.Received_Baseband_SHSH_blobs_n
call fcn.140002320
cmp dword [0x14002eae0], r12d
je 0x140015834
xor eax, eax
lea r8, [rbp + 3]
lea rdx, [rbp - 0x41]
mov dword [rbp + 3], eax
mov rcx, rsi
mov qword [rbp - 0x41], rax
call qword [sym.imp.plist.dll_plist_to_xml]
mov r8d, dword [rbp + 3]
lea rdx, str.d:_a1_sidevicerestore_srccommon.c
cmp r8d, 0x10000
ja 0x14001581e
mov r9, qword [rbp - 0x41]
lea rcx, str._s:printing__i_bytes_plist:_n_s
call fcn.140002320
jmp 0x14001582a
lea rcx, str._s:supressed_printing__i_bytes_plist..._n
call fcn.140002320
mov rcx, qword [rbp - 0x41]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rax, str.Path
mov edx, 4
mov qword [rsp + 0x28], rax
lea r9, str.BasebandFirmware
lea rax, str.Info
mov rcx, r13
lea r8, str.Manifest
mov qword [rsp + 0x20], rax
call qword [sym.imp.plist.dll_plist_access_path]
mov rbx, rax
test rax, rax
je 0x140015a89
mov rcx, rax
call qword [sym.imp.plist.dll_plist_get_node_type]
cmp eax, 3
jne 0x140015a89
xor r13d, r13d
lea rdx, [rbp - 0x31]
mov rcx, rbx
mov qword [rbp - 0x31], r13
call qword [sym.imp.plist.dll_plist_get_string_val]
cmp qword [rbp - 0x31], r12
jne 0x1400158ac
lea rcx, str.ERROR:_Unable_to_get_baseband_path_n
jmp 0x140015a90
lea rcx, str.bbfw_
call fcn.140002b50
mov rdi, rax
test rax, rax
jne 0x140015935
mov rax, qword [r14 + 0x40]
mov rdx, r15
mov rbx, rdx
nop word [rax + rax]
inc rbx
cmp byte [rax + rbx], r12b
jne 0x1400158d0
mov rcx, rbx
add rcx, 0xa
cmovb rcx, rdx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rdi, rax
mov r8, rbx
mov eax, dword [str.bbfw_]
mov dword [rdi], eax
lea rcx, [rdi + 5]
movzx eax, word [0x140026668]
mov word [rdi + 4], ax
mov rdx, qword [r14 + 0x40]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
mov eax, dword [str..tmp]
lea rcx, str.WARNING:_Could_not_generate_temporary_filename__using__s_in_current_directory_n
mov dword [rbx + rdi + 5], eax
mov rdx, rdi
movzx eax, byte [0x14001ff70]
mov byte [rbx + rdi + 9], al
call fcn.1400023a0
mov rdx, qword [rbp - 0x31]
mov r8, rdi
mov rcx, qword [r14 + 0x50]
call fcn.14000e210
test eax, eax
je 0x140015992
lea rcx, str.ERROR:_Unable_to_extract_baseband_firmware_from_ipsw_n
call fcn.1400023a0
mov rbx, r12
mov rcx, rbx
call qword [sym.imp.plist.dll_plist_free]
mov rcx, r12
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
test rdi, rdi
je 0x140015981
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_remove]
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, rsi
call qword [sym.imp.plist.dll_plist_free]
mov eax, r15d
jmp 0x140015aa1
mov r8, qword [rbp - 0x39]
test r8, r8
je 0x1400159b0
mov rax, qword [r14 + 0x68]
cmp qword [rax + 8], r12
jne 0x1400159b0
mov qword [rax + 8], rsi
mov rsi, r13
mov r8, qword [rbp - 0x39]
mov rax, qword [r14 + 0x68]
mov rdx, rsi
mov rcx, qword [rax + 8]
test rcx, rcx
cmovne rdx, rcx
mov rcx, rdi
call fcn.1400143e0
mov r15d, eax
test eax, eax
jne 0x140015955
lea r8, [rbp - 0x41]
mov qword [rbp - 0x41], r13
lea rdx, [rbp - 0x51]
mov rcx, rdi
mov r15, 0xffffffffffffffff
call fcn.1400024d0
test eax, eax
jns 0x140015a08
lea rcx, str.ERROR:_could_not_read_updated_bbfw_archive_n
call fcn.1400023a0
mov r12, qword [rbp - 0x51]
mov rbx, r13
jmp 0x140015958
call qword [sym.imp.plist.dll_plist_new_dict]
mov rdx, qword [rbp - 0x41]
mov r12, rax
mov rcx, qword [rbp - 0x51]
mov qword [rbp - 0x59], rax
call qword [sym.imp.plist.dll_plist_new_data]
lea rdx, str.BasebandData
mov rcx, r12
mov r8, rax
call qword [sym.imp.plist.dll_plist_dict_set_item]
mov rcx, qword [rbp - 0x51]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rcx, str.Sending_BasebandData_now..._n
mov r12, r13
call fcn.140002320
mov rbx, qword [rbp - 0x59]
mov rcx, qword [rbp - 0x49]
mov rdx, rbx
call qword [sym.imp.imobiledevice.dll_restored_send]
test eax, eax
je 0x140015a75
lea rcx, str.ERROR:_Unable_to_send_BasebandData_data_n
call fcn.1400023a0
jmp 0x140015958
lea rcx, str.Done_sending_BasebandData_n
call fcn.140002320
mov r15d, r13d
jmp 0x140015958
lea rcx, str.ERROR:_Unable_to_get_BasebandFirmware_Info_Path_node_n
call fcn.1400023a0
mov rcx, rsi
call qword [sym.imp.plist.dll_plist_free]
mov rax, r15
mov rcx, qword [rbp + 7]
xor rcx, rsp
call fcn.14001bfa0
add rsp, 0xa8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret