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

Disassembly:
mov eax, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
push edi
mov eax, dword [eax*4 + 0x1002941]
xor edi, edi
mov ecx, dword [eax]
movsx ecx, byte [ecx]
test ecx, ecx
jle 0x1003d8d
mov edx, dword [eax]
mov dl, byte [edx + edi + 1]
xor dl, 0x42
mov byte [esi], dl
inc esi
inc edi
cmp edi, ecx
jl 0x1003d7c
mov eax, dword [esp + 0x14]
and byte [esi], 0
pop edi
pop esi
mov dword [eax], ecx
ret

Function at 0x1004270
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1001398
push 0x10045f4
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffa8
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
xor edx, edx
mov dl, ah
mov dword [0x100a518], edx
mov ecx, eax
and ecx, 0xff
mov dword [0x100a514], ecx
shl ecx, 8
add ecx, edx
mov dword [0x100a510], ecx
shr eax, 0x10
mov dword [0x100a50c], eax
call fcn.010055f0
test eax, eax
jne 0x10042da
push 0x1c
call fcn.01004440
add esp, 4
mov dword [ebp - 4], 0
call fcn.010053f0
call fcn.010053e0
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x100aab4], eax
call fcn.01004da0
mov dword [0x100a4f4], eax
test eax, eax
je 0x100430d
mov eax, dword [0x100aab4]
test eax, eax
jne 0x1004317
push 0xffffffffffffffff
call fcn.01004700
add esp, 4
call fcn.01004af0
call fcn.01004a00
call fcn.010046d0
mov esi, dword [0x100aab4]
mov dword [ebp - 0x64], esi
cmp byte [esi], 0x22
jne 0x10043f6
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
cmp al, 0x22
je 0x100435e
test al, al
je 0x100435e
and eax, 0xff
push eax
call fcn.010049a0
add esp, 4
test eax, eax
je 0x1004338
inc esi
mov dword [ebp - 0x64], esi
jmp 0x1004338
cmp byte [esi], 0x22
jne 0x1004367
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
test al, al
je 0x1004377
cmp al, 0x20
ja 0x1004377
inc esi
mov dword [ebp - 0x64], esi
jmp 0x1004367
mov dword [ebp - 0x30], 0
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x30], 1
je 0x1004398
mov eax, dword [ebp - 0x2c]
and eax, 0xffff
jmp 0x100439d
mov eax, 0xa
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
mov dword [ebp - 0x60], eax
push eax
call fcn.01004700
jmp 0x10043db
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0x20
jbe 0x1004367
inc esi
mov dword [ebp - 0x64], esi
jmp 0x10043f6

Function at 0x1004440
Capabilities:
Terminate process

Disassembly:
cmp dword [0x100a4fc], 1
jne 0x100444e
call fcn.01005630
mov eax, dword [esp + 4]
push eax
call fcn.01005670
add esp, 4
push 0xff
call dword [sym.imp.KERNEL32.dll_ExitProcess]
Function at 0x1004740
Capabilities:
Terminate process

Disassembly:
mov eax, dword [0x100a548]
push ebx
push ebp
mov ebp, dword [esp + 0xc]
cmp eax, 1
push esi
jne 0x100475f
push ebp
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov eax, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
test eax, eax
mov dword [0x100a544], 1
mov byte [0x100a540], bl
jne 0x10047b9
mov ecx, dword [0x100aaac]
test ecx, ecx
je 0x10047a7
mov esi, dword [0x100aaa8]
sub esi, 4
cmp esi, ecx
jb 0x10047a7
mov eax, dword [esi]
test eax, eax
je 0x10047a0
call eax
mov ecx, dword [0x100aaac]
sub esi, 4
cmp esi, ecx
jae 0x1004792
push 0x1008014
push 0x1008010
call fcn.010047f0
add esp, 8
push 0x100801c
push 0x1008018
call fcn.010047f0
add esp, 8
test ebx, ebx
jne 0x10047e0
push ebp
mov dword [0x100a548], 1
call dword [sym.imp.KERNEL32.dll_ExitProcess]
pop esi
pop ebp
pop ebx
ret

Function at 0x1004da0
Capabilities:
Query environment variable

Disassembly:
mov eax, dword [0x100a658]
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
push esi
xor esi, esi
xor ebx, ebx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
test eax, eax
jne 0x1004de2
call edi
mov esi, eax
test esi, esi
je 0x1004dcc
mov eax, 1
jmp 0x1004ddd
call ebp
mov ebx, eax
test ebx, ebx
je 0x1004eef
mov eax, 2
mov dword [0x100a658], eax
cmp eax, 1
jne 0x1004e82
test esi, esi
jne 0x1004dfb
call edi
mov esi, eax
test esi, esi
je 0x1004eef
cmp word [esi], 0
mov eax, esi
je 0x1004e15
add eax, 2
cmp word [eax], 0
jne 0x1004e03
add eax, 2
cmp word [eax], 0
jne 0x1004e03
sub eax, esi
push 0
sar eax, 1
inc eax
push 0
mov ebp, eax
push 0
push 0
push ebp
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov edi, eax
test edi, edi
je 0x1004e74
push edi
call fcn.010059a0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x1004e74
push 0
push 0
push edi
push ebx
push ebp
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x1004e66
push ebx
call fcn.01005950
add esp, 4
xor ebx, ebx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop esi
pop ebp
pop ebx
ret
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
cmp eax, 2
jne 0x1004eef
test ebx, ebx
jne 0x1004e93
call ebp
mov ebx, eax
test ebx, ebx
je 0x1004eef
mov cl, byte [ebx]
mov eax, ebx
test cl, cl
je 0x1004eab
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x1004e9b
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x1004e9b
sub eax, ebx
inc eax
mov esi, eax
push esi
call fcn.010059a0
mov ebp, eax
add esp, 4
test ebp, ebp
jne 0x1004ecd
push ebx
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov ecx, esi
mov esi, ebx
mov eax, ecx
mov edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
mov eax, ebp
pop edi
pop esi
pop ebp
pop ebx
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
Function at 0x1005670
Capabilities:
Write file on windows

Disassembly:
mov ecx, dword [esp + 4]
sub esp, 0x1a8
mov eax, 0x10081f0
push ebx
push ebp
push esi
push edi
xor ebp, ebp
cmp ecx, dword [eax]
je 0x1005694
add eax, 8
inc ebp
cmp eax, 0x1008280
jb 0x1005685
cmp ecx, dword [ebp*8 + 0x10081f0]
jne 0x100583b
mov eax, dword [0x100a4fc]
cmp eax, 1
je 0x10057fd
test eax, eax
jne 0x10056c0
cmp dword [0x100804c], 1
je 0x10057fd
cmp ecx, 0xfc
je 0x100583b
lea eax, [esp + 0xb4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x10056fb
mov ecx, 5
mov esi, 0x100167c
lea edi, [esp + 0xb4]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
lea edi, [esp + 0xb4]
or ecx, 0xffffffff
xor eax, eax
lea ebx, [esp + 0xb4]
repne scasb al, byte es:[edi]
not ecx
cmp ecx, 0x3c
jbe 0x1005744
lea edi, [esp + 0xb4]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 3
mov ebx, ecx
lea ecx, [esp + 0xb8]
sub ecx, 0x3b
push 0x1001678
add ebx, ecx
push ebx
call fcn.010065a0
add esp, 0xc
mov ecx, 6
mov esi, 0x100165c
lea edi, [esp + 0x14]
xor eax, eax
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
or ecx, 0xffffffff
mov edi, ebx
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x14]
mov ebx, ecx
mov esi, edi
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x14]
and ecx, 3
push 0x12010
rep movsb byte es:[edi], byte [esi]
mov edi, 0x1001658
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x1001630
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x1c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebp*8 + 0x10081f4]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x1c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call fcn.01006510
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1a8
ret
mov eax, dword [0x100a9a0]
test eax, eax
je 0x100580e
mov esi, dword [eax + 0x10]
cmp esi, 0xffffffff
jne 0x1005818
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, eax
mov edx, dword [ebp*8 + 0x10081f4]
lea ecx, [esp + 0x10]
push 0
push ecx
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1a8
ret
Function at 0x105d6560
Capabilities:
Packed with generic packer

Disassembly:
cmp byte [esp + 8], 1
jne 0x105d674d
pushal
mov esi, section.UPX1
lea edi, [esi - 0x1bb000]
push edi
or ebp, 0xffffffff
jmp 0x105d658a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x105d6591
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x105d6580
mov eax, 1
add ebx, ebx
jne 0x105d65a3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x105d65b4
jne 0x105d65d3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x105d65d3
dec eax
add ebx, ebx
jne 0x105d65c0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x105d6598
add ebx, ebx
jne 0x105d65cf
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x105d6625
xor ecx, ecx
sub eax, 3
jb 0x105d65eb
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x105d665a
sar eax, 1
mov ebp, eax
jmp 0x105d65f6
add ebx, ebx
jne 0x105d65f6
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x105d65c4
inc ecx
add ebx, ebx
jne 0x105d6604
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x105d65c4
add ebx, ebx
jne 0x105d6611
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x105d6606
jne 0x105d6622
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x105d6606
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x105d6644
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x105d6636
jmp 0x105d6586
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x105d6644
add edi, ecx
jmp 0x105d6586
pop esi
mov edi, esi
mov ecx, 0x4ec
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x105d6662
cmp byte [edi], 7
jne 0x105d6662
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x105d6667
lea edi, [esi + 0x5d4000]
mov eax, dword [edi]
or eax, eax
je 0x105d66d6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x5d60a8]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x5d60e4]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x105d6694
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x5d60e8]
or eax, eax
je 0x105d66d0
mov dword [ebx], eax
add ebx, 4
jmp 0x105d66b1
popal
xor eax, eax
ret 0xc
add edi, 4
lea ebx, [esi - 4]
xor eax, eax
mov al, byte [edi]
inc edi
or eax, eax
je 0x105d6710
cmp al, 0xef
ja 0x105d66fa
add ebx, eax
mov eax, dword [ebx]
xchg ah, al
rol eax, 0x10
xchg ah, al
add eax, esi
mov dword [ebx], eax
jmp 0x105d66dc
and al, 0xf
shl eax, 0x10
mov ax, word [edi]
add edi, 2
or eax, eax
jne 0x105d66e9
mov eax, dword [edi]
add edi, 4
jmp 0x105d66e9
mov ebp, dword [esi + 0x5d60ec]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x22f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x105d6744
sub esp, 0xffffff80
jmp 0x100024b3
Function at 0x403750
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push ecx
push ebx
push esi
push edi
push 0
push 0x80
push 2
push 0
push 0
mov edi, ecx
mov ebx, edx
push 0x40000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4037a6
mov edx, str.Failed_to_create_file.
mov ecx, 0x4330d0
call fcn.00406020
push eax
call fcn.00405f80
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push 0
push dword [ebp + 8]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4037e1
mov edx, str.Failed_to_write_file.
mov ecx, 0x4330d0
call fcn.00406020
push eax
call fcn.00405f80
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, str.Wrote_to
mov ecx, 0x432fd8
call fcn.00406020
mov edx, edi
mov ecx, eax
call fcn.00406020
push eax
call fcn.00405f80
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4089c6
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
push edi
mov edi, dword [ebp + 0xc]
test eax, eax
jg 0x4089e7
jl 0x4089de
test edi, edi
jne 0x4089e7
xor eax, eax
xor edx, edx
jmp 0x408aa8
cmp dword [ebx + 0x38], 0
je 0x4089fc
push eax
push edi
push dword [ebp + 8]
call fcn.00408aae
jmp 0x408aa8
mov eax, dword [ebx + 0x1c]
push esi
mov esi, edi
mov ecx, dword [eax]
test ecx, ecx
je 0x408a43
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
mov dword [ebp - 4], eax
test eax, eax
je 0x408a43
cmp eax, edi
jb 0x408a1d
mov eax, edi
mov dword [ebp - 4], edi
push eax
push ecx
push dword [ebp + 8]
call fcn.0040ad20
mov ecx, dword [ebp - 4]
add esp, 0xc
mov eax, dword [ebp + 8]
sub esi, ecx
add eax, ecx
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x2c]
sub dword [eax], ecx
mov eax, dword [ebx + 0x1c]
add dword [eax], ecx
jmp 0x408a49
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
cmp dword [ebx + 0x4c], 0
je 0x408a9d
mov ecx, ebx
call fcn.00408266
mov ecx, dword [ebp - 4]
mov edx, esi
mov eax, 0xfff
cmp esi, eax
jbe 0x408a88
push dword [ebx + 0x4c]
push eax
push 1
push ecx
call fcn.00411abd
mov ecx, dword [ebp - 4]
sub esi, eax
add ecx, eax
add esp, 0x10
mov dword [ebp - 4], ecx
mov edx, esi
cmp eax, 0xfff
jne 0x408a9d
jmp 0x408a5b
test edx, edx
je 0x408a9d
push dword [ebx + 0x4c]
push esi
push 1
push ecx
call fcn.00411abd
add esp, 0x10
sub esi, eax
mov edx, dword [ebp + 0x10]
sub edi, esi
mov eax, edi
sbb edx, 0
pop esi
pop edi
pop ebx
leave
ret 0xc

Function at 0x40a500
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x40a53f
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x40a53f
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x40a53f
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x40a53f
cmp dword [ecx + 0x74], 0xe
jbe 0x40a53f
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x418c92
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x42b0e0
push 0x42b0d8
push str.FlsAlloc
push 0x1f
call fcn.00418afd
mov esi, eax
add esp, 0x10
test esi, esi
je 0x418cc6
push dword [ebp + 8]
mov ecx, esi
call dword [0x427174]
call esi
jmp 0x418ccc
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x418d10
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x42b0f0
push 0x42b0e8
push str.FlsGetValue
push 0x21
call fcn.00418afd
mov esi, eax
add esp, 0x10
test esi, esi
je 0x418d47
push dword [ebp + 8]
mov ecx, esi
call dword [0x427174]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x418d4f
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x42b0f8
push 0x42b0f0
push str.FlsSetValue
push 0x22
call fcn.00418afd
mov esi, eax
add esp, 0x10
test esi, esi
je 0x418d89
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x427174]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x41a465
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.0040a670
mov eax, dword [0x432014]
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.004173a9
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x41a4a7
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x41a603
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.004252b0
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 + 0x433978]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.0041b462
mov ecx, dword [esi*4 + 0x433978]
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 0x41a5fc
cmp eax, dword [ecx + edi + 0x24]
jne 0x41a5fc
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 0x41a5fc
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0041b462
add esp, 0x14
test edx, edx
jl 0x41a5fc
jg 0x41a572
test eax, eax
jb 0x41a5fc
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x41a5fc
jl 0x41a58c
cmp dword [ebp - 0x1008], eax
ja 0x41a5fc
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x41a5aa
test ebx, ebx
je 0x41a5e3
cmp ecx, edi
jae 0x41a5e3
mov al, byte [ecx]
cmp al, 0xd
jne 0x41a5c4
lea eax, [edi - 1]
cmp ecx, eax
jae 0x41a5d0
cmp byte [ecx + 1], 0xa
jne 0x41a5d0
inc ecx
jmp 0x41a5d0
movzx eax, al
movsx eax, byte [eax + 0x432290]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x41a5aa
cmp edx, ebx
jne 0x41a5aa
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x41a601
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.00409853
leave
ret
Function at 0x41a8fa
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 + 0x433978]
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 0x41a93a
cmp byte [ebx], 0xa
jne 0x41a93a
or byte [edi + eax + 0x28], 4
jmp 0x41a93f
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 0x41aa3e
mov dl, byte [eax]
cmp dl, 0x1a
je 0x41aa21
inc eax
cmp dl, 0xd
je 0x41a96b
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x41a991
cmp eax, ecx
jae 0x41a99f
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 0x41a953
jmp 0x41aa3e
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 0x41aa1c
cmp dword [ebp - 0x10], 0
je 0x41aa1c
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x433978]
test byte [eax + edi + 0x28], 0x48
je 0x41a9f6
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x41a9e1
mov byte [esi], dl
jmp 0x41a9f2
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x433978]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x41aa3e
cmp byte [ebp - 1], 0xa
jne 0x41aa05
cmp esi, ebx
jne 0x41aa05
mov byte [esi], 0xa
jmp 0x41aa3d
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0041b480
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x41aa3e
mov byte [esi], 0xd
jmp 0x41aa3d
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x433978]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x41aa3b
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x41aa3e
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x41aa47
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 + 0x433978]
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 0x41aa8d
cmp word [ebx], dx
jne 0x41aa8d
or byte [eax + edi + 0x28], 4
jmp 0x41aa92
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 0x41abf5
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 0x41abd5
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x41aad3
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x41ab09
cmp eax, edx
jae 0x41ab17
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 0x41aaae
jmp 0x41abf5
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 0x41abd0
cmp dword [ebp - 0x18], 0
je 0x41abd0
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x433978]
test byte [eax + edi + 0x28], 0x48
je 0x41aba6
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 0x41ab6a
mov word [esi], cx
jmp 0x41aba1
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x433978]
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 + 0x433978]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x433978]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x41abf5
pop eax
cmp word [ebp - 4], ax
jne 0x41abb6
cmp esi, ebx
jne 0x41abb6
mov word [esi], ax
jmp 0x41abf2
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0041b480
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x41abf5
push 0xd
pop eax
jmp 0x41abb1
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x433978]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x41abef
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x41abf5
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret