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

Disassembly:
sub esp, 0x14
push ebx
mov ebx, dword [esp + 0x1c]
push 0x1000
push 0
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esp + 8], edx
test edx, edx
je 0x45dcef
mov ax, word [esp + 0x1c]
push ebp
push esi
push edi
mov edi, edx
mov dword [esp + 0x1c], 0x1000
mov dword [esp + 0x18], 0x7ff
mov ecx, dword [esp + 0x30]
cmp ecx, 0xffffffff
je 0x45db89
test ecx, ecx
je 0x45dc4c
dec ecx
mov dword [esp + 0x30], ecx
cmp dword [ebx + 4], 0
lea ebp, [ebx + 4]
je 0x45dba5
push 2
lea eax, [esp + 0x2c]
push eax
push ebx
call fcn.0045d850
mov dword [esp + 0x10], eax
jmp 0x45dbbf
push 0
lea eax, [esp + 0x14]
push eax
push 2
lea eax, [esp + 0x34]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x10]
cmp eax, 2
mov ax, word [esp + 0x28]
jne 0x45dc4f
test ax, ax
je 0x45dbdd
mov word [edi], ax
add edi, 2
mov ax, word [esp + 0x28]
mov edx, dword [esp + 0x14]
mov esi, edi
mov ecx, dword [esp + 0x18]
sub esi, edx
sar esi, 1
cmp esi, ecx
jle 0x45dc24
mov eax, dword [esp + 0x1c]
add ecx, 0x800
add eax, 0x1000
mov dword [esp + 0x18], ecx
push eax
push edx
push 8
push dword [0x1812534]
mov dword [esp + 0x2c], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edx, eax
mov ax, word [esp + 0x28]
mov dword [esp + 0x14], edx
lea edi, [edx + esi*2]
test ax, ax
je 0x45dc4f
cmp dword [esp + 0x2c], 0
jne 0x45db73
cmp ax, 0xd
je 0x45dc56
cmp ax, 0xa
jne 0x45db73
sub edi, 2
jmp 0x45dcce
lea ebp, [ebx + 4]
cmp dword [esp + 0x2c], 0
jne 0x45dcce
cmp ax, 0xa
jne 0x45dc61
sub edi, 2
jmp 0x45dcce
cmp ax, 0xd
jne 0x45dcce
sub edi, 2
cmp dword [ebp], 0
je 0x45dc83
push 2
lea eax, [esp + 0x2c]
push eax
push ebx
call fcn.0045d850
mov dword [esp + 0x10], eax
jmp 0x45dc99
push 0
lea eax, [esp + 0x14]
push eax
push 2
lea eax, [esp + 0x34]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp word [esp + 0x28], 0xa
je 0x45dcce
cmp dword [ebp], 0
je 0x45dcad
add dword [ebx + 0xc], 2
jmp 0x45dcce
push 1
lea eax, [esp + 0x24]
mov dword [esp + 0x20], 0xfffffffe
push eax
push 0xfffffffffffffffe
push dword [ebx]
mov dword [esp + 0x30], 0
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x34]
mov ecx, edi
sub ecx, dword [esp + 0x14]
sar ecx, 1
mov dword [eax], ecx
xor eax, eax
mov word [edi], ax
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x10
xor eax, eax
pop ebx
add esp, 0x14
ret 0x10
Function at 0x45dd00
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x14
push 0x1000
push 0
push dword [0x1812534]
mov dword [esp + 0x10], 0x1000
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esp + 0xc], edx
test edx, edx
je 0x45de50
mov eax, dword [esp + 0x1c]
mov cl, byte [esp + 3]
push ebx
push ebp
mov ebp, dword [esp + 0x20]
push esi
push edi
mov edi, dword [esp + 0x30]
mov esi, edx
cmp edi, 0xffffffff
je 0x45dd4c
test edi, edi
je 0x45ddbd
dec edi
push esi
push ebp
call fcn.0045ded0
mov dword [esp + 0x20], eax
test eax, eax
jne 0x45dd5f
xor cl, cl
jmp 0x45dd61
mov cl, byte [esi]
mov edx, dword [esp + 0x1c]
add esi, eax
mov eax, dword [esp + 0x14]
mov ebx, esi
sub ebx, edx
mov byte [esp + 0x13], cl
add eax, 0xfffffffb
cmp ebx, eax
jle 0x45dda4
mov eax, dword [esp + 0x14]
add eax, 0x1000
push eax
push edx
push 8
push dword [0x1812534]
mov dword [esp + 0x24], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov cl, byte [esp + 0x13]
mov edx, eax
mov dword [esp + 0x1c], edx
lea esi, [ebx + edx]
mov eax, dword [esp + 0x2c]
test cl, cl
je 0x45ddbd
test eax, eax
jne 0x45dd42
cmp cl, 0xd
je 0x45ddc1
cmp cl, 0xa
jne 0x45dd42
dec esi
jmp 0x45de33
test eax, eax
jne 0x45de33
cmp cl, 0xa
jne 0x45ddc9
dec esi
jmp 0x45de33
cmp cl, 0xd
jne 0x45de33
dec esi
cmp dword [ebp + 4], 0
je 0x45dde8
push 1
lea eax, [esp + 0x17]
push eax
push ebp
call fcn.0045d850
mov dword [esp + 0x20], eax
jmp 0x45ddff
push 0
lea eax, [esp + 0x24]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebp]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp byte [esp + 0x13], 0xa
je 0x45de33
cmp dword [ebp + 4], 0
je 0x45de11
inc dword [ebp + 0xc]
jmp 0x45de33
push 1
lea eax, [esp + 0x1c]
mov dword [esp + 0x18], 0xffffffff
push eax
push 0xffffffffffffffff
push dword [ebp]
mov dword [esp + 0x28], 0xffffffff
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x34]
mov ecx, esi
sub ecx, dword [esp + 0x1c]
pop edi
mov dword [eax], ecx
mov eax, dword [esp + 0x18]
mov byte [esi], 0
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x10
xor eax, eax
add esp, 0x14
ret 0x10
Function at 0x45ded0
Capabilities:
Read file on windows

Disassembly:
push ecx
push edi
mov edi, dword [esp + 0xc]
mov dword [esp + 4], 0
cmp dword [edi + 4], 0
je 0x45def7
push 1
lea eax, [esp + 0x10]
push eax
push edi
call fcn.0045d850
mov dword [esp + 4], eax
jmp 0x45df11
push 0
lea eax, [esp + 8]
push eax
push 1
lea eax, [esp + 0x18]
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 4]
cmp eax, 1
jne 0x45dfc4
mov cl, byte [esp + 0xc]
test cl, cl
js 0x45df36
mov eax, dword [esp + 0x10]
pop edi
mov byte [eax], cl
mov byte [eax + 1], 0
mov eax, 1
pop ecx
ret 8
mov al, cl
and al, 0xe0
push esi
cmp al, 0xc0
jne 0x45df46
mov esi, 2
jmp 0x45df62
mov al, cl
and al, 0xf0
cmp al, 0xe0
jne 0x45df55
mov esi, 3
jmp 0x45df62
mov al, cl
and al, 0xf8
cmp al, 0xf0
jne 0x45dfb0
mov esi, 4
mov eax, dword [esp + 0x14]
push ebx
lea ebx, [esi - 1]
mov byte [eax], cl
inc eax
cmp dword [edi + 4], 0
je 0x45df8b
push ebx
push eax
push edi
call fcn.0045d850
xor ecx, ecx
cmp eax, ebx
pop ebx
cmovne esi, ecx
mov eax, esi
pop esi
pop edi
pop ecx
ret 8
push 0
lea ecx, [esp + 0x10]
push ecx
push ebx
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0xc]
xor ecx, ecx
cmp eax, ebx
pop ebx
cmovne esi, ecx
mov eax, esi
pop esi
pop edi
pop ecx
ret 8
mov eax, dword [esp + 0x14]
pop esi
pop edi
mov word [eax], 0x3f
mov eax, 1
pop ecx
ret 8
xor eax, eax
pop edi
pop ecx
ret 8

Function at 0x460a4d
Capabilities:
Set thread local storage value

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
xor ebx, ebx
push edi
mov edi, ebx
test esi, esi
je 0x460aaa
push esi
call dword [esi + 0x58]
mov ecx, dword [esi + 0x80]
mov edi, eax
mov dword [esi + 0x94], ecx
mov ecx, dword [esi + 0x84]
mov dword [esi + 0x98], ecx
test edi, edi
jne 0x460aaa
mov eax, dword [esi + 0x70]
test eax, eax
je 0x460a89
push ebx
push esi
call eax
push esi
push ebx
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapFree]
push ebx
push dword [0x1815468]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov dword [0x181546c], ebx
mov eax, edi
pop edi
pop esi
pop ebx
ret 4

Function at 0x460b0e
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x1815468]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [eax + 0x90]
add ecx, dword [esp + 8]
push ecx
mov ecx, dword [eax + 0x8c]
add ecx, dword [esp + 8]
push ecx
push eax
call dword [eax + 0x54]
ret 8

Function at 0x460cbe
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x1815468]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push dword [esp + 0xc]
mov ecx, dword [eax + 0x90]
add ecx, dword [esp + 0xc]
push ecx
mov ecx, dword [eax + 0x8c]
add ecx, dword [esp + 0xc]
push ecx
push eax
call dword [eax + 0x50]
ret 0xc
Function at 0x460ceb
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push esi
push dword [0x1815468]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
mov eax, dword [ebp + 0x18]
cmp eax, dword [esi + 0xac]
je 0x460d13
push eax
push esi
mov dword [esi + 0xac], eax
call dword [esi + 0x40]
push dword [ebp + 0x14]
mov eax, dword [esi + 0x90]
push dword [ebp + 0x10]
add eax, dword [ebp + 0xc]
push eax
mov eax, dword [esi + 0x8c]
add eax, dword [ebp + 8]
push eax
push esi
call dword [esi + 4]
pop esi
pop ebp
ret 0x14

Function at 0x460f0f
Capabilities:
Set thread local storage value

Disassembly:
push esi
push 0x188
push 8
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
push esi
push dword [0x1815468]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push dword [esp + 8]
mov dword [0x181546c], esi
and dword [esi + 0xa8], 0
or dword [esi + 0xac], 0xffffffff
or dword [esi + 0xb0], 0xffffffff
push esi
mov dword [esi + 0xa4], 0xffffff
mov dword [esi + 0x74], 2
mov dword [esi + 0x78], 0x3f
call fcn.00463eec
mov dword [esi + 0x58], 0x461ef2
mov eax, esi
mov dword [esi + 0x5c], 0x461f3e
mov dword [esi + 0x10], fcn.00461a2a
mov dword [esi + 0x30], 0x461805
mov dword [esi + 0x64], 0x461fd3
mov dword [esi + 0x60], 0x461f87
mov dword [esi + 0x34], 0x4612d0
mov dword [esi + 0x24], 0x4612a7
mov dword [esi + 0x28], 0x46127c
mov dword [esi + 0x2c], 0x4611d0
mov dword [esi + 0x44], 0x461cc2
mov dword [esi + 0x68], 0x460fd0
mov dword [esi + 0x6c], 0x4621d5
pop esi
ret 4
Function at 0x46ab6d
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x50
push ebp
xor ebp, ebp
cmp dword [0x1815094], ebp
je 0x46ad53
push ebx
mov ebx, dword [esp + 0x60]
push edi
test ebx, ebx
je 0x46ab8d
mov edi, ebx
jmp 0x46ab9f
push 0
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov edi, eax
test edi, edi
je 0x46ad51
lea eax, [esp + 0x18]
push eax
push 0x18
push dword [esp + 0x68]
call dword [sym.imp.GDI32.dll_GetObjectW]
test eax, eax
je 0x46ad46
mov ebp, dword [esp + 0x1c]
lea eax, [esp + 0x30]
push esi
mov esi, dword [esp + 0x24]
push 0x2c
push 0
push eax
mov dword [esp + 0x20], ebp
call fcn.00428100
add esp, 0xc
mov dword [esp + 0x34], 0x28
xor eax, eax
mov dword [esp + 0x38], ebp
inc eax
mov dword [esp + 0x3c], esi
mov word [esp + 0x40], ax
xor ecx, ecx
push 0x20
pop eax
push ecx
push ecx
mov word [esp + 0x4a], ax
lea eax, [esp + 0x18]
push eax
push ecx
lea eax, [esp + 0x44]
mov dword [esp + 0x54], ecx
push eax
push edi
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov ebp, eax
mov dword [esp + 0x18], ebp
test ebp, ebp
je 0x46ad45
push 0
lea eax, [esp + 0x38]
push eax
push dword [esp + 0x18]
push esi
push 0
push dword [esp + 0x78]
push edi
call dword [sym.imp.GDI32.dll_GetDIBits]
imul esi, dword [esp + 0x14]
test esi, esi
jle 0x46ad45
cmp dword [esp + 0x6c], 0
je 0x46acf2
mov ebp, dword [esp + 0x10]
push 0xa
pop ebx
movzx ecx, byte [ebp + 1]
xor edx, edx
movzx eax, byte [ebp + 2]
lea eax, [eax + ecx*2]
movzx ecx, byte [ebp]
imul eax, eax, 3
add eax, ecx
div ebx
mov cl, al
cmp cl, 0x40
jae 0x46ac86
movzx eax, cl
sub eax, 0x40
imul eax, eax, 7
cdq
idiv ebx
lea ecx, [eax + 0x40]
jmp 0x46ac9c
cmp cl, 0xc0
jbe 0x46ac9c
movzx eax, cl
sub eax, 0xc0
imul eax, eax, 7
cdq
idiv ebx
lea ecx, [eax - 0x40]
movzx eax, byte [ebp + 3]
movd xmm1, eax
cvtdq2ps xmm1, xmm1
movzx eax, cl
movd xmm0, eax
divss xmm1, dword [0x536190]
cvtdq2ps xmm0, xmm0
mulss xmm1, xmm0
cvttss2si ecx, xmm1
mov byte [ebp], cl
mov eax, dword [esp + 0x10]
mov byte [eax + 1], cl
mov ecx, dword [esp + 0x10]
mov al, byte [ecx]
mov byte [ecx + 2], al
mov ebp, dword [esp + 0x10]
add ebp, 4
mov dword [esp + 0x10], ebp
sub esi, 1
jne 0x46ac56
mov ebx, dword [esp + 0x68]
mov ebp, dword [esp + 0x18]
jmp 0x46ad45
mov edx, dword [esp + 0x10]
mov al, byte [edx + 3]
cmp al, 0xff
jae 0x46ad39
movzx ecx, al
movzx eax, byte [edx]
imul ecx, eax
shr ecx, 8
mov byte [edx], cl
mov edx, dword [esp + 0x10]
movzx eax, byte [edx + 1]
movzx ecx, byte [edx + 3]
imul ecx, eax
shr ecx, 8
mov byte [edx + 1], cl
mov edx, dword [esp + 0x10]
movzx ecx, byte [edx + 3]
movzx eax, byte [edx + 2]
imul ecx, eax
shr ecx, 8
mov byte [edx + 2], cl
mov edx, dword [esp + 0x10]
add edx, 4
mov dword [esp + 0x10], edx
sub esi, 1
jne 0x46acf6
pop esi
test ebx, ebx
jne 0x46ad51
push edi
call dword [sym.imp.GDI32.dll_DeleteDC]
pop edi
pop ebx
mov eax, ebp
pop ebp
add esp, 0x50
ret 0xc
Function at 0x46c87e
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 0xc
push ebx
push esi
mov esi, dword [esp + 0x3c]
xor ebx, ebx
cmp esi, 1
je 0x46c8ae
cmp esi, 2
je 0x46c8ae
cmp esi, 4
je 0x46c8ae
cmp esi, 8
je 0x46c8ae
cmp esi, 0x18
je 0x46c8ae
cmp esi, 0x20
je 0x46c8ae
xor eax, eax
jmp 0x46ca7b
mov ecx, dword [0x18150b8]
push ebp
push edi
xor edi, edi
mov dword [esp + 0x10], edi
test ecx, ecx
jle 0x46ca77
mov edx, dword [esp + 0x28]
mov eax, dword [edi*4 + 0x18154f8]
cmp dword [eax], edx
je 0x46c8e1
inc edi
mov dword [esp + 0x10], edi
cmp edi, ecx
jl 0x46c8c8
jmp 0x46ca77
cmp dword [esp + 0x38], 0x20
jne 0x46ca4e
mov eax, dword [eax + 8]
test eax, eax
je 0x46c921
cmp esi, 0x20
je 0x46c8fd
cmp esi, 0xffffffff
jne 0x46c921
push esi
push dword [esp + 0x44]
push dword [esp + 0x44]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
call eax
jmp 0x46ca75
mov eax, dword [esp + 0x2c]
inc eax
imul ebp, eax, 3
and ebp, 0xfffffffc
mov eax, ebp
mov dword [esp + 0x14], ebp
imul eax, dword [esp + 0x30]
push eax
push 0
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [esp + 0x18], eax
test eax, eax
je 0x46ca77
mov ebx, dword [esp + 0x30]
test ebx, ebx
jle 0x46ca19
mov edx, dword [esp + 0x24]
mov ecx, eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x38], ecx
mov dword [esp + 0x30], edx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ecx
mov esi, edx
test eax, eax
jle 0x46c9f8
mov ebp, ecx
mov edi, eax
mov ecx, 0xff
movzx eax, byte [esi + 2]
sub eax, ecx
movzx ecx, byte [esi + 3]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp + 2], al
movzx eax, byte [esi + 1]
sub eax, ecx
movzx ecx, byte [esi + 3]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp + 1], al
movzx eax, byte [esi]
lea esi, [esi + 4]
sub eax, ecx
movzx ecx, byte [esi - 1]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp], al
lea ebp, [ebp + 3]
sub edi, 1
jne 0x46c987
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x30]
add edx, dword [esp + 0x34]
add ecx, ebp
sub dword [esp + 0x24], 1
mov dword [esp + 0x30], edx
mov dword [esp + 0x38], ecx
jne 0x46c974
mov esi, dword [esp + 0x44]
mov edi, dword [esp + 0x10]
mov eax, dword [edi*4 + 0x18154f8]
push esi
push dword [esp + 0x44]
mov esi, dword [esp + 0x20]
push dword [esp + 0x44]
push ebp
push ebx
push dword [esp + 0x40]
push esi
push dword [esp + 0x3c]
call dword [eax + 4]
push esi
push 0
push dword [0x1812534]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x46ca77
cmp dword [esp + 0x38], 0x18
jne 0x46ca77
push esi
push dword [esp + 0x44]
push dword [esp + 0x44]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
call dword [eax + 4]
mov ebx, eax
pop edi
mov eax, ebx
pop ebp
pop esi
pop ebx
add esp, 0xc
ret 0x28
Function at 0x4701d5
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push edi
push dword [0x18150c8]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
jne 0x470236
push esi
push dword [0x18150c4]
push 8
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
push edi
push dword [0x18150c8]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov esi, dword [0x18150c0]
jmp 0x470226
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x470224
mov eax, dword [esi + 8]
add eax, edi
push eax
call ecx
pop ecx
mov esi, dword [esi]
test esi, esi
jne 0x470214
push edi
push 0x470173
call fcn.004e21f7
pop esi
mov eax, dword [esp + 8]
add eax, edi
pop edi
ret 4

Function at 0x470240
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x14]
mov ecx, edi
and ecx, 3
je 0x470256
push 4
pop eax
sub eax, ecx
add edi, eax
mov esi, dword [0x18150c4]
mov ebx, dword [sym.imp.KERNEL32.dll_TlsSetValue]
test esi, esi
jne 0x47028f
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push edi
push 8
push dword [0x1812534]
mov dword [0x18150c8], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push dword [0x18150c8]
call ebx
mov esi, dword [0x18150c4]
lea eax, [edi + esi]
push eax
push dword [0x18150c8]
mov dword [0x18150c4], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
push 8
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ebp, eax
push ebp
push dword [0x18150c8]
call ebx
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
test edi, edi
jne 0x4702ce
test ebx, ebx
je 0x4702ef
push 0x14
push 0x18150c0
call fcn.00470b46
pop ecx
pop ecx
mov dword [eax], esi
mov dword [eax + 4], edi
mov dword [eax + 8], ebx
test edi, edi
je 0x4702ef
lea ecx, [esi + ebp]
push ecx
call edi
pop ecx
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
ret 0xc

Function at 0x470c30
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push ebp
push esi
push edi
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebx, dword [esp + 0x18]
mov edi, eax
mov ebp, dword [esp + 0x14]
mov esi, dword [edi + 8]
mov ecx, dword [ebp]
sub esi, ebx
lea eax, [esi + 0xa]
push eax
test ecx, ecx
jne 0x470c69
push ecx
push dword [0x1815588]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
jmp 0x470c78
push ecx
push 0
push dword [0x1815588]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, eax
shr esi, 1
mov dword [ebp], ecx
mov eax, dword [edi]
push esi
add eax, ebx
push eax
push ecx
call fcn.004711a0
mov dword [edi + 8], ebx
pop edi
pop esi
pop ebp
pop ebx
ret 8

Function at 0x470ca0
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
add dword [eax + 8], 2
ret
Function at 0x471060
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push ebp
push esi
push edi
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebx, dword [esp + 0x18]
mov esi, eax
cmp ebx, 0xffffffff
jne 0x47107e
mov ebx, dword [esi + 8]
mov eax, dword [esp + 0x14]
mov edx, dword [esi + 4]
mov ecx, dword [esi + 8]
lea ebp, [eax + eax]
add ecx, ebp
lea eax, [edx - 4]
cmp ecx, eax
jl 0x4710a2
lea eax, [ecx + 0x4000]
mov dword [esi + 4], eax
add eax, 0xa
jmp 0x4710bd
cmp edx, 0x100000
jle 0x4710d0
cmp ecx, 0x100000
jge 0x4710b7
mov ecx, 0x100000
mov dword [esi + 4], ecx
lea eax, [ecx + 0xa]
push eax
push dword [esi]
push 0
push dword [0x1815588]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov dword [esi], eax
lea eax, [ebx + ebp]
mov dword [esi + 8], eax
mov eax, dword [esi]
pop edi
pop esi
pop ebp
add eax, ebx
pop ebx
ret 8

Function at 0x471110
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [esp + 4]
neg ecx
add ecx, ecx
add dword [eax + 8], ecx
ret 4

Function at 0x471130
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, eax
mov eax, dword [esp + 4]
mov edx, dword [ecx]
cmp eax, edx
jb 0x471157
mov ecx, dword [ecx + 8]
add ecx, edx
cmp eax, ecx
ja 0x471157
sub eax, edx
inc eax
ret 4
xor eax, eax
ret 4

Function at 0x471160
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [eax]
mov eax, dword [esp + 4]
dec eax
add eax, ecx
ret 4

Function at 0x471180
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov eax, dword [eax]
add eax, dword [esp + 4]
ret 4

Function at 0x471350
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x180e778]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [esp + 4]
mov dword [eax + 8], ecx
mov eax, dword [eax]
add eax, ecx
ret 4
Function at 0x4e21f7
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
cmp dword [0x181512c], 0
push ebx
push esi
mov esi, 0x1815134
jne 0x4e2223
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push esi
mov dword [0x181514c], eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov dword [0x181512c], 1
push dword [0x181514c]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebx, eax
test ebx, ebx
jne 0x4e22c0
push 0x14
push 8
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
test ebx, ebx
je 0x4e22ea
push esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x1815130]
test eax, eax
je 0x4e2265
mov dword [eax], ebx
push edi
push esi
mov dword [ebx + 4], eax
mov dword [0x1815130], ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov esi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea edi, [ebx + 0x10]
push 0
push 0
push 0x100000
push edi
call esi
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call esi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
push 8
push 0xffffffffffffffff
push ebx
push 0x4e22ef
push dword [edi]
lea eax, [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_RegisterWaitForSingleObject]
push ebx
push dword [0x181514c]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
pop edi
push 0xc
push 0
push dword [0x1812534]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
je 0x4e22ea
mov ecx, dword [esp + 0xc]
mov dword [eax + 4], ecx
mov ecx, dword [esp + 0x10]
mov dword [eax + 8], ecx
mov ecx, dword [ebx + 8]
mov dword [eax], ecx
mov dword [ebx + 8], eax
pop esi
pop ebx
ret 8

Function at 0x4e2960
Capabilities:
Parse pe header

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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004e2820
mov eax, dword [0x180dddc]
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.00424cb8
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x504d01
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x504e5d
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.004e2a70
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 + 0x1813bf0]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.00427989
mov ecx, dword [esi*4 + 0x1813bf0]
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 0x504e56
cmp eax, dword [ecx + edi + 0x24]
jne 0x504e56
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 0x504e56
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00427989
add esp, 0x14
test edx, edx
jl 0x504e56
jg 0x504dcc
test eax, eax
jb 0x504e56
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x504e56
jl 0x504de6
cmp dword [ebp - 0x1008], eax
ja 0x504e56
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x504e04
test ebx, ebx
je 0x504e3d
cmp ecx, edi
jae 0x504e3d
mov al, byte [ecx]
cmp al, 0xd
jne 0x504e1e
lea eax, [edi - 1]
cmp ecx, eax
jae 0x504e2a
cmp byte [ecx + 1], 0xa
jne 0x504e2a
inc ecx
jmp 0x504e2a
movzx eax, al
movsx eax, byte [eax + 0x180e530]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x504e04
cmp edx, ebx
jne 0x504e04
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x504e5b
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.0041298f
leave
ret