Function at 0x48bf50
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4b0
mov dword [ebp - 0x8c], edx
lea edx, [ebp - 0xb0]
push esi
mov esi, ecx
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x94], 0xff
call fcn.0048ba70
test eax, eax
je 0x48bfa9
mov eax, dword [esi + 4]
mov dword [ebp - 0x64], eax
cdq
xor eax, edx
sub eax, edx
mov dword [esi + 4], eax
cmp eax, 0x1000000
jbe 0x48bfb0
mov eax, dword fs:[0x2c]
mov eax, dword [eax]
mov dword [eax + 0xc], str.too_large
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
cmp dword [esi], 0x1000000
ja 0x48bf97
mov eax, dword [ebp - 0xa4]
mov edx, dword [ebp - 0x90]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0xa0]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x9c]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp - 0x98]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x94]
push ebx
mov ebx, dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0xa8]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x1c], edx
push edi
mov edi, dword [ebp - 0xac]
mov dword [ebp - 0x50], edi
cmp eax, 0xc
jne 0x48c035
mov eax, dword [ebp - 0xb0]
mov dword [ebp - 0x30], eax
cmp eax, 0x18
jge 0x48c056
mov ecx, edi
mov eax, 0x55555556
sub ecx, edx
sub ecx, 0x18
imul ecx
mov ebx, edx
shr ebx, 0x1f
add ebx, edx
jmp 0x48c04c
mov ecx, dword [ebp - 0xb0]
mov dword [ebp - 0x30], ecx
cmp ecx, 0x10
jge 0x48c056
mov ebx, edi
sub ebx, edx
sub ebx, eax
sar ebx, 2
mov dword [ebp - 0x18], ebx
test ebx, ebx
jne 0x48c0b6
mov ebx, dword [ebp - 0xc]
mov ecx, dword [esi + 0xa8]
mov eax, ecx
sub eax, dword [esi + 0xb4]
mov edx, dword [esi + 0xac]
add eax, edx
cmp edi, eax
je 0x48c090
push 0x1515
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.info.offset__s__callback_already_read___int___s__img_buffer___s__img_buffer_original_
call ebx
mov edx, dword [esi + 0xac]
add esp, 0xc
mov ecx, dword [esi + 0xa8]
sub ecx, esi
lea eax, [edx - 0x28]
add eax, ecx
cmp edi, eax
je 0x48c0b6
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax]
mov dword [eax + 0xc], str.bad_offset
xor eax, eax
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x30], 0x18
mov ecx, dword [ebp - 0x20]
jne 0x48c0ce
cmp ecx, 0xff000000
jne 0x48c0ce
mov eax, 3
jmp 0x48c0d8
xor eax, eax
test ecx, ecx
setne al
add eax, 3
mov dword [esi + 8], eax
mov ecx, dword [esi]
mov ebx, dword [esi + 4]
mov dword [ebp - 0x10], eax
test ecx, ecx
js 0x48d227
je 0x48c101
mov eax, 0x7fffffff
cdq
idiv ecx
cmp dword [ebp - 0x10], eax
jg 0x48d227
mov eax, dword [ebp - 0x10]
mov edi, eax
imul edi, ecx
test edi, edi
js 0x48d227
test ebx, ebx
js 0x48d227
je 0x48c128
mov eax, 0x7fffffff
cdq
idiv ebx
cmp edi, eax
jg 0x48d227
test ecx, ecx
je 0x48c13e
xor edx, edx
mov eax, 0x7fffffff
div ecx
cmp dword [ebp - 0x10], eax
jg 0x48d20c
test ebx, ebx
je 0x48c153
xor edx, edx
mov eax, 0x7fffffff
div ebx
cmp edi, eax
jg 0x48d20c
mov eax, dword [ebp - 0x10]
imul eax, ecx
imul eax, ebx
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov ebx, eax
add esp, 4
mov dword [ebp - 0x68], ebx
test ebx, ebx
je 0x48d20c
xor edi, edi
cmp dword [ebp - 0x30], 0x10
jge 0x48c913
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x48c8ee
cmp eax, 0x100
jg 0x48c8ee
mov dword [ebp - 0x24], edi
test eax, eax
jle 0x48c3e5
mov eax, dword [esi + 0xac]
lea ebx, [esi + 0xac]
xor edx, edx
nop
mov ecx, dword [esi + 0xb0]
cmp eax, ecx
jae 0x48c1c6
mov dl, byte [eax]
lea edi, [eax + 1]
mov byte [ebp - 1], dl
mov eax, edi
jmp 0x48c215
cmp dword [esi + 0x20], 0
je 0x48c24a
push dword [esi + 0x24]
mov eax, dword [esi + 0x10]
lea edi, [esi + 0x28]
push edi
push dword [esi + 0x1c]
call eax
mov ecx, dword [ebx]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c200
lea ecx, [esi + 0x29]
mov dword [esi + 0x20], eax
mov dword [esi + 0xb0], ecx
mov byte [edi], al
jmp 0x48c20b
lea ecx, [esi + 0x28]
add ecx, eax
mov dword [esi + 0xb0], ecx
mov al, byte [edi]
mov byte [ebp - 1], al
lea eax, [edi + 1]
mov edi, eax
mov dword [ebx], edi
mov edx, ecx
mov edi, dword [ebp - 0x24]
shl edi, 2
mov dword [ebp - 0x14], ebx
mov bl, byte [ebp - 1]
mov dword [ebp - 0xc], edi
mov byte [ebp + edi - 0x4ae], bl
lea ebx, [esi + 0xac]
mov dword [ebp - 0x14], edi
cmp eax, ecx
jae 0x48c25f
mov bl, byte [eax]
inc eax
mov byte [ebp - 1], bl
lea ebx, [esi + 0xac]
jmp 0x48c2b3
shl edx, 2
mov dword [ebp - 0xc], edx
mov byte [ebp + edx - 0x4ae], 0
mov edx, ecx
mov ecx, dword [ebp - 0xc]
jmp 0x48c262
mov ecx, dword [ebp - 0x14]
cmp dword [esi + 0x20], 0
je 0x48c2e1
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [ebx]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c29d
lea ecx, [esi + 0x29]
mov dword [esi + 0x20], eax
mov dword [esi + 0xb0], ecx
mov byte [esi + 0x28], al
jmp 0x48c2a8
lea ecx, [esi + 0x28]
add ecx, eax
mov dword [esi + 0xb0], ecx
mov al, byte [esi + 0x28]
mov edx, ecx
mov byte [ebp - 1], al
lea eax, [esi + 0x29]
mov dword [ebp - 0x2c], ebx
mov ebx, eax
mov edi, dword [ebp - 0x2c]
mov dword [ebp - 0x14], eax
mov dword [edi], ebx
mov edi, dword [ebp - 0xc]
mov bl, byte [ebp - 1]
mov byte [ebp + edi - 0x4af], bl
lea ebx, [esi + 0xac]
cmp eax, ecx
jae 0x48c2e9
mov cl, byte [eax]
inc eax
mov byte [ebp - 1], cl
mov dword [ebx], eax
jmp 0x48c346
mov byte [ebp + ecx - 0x4af], 0
cmp dword [esi + 0x20], 0
je 0x48c342
push dword [esi + 0x24]
mov eax, dword [esi + 0x10]
lea edi, [esi + 0x28]
push edi
push dword [esi + 0x1c]
call eax
mov ecx, dword [ebx]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c32b
lea edx, [esi + 0x29]
mov dword [esi + 0x20], eax
mov dword [esi + 0xb0], edx
mov byte [edi], al
mov byte [ebp - 1], al
lea eax, [edi + 1]
mov dword [ebx], eax
jmp 0x48c346
lea edx, [esi + 0x28]
add edx, eax
mov dword [esi + 0xb0], edx
mov al, byte [edi]
mov byte [ebp - 1], al
lea eax, [edi + 1]
mov dword [ebx], eax
jmp 0x48c346
mov byte [ebp - 1], 0
cmp dword [ebp - 8], 0xc
mov ecx, dword [ebp - 0xc]
mov bl, byte [ebp - 1]
mov byte [ebp + ecx - 0x4b0], bl
lea ebx, [esi + 0xac]
je 0x48c3c4
cmp eax, edx
jae 0x48c368
inc eax
mov dword [ebx], eax
jmp 0x48c3c4
cmp dword [esi + 0x20], 0
je 0x48c3c4
push dword [esi + 0x24]
mov eax, dword [esi + 0x10]
lea edi, [esi + 0x28]
push edi
push dword [esi + 0x1c]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c3a7
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
mov byte [edi], 0
jmp 0x48c3b2
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
mov ecx, dword [ebp - 0xc]
lea eax, [edi + 1]
mov dword [esi + 0xac], eax
lea ebx, [esi + 0xac]
mov edx, dword [ebp - 0x24]
inc edx
mov byte [ebp + ecx - 0x4ad], 0xff
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x24], edx
cmp edx, ecx
jl 0x48c1b0
mov ebx, dword [ebp - 0x68]
xor edi, edi
jmp 0x48c3e8
mov ecx, dword [ebp - 0x18]
xor eax, eax
cmp dword [ebp - 8], 0xc
setne al
add eax, 3
imul eax, ecx
mov ecx, dword [ebp - 0x50]
sub ecx, eax
sub ecx, dword [ebp - 0x1c]
sub ecx, dword [ebp - 8]
je 0x48c44a
test ecx, ecx
jns 0x48c416
mov eax, dword [esi + 0xb0]
mov dword [esi + 0xac], eax
jmp 0x48c44a
cmp dword [esi + 0x10], 0
je 0x48c444
mov edx, dword [esi + 0xb0]
mov eax, edx
sub eax, dword [esi + 0xac]
cmp eax, ecx
jge 0x48c444
sub ecx, eax
mov dword [esi + 0xac], edx
mov eax, dword [esi + 0x14]
push ecx
push dword [esi + 0x1c]
call eax
add esp, 8
jmp 0x48c44a
add dword [esi + 0xac], ecx
mov edx, dword [ebp - 0x30]
cmp edx, 1
jne 0x48c45c
mov eax, dword [esi]
add eax, 7
shr eax, 3
jmp 0x48c473
cmp edx, 4
jne 0x48c468
mov eax, dword [esi]
inc eax
shr eax, 1
jmp 0x48c473
cmp edx, 8
jne 0x48c8c9
mov eax, dword [esi]
mov ecx, dword [esi + 4]
neg eax
and eax, 3
mov dword [ebp - 0x2c], eax
cmp edx, 1
jne 0x48c6b0
mov dword [ebp - 8], 0
mov edx, ecx
mov dword [ebp - 0x18], edx
test ecx, ecx
jle 0x48c8c1
nop dword [eax + eax]
mov eax, dword [esi + 0xac]
mov ecx, 7
mov dword [ebp - 0x20], ecx
cmp eax, dword [esi + 0xb0]
jae 0x48c4c1
mov dl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48c52e
cmp dword [esi + 0x20], 0
je 0x48c52c
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c510
mov ecx, dword [ebp - 0x20]
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov dl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c52e
mov ecx, dword [ebp - 0x20]
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov dl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c52e
xor dl, dl
movzx eax, dl
xor edx, edx
mov dword [ebp - 0x14], eax
cmp dword [esi], edx
jle 0x48c657
nop
sar eax, cl
and eax, 1
lea ecx, [eax*4]
movzx eax, byte [ebp + ecx - 0x4b0]
mov byte [edi + ebx], al
movzx eax, byte [ebp + ecx - 0x4af]
mov byte [edi + ebx + 1], al
movzx eax, byte [ebp + ecx - 0x4ae]
mov byte [edi + ebx + 2], al
add edi, 3
cmp dword [ebp - 0x10], 4
jne 0x48c57d
mov byte [edi + ebx], 0xff
inc edi
mov ecx, dword [esi]
inc edx
mov dword [ebp - 0x1c], edx
cmp edx, ecx
je 0x48c657
sub dword [ebp - 0x20], 1
jns 0x48c649
mov eax, dword [esi + 0xac]
mov dword [ebp - 0x20], 7
cmp eax, dword [esi + 0xb0]
jae 0x48c5c1
mov dl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
movzx eax, dl
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jmp 0x48c64c
cmp dword [esi + 0x20], 0
je 0x48c63c
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c618
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov dl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
mov ecx, dword [esi]
movzx eax, dl
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jmp 0x48c64c
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov dl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
mov ecx, dword [esi]
movzx eax, dl
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jmp 0x48c64c
xor dl, dl
movzx eax, dl
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jmp 0x48c64c
mov eax, dword [ebp - 0x14]
cmp edx, ecx
mov ecx, dword [ebp - 0x20]
jl 0x48c540
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x48c692
cmp dword [esi + 0x10], 0
je 0x48c68c
mov edx, dword [esi + 0xb0]
mov ecx, edx
sub ecx, dword [esi + 0xac]
cmp ecx, eax
jge 0x48c68c
sub eax, ecx
mov dword [esi + 0xac], edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
add esp, 8
jmp 0x48c692
add dword [esi + 0xac], eax
mov eax, dword [ebp - 8]
mov ecx, dword [esi + 4]
inc eax
mov dword [ebp - 8], eax
mov edx, ecx
mov dword [ebp - 0x18], edx
cmp eax, ecx
jl 0x48c4a0
mov eax, ecx
jmp 0x48d121
xor edx, edx
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x34], edx
test ecx, ecx
jle 0x48c8c1
cmp dword [esi], 0
mov dword [ebp - 0x24], 0
jle 0x48c874
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48c6e9
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48c750
cmp dword [esi + 0x20], 0
je 0x48c74e
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c735
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c750
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c750
xor cl, cl
xor edx, edx
movzx ecx, cl
cmp dword [ebp - 0x30], 4
jne 0x48c763
mov edx, ecx
and edx, 0xf
shr ecx, 4
movzx eax, byte [ebp + ecx*4 - 0x4b0]
mov byte [edi + ebx], al
movzx eax, byte [ebp + ecx*4 - 0x4af]
mov byte [edi + ebx + 1], al
movzx eax, byte [ebp + ecx*4 - 0x4ae]
mov byte [edi + ebx + 2], al
add edi, 3
cmp dword [ebp - 0x10], 4
jne 0x48c794
mov byte [edi + ebx], 0xff
inc edi
mov ecx, dword [ebp - 0x24]
lea eax, [ecx + 1]
cmp eax, dword [esi]
je 0x48c871
cmp dword [ebp - 0x30], 8
jne 0x48c832
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48c7c5
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48c82c
cmp dword [esi + 0x20], 0
je 0x48c82a
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48c811
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c82c
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48c82c
xor cl, cl
movzx edx, cl
mov ecx, dword [ebp - 0x24]
movzx eax, byte [ebp + edx*4 - 0x4b0]
mov byte [edi + ebx], al
movzx eax, byte [ebp + edx*4 - 0x4af]
mov byte [edi + ebx + 1], al
movzx eax, byte [ebp + edx*4 - 0x4ae]
mov byte [edi + ebx + 2], al
add edi, 3
cmp dword [ebp - 0x10], 4
jne 0x48c863
mov byte [edi + ebx], 0xff
inc edi
add ecx, 2
mov dword [ebp - 0x24], ecx
cmp ecx, dword [esi]
jl 0x48c6d0
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x48c8af
cmp dword [esi + 0x10], 0
je 0x48c8a9
mov edx, dword [esi + 0xb0]
mov ecx, edx
sub ecx, dword [esi + 0xac]
cmp ecx, eax
jge 0x48c8a9
sub eax, ecx
mov dword [esi + 0xac], edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
mov eax, dword [ebp - 0x2c]
add esp, 8
jmp 0x48c8af
add dword [esi + 0xac], eax
inc dword [ebp - 0x34]
mov ecx, dword [esi + 4]
mov dword [ebp - 0x18], ecx
cmp dword [ebp - 0x34], ecx
jl 0x48c6c0
mov eax, dword [ebp - 0x18]
jmp 0x48d121
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword fs:[0x2c]
add esp, 4
mov eax, dword [eax]
pop edi
pop ebx
pop esi
mov dword [eax + 0xc], str.bad_bpp
xor eax, eax
mov esp, ebp
pop ebp
ret
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword fs:[0x2c]
add esp, 4
mov eax, dword [eax]
pop edi
pop ebx
pop esi
mov dword [eax + 0xc], str.invalid
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x50]
sub eax, dword [ebp - 0x1c]
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x5c], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x54], edi
sub eax, dword [ebp - 8]
je 0x48c9a1
test eax, eax
jns 0x48c96e
mov eax, dword [esi + 0xb0]
mov dword [esi + 0xac], eax
jmp 0x48c9a1
cmp dword [esi + 0x10], edi
je 0x48c99b
mov edx, dword [esi + 0xb0]
mov ecx, edx
sub ecx, dword [esi + 0xac]
cmp ecx, eax
jge 0x48c99b
sub eax, ecx
mov dword [esi + 0xac], edx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
add esp, 8
jmp 0x48c9a1
add dword [esi + 0xac], eax
mov ecx, dword [ebp - 0x30]
cmp ecx, 0x18
jne 0x48c9b0
mov eax, dword [esi]
lea eax, [eax + eax*2]
jmp 0x48c9bd
cmp ecx, 0x10
jne 0x48c9bb
mov eax, dword [esi]
add eax, eax
jmp 0x48c9bd
xor eax, eax
neg eax
and eax, 3
mov dword [ebp - 0x60], eax
cmp ecx, 0x18
jne 0x48c9d8
mov dword [ebp - 0x54], 1
xor edx, edx
jmp 0x48cba6
mov edx, dword [ebp - 0x48]
cmp ecx, 0x20
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x38]
jne 0x48ca14
cmp edx, 0xff
jne 0x48ca14
cmp eax, 0xff00
jne 0x48ca14
cmp ecx, 0xff0000
jne 0x48ca14
cmp dword [ebp - 0x20], 0xff000000
jne 0x48ca2c
mov dword [ebp - 0x54], 2
xor edx, edx
jmp 0x48cba6
test ecx, ecx
je 0x48d1e7
test eax, eax
je 0x48d1e7
test edx, edx
je 0x48d1e7
call fcn.0048ba10
sub eax, 7
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x38]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x3c]
movzx eax, al
mov dword [ebp - 0x40], eax
call fcn.0048ba10
sub eax, 7
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x3c]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x48]
movzx eax, al
mov dword [ebp - 0x44], eax
call fcn.0048ba10
sub eax, 7
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x48]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x20]
movzx eax, al
mov dword [ebp - 0x2c], eax
call fcn.0048ba10
sub eax, 7
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x20]
mov edx, eax
and eax, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, eax
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
cmp dword [ebp - 0x40], 8
movzx eax, al
mov dword [ebp - 0x24], eax
ja 0x48d1e7
cmp dword [ebp - 0x44], 8
ja 0x48d1e7
mov edx, dword [ebp - 0x2c]
cmp edx, 8
ja 0x48d1e7
cmp eax, 8
ja 0x48d1e7
mov ecx, dword [esi + 4]
mov eax, ecx
mov dword [ebp - 0x50], edi
mov dword [ebp - 0x18], eax
test ecx, ecx
jle 0x48d121
mov eax, dword [ebp - 0x58]
neg eax
mov dword [ebp - 0x6c], eax
mov eax, 8
sub eax, dword [ebp - 0x40]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x5c]
neg eax
mov dword [ebp - 0x74], eax
mov eax, 8
sub eax, dword [ebp - 0x44]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x34]
neg eax
mov dword [ebp - 0x7c], eax
mov eax, 8
sub eax, edx
mov dword [ebp - 0x80], eax
mov eax, dword [ebp - 0x14]
neg eax
mov dword [ebp - 0x84], eax
mov eax, 8
sub eax, dword [ebp - 0x24]
mov dword [ebp - 0x88], eax
nop word [eax + eax]
cmp dword [ebp - 0x54], 0
mov eax, dword [esi]
mov dword [ebp - 0x1c], 0
je 0x48ce74
test eax, eax
jle 0x48d0cd
nop dword [eax + eax]
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48cc49
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48ccb0
cmp dword [esi + 0x20], 0
je 0x48ccae
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48cc95
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48ccb0
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48ccb0
xor cl, cl
mov byte [edi + ebx + 2], cl
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48cccd
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48cd34
cmp dword [esi + 0x20], 0
je 0x48cd32
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48cd19
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48cd34
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48cd34
xor cl, cl
mov byte [edi + ebx + 1], cl
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48cd51
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48cdb8
cmp dword [esi + 0x20], 0
je 0x48cdb6
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48cd9d
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48cdb8
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48cdb8
xor cl, cl
mov byte [edi + ebx], cl
add edi, 3
cmp dword [ebp - 0x54], 2
jne 0x48ce4a
mov eax, dword [esi + 0xac]
cmp eax, dword [esi + 0xb0]
jae 0x48cde1
mov cl, byte [eax]
inc eax
mov dword [esi + 0xac], eax
jmp 0x48ce4d
cmp dword [esi + 0x20], 0
je 0x48ce46
push dword [esi + 0x24]
lea eax, [esi + 0x28]
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x10]
call eax
mov ecx, dword [esi + 0xac]
add esp, 0xc
sub ecx, dword [esi + 0xb4]
add dword [esi + 0xa8], ecx
test eax, eax
jne 0x48ce2d
mov dword [esi + 0x20], eax
lea eax, [esi + 0x29]
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov byte [esi + 0x28], 0
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48ce4d
add eax, 0x28
add eax, esi
mov dword [esi + 0xb0], eax
lea eax, [esi + 0x29]
mov cl, byte [esi + 0x28]
mov dword [esi + 0xac], eax
jmp 0x48ce4d
xor cl, cl
jmp 0x48ce4d
or cl, 0xff
movzx eax, cl
or dword [ebp - 0x4c], eax
cmp dword [ebp - 0x10], 4
jne 0x48ce5d
mov byte [edi + ebx], cl
inc edi
mov ecx, dword [ebp - 0x1c]
inc ecx
mov dword [ebp - 0x1c], ecx
cmp ecx, dword [esi]
jl 0x48cc30
mov dword [ebp - 0x28], edi
jmp 0x48d0cd
test eax, eax
jle 0x48d0cd
nop dword [eax]
mov ecx, esi
call fcn.00482930
cmp dword [ebp - 0x30], 0x10
mov edi, eax
je 0x48cea0
mov ecx, esi
call fcn.00482930
shl eax, 0x10
add eax, edi
mov dword [ebp - 8], eax
mov edi, eax
mov ecx, dword [ebp - 0x58]
mov edx, edi
and edx, dword [ebp - 0x38]
mov eax, edx
shr eax, cl
mov ecx, dword [ebp - 0x6c]
shl edx, cl
cmp dword [ebp - 0x58], 0
cmovge edx, eax
mov dword [ebp - 8], edx
cmp edx, 0x100
jb 0x48cedb
push 0x148e
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.v___256
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x70]
shr edx, cl
mov ecx, dword [ebp - 0x40]
mov dword [ebp - 8], edx
cmp ecx, 8
jbe 0x48cf06
push 0x1490
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.bits___0__bits___8
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x40]
mov eax, dword [ecx*4 + 0x4c0c54]
mov ecx, dword [ecx*4 + 0x4c0c98]
imul eax, edx
mov edx, edi
and edx, dword [ebp - 0x3c]
sar eax, cl
mov ecx, dword [ebp - 0x28]
mov byte [ecx + ebx], al
inc ecx
mov eax, edx
mov dword [ebp - 0x28], ecx
mov ecx, dword [ebp - 0x5c]
shr eax, cl
mov ecx, dword [ebp - 0x74]
shl edx, cl
cmp dword [ebp - 0x5c], 0
cmovge edx, eax
mov dword [ebp - 8], edx
cmp edx, 0x100
jb 0x48cf5e
push 0x148e
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.v___256
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x78]
shr edx, cl
mov ecx, dword [ebp - 0x44]
mov dword [ebp - 8], edx
cmp ecx, 8
jbe 0x48cf89
push 0x1490
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.bits___0__bits___8
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x44]
mov eax, dword [ecx*4 + 0x4c0c54]
mov ecx, dword [ecx*4 + 0x4c0c98]
imul eax, edx
mov edx, edi
and edx, dword [ebp - 0x48]
sar eax, cl
mov ecx, dword [ebp - 0x28]
mov byte [ecx + ebx], al
inc ecx
mov eax, edx
mov dword [ebp - 0x28], ecx
mov ecx, dword [ebp - 0x34]
shr eax, cl
mov ecx, dword [ebp - 0x7c]
shl edx, cl
cmp dword [ebp - 0x34], 0
cmovge edx, eax
mov dword [ebp - 8], edx
cmp edx, 0x100
jb 0x48cfe1
push 0x148e
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.v___256
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x80]
shr edx, cl
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 8], edx
cmp ecx, 8
jbe 0x48d00c
push 0x1490
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.bits___0__bits___8
call dword [ebp - 0xc]
mov edx, dword [ebp - 8]
add esp, 0xc
mov ecx, dword [ebp - 0x2c]
mov eax, dword [ecx*4 + 0x4c0c54]
mov ecx, dword [ecx*4 + 0x4c0c98]
imul eax, edx
sar eax, cl
mov ecx, dword [ebp - 0x28]
mov byte [ecx + ebx], al
inc ecx
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x28], ecx
test eax, eax
je 0x48d0a6
mov edx, dword [ebp - 0x14]
and edi, eax
mov eax, edi
mov ecx, edx
shr eax, cl
mov ecx, dword [ebp - 0x84]
shl edi, cl
test edx, edx
cmovns edi, eax
cmp edi, 0x100
jb 0x48d069
push 0x148e
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.v___256
call dword [ebp - 0xc]
add esp, 0xc
mov ecx, dword [ebp - 0x88]
shr edi, cl
mov ecx, dword [ebp - 0x24]
cmp ecx, 8
jbe 0x48d091
push 0x1490
push str.d:CProjectsSCUMSX2_srcImGuiFileDialog_stb_stb_image.h
push str.bits___0__bits___8
call dword [ebp - 0xc]
mov ecx, dword [ebp - 0x24]
add esp, 0xc
mov eax, dword [ecx*4 + 0x4c0c54]
mov ecx, dword [ecx*4 + 0x4c0c98]
imul eax, edi
sar eax, cl
jmp 0x48d0ab
mov eax, 0xff
or dword [ebp - 0x4c], eax
cmp dword [ebp - 0x10], 4
mov edi, dword [ebp - 0x28]
jne 0x48d0be
mov byte [edi + ebx], al
inc edi
mov dword [ebp - 0x28], edi
mov ecx, dword [ebp - 0x1c]
inc ecx
mov dword [ebp - 0x1c], ecx
cmp ecx, dword [esi]
jl 0x48ce80
mov edx, dword [ebp - 0x60]
test edx, edx
je 0x48d10a
cmp dword [esi + 0x10], 0
je 0x48d104
mov eax, dword [esi + 0xb0]
mov ecx, eax
sub ecx, dword [esi + 0xac]
cmp ecx, edx
jge 0x48d104
mov dword [esi + 0xac], eax
mov eax, edx
sub eax, ecx
push eax
push dword [esi + 0x1c]
mov eax, dword [esi + 0x14]
call eax
add esp, 8
jmp 0x48d10a
add dword [esi + 0xac], edx
mov edx, dword [ebp - 0x50]
mov ecx, dword [esi + 4]
inc edx
mov dword [ebp - 0x50], edx
mov eax, ecx
mov dword [ebp - 0x18], eax
cmp edx, ecx
jl 0x48cc10
cmp dword [ebp - 0x10], 4
mov edx, eax
jne 0x48d14e
cmp dword [ebp - 0x4c], 0
jne 0x48d14e
mov eax, dword [esi]
mov edx, dword [ebp - 0x18]
imul eax, ecx
lea eax, [eax*4 - 1]
test eax, eax
js 0x48d14e
mov byte [eax + ebx], 0xff
sub eax, 4
jns 0x48d142
mov edx, dword [esi + 4]
cmp dword [ebp - 0x64], 0
jle 0x48d1c0
xor edi, edi
mov dword [ebp - 0x1c], edi
test edx, 0xfffffffe
jle 0x48d1c0
mov ecx, dword [esi]
sub edx, edi
mov eax, dword [ebp - 0x10]
dec edx
imul eax, ecx
imul eax, edi
xor edi, edi
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x10]
imul edx, eax
imul eax, ecx
imul edx, ecx
mov dword [ebp - 0x60], edx
add edx, ebx
test eax, eax
jle 0x48d1ae
mov ebx, dword [ebp - 0x64]
sub ebx, dword [ebp - 0x60]
nop
mov al, byte [edx]
lea edx, [edx + 1]
mov cl, byte [ebx + edx - 1]
inc edi
mov byte [ebx + edx - 1], al
mov byte [edx - 1], cl
mov eax, dword [esi]
imul eax, dword [ebp - 0x10]
cmp edi, eax
jl 0x48d190
mov ebx, dword [ebp - 0x68]
mov edi, dword [ebp - 0x1c]
mov edx, dword [esi + 4]
inc edi
mov eax, edx
mov dword [ebp - 0x1c], edi
sar eax, 1
cmp edi, eax
jl 0x48d161
mov ecx, dword [ebp - 0x8c]
mov eax, dword [esi]
mov dword [ecx], eax
mov eax, dword [ebp + 8]
mov ecx, dword [esi + 4]
mov dword [eax], ecx
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x48d1de
mov eax, dword [esi + 8]
mov dword [ecx], eax
pop edi
mov eax, ebx
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword fs:[0x2c]
add esp, 4
mov eax, dword [eax]
pop edi
pop ebx
pop esi
mov dword [eax + 0xc], str.bad_masks
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax]
mov dword [eax + 0xc], str.outofmem
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword fs:[0x2c]
pop edi
pop ebx
pop esi
mov eax, dword [eax]
mov dword [eax + 0xc], str.too_large
xor eax, eax
mov esp, ebp
pop ebp
ret