Function at 0x401590
Capabilities:
Encrypt data using rc4 ksa
Get file size
Read file on windows

Disassembly:
sub esp, 0x434
mov eax, dword [0x484004]
xor eax, esp
mov dword [esp + 0x42c], eax
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x5c]
push eax
mov esi, ecx
mov ebx, edx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
call fcn.004013c0
push ebx
lea edi, [esi + 0x48]
push 0x200
push edi
call fcn.0043c5ed
add esp, 0xc
push 0
push 0x20
push 3
push 0
push 0
push SysReAllocStringLen
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esi + 0x24], eax
je 0x401646
lea ecx, [esi + 0x4fe4]
push ecx
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileTime]
mov edx, dword [esi + 0x24]
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea ecx, [esp + 0x14]
push ecx
push 0x20
lea edi, [esi + 0x448]
push edi
push edx
mov dword [esi + 0x20], 0
call ebp
mov eax, dword [esp + 0x10]
add dword [esi + 0x20], eax
push 9
push str.ADCLABFFS
push edi
call fcn.0043ba95
mov ecx, dword [esi + 0x24]
add esp, 0xc
test eax, eax
je 0x40164d
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x402b34
push 0
lea edx, [esp + 0x14]
push edx
push 0x34
lea eax, [esi + 0x468]
push eax
push ecx
call ebp
fld qword [esi + 0x490]
movsx eax, byte [esi + 0x498]
fstp dword [esi + 0x4ff0]
mov edx, dword [esp + 0x10]
mov ebx, dword [0x488ae8]
add dword [esi + 0x20], edx
mov edi, dword [esi + 0x20]
push 0x477f94
push 0x477f88
push ebx
mov dword [esi + 0x38], eax
call fcn.0043bf85
mov ecx, dword [ebx]
add esp, 0xc
push edi
push edi
push str._File_Head_length_
push str._s_d__x__n
push ecx
call fcn.0043c301
mov edx, dword [ebx]
add esp, 0x14
push edx
call fcn.0043c6cc
mov eax, dword [esi + 0x38]
add esp, 4
sub eax, 1
je 0x401da9
sub eax, 5
jne 0x401f7e
mov edx, dword [esi + 0x24]
push 0
lea eax, [esp + 0x14]
push eax
push 0x66
lea ecx, [esi + 0x1918]
push ecx
push edx
mov dword [esi + 0x30], 1
call ebp
movzx ecx, byte [esi + 0x193c]
mov eax, dword [esp + 0x10]
add dword [esi + 0x20], eax
and ecx, 4
push str.2_channel_mode
mov edi, ecx
call fcn.004010f0
mov ecx, dword [esi + 0x24]
push 0
lea edx, [esp + 0x14]
push edx
push 0x126
lea eax, [esi + 0x197e]
push eax
push ecx
call ebp
movsx ecx, byte [esi + 0x193d]
mov edx, dword [esp + 0x10]
add dword [esi + 0x20], edx
mov eax, ecx
cdq
idiv dword [esi + 0x30]
test byte [esi + 0x193c], 4
mov dword [esi + 0x2c], ecx
mov dword [esi + 0x34], eax
je 0x40174c
lea eax, [ecx + ecx]
mov dword [esi + 0x2c], eax
xor edi, edi
cmp dword [esi + 0x2c], edi
jle 0x401852
lea ebp, [esi + 0x53f8]
lea ebx, [esi + 0x193e]
lea ecx, [esi + 0x4f0]
lea esp, [esp]
lea eax, [edi + 1]
mov dword [esp + 0x24], eax
mov dword [ecx], eax
movzx eax, word [ebx]
test al, al
je 0x40178a
add eax, 1
and eax, 0xff
mov dword [ecx], eax
test byte [esi + 0x193c], 4
fld dword [esi + 0x1a1c]
fstp dword [esp + 0x14]
je 0x4017ef
mov eax, edi
cdq
sub eax, edx
sar eax, 1
and edi, 0x80000001
lea eax, [esi + eax*2 + 0x193e]
jns 0x4017b8
dec edi
or edi, 0xfffffffe
inc edi
movzx edx, byte [eax]
and edx, 0xff
test edi, edi
lea edx, [edi + edx*2 + 1]
mov dword [ecx], edx
jne 0x4017dc
mov al, byte [eax + 1]
and al, 3
movsx dx, al
movzx eax, dx
mov dword [ebp], edi
jmp 0x401803
mov ax, word [eax]
sar ax, 0xb
and ax, 3
movzx eax, ax
mov dword [ebp], edi
jmp 0x401803
mov dl, byte [ebx + 1]
and dl, 3
movsx ax, dl
movzx eax, ax
mov dword [ebp], 0
fld dword [esp + 0x14]
movzx eax, ax
mov edx, dword [esi + eax*4 + 0x19ac]
test edx, edx
fild dword [esi + eax*4 + 0x19ac]
jge 0x401822
fadd dword [0x479620]
fdivp st(1)
mov edi, dword [esp + 0x24]
mov dword [ebp - 0x400], eax
add ebx, 2
add ebp, 4
add ecx, 0x14
fstp dword [esp + 0x14]
fld dword [esp + 0x14]
fld st(0)
fchs
fstp qword [ecx - 0x10]
fstp qword [ecx - 8]
cmp edi, dword [esi + 0x2c]
jl 0x401770
cmp dword [esi + 0x2c], 0
mov dword [esp + 0x20], 0
jle 0x4018c4
lea ebp, [esi + 0x4ff8]
lea edi, [esi + 0x193e]
movzx eax, word [edi]
mov ecx, dword [ebp]
movzx eax, ax
push ecx
mov edx, eax
shr edx, 0xb
mov ecx, eax
and edx, 3
push edx
shr ecx, 8
and ecx, 3
push ecx
and eax, 0xff
push eax
push str.Chan._02d_K1_d_K2_d_NGain_d
lea edx, [esp + 0x14c]
call fcn.00403ce0
add esp, 0x14
lea ebx, [esp + 0x138]
call fcn.00401020
mov eax, dword [esp + 0x20]
add eax, 1
add edi, 2
add ebp, 4
cmp eax, dword [esi + 0x2c]
mov dword [esp + 0x20], eax
jl 0x40186c
push str.Kdev
lea edx, [esp + 0x13c]
push 0x100
push edx
call fcn.0043c5ed
add esp, 0xc
lea ebp, [esp + 0x142]
lea edi, [esi + 0x19a8]
mov ebx, 5
mov eax, dword [edi]
push eax
push str.__5u
push 5
push ebp
call fcn.0043b622
add esp, 0x10
add edi, 4
add ebp, 0xc
sub ebx, 1
jne 0x4018f0
lea ebx, [esp + 0x138]
call fcn.00401020
fld dword [esi + 0x1a1c]
sub esp, 8
fstp qword [esp]
push str.ADC_Range____8.3f
mov edx, ebx
call fcn.00403ce0
add esp, 0xc
call fcn.00401020
push str.K1cal
mov ecx, ebx
push 0x100
push ecx
call fcn.0043c5ed
add esp, 0xc
lea ebx, [esp + 0x144]
lea edi, [esi + 0x19d0]
mov ebp, 5
fld dword [edi]
sub esp, 8
fstp qword [esp]
push str.__8.3f
push 8
push ebx
call fcn.0043b622
add esp, 0x14
add edi, 4
add ebx, 0x10
sub ebp, 1
jne 0x401961
mov edi, dword [0x488ae8]
lea eax, [esp + 0x138]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401994
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea edx, [esp + 0x14c]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4019d0
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov eax, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push eax
call fcn.0043c301
mov ecx, dword [edi]
add esp, 0xc
push ecx
call fcn.0043c6cc
add esp, 4
push str.B1cal
lea edx, [esp + 0x13c]
push 0x100
push edx
call fcn.0043c5ed
add esp, 0xc
lea ebx, [esp + 0x144]
lea edi, [esi + 0x19bc]
mov ebp, 5
fld dword [edi]
sub esp, 8
fstp qword [esp]
push str.__8.3f
push 8
push ebx
call fcn.0043b622
add esp, 0x14
add edi, 4
add ebx, 0x10
sub ebp, 1
jne 0x401a41
mov edi, dword [0x488ae8]
lea eax, [esp + 0x138]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401a74
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea eax, [esp + 0x14c]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x401ab0
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov ecx, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push ecx
call fcn.0043c301
mov edx, dword [edi]
add esp, 0xc
push edx
call fcn.0043c6cc
add esp, 4
push str.K2cal
lea eax, [esp + 0x13c]
push 0x100
push eax
call fcn.0043c5ed
add esp, 0xc
lea ebx, [esp + 0x144]
lea edi, [esi + 0x19f8]
mov ebp, 5
fld dword [edi]
sub esp, 8
fstp qword [esp]
push str.__8.3f
push 8
push ebx
call fcn.0043b622
add esp, 0x14
add edi, 4
add ebx, 0x10
sub ebp, 1
jne 0x401b21
mov edi, dword [0x488ae8]
lea eax, [esp + 0x138]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401b54
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea ecx, [esp + 0x14c]
push ecx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x401b90
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov edx, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push edx
call fcn.0043c301
mov eax, dword [edi]
add esp, 0xc
push eax
call fcn.0043c6cc
add esp, 4
push str.B2cal
lea ecx, [esp + 0x13c]
push 0x200
push ecx
call fcn.0043c5ed
add esp, 0xc
lea ebx, [esp + 0x144]
lea edi, [esi + 0x19e4]
mov ebp, 5
fld dword [edi]
sub esp, 8
fstp qword [esp]
push str.__8.3f
push 8
push ebx
call fcn.0043b622
add esp, 0x14
add edi, 4
add ebx, 0x10
sub ebp, 1
jne 0x401c01
mov edi, dword [0x488ae8]
lea eax, [esp + 0x138]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401c34
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea edx, [esp + 0x14c]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x401c70
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov eax, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push eax
call fcn.0043c301
mov ecx, dword [edi]
add esp, 0xc
push ecx
call fcn.0043c6cc
add esp, 4
push 0x2000
lea edi, [esi + 0x5804]
push 0xff
push edi
call fcn.0043e850
mov eax, dword [esi + 0x24]
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
add esp, 0xc
push 0
lea edx, [esp + 0x14]
push edx
push 0xc
push edi
push eax
call ebx
push 8
push str.ADCBLOCK
push edi
call fcn.0043ba95
add esp, 0xc
test eax, eax
je 0x401d0d
mov ecx, dword [esi + 0x24]
push 1
push 0
push 0xfffffffffffffff4
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x401f84
mov dword [esi + 0x7804], 0xc
mov edx, dword [esi + 0x580c]
mov dword [esi + 0x7818], edx
test byte [esi + 0x580c], 2
je 0x401d64
mov ecx, dword [esi + 0x2c]
push 0
lea eax, [esp + 0x14]
push eax
lea edx, [ecx*4 + 4]
mov ecx, dword [esi + 0x24]
push edx
lea eax, [esi + 0x5810]
push eax
push ecx
call ebx
mov edx, dword [esi + 0x2c]
lea eax, [edx*4 + 4]
add dword [esi + 0x7804], eax
mov eax, dword [esi + 0x7804]
add dword [esi + 0x20], eax
test byte [esi + 0x580c], 4
je 0x401f84
mov edx, dword [esi + 0x2c]
mov eax, dword [esi + 0x7804]
push 0
add edx, edx
lea ecx, [esp + 0x14]
push ecx
add edx, edx
push edx
mov edx, dword [esi + 0x24]
lea ecx, [esi + eax + 0x5804]
push ecx
push edx
call ebx
mov eax, dword [esi + 0x2c]
add eax, eax
add eax, eax
add dword [esi + 0x7804], eax
add dword [esi + 0x20], eax
jmp 0x401f84
mov eax, dword [esi + 0x48c]
mov ecx, eax
and ecx, 0x1ff
sar eax, 0x10
push 0x477fd8
mov edi, ecx
mov dword [esi + 0x2c], ecx
mov dword [esi + 0x30], eax
mov dword [esi + 0x48c], ecx
call fcn.004010f0
mov edi, dword [esi + 0x30]
test edi, edi
je 0x401de3
push 0x477fe8
call fcn.004010f0
cmp dword [esi + 0x30], 0
jne 0x401df0
mov dword [esi + 0x30], 1
mov eax, dword [esi + 0x2c]
mov ecx, dword [esi + 0x30]
cdq
idiv ecx
test ecx, ecx
mov dword [esi + 0x34], eax
je 0x401e0c
push 0x478000
mov edi, eax
call fcn.004010f0
movsx edi, byte [esi + 0x49b]
push str.m_mode
call fcn.004010f0
xor ecx, ecx
cmp dword [esi + 0x2c], ecx
jle 0x401e51
fld qword [0x479660]
lea eax, [esi + 0x4f4]
fld qword [0x4795b0]
fxch st(1)
add ecx, 1
fst qword [eax]
mov dword [eax - 4], ecx
fxch st(1)
add eax, 0x14
fst qword [eax - 0xc]
cmp ecx, dword [esi + 0x2c]
jl 0x401e36
fstp st(1)
fstp st(0)
mov edx, dword [esi + 0x24]
push 0
lea eax, [esp + 0x14]
push eax
push 0x18
lea ecx, [esp + 0x344]
push ecx
push edx
call ebp
mov eax, dword [esi + 0x24]
push 1
push 0
push 0xffffffffffffffe8
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0xe
lea ecx, [esp + 0x33c]
push str.SAMPLES_RECORD
push ecx
call fcn.0043ba95
add esp, 0xc
test eax, eax
je 0x401f7e
mov ecx, dword [esi + 0x24]
push 0
lea edx, [esp + 0x14]
push edx
push 0x34
lea eax, [esi + 0x49c]
push eax
push ecx
call ebp
mov edx, dword [esp + 0x10]
add dword [esi + 0x20], edx
mov edx, dword [esi + 0x24]
push 0
lea eax, [esp + 0x14]
push eax
push 0x20
lea ecx, [esi + 0x4d0]
push ecx
push edx
call ebp
mov eax, dword [esp + 0x10]
add dword [esi + 0x20], eax
xor edi, edi
cmp dword [esi + 0x2c], edi
jle 0x401f02
lea ebx, [esi + 0x4f0]
mov edi, edi
mov edx, dword [esi + 0x24]
push 0
lea ecx, [esp + 0x14]
push ecx
push 0x14
push ebx
push edx
call ebp
mov eax, dword [esp + 0x10]
add dword [esi + 0x20], eax
add edi, 1
add ebx, 0x14
cmp edi, dword [esi + 0x2c]
jl 0x401ee0
push 0x2000
lea edi, [esi + 0x5804]
push 0xff
push edi
call fcn.0043e850
mov eax, dword [esi + 0x48c]
lea ecx, [eax + eax*4]
add ecx, ecx
add ecx, ecx
mov eax, ecx
cdq
add esp, 0xc
cmp edx, dword [esi + 0x4ec]
jg 0x401f61
jl 0x401f3d
cmp eax, dword [esi + 0x4e8]
jae 0x401f61
mov eax, dword [esi + 0x4e8]
mov edx, dword [esi + 0x24]
sub eax, ecx
push 0
lea ecx, [esp + 0x14]
push ecx
push eax
push edi
push edx
mov dword [esi + 0x7804], eax
call ebp
mov eax, dword [esp + 0x10]
add dword [esi + 0x20], eax
mov eax, dword [esi + 0x24]
push 0
lea ecx, [esp + 0x14]
push ecx
push 0x28
lea edx, [esi + 0x18f0]
push edx
push eax
call ebp
mov ecx, dword [esp + 0x10]
add dword [esi + 0x20], ecx
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esi + 0x24]
push 0
lea edx, [esp + 0x14]
push edx
push 0x20
lea eax, [esi + 0x1ac4]
push eax
push ecx
call ebx
mov eax, dword [esi + 0x24]
mov edx, dword [esp + 0x10]
add dword [esi + 0x20], edx
lea edi, [esi + 0x4fdc]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, dword [esi + 0x24]
push 0
push 0
push 0
push 2
push 0
push ecx
mov dword [esi + 0x4fd8], eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov edx, dword [esi + 0x24]
push edx
mov dword [esi + 0x28], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esi + 0x28], 0
jne 0x402042
mov eax, dword [0x489b08]
mov ecx, dword [0x488a6c]
push 0x100
shl eax, 9
add eax, 0x488b08
push eax
push 0xe0
push ecx
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [0x489b08]
lea edx, [eax + 1]
and edx, reloc.OLEAUT32.dll_VariantInit
jns 0x402019
dec edx
or edx, 0xfffffff8
inc edx
shl eax, 9
add eax, 0x488b08
push eax
mov eax, dword [esi]
push 0x400
push 0x400
push eax
mov dword [0x489b08], edx
call dword [sym.imp.USER32.dll_SendMessageW]
xor eax, eax
jmp 0x402b34
mov eax, dword [edi]
push 1
cdq
push 0
push edx
push eax
mov dword [esi + 0x18], 0xffffffff
call fcn.00441ea0
mov ecx, dword [esi + 0x4fd8]
mov ebx, dword [esi + 0x38]
mov edi, edx
xor edx, edx
mov ebp, eax
add ebp, ecx
adc edi, edx
cmp ebx, 1
mov dword [esp + 0x4c], edi
jne 0x402090
mov eax, dword [esi + 0x20]
xor ecx, ecx
mov edx, ebp
sub edx, eax
push ecx
mov eax, edi
push 4
sbb eax, ecx
push eax
push edx
call fcn.00441ee0
mov dword [esi + 0x40], eax
mov dword [esi + 0x44], edx
mov ecx, dword [esi + 0x20]
xor edx, edx
mov eax, ebp
sub eax, ecx
sbb edi, edx
cmp ebx, 1
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], edi
fild qword [esp + 0x28]
jne 0x4020b4
fmul qword [0x479658]
jmp 0x4020ba
fmul qword [0x479508]
sub esp, 8
fstp qword [esp]
push str._.0lf_counts_in_a_file_incl._8_bytes_numsect_in_case_2_byte_counts_
lea edx, [esp + 0x344]
call fcn.00403d10
mov edi, dword [0x488ae8]
add esp, 0xc
push 0x477f94
push 0x477f88
push edi
call fcn.0043bf85
mov edx, dword [edi]
add esp, 0xc
lea ecx, [esp + 0x338]
push ecx
push 0x477f98
push edx
call fcn.0043c301
mov eax, dword [edi]
add esp, 0xc
push eax
call fcn.0043c6cc
add esp, 4
cmp dword [esi + 0x38], 6
jne 0x402b13
movzx ecx, byte [esi + 0x1a9e]
movzx edx, byte [esi + 0x1a9f]
movzx eax, byte [esi + 0x1aa0]
push ecx
movzx ecx, byte [esi + 0x1aa3]
push edx
movzx edx, byte [esi + 0x1aa2]
push eax
movzx eax, byte [esi + 0x1aa1]
push ecx
push edx
push eax
lea ecx, [esp + 0x150]
push str.Date_from_SD_file___02u._02u._02u_nTime_from_SD_file__02u:_02u:_02u
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
mov edi, dword [0x488ae8]
lea eax, [esp + 0x158]
add esp, 0x20
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402170
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea edx, [esp + 0x14c]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
lea esp, [esp]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4021b0
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov eax, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push eax
call fcn.0043c301
mov ecx, dword [edi]
add esp, 0xc
push ecx
call fcn.0043c6cc
mov edx, dword [esp + 0x50]
add esp, 4
xor ebx, ebx
push ebx
push 0x100
push edx
push ebp
call fcn.00441ee0
mov edi, dword [esi + 0x20]
add eax, 0xfffffffe
lea ebp, [eax - 1]
shr edi, 1
mov dword [esi + 0x57f8], eax
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
mov dword [esp + 0x14], ebp
mov dword [esp + 0x24], ebx
je 0x40223e
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], eax
mov ecx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
mov ecx, dword [ecx + edi*2]
cmp ecx, 0xffffffff
mov dword [esp + 0x20], ecx
jne 0x4022ba
mov edx, dword [0x489b08]
mov eax, dword [0x488a6c]
push 0x100
shl edx, 9
add edx, 0x488b08
push edx
push 0xe1
push eax
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [0x489b08]
lea ecx, [eax + 1]
and ecx, reloc.OLEAUT32.dll_VariantInit
jns 0x402291
dec ecx
or ecx, 0xfffffff8
inc ecx
mov edx, dword [esi]
shl eax, 9
add eax, 0x488b08
push eax
push 0x400
push 0x400
push edx
mov dword [0x489b08], ecx
call dword [sym.imp.USER32.dll_SendMessageW]
xor eax, eax
jmp 0x402b34
mov edi, dword [esi + 0x20]
mov eax, ebp
shl eax, 7
shr edi, 1
add edi, eax
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x4022e7
mov ecx, esi
call fcn.00402b50
mov ecx, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], ecx
mov ecx, dword [esp + 0x20]
test ecx, ecx
jne 0x402309
mov edx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
cmp dword [edx + edi*2], 0xffffffff
je 0x402309
add ebp, 1
mov dword [esp + 0x18], ebp
jmp 0x402466
cmp ebp, 0x10
jbe 0x4023b1
mov eax, dword [esp + 0x14]
mov edi, dword [esi + 0x20]
lea ebp, [eax + ebx]
shr ebp, 1
mov ecx, ebp
shr edi, 1
shl ecx, 7
add edi, ecx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x402344
mov ecx, esi
call fcn.00402b50
mov edx, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], edx
mov eax, dword [esi + 0x4ff4]
and edi, 0x7ffffff
mov ecx, dword [eax + edi*2]
cmp ecx, 0xffffffff
mov dword [esp + 0x1c], ecx
je 0x40239a
mov edi, dword [esi + 0x20]
mov edx, ebx
shr edi, 1
shl edx, 7
add edi, edx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x402389
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0x4ff4], eax
mov edx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
cmp ecx, dword [edx + edi*2]
jae 0x4023a0
mov dword [esp + 0x14], ebp
jmp 0x4023a2
mov ebx, ebp
mov eax, dword [esp + 0x14]
sub eax, ebx
cmp eax, 0x10
ja 0x402312
mov edi, dword [esi + 0x20]
lea ebp, [ebx + 1]
shr edi, 1
shl ebx, 7
add edi, ebx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
mov dword [esp + 0x18], ebp
je 0x4023df
mov ecx, esi
call fcn.00402b50
mov ecx, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], ecx
mov edx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
cmp ebp, dword [esp + 0x14]
mov ecx, dword [edx + edi*2]
mov dword [esp + 0x1c], ecx
ja 0x40245b
mov ebx, ebp
shl ebx, 7
mov edi, dword [esi + 0x20]
shr edi, 1
add edi, ebx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x402425
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0x4ff4], eax
mov edx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
mov edi, dword [edx + edi*2]
mov edx, dword [esi + 0x57f8]
mov eax, edi
sub eax, ecx
shr edx, 1
cmp eax, edx
ja 0x402457
cmp edi, ecx
jb 0x402457
add ebp, 1
add ebx, 0x80
cmp ebp, dword [esp + 0x14]
jbe 0x4023fd
mov dword [esp + 0x18], ebp
cmp dword [esp + 0x20], 0
jne 0x4024dd
mov eax, dword [esp + 0x18]
mov edi, dword [esi + 0x20]
sub eax, 1
mov dword [esp + 0x18], eax
mov edx, 0x80
mul edx
xor ecx, ecx
push ecx
shr edi, 1
xor ebx, ebx
add edi, eax
push 0x8000000
adc ebx, edx
push ebx
push edi
mov dword [esp + 0x38], ecx
mov dword [esp + 0x3c], ecx
call fcn.00441ee0
cmp eax, dword [esi + 0x18]
je 0x4024b2
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], eax
push 0
push 0x8000000
push ebx
push edi
call fcn.00454d40
mov ecx, dword [esi + 0x4ff4]
mov ebp, dword [ecx + eax*2]
add ebp, 1
mov dword [esp + 0x34], ebp
mov dword [esp + 0x14], 0
jmp 0x4025a9
mov ebp, dword [esp + 0x18]
mov edx, dword [esi + 0x20]
lea edi, [ebp - 1]
shl edi, 7
shr edx, 1
add edi, edx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x40250b
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], eax
mov ecx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
mov ebx, dword [ecx + edi*2]
mov edi, dword [esi + 0x20]
mov edx, ebp
shr edi, 1
shl edx, 7
add edi, edx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x402543
mov ecx, esi
call fcn.00402b50
mov eax, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], eax
mov ecx, dword [esi + 0x4ff4]
and edi, 0x7ffffff
mov edi, dword [ecx + edi*2]
mov eax, edi
imul eax, eax, 0x7c
xor edx, edx
div dword [esi + 0x2c]
mov dword [esp + 0x24], edi
test eax, eax
mov dword [esp + 0x1c], eax
fild dword [esp + 0x1c]
jge 0x402572
fadd qword [0x479570]
fld dword [esi + 0x4ff0]
fdivr qword [0x479568]
fmulp st(1)
call fcn.00441e16
mov dword [esp + 0x2c], edx
mov edx, dword [esi + 0x57f8]
sub ebx, edi
add ebx, 1
sub edx, 1
mov dword [esp + 0x14], ebp
mov dword [esp + 0x28], eax
mov dword [esp + 0x34], ebx
mov dword [esp + 0x18], edx
mov ebp, ebx
lea edi, [ebp*4]
push edi
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
mov dword [esi + 0xc], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push edi
push 0xff
push eax
mov dword [esi + 8], eax
call fcn.0043e850
mov edi, dword [esp + 0x24]
lea eax, [ebp - 1]
add esp, 0xc
cmp edi, eax
jne 0x40260e
mov ebx, dword [esp + 0x14]
xor ecx, ecx
jmp 0x4025f0
lea eax, [ecx + ebx]
xor edx, edx
div dword [esi + 0x57f8]
mov eax, dword [esi + 8]
add ecx, 1
cmp ecx, edi
mov dword [eax + ecx*4 - 4], edx
jbe 0x4025f0
jmp 0x40277d
mov eax, dword [esi]
mov ecx, dword [0x488a6c]
push eax
push 0x408750
push eax
push str.PERSENT
push ecx
call dword [sym.imp.USER32.dll_CreateDialogParamW]
mov edx, dword [0x489b08]
push 0x100
shl edx, 9
add edx, 0x488b08
push edx
mov dword [esi + 4], eax
mov eax, dword [0x488a6c]
push 0xde
push eax
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [0x489b08]
lea ecx, [eax + 1]
and ecx, reloc.OLEAUT32.dll_VariantInit
jns 0x402667
dec ecx
or ecx, 0xfffffff8
inc ecx
mov edx, dword [esi + 4]
shl eax, 9
add eax, 0x488b08
push eax
push edx
mov dword [0x489b08], ecx
call dword [sym.imp.USER32.dll_SetWindowTextW]
xor ebx, ebx
lea eax, [edi + 1]
cmp eax, ebx
mov dword [esp + 0x1c], ebx
jbe 0x402763
test eax, eax
mov dword [esp + 0x48], eax
fild dword [esp + 0x48]
jge 0x4026a3
fadd qword [0x479570]
fstp qword [esp + 0x50]
mov eax, ebx
test eax, eax
mov dword [esp + 0x48], eax
fild dword [esp + 0x48]
jge 0x4026bb
fadd qword [0x479570]
fdiv qword [esp + 0x50]
fmul qword [0x479598]
call fcn.00441de0
mov edi, eax
cmp edi, dword [esp + 0x1c]
je 0x4026fb
mov ecx, dword [esi + 4]
push edi
push 1
push 0x400
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
push 1
push 0
push 0
push 0
lea edx, [esp + 0x7c]
push edx
mov dword [esp + 0x30], edi
call dword [sym.imp.USER32.dll_PeekMessageW]
mov eax, dword [esp + 0x14]
add eax, ebx
xor edx, edx
div dword [esi + 0x57f8]
mov edi, dword [esi + 0x20]
shr edi, 1
mov ebp, edx
mov ecx, ebp
shl ecx, 7
add edi, ecx
mov eax, edi
shr eax, 0x1b
cmp eax, dword [esi + 0x18]
je 0x402734
mov ecx, esi
call fcn.00402b50
mov edx, dword [esi + 0x4fe0]
mov dword [esi + 0x4ff4], edx
mov eax, dword [esi + 0x4ff4]
mov edx, dword [esi + 8]
and edi, 0x7ffffff
mov ecx, dword [eax + edi*2]
mov eax, dword [esp + 0x18]
sub ecx, dword [esp + 0x24]
add ebx, 1
add eax, 1
cmp ebx, eax
mov dword [edx + ecx*4], ebp
jb 0x4026a7
mov ebp, dword [esp + 0x34]
mov eax, dword [esi + 4]
push 0x64
push 1
push 0x400
push eax
call dword [sym.imp.USER32.dll_SendMessageW]
mov dword [esi + 4], 0
mov eax, dword [esi + 0x57f8]
push eax
push eax
lea ecx, [esp + 0x140]
push str.Number_of_256_bytes_sectors_in_SD_file__10u__08x_
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
mov edi, dword [0x488ae8]
lea eax, [esp + 0x148]
add esp, 0x10
lea edx, [eax + 2]
jmp 0x4027b0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4027b0
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea edx, [esp + 0x14c]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
lea esp, [esp]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4027f0
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov eax, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push eax
call fcn.0043c301
mov ecx, dword [edi]
add esp, 0xc
push ecx
call fcn.0043c6cc
add esp, 4
push ebp
push ebp
lea edx, [esp + 0x140]
push str.Number_of_data_sectors_include_holes___10u__08x_
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
mov edi, dword [0x488ae8]
lea eax, [esp + 0x148]
add esp, 0x10
lea ecx, [eax + 2]
lea ecx, [ecx]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x402860
push 0
sub eax, ecx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea eax, [esp + 0x14c]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4028a0
push 0x477f94
sub eax, edx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], cl
call fcn.0043bf85
mov ecx, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push ecx
call fcn.0043c301
mov edx, dword [edi]
add esp, 0xc
push edx
call fcn.0043c6cc
add esp, 4
cmp dword [esp + 0x20], 0
jne 0x402904
mov eax, dword [esp + 0x18]
add eax, 1
push eax
push eax
push str.Number_of_data_sectors_exclude_holes__10u__08x_
lea eax, [esp + 0x144]
push eax
jmp 0x402917
mov eax, dword [esp + 0x14]
push eax
push eax
push str.The_first_sector_of_cyclebuffer__10u__08x_
lea ecx, [esp + 0x144]
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
mov edi, dword [0x488ae8]
lea eax, [esp + 0x148]
add esp, 0x10
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402930
push 0
sub eax, edx
push 0
sar eax, 1
add eax, 1
push eax
lea ebx, [edi + 0x204]
push ebx
push 0xffffffffffffffff
lea edx, [esp + 0x14c]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea eax, [esp + 0x138]
lea ecx, [eax + 2]
lea esp, [esp]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x402970
push 0x477f94
sub eax, ecx
sar eax, 1
push 0x477f88
push edi
mov byte [edi + eax + 0x204], dl
call fcn.0043bf85
mov eax, dword [edi]
add esp, 0xc
push ebx
push 0x477f98
push eax
call fcn.0043c301
mov ecx, dword [edi]
add esp, 0xc
push ecx
call fcn.0043c6cc
mov eax, ebp
mov edx, 0x100
mul edx
mov edi, eax
mov eax, dword [esi + 8]
mov dword [esi + 0x57fc], ebp
mov eax, dword [eax]
add esp, 4
test eax, eax
mov ebx, edx
je 0x4029df
mov ecx, dword [esi + 0x2c]
imul eax, eax, 0x7c
xor edx, edx
div ecx
sub ecx, edx
jmp 0x4029e1
xor ecx, ecx
cmp ecx, dword [esi + 0x2c]
mov dword [esi + 0x5800], ecx
jne 0x4029f6
mov dword [esi + 0x5800], 0
push 0
push 2
push ebx
push edi
call fcn.00441ee0
push 0
push 0x80
mov ebx, edx
mov edi, eax
push ebx
push edi
mov dword [esi + 0x40], eax
mov dword [esi + 0x44], edx
call fcn.00454d40
push 0
push 0x80
push ebx
push edi
mov ebp, eax
call fcn.00441ee0
mov ecx, 0x7c
mul ecx
cmp ebp, 4
mov dword [esi + 0x40], eax
mov dword [esi + 0x44], edx
jbe 0x402a45
add ebp, 0xfffffffc
add dword [esi + 0x40], ebp
adc dword [esi + 0x44], 0
movzx edx, byte [esi + 0x1a9e]
movzx ecx, byte [esi + 0x1aa0]
xor eax, eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x44], eax
movzx eax, byte [esi + 0x1a9f]
mov word [esp + 0x44], dx
movzx edx, byte [esi + 0x1aa1]
mov word [esp + 0x40], cx
movzx ecx, byte [esi + 0x1aa3]
mov word [esp + 0x42], ax
movzx eax, byte [esi + 0x1aa2]
mov word [esp + 0x3e], dx
lea ebp, [esi + 0x4fe4]
push ebp
lea edx, [esp + 0x3c]
add cx, 0x7d0
push edx
mov word [esp + 0x42], ax
mov word [esp + 0x40], cx
call dword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
mov eax, dword [esi + 0x4fe8]
push 1
push 0
push 0
push eax
call fcn.00441ea0
mov ecx, dword [ebp]
mov ebx, eax
mov edi, edx
xor edx, edx
add ebx, ecx
adc edi, edx
add ebx, dword [esp + 0x28]
lea eax, [esp + 0x88]
adc edi, dword [esp + 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_GetTimeZoneInformation]
mov eax, dword [esp + 0x88]
push 0
cdq
push 0x23c34600
push edx
push eax
call fcn.00441ea0
add ebx, eax
adc edi, edx
mov ecx, edi
sar ecx, 0x1f
mov dword [esi + 0x4fe8], edi
mov dword [ebp], ebx
mov eax, dword [esi + 0x2c]
cdq
push edx
mov edx, dword [esi + 0x44]
push eax
mov eax, dword [esi + 0x40]
push edx
push eax
call fcn.00441ee0
mov dword [esi + 0x40], eax
mov eax, 1
mov dword [esi + 0x44], edx
mov dword [esi + 0x10], eax
mov ecx, dword [esp + 0x43c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0043b563
add esp, 0x434
ret