Function at 0x41d311
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x4c
mov dword [ebp - 0x24], eax
mov edi, dword [ebp + 8]
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x2c], ecx
test eax, eax
je 0x41d839
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__strdup]
mov ebx, eax
test eax, eax
je 0x41d839
mov dword [esp], eax
call sub.msvcrt.dll_strlen
mov ecx, 0x5c
mov edx, 0x2f
mov dword [ebp - 0x30], eax
mov eax, ebx
call fcn.0041d304
cmp dword [0x526c50], 3
je 0x41d370
xor eax, eax
mov dword [ebp - 0x1c], eax
jmp 0x41d4f3
cmp word [0x51331c], 0
jne 0x41d387
mov al, byte [0x51330c]
or al, byte [0x51330b]
je 0x41d366
cmp word [0x513304], 0
jne 0x41d366
cmp byte [0x513312], 0
jne 0x41d366
mov ax, word [0x5132fa]
mov edx, eax
not edx
and dl, 7
je 0x41d366
mov edx, eax
not edx
test dl, 0x23
je 0x41d366
mov eax, edx
test ax, 0x1c0
je 0x41d366
mov al, byte [0x512fa0]
or al, byte [0x51330e]
jne 0x41d366
cmp dword [0x4e2204], 0
jne 0x41d3d9
cmp dword [0x4e2200], 0
je 0x41d366
cmp byte [edi + 3], 0
jne 0x41d3f1
cmp byte [edi + 4], 0
jne 0x41d3f8
cmp byte [edi + 2], 0
je 0x41d366
jmp 0x41d3f8
mov eax, str.linux
jmp 0x41d3fd
mov eax, str.append
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], str.persistent_file_cdrom_preseed
mov dword [esp + 8], str.file_cdrom_preseed
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.00428e5e
test eax, eax
je 0x41d46c
mov dword [esp], str.__Added_persistent_kernel_option
call fcn.0043efa9
cmp byte [edi + 3], 0
je 0x41d4a4
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], 0x49e00b
mov dword [esp + 8], str.maybe_ubiquity
mov dword [esp + 4], str.linux
mov dword [esp], ebx
call fcn.00428e5e
test eax, eax
je 0x41d4a4
mov dword [esp], str.__Removed_maybe_ubiquity_kernel_option
jmp 0x41d49f
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], str.persistent_layerfs_pathminimal.standard.live.squashfs
mov dword [esp + 8], str.layerfs_pathminimal.standard.live.squashfs
mov dword [esp + 4], str.linux
mov dword [esp], ebx
call fcn.00428e5e
test eax, eax
je 0x41d4ad
mov dword [esp], str.__Added_persistent_kernel_option
call fcn.0043efa9
mov dword [ebp - 0x1c], 1
jmp 0x41d4f3
cmp byte [edi + 3], 0
mov eax, str.append
mov dword [esp], ebx
mov edx, str.linux
cmovne eax, edx
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], str.bootlive_persistence
mov dword [esp + 8], str.bootlive
mov dword [esp + 4], eax
call fcn.00428e5e
test eax, eax
je 0x41d366
mov dword [esp], str.__Added_persistence_kernel_option
jmp 0x41d49f
cmp byte [edi], 0
jne 0x41d502
cmp byte [edi + 1], 0
je 0x41d66c
mov dword [esp + 8], str.x20
mov dword [esp + 4], 0x20
mov dword [esp], 0x512da0
call fcn.00429481
mov dword [ebp - 0x20], eax
mov dword [esp + 8], str.x20
mov dword [esp + 4], 0x20
mov dword [esp], 0x512e60
call fcn.00429481
cmp dword [ebp - 0x20], 0
mov esi, eax
je 0x41d659
test eax, eax
je 0x41d659
xor ecx, ecx
xor edx, edx
mov dword [ebp - 0x38], edx
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], esi
mov eax, dword [ebp - 0x20]
mov dword [esp + 8], eax
mov eax, dword [ecx*4 + 0x49f1d0]
mov dword [ebp - 0x34], ecx
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.00428e5e
mov edx, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x34]
test eax, eax
mov eax, 1
cmovne edx, eax
cmove eax, dword [ebp - 0x1c]
inc ecx
mov dword [ebp - 0x1c], eax
cmp ecx, 7
jne 0x41d555
test edx, edx
je 0x41d5bd
mov dword [esp + 0xc], esi
mov eax, dword [ebp - 0x20]
mov dword [esp + 4], ebx
mov dword [esp + 8], eax
mov dword [esp], str.__Patched__s:__s___s_n
call fcn.0043efa9
cmp byte [0x5132f9], 0
je 0x41d659
mov dword [esp + 4], str.netinst
mov eax, dword [0x525a68]
mov dword [esp], eax
call sub.msvcrt.dll_strstr
test eax, eax
jne 0x41d659
xor ecx, ecx
xor edx, edx
mov eax, dword [ecx*4 + 0x49f1d0]
mov dword [ebp - 0x38], edx
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], str.inst.repo
mov dword [esp + 8], str.inst.stage2
mov dword [ebp - 0x34], ecx
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.00428e5e
mov edx, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x34]
test eax, eax
mov eax, 1
cmovne edx, eax
cmove eax, dword [ebp - 0x1c]
inc ecx
mov dword [ebp - 0x1c], eax
cmp ecx, 7
jne 0x41d5e7
test edx, edx
je 0x41d659
mov dword [esp + 0xc], str.inst.repo
mov dword [esp + 8], str.inst.stage2
mov dword [esp + 4], ebx
mov dword [esp], str.__Patched__s:__s___s_n
call fcn.0043efa9
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call sub.msvcrt.dll_free
mov dword [esp], esi
call sub.msvcrt.dll_free
cmp byte [edi + 2], 0
je 0x41d72c
mov eax, dword [str._efi_boot]
test eax, eax
jne 0x41d684
mov eax, 0x49ddf0
cmp dword [ebp - 0x28], 0
jne 0x41d691
mov dword [ebp - 0x28], 0x49ddf0
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x28]
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__stricmp]
test eax, eax
jne 0x41d72c
cmp dword [ebp - 0x2c], 0
jne 0x41d6b6
mov dword [ebp - 0x2c], 0x49ddf0
mov dword [esp + 4], str.isolinux.cfg
mov eax, dword [ebp - 0x2c]
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__stricmp]
test eax, eax
jne 0x41d72c
cmp byte [0x51330a], 0
jne 0x41d72c
mov dword [esp], ebx
call dword [sym.imp.msvcrt.dll__strdup]
mov esi, eax
test eax, eax
je 0x41d72c
mov eax, dword [ebp - 0x30]
mov byte [esi + eax - 0xc], 0x73
mov byte [esi + eax - 0xb], 0x79
mov byte [esi + eax - 0xa], 0x73
mov dword [esp + 8], 1
mov dword [esp + 4], esi
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.DLL_CopyFileA]
sub esp, 0xc
mov dword [esp + 8], esi
mov dword [esp + 4], ebx
mov dword [esp], str.Duplicated__s_to__s_n
call fcn.0043efa9
mov dword [esp], esi
call sub.msvcrt.dll_free
cmp byte [edi + 3], 0
je 0x41d809
mov dword [esp], 0x104
call sub.msvcrt.dll_malloc
mov dword [esp], 0x104
mov edi, eax
call sub.msvcrt.dll_malloc
mov esi, eax
test edi, edi
je 0x41d7f9
test eax, eax
je 0x41d7f9
mov edx, dword [sym.imp.msvcrt.dll__snprintf]
mov dword [esp + 0xc], 0x512da0
mov dword [esp + 8], str.cd9660:_dev_iso9660__s
mov dword [esp + 4], 0x104
mov dword [esp], edi
mov dword [ebp - 0x20], edx
call edx
mov byte [edi + 0x103], 0
mov dword [esp + 0xc], 0x512e60
mov dword [esp + 8], str.msdosfs:_dev_msdosfs__s
mov dword [esp + 4], 0x104
mov dword [esp], esi
mov edx, dword [ebp - 0x20]
call edx
mov byte [esi + 0x103], 0
mov dword [esp + 0x10], 1
mov dword [esp + 0xc], esi
mov dword [esp + 8], edi
mov dword [esp + 4], 0x49e17c
mov dword [esp], ebx
call fcn.00428e5e
test eax, eax
je 0x41d7f9
mov dword [esp + 0xc], esi
mov dword [esp + 8], edi
mov dword [esp + 4], ebx
mov dword [esp], str.__Patched__s:__s___s_n
call fcn.0043efa9
mov dword [ebp - 0x1c], 1
mov dword [esp], edi
call sub.msvcrt.dll_free
mov dword [esp], esi
call sub.msvcrt.dll_free
cmp dword [ebp - 0x1c], 0
je 0x41d82a
mov dword [esp + 8], 1
mov eax, dword [ebp - 0x24]
mov dword [esp], 0x513584
mov dword [esp + 4], eax
call fcn.0043d662
mov dword [ebp + 8], ebx
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
jmp sub.msvcrt.dll_free
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret