joyce8/EMBER2024-capa huggingface dataset:
Function at 0x473710
Capabilities:
Create a process with modified i/o handles and window
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x78
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, dword [eax]
cmp esi, 0xffffffff
je 0x4737df
mov edi, dword [edi]
cmp edi, 0xffffffff
je 0x4737df
push 0x44
lea eax, [ebp - 0x78]
xorps xmm0, xmm0
push 0
push eax
movups xmmword [ebp - 0x30], xmm0
call fcn.004a83c0
movups xmm0, xmmword [str.ipconfig__all]
add esp, 0xc
or dword [ebp - 0x4c], 0x101
xor eax, eax
mov dword [ebp - 0x78], 0x44
mov word [ebp - 0x48], ax
mov eax, dword [0x4fa1fc]
mov dword [ebp - 8], eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x78]
mov dword [ebp - 0x38], esi
push eax
push 0
push 0
push 0x8000000
push 1
push 0
push 0
lea eax, [ebp - 0x20]
mov dword [ebp - 0x3c], esi
movups xmmword [ebp - 0x20], xmm0
push eax
movq xmm0, qword [0x4fa1f4]
push 0
mov dword [ebp - 0x40], edi
movq qword [ebp - 0x10], xmm0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
mov edi, eax
test edi, edi
je 0x4737df
push dword [ebp - 0x30]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x2c]
call esi
mov eax, edi
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
xor ecx, ebp
pop esi
call fcn.004a578d
mov esp, ebp
pop ebp
ret 8
Function at 0x475750
Capabilities:
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xd40
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
xor bl, bl
mov dword [ebp - 0xd3c], edx
push edi
mov dword [ebp - 0xd38], ecx
xor esi, esi
mov dword [ebp - 0xd40], eax
nop
test bl, bl
jne 0x4759e4
push 0x200
lea eax, [ebp - 0x50c]
push 0
push eax
call fcn.004a83c0
add esp, 0xc
lea eax, [ebp - 0x50c]
push esi
push 0x4fa3f0
push 0xffffffffffffffff
push 0xff
push eax
call fcn.00456200
add esp, 0x14
lea eax, [ebp - 0x50c]
push 0
push 0
push 3
push 0
push 3
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4759da
push 0x800
xorps xmm0, xmm0
mov dword [ebp - 0xd34], 0
lea eax, [ebp - 0xd0c]
movq qword [ebp - 0xd30], xmm0
push 0
push eax
mov dword [ebp - 0xd28], 0
mov dword [ebp - 0xd30], 0
mov dword [ebp - 0xd2c], 0
call fcn.004a83c0
add esp, 0xc
lea eax, [ebp - 0xd34]
push 0
push eax
push 0x800
lea eax, [ebp - 0xd0c]
push eax
push 0xc
lea eax, [ebp - 0xd30]
push eax
push 0x2d1400
push edi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4759cd
push 0x100
lea eax, [ebp - 0x10c]
push 0
push eax
call fcn.004a83c0
add esp, 0xc
lea eax, [ebp - 0x20c]
push 0x100
push 0
push eax
call fcn.004a83c0
add esp, 0xc
lea eax, [ebp - 0x30c]
push 0x100
push 0
push eax
call fcn.004a83c0
mov edx, dword [ebp - 0xcfc]
lea eax, [ebp - 0x20c]
add esp, 0xc
lea ecx, [ebp - 0xd0c]
push eax
push 0
call fcn.00475170
mov edx, dword [ebp - 0xcf8]
lea eax, [ebp - 0x30c]
push eax
push 0
lea ecx, [ebp - 0xd0c]
call fcn.00475170
mov edx, dword [ebp - 0xcf4]
lea eax, [ebp - 0x10c]
push eax
push 1
lea ecx, [ebp - 0xd0c]
call fcn.00475170
movsx eax, byte [ebp - 0x10c]
push eax
call fcn.004bb490
add esp, 0x1c
test eax, eax
jne 0x475915
movsx eax, byte [ebp - 0xf9]
push eax
call fcn.004bb490
add esp, 4
test eax, eax
je 0x4759d3
lea eax, [ebp - 0x10c]
push eax
lea ecx, [ebp - 0xd24]
call fcn.004387d0
mov ecx, dword [ebp - 0xd38]
push eax
call fcn.0046f7a0
mov eax, dword [ebp - 0xd10]
cmp eax, 0x10
jb 0x475951
inc eax
lea ecx, [ebp - 0xd24]
push eax
push dword [ebp - 0xd24]
call fcn.00433760
lea eax, [ebp - 0x20c]
push eax
lea ecx, [ebp - 0xd24]
call fcn.004387d0
mov ecx, dword [ebp - 0xd3c]
push eax
call fcn.0046f7a0
mov eax, dword [ebp - 0xd10]
cmp eax, 0x10
jb 0x47598d
inc eax
lea ecx, [ebp - 0xd24]
push eax
push dword [ebp - 0xd24]
call fcn.00433760
lea eax, [ebp - 0x30c]
push eax
lea ecx, [ebp - 0xd24]
call fcn.004387d0
mov ecx, dword [ebp - 0xd40]
push eax
call fcn.0046f7a0
mov eax, dword [ebp - 0xd10]
cmp eax, 0x10
jb 0x4759c9
inc eax
lea ecx, [ebp - 0xd24]
push eax
push dword [ebp - 0xd24]
call fcn.00433760
mov bl, 1
jmp 0x4759d3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, 0x10
jl 0x475780
mov ecx, dword [ebp - 8]
mov al, bl
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x4762e0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x11c
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [ebp - 0x11c]
push edi
push eax
push 0x20019
push 0
push str.SystemCurrentControlSetControlNetwork4D36E972_E325_11CE_BFC1_08002BE10318
push reloc.OLEAUT32.dll_SysReAllocString
mov edi, ecx
mov dword [ebp - 0x10c], 0x104
mov ebx, 3
mov dword [ebp - 0x110], 1
mov dword [ebp - 0x11c], 0
mov dword [ebp - 0x118], 0
mov dword [ebp - 0x114], 0
call esi
test eax, eax
jne 0x4764ae
push edi
push str._sConnection
push 0xffffffffffffffff
lea eax, [ebp - 0x108]
push 0x103
push eax
call fcn.0046c070
add esp, 0x14
lea eax, [ebp - 0x118]
push eax
push 0x20019
push 0
lea eax, [ebp - 0x108]
push eax
push dword [ebp - 0x11c]
call esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
jne 0x4764a6
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x114]
mov dword [ebp - 0x110], 4
push eax
lea eax, [ebp - 0x110]
mov dword [ebp - 0x10c], 4
push eax
push 0
push str.MediaSubType
push dword [ebp - 0x118]
call edi
test eax, eax
jne 0x47649e
push 0x104
push eax
lea eax, [ebp - 0x108]
mov dword [ebp - 0x110], 1
push eax
mov dword [ebp - 0x10c], 0x103
call fcn.004a83c0
add esp, 0xc
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x110]
push eax
push 0
push str.PnpInstanceID
push dword [ebp - 0x118]
call edi
test eax, eax
jne 0x47649e
mov eax, dword [ebp - 0x114]
cmp eax, 1
jne 0x47648f
push ebx
lea eax, [ebp - 0x108]
push 0x4fa4f8
push eax
call fcn.004bbf50
add esp, 0xc
test eax, eax
jne 0x47645d
xor ebx, ebx
jmp 0x47649e
mov eax, dword [ebp - 0x114]
cmp eax, 1
jne 0x47648f
push 3
lea eax, [ebp - 0x108]
push 0x4fa4f8
push eax
call fcn.004bbf50
add esp, 0xc
test eax, eax
je 0x476489
mov ebx, 2
jmp 0x47649e
mov eax, dword [ebp - 0x114]
xor ebx, ebx
cmp eax, 2
setne bl
lea ebx, [ebx*2 + 1]
push dword [ebp - 0x118]
call esi
push dword [ebp - 0x11c]
call esi
mov eax, ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a578d
mov esp, ebp
pop ebp
ret

Function at 0x4765b0
Capabilities:
Hash data with md5

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x68
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 8], eax
push esi
mov esi, dword [ebp + 8]
test ecx, ecx
je 0x476623
test edx, edx
jle 0x476623
test esi, esi
je 0x476623
push edx
mov edx, ecx
mov dword [ebp - 0x50], 0
lea ecx, [ebp - 0x64]
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x64], 0x67452301
mov dword [ebp - 0x60], 0xefcdab89
mov dword [ebp - 0x5c], 0x98badcfe
mov dword [ebp - 0x58], 0x10325476
call fcn.00476900
add esp, 4
lea edx, [ebp - 0x64]
mov ecx, esi
call fcn.004769d0
mov al, 1
pop esi
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 8]
xor al, al
xor ecx, ebp
pop esi
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x476710
Capabilities:
Hash data with md5
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d993b
mov eax, dword fs:[0]
push eax
mov eax, 0x217c
call fcn.004a6780
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x2180], edx
xor ebx, ebx
mov dword [ebp - 0x2188], ebx
mov dword [ebp - 0x2184], ebx
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocString
push ecx
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
jne 0x476785
call fcn.00433120
test eax, eax
jns 0x47678d
xor eax, eax
jmp 0x4768e2
mov ebx, eax
mov dword [ebp - 0x2188], ebx
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
xorps xmm0, xmm0
mov byte [ebp - 0x20], 0
movq qword [ebp - 0x1f], xmm0
mov dword [ebp - 0x17], 0
mov word [ebp - 0x13], 0
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x2164], 0
mov dword [ebp - 0x2168], 0
mov dword [ebp - 0x2178], 0x67452301
mov dword [ebp - 0x2174], 0xefcdab89
mov dword [ebp - 0x2170], 0x98badcfe
mov dword [ebp - 0x216c], 0x10325476
nop dword [eax]
push 0
lea eax, [ebp - 0x217c]
mov dword [ebp - 0x217c], 0
push eax
push 0x2000
lea eax, [ebp - 0x2120]
push eax
push ebx
call esi
test eax, eax
jne 0x47681b
call fcn.00433120
mov eax, dword [ebp - 0x217c]
test eax, eax
je 0x47683c
push eax
lea edx, [ebp - 0x2120]
lea ecx, [ebp - 0x2178]
call fcn.00476900
add esp, 4
jmp 0x4767f0
test ebx, ebx
je 0x47684f
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
mov dword [ebp - 0x2188], ebx
lea edx, [ebp - 0x2178]
lea ecx, [ebp - 0x20]
call fcn.004769d0
push 0x100
lea eax, [ebp - 0x120]
push 0
push eax
call fcn.004a83c0
add esp, 0xc
lea edi, [ebp - 0x120]
xor esi, esi
nop dword [eax + eax]
movzx eax, byte [ebp + esi - 0x20]
push eax
push str._.2x
push 0xffffffffffffffff
push 3
push edi
call fcn.00456200
inc esi
add esp, 0x14
add edi, 4
cmp esi, 0x10
jb 0x476880
lea edx, [ebp - 0x120]
lea esi, [edx + 2]
nop word [eax + eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x4768b0
mov ecx, dword [ebp - 0x2180]
lea eax, [ebp - 0x120]
sub edx, esi
sar edx, 1
push edx
push eax
call fcn.0041ccd0
test ebx, ebx
je 0x4768dd
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x4773a0
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, edx
test ecx, ecx
je 0x47747d
xor eax, eax
cmp ax, word [ecx]
je 0x47747d
cmp dword [esi], eax
jne 0x47747d
push ebx
push 0
push 0x80
push 3
push 0
mov dword [esi], eax
mov eax, dword [ebp + 8]
push 1
push SysReAllocString
push ecx
mov dword [eax], 0
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4773f6
pop ebx
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
push edi
push 0
push ebx
mov dword [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
test edi, edi
je 0x477457
cmp edi, 0xffffffff
je 0x477457
push 0x5142bc
push edi
call fcn.004a600d
add esp, 8
mov dword [esi], eax
test eax, eax
je 0x477457
push 0
push dword [ebp + 8]
push edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x477457
mov eax, dword [ebp + 8]
cmp dword [eax], edi
jne 0x477457
push ebx
mov dword [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 4]
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [esi]
test eax, eax
je 0x477466
push eax
call fcn.004a5802
add esp, 4
push ebx
mov dword [esi], 0
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 4]
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x477490
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, edx
push esi
test ecx, ecx
je 0x47751b
xor eax, eax
cmp ax, word [ecx]
je 0x47751b
test ebx, ebx
je 0x47751b
mov esi, dword [ebp + 8]
test esi, esi
je 0x47751b
push edi
push eax
push 0x80
push 2
push eax
push eax
push 0x40000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4774d5
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x477509
cmp dword [ebp - 4], esi
jne 0x477509
push edi
mov esi, 1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
xor esi, esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x477530
Capabilities:
Encrypt data using rc4 ksa
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x204
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, ecx
mov esi, edx
test edi, edi
jne 0x477565
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
test esi, esi
jg 0x47757f
pop edi
pop esi
mov eax, 0xfffffffe
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
cmp dword [ebp + 0x10], 0
jne 0x47759b
pop edi
pop esi
mov eax, 0xfffffffd
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0xc]
test ecx, ecx
jg 0x4775b8
pop edi
pop esi
mov eax, 0xfffffffc
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
test ebx, ebx
jne 0x4775d0
pop edi
pop esi
lea eax, [ebx - 5]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x14]
test eax, eax
jg 0x4775ed
pop edi
pop esi
mov eax, 0xfffffffa
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
cmp ecx, eax
jge 0x477607
pop edi
pop esi
mov eax, 0xfffffff9
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
xor edx, edx
xor ecx, ecx
nop dword [eax + eax]
mov al, byte [edx + edi]
mov byte [ebp + ecx - 0x204], al
lea eax, [edx + 1]
mov byte [ebp + ecx - 0x104], cl
inc ecx
cdq
idiv esi
cmp ecx, 0x100
jl 0x477610
xor edi, edi
xor esi, esi
nop dword [eax]
nop dword [eax + eax]
mov dl, byte [ebp + esi - 0x104]
movzx eax, byte [ebp + esi - 0x204]
add edi, eax
movzx ecx, dl
add edi, ecx
and edi, 0x800000ff
jns 0x477666
dec edi
or edi, 0xffffff00
inc edi
mov al, byte [ebp + edi - 0x104]
mov byte [ebp + edi - 0x104], dl
mov byte [ebp + esi - 0x104], al
inc esi
cmp esi, 0x100
jl 0x477640
mov edi, dword [ebp + 0x14]
xor esi, esi
xor edx, edx
test edi, edi
jle 0x477700
sub dword [ebp + 0x10], ebx
inc edx
and edx, 0x800000ff
jns 0x4776a3
dec edx
or edx, 0xffffff00
inc edx
movzx eax, byte [ebp + edx - 0x104]
add esi, eax
and esi, 0x800000ff
jns 0x4776bd
dec esi
or esi, 0xffffff00
inc esi
movzx eax, byte [ebp + edx - 0x104]
mov cl, byte [ebp + esi - 0x104]
mov byte [ebp + esi - 0x104], al
mov byte [ebp + edx - 0x104], cl
movzx eax, byte [ebp + esi - 0x104]
movzx ecx, cl
add ecx, eax
movzx eax, cl
mov ecx, dword [ebp + 0x10]
movzx eax, byte [ebp + eax - 0x104]
xor al, byte [ecx + ebx]
mov byte [ebx], al
inc ebx
sub edi, 1
jne 0x477692
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x477720
Capabilities:
Encrypt data using rc4 ksa
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x204
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, ecx
mov esi, edx
test edi, edi
jne 0x477755
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
test esi, esi
jg 0x47776f
pop edi
pop esi
mov eax, 0xfffffffe
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
test ebx, ebx
jne 0x477787
pop edi
pop esi
lea eax, [ebx - 3]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0xc]
test ecx, ecx
jg 0x4777a4
pop edi
pop esi
mov eax, 0xfffffffc
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
cmp dword [ebp + 0x10], 0
jne 0x4777c0
pop edi
pop esi
mov eax, 0xfffffffb
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x14]
test eax, eax
jg 0x4777dd
pop edi
pop esi
mov eax, 0xfffffffa
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
cmp ecx, eax
jge 0x4777f7
pop edi
pop esi
mov eax, 0xfffffff9
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a578d
mov esp, ebp
pop ebp
ret
xor edx, edx
xor ecx, ecx
nop dword [eax + eax]
mov al, byte [edx + edi]
mov byte [ebp + ecx - 0x204], al
lea eax, [edx + 1]
mov byte [ebp + ecx - 0x104], cl
inc ecx
cdq
idiv esi
cmp ecx, 0x100
jl 0x477800
xor edi, edi
xor esi, esi
nop dword [eax]
nop dword [eax + eax]
mov dl, byte [ebp + esi - 0x104]
movzx eax, byte [ebp + esi - 0x204]
add edi, eax
movzx ecx, dl
add edi, ecx
and edi, 0x800000ff
jns 0x477856
dec edi
or edi, 0xffffff00
inc edi
mov al, byte [ebp + edi - 0x104]
mov byte [ebp + edi - 0x104], dl
mov byte [ebp + esi - 0x104], al
inc esi
cmp esi, 0x100
jl 0x477830
mov edi, dword [ebp + 0x14]
xor esi, esi
xor edx, edx
test edi, edi
jle 0x4778f0
sub dword [ebp + 0x10], ebx
inc edx
and edx, 0x800000ff
jns 0x477893
dec edx
or edx, 0xffffff00
inc edx
movzx eax, byte [ebp + edx - 0x104]
add esi, eax
and esi, 0x800000ff
jns 0x4778ad
dec esi
or esi, 0xffffff00
inc esi
movzx eax, byte [ebp + edx - 0x104]
mov cl, byte [ebp + esi - 0x104]
mov byte [ebp + esi - 0x104], al
mov byte [ebp + edx - 0x104], cl
movzx eax, byte [ebp + esi - 0x104]
movzx ecx, cl
add ecx, eax
movzx eax, cl
mov ecx, dword [ebp + 0x10]
movzx eax, byte [ebp + eax - 0x104]
xor al, byte [ecx + ebx]
mov byte [ebx], al
inc ebx
sub edi, 1
jne 0x477882
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x477910
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [sym.imp.WS2_32.dll_ntohl]
push esi
mov esi, ecx
mov dword [ebp - 0x18], eax
push edi
push dword [esi]
call ebx
push dword [esi + 4]
mov edi, eax
call ebx
mov ebx, eax
xor esi, esi
push dword [esi + str.37k_IF__y_d]
call dword [sym.imp.WS2_32.dll_ntohl]
mov dword [ebp + esi - 0x14], eax
add esi, 4
cmp esi, 0x10
jl 0x477940
xor edx, edx
lea esi, [edx + 0x10]
nop dword [eax]
mov ecx, ebx
lea edx, [edx - 0x61c88647]
shl ecx, 4
mov eax, ebx
add ecx, dword [ebp - 0x14]
shr eax, 5
add eax, dword [ebp - 0x10]
xor ecx, eax
lea eax, [edx + ebx]
xor ecx, eax
add edi, ecx
mov ecx, edi
mov eax, edi
shr ecx, 5
add ecx, dword [ebp - 8]
shl eax, 4
add eax, dword [ebp - 0xc]
xor ecx, eax
lea eax, [edx + edi]
xor ecx, eax
add ebx, ecx
sub esi, 1
jne 0x477960
mov esi, dword [sym.imp.WS2_32.dll_htonl]
push edi
call esi
mov edi, dword [ebp - 0x18]
push ebx
mov dword [edi], eax
call esi
mov ecx, dword [ebp - 4]
mov dword [edi + 4], eax
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.004a578d
mov esp, ebp
pop ebp
ret
Function at 0x477cc0
Capabilities:
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
mov edi, edx
mov esi, ecx
lea ecx, [edi + 2]
cmp ecx, 0xc0000000
jb 0x477cdb
pop edi
or eax, 0xffffffff
pop esi
pop ebp
ret
mov eax, 0xaaaaaaab
mul ecx
mov eax, dword [ebp + 0xc]
shr edx, 1
shl edx, 2
cmp dword [eax], edx
jb 0x477cd4
push ebx
mov ebx, dword [ebp + 8]
mov ecx, ebx
cmp edi, 2
jbe 0x477d74
lea edx, [edi - 3]
mov eax, 0xaaaaaaab
mul edx
mov ebx, edx
shr ebx, 1
inc ebx
nop dword [eax + eax]
movzx eax, byte [esi]
sub edi, 3
shr eax, 2
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx], al
movzx edx, byte [esi]
movzx eax, byte [esi + 1]
and edx, 3
shr eax, 4
add edx, edx
movzx eax, byte [eax + edx*8 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 1], al
movzx edx, byte [esi + 1]
movzx eax, byte [esi + 2]
and edx, 0xf
shr eax, 6
movzx eax, byte [eax + edx*4 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 2], al
movzx eax, byte [esi + 2]
add esi, 3
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 3], al
add ecx, 4
sub ebx, 1
jne 0x477d10
mov ebx, dword [ebp + 8]
test edi, edi
je 0x477dd8
movzx eax, byte [esi]
shr eax, 2
mov al, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx], al
cmp edi, 1
jbe 0x477dbd
movzx edx, byte [esi]
movzx eax, byte [esi + 1]
and edx, 3
shr eax, 4
add edx, edx
movzx eax, byte [eax + edx*8 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 1], al
movzx eax, byte [esi + 1]
and eax, 0xf
movzx eax, byte [eax*4 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 2], al
mov byte [ecx + 3], 0x3d
jmp 0x477dd5
movzx eax, byte [esi]
and eax, 3
shl eax, 4
mov al, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [ecx + 1], al
mov word [ecx + 2], 0x3d3d
add ecx, 4
mov edx, dword [ebp + 0xc]
mov eax, ecx
sub eax, ebx
pop ebx
pop edi
mov dword [edx], eax
xor eax, eax
mov byte [ecx], 0
pop esi
pop ebp
ret