joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4b174d
Capabilities:
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ebx
lea ebx, [ebp - 0xc]
sub esp, 0x34
mov dword [esp], ebx
call fcn.004a8627
mov eax, dword [ebp - 0xc]
cmp dword [eax], 0
je 0x4b17cf
mov edx, dword [ebp + 0x10]
add eax, 4
mov dword [esp + 0x10], edx
mov edx, dword [ebp + 0xc]
mov edx, dword [edx]
mov dword [esp + 8], eax
mov dword [esp + 4], str._s_s__u
add edx, 4
mov dword [esp], 0x569040
mov dword [esp + 0xc], edx
call sub.msvcrt.dll_sprintf
mov dword [esp], 0x569040
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
inc eax
push ecx
jne 0x4b17bd
mov dword [esp + 4], 0
mov dword [esp], 0x569040
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push edx
push edx
mov dword [esp], 0x569040
mov ecx, dword [ebp + 8]
call fcn.004c639a
push eax
jmp 0x4b17d7
mov ecx, dword [ebp + 8]
call fcn.004c62d0
mov ecx, ebx
call fcn.004c616a
mov eax, dword [ebp + 8]
mov ebx, dword [ebp - 4]
leave
ret
Function at 0x4b1848
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
lea edi, [ebp - 0x28]
push ebx
sub esp, 0x4c
mov dword [esp], 0xfffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
mov ebx, eax
lea eax, [ebp - 0x2c]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edi
mov dword [esp + 8], 4
mov dword [esp + 4], eax
mov dword [esp], ebx
call esi
sub esp, 0x14
test eax, eax
jne 0x4b18bb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 4], str.read_len_failed
mov dword [esp], 0x5694e0
mov ebx, eax
call fcn.004c8905
mov dword [esp + 4], ebx
mov dword [esp], eax
call fcn.004c8a58
jmp 0x4b18d5
cmp dword [ebp - 0x28], 3
ja 0x4b18ea
mov dword [esp + 4], str.bad_read_len
mov dword [esp], 0x5694e0
call fcn.004c8905
mov dword [esp], eax
call fcn.004c8cf3
mov ecx, dword [ebp + 8]
call fcn.00427ac0
jmp 0x4b19be
lea ecx, [ebp - 0x20]
call fcn.004c7198
lea eax, [ebp - 0x24]
lea ecx, [ebp - 0x20]
mov byte [ebp - 0x24], 0
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp], eax
call fcn.004c7482
mov eax, dword [ebp - 0x2c]
push ecx
push ecx
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x20]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edi
mov dword [esp + 4], eax
mov dword [esp], ebx
call esi
sub esp, 0x14
test eax, eax
jne 0x4b195d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 4], str.read_msg_failed
mov dword [esp], 0x5694e0
mov ebx, eax
call fcn.004c8905
mov dword [esp + 4], ebx
mov dword [esp], eax
call fcn.004c8a58
jmp 0x4b1979
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x28], eax
jae 0x4b198b
mov dword [esp + 4], str.read_trimmed_msg
mov dword [esp], 0x5694e0
call fcn.004c8905
mov dword [esp], eax
call fcn.004c8cf3
mov ecx, dword [ebp + 8]
call fcn.00427ac0
jmp 0x4b19b6
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x20]
lea ecx, [ebp - 0x24]
mov dword [esp], eax
call fcn.0042987e
mov ecx, dword [ebp + 8]
push eax
push eax
lea eax, [ebp - 0x24]
mov dword [esp], eax
call fcn.00428e76
lea ecx, [ebp - 0x24]
push edx
call fcn.0042851a
lea ecx, [ebp - 0x20]
call fcn.004c71a6
mov eax, dword [ebp + 8]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4b97e8
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, ecx
lea edi, [ebp - 0x38]
push ebx
mov ebx, edx
mov edx, eax
lea eax, [ebp - 0x48]
sub esp, 0x5c
call fcn.004b97a4
lea eax, [ebp - 0x48]
mov edx, esi
call fcn.004b97d1
lea eax, [esi + 0x10]
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x5c], eax
mov ecx, eax
lea eax, [ebx - 1]
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x48]
movzx edx, byte [eax]
inc eax
mov dl, byte [edx + str.cw]
mov byte [eax - 1], dl
cmp edi, eax
jne 0x4b9824
mov eax, dword [ebp - 0x44]
mov ebx, dword [ebp - 0x48]
mov esi, dword [ebp - 0x58]
ror eax, 8
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x40]
rol eax, 0x10
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x3c]
rol eax, 8
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x60], esi
je 0x4b98f7
xor esi, esi
mov eax, dword [edi + esi*4]
and eax, 0x80808080
mov edx, eax
shr edx, 7
sub eax, edx
mov edx, dword [edi + esi*4]
and eax, 0x1b1b1b1b
add edx, edx
and edx, 0xfefefefe
xor eax, edx
mov dword [ebp + esi*4 - 0x28], eax
inc esi
cmp esi, 4
jne 0x4b986d
mov edx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x28]
add ecx, 0x10
mov esi, dword [ebp - 0x20]
inc dword [ebp - 0x58]
xor eax, edx
xor eax, dword [ebp - 0x4c]
xor eax, dword [ebp - 0x50]
xor eax, dword [ebp - 0x54]
xor eax, dword [ecx - 0x10]
mov dword [ebp - 0x48], eax
mov eax, edx
mov edx, dword [ebp - 0x1c]
xor eax, ebx
xor eax, esi
xor eax, dword [ebp - 0x50]
xor eax, dword [ebp - 0x54]
xor eax, dword [ecx - 0xc]
mov dword [ebp - 0x44], eax
mov eax, esi
xor eax, ebx
xor eax, edx
xor eax, dword [ebp - 0x4c]
xor eax, dword [ebp - 0x54]
xor eax, dword [ecx - 8]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x28]
xor eax, ebx
xor eax, edx
xor eax, dword [ebp - 0x4c]
xor eax, dword [ebp - 0x50]
xor eax, dword [ecx - 4]
mov dword [ebp - 0x3c], eax
jmp 0x4b9821
mov ebx, dword [ebp - 0x60]
mov edx, dword [ebp - 0x5c]
lea eax, [ebp - 0x38]
shl ebx, 4
add edx, ebx
call fcn.004b97d1
mov eax, dword [ebp + 8]
lea edx, [ebp - 0x38]
call fcn.004b97a4
add esp, 0x5c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4b991d
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x7c
cmp byte [0x569360], 0
mov dword [ebp - 0x84], edx
jne 0x4b994d
xor edx, edx
movzx ebx, byte [edx + str.cw]
mov byte [ebx + 0x569360], dl
inc edx
cmp edx, 0x100
jne 0x4b9937
mov ebx, dword [ebp - 0x84]
mov edx, eax
lea eax, [ebp - 0x78]
shl ebx, 4
add ebx, ecx
call fcn.004b97a4
lea eax, [ebp - 0x78]
mov edx, ebx
call fcn.004b97d1
lea eax, [ebx - 0x10]
mov dword [ebp - 0x80], 0
mov dword [ebp - 0x7c], eax
lea edx, [ebp - 0x78]
movzx eax, byte [edx]
inc edx
mov al, byte [eax + 0x569360]
mov byte [edx - 1], al
lea eax, [ebp - 0x68]
cmp eax, edx
jne 0x4b997c
mov eax, dword [ebp - 0x78]
mov edx, dword [ebp - 0x7c]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x74]
rol eax, 8
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x70]
rol eax, 0x10
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x6c]
ror eax, 8
mov dword [ebp - 0x5c], eax
lea eax, [ebp - 0x68]
call fcn.004b97d1
mov eax, dword [ebp - 0x84]
sub dword [ebp - 0x7c], 0x10
dec eax
cmp eax, dword [ebp - 0x80]
je 0x4b9aa6
lea ecx, [ebp - 0x58]
xor edx, edx
mov eax, dword [ebp + edx*4 - 0x68]
mov ebx, ecx
mov esi, 1
mov dword [ecx], eax
mov eax, dword [ebx]
inc esi
add ebx, 0x10
and eax, 0x80808080
mov edi, eax
shr edi, 7
sub eax, edi
mov edi, dword [ebx - 0x10]
and eax, 0x1b1b1b1b
add edi, edi
and edi, 0xfefefefe
xor eax, edi
mov dword [ebx], eax
cmp esi, 4
jne 0x4b99e2
inc edx
add ecx, 4
cmp edx, 4
jne 0x4b99d5
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x48]
xor eax, dword [ebp - 0x24]
xor eax, dword [ebp - 0x44]
xor eax, dword [ebp - 0x54]
xor eax, dword [ebp - 0x50]
mov esi, dword [ebp - 0x28]
xor eax, edi
xor esi, dword [ebp - 0x38]
xor eax, dword [ebp - 0x4c]
mov ebx, dword [ebp - 0x20]
xor eax, esi
xor ebx, dword [ebp - 0x30]
mov edx, dword [ebp - 0x2c]
xor eax, ebx
mov ecx, dword [ebp - 0x24]
xor ecx, dword [ebp - 0x34]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x28]
xor edx, edi
xor eax, dword [ebp - 0x44]
xor eax, dword [ebp - 0x20]
xor eax, dword [ebp - 0x50]
xor eax, dword [ebp - 0x4c]
xor eax, dword [ebp - 0x58]
xor eax, dword [ebp - 0x40]
xor eax, ecx
xor eax, edx
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x24]
xor eax, dword [ebp - 0x54]
xor eax, edi
xor eax, dword [ebp - 0x4c]
xor eax, dword [ebp - 0x58]
xor eax, dword [ebp - 0x40]
xor eax, dword [ebp - 0x3c]
xor eax, esi
xor eax, ebx
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x28]
xor eax, dword [ebp - 0x48]
xor eax, dword [ebp - 0x54]
xor eax, dword [ebp - 0x20]
xor eax, dword [ebp - 0x50]
xor eax, dword [ebp - 0x58]
xor eax, dword [ebp - 0x3c]
xor ecx, eax
inc dword [ebp - 0x80]
xor edx, ecx
mov dword [ebp - 0x6c], edx
jmp 0x4b9979
mov eax, dword [ebp + 8]
lea edx, [ebp - 0x68]
call fcn.004b97a4
add esp, 0x7c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4b9b7a
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x12c
mov dword [ebp - 0x12c], ecx
mov dword [ebp - 0x128], edx
xor edx, edx
mov ecx, dword [eax + edx*4]
mov dword [ebp - 0x124], edx
mov dword [ebp + edx*4 - 0x108], ecx
inc edx
cmp dword [ebp + 8], edx
jne 0x4b9b94
lea eax, [ebp - 0x108]
mov ebx, edx
mov esi, 0x52ca80
mov dword [ebp - 0x11c], 0
mov dword [ebp - 0x120], eax
mov eax, dword [ebp + ebx*4 - 0x10c]
cmp dword [ebp - 0x11c], 0
mov dword [ebp - 0x10c], eax
jne 0x4b9c30
ror eax, 8
inc esi
movzx edi, al
mov cl, byte [edi + str.cw]
movzx edi, ah
mov byte [ebp - 0x10c], cl
mov cl, byte [edi + str.cw]
mov edi, eax
shr eax, 0x18
shr edi, 0x10
mov al, byte [eax + str.cw]
mov byte [ebp - 0x10b], cl
mov ecx, edi
movzx edi, cl
mov byte [ebp - 0x109], al
movzx eax, byte [esi - 1]
mov cl, byte [edi + str.cw]
mov byte [ebp - 0x10a], cl
xor dword [ebp - 0x10c], eax
jmp 0x4b9c81
cmp dword [ebp - 0x11c], 4
jne 0x4b9c81
cmp edx, 8
jne 0x4b9c81
movzx edi, al
mov cl, byte [edi + str.cw]
movzx edi, ah
mov byte [ebp - 0x10c], cl
mov cl, byte [edi + str.cw]
mov edi, eax
shr eax, 0x18
shr edi, 0x10
mov al, byte [eax + str.cw]
mov byte [ebp - 0x10b], cl
mov ecx, edi
movzx edi, cl
mov byte [ebp - 0x109], al
mov cl, byte [edi + str.cw]
mov byte [ebp - 0x10a], cl
mov eax, dword [ebp - 0x120]
mov ecx, dword [ebp - 0x11c]
mov eax, dword [eax]
xor eax, dword [ebp - 0x10c]
mov dword [ebp + ebx*4 - 0x108], eax
mov eax, dword [ebp - 0x11c]
inc eax
cmp dword [ebp - 0x124], ecx
mov ecx, 0
cmovne ecx, eax
add dword [ebp - 0x120], 4
inc ebx
mov dword [ebp - 0x11c], ecx
cmp dword [ebp - 0x12c], ebx
jne 0x4b9bc7
xor esi, esi
lea eax, [esi*4]
lea edx, [ebp - 0x108]
add esi, 4
add edx, eax
add eax, dword [ebp - 0x128]
call fcn.004b97a4
cmp ebx, esi
ja 0x4b9ccd
add esp, 0x12c
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x4b9db6
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov eax, 0x3020100
mov ebp, esp
push edi
push esi
push ebx
push edx
mov edx, ecx
mov dword [edx], eax
add eax, 0x4040404
add edx, 4
cmp eax, 0x4030200
jne 0x4b9dc4
xor eax, eax
xor edx, edx
xor esi, esi
mov bl, byte [ecx + eax]
mov edi, dword [ebp + 8]
mov byte [ebp - 0xd], bl
movzx ebx, byte [edi + edx]
inc edx
movzx edi, byte [ebp - 0xd]
add ebx, edi
add ebx, esi
movzx esi, bl
cmp edx, dword [ebp + 0xc]
jne 0x4b9dfb
xor edx, edx
mov bl, byte [ecx + esi]
mov byte [ecx + eax], bl
mov bl, byte [ebp - 0xd]
inc eax
mov byte [ecx + esi], bl
cmp eax, 0x100
jne 0x4b9ddb
mov dword [ecx + 0x100], 1
mov dword [ecx + 0x104], 0
pop eax
pop ebx
pop esi
pop edi
pop ebp
ret 8
Function at 0x4bbebe
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x4c
cmp dword [0x569460], 0
mov dword [ebp - 0x38], ecx
jne 0x4bbf8c
mov dword [esp], 0x40
call sub.msvcrt.dll_malloc
xor edx, edx
mov dword [0x569464], eax
movzx ecx, byte [edx + 0x52cec0]
mov byte [eax + ecx], dl
inc edx
cmp edx, 0x40
jne 0x4bbeea
mov dword [esp], 0x800
xor ebx, ebx
call sub.msvcrt.dll_malloc
mov dword [0x569460], eax
mov edx, ebx
lea edi, [ebx*8]
lea esi, [ebx*4]
shl edx, 8
mov dword [ebp - 0x3c], edi
mov dword [ebp - 0x30], esi
lea esi, [eax + edx]
mov dword [ebp - 0x34], esi
xor esi, esi
mov edx, esi
mov ecx, esi
xor edi, edi
shr edx, 3
add edx, dword [ebp - 0x3c]
and ecx, 7
mov edx, dword [edx*4 + 0x52cda0]
shl ecx, 2
shr edx, cl
mov cl, byte [ebp - 0x30]
and edx, 0xf
shl edx, cl
mov dword [ebp - 0x2c], edx
xor edx, edx
lea ecx, [edx + edx]
mov edx, dword [ebp - 0x2c]
inc edi
mov dword [ebp - 0x40], ecx
movzx ecx, byte [edi + 0x52ce9f]
shr edx, cl
mov ecx, edx
mov edx, dword [ebp - 0x40]
and ecx, 1
or edx, ecx
cmp edi, 0x20
jne 0x4bbf56
mov edi, dword [ebp - 0x34]
rol edx, 1
mov dword [edi + esi*4], edx
inc esi
cmp esi, 0x40
jne 0x4bbf2e
inc ebx
cmp ebx, 8
jne 0x4bbf0d
mov eax, dword [ebp + 8]
mov ecx, 0x52cec0
mov edx, 0x20
xor esi, esi
call fcn.004bbe8b
mov edx, 0x20
mov ecx, 0x52cee0
rol eax, 1
mov ebx, eax
mov eax, dword [ebp + 8]
call fcn.004bbe8b
rol eax, 1
mov edx, eax
mov eax, dword [0x569460]
mov dword [ebp - 0x30], eax
lea eax, [esi + esi]
mov dword [ebp - 0x2c], ebx
xor ebx, ebx
mov dword [ebp - 0x3c], eax
mov ecx, ebx
mov eax, dword [ebp - 0x38]
mov edi, ebx
shl ecx, 8
add ecx, dword [ebp - 0x30]
shr edi, 2
add edi, dword [ebp - 0x3c]
mov dword [ebp - 0x34], ecx
mov ecx, ebx
mov edi, dword [eax + edi*4 + 4]
mov eax, edx
and ecx, 3
imul ecx, ecx, 6
shr edi, cl
lea ecx, [ebx*4]
inc ebx
ror eax, cl
xor edi, eax
mov eax, dword [ebp - 0x34]
and edi, 0x3f
mov eax, dword [eax + edi*4]
xor dword [ebp - 0x2c], eax
cmp ebx, 8
jne 0x4bbfcd
inc esi
mov ebx, edx
cmp esi, 0x10
je 0x4bc01d
mov edx, dword [ebp - 0x2c]
jmp 0x4bbfc2
mov eax, dword [ebp - 0x2c]
ror eax, 1
call fcn.004bbe88
mov dword [ebp - 0x20], eax
mov eax, edx
ror eax, 1
call fcn.004bbe88
mov ebx, dword [0x569464]
mov edx, 0x20
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x20]
mov ecx, ebx
call fcn.004bbe8b
lea ecx, [ebx + 0x20]
mov edx, 0x20
mov esi, eax
lea eax, [ebp - 0x20]
call fcn.004bbe8b
mov edx, eax
mov eax, esi
call fcn.004bbe88
mov esi, dword [ebp + 0xc]
mov dword [esi], eax
mov eax, edx
call fcn.004bbe88
mov dword [esi + 4], eax
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret 8
Function at 0x4c98c8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, 1
push esi
push ebx
sub esp, 0x3c
mov eax, dword [ecx + 0x10]
mov esi, dword [ecx + 0x14]
sub esi, eax
je 0x4c991e
mov dword [esp + 4], eax
mov eax, dword [ecx + 0x11c]
lea edx, [ebp - 0x1c]
mov ebx, ecx
mov dword [ebp - 0x1c], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edx
mov dword [esp + 8], esi
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub esp, 0x14
cmp dword [ebp - 0x1c], esi
je 0x4c991b
xor edi, edi
jmp 0x4c991e
sub dword [ebx + 0x14], esi
lea esp, [ebp - 0xc]
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x4cabb0
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp], 2
lea ebx, [esp + 0x24]
call fcn.004cc800
mov dword [esp + 8], 0x1b
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], str.Mingw_w64_runtime_failure:_n
call sub.msvcrt.dll_fwrite
mov dword [esp], 2
call fcn.004cc800
mov edx, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], edx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
lea esi, [esi]

Function at 0x4cac10
Capabilities:
Allocate or change rwx memory

Disassembly:
push edi
push esi
push ebx
mov ebx, eax
sub esp, 0x30
mov esi, dword [0x5698a0]
test esi, esi
jle 0x4cad10
mov eax, dword [0x5698a4]
xor ecx, ecx
add eax, 0xc
mov edx, dword [eax]
cmp edx, ebx
ja 0x4cac40
mov edi, dword [eax + 4]
add edx, dword [edi + 8]
cmp ebx, edx
jb 0x4cacbf
add ecx, 1
add eax, 0x14
cmp ecx, esi
jne 0x4cac30
mov dword [esp], ebx
call fcn.004cb510
mov edi, eax
test eax, eax
je 0x4cad37
mov eax, dword [0x5698a4]
lea ebx, [esi + esi*4]
shl ebx, 2
add eax, ebx
mov dword [eax + 0x10], edi
mov dword [eax], 0
call fcn.004cb620
mov edx, dword [0x5698a4]
add eax, dword [edi + 0xc]
mov dword [edx + ebx + 0xc], eax
lea edx, [esp + 0x14]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
sub esp, 0xc
test eax, eax
je 0x4cad17
mov eax, dword [esp + 0x28]
lea edx, [eax - 0x40]
and edx, 0xffffffbf
je 0x4cacb8
sub eax, 4
and eax, 0xfffffffb
jne 0x4cacc6
add dword [0x5698a0], 1
add esp, 0x30
pop ebx
pop esi
pop edi
ret
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
add ebx, dword [0x5698a4]
mov dword [ebx + 4], eax
mov dword [ebx + 8], edx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x40
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
test eax, eax
jne 0x4cacb8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp], str.__VirtualProtect_failed_with_code_0x_x
mov dword [esp + 4], eax
call fcn.004cabb0
xor esi, esi
jmp 0x4cac4a
mov eax, dword [0x5698a4]
mov eax, dword [eax + ebx + 0xc]
mov dword [esp + 8], eax
mov eax, dword [edi + 8]
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov dword [esp + 4], eax
call fcn.004cabb0
mov dword [esp + 4], ebx
mov dword [esp], str.Address__p_has_no_image_section
call fcn.004cabb0
lea esi, [esi]
nop
Function at 0x4cb180
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x5698b8
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x5698b0]
sub esp, 4
test ebx, ebx
je 0x4cb1d5
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x4cb1ce
test esi, esi
je 0x4cb1ce
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x4cb1b0
mov dword [esp], 0x5698b8
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4ebe24
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov eax, dword [0x568820]
mov dword [esp + 8], 0x52912a
mov dword [esp + 4], 0x66
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_FindResourceA]
sub esp, 0xc
mov ebx, eax
mov dword [esp + 4], eax
mov eax, dword [0x568820]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
push edx
mov esi, eax
mov eax, dword [0x568820]
push edx
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push ecx
mov ebx, eax
push ecx
mov dword [esp], esi
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
lea esi, [ebp - 0x20]
mov ecx, esi
mov dword [esp], eax
mov dword [esp + 4], ebx
call fcn.004c638a
push edi
push edi
lea edi, [ebp - 0x1c]
mov ecx, edi
mov dword [esp], str.RouterOS_Credits
call fcn.004c639a
push eax
mov dword [esp + 4], esi
mov dword [esp], edi
call sym.winbox.exe_createBigMessageBox_string_const__string_const_
mov ebx, eax
test eax, eax
je 0x4ebec7
mov eax, dword [eax]
mov edx, dword [eax - 0xc]
add edx, ebx
inc dword [edx + 4]
mov ecx, edi
call fcn.004c616a
mov ecx, esi
call fcn.004c616a
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x18]
mov eax, dword [ebx]
mov ecx, dword [eax - 0xc]
add ecx, ebx
call fcn.00509740
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4ec0c8
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
lea ebx, [ebp - 0x20]
sub esp, 0x4c
mov dword [ebp - 0x3c], ecx
mov ecx, ebx
call fcn.004c706c
mov eax, dword [ebp - 0x3c]
mov dword [esp + 4], ebx
lea edi, [eax + 0xf8]
mov dword [esp], edi
call fcn.004a877f
mov eax, dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x20]
mov dword [ebp - 0x40], eax
cmp ebx, dword [ebp - 0x40]
je 0x4ec1b2
mov dword [esp + 4], str..viw
mov dword [esp], ebx
call fcn.004b150e
test al, al
je 0x4ec1aa
mov edx, str.settings.cfg.viw
mov eax, ebx
call fcn.004b0854
test al, al
jne 0x4ec1aa
mov edx, dword [ebp + 8]
mov ecx, 0x528d60
lea eax, [ebp - 0x28]
call fcn.004b078e
mov ecx, ebx
lea edx, [ebp - 0x28]
lea eax, [ebp - 0x24]
call fcn.004b086c
mov eax, dword [ebp - 0x24]
mov ecx, 0x528d60
mov edx, edi
lea esi, [eax + 4]
lea eax, [ebp - 0x30]
call fcn.004b078e
lea edx, [ebp - 0x30]
mov ecx, ebx
lea eax, [ebp - 0x2c]
call fcn.004b086c
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], esi
mov dword [esp + 8], 3
add eax, 4
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
lea ecx, [ebp - 0x2c]
sub esp, 0xc
call fcn.004c616a
lea ecx, [ebp - 0x30]
call fcn.004c616a
lea ecx, [ebp - 0x24]
call fcn.004c616a
lea ecx, [ebp - 0x28]
call fcn.004c616a
add ebx, 4
jmp 0x4ec0fc
lea ecx, [ebp - 0x24]
mov dword [esp], ecx
call fcn.004b1817
mov eax, dword [ebp - 0x24]
mov dword [esp + 4], 0x52924d
add eax, 4
mov dword [esp], eax
call sub.msvcrt.dll_fopen
lea ecx, [ebp - 0x24]
mov ebx, eax
call fcn.004c616a
test ebx, ebx
je 0x4ec20c
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x3c]
mov dword [esp], eax
call fcn.004edc44
push eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], ebx
mov eax, dword [eax]
add eax, 4
mov dword [esp], eax
call sub.msvcrt.dll_fputs
mov dword [esp], ebx
call sub.msvcrt.dll_fclose
lea ecx, [ebp - 0x20]
call fcn.004b1d68
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 4
Function at 0x4ef1d4
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
lea esi, [ebp - 0x2c]
lea edi, [ebp - 0x28]
push ebx
lea ebx, [ecx + 0xdc]
sub esp, 0x5c
mov dword [ebp - 0x3c], ecx
lea ecx, [ebp - 0x1c]
call fcn.004c62d0
lea eax, [ebp - 0x1c]
mov dword [esp], ebx
mov ecx, esi
mov dword [esp + 8], eax
mov dword [esp + 4], 0x200003f0
call fcn.0042776a
lea ecx, [ebp - 0x1c]
sub esp, 0xc
call fcn.004c616a
lea ecx, [ebp - 0x1c]
call fcn.004c62d0
lea eax, [ebp - 0x1c]
mov dword [esp], ebx
mov ecx, edi
mov dword [esp + 8], eax
mov dword [esp + 4], 0x200003ef
call fcn.0042776a
lea ecx, [ebp - 0x1c]
sub esp, 0xc
call fcn.004c616a
mov eax, dword [ebp - 0x28]
cmp dword [eax], 0
je 0x4ef262
mov dword [esp + 4], esi
mov ecx, dword [ebp - 0x3c]
mov dword [esp], edi
call fcn.004ee89c
push ebx
push ebx
jmp 0x4ef369
lea eax, [ebp - 0x1c]
lea ebx, [ebp - 0x24]
mov dword [esp], eax
call fcn.004b17e6
mov eax, ebx
lea edx, [ebp - 0x1c]
call fcn.004b0c53
lea ecx, [ebp - 0x1c]
call fcn.004c616a
mov eax, dword [ebp - 0x24]
cmp dword [eax], 0
jne 0x4ef2c1
lea edi, [ebp - 0x20]
mov dword [esp], edi
call fcn.004a8627
mov edx, edi
mov ecx, str.Addresses.cdb
lea eax, [ebp - 0x1c]
call fcn.004b078e
lea eax, [ebp - 0x1c]
mov ecx, ebx
mov dword [esp], eax
call fcn.004c66f8
push ecx
lea ecx, [ebp - 0x1c]
call fcn.004c616a
mov ecx, edi
call fcn.004c616a
mov dword [esp + 4], esi
mov ecx, dword [ebp - 0x3c]
mov dword [esp], ebx
call fcn.004ee89c
mov eax, dword [ebp - 0x24]
push edx
push edx
add eax, 4
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], pe_nt_image_headers32
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
sub esp, 0x1c
cmp eax, 0xffffffff
jne 0x4ef357
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x4ef361
lea ebx, [ebp - 0x20]
mov dword [esp], ebx
call fcn.004a8627
mov edx, ebx
mov ecx, str.winbox.cfg
lea eax, [ebp - 0x1c]
call fcn.004b078e
lea eax, [ebp - 0x1c]
call fcn.004b0b9e
lea ecx, [ebp - 0x1c]
call fcn.004c616a
mov ecx, ebx
call fcn.004c616a
jmp 0x4ef361
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
lea ecx, [ebp - 0x24]
call fcn.004c616a
lea ecx, [ebp - 0x28]
call fcn.004c616a
lea ecx, [ebp - 0x2c]
call fcn.004c616a
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret