joyce8/EMBER2024-capa huggingface dataset:
Function at 0x45dedf
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 0x45df0f
cmp esi, 2
je 0x45df0f
cmp esi, 4
je 0x45df0f
cmp esi, 8
je 0x45df0f
cmp esi, 0x18
je 0x45df0f
cmp esi, 0x20
je 0x45df0f
xor eax, eax
jmp 0x45e0d9
mov ecx, dword [0x62dbbc]
push ebp
push edi
xor edi, edi
mov dword [esp + 0x10], edi
test ecx, ecx
jle 0x45e0d5
mov edx, dword [esp + 0x28]
mov eax, dword [edi*4 + 0x62e2f4]
cmp dword [eax], edx
je 0x45df42
inc edi
mov dword [esp + 0x10], edi
cmp edi, ecx
jl 0x45df29
jmp 0x45e0d5
cmp dword [esp + 0x38], 0x20
jne 0x45e0ac
mov eax, dword [eax + 8]
test eax, eax
je 0x45df82
cmp esi, 0x20
je 0x45df5e
cmp esi, 0xffffffff
jne 0x45df82
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 0x45e0d3
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 [0x62c3a4]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [esp + 0x18], eax
test eax, eax
je 0x45e0d5
mov ebx, dword [esp + 0x30]
test ebx, ebx
jle 0x45e077
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 0x45e057
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]
dec edi
jne 0x45dfe8
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
dec dword [esp + 0x24]
mov dword [esp + 0x30], edx
mov dword [esp + 0x38], ecx
jne 0x45dfd5
mov esi, dword [esp + 0x44]
mov edi, dword [esp + 0x10]
mov eax, dword [edi*4 + 0x62e2f4]
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 [0x62c3a4]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x45e0d5
cmp dword [esp + 0x38], 0x18
jne 0x45e0d5
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 0x46384b
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push edi
push dword [0x62ddd8]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
jne 0x4638ac
push esi
push dword [0x62ddd4]
push 8
push dword [0x62c3a4]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
push edi
push dword [0x62ddd8]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov esi, dword [0x62ddd0]
jmp 0x46389c
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x46389a
mov eax, dword [esi + 8]
add eax, edi
push eax
call ecx
pop ecx
mov esi, dword [esi]
test esi, esi
jne 0x46388a
push edi
push 0x4637e9
call fcn.00499b1c
pop esi
mov eax, dword [esp + 8]
add eax, edi
pop edi
ret 4

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

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x10]
mov ecx, esi
push edi
and ecx, 3
je 0x4638cc
push 4
pop eax
sub eax, ecx
add esi, eax
mov eax, dword [0x62ddd4]
mov ebx, dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x463903
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push esi
push 8
push dword [0x62c3a4]
mov dword [0x62ddd8], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push dword [0x62ddd8]
call ebx
mov eax, dword [0x62ddd4]
mov edi, eax
add eax, esi
push eax
push dword [0x62ddd8]
mov dword [0x62ddd4], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
push 8
push dword [0x62c3a4]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ebp, eax
push ebp
push dword [0x62ddd8]
call ebx
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
test esi, esi
jne 0x463943
test ebx, ebx
je 0x463964
push 0x14
push 0x62ddd0
call fcn.00464266
pop ecx
pop ecx
mov dword [eax], edi
mov dword [eax + 4], esi
mov dword [eax + 8], ebx
test esi, esi
je 0x463964
lea ecx, [edi + ebp]
push ecx
call esi
pop ecx
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
ret 0xc

Function at 0x4643e0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 8]
sub edx, dword [ebp + 0xc]
mov dword [ebp - 4], edx
mov eax, dword [ebp + 8]
cmp dword [eax], 0
jne 0x464426
mov ecx, dword [ebp - 4]
add ecx, 0xa
push ecx
push 0
mov edx, dword [0x62e378]
push edx
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
jmp 0x464447
mov edx, dword [ebp - 4]
add edx, 0xa
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
push 0
mov edx, dword [0x62e378]
push edx
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
mov edx, dword [ebp - 4]
shr edx, 1
push edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
add ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call fcn.00464dd0
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dword [ecx + 8], edx
mov esp, ebp
pop ebp
ret 8
Function at 0x464470
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 8]
add edx, 2
mov eax, dword [ebp - 4]
mov dword [eax + 8], edx
mov esp, ebp
pop ebp
ret

Function at 0x464540
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov eax, dword [ecx]
mov edx, dword [ebp - 4]
add eax, dword [edx + 8]
mov esp, ebp
pop ebp
ret

Function at 0x464a90
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
cmp dword [ebp + 0xc], 0xffffffff
jne 0x464ab4
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 8]
mov dword [ebp + 0xc], edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 8]
mov edx, dword [ebp + 8]
lea eax, [ecx + edx*2]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
sub edx, 4
cmp dword [ebp - 8], edx
jl 0x464b04
mov eax, dword [ebp - 8]
add eax, 0x4000
mov ecx, dword [ebp - 4]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 4]
mov eax, dword [edx + 4]
add eax, 0xa
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
push edx
push 0
mov eax, dword [0x62e378]
push eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [ebp - 4]
mov dword [ecx], eax
jmp 0x464b4c
mov edx, dword [ebp - 4]
cmp dword [edx + 4], 0x100000
jle 0x464b4c
cmp dword [ebp - 8], 0x100000
jge 0x464b20
mov dword [ebp - 8], 0x100000
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 8]
mov dword [eax + 4], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx + 4]
add eax, 0xa
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
push edx
push 0
mov eax, dword [0x62e378]
push eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [ebp - 4]
mov dword [ecx], eax
mov edx, dword [ebp - 4]
mov eax, dword [edx]
add eax, dword [ebp + 0xc]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
lea eax, [edx + ecx*2]
mov ecx, dword [ebp - 4]
mov dword [ecx + 8], eax
mov eax, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret 8

Function at 0x464ba0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 8]
shl ecx, 1
mov edx, dword [ebp - 4]
mov eax, dword [edx + 8]
sub eax, ecx
mov ecx, dword [ebp - 4]
mov dword [ecx + 8], eax
mov esp, ebp
pop ebp
ret 4
Function at 0x464d20
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 8]
cmp edx, dword [ecx]
jb 0x464d5e
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ebp - 4]
add ecx, dword [edx + 8]
cmp dword [ebp + 8], ecx
ja 0x464d5e
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
sub ecx, dword [eax]
add ecx, 1
mov eax, ecx
jmp 0x464d60
xor eax, eax
mov esp, ebp
pop ebp
ret 4

Function at 0x464da0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov eax, dword [ecx]
add eax, dword [ebp + 8]
mov esp, ebp
pop ebp
ret 4

Function at 0x465180
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x628958]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 8]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ebp - 4]
add ecx, dword [edx + 8]
mov dword [ebp - 8], ecx
mov eax, dword [ebp - 8]
mov esp, ebp
pop ebp
ret 4
Function at 0x46fbf0
Capabilities:
Terminate process

Disassembly:
mov eax, dword [esp + 4]
test eax, eax
je 0x46fc10
mov ecx, dword [eax + 0x40]
test ecx, ecx
je 0x46fc10
mov eax, dword [eax + 0x44]
test eax, eax
je 0x46fc10
push dword [esp + 8]
push eax
call ecx
add esp, 8
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]

Function at 0x481ea0
Capabilities:
Query environment variable

Disassembly:
push ecx
push esi
push edi
mov edi, dword [esp + 0x10]
push edi
mov dword [edi + 4], 0
call fcn.00483fc0
push 0x54
push edi
mov dword [esp + 0x14], eax
call fcn.00483f90
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x481ee7
push edi
call fcn.00483fd0
mov ecx, dword [edi]
push edi
mov dword [ecx + 0x14], 0x38
mov ecx, dword [edi]
mov dword [ecx + 0x18], esi
mov eax, dword [edi]
mov eax, dword [eax]
call eax
add esp, 8
mov dword [esi], fcn.00481b30
mov dword [esi + 4], fcn.004819c0
mov dword [esi + 8], fcn.00481a90
mov dword [esi + 0xc], fcn.00481910
mov dword [esi + 0x10], 0x482200
mov dword [esi + 0x14], 0x482190
mov dword [esi + 0x18], 0x481ff0
mov dword [esi + 0x1c], 0x4817c0
mov dword [esi + 0x20], 0x481670
mov dword [esi + 0x24], 0x481da0
mov dword [esi + 0x28], 0x482270
mov dword [esi + 0x30], 0x3b9aca00
mov eax, dword [esp + 8]
mov dword [esi + 0x2c], eax
mov dword [esi + 0x38], 0
mov dword [esi + 0x40], 0
mov dword [esi + 0x34], 0
mov dword [esi + 0x3c], 0
mov dword [esi + 0x44], 0
mov dword [esi + 0x48], 0
mov dword [esi + 0x4c], 0x54
push str.JPEGMEM
mov dword [edi + 4], esi
call dword [sym.imp.MSVCRT.dll_getenv]
add esp, 4
test eax, eax
je 0x481fca
lea ecx, [esp + 0x10]
mov byte [esp + 0x10], 0x78
push ecx
lea ecx, [esp + 0xc]
push ecx
push str._ld_c
push eax
call dword [sym.imp.MSVCRT.dll_sscanf]
add esp, 0x10
test eax, eax
jle 0x481fca
mov al, byte [esp + 0x10]
cmp al, 0x6d
je 0x481fb9
cmp al, 0x4d
mov eax, dword [esp + 8]
jne 0x481fc1
imul eax, dword [esp + 8], 0x3e8
imul eax, eax, 0x3e8
mov dword [esi + 0x2c], eax
pop edi
pop esi
pop ecx
ret
Function at 0x498000
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push edi
mov edi, dword [ebx + 0x48]
mov eax, dword [edi + 0x18]
cmp eax, 0xc
jle 0x49801d
pop edi
mov dword [ebx + 0x40], 0x70
xor eax, eax
pop ebx
ret
push ebp
push esi
cmp dword [edi + 0x2c], eax
jge 0x4980e1
lea esi, [edi + 0x44]
jmp 0x498030
mov dl, byte [esi]
test dl, dl
jne 0x4980b5
mov ecx, dword [ebx + 0x48]
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x49804b
push 1
push esi
push ebx
call eax
add esp, 0xc
jmp 0x49805c
push dword [ecx + 0x38]
push 1
push 1
push esi
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x49813c
mov al, byte [esi]
test al, al
je 0x49812e
mov edx, dword [ebx + 0x48]
lea ebp, [esi + 1]
movzx eax, al
mov ecx, dword [edx + 0x3c]
test ecx, ecx
je 0x498089
push eax
push ebp
push ebx
call ecx
add esp, 0xc
jmp 0x498099
push dword [edx + 0x38]
push eax
push 1
push ebp
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
mov cl, byte [esi]
mov edx, eax
movzx eax, cl
cmp edx, eax
jne 0x49813c
mov al, byte [ebp]
dec cl
mov byte [ebp], 2
mov byte [esi], cl
jmp 0x4980c7
mov cl, byte [esi + 1]
movzx eax, cl
inc cl
dec dl
mov al, byte [eax + esi]
mov byte [esi + 1], cl
mov byte [esi], dl
mov ecx, dword [edi + 0x2c]
movzx eax, al
shl eax, cl
or dword [edi + 0x30], eax
lea eax, [ecx + 8]
mov dword [edi + 0x2c], eax
cmp eax, dword [edi + 0x18]
jl 0x498030
mov eax, dword [edi + 0x18]
movzx ecx, word [eax*2 + 0x4bb418]
mov eax, dword [esp + 0x18]
and ecx, dword [edi + 0x30]
mov dword [eax], ecx
mov ecx, dword [edi + 0x18]
shr dword [edi + 0x30], cl
sub dword [edi + 0x2c], ecx
mov eax, dword [edi + 0x14]
cmp eax, 0x1001
jge 0x498124
mov edx, dword [edi + 0x1c]
inc eax
mov dword [edi + 0x14], eax
cmp eax, edx
jle 0x498124
cmp ecx, 0xc
jge 0x498124
lea eax, [edx + edx]
mov dword [edi + 0x1c], eax
lea eax, [ecx + 1]
mov dword [edi + 0x18], eax
pop esi
pop ebp
pop edi
mov eax, 1
pop ebx
ret
pop esi
pop ebp
pop edi
mov dword [ebx + 0x40], 0x70
xor eax, eax
pop ebx
ret
pop esi
pop ebp
pop edi
mov dword [ebx + 0x40], 0x66
xor eax, eax
pop ebx
ret
Function at 0x498410
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
mov edi, dword [esi + 0x48]
mov eax, dword [edi + 0x3c]
test eax, eax
je 0x49842f
push 1
lea ecx, [esp + 0x10]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x498444
push dword [edi + 0x38]
lea eax, [esp + 0x10]
push 1
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x49849b
mov cl, byte [esp + 0xc]
test cl, cl
je 0x4984a7
mov edx, dword [esp + 0x10]
lea eax, [edi + 0x44]
mov dword [edx], eax
mov byte [eax], cl
mov eax, dword [esi + 0x48]
mov ecx, dword [eax + 0x3c]
test ecx, ecx
je 0x498478
movzx eax, byte [esp + 0xc]
push eax
mov eax, dword [edx]
inc eax
push eax
push esi
call ecx
add esp, 0xc
jmp 0x498490
push dword [eax + 0x38]
movzx eax, byte [esp + 0x10]
push eax
mov eax, dword [edx]
inc eax
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
mov ecx, eax
movzx eax, byte [esp + 0xc]
cmp ecx, eax
je 0x4984bc
pop edi
mov dword [esi + 0x40], 0x66
xor eax, eax
pop esi
ret
mov eax, dword [esp + 0x10]
mov dword [eax], 0
mov byte [edi + 0x44], 0
mov dword [edi + 0x34], 0
pop edi
mov eax, 1
pop esi
ret

Function at 0x4984d0
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
mov edi, dword [esi + 0x48]
mov eax, dword [edi + 0x3c]
test eax, eax
je 0x4984ef
push 1
lea ecx, [esp + 0x10]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x498504
push dword [edi + 0x38]
lea eax, [esp + 0x10]
push 1
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x49855b
mov cl, byte [esp + 0xc]
test cl, cl
je 0x498567
mov edx, dword [esp + 0x10]
lea eax, [edi + 0x44]
mov dword [edx], eax
mov byte [eax], cl
mov eax, dword [esi + 0x48]
mov ecx, dword [eax + 0x3c]
test ecx, ecx
je 0x498538
movzx eax, byte [esp + 0xc]
push eax
mov eax, dword [edx]
inc eax
push eax
push esi
call ecx
add esp, 0xc
jmp 0x498550
push dword [eax + 0x38]
movzx eax, byte [esp + 0x10]
push eax
mov eax, dword [edx]
inc eax
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
mov ecx, eax
movzx eax, byte [esp + 0xc]
cmp ecx, eax
je 0x498571
pop edi
mov dword [esi + 0x40], 0x66
xor eax, eax
pop esi
ret
mov eax, dword [esp + 0x10]
mov dword [eax], 0
pop edi
mov eax, 1
pop esi
ret
Function at 0x4988c0
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
mov eax, dword [esi + 0x48]
test byte [eax], 8
jne 0x4988d8
mov dword [esi + 0x40], 0x6f
xor eax, eax
pop esi
ret
mov ecx, dword [eax + 0x3c]
test ecx, ecx
je 0x4988ee
push 1
lea eax, [esp + 0xc]
push eax
push esi
call ecx
add esp, 0xc
jmp 0x498903
push dword [eax + 0x38]
lea eax, [esp + 0xc]
push 1
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
je 0x498913
mov dword [esi + 0x40], 0x66
xor eax, eax
pop esi
ret
mov al, byte [esp + 8]
cmp al, 0x21
je 0x498956
cmp al, 0x2c
je 0x498945
cmp al, 0x3b
mov eax, dword [esp + 0xc]
je 0x498938
mov dword [eax], 0
xor eax, eax
mov dword [esi + 0x40], 0x6b
pop esi
ret
mov dword [eax], 4
mov eax, 1
pop esi
ret
mov eax, dword [esp + 0xc]
pop esi
mov dword [eax], 2
mov eax, 1
ret
mov eax, dword [esp + 0xc]
pop esi
mov dword [eax], 3
mov eax, 1
ret
Function at 0x498970
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
mov eax, dword [esi + 0x48]
test byte [eax], 8
jne 0x498988
mov dword [esi + 0x40], 0x6f
xor eax, eax
pop esi
ret
push esi
push esi
call fcn.00498b20
add esp, 8
test eax, eax
je 0x498984
lea eax, [esi + 4]
push eax
push esi
call fcn.00498b20
add esp, 8
test eax, eax
je 0x498984
mov ecx, dword [esi + 0x48]
push ebp
mov ebp, dword [sym.imp.MSVCRT.dll_fread]
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x4989c7
push 3
lea ecx, [esp + 0x10]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x4989d8
push dword [ecx + 0x38]
lea eax, [esp + 0x10]
push 3
push 1
push eax
call ebp
add esp, 0x10
cmp eax, 3
je 0x4989fb
push dword [esi + 0x14]
mov dword [esi + 0x40], 0x66
call fcn.004993d0
add esp, 4
mov dword [esi + 0x14], 0
xor eax, eax
pop ebp
pop esi
ret
mov dl, byte [esp + 0xc]
movzx ecx, dl
mov eax, ecx
and ecx, 7
shr eax, 4
inc ecx
and eax, 7
inc eax
push ebx
mov dword [esi + 8], eax
mov bl, dl
movzx eax, byte [esp + 0x11]
shr bl, 3
mov dword [esi + 0xc], eax
and bl, 1
mov al, byte [esp + 0x12]
mov byte [esi + 0x10], al
push edi
test dl, dl
jns 0x498b00
mov eax, 1
shl eax, cl
push 0
push eax
call fcn.00499480
add esp, 8
mov dword [esi + 0x14], eax
test eax, eax
jne 0x498a58
pop edi
pop ebx
pop ebp
mov dword [esi + 0x40], 0x6d
pop esi
ret
mov byte [eax + 8], bl
xor ebx, ebx
mov eax, dword [esi + 0x14]
cmp dword [eax], ebx
jle 0x498b07
xor edi, edi
lea ebx, [ebx]
mov ecx, dword [esi + 0x48]
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x498a89
push 3
lea ecx, [esp + 0x18]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x498a9a
push dword [ecx + 0x38]
lea eax, [esp + 0x18]
push 3
push 1
push eax
call ebp
add esp, 0x10
cmp eax, 3
jne 0x498ae0
mov eax, dword [esi + 0x14]
inc ebx
mov ecx, dword [eax + 0xc]
movzx eax, byte [esp + 0x14]
mov byte [edi + ecx], al
mov eax, dword [esi + 0x14]
mov ecx, dword [eax + 0xc]
movzx eax, byte [esp + 0x15]
mov byte [ecx + edi + 1], al
mov eax, dword [esi + 0x14]
mov ecx, dword [eax + 0xc]
movzx eax, byte [esp + 0x16]
mov byte [ecx + edi + 2], al
add edi, 3
mov eax, dword [esi + 0x14]
cmp ebx, dword [eax]
jl 0x498a70
pop edi
pop ebx
pop ebp
mov eax, 1
pop esi
ret
push dword [esi + 0x14]
call fcn.004993d0
add esp, 4
mov dword [esi + 0x14], 0
mov dword [esi + 0x40], 0x66
xor eax, eax
pop edi
pop ebx
pop ebp
pop esi
ret
mov dword [esi + 0x14], 0
pop edi
pop ebx
pop ebp
mov eax, 1
pop esi
ret

Function at 0x498b20
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
mov ecx, dword [esi + 0x48]
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x498b3e
push 2
lea ecx, [esp + 0xc]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x498b53
push dword [ecx + 0x38]
lea eax, [esp + 0xc]
push 2
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 2
je 0x498b63
mov dword [esi + 0x40], 0x66
xor eax, eax
pop esi
ret
mov ax, word [esp + 8]
movzx ecx, ah
movzx eax, al
shl ecx, 8
or ecx, eax
mov eax, dword [esp + 0xc]
pop esi
mov dword [eax], ecx
mov eax, 1
ret
Function at 0x498b80
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push edi
push 0x4c
call dword [sym.imp.MSVCRT.dll_malloc]
mov edi, eax
add esp, 4
test edi, edi
jne 0x498baa
mov eax, dword [esp + 0x18]
test eax, eax
je 0x498ba3
mov dword [eax], 0x6d
xor eax, eax
pop edi
add esp, 8
ret
push esi
push 0x4c
push 0
push edi
call sub.MSVCRT.dll_memset
push 0x614c
push 1
mov dword [edi + 0x34], 0
mov dword [edi + 0x14], 0
call dword [sym.imp.MSVCRT.dll_calloc]
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x498bf9
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x498be7
mov dword [eax], 0x6d
push edi
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
xor eax, eax
pop esi
pop edi
add esp, 8
ret
push 0x614c
push 0
push esi
call sub.MSVCRT.dll_memset
mov eax, dword [esp + 0x24]
add esp, 0xc
mov dword [edi + 0x48], esi
mov dword [esi + 0x3c], eax
mov eax, dword [esp + 0x14]
mov dword [esi + 4], 0
mov dword [esi + 0x38], 0
mov dword [esi], 8
mov ecx, dword [edi + 0x48]
mov dword [edi + 0x44], eax
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x498c47
push 6
lea ecx, [esp + 0xc]
push ecx
push edi
call eax
add esp, 0xc
jmp 0x498c5c
push dword [ecx + 0x38]
lea eax, [esp + 0xc]
push 6
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 6
je 0x498c71
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x498c9d
mov dword [eax], 0x66
jmp 0x498c9d
push 3
lea eax, [esp + 0xc]
mov byte [esp + 0x12], 0
push eax
push str.GIFVER
call dword [sym.imp.MSVCRT.dll_strncmp]
add esp, 0xc
test eax, eax
je 0x498cb4
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x498c9d
mov dword [eax], 0x67
push esi
mov esi, dword [sym.imp.MSVCRT.dll_free]
call esi
push edi
call esi
add esp, 8
xor eax, eax
pop esi
pop edi
add esp, 8
ret
push edi
call fcn.00498970
add esp, 4
test eax, eax
jne 0x498ce6
push esi
mov esi, dword [sym.imp.MSVCRT.dll_free]
call esi
push edi
call esi
mov eax, dword [esp + 0x24]
add esp, 8
test eax, eax
je 0x498cde
mov dword [eax], 0x68
pop esi
xor eax, eax
pop edi
add esp, 8
ret
mov dword [edi + 0x40], 0
cmp byte [esp + 0xb], 0x39
sete al
mov byte [esi + 0x6148], al
mov eax, edi
pop esi
pop edi
add esp, 8
ret

Function at 0x498f30
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
mov edi, dword [esi + 0x48]
mov eax, dword [edi + 0x3c]
test eax, eax
je 0x498f4f
push 1
lea ecx, [esp + 0x10]
push ecx
push esi
call eax
add esp, 0xc
jmp 0x498f64
push dword [edi + 0x38]
lea eax, [esp + 0x10]
push 1
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
cmp eax, 1
jb 0x498f7a
movzx ecx, byte [esp + 0xc]
cmp ecx, 8
jle 0x498f7f
mov dword [esi + 0x40], 0x66
pop edi
xor eax, eax
pop esi
ret
mov eax, 1
mov dword [edi + 8], ecx
shl eax, cl
inc ecx
mov dword [edi + 0xc], eax
inc eax
mov dword [edi + 0x10], eax
inc eax
mov dword [edi + 0x14], eax
mov eax, 1
shl eax, cl
mov dword [edi + 0x1c], eax
mov eax, 0x1002
mov dword [edi + 0x18], ecx
mov ecx, 0x1000
mov byte [edi + 0x44], 0
mov dword [edi + 0x28], 0
mov dword [edi + 0x20], 0x1002
mov dword [edi + 0x2c], 0
mov dword [edi + 0x30], 0
add edi, 0x2144
rep stosd dword es:[edi], eax
pop edi
mov eax, 1
pop esi
ret