joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40469f
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov ecx, dword [esp + 8]
cmp word [ecx], 0
mov eax, dword [esp + 4]
push ebx
mov ebx, eax
je 0x40472d
cmp word [eax], 0
push ebp
push esi
push edi
je 0x404728
mov ebp, dword [sym.imp.USER32.dll_CharNextW]
cmp word [ebx], 0
mov edi, dword [esp + 0x18]
mov esi, ebx
je 0x404717
mov ax, word [edi]
test ax, ax
je 0x404731
movzx ecx, word [esi]
movzx eax, ax
sub ecx, eax
jne 0x404717
push esi
call ebp
push edi
mov dword [esp + 0x18], eax
call ebp
mov ecx, eax
mov eax, dword [esp + 0x14]
mov edx, eax
sub ecx, edi
sub edx, esi
xor ecx, edx
test ecx, 0xfffffffe
jne 0x404717
jmp 0x40470d
inc esi
inc esi
movzx edx, word [esi]
inc edi
inc edi
movzx ecx, word [edi]
sub edx, ecx
je 0x404711
cmp esi, eax
jb 0x4046ff
cmp word [esi], 0
jne 0x4046cb
cmp word [edi], 0
je 0x404731
push ebx
call ebp
mov ebx, eax
cmp word [ebx], 0
jne 0x4046bf
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret 8
mov eax, ebx
jmp 0x40472a

Function at 0x4048e1
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov eax, 0x200c
lea ebp, [esp - 0x1f8c]
call fcn.00414370
mov eax, dword [0x4188a0]
push esi
xor esi, esi
push esi
push esi
push esi
push esi
mov dword [ebp + 0x1f88], eax
lea eax, [ebp - 0x7c]
push eax
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp + 0x1f94]
mov dword [ebp - 0x7c], esi
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
jne 0x404955
cmp dword [ebp - 0x7c], 1
jne 0x404959
push esi
push esi
push esi
push esi
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x78]
push eax
push esi
push dword [ebp + 0x1f94]
mov dword [ebp - 0x80], 0x1000
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
jne 0x404955
cmp word [ebp - 0x78], si
je 0x404955
inc eax
jmp 0x404962
xor eax, eax
jmp 0x404962
xor eax, eax
cmp eax, dword [ebp - 0x7c]
sbb eax, eax
neg eax
mov ecx, dword [ebp + 0x1f88]
pop esi
call fcn.004140c6
add ebp, 0x1f8c
leave
ret 4

Function at 0x4052ea
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
mov eax, 0x4145bd
call fcn.00414460
sub esp, 0x214
mov eax, dword [0x4188a0]
push ebx
push esi
xor esi, esi
mov dword [ebp - 0x10], eax
mov ebx, ecx
mov dword [ebp - 0x214], esi
push 0x2001f
push dword [ebp + 8]
lea ecx, [ebp - 0x214]
push dword [ebx]
mov dword [ebp - 4], esi
call fcn.004042eb
cmp eax, esi
jne 0x405389
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
jmp 0x405343
lea eax, [ebp - 0x210]
push eax
call fcn.004052ea
cmp eax, esi
jne 0x405388
lea eax, [ebp - 0x220]
push eax
push esi
push esi
push esi
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x210]
push eax
push esi
push dword [ebp - 0x214]
mov dword [ebp - 0x218], 0x100
call edi
test eax, eax
lea ecx, [ebp - 0x214]
je 0x405333
call fcn.00404286
push dword [ebp + 8]
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
pop edi
lea ecx, [ebp - 0x214]
mov esi, eax
call fcn.00404286
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x10]
pop ebx
call fcn.004140c6
leave
ret 4
Function at 0x407c86
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, 0x4146fb
call fcn.00414460
sub esp, 0x10
push ebx
push esi
push edi
xor edi, edi
mov dword [ebp - 0x10], edi
push 2
push edi
push dword [ebp + 8]
mov dword [ebp - 4], edi
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x1c], edi
call fcn.00406265
mov esi, eax
cmp esi, edi
mov dword [ebp - 0x14], esi
jne 0x407ce2
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
test eax, eax
jg 0x407ccd
call esi
mov esi, eax
jmp 0x407dfb
call esi
mov esi, eax
and esi, 0xffff
or esi, 0x80070000
jmp 0x407dfb
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov ebx, eax
cmp ebx, edi
je 0x407d03
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
cmp esi, edi
jne 0x407d2b
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
test eax, eax
jg 0x407d16
call esi
jmp 0x407df0
call esi
mov esi, eax
and esi, 0xffff
or esi, 0x80070000
jmp 0x407df2
push ebx
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
cmp byte [ebx + esi], 0
mov edi, esi
je 0x407d99
lea edi, [ebx + 1]
cmp edi, 0x400
ja 0x407d66
push edi
call fcn.0040418d
test al, al
je 0x407d66
mov eax, edi
add eax, 3
and eax, 0xfffffffc
call fcn.00414370
mov dword [ebp + 8], esp
jmp 0x407d72
push edi
lea ecx, [ebp - 0x10]
call fcn.004061b2
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
test eax, eax
jne 0x407d80
mov esi, 0x8007000e
jmp 0x407df2
mov ecx, edi
mov edx, ecx
shr ecx, 2
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebp + 8]
mov byte [eax + ebx], 0
test edi, edi
jne 0x407da1
xor eax, eax
jmp 0x407de4
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
inc esi
lea ebx, [esi + esi]
cmp ebx, 0x400
ja 0x407dd1
push ebx
call fcn.0040418d
test al, al
je 0x407dd1
mov eax, ebx
add eax, 3
and eax, 0xfffffffc
call fcn.00414370
mov eax, esp
jmp 0x407dda
push ebx
lea ecx, [ebp - 0x10]
call fcn.004061b2
push 0
push esi
push edi
push eax
call fcn.004041e8
push dword [ebp + 0x14]
lea ecx, [ebp - 0x1c]
push eax
call fcn.00406fbb
mov esi, eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea ecx, [ebp - 0x10]
call fcn.00404dee
mov eax, esi
lea esp, [ebp - 0x28]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x40cae7
Capabilities:
Delete file

