joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4c3400
Capabilities:
Receive http response

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54a32d
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x5a3604]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x3c], 0
lea ecx, [ebp - 0x28]
call fcn.00404d27
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x18]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x30]
call fcn.004c2ce0
movzx ecx, al
test ecx, ecx
jne 0x4c348c
lea edx, [ebp - 0x28]
push edx
mov ecx, dword [ebp + 8]
call fcn.00404cb3
mov eax, dword [ebp - 0x3c]
or eax, 1
mov dword [ebp - 0x3c], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.00404cae
mov eax, dword [ebp + 8]
jmp 0x4c3596
mov ecx, dword [ebp - 0x30]
call fcn.004c2fc0
mov ecx, dword [ebp - 0x30]
mov dword [ecx + 4], eax
mov edx, dword [ebp - 0x30]
cmp dword [edx + 4], 0x194
jne 0x4c34bb
mov dword [ebp - 0x40], 5
push 0x59733c
lea eax, [ebp - 0x40]
push eax
call fcn.004f69d2
push 0x1000
call fcn.00509d2e
add esp, 4
mov dword [ebp - 0x34], eax
mov byte [ebp - 0x29], 0
mov ecx, 1
test ecx, ecx
je 0x4c3553
lea edx, [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x30]
mov ecx, dword [eax + 0x14]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
jne 0x4c34ef
jmp 0x4c3553
cmp dword [ebp - 0x38], 0
ja 0x4c34fb
mov byte [ebp - 0x29], 1
jmp 0x4c3553
cmp dword [ebp - 0x38], 0x1000
jbe 0x4c351f
mov edx, dword [ebp - 0x34]
push edx
call fcn.004ff369
add esp, 4
mov eax, dword [ebp - 0x38]
push eax
call fcn.00509d2e
add esp, 4
mov dword [ebp - 0x34], eax
lea ecx, [ebp - 0x44]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x34]
push eax
mov ecx, dword [ebp - 0x30]
mov edx, dword [ecx + 0x14]
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
jne 0x4c353e
jmp 0x4c3553
mov eax, dword [ebp - 0x44]
push eax
mov ecx, dword [ebp - 0x34]
push ecx
lea ecx, [ebp - 0x28]
call fcn.00405528
jmp 0x4c34cf
mov edx, dword [ebp - 0x34]
push edx
call fcn.004ff369
add esp, 4
movzx eax, byte [ebp - 0x29]
test eax, eax
jne 0x4c356f
lea ecx, [ebp - 0x28]
call fcn.004c3750
lea ecx, [ebp - 0x28]
push ecx
mov ecx, dword [ebp + 8]
call fcn.00404cb3
mov edx, dword [ebp - 0x3c]
or edx, 1
mov dword [ebp - 0x3c], edx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.00404cae
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004e5fe9
mov esp, ebp
pop ebp
ret 0x14
Function at 0x4c35c0
Capabilities:
Set http header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54a36d
mov eax, dword fs:[0]
push eax
sub esp, 0x54
mov eax, dword [0x5a3604]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x4c], ecx
lea eax, [ebp - 0x40]
push eax
mov ecx, dword [ebp - 0x4c]
add ecx, 0x24
call fcn.004c5b30
mov dword [ebp - 0x5c], eax
mov ecx, dword [ebp - 0x5c]
mov dword [ebp - 0x60], ecx
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x60]
push edx
lea eax, [ebp - 0x28]
push eax
call fcn.004c0990
add esp, 8
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x40]
call fcn.00404cae
push 0xa0000000
lea ecx, [ebp - 0x28]
call sym.steamworks.exe_public:_int___thiscall_Json::Value::getOffsetStart_void_const
push eax
lea ecx, [ebp - 0x28]
call fcn.00402484
push eax
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ecx + 0x14]
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpAddRequestHeaders]
cmp dword [ebp + 8], 0
jne 0x4c365c
mov dword [ebp - 0x50], 0
jmp 0x4c366b
mov eax, dword [ebp + 8]
push eax
call fcn.005006a0
add esp, 4
mov dword [ebp - 0x50], eax
mov ecx, dword [ebp - 0x50]
mov dword [ebp - 0x48], ecx
cmp dword [ebp + 0xc], 0
jne 0x4c36be
push 0
mov edx, dword [ebp - 0x48]
push edx
mov eax, dword [ebp - 0x48]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 0
push 0
mov edx, dword [ebp - 0x4c]
mov eax, dword [edx + 0x14]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
cmp eax, 1
jne 0x4c36a4
mov dword [ebp - 0x54], 1
jmp 0x4c36ab
mov dword [ebp - 0x54], 0
mov cl, byte [ebp - 0x54]
mov byte [ebp - 0x41], cl
lea ecx, [ebp - 0x28]
call fcn.004024ae
mov al, byte [ebp - 0x41]
jmp 0x4c3705
push 0
mov edx, dword [ebp - 0x48]
push edx
mov eax, dword [ebp - 0x48]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 0xffffffffffffffff
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax + 0x14]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
cmp eax, 1
jne 0x4c36ed
mov dword [ebp - 0x58], 1
jmp 0x4c36f4
mov dword [ebp - 0x58], 0
mov dl, byte [ebp - 0x58]
mov byte [ebp - 0x42], dl
lea ecx, [ebp - 0x28]
call fcn.004024ae
mov al, byte [ebp - 0x42]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004e5fe9
mov esp, ebp
pop ebp
ret 8
Function at 0x4ddba0
Capabilities:
Access peb ldr_data
Get process heap force flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54c1c7
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x5a3604]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x14], ebx
cmp dword [ebp + 0xc], 0
mov dword [ebp - 0x10], 0
je 0x4ddbf5
mov dword [ebx], 0x55fd44
mov dword [ebx + 0x50], vtable.std::basic_ios_char__struct_std::char_traits_char__.0
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
push 0
lea esi, [ebx + 4]
mov ecx, ebx
push 0
push esi
mov dword [ebp + 0xc], esi
call fcn.00405941
mov eax, dword [ebx]
push 8
mov dword [ebp - 4], 1
mov dword [ebp - 0x18], esi
mov eax, dword [eax + 4]
mov dword [ebx + eax], vtable.std::basic_ostringstream_char__struct_std::char_traits_char___class_std::allocator_char__.0
mov eax, dword [ebx]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x50]
mov dword [ecx + ebx - 4], eax
mov dword [esi], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
call fcn.0046cf9d
mov esi, eax
add esp, 4
test esi, esi
je 0x4ddc52
push 1
mov byte [ebp - 4], 2
call fcn.004e4ac0
add esp, 4
mov dword [esi + 4], eax
jmp 0x4ddc54
xor esi, esi
lea eax, [ebx + 4]
mov dword [eax + 0x34], esi
lea ebx, [eax + 4]
mov dword [eax + 0xc], ebx
lea esi, [eax + 8]
mov dword [eax + 0x10], esi
lea ecx, [eax + 0x18]
mov dword [eax + 0x20], ecx
lea edx, [eax + 0x24]
mov dword [eax + 0x2c], edx
lea edi, [eax + 0x14]
mov dword [eax + 0x1c], edi
add eax, 0x28
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp + 0xc]
mov dword [ebx + 0x30], eax
mov ebx, dword [ebp - 0x10]
mov dword [esi], 0
mov esi, dword [ebp + 0xc]
mov dword [ecx], 0
mov dword [eax], 0
mov dword [ebx], 0
mov ebx, dword [ebp + 8]
mov ecx, ebx
not ecx
mov dword [edi], 0
mov dword [edx], 0
and ecx, 1
shl ecx, 2
mov eax, ebx
mov edx, ecx
mov dword [esi], vtable.std::basic_stringbuf_char__struct_std::char_traits_char___class_std::allocator_char__.0
or edx, 8
mov dword [esi + 0x38], 0
and al, 8
cmove edx, ecx
mov eax, edx
or eax, 0x10
and bl, 4
cmove eax, edx
mov dword [esi + 0x3c], eax
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x4edb1b
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov eax, dword [esi + 8]
mov edi, eax
mov edx, eax
and edi, 7
je 0x4edb49
cmp eax, edi
jge 0x4edb3d
push esi
call fcn.004eac19
mov eax, dword [esi + 8]
pop ecx
mov ecx, edi
shr dword [esi + 0xc], cl
sub eax, edi
mov dword [esi + 8], eax
mov edx, eax
xor ecx, ecx
test eax, eax
jle 0x4edb6c
mov edi, dword [esi + 0xc]
mov al, byte [esi + 0xc]
sub edx, 8
mov byte [ebp + ecx + 8], al
inc ecx
shr edi, 8
mov dword [esi + 0xc], edi
test edx, edx
jg 0x4edb52
mov dword [esi + 8], edx
jmp 0x4edb81
mov eax, dword [esi]
cmp eax, dword [esi + 4]
jb 0x4edb77
xor dl, dl
jmp 0x4edb7c
mov dl, byte [eax]
inc eax
mov dword [esi], eax
mov byte [ebp + ecx + 8], dl
inc ecx
cmp ecx, 4
jl 0x4edb6c
mov eax, dword [ebp + 8]
movzx ecx, byte [ebp + 0xb]
movzx edi, ah
movzx eax, al
shl edi, 8
add edi, eax
shl ecx, 8
movzx eax, byte [ebp + 0xa]
add ecx, eax
mov eax, edi
xor eax, 0xffff
cmp ecx, eax
je 0x4edbba
mov dword [0x5aee08], str.zlib_corrupt
xor eax, eax
jmp 0x4edbfc
mov eax, dword [esi]
add eax, edi
cmp eax, dword [esi + 4]
jbe 0x4edbcf
mov dword [0x5aee08], str.read_past_buffer
jmp 0x4edbb6
mov eax, dword [esi + 0x10]
add eax, edi
cmp eax, dword [esi + 0x18]
jbe 0x4edbe6
push edi
push esi
call fcn.004effc4
pop ecx
pop ecx
test eax, eax
je 0x4edbb6
push edi
push dword [esi]
push dword [esi + 0x10]
call fcn.004f4b10
add dword [esi], edi
xor eax, eax
add dword [esi + 0x10], edi
add esp, 0xc
inc eax
pop edi
pop esi
pop ebp
ret
Function at 0x4f8c42
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x5a3604]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push 0x563830
push esi
call fcn.0051412c
pop ecx
pop ecx
test eax, eax
jne 0x4f8c70
xor al, al
jmp 0x4f8ced
push ebx
lea eax, [ebp - 0x210]
xor ebx, ebx
push eax
push 0x104
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], ebx
push esi
push eax
call fcn.004f8977
mov edx, eax
add esp, 0x10
test edx, edx
jne 0x4f8caa
push dword [ebp - 0x210]
call fcn.004ff369
xor al, al
jmp 0x4f8ceb
mov ecx, edx
push edi
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x4f8cb0
sub ecx, edi
sar ecx, 1
pop edi
cmp ecx, 3
je 0x4f8cd0
push edx
call fcn.004f8b79
pop ecx
test al, al
je 0x4f8c9b
push esi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 1
jbe 0x4f8cde
mov bl, 1
push dword [ebp - 0x210]
call fcn.004ff369
mov al, bl
pop ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.004e5fe9
leave
ret

Function at 0x5095b5
Capabilities:
Parse pe header

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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004e6f40
mov eax, dword [0x5a3604]
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.0050d46d
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x513b25
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x513c81
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.004e6e50
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 + 0x5af4b8]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.00519043
mov ecx, dword [esi*4 + 0x5af4b8]
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 0x513c7a
cmp eax, dword [ecx + edi + 0x24]
jne 0x513c7a
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 0x513c7a
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00519043
add esp, 0x14
test edx, edx
jl 0x513c7a
jg 0x513bf0
test eax, eax
jb 0x513c7a
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x513c7a
jl 0x513c0a
cmp dword [ebp - 0x1008], eax
ja 0x513c7a
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x513c28
test ebx, ebx
je 0x513c61
cmp ecx, edi
jae 0x513c61
mov al, byte [ecx]
cmp al, 0xd
jne 0x513c42
lea eax, [edi - 1]
cmp ecx, eax
jae 0x513c4e
cmp byte [ecx + 1], 0xa
jne 0x513c4e
inc ecx
jmp 0x513c4e
movzx eax, al
movsx eax, byte [eax + 0x5a3b78]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x513c28
cmp edx, ebx
jne 0x513c28
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x513c7f
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004e5fe9
leave
ret

Function at 0x514cdf
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x565d3c
push 0x565d34
push str.FlsAlloc
push 0x1f
call fcn.00514b0a
mov esi, eax
add esp, 0x10
test esi, esi
je 0x514d13
push dword [ebp + 8]
mov ecx, esi
call dword [0x54e6a0]
call esi
jmp 0x514d19
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x514d5d
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x565d4c
push 0x565d44
push str.FlsGetValue
push 0x21
call fcn.00514b0a
mov esi, eax
add esp, 0x10
test esi, esi
je 0x514d94
push dword [ebp + 8]
mov ecx, esi
call dword [0x54e6a0]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x514d9c
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x565d54
push 0x565d4c
push str.FlsSetValue
push 0x22
call fcn.00514b0a
mov esi, eax
add esp, 0x10
test esi, esi
je 0x514dd6
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x54e6a0]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x5183be
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 + 0x5af4b8]
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 0x5183fe
cmp byte [ebx], 0xa
jne 0x5183fe
or byte [edi + eax + 0x28], 4
jmp 0x518403
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 0x518502
mov dl, byte [eax]
cmp dl, 0x1a
je 0x5184e5
inc eax
cmp dl, 0xd
je 0x51842f
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x518455
cmp eax, ecx
jae 0x518463
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 0x518417
jmp 0x518502
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 0x5184e0
cmp dword [ebp - 0x10], 0
je 0x5184e0
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x5af4b8]
test byte [eax + edi + 0x28], 0x48
je 0x5184ba
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x5184a5
mov byte [esi], dl
jmp 0x5184b6
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x5af4b8]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x518502
cmp byte [ebp - 1], 0xa
jne 0x5184c9
cmp esi, ebx
jne 0x5184c9
mov byte [esi], 0xa
jmp 0x518501
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00519061
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x518502
mov byte [esi], 0xd
jmp 0x518501
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x5af4b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x5184ff
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x518502
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x51850b
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 + 0x5af4b8]
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 0x518551
cmp word [ebx], dx
jne 0x518551
or byte [eax + edi + 0x28], 4
jmp 0x518556
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 0x5186b9
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 0x518699
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x518597
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x5185cd
cmp eax, edx
jae 0x5185db
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 0x518572
jmp 0x5186b9
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 0x518694
cmp dword [ebp - 0x18], 0
je 0x518694
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x5af4b8]
test byte [eax + edi + 0x28], 0x48
je 0x51866a
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 0x51862e
mov word [esi], cx
jmp 0x518665
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x5af4b8]
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 + 0x5af4b8]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x5af4b8]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x5186b9
pop eax
cmp word [ebp - 4], ax
jne 0x51867a
cmp esi, ebx
jne 0x51867a
mov word [esi], ax
jmp 0x5186b6
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00519061
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x5186b9
push 0xd
pop eax
jmp 0x518675
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x5af4b8]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x5186b3
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x5186b9
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x51d956
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [0x5a3604]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x25c], ecx
cmp edx, edi
je 0x51d9a1
movzx eax, word [edx]
lea ecx, [ebp - 0x255]
push eax
call fcn.0051daf1
test al, al
jne 0x51d99b
sub edx, 2
cmp edx, edi
jne 0x51d981
mov ecx, dword [ebp - 0x25c]
movzx esi, word [edx]
cmp esi, 0x3a
jne 0x51d9c3
lea eax, [edi + 2]
cmp edx, eax
je 0x51d9c3
push ecx
xor ebx, ebx
push ebx
push ebx
push edi
call fcn.0051d8a2
add esp, 0x10
jmp 0x51dabd
push esi
lea ecx, [ebp - 0x255]
call fcn.0051daf1
sub edx, edi
movzx eax, al
sar edx, 1
inc edx
neg eax
sbb eax, eax
xor ebx, ebx
push ebx
push ebx
and eax, edx
push ebx
mov dword [ebp - 0x260], eax
lea eax, [ebp - 0x254]
push eax
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileExW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x51da06
push dword [ebp - 0x25c]
jmp 0x51d9b3
mov ebx, dword [ebp - 0x25c]
push 0x2e
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
sar eax, 2
mov dword [ebp - 0x25c], eax
pop eax
cmp word [ebp - 0x228], ax
jne 0x51da43
cmp word [ebp - 0x226], 0
je 0x51da64
cmp word [ebp - 0x226], ax
jne 0x51da43
cmp word [ebp - 0x224], 0
je 0x51da64
push ebx
push dword [ebp - 0x260]
lea eax, [ebp - 0x228]
push edi
push eax
call fcn.0051d8a2
add esp, 0x10
mov dword [ebp - 0x264], eax
test eax, eax
jne 0x51dab0
lea eax, [ebp - 0x254]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
push 0x2e
test eax, eax
pop eax
jne 0x51da1d
mov eax, dword [ebx + 4]
mov edx, dword [ebx]
sub eax, edx
mov ecx, dword [ebp - 0x25c]
sar eax, 2
cmp ecx, eax
jne 0x51da98
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
jmp 0x51dabd
push 0x51d6d2
sub eax, ecx
push 4
push eax
lea eax, [edx + ecx*4]
push eax
call fcn.0050a1c0
add esp, 0x10
jmp 0x51da8d
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [ebp - 0x264]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004e5fe9
leave
ret

Function at 0x51e3d3
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x51e3e4
pop esi
ret
push ebx
push edi
push esi
call fcn.0051e39c
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.00513e3b
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x51e40c
push ebx
push esi
push edi
call fcn.004f4b10
add esp, 0xc
push 0
call fcn.00513e01
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x51e7dc
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0051e421
Function at 0x5209ec
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
call fcn.0051457a
mov esi, dword [ebp + 8]
mov edi, eax
push 2
lea eax, [ebp - 4]
mov ecx, esi
push eax
and ecx, 0x3ff
push 0x20000001
or ecx, 0x400
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x520a5b
cmp esi, dword [ebp - 4]
je 0x520a56
cmp dword [ebp + 0xc], 0
je 0x520a56
mov esi, dword [edi + 0x50]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x520a33
push dword [edi + 0x50]
sub esi, ecx
sar esi, 1
call fcn.0052053e
pop ecx
xor ecx, ecx
cmp eax, esi
setne cl
mov eax, ecx
jmp 0x520a5d
xor eax, eax
inc eax
jmp 0x520a5d
xor eax, eax
pop edi
pop esi
leave
ret