Function at 0x1004db0a
Capabilities:
Get system information on windows
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3c]
sub esp, 0xa0
mov eax, dword [0x100e34b0]
test eax, eax
push ebx
push esi
push edi
mov esi, 0x200
ja 0x1004db52
push 9
pop ecx
xor eax, eax
lea edi, [ebp - 0x64]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [ebp - 0x60]
cmp eax, esi
jb 0x1004db49
dec eax
mov dword [0x100e34b0], eax
jmp 0x1004db4e
mov eax, dword [0x100e34b0]
test eax, eax
je 0x1004db57
mov dword [ebp + 0x18], eax
jmp 0x1004db5e
mov dword [ebp + 0x18], 0xffff
cmp dword [ebp + 0x7c], 0
mov eax, esi
setl byte [ebp + 0x3b]
cmp byte [ebp + 0x3b], 0
mov dword [ebp + 0x30], eax
je 0x1004db74
neg dword [ebp + 0x7c]
cmp dword [ebp + 0x70], 0
je 0x1004db80
mov eax, dword [ebp + 0x70]
mov dword [ebp + 0x30], eax
cmp dword [ebp + 0x74], 0
mov edi, dword [ebp + 0x4c]
mov ebx, dword [ebp + 0x50]
mov esi, dword [ebp + 0x60]
mov ecx, dword [ebp + 0x68]
mov dword [ebp + 0x28], edi
mov dword [ebp + 0x2c], ebx
je 0x1004dbc7
or ecx, dword [ebp + 0x6c]
je 0x1004dbae
mov ebx, dword [ebp + 0x64]
mov edi, esi
add edi, dword [ebp + 0x68]
adc ebx, dword [ebp + 0x6c]
mov dword [ebp + 0x28], edi
mov dword [ebp + 0x2c], ebx
cmp eax, 1
jle 0x1004dc23
cdq
push edx
push eax
push dword [ebp + 0x64]
mov dword [ebp + 0x20], eax
push esi
mov dword [ebp + 0x24], edx
call fcn.100b64f0
jmp 0x1004dbf8
or ecx, dword [ebp + 0x6c]
je 0x1004dbdd
mov ebx, dword [ebp + 0x64]
mov edi, esi
add edi, dword [ebp + 0x68]
adc ebx, dword [ebp + 0x6c]
mov dword [ebp + 0x28], edi
mov dword [ebp + 0x2c], ebx
cmp eax, 1
jle 0x1004dc23
cdq
push edx
push eax
push dword [ebp + 0x64]
mov dword [ebp + 0x20], eax
push esi
mov dword [ebp + 0x24], edx
call fcn.100b64f0
mov dword [ebp + 0x74], eax
cdq
push dword [ebp + 0x24]
sub esi, eax
sbb dword [ebp + 0x64], edx
mov eax, dword [ebp + 0x74]
push dword [ebp + 0x20]
cdq
add esi, eax
adc dword [ebp + 0x64], edx
push dword [ebp + 0x64]
push esi
call fcn.100b64f0
mov dword [ebp + 0x74], eax
cdq
sub esi, eax
sbb dword [ebp + 0x64], edx
mov dword [ebp + 0x60], esi
jmp 0x1004dc27
and dword [ebp + 0x74], 0
cmp ebx, dword [ebp + 0x50]
jl 0x1004dc3f
jg 0x1004dc33
cmp edi, dword [ebp + 0x4c]
jbe 0x1004dc3f
mov edi, dword [ebp + 0x4c]
mov ebx, dword [ebp + 0x50]
mov dword [ebp + 0x28], edi
mov dword [ebp + 0x2c], ebx
mov eax, dword [ebp + 0x18]
not eax
cdq
mov dword [ebp - 4], eax
and eax, esi
mov dword [ebp + 8], eax
mov eax, edx
and eax, dword [ebp + 0x64]
mov dword [ebp], edx
mov dword [ebp + 0xc], eax
mov eax, dword [ebp + 0x18]
cdq
mov esi, eax
add esi, edi
mov ecx, edx
adc ecx, ebx
and ecx, dword [ebp]
and esi, dword [ebp - 4]
cmp ecx, dword [ebp + 0x50]
jl 0x1004dc7c
jg 0x1004dc76
cmp esi, dword [ebp + 0x4c]
jbe 0x1004dc7c
mov esi, dword [ebp + 0x4c]
mov ecx, dword [ebp + 0x50]
mov eax, dword [ebp + 0x74]
mov ebx, dword [ebp + 0x28]
mov edi, dword [ebp + 0x2c]
cdq
mov dword [ebp - 0x40], eax
add eax, dword [ebp + 0x60]
mov dword [ebp - 0x3c], edx
mov dword [ebp + 0x4c], eax
mov eax, edx
adc eax, dword [ebp + 0x64]
mov dword [ebp + 0x50], eax
mov eax, dword [ebp + 0x58]
cdq
sub ebx, eax
mov eax, dword [ebp + 0x78]
sbb edi, edx
sub ebx, dword [ebp + 0x4c]
sbb edi, dword [ebp + 0x50]
and dword [ebp - 0x14], 0
and dword [ebp - 0x10], 0
test eax, eax
jne 0x1004dcd5
push dword [ebp + 0xc]
sub esi, dword [ebp + 8]
push dword [ebp + 8]
sbb ecx, dword [ebp + 0xc]
push 2
push ecx
push esi
push dword [ebp + 0x48]
lea ecx, [ebp - 0x14]
call fcn.1003f887
mov eax, dword [ebp - 0x10]
or dword [ebp - 0x30], 0xffffffff
or dword [ebp - 0x2c], 0xffffffff
test eax, eax
je 0x1004de25
mov esi, dword [ebp + 0x4c]
sub esi, dword [ebp + 8]
and dword [ebp + 0x60], 0
and dword [ebp + 0x64], 0
add esi, eax
cmp dword [ebp + 0x30], 1
mov ecx, ebx
mov dword [ebp], edi
jle 0x1004dd25
mov eax, dword [ebp + 0x30]
cdq
push edx
push eax
push edi
push ebx
mov dword [ebp + 0x20], eax
mov dword [ebp + 0x24], edx
call fcn.100b4150
push dword [ebp + 0x24]
push dword [ebp + 0x20]
push edx
push eax
call fcn.100b4200
mov ecx, eax
mov dword [ebp], edx
cmp byte [ebp + 0x3b], 0
je 0x1004dd48
mov eax, dword [ebp]
add esi, ecx
neg dword [ebp + 0x30]
mov dword [ebp + 0x64], eax
mov eax, dword [ebp + 0x30]
cdq
mov dword [ebp + 0x60], ecx
mov dword [ebp + 0x20], eax
mov dword [ebp + 0x10], eax
mov dword [ebp + 0x14], edx
jmp 0x1004dd5c
mov eax, dword [ebp + 0x30]
cdq
mov dword [ebp + 0x20], eax
add eax, ecx
mov dword [ebp + 0x10], eax
mov eax, edx
adc eax, dword [ebp]
mov dword [ebp + 0x14], eax
cmp dword [ebp + 0x64], edi
mov dword [ebp + 0x24], edx
jg 0x1004e0bb
jl 0x1004dd73
cmp dword [ebp + 0x60], ebx
ja 0x1004e0bb
cmp dword [ebp + 0x64], 0
jl 0x1004e0bb
jg 0x1004dd89
cmp dword [ebp + 0x60], 0
jb 0x1004e0bb
mov eax, dword [ebp + 0x10]
cmp dword [ebp + 0x60], eax
jne 0x1004dd9d
mov eax, dword [ebp + 0x14]
cmp dword [ebp + 0x64], eax
je 0x1004e0bb
mov ebx, dword [ebp + 0x64]
mov edi, dword [ebp + 0x60]
push dword [ebp + 0x58]
push dword [ebp + 0x54]
push esi
call fcn.10046443
add esp, 0xc
test eax, eax
je 0x1004dde5
cmp dword [ebp + 0x44], 0
je 0x1004de0e
mov eax, edi
add eax, dword [ebp + 0x4c]
mov ecx, ebx
adc ecx, dword [ebp + 0x50]
push ecx
push eax
push dword [ebp + 0x44]
call fcn.1004d7f9
xor eax, eax
add esp, 0xc
cmp dword [ebp + 0x7c], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
jle 0x1004dde5
dec dword [ebp + 0x7c]
je 0x1004ddfd
add edi, dword [ebp + 0x20]
adc ebx, dword [ebp + 0x24]
add esi, dword [ebp + 0x30]
cmp edi, dword [ebp + 0x10]
jne 0x1004dda3
cmp ebx, dword [ebp + 0x14]
jne 0x1004dda3
jmp 0x1004e0bb
lea ecx, [ebp - 0x14]
call fcn.1000f660
xor eax, eax
xor edx, edx
jmp 0x1004e0c9
lea ecx, [ebp - 0x14]
call fcn.1000f660
mov eax, edi
add eax, dword [ebp + 0x4c]
mov edx, ebx
adc edx, dword [ebp + 0x50]
jmp 0x1004e0c9
mov ecx, dword [ebp + 0x74]
mov eax, dword [ebp + 0x58]
mov esi, dword [ebp + 0x28]
mov edi, dword [ebp + 0x2c]
add eax, ecx
mov dword [ebp - 8], eax
push 0
push dword [ebp + 0x64]
cdq
push dword [ebp + 0x60]
mov ecx, esi
push dword [ebp + 0x48]
sub ecx, eax
mov eax, edi
sbb eax, edx
mov dword [ebp + 0x10], ecx
mov dword [ebp + 0x14], eax
call fcn.10040d01
add esp, 0x10
cmp dword [ebp + 0x60], eax
jne 0x1004de62
cmp dword [ebp + 0x64], edx
je 0x1004de6c
or edi, 0xffffffff
mov esi, edi
jmp 0x1004e344
sub esi, dword [ebp + 0x60]
mov ecx, dword [ebp - 8]
sbb edi, dword [ebp + 0x64]
mov ebx, ecx
shl ebx, 2
mov eax, ebx
cdq
cmp edx, edi
mov dword [ebp + 0x50], edi
mov dword [ebp - 0x38], eax
jl 0x1004de92
jg 0x1004de90
mov eax, esi
cmp dword [ebp - 0x38], eax
jbe 0x1004de92
mov ebx, esi
lea eax, [ecx + 0x1ff]
mov ecx, 0xfffffe00
and eax, ecx
mov dword [ebp + 0x70], eax
lea eax, [ebx + 0x1ff]
and eax, ecx
mov ecx, 0x400000
cmp eax, ecx
mov dword [ebp + 0x1c], eax
jge 0x1004deb9
mov dword [ebp + 0x1c], ecx
and dword [ebp + 0x50], 0
mov ecx, dword [ebp - 8]
mov eax, dword [ebp + 0x1c]
lea eax, [eax + ecx*4 + 0x100800]
push eax
lea ecx, [ebp + 0x50]
call fcn.10045ff1
test eax, eax
mov dword [ebp + 0x78], eax
je 0x1004dee9
add eax, 0x20000
and eax, 0xfffe0000
mov dword [ebp + 0x78], eax
jne 0x1004df0c
mov eax, dword [ebp + 0x1c]
cmp eax, ebx
jl 0x1004e0b3
cdq
sub eax, edx
sar eax, 1
add eax, 0x1ff
and eax, 0xfffffe00
cmp dword [ebp + 0x78], 0
mov dword [ebp + 0x1c], eax
je 0x1004debd
mov eax, dword [ebp + 0x78]
mov dword [ebp + 0x18], eax
mov eax, dword [ebp + 0x1c]
cmp eax, dword [ebp + 0x70]
jl 0x1004e0b3
xor ebx, ebx
push ebx
mov dword [ebp + 0x70], ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
cmp byte [ebp + 0x3b], bl
mov eax, dword [ebp + 0x60]
mov ecx, dword [ebp + 0x30]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 0x64]
mov dword [ebp + 4], 0x3e8
mov dword [ebp + 0xc], eax
je 0x1004df47
neg ecx
cmp byte [ebp + 0x3b], 0
mov dword [ebp - 0x20], ecx
mov ecx, dword [ebp + 0x74]
mov dword [ebp - 0xc], ecx
jne 0x1004e0fb
cmp eax, dword [ebp + 0x14]
jg 0x1004e0b3
jl 0x1004df71
mov eax, dword [ebp + 0x60]
cmp eax, dword [ebp + 0x10]
ja 0x1004e0b3
mov ecx, dword [ebp + 0x28]
sub ecx, dword [ebp + 0x60]
mov esi, dword [ebp + 0x2c]
sbb esi, dword [ebp + 0x64]
mov edi, dword [ebp + 0x1c]
mov ebx, dword [ebp + 0x70]
add ecx, 0x1ff
adc esi, 0
sub edi, ebx
mov eax, edi
cdq
and ecx, 0xfffffe00
cmp esi, edx
jl 0x1004dfa5
jg 0x1004dfa1
cmp ecx, eax
jbe 0x1004dfa5
mov ecx, eax
mov esi, edx
test esi, esi
jl 0x1004e0b3
jg 0x1004dfb7
test ecx, ecx
jbe 0x1004e0b3
xor esi, esi
push esi
lea eax, [ebp + 0x34]
push eax
mov eax, dword [ebp + 0x78]
push ecx
add eax, ebx
push eax
push dword [ebp + 0x48]
mov dword [ebp + 0x34], esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1004dfda
cmp dword [ebp + 0x34], esi
jg 0x1004dfe9
dec dword [ebp + 4]
cmp dword [ebp + 4], esi
jle 0x1004e0b3
mov dword [ebp + 0x34], esi
cmp dword [ebp + 0x34], edi
jle 0x1004dff1
mov dword [ebp + 0x34], edi
add dword [ebp + 0x34], ebx
mov eax, dword [ebp + 0x34]
cmp eax, dword [ebp - 8]
mov dword [ebp + 0x70], eax
jl 0x1004e099
mov ecx, dword [ebp + 0x74]
mov eax, dword [ebp + 0x78]
lea ebx, [eax + ecx]
mov eax, dword [ebp + 0x70]
sub eax, dword [ebp + 0x58]
sub eax, ecx
add eax, dword [ebp + 0x30]
cdq
idiv dword [ebp + 0x30]
mov esi, eax
imul esi, dword [ebp + 0x30]
lea edi, [eax - 1]
test edi, edi
jl 0x1004e077
push dword [ebp + 0x58]
push dword [ebp + 0x54]
push ebx
call fcn.10046443
add esp, 0xc
test eax, eax
je 0x1004e067
cmp dword [ebp + 0x44], 0
je 0x1004e0e2
mov eax, dword [ebp - 0xc]
cdq
add eax, dword [ebp + 0x60]
adc edx, dword [ebp + 0x64]
push edx
push eax
push dword [ebp + 0x44]
call fcn.1004d7f9
add esp, 0xc
cmp dword [ebp + 0x7c], 0
jle 0x1004e067
dec dword [ebp + 0x7c]
je 0x1004e0d1
mov eax, dword [ebp + 0x30]
cdq
add dword [ebp + 0x60], eax
adc dword [ebp + 0x64], edx
add ebx, dword [ebp + 0x30]
dec edi
jns 0x1004e028
add esi, dword [ebp + 0x74]
and dword [ebp + 0x74], 0
sub dword [ebp + 0x70], esi
cmp dword [ebp + 0x70], 0
jle 0x1004e099
mov eax, dword [ebp + 0x78]
push dword [ebp + 0x70]
add esi, eax
push esi
push eax
call fcn.100144b5
add esp, 0xc
mov eax, dword [ebp + 0x14]
cmp dword [ebp + 0x64], eax
jl 0x1004df71
jg 0x1004e0b3
mov eax, dword [ebp + 0x10]
cmp dword [ebp + 0x60], eax
jbe 0x1004df71
lea ecx, [ebp + 0x50]
call fcn.1003f96c
lea ecx, [ebp - 0x14]
call fcn.1000f660
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x2c]
pop edi
pop esi
pop ebx
add ebp, 0x3c
leave
ret
lea ecx, [ebp + 0x50]
call fcn.1003f96c
xor esi, esi
xor edi, edi
jmp 0x1004e344
lea ecx, [ebp + 0x50]
call fcn.1003f96c
lea ecx, [ebp - 0x14]
call fcn.1000f660
mov eax, dword [ebp - 0xc]
cdq
jmp 0x1004e36b
cmp eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ebp - 8]
lea ecx, [ecx + edx + 0x400]
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x34], edi
mov dword [ebp - 0xc], ecx
jg 0x1004e0b3
jl 0x1004e126
mov eax, dword [ebp + 0x10]
cmp dword [ebp + 0x60], eax
ja 0x1004e0b3
mov eax, dword [ebp + 0x1c]
sub eax, dword [ebp + 0x70]
mov ecx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x18]
neg ecx
adc esi, 0
neg esi
mov ebx, ecx
add ebx, dword [ebp - 0x38]
cdq
mov edi, esi
adc edi, dword [ebp - 0x34]
mov dword [ebp - 4], eax
mov eax, edx
cmp edi, eax
mov dword [ebp - 0x24], edi
jl 0x1004e15f
jg 0x1004e157
cmp ebx, dword [ebp - 4]
jbe 0x1004e15f
mov ebx, dword [ebp - 4]
mov edi, eax
mov dword [ebp - 0x24], edi
test edi, edi
jl 0x1004e0b3
jg 0x1004e171
test ebx, ebx
jbe 0x1004e0b3
mov edi, dword [ebp + 0x28]
sub edi, ebx
mov dword [ebp + 0x24], ebx
mov ebx, dword [ebp + 0x2c]
sbb ebx, dword [ebp - 0x24]
sub edi, dword [ebp - 0x1c]
mov edx, 0xfffffe00
sbb ebx, dword [ebp - 0x18]
add edi, 0x1ff
adc ebx, 0
and edi, edx
sub ecx, edi
sbb esi, ebx
add ecx, dword [ebp + 0x28]
adc esi, dword [ebp + 0x2c]
add ecx, 0x1ff
adc esi, 0
and ecx, edx
cmp esi, eax
mov dword [ebp - 0x28], ecx
jl 0x1004e1c1
jg 0x1004e1b8
cmp ecx, dword [ebp - 4]
jbe 0x1004e1c1
mov ecx, dword [ebp - 4]
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
xor esi, esi
push esi
push ebx
push edi
push dword [ebp + 0x48]
mov dword [ebp + 0x34], esi
call fcn.10040d01
add esp, 0x10
cmp edi, eax
jne 0x1004e331
cmp ebx, edx
jne 0x1004e331
push esi
lea eax, [ebp + 0x34]
push eax
push dword [ebp - 0x28]
push dword [ebp + 0x78]
push dword [ebp + 0x48]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1004e201
cmp dword [ebp + 0x34], esi
jg 0x1004e210
dec dword [ebp + 4]
cmp dword [ebp + 4], esi
jle 0x1004e0b3
mov dword [ebp + 0x34], esi
mov eax, dword [ebp + 0x24]
cmp dword [ebp + 0x34], eax
jle 0x1004e21b
mov dword [ebp + 0x34], eax
cmp dword [ebp + 0x70], esi
jle 0x1004e23d
mov eax, dword [ebp + 0x18]
push dword [ebp + 0x70]
mov ecx, dword [ebp - 0xc]
add ecx, eax
push ecx
mov ecx, dword [ebp + 0x34]
add ecx, eax
push ecx
mov dword [ebp + 0x78], eax
call fcn.100144b5
add esp, 0xc
mov ecx, dword [ebp + 0x34]
mov eax, ecx
cdq
add dword [ebp - 0x1c], eax
adc dword [ebp - 0x18], edx
add ecx, dword [ebp + 0x70]
mov eax, ecx
cmp eax, dword [ebp - 8]
mov dword [ebp + 0x34], ecx
mov dword [ebp + 0x70], eax
jl 0x1004e30e
sub eax, dword [ebp + 0x58]
mov esi, dword [ebp + 0x30]
sub eax, dword [ebp + 0x74]
add eax, esi
cdq
idiv esi
mov edx, dword [ebp + 0x18]
mov ecx, eax
imul eax, esi
mov dword [ebp + 0x78], eax
sub eax, esi
lea esi, [eax + edx]
add esi, dword [ebp + 0x74]
cdq
add eax, edi
adc edx, ebx
lea edi, [ecx - 1]
test edi, edi
mov dword [ebp + 0x60], eax
mov dword [ebp + 0x64], edx
jl 0x1004e2e1
push dword [ebp + 0x58]
push dword [ebp + 0x54]
push esi
call fcn.10046443
add esp, 0xc
test eax, eax
je 0x1004e2d1
cmp dword [ebp + 0x44], 0
je 0x1004e355
mov eax, dword [ebp - 0x40]
add eax, dword [ebp + 0x60]
mov ecx, dword [ebp - 0x3c]
adc ecx, dword [ebp + 0x64]
push ecx
push eax
push dword [ebp + 0x44]
call fcn.1004d7f9
add esp, 0xc
cmp dword [ebp + 0x7c], 0
jle 0x1004e2d1
dec dword [ebp + 0x7c]
je 0x1004e338
mov eax, dword [ebp - 0x20]
cdq
add dword [ebp + 0x60], eax
adc dword [ebp + 0x64], edx
add esi, dword [ebp - 0x20]
dec edi
jns 0x1004e290
mov ecx, dword [ebp + 0x78]
mov eax, ecx
cdq
add dword [ebp + 8], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp + 0x78], eax
adc dword [ebp + 0xc], edx
sub dword [ebp + 0x70], ecx
cmp dword [ebp + 0x70], 0
jle 0x1004e30e
push dword [ebp + 0x70]
mov ecx, dword [ebp - 0xc]
push eax
add ecx, eax
push ecx
call fcn.100144b5
add esp, 0xc
mov eax, dword [ebp + 0xc]
cmp eax, dword [ebp + 0x14]
jl 0x1004e126
jg 0x1004e0b3
mov eax, dword [ebp + 0x10]
cmp dword [ebp + 8], eax
jbe 0x1004e126
jmp 0x1004e0b3
or edi, 0xffffffff
mov esi, edi
jmp 0x1004e33c
xor esi, esi
xor edi, edi
lea ecx, [ebp + 0x50]
call fcn.1003f96c
lea ecx, [ebp - 0x14]
call fcn.1000f660
mov eax, esi
mov edx, edi
jmp 0x1004e0c9
lea ecx, [ebp + 0x50]
call fcn.1003f96c
lea ecx, [ebp - 0x14]
call fcn.1000f660
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
add eax, dword [ebp + 0x60]
adc edx, dword [ebp + 0x64]
jmp 0x1004e0c9