Disassembly:
mov eax, 0x414914
call fcn.00414460
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esi
mov eax, dword [esi + 0x4c]
test eax, eax
mov dword [ebp - 4], 2
je 0x40c7c7
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [esi + 0x74]
test eax, eax
je 0x40c7d5
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
lea eax, [esi + 0x8c]
cmp dword [eax], 0
je 0x40c7e8
mov eax, dword [eax]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [esi + 0x50]
test eax, eax
je 0x40c801
push dword [eax + 0x20]
call sub.msvcrt.dll_void___cdecl_operator_delete_void__
push dword [esi + 0x50]
call sub.msvcrt.dll_void___cdecl_operator_delete_void__
pop ecx
pop ecx
mov eax, dword [esi + 0x70]
test eax, eax
je 0x40c80f
push eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov eax, dword [esi + 0x78]
test eax, eax
mov ebx, dword [sym.imp.OLEAUT32.dll_SysStringLen]
je 0x40c81f
push eax
call ebx
mov eax, dword [esi + 0x7c]
test eax, eax
je 0x40c829
push eax
call ebx
mov eax, dword [esi + 0x80]
test eax, eax
je 0x40c836
push eax
call ebx
mov eax, dword [esi + 0x84]
test eax, eax
je 0x40c843
push eax
call ebx
lea edi, [esi + 0x88]
mov eax, dword [edi]
test eax, eax
je 0x40c85a
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push dword [edi]
call ebx
mov ecx, esi
call fcn.0040bda4
lea ecx, [esi + 0x60]
mov byte [ebp - 4], 1
call fcn.0040bc0c
lea ecx, [esi + 0x54]
call fcn.00408914
lea ecx, [esi + 0x24]
call fcn.0040421f
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
push esi
mov esi, ecx
push 0x4188f4
mov dword [esi], 0x402334
mov dword [esi + 4], 1
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
mov ecx, esi
pop esi
jmp 0x40c79f
Function at 0x40e3cf
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
and dword [ebp - 8], 0
push ebx
push esi
mov esi, dword [ebp + 0x14]
mov eax, dword [esi + 4]
mov dword [ebp - 4], eax
mov eax, dword [esi]
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
push edi
lea ebx, [ecx + eax + 0x18]
jbe 0x40e4b1
add ebx, 0x10
mov eax, dword [ebx]
test eax, eax
jne 0x40e44c
mov eax, dword [ebp + 0x10]
mov edi, dword [eax + 0x38]
test edi, edi
jle 0x40e49c
push dword [esi + 0x34]
mov eax, dword [ebx - 4]
add eax, dword [ebp - 4]
push 4
push 0x1000
push edi
push eax
call dword [esi + 0x1c]
test eax, eax
je 0x40e4bb
mov edx, dword [ebx - 4]
add edx, dword [ebp - 4]
mov ecx, edi
mov dword [ebx - 8], edx
mov edi, edx
mov edx, ecx
shr ecx, 2
xor eax, eax
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
jmp 0x40e49c
mov ecx, dword [ebx + 4]
add ecx, eax
mov eax, dword [ebp + 0xc]
push ecx
call fcn.0040e3b7
test eax, eax
je 0x40e4bb
push dword [esi + 0x34]
mov eax, dword [ebx - 4]
add eax, dword [ebp - 4]
push 4
push 0x1000
push dword [ebx]
push eax
call dword [esi + 0x1c]
test eax, eax
je 0x40e4bb
mov eax, dword [ebx - 4]
mov ecx, dword [ebx]
add eax, dword [ebp - 4]
mov esi, dword [ebx + 4]
add esi, dword [ebp + 8]
mov edx, ecx
shr ecx, 2
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [ebp + 0x14]
mov dword [ebx - 8], eax
mov eax, dword [esi]
movzx eax, word [eax + 6]
inc dword [ebp - 8]
add ebx, 0x28
cmp dword [ebp - 8], eax
jl 0x40e3fc
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0x10
xor eax, eax
jmp 0x40e4b4
Function at 0x40f7c9
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push edi
push 0xd
mov edx, ecx
pop ecx
xor eax, eax
lea edi, [ebp - 0x34]
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x34]
push eax
push 0
push 0x104b
push dword [edx + 4]
mov dword [ebp - 0x34], 4
call dword [sym.imp.USER32.dll_SendMessageW]
neg eax
sbb eax, eax
and eax, dword [ebp - 0x14]
pop edi
leave
ret 4

Function at 0x40f857
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 8]
mov esi, ecx
call dword [sym.imp.USER32.dll_GetWindowRect]
test eax, eax
je 0x40f8a2
push 0
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [ebp + 0xc]
mov dword [ebp + 8], eax
lea eax, [ebp - 0x10]
push eax
lea ecx, [esi + 4]
call fcn.0040f099
test eax, eax
je 0x40f8a2
push 1
lea eax, [ebp - 0x10]
push eax
lea ecx, [ebp + 8]
call fcn.0040f06f
jmp 0x40f8a4
xor eax, eax
pop esi
leave
ret 8

Function at 0x41025e
Capabilities:
Get graphical window text

Disassembly:
mov eax, 0x414a15
call fcn.00414460
sub esp, 0x3c
push ebx
push esi
mov esi, ecx
and dword [ebp - 4], 0
push 0x1c
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov dword [ebp - 0x10], eax
test eax, eax
mov byte [ebp - 4], 1
je 0x410291
mov ecx, eax
call fcn.0040efac
mov ebx, eax
jmp 0x410293
xor ebx, ebx
test ebx, ebx
mov byte [ebp - 4], 0
mov dword [ebp - 0x10], ebx
jne 0x4102a3
or esi, 0xffffffff
jmp 0x410300
push edi
lea eax, [ebp + 8]
push eax
mov ecx, ebx
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const__]
lea ecx, [esi + 0x30]
mov eax, dword [ecx + 4]
lea edx, [ebp - 0x10]
push edx
push eax
lea eax, [ebp - 0x14]
push eax
call fcn.0040ff5b
push 0xd
pop ecx
xor eax, eax
push eax
push eax
push 0x1004
push dword [esi + 4]
lea edi, [ebp - 0x48]
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.USER32.dll_SendMessageW]
mov dword [ebp - 0x48], 4
call edi
mov dword [ebp - 0x44], eax
lea eax, [ebp - 0x48]
push eax
push 0
push 0x104d
push dword [esi + 4]
mov dword [ebp - 0x28], ebx
call edi
mov esi, eax
pop edi
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call dword [sym.imp.MSVCP60.dll_public:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::destructor_void_]
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0x10
Function at 0x41031f
Capabilities:
Hide graphical window

Disassembly:
mov eax, 0x414a27
call fcn.00414460
sub esp, 0x10
mov eax, dword [0x417020]
push ebx
push esi
push edi
mov esi, ecx
mov dword [ebp - 0x10], eax
mov edi, dword [sym.imp.USER32.dll_GetDlgItem]
and dword [ebp - 4], 0
and dword [ebp - 0x18], 0
push 1
push dword [esi + 4]
call edi
push 2
push dword [esi + 4]
mov ebx, eax
mov dword [ebp - 0x1c], ebx
call edi
push dword [esi + 4]
mov dword [ebp - 0x14], eax
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x41045f
test ebx, ebx
je 0x41045f
cmp dword [ebp - 0x14], 0
je 0x41045f
lea eax, [ebp - 0x18]
push eax
mov ecx, esi
call fcn.0041011f
test eax, eax
je 0x410447
push 1
push ebx
mov ebx, dword [sym.imp.USER32.dll_EnableWindow]
call ebx
push 0
push dword [ebp - 0x14]
call ebx
push 1
push dword [ebp - 0x1c]
push 0x28
push dword [esi + 4]
call dword [sym.imp.USER32.dll_SendMessageW]
push 0x130
push dword [esi + 4]
call edi
test eax, eax
mov ebx, dword [sym.imp.USER32.dll_ShowWindow]
je 0x4103ce
push 0
push eax
call ebx
push 0x138
push dword [esi + 4]
call edi
test eax, eax
je 0x4103e1
push 0
push eax
call ebx
push 0x131
push dword [esi + 4]
call edi
test eax, eax
je 0x4103f4
push 0
push eax
call ebx
push 0x139
push dword [esi + 4]
call edi
test eax, eax
je 0x410407
push 0
push eax
call ebx
cmp dword [ebp - 0x18], 0
lea ecx, [ebp - 0x10]
jne 0x410417
push 0x1f4
jmp 0x41041c
push 0x1f5
call fcn.0040fc8f
test eax, eax
je 0x41045f
push dword [ebp - 0x10]
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov edi, eax
test edi, edi
je 0x41045f
lea eax, [esi + 0x1c]
mov ecx, dword [eax]
push edi
push eax
call dword [ecx + 0x34]
push edi
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
jmp 0x41045f
mov edi, dword [sym.imp.USER32.dll_EnableWindow]
push 0
push ebx
call edi
test byte [esi + 0x4c], 2
je 0x41045f
push 1
push dword [ebp - 0x14]
call edi
lea ecx, [ebp - 0x10]
call fcn.0040f307
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x410f2f
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x410f5b
push eax
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x410f5b
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
jmp 0x410f5d
xor eax, eax
ret 8

Function at 0x4137a9
Capabilities:
Create new key via cryptacquirecontext
Hash data via wincrypt
Initialize hashing via wincrypt
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x424
mov eax, dword [0x4188a0]
push edi
push 0xf0000000
xor edi, edi
push 0x18
push edi
mov dword [ebp - 4], eax
push edi
lea eax, [ebp - 0x41c]
push eax
mov dword [ebp - 0x424], 0x20
mov dword [ebp - 0x41c], edi
mov dword [ebp - 0x418], edi
mov byte [ebp - 0x14], 4
mov byte [ebp - 0x13], 0x2a
mov byte [ebp - 0x12], 0x83
mov byte [ebp - 0x11], 0x16
mov byte [ebp - 0x10], 0x70
mov byte [ebp - 0xf], 0x7e
mov byte [ebp - 0xe], 0x25
mov byte [ebp - 0xd], 0x76
mov byte [ebp - 0xc], 0x52
mov byte [ebp - 0xb], 0xc
mov byte [ebp - 0xa], 0xd9
mov byte [ebp - 9], 0x8e
mov byte [ebp - 8], 0xd8
mov byte [ebp - 7], 0x90
mov byte [ebp - 6], 0x62
mov byte [ebp - 5], 0x84
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x41391c
push ebx
push esi
lea eax, [ebp - 0x418]
push eax
push edi
push edi
push 0x800c
push dword [ebp - 0x41c]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
jne 0x413858
xor esi, esi
jmp 0x41390b
mov esi, dword [sym.imp.ADVAPI32.dll_CryptHashData]
push edi
push 0x10
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x418]
call esi
test eax, eax
jne 0x413878
xor esi, esi
jmp 0x4138ff
push 0x402844
push dword [ebp + 8]
mov dword [ebp - 0x420], edi
call dword [sym.imp.msvcrt.dll__wfopen]
mov ebx, eax
cmp ebx, edi
pop ecx
pop ecx
je 0x4138df
push ebx
push 0x400
lea eax, [ebp - 0x414]
push 1
push eax
call dword [sym.imp.msvcrt.dll_fread]
add esp, 0x10
cmp eax, edi
jbe 0x4138d7
add dword [ebp - 0x420], eax
push edi
push eax
lea eax, [ebp - 0x414]
push eax
push dword [ebp - 0x418]
call esi
test eax, eax
je 0x413929
cmp dword [ebp - 0x420], 0x1c00
jb 0x413894
push ebx
call dword [sym.imp.msvcrt.dll_fclose]
pop ecx
push edi
lea eax, [ebp - 0x424]
push eax
push dword [ebp + 0xc]
push 2
push dword [ebp - 0x418]
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
xor esi, esi
test eax, eax
je 0x4138ff
inc esi
push dword [ebp - 0x418]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push edi
push dword [ebp - 0x41c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
pop edi
call fcn.004140c6
leave
ret 8
push dword [ebp - 0x418]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push edi
push dword [ebp - 0x41c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
push ebx
call dword [sym.imp.msvcrt.dll_fclose]
pop ecx
xor eax, eax
jmp 0x41391a
Function at 0x41394e
Capabilities:
Create new key via cryptacquirecontext
Encrypt data using aes via winapi
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x4188a0]
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
push 8
pop ecx
push 0xf0000000
push 0x18
push 0x402850
xor ebx, ebx
mov dword [ebp - 4], eax
push ebx
lea eax, [ebp - 0x3c]
mov byte [ebp - 0x30], cl
mov byte [ebp - 0x2f], 2
mov word [ebp - 0x2e], bx
mov dword [ebp - 0x2c], 0x6610
mov dword [ebp - 0x28], 0x20
lea edi, [ebp - 0x24]
push eax
rep movsd dword es:[edi], dword [esi]
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x413a3b
lea eax, [ebp + 0xc]
push eax
push ebx
push ebx
push 0x2c
lea eax, [ebp - 0x30]
push eax
push dword [ebp - 0x3c]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
xor edi, edi
test eax, eax
je 0x413a2f
mov esi, dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
push ebx
lea eax, [ebp - 0x34]
push eax
push 4
push dword [ebp + 0xc]
inc edi
mov dword [ebp - 0x34], edi
call esi
test eax, eax
jne 0x4139dd
xor edi, edi
jmp 0x413a26
push ebx
lea eax, [ebp - 0x34]
push eax
push 3
push dword [ebp + 0xc]
mov dword [ebp - 0x34], edi
call esi
test eax, eax
je 0x4139d9
mov ecx, dword [ebp + 8]
call dword [sym.imp.MSVCP60.dll_public:_unsigned_int___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::size_void_const]
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.MSVCP60.dll_public:_char_const____thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::data_void_const]
push eax
push ebx
push edi
push ebx
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
je 0x4139d9
push dword [ebp - 0x38]
mov ecx, dword [ebp + 8]
call dword [sym.imp.MSVCP60.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::resize_unsigned_int_]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
push ebx
push dword [ebp - 0x3c]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, edi
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.004140c6
leave
ret 8
Function at 0x4140c6
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4188a0]
jne 0x4140cf
ret
jmp 0x4140d4
push ebp
lea ebp, [esp - 0x2a8]
sub esp, 0x328
mov eax, dword [0x4188a0]
mov dword [ebp + 0x2a4], eax
mov eax, dword [0x418a40]
test eax, eax
je 0x4140f8
call eax
cmp dword [0x418a44], 0
je 0x41413f
push edi
xor eax, eax
and dword [ebp - 0x28], eax
push 0x13
pop ecx
lea edi, [ebp - 0x7c]
rep stosd dword es:[edi], eax
mov ecx, 0xb2
lea edi, [ebp - 0x24]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x80]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x28]
push 0
mov dword [ebp - 0x80], 0xc0000409
mov dword [ebp - 0x2c], eax
call dword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
lea eax, [ebp - 0x30]
push eax
call dword [0x418a44]
pop edi
push 0x502
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov ecx, dword [ebp + 0x2a4]
call fcn.004140c6
add ebp, 0x2a8
leave
ret
Function at 0x402420
Capabilities:
Encrypt data using aes mixcolumns step

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov dword [ebp - 0x10], ecx
mov byte [ebp - 1], 0
mov eax, 1
imul ecx, eax, 0
mov dl, byte [ebp + 0xc]
mov byte [ebp + ecx - 0xc], dl
mov dword [ebp - 8], 1
jmp 0x40244e
mov eax, dword [ebp - 8]
add eax, 1
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 4
jge 0x402489
mov ecx, dword [ebp - 8]
movzx edx, byte [ebp + ecx - 0xd]
shl edx, 1
mov eax, dword [ebp - 8]
mov byte [ebp + eax - 0xc], dl
mov ecx, dword [ebp - 8]
movzx edx, byte [ebp + ecx - 0xd]
and edx, 0x80
je 0x402487
mov eax, dword [ebp - 8]
movzx ecx, byte [ebp + eax - 0xc]
xor ecx, 0x1b
mov edx, dword [ebp - 8]
mov byte [ebp + edx - 0xc], cl
jmp 0x402445
mov dword [ebp - 8], 0
jmp 0x40249b
mov eax, dword [ebp - 8]
add eax, 1
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 4
jge 0x4024c2
movzx edx, byte [ebp + 8]
mov ecx, dword [ebp - 8]
sar edx, cl
and edx, 1
je 0x4024c0
mov eax, dword [ebp - 8]
movzx ecx, byte [ebp + eax - 0xc]
movzx edx, byte [ebp - 1]
xor edx, ecx
mov byte [ebp - 1], dl
jmp 0x402492
mov al, byte [ebp - 1]
mov esp, ebp
pop ebp
ret 8

Function at 0x407d60
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x407d84
xor eax, eax
jmp 0x407e04
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x407d9b
xor eax, eax
jmp 0x407e04
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x14], eax
mov edx, dword [ebp - 4]
add edx, dword [ebp - 0x14]
mov dword [ebp - 0x10], edx
mov eax, dword [ebp + 0x10]
and eax, 0xf
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jbe 0x407de7
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp - 0x10]
jae 0x407de7
mov edx, dword [ebp - 4]
movzx eax, word [edx]
mov ecx, dword [ebp - 4]
lea edx, [ecx + eax*2 + 2]
mov dword [ebp - 4], edx
mov eax, dword [ebp - 8]
sub eax, 1
mov dword [ebp - 8], eax
jmp 0x407dbe
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp - 0x10]
jb 0x407df3
xor eax, eax
jmp 0x407e04
mov edx, dword [ebp - 4]
movzx eax, word [edx]
test eax, eax
jne 0x407e01
xor eax, eax
jmp 0x407e04
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret