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

Disassembly:
sub esp, 0x10
mov eax, dword [esp + 0x14]
and dword [esp + 4], 0
push ebx
push ebp
mov ebx, dword [eax]
push esi
mov esi, dword [esp + 0x24]
push edi
push 4
pop edi
mov dword [esi + 0xa0], ebx
mov ebp, dword [eax + 4]
mov dword [esi + 0xa4], ebp
mov ecx, dword [eax + 8]
mov dword [esi + 0xa8], ecx
mov eax, dword [eax + 0xc]
mov dword [esp + 0x1c], ecx
lea ecx, [esi + 0x98]
mov dword [esp + 0x18], ecx
lea ecx, [esi + 0x90]
mov dword [esi + 0xac], eax
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x10], eax
mov dword [esp + 0x24], ecx
push 3
push eax
call fcn.004021e0
mov edx, dword [esp + 0x1c]
pop ecx
pop ecx
mov ecx, dword [esp + 0x18]
xor eax, dword [edx + 0x4db340]
add edx, edi
xor ebx, eax
mov dword [esp + 0x14], edx
mov eax, dword [esp + 0x24]
xor ebp, ebx
sub dword [esp + 0x24], 0x10
xor esi, ebp
mov dword [eax], ebx
mov eax, dword [esp + 0x10]
mov dword [ecx - 4], ebp
xor eax, esi
mov dword [ecx], esi
mov dword [ecx + 4], eax
sub ecx, 0x10
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], ecx
cmp edx, 0x28
jb 0x46c286
mov esi, dword [esp + 0x28]
push dword [esi + edi*4]
call fcn.00402761
mov dword [esi + edi*4], eax
inc edi
pop ecx
cmp edi, 0x28
jb 0x46c2d7
and dword [esi + 0xf0], 0
and byte [esi + 0xf2], 0xfe
xor eax, eax
pop edi
mov byte [esi + 0xf0], 0xa0
pop esi
pop ebp
pop ebx
add esp, 0x10
ret

Function at 0x46c308
Capabilities:
Encode data using xor

Disassembly:
push ecx
push ecx
mov eax, dword [esp + 0xc]
and dword [esp], 0
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
push edi
mov edi, dword [eax]
mov dword [esi], edi
mov ebx, dword [eax + 4]
mov dword [esi + 4], ebx
mov ebp, dword [eax + 8]
mov dword [esi + 8], ebp
mov eax, dword [eax + 0xc]
mov dword [esp + 0x1c], eax
mov dword [esi + 0xc], eax
lea eax, [esi + 0x14]
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
push 3
push esi
call fcn.004021e0
pop ecx
pop ecx
mov ecx, dword [esp + 0x10]
xor eax, dword [ecx + 0x4db340]
add ecx, 4
xor edi, eax
mov dword [esp + 0x10], ecx
mov eax, dword [esp + 0x14]
xor ebx, edi
xor ebp, ebx
xor esi, ebp
mov dword [eax - 4], edi
mov dword [eax], ebx
mov dword [eax + 4], ebp
mov dword [eax + 8], esi
add eax, 0x10
mov dword [esp + 0x14], eax
cmp ecx, 0x24
jb 0x46c33f
push 3
push esi
mov dword [esp + 0x24], esi
call fcn.004021e0
xor eax, dword [0x4db364]
mov esi, dword [esp + 0x28]
xor edi, eax
mov eax, dword [esp + 0x24]
xor ebx, edi
pop ecx
xor ebp, ebx
and dword [esi + 0xf0], 0
xor eax, ebp
or byte [esi + 0xf2], 1
pop ecx
mov dword [esi + 0xa0], edi
pop edi
mov dword [esi + 0xa4], ebx
mov dword [esi + 0xa8], ebp
mov dword [esi + 0xac], eax
xor eax, eax
mov byte [esi + 0xf0], 0xa0
pop esi
pop ebp
pop ebx
pop ecx
pop ecx
ret
Function at 0x46c67e
Capabilities:
Decrypt data using aes via x86 extensions
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x188
mov eax, dword [0x5107c0]
xor eax, esp
mov dword [esp + 0x184], eax
mov edx, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x10], ecx
push esi
mov esi, dword [ebp + 8]
mov dword [esp + 0x10], esi
push edi
mov edi, dword [ebp + 0xc]
mov dword [esp + 0x1c], edi
test dl, 0xf
je 0x46c6e3
lea eax, [esp + 0x80]
mov esi, edx
neg eax
lea ecx, [esp + 0x80]
and eax, 0xf
add eax, ecx
push 0x3d
pop ecx
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [esp + 0x18]
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x1c]
jmp 0x46c6e5
mov eax, edx
movdqa xmm0, xmmword [eax + 0x50]
mov edx, dword [ebp + 0x10]
movdqa xmm3, xmmword [eax]
movdqa xmm4, xmmword [eax + 0x10]
movdqa xmm5, xmmword [eax + 0x20]
movdqa xmm6, xmmword [eax + 0x30]
movdqa xmm7, xmmword [eax + 0x40]
movdqu xmm2, xmmword [ecx]
sar edx, 4
movdqa xmmword [esp + 0x70], xmm0
movdqa xmm0, xmmword [eax + 0x60]
movdqa xmmword [esp + 0x20], xmm0
movdqa xmm0, xmmword [eax + 0x70]
movdqa xmmword [esp + 0x50], xmm0
movdqa xmm0, xmmword [eax + 0x80]
movdqa xmmword [esp + 0x30], xmm0
movdqa xmm0, xmmword [eax + 0x90]
movdqa xmmword [esp + 0x40], xmm0
movdqa xmm0, xmmword [eax + 0xa0]
movdqa xmmword [esp + 0x60], xmm0
test edx, edx
jle 0x46c7b5
sub edi, esi
movdqu xmm1, xmmword [esi]
movdqa xmm0, xmm1
pxor xmm0, xmm3
aesdec xmm0, xmm4
aesdec xmm0, xmm5
aesdec xmm0, xmm6
aesdec xmm0, xmm7
aesdec xmm0, xmmword [esp + 0x70]
aesdec xmm0, xmmword [esp + 0x20]
aesdec xmm0, xmmword [esp + 0x50]
aesdec xmm0, xmmword [esp + 0x30]
aesdec xmm0, xmmword [esp + 0x40]
aesdeclast xmm0, xmmword [esp + 0x60]
pxor xmm0, xmm2
movdqa xmm2, xmm1
movdqu xmmword [edi + esi], xmm0
lea esi, [esi + 0x10]
dec edx
jne 0x46c758
movdqu xmmword [ecx], xmm2
mov ecx, dword [esp + 0x18c]
pop edi
pop esi
xor ecx, esp
call fcn.004b35e5
mov esp, ebp
pop ebp
ret

Function at 0x46c93a
Capabilities:
Hash data using sha1

Disassembly:
mov eax, dword [esp + 4]
and dword [eax + 4], 0
and dword [eax], 0
mov dword [eax + 8], 0x67452301
mov dword [eax + 0xc], 0xefcdab89
mov dword [eax + 0x10], 0x98badcfe
mov dword [eax + 0x14], 0x10325476
mov dword [eax + 0x18], 0xc3d2e1f0
ret
Function at 0x46db9a
Capabilities:
Hash data with md5

Disassembly:
mov eax, dword [esp + 4]
and dword [eax + 4], 0
and dword [eax], 0
mov dword [eax + 8], 0x67452301
mov dword [eax + 0xc], 0xefcdab89
mov dword [eax + 0x10], 0x98badcfe
mov dword [eax + 0x14], 0x10325476
ret
Function at 0x46e6a7
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
xor ebx, ebx
movzx edi, byte [ebx + 0x51f278]
mov ecx, edi
mov edx, edi
shr edx, 1
and ecx, 3
xor edx, edi
mov eax, edi
shr eax, 2
shr edx, 1
movzx esi, byte [ecx + 0x50fb20]
xor esi, eax
movzx eax, byte [ecx + 0x50fb24]
xor edx, eax
xor esi, edi
xor edx, edi
imul eax, edx, 0x10100
add eax, esi
shl eax, 8
add eax, edi
shl edi, 0x10
mov dword [ebx*4 + 0x51f378], eax
imul eax, edx, 0x1000100
add eax, esi
add edi, eax
mov dword [ebx*4 + 0x51fb78], edi
movzx edi, byte [ebx + 0x51f178]
mov ecx, edi
mov edx, edi
and ecx, 3
shr edx, 1
xor edx, edi
mov eax, edi
shr eax, 2
shr edx, 1
movzx esi, byte [ecx + 0x50fb20]
xor esi, eax
movzx eax, byte [ecx + 0x50fb24]
xor edx, eax
xor esi, edi
xor edx, edi
mov ecx, edi
imul eax, edx, 0x101
shl ecx, 8
add ecx, esi
shl edx, 8
shl ecx, 0x10
add edx, edi
shl edx, 8
add ecx, eax
imul eax, esi, 0x1000001
mov dword [ebx*4 + 0x51f778], ecx
add edx, eax
mov dword [ebx*4 + 0x51ff78], edx
inc ebx
cmp ebx, 0x100
jb 0x46e6ac
pop edi
pop esi
pop ebx
ret
Function at 0x470b75
Capabilities:
Clear file content

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push ebp
xor ebp, ebp
mov eax, dword [ebx + 0x24]
test eax, eax
jle 0x470bb2
push esi
cdq
push edi
mov edi, eax
mov esi, edx
mov ecx, edi
mov eax, esi
add ecx, dword [esp + 0x18]
push esi
adc eax, dword [esp + 0x20]
sub ecx, 1
push edi
sbb eax, ebp
push eax
push ecx
call fcn.004b9b50
push esi
push edi
push edx
push eax
call fcn.004ba310
pop edi
pop esi
jmp 0x470bba
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edx
push eax
push ebx
call fcn.0048b213
add esp, 0xc
test eax, eax
je 0x470bd8
push 0x802d
push dword [ebx + 0x20]
push str.winTruncate1
jmp 0x470bfb
push dword [ebx + 8]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x470c0a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x8030
push dword [ebx + 0x20]
mov dword [ebx + 0x14], eax
push str.winTruncate2
push 0x60a
call fcn.004b0bc6
mov ebp, eax
add esp, 0x10
mov eax, ebp
pop ebp
pop ebx
ret

Function at 0x470e8d
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 4]
push edi
push eax
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 0xffffffff
jne 0x470ed3
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x470ed3
push 0x808c
push dword [esi + 0x20]
mov dword [esi + 0x14], eax
push str.winFileSize
push 0x70a
call fcn.004b0bc6
add esp, 0x10
jmp 0x470ee7
mov eax, dword [ebp + 0xc]
xor ecx, ecx
mov edx, dword [ebp - 4]
add ecx, edi
adc edx, 0
mov dword [eax], ecx
mov dword [eax + 4], edx
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x47274a
Capabilities:
Check if file exists
Delete file
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
push esi
push dword [ebp + 0xc]
call fcn.0047e520
mov esi, eax
pop ecx
test esi, esi
jne 0x47276a
push 7
pop eax
jmp 0x472805
push ebx
push edi
call fcn.004840d1
xor edi, edi
inc edi
test eax, eax
je 0x4727a1
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4727c8
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov edi, eax
test edi, edi
jne 0x4727c8
lea eax, [ebp - 4]
push eax
call fcn.0048adc0
pop ecx
test eax, eax
jne 0x472778
jmp 0x4727c8
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4727c8
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edi, eax
test edi, edi
jne 0x4727c8
lea eax, [ebp - 4]
push eax
call fcn.0048adc0
pop ecx
test eax, eax
jne 0x4727a1
xor ebx, ebx
test edi, edi
sete bl
test ebx, ebx
je 0x4727f1
push 0x85f9
push dword [ebp + 0xc]
push str.winDelete
push 0xa0a
call fcn.004b0bc6
add esp, 0x10
mov ebx, eax
jmp 0x4727fa
push dword [ebp - 4]
call fcn.00484abb
pop ecx
push esi
call fcn.004b592c
pop ecx
pop edi
mov eax, ebx
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x4830c9
Capabilities:
Get disk size

Disassembly:
push ebp
lea ebp, [esp - 0x94]
sub esp, 0x114
mov eax, dword [0x5107c0]
xor eax, ebp
mov dword [ebp + 0x90], eax
mov eax, dword [ebp + 0xa0]
lea ecx, [ebp - 0x78]
push esi
push edi
push ecx
push 0x104
push eax
push dword [ebp + 0x9c]
mov edi, 0x200
mov dword [ebp - 0x80], edi
call fcn.00475dbd
add esp, 0x10
test eax, eax
jne 0x483199
lea eax, [ebp - 0x78]
push eax
call fcn.0047e520
mov esi, eax
pop ecx
test esi, esi
je 0x48319c
push ebx
call fcn.004840d1
test eax, eax
mov eax, esi
je 0x483162
xor ecx, ecx
cmp word [esi], cx
je 0x48314c
cmp word [eax], 0x5c
je 0x483147
add eax, 2
cmp word [eax], cx
jne 0x483137
jmp 0x48314c
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x7c]
push eax
push eax
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x7c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceW]
jmp 0x48318b
cmp byte [esi], 0
je 0x483177
cmp byte [eax], 0x5c
je 0x483174
inc eax
cmp byte [eax], 0
jne 0x483167
jmp 0x483177
mov byte [eax], 0
lea eax, [ebp - 0x7c]
push eax
push eax
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x7c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
push esi
mov ebx, eax
call fcn.004b592c
pop ecx
test ebx, ebx
pop ebx
je 0x48319c
mov edi, dword [ebp - 0x80]
mov ecx, dword [ebp + 0x90]
mov eax, edi
pop edi
xor ecx, ebp
pop esi
call fcn.004b35e5
lea esp, [ebp + 0x94]
pop ebp
ret
Function at 0x4831b5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x314
mov eax, dword [0x5107c0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [0x5203a8]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
test eax, eax
je 0x4831f3
push eax
push 0x4df798
lea eax, [ebp - 0x10c]
push eax
push 0xe6
call fcn.004755a6
add esp, 0x10
jmp 0x48326e
call fcn.004840d1
mov esi, 0xe6
test eax, eax
je 0x483236
lea eax, [ebp - 0x314]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp - 0x314]
push eax
call fcn.004adf2f
mov edi, eax
pop ecx
test edi, edi
jne 0x483252
push 7
pop eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004b35e5
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x210]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea eax, [ebp - 0x210]
push eax
call fcn.004ad572
jmp 0x48321b
push edi
push 0x4df798
lea eax, [ebp - 0x10c]
push eax
push esi
call fcn.004755a6
push edi
call fcn.004b592c
add esp, 0x14
push str.etilqs_
call fcn.004a0cc8
mov edx, eax
lea eax, [ebp - 0x10c]
push eax
call fcn.004a0cc8
add edx, 0x11
add eax, edx
mov edx, dword [ebp + 8]
pop ecx
pop ecx
cmp eax, edx
jl 0x483299
xor eax, eax
inc eax
jmp 0x483225
lea eax, [ebp - 0x10c]
push eax
call fcn.004a0cc8
pop ecx
test eax, eax
je 0x4832ba
lea ecx, [ebp - 0x10c]
cmp byte [ecx + eax - 1], 0x5c
jne 0x4832ba
dec eax
jne 0x4832b0
cmp eax, 0x105
jae 0x48331a
mov byte [ebp + eax - 0x10c], 0
lea eax, [ebp - 0x10c]
push eax
push str._setilqs_
lea eax, [edx - 0x11]
push ebx
push eax
call fcn.004755a6
push ebx
call fcn.004a0cc8
mov esi, eax
lea ecx, [ebx + esi]
push ecx
push 0xf
pop edi
push edi
call fcn.00475858
add esp, 0x1c
movzx eax, byte [ebx + esi]
xor edx, edx
push 0x3e
pop ecx
div ecx
mov al, byte [edx + str.abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]
mov byte [ebx + esi], al
inc esi
dec edi
jne 0x4832f7
mov byte [ebx + esi], 0
xor eax, eax
jmp 0x483225
call fcn.004b44ed
int3
Function at 0x487f76
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xc
push ebx
mov ebx, dword [esp + 0x14]
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [ebx + 0x3c]
cmp dword [eax], 0
jne 0x487fa5
push dword [ebx + 0x78]
push eax
push ebx
call fcn.00486c47
add esp, 0xc
mov dword [esp + 4], eax
test eax, eax
jne 0x488091
mov ecx, dword [ebx + 0x18]
cmp ecx, dword [ebx + 0x24]
jbe 0x487fdf
mov eax, dword [ebx + 0x80]
push 0
cdq
push ecx
push edx
push eax
call fcn.004ba310
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x3c]
mov dword [esp + 0xc], edx
lea edx, [esp + 8]
push edx
push 5
mov ecx, dword [eax]
push eax
call dword [ecx + 0x28]
mov eax, dword [ebx + 0x18]
add esp, 0xc
mov dword [ebx + 0x24], eax
mov eax, dword [esp + 4]
push ebp
mov ebp, dword [esp + 0x1c]
push esi
push edi
test ebp, ebp
je 0x48808e
mov esi, dword [ebp + 0xc]
mov dword [esp + 0x14], esi
cmp esi, dword [ebx + 0x18]
ja 0x488083
test byte [ebp + 0x14], 0x20
jne 0x488083
mov eax, dword [ebx + 0x80]
lea ecx, [esi - 1]
cdq
push edx
push eax
push 0
push ecx
call fcn.004ba310
mov dword [esp + 0x20], eax
mov ecx, edx
mov dword [esp + 0x10], ecx
cmp esi, 1
jne 0x48803a
push ebp
call fcn.00487f33
mov eax, dword [esp + 0x24]
pop ecx
mov ecx, dword [esp + 0x10]
mov edi, dword [ebp]
push ecx
push eax
push dword [ebx + 0x80]
push edi
push dword [ebx + 0x3c]
call fcn.00499ce0
add esp, 0x14
mov dword [esp + 0x10], eax
cmp esi, 1
jne 0x488068
lea esi, [edi + 0x18]
lea edi, [ebx + 0x64]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x14]
cmp esi, dword [ebx + 0x20]
jbe 0x488070
mov dword [ebx + 0x20], esi
push dword [ebp]
push esi
push dword [ebx + 0x58]
call fcn.0048db0b
mov eax, dword [esp + 0x1c]
add esp, 0xc
mov ebp, dword [ebp + 8]
test eax, eax
je 0x487fea
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
Function at 0x495751
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x24
push ebx
push ebp
push esi
mov esi, dword [esp + 0x34]
push edi
mov edi, dword [esi + 0x200]
and dword [esi + 0x200], 0
cmp dword [esi + 0x40], 0
mov ebx, dword [esi]
jne 0x4958f3
test edi, edi
je 0x4958f3
push dword [edi + 0x14]
mov eax, dword [edi]
push ebx
mov dword [esp + 0x1c], eax
call fcn.0049eb74
mov ebp, dword [esp + 0x44]
mov edx, eax
pop ecx
pop ecx
mov dword [esp + 0x10], edx
mov dword [edi + 0x1c], ebp
jmp 0x4957a3
mov dword [ebp + 4], edi
mov ebp, dword [ebp + 0x20]
test ebp, ebp
jne 0x49579d
mov eax, dword [edi]
push eax
mov dword [esp + 0x20], eax
call fcn.004a0cc8
mov dword [esp + 0x24], eax
lea eax, [esp + 0x20]
push eax
push str.trigger
push edx
lea eax, [esp + 0x34]
push esi
push eax
call fcn.004959a0
add esp, 0x18
test eax, eax
je 0x4957eb
push dword [edi + 0x1c]
lea eax, [esp + 0x28]
push eax
call fcn.00495ad1
pop ecx
pop ecx
test eax, eax
jne 0x4958f7
cmp byte [ebx + 0x7c], 0
jne 0x495893
push esi
call fcn.0049753d
mov dword [esp + 0x1c], eax
pop ecx
test eax, eax
je 0x4958f7
push dword [esp + 0x10]
push 0
push esi
call fcn.0048df88
mov eax, dword [esp + 0x4c]
push dword [eax + 4]
push dword [eax]
push ebx
call fcn.00491fd7
mov ecx, dword [esp + 0x28]
mov esi, eax
push esi
push dword [edi + 4]
cmp ecx, 1
mov edx, str.sqlite_master
push dword [esp + 0x34]
mov eax, str.sqlite_temp_master
cmovne eax, edx
add ecx, ecx
push eax
mov eax, dword [ebx + 8]
push dword [eax + ecx*8]
push str.INSERT_INTO__Q._s_VALUES_trigger__Q__Q_0_CREATE_TRIGGER__q_
push dword [esp + 0x68]
call fcn.00499909
push esi
push ebx
call fcn.00491da8
mov esi, dword [esp + 0x4c]
push esi
push dword [esp + 0x78]
call fcn.0049043a
add esp, 0x44
push dword [esp + 0x14]
push str.typetrigger_AND_name_q
push ebx
call fcn.00499220
push eax
push esi
push dword [esp + 0x2c]
call fcn.004a30e0
add esp, 0x18
cmp byte [ebx + 0x7c], 0
je 0x4958f7
mov ecx, dword [esp + 0x10]
mov esi, edi
mov eax, dword [ebx + 8]
add ecx, ecx
push edi
mov edi, dword [esp + 0x18]
push edi
mov edx, dword [eax + ecx*8 + 0xc]
add edx, 0x28
call fcn.004a0cc8
pop ecx
push eax
push edi
push edx
call fcn.00497628
mov edi, eax
add esp, 0x10
test edi, edi
je 0x4958c8
mov byte [ebx + 0x1e], 1
jmp 0x4958f7
mov edx, dword [esi + 0x18]
cmp dword [esi + 0x14], edx
jne 0x4958f7
push dword [esi + 4]
call fcn.004a0cc8
push eax
push dword [esi + 4]
lea eax, [edx + 8]
push eax
call fcn.004975e7
add esp, 0x10
mov ecx, dword [eax + 0x40]
mov dword [esi + 0x20], ecx
mov dword [eax + 0x40], esi
jmp 0x4958f7
mov ebp, dword [esp + 0x3c]
push edi
push ebx
call fcn.004925b7
push ebp
push ebx
call fcn.004925fe
add esp, 0x10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
Function at 0x4ad908
Capabilities:
Encode data using xor

Disassembly:
push esi
mov esi, dword [esp + 0xc]
push edi
xor edi, edi
test esi, esi
jle 0x4ad933
push ebx
mov ebx, dword [esp + 0x10]
movzx eax, byte [ebx]
mov ecx, edi
shl ecx, 3
movzx edx, byte [eax + 0x4db9d8]
xor edx, ecx
xor edi, edx
inc ebx
dec esi
test esi, esi
jg 0x4ad919
pop ebx
mov eax, edi
pop edi
pop esi
ret
Function at 0x4b5b45
Capabilities:
Accept command line arguments
Terminate process

Disassembly:
call fcn.004c21f9
jmp 0x4b5b4f
push 0x10
push 0x4edd40
call fcn.004b9e60
call fcn.004bc8aa
movzx esi, ax
push 2
call fcn.004c21b3
pop ecx
call fcn.004c19ee
test eax, eax
jne 0x4b5b7c
push 0x1c
call fcn.004b5c31
pop ecx
call fcn.004be9e7
test eax, eax
jne 0x4b5b8d
push 0x10
call fcn.004b5c31
pop ecx
call fcn.004c2295
and dword [ebp - 4], 0
call fcn.004c1341
test eax, eax
jns 0x4b5ba7
push 0x1b
call fcn.004b5c31
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x522b38], eax
call fcn.004c22d5
mov dword [0x520c80], eax
call fcn.004c1c57
test eax, eax
jns 0x4b5bcd
push 8
call fcn.004bad44
pop ecx
call fcn.004c1e97
test eax, eax
jns 0x4b5bde
push 9
call fcn.004bad44
pop ecx
push 1
call fcn.004bad5e
pop ecx
test eax, eax
je 0x4b5bf1
push eax
call fcn.004bad44
pop ecx
call fcn.004c235a
push esi
push eax
push 0
push 0x400000
call main
mov dword [ebp - 0x20], eax
push eax
call fcn.004bafbf
mov ecx, dword [ebp - 0x14]
mov eax, dword [ecx]
mov eax, dword [eax]
mov dword [ebp - 0x1c], eax
push ecx
push eax
call fcn.004c1b00
pop ecx
pop ecx
ret
Function at 0x4c1222
Capabilities:
Read file on windows

Disassembly:
push edi
mov edi, dword [esp + 8]
test edi, edi
jne 0x4c1240
call fcn.004bc77f
mov dword [eax], 0x16
call fcn.004bdd46
jmp 0x4c133c
mov eax, dword [edi + 0xc]
test al, 0x83
je 0x4c133c
test al, 0x40
jne 0x4c133c
test al, 2
je 0x4c1262
or eax, 0x20
mov dword [edi + 0xc], eax
jmp 0x4c133c
or eax, 1
mov dword [edi + 0xc], eax
test eax, 0x10c
jne 0x4c1278
push edi
call fcn.004c74ab
pop ecx
jmp 0x4c127d
mov eax, dword [edi + 8]
mov dword [edi], eax
push dword [edi + 0x18]
push dword [edi + 8]
push edi
call fcn.004b656b
pop ecx
push eax
call fcn.004c4000
add esp, 0xc
mov dword [edi + 4], eax
test eax, eax
je 0x4c132a
cmp eax, 0xffffffff
je 0x4c132a
test byte [edi + 0xc], 0x82
jne 0x4c12fe
push edi
call fcn.004b656b
pop ecx
cmp eax, 0xffffffff
je 0x4c12e9
push edi
call fcn.004b656b
pop ecx
cmp eax, 0xfffffffe
je 0x4c12e9
push esi
push edi
call fcn.004b656b
mov esi, eax
push edi
sar esi, 5
call fcn.004b656b
and eax, 0x1f
pop ecx
shl eax, 6
add eax, dword [esi*4 + 0x520f18]
pop ecx
pop esi
jmp 0x4c12ee
mov eax, 0x511730
mov al, byte [eax + 4]
and al, 0x82
cmp al, 0x82
jne 0x4c12fe
or dword [edi + 0xc], 0x2000
cmp dword [edi + 0x18], 0x200
jne 0x4c131d
test byte [edi + 0xc], 8
je 0x4c131d
test dword [edi + 0xc], 0x400
jne 0x4c131d
mov dword [edi + 0x18], 0x1000
mov ecx, dword [edi]
dec dword [edi + 4]
movzx eax, byte [ecx]
inc ecx
mov dword [edi], ecx
pop edi
ret
push 0x10
pop ecx
push 0x20
test eax, eax
pop edx
cmovne ecx, edx
or dword [edi + 0xc], ecx
and dword [edi + 4], 0
or eax, 0xffffffff
pop edi
ret
Function at 0x4c1fe7
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x1fc
mov eax, dword [0x5107c0]
xor eax, esp
mov dword [esp + 0x1f8], eax
push ebp
push esi
push edi
mov edi, dword [esp + 0x20c]
push edi
call fcn.004c1fc7
mov esi, eax
pop ecx
test esi, esi
je 0x4c2190
push ebx
push 3
call fcn.004c21bd
pop ecx
cmp eax, 1
je 0x4c2138
push 3
call fcn.004c21bd
pop ecx
test eax, eax
jne 0x4c2041
cmp dword [0x521128], 1
je 0x4c2138
cmp edi, 0xfc
je 0x4c218f
push str.Runtime_Error__n_nProgram:
push 0x314
mov ebp, 0x521130
push ebp
call fcn.004c1a03
add esp, 0xc
xor ebx, ebx
test eax, eax
jne 0x4c21a8
push 0x104
push 0x521162
push ebx
mov word [0x52136a], ax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov edi, 0x2fb
test eax, eax
jne 0x4c20aa
push str._program_name_unknown_
push edi
push 0x521162
call fcn.004c1a03
add esp, 0xc
test eax, eax
jne 0x4c21a8
mov ecx, 0x521162
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x4c20b2
sub ecx, edx
sar ecx, 1
lea eax, [ecx + 1]
cmp eax, 0x3c
jbe 0x4c20f4
lea ecx, [ecx*2 + 0x5210ec]
mov eax, ecx
sub eax, 0x521162
push 3
sar eax, 1
push 0x4e7c14
sub edi, eax
push edi
push ecx
call fcn.004c7311
add esp, 0x10
test eax, eax
jne 0x4c21a8
push 0x4e7c1c
mov edi, 0x314
push edi
push ebp
call fcn.004c72a6
add esp, 0xc
test eax, eax
jne 0x4c21a8
push esi
push edi
push ebp
call fcn.004c72a6
add esp, 0xc
test eax, eax
jne 0x4c21a8
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.004c86da
add esp, 0xc
jmp 0x4c218f
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edx, eax
test edx, edx
je 0x4c218f
cmp edx, 0xffffffff
je 0x4c218f
xor ebx, ebx
mov ecx, ebx
mov al, byte [esi + ecx*2]
mov byte [esp + ecx + 0x14], al
cmp word [esi + ecx*2], bx
je 0x4c2165
inc ecx
cmp ecx, 0x1f4
jb 0x4c214f
lea ecx, [esp + 0x14]
mov byte [esp + 0x207], bl
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4c2173
push ebx
lea eax, [esp + 0x14]
sub ecx, esi
push eax
push ecx
lea eax, [esp + 0x20]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebx
mov ecx, dword [esp + 0x204]
pop edi
pop esi
pop ebp
xor ecx, esp
call fcn.004b35e5
add esp, 0x1fc
ret
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.004bdd56
int3
Function at 0x4c22d5
Capabilities:
Query environment variable

Disassembly:
push edi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov edi, eax
xor eax, eax
test edi, edi
je 0x4c2358
push esi
mov esi, edi
cmp word [edi], ax
je 0x4c22fc
add esi, 2
cmp word [esi], ax
jne 0x4c22ec
add esi, 2
cmp word [esi], ax
jne 0x4c22ec
push ebx
push ebp
push eax
push eax
push eax
sub esi, edi
push eax
sar esi, 1
inc esi
push esi
push edi
push eax
push eax
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov ebp, eax
test ebp, ebp
je 0x4c234c
push ebp
call fcn.004bc66d
mov ebx, eax
pop ecx
test ebx, ebx
je 0x4c234c
xor eax, eax
push eax
push eax
push ebp
push ebx
push esi
push edi
push eax
push eax
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x4c2341
push ebx
call fcn.004b592c
pop ecx
xor ebx, ebx
push edi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
jmp 0x4c2355
push edi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
pop ebp
pop ebx
pop esi
pop edi
ret