joyce8/EMBER2024-capa huggingface dataset:
Function at 0x48e955
Capabilities:
Encode data using xor

Disassembly:
push esi
and eax, 0x8468d01
mov dword [esi], 0xf908
push eax
call dword [0x1b4968c]
mov ecx, esi
pop esi
jmp 0x5ab0c6
popal
loope 0x5ab0fc
adc al, 0x54
and dl, dh
cmc
leave
cmc
push ecx
bound esp, qword [ecx - 0x4fda54e3]
or byte [esi + 0x456e6589], ah
xchg byte [ecx - 0x37], bl
paddq mm7, mm6
jmp 0x7ee36650
mov dh, 0x31
push 0xe8e98011
pop ebp
in eax, 0xc1
mov al, 0x58
js 0x5ab15e
stosd dword es:[edi], eax
int3
push ebp
enter 0xffffffffffffd288, 0xffffffffffffff99
test byte [ecx - 0x420a4ddc], al
rcl dword [ecx + 0x4e4e61a2], cl
cmc
mov ebp, 0x61a291d3
dec esi
dec esi
xor ah, byte [eax + 0x7c]
les esi, [ebp + 0x74f74f88]
sbb cl, byte [eax - 0x57]
test dword [ebp + esi*4 + 0x66f2924b], ebp
inc edi
test eax, 0x4bb5ac85
xchg edx, eax
inc di
xchg ebx, eax
stc
scasd eax, dword es:[edi]
ja 0x5ab142
push esi
add edx, edi
int 0x9a
out dx, eax
jmp 0x5ab14b
Function at 0x550607
Capabilities:
Encode data using xor

Disassembly:
jg 0x550669
ror byte [ebp + 9], 1
push 0x432e4cf8
xlatb
jg 0x55066e
and ecx, ebp
in eax, dx
lahf
adc ebp, dword [esi + 0x34ce2e5c]
mov bh, 0xc4
lds eax, [ebx + 0x731bba13]
loop 0x55062f
call 0xe1f1d47a
xchg dword [ecx - 0x5cb89d49], esp
mov ebp, 0x8141e51a
sub dl, byte [ecx - 0x547c3206]
mov bh, 0x62
inc edi
mov dword [0x41e51abd], eax
sub dword [edx], 0x83cdfa91
stosd dword es:[edi], eax
scasb al, byte es:[edi]
lodsb al, byte [esi]
pop ss
sal bh, 0xb2
invalid
lodsd eax, dword [esi]
test esi, ebx
push 0x1ebe1bce
cdq
les esp, [eax]
sbb edi, dword [esi + 0x20c4991e]
add dword [0x440531ac], eax
push 0xafb15edd
scasd eax, dword es:[edi]
and dword [ebp - 0x66abc4c4], ebp
mov esi, 0xfbc63576
push ecx
fdivr qword [0xa1cf1e86]
push ds
dec esi
mov ecx, 0x92b3a6d1
mov byte [eax + 0x34dd035a], dl
xor eax, 0x564f358a
push esi
lcall 0xf030, 0xc20f56a2
wait
pushaw
fldcw word [ebx + 0x54]
pop ds
jo 0x55067e
in eax, 0x34
sub al, 0x5f
inc eax
sub eax, 0x1bf73789
mov esi, 0x193290cf
arpl word [edx + ebx*4 + 0x77], si
sbb dword [edi - 0x2ca547db], ebp
add eax, 0x2916029b
das
fiadd dword [edx]
movsd dword es:[edi], dword [esi]
xchg ebx, ebp
invalid

Function at 0x628d15
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x6323e8
cmp edx, dword [eax]
je 0x628d37
add eax, 8
inc ecx
cmp eax, 0x632478
jl 0x628d28
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x6323e8]
jne 0x628e65
mov eax, dword [0x63ad88]
cmp eax, 1
je 0x628e3f
test eax, eax
jne 0x628d68
cmp dword [0x632310], 1
je 0x628e3f
cmp edx, 0xfc
je 0x628e65
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x628d9f
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00629700
add byte [ecx + 0x59], bl
lea eax, [ebp + 8]
lea esi, [esi + 0x6323ec]
push 0
push eax
push dword [esi]
call fcn.00629b90
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
Function at 0x430006
Capabilities:
Encode data using xor

Disassembly:
mov eax, section..text
nop
nop
mov ebx, 0x408f6c
nop
mov ecx, 0x286c420f
test eax, eax
nop
nop
nop
nop
nop
nop
nop
je 0x43004e
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
inc eax
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
jne 0x430024
mov eax, section..data
nop
nop
mov ebx, 0x42e3d0
nop
mov ecx, 0x37e5222a
nop
nop
nop
nop
test eax, eax
je 0x430084
nop
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
add eax, 4
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
jne 0x43006c
nop
nop
nop
nop
nop
nop
nop
popal
jmp 0x401219
Function at 0x402a20
Capabilities:
Create new key via cryptacquirecontext
Get file size
Hash data via wincrypt
Initialize hashing via wincrypt
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x42c080]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ecx + 0x14], 0xf
push ebx
push esi
push edi
mov ebx, edx
jbe 0x402a3d
mov ecx, dword [ecx]
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x402bd7
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push eax
mov dword [ebp - 0x3c], eax
call fcn.0040811f
add esp, 4
mov esi, eax
lea eax, [ebp - 0x34]
mov dword [ebp - 0x40], esi
push 0
push eax
push dword [ebp - 0x3c]
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x402ab3
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call fcn.004080dc
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004080ce
mov esp, ebp
pop ebp
ret
push 0xf0000000
push 0x18
push 0
push 0
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x30], 0x20
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x402bb3
lea eax, [ebp - 0x28]
push eax
push 0
push 0
push 0x800c
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x402bb3
push 0
push dword [ebp - 0x3c]
push esi
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x402bb3
push 0
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x24]
push eax
push 2
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
je 0x402bb3
mov esi, dword [ebp - 0x30]
xor edx, edx
mov byte [ebp - 0x35], 1
test esi, esi
je 0x402b51
lea eax, [ebp - 0x24]
sub ebx, eax
nop dword [eax + eax]
lea ecx, [ebp - 0x24]
add ecx, edx
mov al, byte [ecx]
cmp al, byte [ebx + ecx]
jne 0x402ba3
inc edx
cmp edx, esi
jb 0x402b40
mov ecx, 0x42d0e8
mov edx, str.Checksum_Passed.
call fcn.004060b0
push eax
call fcn.00406350
add esp, 4
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push 0
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
push dword [ebp - 0x40]
call fcn.004080dc
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, byte [ebp - 0x35]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004080ce
mov esp, ebp
pop ebp
ret
mov byte [ebp - 0x35], 0
mov ecx, 0x42d290
mov edx, str.Checksum_error._Program_will_be_closed.
jmp 0x402b5b
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push 0
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
push esi
call fcn.004080dc
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
xor al, al
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004080ce
mov esp, ebp
pop ebp
ret
Function at 0x403810
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [esp + 0xc], edi
test eax, eax
jg 0x403842
jl 0x403835
test ecx, ecx
jne 0x403842
xor eax, eax
xor edx, edx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x40391f
mov dword [esp + 0x10], eax
lea eax, [ebx + 0x2c]
mov dword [esp + 0xc], ecx
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x1c]
mov eax, dword [eax]
mov dword [esp + 0x18], eax
test eax, eax
je 0x403872
mov eax, dword [esp + 0x14]
mov eax, dword [eax]
mov eax, dword [eax]
jmp 0x403874
xor eax, eax
cdq
mov dword [esp + 0x1c], edx
mov esi, eax
test edx, edx
jl 0x4038c8
jg 0x403885
test esi, esi
je 0x4038c8
mov eax, dword [esp + 0x10]
cmp eax, edx
jg 0x403899
jl 0x403893
cmp ecx, esi
jae 0x403899
mov esi, ecx
mov dword [esp + 0x1c], eax
push esi
push dword [esp + 0x1c]
push edi
call fcn.00409630
mov eax, dword [esp + 0x20]
add esp, 0xc
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 0x10]
sub ecx, esi
mov eax, dword [eax]
sbb edx, dword [esp + 0x1c]
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
mov eax, dword [esp + 0x14]
jmp 0x4038ec
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x1c]
mov edx, dword [esp + 0x10]
cmp eax, 0xffffffff
je 0x403908
mov ecx, dword [esp + 0xc]
mov esi, 1
add ecx, 0xffffffff
mov byte [edi], al
lea eax, [ebx + 0x2c]
adc edx, 0xffffffff
add edi, esi
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], ecx
test edx, edx
jg 0x403857
jl 0x403908
test ecx, ecx
jne 0x403857
mov eax, dword [ebp + 0xc]
sub eax, dword [esp + 0xc]
mov ecx, dword [ebp + 0x10]
sbb ecx, edx
mov edx, ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
lea esi, [ebx + 0x2c]
mov edi, ecx
mov edx, dword [eax]
test edx, edx
je 0x403963
mov eax, dword [esi]
mov eax, dword [eax]
test eax, eax
je 0x403963
mov edi, dword [esp + 0xc]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push edx
push edi
call fcn.00409630
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [esp + 0x18], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
lea esi, [ebx + 0x2c]
cmp dword [ebx + 0x4c], 0
je 0x4039cc
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x403989
mov eax, dword [ebx + 0xc]
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi]
mov dword [eax], edx
mov esi, dword [esp + 0xc]
cmp edi, 0xfff
jbe 0x4039b7
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call fcn.0040e3fc
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x4039cc
cmp edi, eax
ja 0x403995
test edi, edi
je 0x4039cc
push dword [ebx + 0x4c]
push edi
push 1
push esi
call fcn.0040e3fc
add esp, 0x10
sub edi, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x404250
Capabilities:
Access peb ldr_data
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4218bc
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x42c080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], 0
mov dword [ebx], 0x42926c
mov dword [ebx + 0x78], 0
mov dword [ebx + 0x7c], 0
mov dword [ebx + 0x80], 0
mov dword [ebx + 0x84], 0
mov dword [ebx + 0x88], 0
mov dword [ebx + 0x8c], 0
mov dword [ebx + 0x90], 0
mov dword [ebx + 0x94], 0
mov dword [ebx + 0x98], 0
mov dword [ebx + 0x9c], 0
mov dword [ebx + 0xa0], 0
mov dword [ebx + 0x70], vtable.std::basic_ios_char__struct_std::char_traits_char__.0
mov dword [ebx + 0xa8], 0
mov dword [ebx + 0xac], 0
mov byte [ebx + 0xb0], 0
push 0
push 0
lea esi, [ebx + 0x10]
mov dword [ebp - 4], 0
push esi
mov dword [ebp - 0x18], 1
call fcn.00405750
mov dword [ebp - 4], 1
lea edi, [esi + 0x28]
mov eax, dword [ebx]
mov dword [ebp - 0x14], esi
push 8
mov eax, dword [eax + 4]
mov dword [ebx + eax], vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebx]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x70]
mov dword [ecx + ebx - 4], eax
lea eax, [esi + 4]
mov dword [esi], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
mov dword [ebp - 0x14], eax
mov dword [eax], 0
mov dword [esi + 8], 0
mov dword [esi + 0xc], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov dword [esi + 0x18], 0
mov dword [esi + 0x1c], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x24], 0
mov dword [edi], 0
mov dword [esi + 0x2c], 0
mov dword [esi + 0x30], 0
call fcn.004080e1
mov esi, eax
xorps xmm0, xmm0
movq qword [esi], xmm0
push 1
mov byte [ebp - 4], 2
call fcn.0040771e
mov ecx, ebx
mov dword [esi + 4], eax
add esp, 8
mov dword [ecx + 0x44], esi
lea ecx, [ecx + 0x10]
call fcn.00405a10
mov eax, ebx
lea esi, [eax + 0x14]
mov dword [eax + 0x10], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
mov dword [eax + 0x1c], esi
lea edx, [eax + 0x18]
mov esi, ebx
mov byte [eax + 0x58], 0
lea ecx, [eax + 0x24]
mov byte [eax + 0x4d], 0
mov dword [eax + 0x20], edx
mov dword [eax + 0x2c], ecx
lea eax, [esi + 0x28]
mov dword [esi + 0x30], eax
lea ebx, [esi + 0x34]
mov dword [esi + 0x3c], ebx
mov dword [esi + 0x40], edi
mov esi, dword [ebp - 0x14]
mov dword [edx], 0
mov dword [eax], 0
mov dword [edi], 0
mov dword [esi], 0
mov dword [ecx], 0
mov dword [ebx], 0
mov ebx, dword [ebp - 0x10]
mov eax, ebx
mov dword [ebx + 0x5c], 0
mov ecx, dword [0x42df54]
mov edx, dword [0x42df58]
mov dword [ebx + 0x50], ecx
mov dword [ebx + 0x54], edx
mov dword [ebx + 0x48], 0
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 0x405a70
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x421ae0
mov eax, dword fs:[0]
push eax
push esi
push edi
mov eax, dword [0x42c080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
push 8
mov dword [edi], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
mov dword [edi + 4], 0
mov dword [edi + 8], 0
mov dword [edi + 0xc], 0
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 0
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 0x20], 0
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
mov dword [edi + 0x2c], 0
mov dword [edi + 0x30], 0
call fcn.004080e1
mov esi, eax
xorps xmm0, xmm0
movq qword [esi], xmm0
push 1
mov dword [ebp - 4], 0
call fcn.0040771e
add esp, 8
mov dword [esi + 4], eax
mov ecx, edi
mov dword [edi + 0x34], esi
call fcn.00405a10
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x40728b
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
push 2
lea eax, [ebp - 4]
push eax
push 0x20000001
push str._x_sys_default_locale
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
xor ecx, ecx
test eax, eax
jne 0x4072b2
mov eax, ecx
mov dword [ebp - 4], eax
jmp 0x4072b5
mov eax, dword [ebp - 4]
push esi
mov esi, dword [ebp + 0xc]
push ecx
push ecx
push esi
push eax
push dword [ebp + 8]
push ecx
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push eax
push dword [esi]
call fcn.00407267
pop esi
leave
ret 8

Function at 0x408e16
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x408e55
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x408e55
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x408e55
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x408e55
cmp dword [ecx + 0x74], 0xe
jbe 0x408e55
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x4156c9
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x425440
push 0x425438
push str.FlsAlloc
push 0x1f
call fcn.00415534
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4156fd
push dword [ebp + 8]
mov ecx, esi
call dword [0x422184]
call esi
jmp 0x415703
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x415747
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x425450
push 0x425448
push str.FlsGetValue
push 0x21
call fcn.00415534
mov esi, eax
add esp, 0x10
test esi, esi
je 0x41577e
push dword [ebp + 8]
mov ecx, esi
call dword [0x422184]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x415786
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x425458
push 0x425450
push str.FlsSetValue
push 0x22
call fcn.00415534
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4157c0
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x422184]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x415fec
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.00408f80
mov eax, dword [0x42c080]
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.00412a1e
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x41602e
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x41618a
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.00421110
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 + 0x42db38]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.004170e2
mov ecx, dword [esi*4 + 0x42db38]
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 0x416183
cmp eax, dword [ecx + edi + 0x24]
jne 0x416183
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 0x416183
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004170e2
add esp, 0x14
test edx, edx
jl 0x416183
jg 0x4160f9
test eax, eax
jb 0x416183
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x416183
jl 0x416113
cmp dword [ebp - 0x1008], eax
ja 0x416183
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x416131
test ebx, ebx
je 0x41616a
cmp ecx, edi
jae 0x41616a
mov al, byte [ecx]
cmp al, 0xd
jne 0x41614b
lea eax, [edi - 1]
cmp ecx, eax
jae 0x416157
cmp byte [ecx + 1], 0xa
jne 0x416157
inc ecx
jmp 0x416157
movzx eax, al
movsx eax, byte [eax + 0x42c338]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x416131
cmp edx, ebx
jne 0x416131
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x416188
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004080ce
leave
ret
Function at 0x41657a
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 + 0x42db38]
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 0x4165ba
cmp byte [ebx], 0xa
jne 0x4165ba
or byte [edi + eax + 0x28], 4
jmp 0x4165bf
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 0x4166be
mov dl, byte [eax]
cmp dl, 0x1a
je 0x4166a1
inc eax
cmp dl, 0xd
je 0x4165eb
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x416611
cmp eax, ecx
jae 0x41661f
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 0x4165d3
jmp 0x4166be
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 0x41669c
cmp dword [ebp - 0x10], 0
je 0x41669c
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x42db38]
test byte [eax + edi + 0x28], 0x48
je 0x416676
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x416661
mov byte [esi], dl
jmp 0x416672
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x42db38]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x4166be
cmp byte [ebp - 1], 0xa
jne 0x416685
cmp esi, ebx
jne 0x416685
mov byte [esi], 0xa
jmp 0x4166bd
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00417100
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4166be
mov byte [esi], 0xd
jmp 0x4166bd
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x42db38]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x4166bb
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x4166be
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x4166c7
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x42db38]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41670d
cmp word [ebx], dx
jne 0x41670d
or byte [eax + edi + 0x28], 4
jmp 0x416712
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x416875
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x416855
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x416753
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x416789
cmp eax, edx
jae 0x416797
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
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 - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x41672e
jmp 0x416875
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x416850
cmp dword [ebp - 0x18], 0
je 0x416850
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x42db38]
test byte [eax + edi + 0x28], 0x48
je 0x416826
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x4167ea
mov word [esi], cx
jmp 0x416821
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x42db38]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x42db38]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x42db38]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x416875
pop eax
cmp word [ebp - 4], ax
jne 0x416836
cmp esi, ebx
jne 0x416836
mov word [esi], ax
jmp 0x416872
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00417100
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x416875
push 0xd
pop eax
jmp 0x416831
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x42db38]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x41686f
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x416875
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret