joyce8/EMBER2024-capa huggingface dataset:
Function at 0x497430
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d059d
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
push edi
mov eax, dword [0x4ff080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [0x511ccc]
cmp dword [edi], 0
je 0x497502
mov dword [ebp - 0x10], 0
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x14], 0
test eax, eax
je 0x497492
push eax
call esi
mov dword [ebp - 0x10], 0
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x14]
push eax
push 1
push 1
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_GetSecurityInfo]
test eax, eax
jne 0x4974f1
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x4974f1
cmp dword [ebp - 0x10], 0
je 0x4974f1
push dword [edi]
push eax
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
je 0x4974f1
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x4974dc
push eax
call esi
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x497502
push eax
call esi
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4

Function at 0x4976b0
Capabilities:
Enumerate pe sections
Parse pe header
Resolve function by parsing pe exports

Disassembly:
push esi
mov esi, ecx
push edi
xor edi, edi
cmp dword [esi + 0x1c], edi
ja 0x4976cb
cmp dword [esi + 0x18], 0x40
ja 0x4976cb
mov edi, 2
mov eax, edi
pop edi
pop esi
ret
push ebx
mov ebx, dword [esi + 0x14]
push 0x40
push ebx
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
jne 0x4977c5
mov eax, 0x5a4d
cmp word [ebx], ax
jne 0x4977c5
mov byte [esi + 0x20], 1
mov ecx, dword [ebx + 0x3c]
lea eax, [ecx + 0xf8]
cmp dword [esi + 0x1c], edi
jb 0x4977c0
ja 0x49770f
cmp dword [esi + 0x18], eax
jbe 0x4977c0
mov eax, dword [esi + 0x14]
add eax, ecx
push 0xf8
push eax
mov dword [esi + 0x10], eax
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
jne 0x4977c5
mov ecx, dword [esi + 0x10]
cmp dword [ecx], 0x4550
jne 0x4977c5
mov eax, 0x2000
test word [ecx + 0x16], ax
jne 0x497749
mov byte [esi + 0x2c], 1
movzx eax, word [ecx + 0x18]
mov edx, 0x10b
cmp ax, dx
jne 0x497763
mov dword [esi + 0x28], 1
lea eax, [ecx + 0x78]
jmp 0x49777a
mov edx, 0x20b
cmp ax, dx
jne 0x49777d
mov dword [esi + 0x28], 2
lea eax, [ecx + 0x88]
mov dword [esi + 0xc], eax
cmp dword [esi + 0xc], edi
je 0x4977c5
movzx eax, word [ecx + 6]
mov dword [esi + 0x24], eax
test eax, eax
je 0x4977c5
movzx edx, word [ecx + 0x14]
lea eax, [eax + eax*4]
shl eax, 3
sub eax, dword [esi + 0x14]
add eax, 0x18
add eax, edx
add eax, ecx
cmp dword [esi + 0x1c], edi
jb 0x4977c0
ja 0x4977ad
cmp dword [esi + 0x18], eax
jbe 0x4977c0
lea eax, [ecx + 0x18]
mov edi, 1
add eax, edx
mov dword [esi + 8], eax
mov eax, edi
pop ebx
pop edi
pop esi
ret
mov edi, 2
pop ebx
mov eax, edi
pop edi
pop esi
ret
Function at 0x4979c0
Capabilities:
Enumerate pe sections

Disassembly:
mov ecx, dword [ecx + 0x10]
xor edx, edx
push ebx
push esi
push edi
movzx eax, word [ecx + 0x14]
movzx ebx, word [ecx + 6]
add eax, 0x18
mov edi, dword [ecx + 0x28]
add eax, ecx
test ebx, ebx
je 0x4979f8
nop dword [eax]
mov esi, dword [eax + 0xc]
cmp edi, esi
jb 0x4979f0
mov ecx, dword [eax + 8]
add ecx, esi
cmp edi, ecx
jb 0x4979fe
inc edx
add eax, 0x28
cmp edx, ebx
jb 0x4979e0
pop edi
pop esi
xor eax, eax
pop ebx
ret
mov eax, dword [eax + 0x14]
sub eax, esi
add eax, edi
pop edi
pop esi
pop ebx
ret

Function at 0x497a10
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, ecx
push ebx
push esi
mov dword [ebp - 4], eax
mov edx, dword [eax + 0x10]
push edi
xor edi, edi
movzx eax, word [edx + 0x14]
lea esi, [edx + 0x18]
movzx ebx, word [edx + 6]
add esi, eax
test ebx, ebx
je 0x497a4d
mov edx, dword [ebp + 8]
mov ecx, dword [esi + 0xc]
cmp edx, ecx
jb 0x497a45
mov eax, dword [esi + 8]
add eax, ecx
cmp edx, eax
jb 0x497a58
inc edi
add esi, 0x28
cmp edi, ebx
jb 0x497a35
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x14]
mov esi, dword [ebp - 4]
pop edi
add eax, dword [esi + 0x14]
sub eax, ecx
pop esi
add eax, edx
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x497f90
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d0895
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x4ff080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x10], ebx
mov edx, dword [ebp + 0x10]
cmp edx, 0x64
ja 0x498145
mov esi, dword [ebp + 0x20]
mov eax, dword [esi]
cmp eax, 0x4e20
jg 0x498145
mov edi, dword [ebp + 8]
inc eax
mov dword [esi], eax
mov ecx, dword [edi + 4]
mov eax, dword [edi]
test ecx, ecx
jns 0x49801a
push esi
push dword [ebp + 0x1c]
and ecx, 0x7fffffff
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push eax
mov eax, dword [ebp + 0xc]
add ecx, eax
push edx
push eax
push ecx
mov ecx, ebx
call fcn.00498160
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov esi, dword [ebp + 0xc]
lea ecx, [ebp + 0x10]
push esi
push eax
call fcn.00497d10
add esp, 8
mov dword [ebp - 4], 0
mov ebx, 0xffffffff
mov eax, dword [edi + 4]
add eax, esi
mov dword [ebp + 0xc], eax
je 0x49810b
mov ecx, dword [ebp - 0x10]
xor esi, esi
mov edi, dword [eax]
mov ecx, dword [ecx + 0x10]
movzx eax, word [ecx + 0x14]
lea edx, [ecx + 0x18]
movzx ebx, word [ecx + 6]
add edx, eax
test ebx, ebx
je 0x49807c
nop
mov ecx, dword [edx + 0xc]
cmp edi, ecx
jb 0x498074
mov eax, dword [edx + 8]
add eax, ecx
cmp edi, eax
jb 0x4980f9
inc esi
add edx, 0x28
cmp esi, ebx
jb 0x498060
xor esi, esi
mov edx, dword [ebp + 0x14]
lea ecx, [ebp + 0x20]
push 0x4eb37c
call fcn.00469bf0
mov byte [ebp - 4], 1
lea ecx, [ebp + 0x10]
push ecx
mov edx, eax
lea ecx, [ebp + 0x14]
call fcn.00469d80
add esp, 8
mov byte [ebp - 4], 2
push dword [ebp + 0x1c]
mov ecx, dword [ebp + 0xc]
push dword [ecx + 4]
push esi
push eax
call dword [ebp + 0x18]
mov byte [ebp + 0xf], al
mov byte [ebp - 4], 1
or ebx, 0xffffffff
mov edx, dword [ebp + 0x14]
mov eax, ebx
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4980d9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
mov eax, ebx
mov edx, dword [ebp + 0x20]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49810f
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x49810f
mov eax, dword [ebp - 0x10]
sub ecx, dword [edx + 0x14]
mov esi, dword [eax + 0x14]
sub esi, ecx
add esi, edi
jmp 0x49807e
mov byte [ebp + 0xf], 1
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0x10]
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x49812e
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov al, byte [ebp + 0xf]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x1c
Function at 0x4985f0
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d0a2b
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x4ff080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [esi], 0xffffffff
mov dword [ebp - 4], 0
mov dword [esi + 4], 0
mov byte [ebp - 4], 1
lea ebx, [esi + 8]
mov dword [ebp - 0x14], ebx
mov dword [ebx], 0
mov byte [ebp - 4], 3
mov eax, dword [ebp + 8]
cmp eax, 0xffffffff
je 0x49869d
push 0
push 0
push 0
push 2
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov edi, eax
mov eax, dword [esi + 4]
cmp edi, eax
je 0x498672
test eax, eax
je 0x498672
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 4], edi
test edi, edi
je 0x49869d
push 0
push 0
push 0
push 4
push edi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov ecx, dword [ebx]
mov edi, eax
cmp edi, ecx
je 0x49869b
test ecx, ecx
je 0x49869b
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [ebx], edi
mov dword [ebp - 4], 0xffffffff
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x4a3e50
Capabilities:
Hash data with md5

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d297f
mov eax, dword fs:[0]
push eax
sub esp, 0x68
mov eax, dword [0x4ff080]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x70], edi
push dword [ebp + 8]
mov dword [ebp - 0x74], edi
lea ecx, [ebp - 0x68]
mov dword [ebp - 0x6c], 0
xorps xmm0, xmm0
movq qword [ebp - 0x58], xmm0
mov dword [ebp - 0x68], 0x67452301
mov dword [ebp - 0x64], 0xefcdab89
mov dword [ebp - 0x60], 0x98badcfe
mov dword [ebp - 0x5c], 0x10325476
call fcn.004a3fd0
add esp, 4
lea eax, [ebp - 0x70]
lea ecx, [ebp - 0x68]
push eax
call fcn.004a3980
mov dword [ebp - 4], 2
mov ecx, edi
mov eax, dword [eax]
push dword [eax + 4]
mov edx, dword [eax]
call fcn.00495860
mov eax, 2
mov dword [ebp - 0x6c], 2
mov dword [ebp - 0x6c], eax
add esp, 4
and eax, 0xfffffffd
mov dword [ebp - 0x6c], eax
mov dword [ebp - 4], 1
or eax, 1
mov dword [ebp - 0x6c], eax
mov byte [ebp - 4], 0
mov esi, dword [ebp - 0x70]
add dword [esi + 8], 0xffffffff
jne 0x4a3f3d
cmp dword [esi + 4], 0
je 0x4a3f29
push 0
push dword [esi]
call fcn.004b3cee
add esp, 8
mov dword [esi], eax
mov dword [esi + 4], 0
push 0xc
push dword [ebp - 0x70]
call fcn.004aa25b
add esp, 8
mov dword [ebp - 0x70], 0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a9b96
mov esp, ebp
pop ebp
ret

Function at 0x4a4800
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, ecx
cmp esi, 8
jb 0x4a48c9
mov eax, dword [edi]
push ebx
mov ebx, esi
shr ebx, 3
nop dword [eax + eax]
movzx ecx, byte [edx]
sub esi, 8
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 1]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 2]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 3]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 4]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 5]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 6]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
movzx ecx, byte [edx + 7]
add edx, 8
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x4e81b0]
sub ebx, 1
jne 0x4a4820
pop ebx
mov dword [edi], eax
test esi, esi
je 0x4a48ef
nop dword [eax]
mov ecx, dword [edi]
lea edx, [edx + 1]
movzx eax, byte [edx - 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x4e81b0]
mov dword [edi], ecx
sub esi, 1
jne 0x4a48d0
pop edi
pop esi
pop ebp
ret
Function at 0x4a8740
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d30a4
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebx
push esi
push edi
mov eax, dword [0x4ff080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, ecx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 4], 0
lea esi, [ebx + 4]
push esi
push 0
push 0
push 0
push 0
push str.FopdMonPort
call sub.FLTLIB.DLL_FilterConnectCommunicationPort
test eax, eax
jne 0x4a8878
push 4
push eax
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CreateIoCompletionPort]
mov dword [ebx + 8], eax
test eax, eax
je 0x4a8878
xor al, al
mov byte [ebp - 0x11], al
xor edi, edi
mov dword [ebp - 0x1c], edi
cmp edi, 2
jae 0x4a885b
push 0x20
call fcn.004a9ec5
add esp, 4
mov dword [ebp - 0x24], eax
mov byte [ebp - 4], 1
test eax, eax
je 0x4a87df
mov ecx, eax
call fcn.004a8120
mov esi, eax
jmp 0x4a87e1
xor esi, esi
mov byte [ebp - 4], 0
mov dword [ebp - 0x18], esi
mov eax, dword [ebp + 8]
mov dword [esi + 0x1c], eax
mov ecx, dword [esi]
lea eax, [ecx + 0x220]
push eax
push 0x220
push ecx
push dword [ebx + 4]
call sub.FLTLIB.DLL_FilterGetMessage
mov ecx, esi
cmp eax, 0x800703e5
jne 0x4a884e
mov eax, dword [ebx + 4]
mov dword [esi + 0xc], eax
mov eax, dword [ebx + 8]
mov dword [esi + 8], eax
call fcn.004a9050
push 0
push 0
push esi
push 0x4a8420
push 0
push 0
call fcn.004b3c5d
add esp, 0x18
mov dword [esi + 4], eax
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebx + 0xc]
call fcn.004a9020
mov byte [ebp - 0x11], 1
inc edi
jmp 0x4a87b3
push 1
call fcn.004a83a0
inc edi
jmp 0x4a87b3
mov al, byte [ebp - 0x11]
test al, al
je 0x4a8878
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [ebp - 4], 0xffffffff
jmp 0x4a8891
mov ecx, ebx
call fcn.004a85e0
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x4a94d0
Capabilities:
Get common file path
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d32be
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x4ff080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], 0
call fcn.00456f30
mov ecx, eax
test ecx, ecx
je 0x4a9613
mov eax, dword [ecx]
call dword [eax + 0xc]
mov ecx, dword [ebp + 8]
add eax, 0x10
mov dword [ecx], eax
mov dword [ebp - 4], 0
push 0x800
mov dword [ebp - 0x14], 1
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0x400
mov byte [ebp - 0x18], 1
call fcn.004b3921
mov edi, eax
add esp, 4
test edi, edi
je 0x4a956c
push 0x800
push 0
push edi
call fcn.004abe70
add esp, 0xc
mov dword [ebp - 0x20], edi
mov dword [ebp - 4], 2
push 0x400
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
xor eax, eax
push eax
push eax
push eax
push eax
mov word [edi + 6], ax
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
mov bl, byte [ebp - 0x10]
mov ch, byte [ebp - 0xf]
mov dl, byte [ebp - 0xe]
mov cl, byte [ebp - 0xd]
movzx eax, ch
movzx esi, bl
add esi, eax
mov byte [ebp - 0xd], bl
mov ebx, dword [ebp + 8]
movzx eax, dl
add esi, eax
mov byte [ebp - 0x10], cl
movzx eax, cl
add esi, eax
mov byte [ebp - 0xf], dl
push esi
push 0x4ea87c
push ebx
mov byte [ebp - 0xe], ch
call fcn.0047ba70
push dword [ebp - 0x10]
push 0x4ea87c
push dword [ebp + 0xc]
call fcn.0047ba70
mov byte [ebp - 4], 0
push edi
call fcn.004b38cc
add esp, 0x1c
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.00456c80
int3

Function at 0x4aaf5d
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4aaf9c
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4aaf9c
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4aaf9c
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x4aaf9c
cmp dword [ecx + 0x74], 0xe
jbe 0x4aaf9c
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x4b8e2e
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004aa970
mov eax, dword [0x4ff080]
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.004bace7
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x4b8e70
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x4b8fcc
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.004aa6a0
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 + 0x511938]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.004bd9f9
mov ecx, dword [esi*4 + 0x511938]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x4b8fc5
cmp eax, dword [ecx + edi + 0x24]
jne 0x4b8fc5
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4b8fc5
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004bd9f9
add esp, 0x14
test edx, edx
jl 0x4b8fc5
jg 0x4b8f3b
test eax, eax
jb 0x4b8fc5
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x4b8fc5
jl 0x4b8f55
cmp dword [ebp - 0x1008], eax
ja 0x4b8fc5
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x4b8f73
test ebx, ebx
je 0x4b8fac
cmp ecx, edi
jae 0x4b8fac
mov al, byte [ecx]
cmp al, 0xd
jne 0x4b8f8d
lea eax, [edi - 1]
cmp ecx, eax
jae 0x4b8f99
cmp byte [ecx + 1], 0xa
jne 0x4b8f99
inc ecx
jmp 0x4b8f99
movzx eax, al
movsx eax, byte [eax + 0x4ff380]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x4b8f73
cmp edx, ebx
jne 0x4b8f73
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x4b8fca
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004a9b96
leave
ret

Function at 0x4b9844
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4e43cc
push 0x4e43c4
push str.FlsAlloc
push 0x1f
call fcn.004b96c3
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4b9878
push dword [ebp + 8]
mov ecx, esi
call dword [0x4d5410]
call esi
jmp 0x4b987e
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x4b98c2
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4e43dc
push 0x4e43d4
push str.FlsGetValue
push 0x21
call fcn.004b96c3
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4b98f9
push dword [ebp + 8]
mov ecx, esi
call dword [0x4d5410]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x4b9901
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4e43e4
push 0x4e43dc
push str.FlsSetValue
push 0x22
call fcn.004b96c3
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4b993b
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x4d5410]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x4bcaf6
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]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.004bca72
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x4bcc65
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x4bcc65
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x4bcc1a
jg 0x4bcb52
test eax, eax
je 0x4bcc10
push 1
push 0x1000
call fcn.004b94f9
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x4bcb75
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x4bcc07
push 0x8000
push ebx
call fcn.004b7d34
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x4bcb9e
jg 0x4bcb99
cmp ecx, 0x1000
jb 0x4bcb9e
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.004bc360
add esp, 0x10
cmp eax, 0xffffffff
je 0x4bcbe3
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 0x4bcb99
jl 0x4bcbca
test ecx, ecx
jne 0x4bcb8b
push dword [ebp - 0xc]
push ebx
call fcn.004b7d34
push esi
call fcn.004b9556
add esp, 0xc
xor ebx, ebx
jmp 0x4bcc73
cmp byte [edi + 0x24], 0
je 0x4bcbfa
cmp dword [edi + 0x20], 5
jne 0x4bcbfa
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x4bcc05
mov ebx, dword [edi + 0x18]
jmp 0x4bcc07
xor ebx, ebx
push esi
call fcn.004b9556
pop ecx
jmp 0x4bcc73
test ecx, ecx
jg 0x4bcbdc
jl 0x4bcc1a
test eax, eax
jae 0x4bcbdc
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004bda17
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x4bcc3a
cmp byte [edi + 0x1c], 0
je 0x4bcbdc
jmp 0x4bcc6b
push ebx
call fcn.004bca08
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x4bcbdc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x4bcc73
cmp byte [edi + 0x1c], 0
je 0x4bcc70
mov ebx, dword [edi + 0x18]
jmp 0x4bcc73
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.004bda17
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4bce91
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
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 + 0x511938]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x4bced1
cmp byte [ebx], 0xa
jne 0x4bced1
or byte [edi + eax + 0x28], 4
jmp 0x4bced6
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x4bcfd5
mov dl, byte [eax]
cmp dl, 0x1a
je 0x4bcfb8
inc eax
cmp dl, 0xd
je 0x4bcf02
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x4bcf28
cmp eax, ecx
jae 0x4bcf36
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x4bceea
jmp 0x4bcfd5
push 0
lea eax, [ebp - 0x10]
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 0x4bcfb3
cmp dword [ebp - 0x10], 0
je 0x4bcfb3
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x511938]
test byte [eax + edi + 0x28], 0x48
je 0x4bcf8d
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x4bcf78
mov byte [esi], dl
jmp 0x4bcf89
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x511938]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x4bcfd5
cmp byte [ebp - 1], 0xa
jne 0x4bcf9c
cmp esi, ebx
jne 0x4bcf9c
mov byte [esi], 0xa
jmp 0x4bcfd4
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.004bda17
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4bcfd5
mov byte [esi], 0xd
jmp 0x4bcfd4
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x511938]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x4bcfd2
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x4bcfd5
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret