joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4230a6
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
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 + 0x45b7b8]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x4230e6
cmp byte [ebx], 0xa
jne 0x4230e6
or byte [eax + edi + 0x28], 4
jmp 0x4230eb
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x4231e9
mov al, byte [edx]
cmp al, 0x1a
je 0x4231cb
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x42311a
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x42313f
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x423149
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x4230fc
jmp 0x4231e9
push 0
lea eax, [ebp - 0xc]
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 0x4231c6
cmp dword [ebp - 0xc], 0
je 0x4231c6
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x45b7b8]
test byte [eax + edi + 0x28], 0x48
je 0x4231a0
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x42318b
mov byte [esi], dl
jmp 0x42319c
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x45b7b8]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x4231e9
cmp byte [ebp - 1], 0xa
jne 0x4231af
cmp esi, ebx
jne 0x4231af
mov byte [esi], 0xa
jmp 0x4231e8
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0041b1a1
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4231e9
mov byte [esi], 0xd
jmp 0x4231e8
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x45b7b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x4231e5
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x4231e9
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x4231f2
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x45b7b8]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x423235
cmp word [esi], dx
jne 0x423235
or byte [edi + eax + 0x28], 4
jmp 0x42323a
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x42338d
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x42336d
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x42327c
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x4232b2
cmp eax, edx
jae 0x4232be
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
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 - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x423254
jmp 0x42338d
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x423369
cmp dword [ebp - 0x14], 0
je 0x423369
mov eax, dword [ebx*4 + 0x45b7b8]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x423341
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x42330a
mov word [esi], cx
jmp 0x42333d
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x45b7b8]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x45b7b8]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x45b7b8]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x42338d
pop ebx
cmp word [ebp - 4], bx
jne 0x423352
cmp esi, dword [ebp + 0xc]
jne 0x423352
mov word [esi], bx
jmp 0x42338a
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0041b1a1
add esp, 0x10
cmp word [ebp - 4], bx
je 0x42338d
push 0xd
jmp 0x423386
mov ecx, dword [ebx*4 + 0x45b7b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x423384
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x42338d
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x4010e0
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
xor edx, edx
mov eax, edx
and eax, 1
sub eax, 1
not eax
and eax, 0xedb88320
mov ecx, edx
shr ecx, 1
xor eax, ecx
mov ecx, eax
and ecx, 1
sub ecx, 1
not ecx
and ecx, 0xedb88320
shr eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
sub eax, 1
shr ecx, 1
not eax
and eax, 0xedb88320
xor eax, ecx
mov ecx, eax
and ecx, 1
sub ecx, 1
not ecx
and ecx, 0xedb88320
shr eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
sub eax, 1
shr ecx, 1
not eax
and eax, 0xedb88320
xor eax, ecx
mov ecx, eax
and ecx, 1
sub ecx, 1
not ecx
and ecx, 0xedb88320
shr eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
sub eax, 1
shr ecx, 1
not eax
and eax, 0xedb88320
xor eax, ecx
mov ecx, eax
and ecx, 1
sub ecx, 1
not ecx
and ecx, 0xedb88320
shr eax, 1
xor ecx, eax
mov dword [edx*4 + 0x416a40], ecx
add edx, 1
cmp edx, 0x100
jb 0x4010e2
cmp edx, 0x800
jae 0x4011cb
mov edi, edi
mov eax, dword [edx*4 + 0x416640]
mov ecx, eax
and ecx, 0xff
shr eax, 8
xor eax, dword [ecx*4 + 0x416a40]
add edx, 1
cmp edx, 0x800
mov dword [edx*4 + 0x416a3c], eax
jb 0x4011a0
mov dword [0x415fc0], 0x4011f0
call fcn.00404fc0
test eax, eax
jne 0x4011e8
mov dword [0x415fc0], 0x4012a0
ret

Function at 0x401cf0
Capabilities:
Read file on windows

Disassembly:
push esi
push edi
mov edi, dword [esp + 0x14]
mov esi, dword [edi]
test esi, esi
je 0x401d52
push ebx
mov ebx, dword [esp + 0x14]
push ebp
mov ebp, dword [esp + 0x14]
mov dword [edi], 0
lea esp, [esp]
cmp esi, 0x400000
mov eax, 0x400000
ja 0x401d1f
mov eax, esi
mov edx, dword [ebp]
push 0
lea ecx, [esp + 0x20]
push ecx
push eax
push ebx
push edx
mov dword [esp + 0x30], 0
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esp + 0x1c]
add dword [edi], ecx
add ebx, ecx
sub esi, ecx
test eax, eax
je 0x401d57
test ecx, ecx
je 0x401d50
test esi, esi
ja 0x401d10
pop ebp
pop ebx
pop edi
xor eax, eax
pop esi
ret
pop ebp
pop ebx
pop edi
pop esi
jmp dword [sym.imp.KERNEL32.dll_GetLastError]

Function at 0x401d70
Capabilities:
Write file on windows

Disassembly:
push esi
push edi
mov edi, dword [esp + 0x14]
mov esi, dword [edi]
test esi, esi
je 0x401dd2
push ebx
mov ebx, dword [esp + 0x14]
push ebp
mov ebp, dword [esp + 0x14]
mov dword [edi], 0
lea esp, [esp]
cmp esi, 0x400000
mov eax, 0x400000
ja 0x401d9f
mov eax, esi
mov edx, dword [ebp]
push 0
lea ecx, [esp + 0x20]
push ecx
push eax
push ebx
push edx
mov dword [esp + 0x30], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [esp + 0x1c]
add dword [edi], ecx
add ebx, ecx
sub esi, ecx
test eax, eax
je 0x401dd7
test ecx, ecx
je 0x401dd0
test esi, esi
ja 0x401d90
pop ebp
pop ebx
pop edi
xor eax, eax
pop esi
ret
pop ebp
pop ebx
pop edi
pop esi
jmp dword [sym.imp.KERNEL32.dll_GetLastError]
Function at 0x404d00
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ecx
mov ecx, dword [esp + 0x14]
push ebp
mov ebp, dword [ecx]
mov ecx, dword [esp + 0x10]
xor eax, eax
and ebp, 7
cmp ecx, 5
jae 0x404d19
pop ebp
pop ecx
ret
mov edx, dword [esp + 0xc]
push ebx
push esi
mov esi, dword [esp + 0x1c]
add esi, 5
lea edx, [edx + ecx - 4]
push edi
mov dword [esp + 0x20], esi
mov dword [esp + 0x1c], 0xffffffff
mov dword [esp + 0x10], edx
jmp 0x404d40
mov ecx, dword [esp + 0x18]
lea edi, [eax + ecx]
cmp edi, edx
jae 0x404d5f
jmp 0x404d50
mov al, byte [edi]
and al, 0xfe
cmp al, 0xe8
je 0x404d5f
add edi, 1
cmp edi, edx
jb 0x404d50
mov eax, edi
sub eax, ecx
mov ecx, eax
sub ecx, dword [esp + 0x1c]
cmp edi, edx
jae 0x404e75
cmp ecx, 3
jbe 0x404d95
xor ebp, ebp
mov cl, byte [edi + 4]
test cl, cl
mov dword [esp + 0x1c], eax
je 0x404dd3
cmp cl, 0xff
je 0x404dd3
and ebp, 3
add ebp, ebp
or ebp, 1
add eax, 1
jmp 0x404d40
add ecx, 0xffffffff
shl ebp, cl
and ebp, 7
je 0x404d78
movzx ecx, byte [ebp + 0x4121b8]
mov ebx, edi
sub ebx, ecx
cmp byte [ebp + 0x4121b0], 0
mov cl, byte [ebx + 4]
je 0x404dbf
test cl, cl
je 0x404dbf
cmp cl, 0xff
jne 0x404d78
and ebp, 3
add ebp, ebp
mov dword [esp + 0x1c], eax
or ebp, 1
add eax, 1
jmp 0x404d40
xor edx, edx
mov dh, cl
movzx ecx, byte [edi + 2]
mov dl, byte [edi + 3]
shl edx, 8
or edx, ecx
movzx ecx, byte [edi + 1]
shl edx, 8
or edx, ecx
lea esp, [esp]
cmp dword [esp + 0x28], 0
je 0x404dfe
lea ebx, [edx + eax]
add ebx, esi
jmp 0x404e04
sub edx, eax
sub edx, esi
mov ebx, edx
test ebp, ebp
je 0x404e46
movzx esi, byte [ebp + 0x4121b8]
add esi, esi
add esi, esi
add esi, esi
mov ecx, 0x18
sub ecx, esi
mov edx, ebx
shr edx, cl
test dl, dl
je 0x404e29
cmp dl, 0xff
jne 0x404e42
mov ecx, 0x20
sub ecx, esi
mov esi, dword [esp + 0x20]
mov edx, 1
shl edx, cl
sub edx, 1
xor edx, ebx
jmp 0x404df0
mov esi, dword [esp + 0x20]
mov edx, ebx
shr edx, 0x18
and dl, 1
sub dl, 1
not dl
mov byte [edi + 4], dl
mov edx, ebx
shr edx, 8
mov ecx, ebx
shr ecx, 0x10
mov byte [edi + 2], dl
mov edx, dword [esp + 0x10]
mov byte [edi + 3], cl
mov byte [edi + 1], bl
add eax, 5
jmp 0x404d40
cmp ecx, 3
pop edi
pop esi
pop ebx
jbe 0x404e88
mov ecx, dword [esp + 0x18]
xor ebp, ebp
mov dword [ecx], ebp
pop ebp
pop ecx
ret
add ecx, 0xffffffff
shl ebp, cl
mov ecx, dword [esp + 0x18]
and ebp, 7
mov dword [ecx], ebp
pop ebp
pop ecx
ret
Function at 0x406eb0
Capabilities:
Extract resource via kernel32 functions
Print debug messages

Disassembly:
sub esp, 0x20c
mov eax, dword [0x415060]
xor eax, esp
mov dword [esp + 0x208], eax
push esi
mov esi, dword [esp + 0x214]
push edi
mov edi, dword [esp + 0x21c]
push 0x1fe
lea eax, [esp + 0x16]
push 0
push eax
mov dword [esp + 0x18], 0
mov word [esp + 0x1c], 0
call fcn.00408150
push esi
push edi
lea ecx, [esp + 0x24]
push str._s_s
push ecx
mov edx, 0x100
call fcn.00406da0
add esp, 0x1c
push 0x412438
push 0x66
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x406f53
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str._nERROR:
call esi
push str.find_resource_failed_
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004080b5
add esp, 0x20c
ret
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
test eax, eax
mov dword [esp + 0xc], eax
jne 0x406f95
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str._nERROR:
call esi
push str.resource_is_empty_
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004080b5
add esp, 0x20c
ret
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x406fd3
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str._nERROR:
call esi
push str.load_resource_failed_
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004080b5
add esp, 0x20c
ret
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
lea edx, [esp + 8]
push edx
mov esi, eax
call fcn.00401c30
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x10]
push ecx
call fcn.00401c80
add esp, 0xc
test eax, eax
je 0x40702c
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str._nERROR:
call esi
push str.can_not_create_file
call esi
pop edi
mov eax, 0xb
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004080b5
add esp, 0x20c
ret
lea edx, [esp + 0xc]
push edx
lea eax, [esp + 0xc]
push esi
push eax
call fcn.00401d70
add esp, 0xc
test eax, eax
je 0x40706c
push str.can_not_open_write_file
call fcn.00406dc0
add esp, 4
pop edi
mov eax, 9
pop esi
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004080b5
add esp, 0x20c
ret
lea ecx, [esp + 8]
push ecx
call fcn.00401cc0
mov ecx, dword [esp + 0x214]
add esp, 4
pop edi
pop esi
xor ecx, esp
xor eax, eax
call fcn.004080b5
add esp, 0x20c
ret
Function at 0x4076a0
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
sub esp, 0x654
mov eax, dword [0x415060]
xor eax, esp
mov dword [esp + 0x650], eax
push ebp
push edi
mov edi, dword [esp + 0x660]
push 0x1fe
lea eax, [esp + 0x45e]
push 0
push eax
mov word [esp + 0x464], 0
call fcn.00408150
push 0x1fe
lea ecx, [esp + 0x26a]
push 0
push ecx
mov word [esp + 0x270], 0
call fcn.00408150
lea edx, [esp + 0x470]
push edi
push edx
mov edx, str._s.
call fcn.00406da0
add esp, 0x20
lea eax, [esp + 8]
push eax
lea ecx, [esp + 0x45c]
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x407742
pop edi
xor eax, eax
pop ebp
mov ecx, dword [esp + 0x650]
xor ecx, esp
call fcn.004080b5
add esp, 0x654
ret
lea edx, [esp + 8]
push edx
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
je 0x40782d
jmp 0x407760
mov ecx, 0x412564
lea eax, [esp + 0x34]
lea esp, [esp]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x407796
test dx, dx
je 0x407792
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x407796
add eax, 4
add ecx, 4
test dx, dx
jne 0x407770
xor eax, eax
jmp 0x40779b
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x407819
mov ecx, 0x41255c
lea eax, [esp + 0x34]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4077ce
test dx, dx
je 0x4077ca
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4077ce
add eax, 4
add ecx, 4
test dx, dx
jne 0x4077a8
xor eax, eax
jmp 0x4077d3
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x407819
lea eax, [esp + 0x34]
push eax
lea ecx, [esp + 0x25c]
push edi
push ecx
mov edx, str._s_s
call fcn.00406da0
add esp, 0xc
test byte [esp + 8], 0x10
je 0x40780b
lea edx, [esp + 0x258]
push edx
call fcn.004076a0
add esp, 4
jmp 0x407819
lea eax, [esp + 0x258]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 8]
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x407760
push ebp
call dword [sym.imp.KERNEL32.dll_FindClose]
push edi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov ecx, dword [esp + 0x658]
pop edi
pop ebp
xor ecx, esp
mov eax, 1
call fcn.004080b5
add esp, 0x654
ret
Function at 0x407860
Capabilities:
Create process on windows
Print debug messages

Disassembly:
sub esp, 0x240
mov eax, dword [0x415060]
xor eax, esp
mov dword [esp + 0x23c], eax
push ebx
mov ebx, dword [esp + 0x250]
push esi
mov esi, dword [esp + 0x24c]
push edi
mov edi, dword [esp + 0x254]
push 0x1fe
lea eax, [esp + 0x4e]
push 0
push eax
mov word [esp + 0x54], 0
call fcn.00408150
push edi
push esi
lea ecx, [esp + 0x5c]
push str._s_s
push ecx
mov edx, 0x100
call fcn.00406da0
push 0x3c
lea edx, [esp + 0x2c]
push 0
push edx
call fcn.00408150
add esp, 0x28
lea ecx, [esp + 0xc]
lea eax, [esp + 0x48]
push ecx
mov dword [esp + 0x10], 0x3c
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], str.open
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], ebx
mov dword [esp + 0x2c], 1
mov dword [esp + 0x14], 0x40
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push str._nERROR:
je 0x40793e
call esi
push str.ShellExecute_succeed_
call esi
mov eax, dword [esp + 0x44]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x23c]
xor ecx, esp
call fcn.004080b5
add esp, 0x240
ret
call esi
push str.ShellExecute_failed_
call esi
mov ecx, dword [esp + 0x248]
pop edi
pop esi
pop ebx
xor ecx, esp
xor eax, eax
call fcn.004080b5
add esp, 0x240
ret
Function at 0x407970
Capabilities:
Check mutex on windows
Create directory
Get common file path
Print debug messages

Disassembly:
sub esp, 0x604
mov eax, dword [0x415060]
xor eax, esp
mov dword [esp + 0x600], eax
push ebx
push ebp
push esi
push edi
xor ebp, ebp
push 0x1fe
lea eax, [esp + 0x16]
push ebp
push eax
mov word [esp + 0x1c], bp
call fcn.00408150
mov ecx, 8
mov esi, str.LOREX_Player.exe
lea edi, [esp + 0x41c]
rep movsd dword es:[edi], dword [esi]
push 0x1de
lea ecx, [esp + 0x442]
push ebp
push ecx
movsw word es:[edi], word [esi]
call fcn.00408150
push 0x1fe
lea edx, [esp + 0x22e]
push ebp
push edx
mov word [esp + 0x234], bp
call fcn.00408150
mov ebx, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
add esp, 0x24
push str._nERROR:
call ebx
push str.start_7zUnzip_main_
call ebx
push 1
push 0x1a
lea eax, [esp + 0x18]
push eax
push ebp
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
jne 0x407a24
lea ecx, [esp + 0x10]
push 0x41269c
push ecx
mov edx, 0x100
call fcn.00406da0
add esp, 8
push str.LOREXPlayer
lea edx, [esp + 0x14]
push edx
mov eax, edx
push str._s_s
push eax
mov edx, 0x100
call fcn.00406da0
add esp, 0x10
push str.smartplayerclient
push 1
push ebp
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebp
cmp eax, 0xb7
jne 0x407a75
push str._nERROR:
call ebx
push str.app_running_
call ebx
xor eax, eax
jmp 0x407b8c
mov esi, 0x100
lea edi, [esp + 0x210]
call fcn.00406de0
test eax, eax
je 0x407a9f
push str._nERROR:
call ebx
push str.can_not_get_module_path_
call ebx
xor eax, eax
jmp 0x407b8c
lea ecx, [esp + 0x210]
push ecx
push str.7zDecode_start______s_n
call fcn.0040895b
mov esi, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
add esp, 8
push 0
lea edx, [esp + 0x14]
push edx
call esi
test eax, eax
jne 0x407af9
call ebp
cmp eax, 0xb7
jne 0x407af9
lea eax, [esp + 0x10]
push eax
call fcn.004076a0
add esp, 4
test eax, eax
je 0x407aec
push 0
lea ecx, [esp + 0x14]
push ecx
call esi
jmp 0x407af9
push str.Remove_directory_failed_
call fcn.00406dc0
add esp, 4
lea edx, [esp + 0x10]
push edx
push str.SmartPlayer.7z
call fcn.00406eb0
add esp, 8
test eax, eax
je 0x407b21
push str._nERROR:
call ebx
push str.load_zip_resource_failed_
call ebx
xor eax, eax
jmp 0x407b8c
push 1
lea edx, [esp + 0x14]
mov ecx, str.SmartPlayer.7z
call fcn.004070a0
add esp, 4
test eax, eax
jne 0x407b79
push str._nERROR:
call ebx
push str.Extract7zZip_succeed_
call ebx
lea eax, [esp + 0x210]
push eax
lea ecx, [esp + 0x414]
push ecx
lea edx, [esp + 0x18]
push edx
call fcn.00407860
mov esi, eax
add esp, 0xc
test esi, esi
je 0x407b72
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str._nERROR:
call ebx
push str.exit_main_
call ebx
mov eax, 1
mov ecx, dword [esp + 0x610]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004080b5
add esp, 0x604
ret

Function at 0x4080b5
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x415060]
jne 0x4080bf
repz ret
jmp fcn.0040a104
Function at 0x409d02
Capabilities:
Write file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
xor esi, esi
xor edi, edi
cmp ebx, dword [edi*8 + 0x4151a0]
je 0x409d1d
inc edi
cmp edi, 0x17
jb 0x409d0e
cmp edi, 0x17
jae 0x409e9d
push ebp
push 3
call fcn.0040d700
cmp eax, 1
pop ecx
je 0x409e69
push 3
call fcn.0040d700
test eax, eax
pop ecx
jne 0x409d51
cmp dword [0x415070], 1
je 0x409e69
cmp ebx, 0xfc
je 0x409e9c
push str.Runtime_Error__n_nProgram:
mov ebx, 0x314
push ebx
mov ebp, 0x416178
push ebp
call fcn.0040d69b
add esp, 0xc
test eax, eax
je 0x409d87
push esi
push esi
push esi
push esi
push esi
call fcn.0040ac27
add esp, 0x14
push 0x104
mov esi, 0x416191
push esi
push 0
mov byte [0x416295], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x409dcb
push str._program_name_unknown_
push 0x2fb
push esi
call fcn.0040d69b
add esp, 0xc
test eax, eax
je 0x409dcb
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.0040ac27
add esp, 0x14
push esi
call fcn.0040d610
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x409e10
push esi
call fcn.0040d610
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x41648c
push 0x412c84
sub ecx, eax
push ecx
push eax
call fcn.0040d553
add esp, 0x14
test eax, eax
je 0x409e10
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.0040ac27
add esp, 0x14
jmp 0x409e12
xor esi, esi
push 0x412c80
push ebx
push ebp
call fcn.0040d4e2
add esp, 0xc
test eax, eax
je 0x409e32
push esi
push esi
push esi
push esi
push esi
call fcn.0040ac27
add esp, 0x14
push dword [edi*8 + 0x4151a4]
push ebx
push ebp
call fcn.0040d4e2
add esp, 0xc
test eax, eax
je 0x409e54
push esi
push esi
push esi
push esi
push esi
call fcn.0040ac27
add esp, 0x14
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.0040d325
add esp, 0xc
jmp 0x409e9c
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x409e9c
cmp ebp, 0xffffffff
je 0x409e9c
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x4151a4]
push dword [esi]
call fcn.0040d610
pop ecx
push eax
push dword [esi]
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret
Function at 0x40d325
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
call fcn.0040a3c8
xor ebx, ebx
cmp dword [0x416918], ebx
mov dword [ebp - 8], eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
jne 0x40d3fb
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40d4db
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
cmp eax, ebx
je 0x40d4db
push eax
call fcn.0040a35a
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x416918], eax
call esi
push eax
call fcn.0040a35a
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x41691c], eax
call esi
push eax
call fcn.0040a35a
mov dword [0x416920], eax
lea eax, [ebp - 0xc]
push eax
call fcn.00409a8f
test eax, eax
pop ecx
pop ecx
je 0x40d3c9
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.0040ac27
add esp, 0x14
cmp dword [ebp - 0xc], 2
jne 0x40d3fb
push str.GetUserObjectInformationA
push edi
call esi
push eax
call fcn.0040a35a
cmp eax, ebx
pop ecx
mov dword [0x416928], eax
je 0x40d3fb
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.0040a35a
pop ecx
mov dword [0x416924], eax
mov eax, dword [0x416924]
mov ecx, dword [ebp - 8]
cmp eax, ecx
je 0x40d480
cmp dword [0x416928], ecx
je 0x40d480
push eax
call fcn.0040a3d1
push dword [0x416928]
mov esi, eax
call fcn.0040a3d1
cmp esi, ebx
pop ecx
pop ecx
mov edi, eax
je 0x40d480
cmp edi, ebx
je 0x40d480
call esi
cmp eax, ebx
je 0x40d44d
lea ecx, [ebp - 0x14]
push ecx
push 0xc
lea ecx, [ebp - 0x20]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x40d44d
test byte [ebp - 0x18], 1
jne 0x40d480
lea eax, [ebp - 0x10]
push eax
call fcn.00409ac6
test eax, eax
pop ecx
je 0x40d468
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.0040ac27
add esp, 0x14
cmp dword [ebp - 0x10], 4
jb 0x40d477
or dword [ebp + 0x10], 0x200000
jmp 0x40d4bb
or dword [ebp + 0x10], 0x40000
jmp 0x40d4bb
mov eax, dword [0x41691c]
cmp eax, dword [ebp - 8]
je 0x40d4bb
push eax
call fcn.0040a3d1
cmp eax, ebx
pop ecx
je 0x40d4bb
call eax
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x40d4bb
mov eax, dword [0x416920]
cmp eax, dword [ebp - 8]
je 0x40d4bb
push eax
call fcn.0040a3d1
cmp eax, ebx
pop ecx
je 0x40d4bb
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x416918]
call fcn.0040a3d1
cmp eax, ebx
pop ecx
je 0x40d4db
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x40d4dd
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret