Function at 0x6d9550c0
Capabilities:
Enumerate pe sections
Get system information on windows
Parse pe header

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x8c
cmp dword [esp + 0xa4], 0x3f
jbe 0x6d955510
mov eax, dword [esp + 0xa0]
cmp word [eax], 0x5a4d
jne 0x6d9554f0
mov eax, dword [esp + 0xa0]
mov eax, dword [eax + 0x3c]
lea edx, [eax + 0xf8]
cmp dword [esp + 0xa4], edx
jb 0x6d955510
add eax, dword [esp + 0xa0]
cmp dword [eax], 0x4550
mov esi, eax
jne 0x6d9554f0
cmp word [eax + 4], 0x14c
jne 0x6d9554f0
mov ebp, dword [eax + 0x38]
test ebp, 1
jne 0x6d9554f0
movzx eax, word [eax + 0x14]
movzx edi, word [esi + 6]
xor ebx, ebx
mov dword [esp + 0x28], edi
lea edx, [esi + eax + 0x18]
test di, di
je 0x6d9551a6
mov dword [esp + 0x2c], esi
xor ecx, ecx
jmp 0x6d955180
mov esi, dword [edx + 0x10]
mov eax, dword [edx + 0xc]
lea edi, [ebp + eax]
add eax, esi
test esi, esi
cmove eax, edi
cmp ebx, eax
cmovb ebx, eax
add ecx, 1
add edx, 0x28
cmp dword [esp + 0x28], ecx
jne 0x6d955180
mov esi, dword [esp + 0x2c]
lea eax, [esp + 0x5c]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov eax, dword [esi + 0x50]
sub esp, 4
mov edx, dword [esp + 0x60]
lea ecx, [edx - 1]
neg edx
add eax, ecx
add ebx, ecx
and eax, edx
and ebx, edx
cmp ebx, eax
jne 0x6d9554f0
mov eax, dword [esp + 0xbc]
mov dword [esp + 0xc], 4
mov dword [esp + 8], 0x3000
mov dword [esp + 0x10], eax
mov dword [esp + 4], ebx
mov eax, dword [esi + 0x34]
mov dword [esp], eax
call dword [esp + 0xa8]
mov dword [esp + 0x38], eax
test eax, eax
je 0x6d955528
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov dword [esp + 8], 0x40
mov dword [esp + 4], 8
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
sub esp, 0xc
mov edi, eax
test eax, eax
je 0x6d9558f8
mov eax, dword [esp + 0x38]
mov dword [edi + 4], eax
movzx eax, byte [esi + 0x17]
shr al, 5
and eax, 1
mov dword [edi + 0x14], eax
mov eax, dword [esp + 0xa8]
mov dword [edi + 0x1c], eax
mov eax, dword [esp + 0xac]
mov dword [edi + 0x20], eax
mov eax, dword [esp + 0xb0]
mov dword [edi + 0x24], eax
mov eax, dword [esp + 0xb4]
mov dword [edi + 0x28], eax
mov eax, dword [esp + 0xb8]
mov dword [edi + 0x2c], eax
mov eax, dword [esp + 0xbc]
mov dword [edi + 0x34], eax
mov eax, dword [esp + 0x60]
mov dword [edi + 0x3c], eax
mov eax, dword [esi + 0x54]
cmp dword [esp + 0xa4], eax
jb 0x6d955578
mov ebp, dword [esp + 0x38]
mov ecx, dword [esp + 0xbc]
mov dword [esp + 4], eax
mov dword [esp + 0xc], 4
mov dword [esp + 0x10], ecx
mov dword [esp], ebp
mov dword [esp + 8], 0x1000
call dword [esp + 0xa8]
mov ebx, eax
mov eax, dword [esi + 0x54]
mov dword [esp], ebx
mov dword [esp + 8], eax
mov eax, dword [esp + 0xa0]
mov dword [esp + 4], eax
call sub.msvcrt.dll_memcpy
mov eax, dword [esp + 0xa0]
mov edx, dword [edi + 4]
add ebx, dword [eax + 0x3c]
mov eax, ebp
movzx ecx, word [ebx + 0x14]
cmp word [ebx + 6], 0
mov dword [edi], ebx
mov dword [esp + 0x34], ebx
mov dword [ebx + 0x34], ebp
lea ebp, [ebx + ecx + 0x18]
je 0x6d95539c
mov dword [esp + 0x28], esi
xor ebx, ebx
mov esi, edx
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x6d9555a8
mov eax, dword [esp + 0x28]
mov ecx, dword [eax + 0x38]
test ecx, ecx
jle 0x6d955381
mov eax, dword [edi + 0x34]
mov dword [esp + 0xc], 4
mov dword [esp + 8], 0x1000
mov dword [esp + 0x10], eax
mov dword [esp + 4], ecx
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x2c], ecx
add eax, esi
mov dword [esp], eax
call dword [edi + 0x1c]
test eax, eax
je 0x6d955588
mov eax, dword [ebp + 0xc]
mov ecx, dword [esp + 0x2c]
add eax, esi
mov dword [ebp + 8], eax
mov dword [esp + 8], ecx
mov dword [esp + 4], 0
mov dword [esp], eax
call sub.msvcrt.dll_memset
mov eax, dword [edi]
add ebx, 1
add ebp, 0x28
movzx ecx, word [eax + 6]
cmp ebx, ecx
jl 0x6d955319
mov dword [esp + 0x34], eax
mov esi, dword [esp + 0x28]
mov eax, dword [eax + 0x34]
sub eax, dword [esi + 0x34]
mov ecx, 1
mov dword [esp + 0x28], eax
jne 0x6d95583b
mov eax, dword [esp + 0x34]
mov dword [edi + 0x18], ecx
mov ebx, dword [eax + 0x84]
test ebx, ebx
je 0x6d955618
mov esi, dword [edi + 4]
mov dword [esp + 0x28], esi
add esi, dword [eax + 0x80]
mov dword [esp + 0x2c], esi
lea esi, cs:[esi]
lea esi, [esi]
mov eax, dword [esp + 0x2c]
mov dword [esp + 4], 0x14
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
sub esp, 8
test eax, eax
jne 0x6d955612
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x6d955612
mov esi, dword [esp + 0x28]
mov edx, dword [edi + 0x34]
add eax, esi
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [edi + 0x24]
mov esi, eax
test eax, eax
je 0x6d9558e3
mov eax, dword [edi + 0xc]
lea eax, [eax*4 + 4]
mov dword [esp + 4], eax
mov eax, dword [edi + 8]
mov dword [esp], eax
call sub.msvcrt.dll_realloc
test eax, eax
je 0x6d955950
mov edx, dword [edi + 0xc]
mov ebx, dword [esp + 0x2c]
mov dword [edi + 8], eax
lea ecx, [edx + 1]
mov dword [edi + 0xc], ecx
mov ecx, ebx
mov dword [eax + edx*4], esi
mov ebp, dword [ecx + 0x10]
mov eax, dword [ebx]
mov ebx, dword [esp + 0x28]
add ebp, ebx
add ebx, eax
test eax, eax
cmove ebx, ebp
mov eax, dword [ebx]
test eax, eax
jne 0x6d9554a9
jmp 0x6d955598
mov ecx, dword [esp + 0x28]
mov dword [esp], esi
lea eax, [ecx + eax + 2]
mov dword [esp + 4], eax
call edx
mov dword [ebp], eax
test eax, eax
je 0x6d9554ca
mov eax, dword [ebx + 4]
add ebx, 4
add ebp, 4
test eax, eax
je 0x6d955598
mov ecx, dword [edi + 0x34]
mov edx, dword [edi + 0x28]
mov dword [esp + 8], ecx
test eax, eax
jns 0x6d955480
movzx eax, ax
mov dword [esp], esi
mov dword [esp + 4], eax
call edx
mov dword [ebp], eax
test eax, eax
jne 0x6d955498
mov eax, dword [edi + 0x34]
mov dword [esp], esi
mov dword [esp + 4], eax
call dword [edi + 0x2c]
mov dword [esp], 0x7f
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
jmp 0x6d955588
mov dword [esp], 0xc1
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
xor edi, edi
add esp, 0x8c
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], 0xd
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
jmp 0x6d955500
mov eax, dword [esp + 0xbc]
mov dword [esp + 0xc], 4
mov dword [esp + 8], 0x3000
mov dword [esp + 0x10], eax
mov dword [esp + 4], ebx
mov dword [esp], 0
call dword [esp + 0xa8]
mov dword [esp + 0x38], eax
test eax, eax
jne 0x6d95520a
mov dword [esp], 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
jmp 0x6d955500
mov dword [esp], 0xd
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
mov dword [esp], edi
call fcn.6d954fe0
jmp 0x6d955500
add dword [esp + 0x2c], 0x14
jmp 0x6d9553e0
mov ecx, dword [ebp + 0x14]
add ecx, eax
cmp dword [esp + 0xa4], ecx
jb 0x6d955578
mov ecx, dword [edi + 0x34]
mov dword [esp + 0xc], 4
mov dword [esp + 8], 0x1000
mov dword [esp + 0x10], ecx
mov dword [esp + 4], eax
mov eax, dword [ebp + 0xc]
add eax, esi
mov dword [esp], eax
call dword [edi + 0x1c]
test eax, eax
je 0x6d955588
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov eax, dword [esp + 0xa0]
add eax, dword [ebp + 0x14]
add ecx, esi
mov dword [esp + 8], edx
mov dword [esp], ecx
mov dword [esp + 4], eax
mov dword [esp + 0x2c], ecx
call sub.msvcrt.dll_memcpy
mov ecx, dword [esp + 0x2c]
mov dword [ebp + 8], ecx
jmp 0x6d955381
mov eax, dword [edi]
mov dword [esp + 0x34], eax
mov ecx, dword [esp + 0x34]
mov ebx, dword [edi + 0x3c]
movzx eax, word [ecx + 0x14]
lea edx, [ecx + eax + 0x18]
mov eax, ebx
mov esi, dword [edx + 8]
neg eax
mov ebp, esi
and esi, eax
mov eax, dword [edx + 0x10]
mov dword [esp + 0x30], esi
test eax, eax
jne 0x6d955660
mov eax, dword [edx + 0x24]
test al, 0x40
jne 0x6d9558d2
and eax, 0x80
je 0x6d955660
mov eax, dword [esp + 0x34]
mov eax, dword [eax + 0x24]
lea esi, cs:[esi]
nop
mov esi, dword [edx + 0x24]
mov dword [esp + 0x58], 0
lea ecx, [edx + 0x28]
mov dword [esp + 0x2c], esi
mov esi, dword [esp + 0x34]
cmp word [esi + 6], 1
jbe 0x6d95592e
lea esi, [esp + 0x48]
mov edx, dword [esp + 0x34]
mov dword [esp + 0x28], 1
mov dword [esp + 0x3c], esi
mov esi, ecx
mov ecx, ebp
mov dword [esp + 0x34], edi
jmp 0x6d9556fa
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x48], ecx
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x54], eax
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
mov dword [esp + 0x4c], ecx
call fcn.6d954b00
test eax, eax
je 0x6d9558da
mov eax, dword [esi + 0x24]
mov dword [esp + 0x30], ebx
mov ecx, edi
mov dword [esp + 0x2c], eax
mov eax, ebp
mov ebp, dword [esp + 0x34]
add dword [esp + 0x28], 1
add esi, 0x28
mov edi, dword [esp + 0x28]
mov edx, dword [ebp]
movzx ebx, word [edx + 6]
cmp edi, ebx
jge 0x6d95576d
mov ebx, dword [ebp + 0x3c]
mov edi, dword [esi + 8]
mov ebp, dword [esi + 0x10]
neg ebx
and ebx, edi
test ebp, ebp
jne 0x6d955716
mov ebp, dword [esi + 0x24]
test ebp, 0x40
je 0x6d955760
mov ebp, dword [edx + 0x20]
cmp dword [esp + 0x30], ebx
je 0x6d955727
lea edx, [eax + ecx]
cmp ebx, edx
jae 0x6d9556a0
mov ebx, dword [esp + 0x2c]
mov eax, dword [esi + 0x24]
mov edx, ebx
or edx, eax
test eax, 0x2000000
je 0x6d955746
mov eax, ebx
mov dword [esp + 0x2c], edx
and eax, 0x2000000
jne 0x6d955750
and edx, 0xfdffffff
mov dword [esp + 0x2c], edx
mov eax, edi
sub eax, ecx
add eax, ebp
jmp 0x6d9556dc
and ebp, 0x80
je 0x6d955716
mov ebp, dword [edx + 0x24]
jmp 0x6d955716
mov edi, dword [esp + 0x34]
mov ebp, ecx
mov esi, dword [esp + 0x30]
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x58], 1
mov dword [esp + 0x48], ebp
mov dword [esp + 0x54], eax
mov eax, edi
mov dword [esp + 0x4c], esi
call fcn.6d954b00
test eax, eax
je 0x6d955588
mov edx, dword [edi]
mov eax, dword [edx + 0xc0]
test eax, eax
je 0x6d9557f3
mov esi, dword [edi + 4]
mov ebx, dword [esi + eax + 0xc]
test ebx, ebx
je 0x6d9557f3
mov eax, dword [ebx]
test eax, eax
je 0x6d9557f3
lea esi, cs:[esi]
lea esi, cs:[esi]
add ebx, 4
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], esi
call eax
mov eax, dword [ebx]
sub esp, 0xc
test eax, eax
jne 0x6d9557d0
mov edx, dword [edi]
mov eax, dword [edx + 0x28]
test eax, eax
je 0x6d9558c6
mov esi, dword [esp + 0x38]
mov edx, dword [edi + 0x14]
add eax, esi
test edx, edx
je 0x6d955926
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], esi
call eax
sub esp, 0xc
test eax, eax
je 0x6d95593b
mov dword [edi + 0x10], 1
jmp 0x6d955502
mov eax, dword [esp + 0x34]
xor ecx, ecx
mov esi, dword [eax + 0xa4]
test esi, esi
je 0x6d9553ae
mov esi, dword [eax + 0xa0]
mov ebp, dword [edi + 4]
add esi, ebp
mov eax, dword [esi]
test eax, eax
je 0x6d9558bc
mov dword [esp + 0x2c], edi
mov edi, eax
lea esi, cs:[esi]
nop
mov ebx, dword [esi + 4]
lea eax, [ebx - 8]
shr eax, 1
je 0x6d9558b0
xor eax, eax
lea esi, [esi]
movzx edx, word [esi + eax*2 + 8]
mov ecx, edx
shr cx, 0xc
cmp cx, 3
jne 0x6d9558a4
and edx, 0xfff
mov ecx, dword [esp + 0x28]
add edx, edi
add dword [ebp + edx], ecx
mov ebx, dword [esi + 4]
lea edx, [ebx - 8]
add eax, 1
shr edx, 1
cmp eax, edx
jb 0x6d955880
add esi, ebx
mov edi, dword [esi]
test edi, edi
jne 0x6d955870
mov edi, dword [esp + 0x2c]
mov ecx, 1
jmp 0x6d9553ae
mov dword [edi + 0x38], 0
jmp 0x6d955502
mov eax, dword [ecx + 0x20]
jmp 0x6d955660
mov edi, dword [esp + 0x34]
jmp 0x6d955588
mov dword [esp], 0x7e
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
jmp 0x6d955588
mov eax, dword [esp + 0xbc]
mov dword [esp + 8], 0x8000
mov dword [esp + 4], 0
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x38]
mov dword [esp], eax
call dword [esp + 0xac]
jmp 0x6d955561
mov dword [edi + 0x38], eax
jmp 0x6d955502
lea esi, [esp + 0x48]
mov dword [esp + 0x3c], esi
jmp 0x6d955773
mov dword [esp], 0x45a
call dword [sym.imp.KERNEL32.dll_SetLastError]
sub esp, 4
jmp 0x6d955588
mov eax, dword [edi + 0x34]
mov dword [esp], esi
mov dword [esp + 4], eax
call dword [edi + 0x2c]
mov dword [esp], 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ecx
jmp 0x6d955588