joyce8/EMBER2024-capa huggingface dataset:
Function at 0x456060
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x238
mov eax, dword [0x48602c]
xor eax, ebp
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x234], ecx
mov dword [ebp - 0x224], 1
mov word [ebp - 0x218], 0
push 0x206
push 0
lea eax, [ebp - 0x216]
push eax
call sub.MSVCR80.dll_memset
add esp, 0xc
mov dword [ebp - 8], 0xffffffff
mov dword [ebp - 0x228], 0
mov dword [ebp - 0x220], 0
xor ecx, ecx
mov dword [ebp - 0x21c], ecx
mov dword [ebp - 4], 0
push 0x104
lea edx, [ebp - 0x218]
push edx
mov ecx, dword [ebp - 0x234]
call fcn.00455d40
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0
jne 0x456123
push 0x9c9
push 0x47a5b4
call fcn.00455990
add esp, 8
push eax
push 0x47a5c8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00401020
add esp, 0xc
jmp 0x456279
push 0
push 0x80
push 3
push 0
push 3
push 0xc0000000
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 8], eax
xor ecx, ecx
cmp dword [ebp - 8], 0xffffffff
setne cl
mov dword [ebp - 0x224], ecx
cmp dword [ebp - 0x224], 0
jne 0x45618e
push 0x9cc
push 0x47a5f0
call fcn.00455990
add esp, 8
push eax
push 0x47a604
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00401020
add esp, 0xc
jmp 0x456279
lea edx, [ebp - 0x220]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov ecx, dword [ebp - 0x220]
push ecx
call fcn.0043acf2
add esp, 4
mov dword [ebp - 0x22c], eax
mov edx, dword [ebp - 0x22c]
mov dword [ebp - 0x228], edx
push 0
lea eax, [ebp - 4]
push eax
mov ecx, dword [ebp - 0x220]
push ecx
mov edx, dword [ebp - 0x228]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0
jne 0x456218
push 0x9d0
push 0x47a624
call fcn.00455990
add esp, 8
push eax
push str.ReadFile_hFile__pbuffer___DWORD_lFIleSize.QuadPart__dwSize__NULL_
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00401020
add esp, 0xc
jmp 0x456279
cmp dword [ebp - 4], 0x1230
jae 0x45622c
mov ecx, dword [ebp - 4]
mov dword [ebp - 0x238], ecx
jmp 0x456236
mov dword [ebp - 0x238], 0x1230
mov edx, dword [ebp - 0x238]
push edx
mov eax, dword [ebp - 0x228]
push eax
mov ecx, dword [ebp + 8]
push ecx
call sub.MSVCR80.dll_memcpy
add esp, 0xc
cmp dword [ebp - 8], 0xffffffff
je 0x456267
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 8], 0xffffffff
lea eax, [ebp - 0x218]
push eax
mov ecx, dword [ebp - 0x234]
call fcn.00455e00
cmp dword [ebp - 0x228], 0
je 0x4562a7
mov ecx, dword [ebp - 0x228]
mov dword [ebp - 0x230], ecx
mov edx, dword [ebp - 0x230]
push edx
call sub.MSVCR80.dll_void___cdecl_operator_delete___void__
add esp, 4
mov dword [ebp - 0x228], 0
cmp dword [ebp - 8], 0xffffffff
je 0x4562be
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 8], 0xffffffff
mov eax, dword [ebp - 0x224]
mov ecx, dword [ebp - 0xc]
xor ecx, ebp
call fcn.0043ad38
mov esp, ebp
pop ebp
ret 4
Function at 0x457580
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x10], 1
mov dword [ebp - 0xc], 0
xor eax, eax
mov dword [ebp - 8], eax
mov dword [ebp - 4], eax
mov dword [ebp - 4], 1
mov ecx, dword [ebp - 0x14]
cmp dword [ecx + 0x1464], 0xffffffff
je 0x4575df
push 0
mov edx, dword [ebp - 0x14]
mov eax, dword [edx + 0x1464]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0xffffffff
jne 0x4575d8
mov ecx, dword [ebp - 0x14]
mov dword [ecx + 0x1464], 0xffffffff
jmp 0x4575df
mov eax, 1
jmp 0x457646
push 0
push 0
mov edx, dword [ebp - 0x14]
push edx
push 0x462100
push 0
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.MSVCR80.dll__beginthreadex]
add esp, 0x18
mov ecx, dword [ebp - 0x14]
mov dword [ecx + 0x1464], eax
mov edx, dword [ebp - 0x14]
xor eax, eax
cmp dword [edx + 0x1464], 0xffffffff
setne al
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x457643
push 0x90b
push 0x47a4a4
call fcn.00455990
add esp, 8
push eax
push 0x47a4b8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00401020
add esp, 0xc
mov eax, dword [ebp - 0x10]
mov esp, ebp
pop ebp
ret
Function at 0x460e00
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1254
call fcn.004646d0
mov eax, dword [0x48602c]
xor eax, ebp
mov dword [ebp - 8], eax
push esi
push edi
mov dword [ebp - 0x1250], ecx
mov dword [ebp - 4], 0
mov dword [ebp - 0x1244], 0
xor eax, eax
mov dword [ebp - 0x1240], eax
mov dword [ebp - 0x123c], eax
mov dword [ebp - 0x123c], 1
mov dword [ebp - 0x1238], 0
push 0x122c
push 0
lea ecx, [ebp - 0x1234]
push ecx
call sub.MSVCR80.dll_memset
add esp, 0xc
mov edx, dword [ebp - 0x1250]
cmp dword [edx + 0x1458], 0xffffffff
je 0x460e7f
mov eax, dword [ebp - 4]
jmp 0x461032
push 0xffffffffffffffff
mov eax, dword [ebp - 0x1250]
mov ecx, dword [eax + 0x145c]
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, dword [ebp - 0x1250]
call fcn.00401ae0
neg eax
sbb eax, eax
add eax, 1
mov dword [ebp - 0x1248], eax
jne 0x460edf
push 0x14f
push 0x478100
call fcn.00455990
add esp, 8
push eax
push str._IsExec__
mov edx, dword [ebp - 0x1248]
push edx
call fcn.00401020
add esp, 0xc
jmp 0x46101c
lea eax, [ebp - 0x1238]
push eax
mov ecx, dword [ebp - 0x1250]
call fcn.00456060
test eax, eax
je 0x460f35
lea esi, [ebp - 0x1238]
mov eax, 0x1230
call fcn.004646d0
mov ecx, 0x48c
mov edi, esp
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x1250]
call fcn.004550c0
lea ecx, [ebp - 0x1008]
push ecx
mov edx, dword [ebp - 0x1250]
add edx, 0x31dc
push edx
call fcn.00401eb0
add esp, 8
call sub.Comn.dll_GetObjectLog
mov dword [ebp - 0x1254], eax
push 0x157
push 0x478120
call fcn.00455990
add esp, 8
push eax
push str._s:________________________Start_work_thread__________________________
mov eax, dword [ebp - 0x1254]
push eax
mov ecx, dword [ebp - 0x1254]
mov edx, dword [ecx]
mov eax, dword [edx + 0xc]
call eax
add esp, 0xc
mov ecx, dword [ebp - 0x1250]
cmp dword [ecx + 0x1458], 0xffffffff
je 0x460fa1
mov edx, dword [ebp - 0x1250]
mov eax, dword [edx + 0x1458]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x1250]
mov dword [ecx + 0x1458], 0xffffffff
push 0
push 0
mov edx, dword [ebp - 0x1250]
push edx
push 0x462220
push 0
lea eax, [ebp - 0x1244]
push eax
call dword [sym.imp.MSVCR80.dll__beginthreadex]
add esp, 0x18
mov ecx, dword [ebp - 0x1250]
mov dword [ecx + 0x1458], eax
mov edx, dword [ebp - 0x1250]
xor eax, eax
cmp dword [edx + 0x1458], 0xffffffff
setne al
mov dword [ebp - 0x124c], eax
cmp dword [ebp - 0x124c], 0
jne 0x46101c
mov dword [ebp - 4], 0x15b1002
push 0x15b
push 0x478180
call fcn.00455990
add esp, 8
push eax
push str.m_hWorkthread_INVALID_HANDLE_VALUE
push 0x15b1002
call fcn.00401020
add esp, 0xc
mov ecx, dword [ebp - 0x1250]
mov edx, dword [ecx + 0x145c]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebp - 4]
pop edi
pop esi
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043ad38
mov esp, ebp
pop ebp
ret
Function at 0x1000a3d0
Capabilities:
Read file on windows

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0xc
mov edi, dword [esp + 0x28]
mov ebx, dword [esp + 0x24]
cmp ebx, 1
mov eax, edi
sbb eax, 0
jl 0x1000a4cd
mov esi, ecx
mov ebp, dword [esp + 0x20]
cmp dword [ecx + 0x38], 0
mov dword [esp], ecx
jne 0x1000a473
mov eax, dword [esi + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x1000a4d6
mov ecx, dword [esi + 0x2c]
mov edi, dword [ecx]
test edi, edi
je 0x1000a4e5
cmp edi, ebx
cmovae edi, ebx
push edi
push eax
push ebp
call fcn.100294c0
add esp, 0xc
add ebp, edi
mov ecx, esi
mov esi, ebx
sub esi, edi
mov eax, dword [ecx + 0x2c]
sub dword [eax], edi
mov eax, dword [ecx + 0x1c]
add dword [eax], edi
jmp 0x1000a4e9
mov dword [esp + 4], edx
push esi
push eax
push ebp
call fcn.100294c0
add esp, 0xc
add ebp, esi
sub ebx, esi
sbb edi, dword [esp + 4]
mov ecx, dword [esp]
mov eax, dword [ecx + 0x2c]
sub dword [eax], esi
mov eax, dword [ecx + 0x1c]
add dword [eax], esi
mov esi, ecx
mov eax, ebx
neg eax
mov eax, 0
sbb eax, edi
jge 0x1000a4b8
mov eax, dword [esi + 0x1c]
mov eax, dword [eax]
test eax, eax
je 0x1000a4a0
mov ecx, dword [esi + 0x2c]
mov ecx, dword [ecx]
test ecx, ecx
jle 0x1000a4a0
cmp ebx, ecx
mov edx, edi
sbb edx, 0
mov edx, edi
mov esi, ebx
jb 0x1000a440
xor edx, edx
mov esi, ecx
jmp 0x1000a440
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x1c]
cmp eax, 0xffffffff
je 0x1000a4b8
mov byte [ebp], al
inc ebp
add ebx, 0xffffffff
adc edi, 0xffffffff
jmp 0x1000a466
mov eax, dword [esp + 0x24]
sub eax, ebx
mov ebx, eax
mov eax, dword [esp + 0x28]
sbb eax, edi
mov edi, eax
jmp 0x1000a57c
xor ebx, ebx
xor edi, edi
jmp 0x1000a57c
mov ecx, esi
mov esi, ebx
cmp dword [ecx + 0x4c], 0
jne 0x1000a4f7
jmp 0x1000a577
mov ecx, esi
mov esi, ebx
mov edi, dword [esp + 0x28]
cmp dword [ecx + 0x4c], 0
je 0x1000a577
mov eax, dword [ecx + 0xc]
add ecx, 0x3c
cmp dword [eax], ecx
jne 0x1000a530
mov ecx, dword [esp]
mov edx, dword [ecx + 0x50]
mov dword [esp + 8], edx
mov edx, dword [ecx + 0x54]
mov dword [esp + 4], edx
mov edx, dword [esp + 8]
mov dword [eax], edx
mov eax, dword [ecx + 0x1c]
mov dword [eax], edx
sub dword [esp + 4], edx
mov eax, dword [ecx + 0x2c]
mov ecx, dword [esp + 4]
mov dword [eax], ecx
nop word [eax + eax]
cmp esi, 0x1000
jb 0x1000a55b
mov eax, dword [esp]
push dword [eax + 0x4c]
push 0xfff
push 1
push ebp
call fcn.100307f6
add esp, 0x10
add ebp, eax
sub esi, eax
cmp eax, 0xfff
je 0x1000a530
jmp 0x1000a577
test esi, esi
je 0x1000a575
mov eax, dword [esp]
push dword [eax + 0x4c]
push esi
push 1
push ebp
call fcn.100307f6
add esp, 0x10
sub esi, eax
jmp 0x1000a577
xor esi, esi
sub ebx, esi
sbb edi, 0
mov eax, ebx
mov edx, edi
add esp, 0xc
pop esi
pop edi
pop ebx
pop ebp
ret 0xc
Function at 0x10013302
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
xor edx, edx
push esi
mov esi, dword [ebp + 0xc]
cmp dword [ebp + 0x10], edx
jbe 0x10013325
movzx eax, byte [esi + edx]
xor eax, ecx
imul ecx, eax, 0x1000193
inc edx
cmp edx, dword [ebp + 0x10]
jb 0x10013313
mov eax, ecx
pop esi
pop ebp
ret

Function at 0x10026917
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
call fcn.1002c21b
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 0x10026956
sub eax, 1
je 0x10026951
sub eax, 1
je 0x1002694d
xor eax, eax
leave
ret
push 3
jmp 0x10026958
xor eax, eax
inc eax
leave
ret
push 2
pop eax
leave
ret

Function at 0x10036120
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1003614d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1003614d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x1003865f
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1004ef1c
push 0x1004ef14
push str.FlsAlloc
push 0x1e
call fcn.10038bbb
mov esi, eax
add esp, 0x10
test esi, esi
je 0x10038693
push dword [ebp + 8]
mov ecx, esi
call dword [section..00cfg]
call esi
jmp 0x10038699
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x100386dd
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1004ef2c
push 0x1004ef24
push str.FlsGetValue
push 0x20
call fcn.10038bbb
mov esi, eax
add esp, 0x10
test esi, esi
je 0x10038714
push dword [ebp + 8]
mov ecx, esi
call dword [section..00cfg]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x1003cae9
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.1000e8f0
mov eax, dword [0x100597c0]
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.1003b918
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x1003cb2b
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x1003cc87
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.1000e7d0
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 + 0x1005b970]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.1003c890
mov ecx, dword [esi*4 + 0x1005b970]
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 0x1003cc80
cmp eax, dword [edi + ecx + 0x24]
jne 0x1003cc80
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 0x1003cc80
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1003c890
add esp, 0x14
test edx, edx
jl 0x1003cc80
jg 0x1003cbf6
test eax, eax
jb 0x1003cc80
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x1003cc80
jl 0x1003cc10
cmp dword [ebp - 0x1008], eax
ja 0x1003cc80
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x1003cc2e
test ebx, ebx
je 0x1003cc67
cmp ecx, edi
jae 0x1003cc67
mov al, byte [ecx]
cmp al, 0xd
jne 0x1003cc48
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1003cc54
cmp byte [ecx + 1], 0xa
jne 0x1003cc54
inc ecx
jmp 0x1003cc54
movzx eax, al
movsx eax, byte [eax + 0x1005a190]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x1003cc2e
cmp edx, ebx
jne 0x1003cc2e
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x1003cc85
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.1000e7b7
leave
ret
Function at 0x1003d5b5
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 0x1003d652
push ebx
push esi
call fcn.1003d6a3
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.100364db
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1003d5ff
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003d651
push edi
push eax
call fcn.10036411
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1003d61f
call fcn.100363d7
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003d650
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.100364db
add esp, 0x20
test eax, eax
jne 0x1003d63e
push edi
call fcn.100363d7
jmp 0x1003d646
push ebx
call fcn.100363d7
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 0x1003d655
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x1003d666
pop esi
ret
push ebx
push edi
push esi
call fcn.1003d6a3
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.10036411
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x1003d68e
push ebx
push esi
push edi
call fcn.100294c0
add esp, 0xc
push 0
call fcn.100363d7
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x1003d6da
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.1003d6e5
Function at 0x1003e8a4
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.1003e8af
Function at 0x1003f31b
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 + 0x1005b970]
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 0x1003f35b
cmp byte [ebx], 0xa
jne 0x1003f35b
or byte [eax + edi + 0x28], 4
jmp 0x1003f360
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1003f45e
mov al, byte [edx]
cmp al, 0x1a
je 0x1003f440
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x1003f38f
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x1003f3b4
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x1003f3be
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 0x1003f371
jmp 0x1003f45e
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 0x1003f43b
cmp dword [ebp - 0xc], 0
je 0x1003f43b
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x1005b970]
test byte [eax + edi + 0x28], 0x48
je 0x1003f415
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x1003f400
mov byte [esi], dl
jmp 0x1003f411
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x1005b970]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x1003f45e
cmp byte [ebp - 1], 0xa
jne 0x1003f424
cmp esi, ebx
jne 0x1003f424
mov byte [esi], 0xa
jmp 0x1003f45d
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1003c832
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1003f45e
mov byte [esi], 0xd
jmp 0x1003f45d
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x1005b970]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003f45a
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1003f45e
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1003f467
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 + 0x1005b970]
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 0x1003f4aa
cmp word [esi], dx
jne 0x1003f4aa
or byte [edi + eax + 0x28], 4
jmp 0x1003f4af
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 0x1003f5e8
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 0x1003f5c8
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x1003f4f1
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x1003f527
cmp eax, edx
jae 0x1003f533
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 0x1003f4c9
jmp 0x1003f5e8
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 0x1003f5c4
cmp dword [ebp - 0x14], 0
je 0x1003f5c4
mov eax, dword [ebx*4 + 0x1005b970]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x1003f59c
mov cx, word [ebp - 4]
pop eax
cmp cx, ax
je 0x1003f5e2
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x1005b970]
push 0xa
mov byte [edi + eax + 0x2a], cl
mov eax, dword [ebx*4 + 0x1005b970]
shr cx, 8
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x1005b970]
pop ecx
mov byte [edi + eax + 0x2c], cl
jmp 0x1003f5e5
pop ebx
cmp word [ebp - 4], bx
jne 0x1003f5ad
cmp esi, dword [ebp + 0xc]
jne 0x1003f5ad
mov word [esi], bx
jmp 0x1003f5e5
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.1003c832
add esp, 0x10
cmp word [ebp - 4], bx
je 0x1003f5e8
push 0xd
jmp 0x1003f5e1
mov ecx, dword [ebx*4 + 0x1005b970]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003f5df
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1003f5e8
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 0x10047954
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.10047af7
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10047acc
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10047acc
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x10047a7b
jg 0x100479ad
test eax, eax
je 0x10047a71
push 1
push 0x1000
call fcn.100394e9
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x100479d3
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x10047a68
push 0x8000
push ebx
call fcn.1004784e
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 0x100479ff
jg 0x100479fa
cmp ecx, 0x1000
jb 0x100479ff
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.1003ddee
add esp, 0x10
cmp eax, 0xffffffff
je 0x10047a44
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 0x100479fa
jl 0x10047a2b
test ecx, ecx
jne 0x100479ec
push dword [ebp - 0xc]
push ebx
call fcn.1004784e
push esi
call fcn.100363d7
add esp, 0xc
xor edi, edi
jmp 0x10047add
cmp byte [edi + 0x24], 0
je 0x10047a5b
cmp dword [edi + 0x20], 5
jne 0x10047a5b
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x10047a66
mov edi, dword [edi + 0x18]
jmp 0x10047a68
xor edi, edi
push esi
call fcn.100363d7
pop ecx
jmp 0x10047add
test ecx, ecx
jg 0x10047a3d
jl 0x10047a7b
test eax, eax
jae 0x10047a3d
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1003c832
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x10047a9e
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x10047a3d
jmp 0x10047ad5
push ebx
call fcn.10043b38
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x10047a3d
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 0x10047add
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x10047ada
mov edi, dword [edi + 0x18]
jmp 0x10047add
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.1003c832
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret