Function at 0x10019c90
Capabilities:
Enumerate pe sections
Write file on windows

Disassembly:
sub esp, 0x81c
push ebx
mov ebx, dword [esp + 0x824]
push ebp
push esi
mov al, byte [ebx + 4]
mov esi, dword [esp + 0x834]
push edi
xor edi, edi
xor ebp, ebp
mov dword [esp + 0x1c], edi
test al, 1
mov dword [esp + 0x14], ebp
mov dword [esp + 0x10], edi
mov dword [esp + 0x18], edi
je 0x10019d06
mov ax, word [esi + 0x4ef4]
and eax, 0x4000
cmp eax, 0x4000
je 0x10019d06
cmp dword [ebx + 0x28], edi
jne 0x10019d06
push esi
push ebx
call fcn.10017680
add esp, 8
test eax, eax
jne 0x10019d06
mov ecx, dword [esi + 0xc9c0]
lea edx, [esi + 0xc7b4]
add ecx, 4
mov dword [ebx + 0x50], edx
mov dword [ebx + 0x28], ecx
mov dword [esp + 0x1c], 1
mov eax, dword [esi + 0x928]
test eax, eax
jne 0x10019d21
mov ecx, dword [ebx + 0x58]
lea eax, [esp + 0x2c]
push eax
push ecx
call dword [sym.imp.USER32.dll_CharToOemA]
jmp 0x10019d30
mov edx, dword [ebx + 0x58]
lea eax, [esp + 0x2c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov eax, dword [esi + 0x92c]
mov ecx, 0x14
test eax, eax
je 0x1001a008
test byte [esi + 0x4ef5], 0x10
je 0x10019d53
mov edi, 7
jmp 0x10019d93
mov eax, dword [ebx + 0x1c]
test eax, eax
jl 0x10019d6b
jg 0x10019d62
cmp dword [ebx + 0x18], 0xffffffff
jb 0x10019d6b
mov edi, 1
mov dword [esp + 0x18], edi
mov eax, dword [ebx + 0x14]
test eax, eax
jl 0x10019d81
jg 0x10019d7a
cmp dword [ebx + 0x10], 0xffffffff
jb 0x10019d81
or edi, 2
mov dword [esp + 0x18], edi
mov eax, dword [ebx + 0x44]
test eax, eax
jl 0x10019d97
jg 0x10019d90
cmp dword [ebx + 0x40], 0xffffffff
jb 0x10019d97
or edi, 4
mov dword [esp + 0x18], edi
lea eax, [edi - 1]
cmp eax, 6
ja case.default.0x10019da3
jmp dword [eax*4 + 0x1001a65c]
mov ecx, dword [ebx + 0x28]
mov dword [esp + 0x10], 0xc
add ecx, 0xc
push ecx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019ddb
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 8
mov edx, dword [ebx + 0x18]
mov dword [ebp + 4], edx
mov eax, dword [ebx + 0x1c]
mov dword [ebp + 8], eax
jmp 0x10019fd9
mov ecx, dword [ebx + 0x28]
mov dword [esp + 0x10], 0xc
add ecx, 0xc
push ecx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019e29
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 8
mov edx, dword [ebx + 0x10]
mov dword [ebp + 4], edx
mov eax, dword [ebx + 0x14]
mov dword [ebp + 8], eax
jmp 0x10019fd9
mov edx, dword [ebx + 0x28]
mov dword [esp + 0x10], ecx
add edx, ecx
push edx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019e72
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 0x10
mov eax, dword [ebx + 0x18]
mov dword [ebp + 4], eax
mov ecx, dword [ebx + 0x1c]
mov dword [ebp + 8], ecx
mov edx, dword [ebx + 0x10]
mov dword [ebp + 0xc], edx
mov eax, dword [ebx + 0x14]
mov dword [ebp + 0x10], eax
jmp 0x10019fd9
mov ecx, dword [ebx + 0x28]
mov dword [esp + 0x10], 0xc
add ecx, 0xc
push ecx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019ecc
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 8
mov edx, dword [ebx + 0x40]
mov dword [ebp + 4], edx
mov eax, dword [ebx + 0x44]
mov dword [ebp + 8], eax
jmp 0x10019fd9
mov edx, dword [ebx + 0x28]
mov dword [esp + 0x10], ecx
add edx, ecx
push edx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019f15
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 0x10
mov eax, dword [ebx + 0x18]
mov dword [ebp + 4], eax
mov ecx, dword [ebx + 0x1c]
mov dword [ebp + 8], ecx
mov edx, dword [ebx + 0x40]
mov dword [ebp + 0xc], edx
mov eax, dword [ebx + 0x44]
mov dword [ebp + 0x10], eax
jmp 0x10019fd9
mov ecx, dword [ebx + 0x28]
mov dword [esp + 0x10], 0x1c
add ecx, 0x1c
push ecx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019f6f
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov word [ebp], 1
mov word [ebp + 2], 0x18
mov edx, dword [ebx + 0x18]
mov dword [ebp + 4], edx
mov eax, dword [ebx + 0x1c]
mov dword [ebp + 8], eax
mov ecx, dword [ebx + 0x10]
mov dword [ebp + 0xc], ecx
mov edx, dword [ebx + 0x14]
mov dword [ebp + 0x10], edx
mov eax, dword [ebx + 0x40]
mov dword [ebp + 0x14], eax
mov ecx, dword [ebx + 0x44]
mov dword [ebp + 0x18], ecx
jmp 0x10019fd9
mov eax, dword [ebx + 0x28]
xor ebp, ebp
cmp eax, ebp
mov dword [esp + 0x18], ebp
mov dword [esp + 0x10], ebp
jbe 0x10019fd5
push eax
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
mov dword [esp + 0x14], ebp
jne 0x10019fd9
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x81c
ret
mov dword [esp + 0x14], ebp
mov ecx, dword [ebx + 0x28]
test ecx, ecx
jbe 0x1001a008
test ebp, ebp
je 0x1001a008
mov edi, dword [esp + 0x10]
mov esi, dword [ebx + 0x50]
and edi, 0xffff
mov edx, ecx
add edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x838]
test byte [esi + 0x4ef5], 0x80
je 0x1001a04a
mov eax, dword [esi + 0x4efc]
cmp eax, 0xffff
mov eax, dword [esi + 0x4ef8]
jne 0x1001a02c
mov dword [esi + 0x4efc], eax
jmp 0x1001a034
cmp eax, dword [esi + 0x4f00]
je 0x1001a044
mov dword [esi + 0x4f00], eax
mov dword [esi + 0x4f08], 0
inc dword [esi + 0x4f08]
mov eax, dword [esp + 0x10]
mov edi, dword [ebx + 0x28]
mov edx, dword [ebx + 0x2c]
mov ecx, dword [ebx + 0x20]
and eax, 0xffff
add eax, edi
xor edi, edi
add eax, edx
lea eax, [eax + ecx + 0x2e]
mov ecx, dword [esi + 0xa8]
cmp ecx, 0xffffffff
mov dword [esp + 0x24], eax
je 0x1001a359
mov ecx, dword [esi + 0x4f28]
test ecx, ecx
jne 0x1001a359
push esi
call fcn.10020aa0
add esp, 4
cmp edx, edi
jg 0x1001a0cf
jl 0x1001a09c
cmp eax, dword [esp + 0x24]
jae 0x1001a0cf
mov edx, dword [esp + 0x834]
push esi
push edx
push 0
call fcn.10020bc0
mov esi, eax
add esp, 0xc
test esi, esi
je 0x1001a0cf
test ebp, ebp
je 0x1001a0c2
push ebp
call fcn.10039f0f
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x81c
ret
mov eax, dword [esp + 0x24]
inc eax
push eax
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x1001a339
mov edx, dword [esp + 0x18]
mov dword [ebp], 0x2014b50
test edx, edx
je 0x1001a142
mov cx, word [ebx]
mov word [ebp + 4], cx
mov ax, word [ebx + 2]
mov word [ebp + 6], ax
mov cx, word [ebx + 4]
mov word [ebp + 8], cx
mov ax, word [ebx + 6]
mov word [ebp + 0xa], ax
mov ecx, dword [ebx + 8]
mov dword [ebp + 0xc], ecx
mov eax, dword [ebx + 0xc]
mov dword [ebp + 0x10], eax
lea eax, [edx - 1]
cmp eax, 6
ja case.default.0x1001a12d
jmp dword [eax*4 + 0x1001a678]
lea ecx, [ebp + 0x18]
mov dword [ecx], 0xffffffff
jmp 0x1001a1f3
mov ax, word [ebx]
xor ecx, ecx
cmp word [ebx + 6], 9
sete cl
add ecx, 0x14
cmp ax, 0x2d
jb 0x1001a15e
mov word [ebp + 4], cx
jmp 0x1001a162
mov word [ebp + 4], ax
mov ax, word [ebx + 2]
cmp ax, 0x2d
jb 0x1001a101
mov word [ebp + 6], cx
jmp 0x1001a105
mov ecx, dword [ebx + 0x18]
lea edx, [ebp + 0x14]
mov dword [ebp + 0x18], ecx
mov dword [edx], 0xffffffff
jmp 0x1001a1f9
lea ecx, [ebp + 0x18]
lea edx, [ebp + 0x14]
mov dword [ecx], 0xffffffff
mov dword [edx], 0xffffffff
jmp 0x1001a1f9
mov ecx, dword [ebx + 0x18]
lea eax, [ebp + 0x2a]
mov dword [ebp + 0x18], ecx
mov edx, dword [ebx + 0x10]
mov dword [ebp + 0x14], edx
mov dword [eax], 0xffffffff
jmp 0x1001a1ff
lea ecx, [ebp + 0x18]
lea eax, [ebp + 0x2a]
mov dword [ecx], 0xffffffff
mov edx, dword [ebx + 0x10]
mov dword [ebp + 0x14], edx
mov dword [eax], 0xffffffff
jmp 0x1001a1ff
mov ecx, dword [ebx + 0x18]
mov dword [ebp + 0x18], ecx
jmp 0x1001a1d9
lea ecx, [ebp + 0x18]
mov dword [ecx], 0xffffffff
lea edx, [ebp + 0x14]
lea eax, [ebp + 0x2a]
mov dword [edx], 0xffffffff
mov dword [eax], 0xffffffff
jmp 0x1001a1ff
mov ecx, dword [ebx + 0x18]
mov dword [ebp + 0x18], ecx
mov edx, dword [ebx + 0x10]
mov dword [ebp + 0x14], edx
mov eax, dword [ebx + 0x40]
mov dword [ebp + 0x2a], eax
mov cx, word [ebx + 0x20]
mov esi, dword [esp + 0x10]
mov word [ebp + 0x1c], cx
mov dx, word [ebx + 0x28]
add esi, edx
lea edi, [ebp + 0x2e]
mov ax, si
mov dword [esp + 0x10], esi
mov word [ebp + 0x1e], ax
sub ax, word [ebx + 0x28]
lea esi, [esp + 0x2c]
mov word [esp + 0x10], ax
mov ax, word [ebx + 0x2c]
mov word [ebp + 0x20], ax
mov cx, word [ebx + 0x30]
mov word [ebp + 0x22], cx
mov dx, word [ebx + 0x34]
mov word [ebp + 0x24], dx
mov eax, dword [ebx + 0x38]
mov dword [ebp + 0x26], eax
mov ecx, dword [ebx + 0x20]
mov edx, ecx
mov eax, dword [esp + 0x18]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
test eax, eax
mov eax, dword [esp + 0x10]
rep movsb byte es:[edi], byte [esi]
je 0x1001a27a
mov esi, dword [ebx + 0x28]
mov ecx, eax
and ecx, 0xffff
add ecx, esi
mov esi, dword [esp + 0x14]
jmp 0x1001a284
mov ecx, dword [ebx + 0x28]
test ecx, ecx
jbe 0x1001a299
mov esi, dword [ebx + 0x50]
mov edx, dword [ebx + 0x20]
lea edi, [edx + ebp + 0x2e]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebx + 0x2c]
test ecx, ecx
jbe 0x1001a2c4
mov edx, dword [ebx + 0x28]
and eax, 0xffff
mov esi, dword [ebx + 0x54]
add eax, edx
mov edx, dword [ebx + 0x20]
add eax, ebp
lea edi, [eax + edx + 0x2e]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x838]
mov esi, dword [esp + 0x24]
lea ecx, [esp + 0x20]
push 0
mov eax, dword [edx + 0xa8]
push ecx
push esi
push ebp
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1001a310
cmp dword [esp + 0x20], esi
jne 0x1001a310
push ebp
call fcn.10039f0f
mov eax, dword [esp + 0x20]
add esp, 4
test eax, eax
je 0x1001a5d0
mov dword [ebx + 0x50], 0
jmp 0x1001a5d0
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x1001a31f
mov dword [ebx + 0x50], 0
push ebp
call fcn.10039f0f
mov eax, dword [esp + 0x18]
add esp, 4
test eax, eax
je 0x1001a64a
jmp 0x1001a641
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x1001a348
mov dword [ebx + 0x50], 0
mov eax, dword [esp + 0x14]
test eax, eax
je 0x1001a64a
jmp 0x1001a641
mov ecx, dword [esp + 0x834]
push esi
push edi
push eax
push ecx
push 0
call fcn.10020210
add esp, 0x14
test eax, eax
je 0x1001a399
test ebp, ebp
je 0x1001a37f
push ebp
call fcn.10039f0f
add esp, 4
mov eax, dword [esi + 0xa0]
pop edi
neg eax
sbb eax, eax
pop esi
and al, 0xf6
pop ebp
add eax, 0x13
pop ebx
add esp, 0x81c
ret
mov edx, dword [esp + 0x24]
inc edx
push edx
call fcn.10039ff8
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x1001a62a
mov edx, dword [esp + 0x18]
mov dword [ebp], 0x2014b50
test edx, edx
je 0x1001a3d1
mov ax, word [ebx]
mov word [ebp + 4], ax
mov cx, word [ebx + 2]
mov word [ebp + 6], cx
jmp 0x1001a405
mov ax, word [ebx]
xor ecx, ecx
cmp word [ebx + 6], 9
sete cl
add ecx, 0x14
cmp ax, 0x2d
jb 0x1001a3ed
mov word [ebp + 4], cx
jmp 0x1001a3f1
mov word [ebp + 4], ax
mov ax, word [ebx + 2]
cmp ax, 0x2d
jb 0x1001a401
mov word [ebp + 6], cx
jmp 0x1001a405
mov word [ebp + 6], ax
mov ax, word [ebx + 4]
mov word [ebp + 8], ax
mov cx, word [ebx + 6]
mov word [ebp + 0xa], cx
mov eax, dword [ebx + 8]
mov dword [ebp + 0xc], eax
mov ecx, dword [ebx + 0xc]
lea eax, [edx - 1]
mov dword [ebp + 0x10], ecx
cmp eax, 6
ja case.default.0x1001a42d
jmp dword [eax*4 + 0x1001a694]
lea edx, [ebp + 0x18]
mov dword [edx], 0xffffffff
jmp 0x1001a4c3
mov edx, dword [ebx + 0x18]
lea eax, [ebp + 0x14]
mov dword [ebp + 0x18], edx
mov dword [eax], 0xffffffff
jmp 0x1001a4c9
lea edx, [ebp + 0x18]
lea eax, [ebp + 0x14]
mov dword [edx], 0xffffffff
mov dword [eax], 0xffffffff
jmp 0x1001a4c9
mov edx, dword [ebx + 0x18]
lea ecx, [ebp + 0x2a]
mov dword [ebp + 0x18], edx
mov eax, dword [ebx + 0x10]
mov dword [ebp + 0x14], eax
mov dword [ecx], 0xffffffff
jmp 0x1001a4cf
lea edx, [ebp + 0x18]
lea ecx, [ebp + 0x2a]
mov dword [edx], 0xffffffff
mov eax, dword [ebx + 0x10]
mov dword [ebp + 0x14], eax
mov dword [ecx], 0xffffffff
jmp 0x1001a4cf
mov edx, dword [ebx + 0x18]
mov dword [ebp + 0x18], edx
jmp 0x1001a4a9
lea edx, [ebp + 0x18]
mov dword [edx], 0xffffffff
lea eax, [ebp + 0x14]
lea ecx, [ebp + 0x2a]
mov dword [eax], 0xffffffff
mov dword [ecx], 0xffffffff
jmp 0x1001a4cf
mov edx, dword [ebx + 0x18]
mov dword [ebp + 0x18], edx
mov eax, dword [ebx + 0x10]
mov dword [ebp + 0x14], eax
mov ecx, dword [ebx + 0x40]
mov dword [ebp + 0x2a], ecx
mov dx, word [ebx + 0x20]
lea esi, [esp + 0x2c]
mov word [ebp + 0x1c], dx
mov ax, word [ebx + 0x28]
mov edx, dword [esp + 0x10]
lea edi, [ebp + 0x2e]
add edx, eax
mov ax, dx
mov dword [esp + 0x10], edx
mov word [ebp + 0x1e], ax
mov cx, word [ebx + 0x2c]
sub ax, word [ebx + 0x28]
mov word [ebp + 0x20], cx
mov dx, word [ebx + 0x30]
mov word [esp + 0x10], ax
mov word [ebp + 0x22], dx
mov ax, word [ebx + 0x34]
mov word [ebp + 0x24], ax
mov ecx, dword [ebx + 0x38]
mov dword [ebp + 0x26], ecx
mov ecx, dword [ebx + 0x20]
mov edx, ecx
mov eax, dword [esp + 0x18]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
test eax, eax
mov eax, dword [esp + 0x10]
rep movsb byte es:[edi], byte [esi]
je 0x1001a54a
mov esi, dword [ebx + 0x28]
mov ecx, eax
and ecx, 0xffff
add ecx, esi
mov esi, dword [esp + 0x14]
jmp 0x1001a554
mov ecx, dword [ebx + 0x28]
test ecx, ecx
jbe 0x1001a569
mov esi, dword [ebx + 0x50]
mov edx, dword [ebx + 0x20]
lea edi, [edx + ebp + 0x2e]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebx + 0x2c]
test ecx, ecx
jbe 0x1001a594
mov edx, dword [ebx + 0x28]
and eax, 0xffff
mov esi, dword [ebx + 0x54]
add eax, edx
mov edx, dword [ebx + 0x20]
add eax, ebp
lea edi, [eax + edx + 0x2e]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x834]
mov esi, dword [esp + 0x24]
xor edi, edi
lea ecx, [esp + 0x20]
mov eax, dword [edx]
push edi
push ecx
push esi
push ebp
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1001a60e
cmp dword [esp + 0x20], esi
jne 0x1001a60e
push ebp
call fcn.10039f0f
mov eax, dword [esp + 0x20]
add esp, 4
cmp eax, edi
je 0x1001a5d0
mov dword [ebx + 0x50], edi
mov ecx, dword [esp + 0x14]
test ecx, ecx
je 0x1001a5fa
mov eax, dword [esp + 0x10]
push ecx
and eax, 0xffff
mov dword [ebx + 0x64], eax
call fcn.10039f0f
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x81c
ret
pop edi
pop esi
mov dword [ebx + 0x64], 0
pop ebp
xor eax, eax
pop ebx
add esp, 0x81c
ret
cmp dword [esp + 0x1c], edi
je 0x1001a617
mov dword [ebx + 0x50], edi
push ebp
call fcn.10039f0f
mov eax, dword [esp + 0x18]
add esp, 4
cmp eax, edi
je 0x1001a64a
jmp 0x1001a641
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x1001a639
mov dword [ebx + 0x50], 0
mov eax, dword [esp + 0x14]
test eax, eax
je 0x1001a64a
push eax
call fcn.10039f0f
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 0xa
pop ebx
add esp, 0x81c
ret