joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403906
Capabilities:
Check if file exists
Get common file path

Disassembly:
push ebp
lea ebp, [esp - 0x1020]
mov eax, 0x1020
call fcn.0043f800
push 0xffffffffffffffff
push 0x447c86
mov eax, dword fs:[0]
push eax
sub esp, 0xc
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp + 0x101c], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea eax, [ebp + 0x1c]
push eax
push 0x800
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
and word [ebp + 0x101a], 0
lea eax, [ebp + 0x1c]
lea ecx, [ebp]
call fcn.00401c6e
and dword [ebp - 4], 0
lea esi, [ebp - 0x18]
lea ecx, [ebp]
call fcn.00401df6
call fcn.00401f9e
cmp word [eax], 0x5c
je 0x40399c
lea esi, [ebp - 0x18]
lea ecx, [ebp]
call fcn.00401df6
call fcn.00401f9e
cmp word [eax], 0x2f
je 0x40399c
lea eax, [ebp]
call fcn.00401e15
push str.firstrun_installer.info
lea eax, [ebp]
push eax
call fcn.00401cb3
cmp dword [ebp + 0x18], 8
mov eax, dword [ebp + 4]
jae 0x4039b6
lea eax, [ebp + 4]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4039f1
push 0
push 1
lea esi, [ebp]
call fcn.004022b6
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp + 0x101c]
xor ecx, ebp
call fcn.0042d4ab
add ebp, 0x1020
leave
ret
cmp dword [ebp + 0x18], 8
mov eax, dword [ebp + 4]
jae 0x4039fd
lea eax, [ebp + 4]
push 0x44d884
push eax
call fcn.0042d580
mov esi, eax
test esi, esi
pop ecx
pop ecx
jne 0x403a22
xor edi, edi
push 0
push 1
lea esi, [ebp]
call fcn.004022b6
mov eax, edi
jmp 0x4039cf
push str.first_run.
push 0x44d89c
push esi
call fcn.0042eefe
push esi
call fcn.0042d82b
xor edi, edi
add esp, 0x10
inc edi
jmp 0x403a12

Function at 0x403a40
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x810
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp - 4], eax
and word [ebp - 0x804], 0
push esi
lea eax, [ebp - 0x804]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
and word [ebp - 6], 0
lea eax, [ebp - 0x804]
mov esi, edi
call fcn.0040210f
cmp dword [edi + 0x14], 0
jne 0x403a8a
xor eax, eax
jmp 0x403ac8
lea esi, [ebp - 0x810]
mov ecx, edi
call fcn.00401df6
call fcn.00401f9e
cmp word [eax], 0x5c
je 0x403ac5
lea esi, [ebp - 0x810]
mov ecx, edi
call fcn.00401df6
call fcn.00401f9e
cmp word [eax], 0x2f
je 0x403ac5
push 0x44d8a0
push edi
call fcn.00401cb3
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0042d4ab
leave
ret
Function at 0x403ad5
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x2c
push ebx
push esi
mov esi, dword [0x45db3c]
push edi
push str.BITMAP7Z
push 0x84
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
xor ebx, ebx
cmp edi, ebx
jne 0x403b09
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
cmp eax, ebx
mov dword [esp + 0x10], eax
je 0x403b00
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
cmp esi, ebx
mov dword [esp + 0x14], esi
je 0x403b00
push esi
call dword [sym.imp.KERNEL32.dll_LockResource]
cmp eax, ebx
mov dword [esp + 0x1c], eax
jne 0x403b43
push esi
call dword [sym.imp.KERNEL32.dll_FreeResource]
jmp 0x403b00
push dword [esp + 0x10]
push eax
call fcn.00411e71
cmp eax, ebx
pop ecx
pop ecx
mov dword [esp + 0x18], eax
jbe 0x403b3a
push eax
call fcn.0042cfe8
mov edi, eax
cmp edi, ebx
pop ecx
je 0x403b3a
mov edx, dword [esp + 0x1c]
lea eax, [esp + 0x18]
push eax
lea esi, [esp + 0x14]
mov ecx, edi
call fcn.00411ed9
test eax, eax
pop ecx
je 0x403b8a
push edi
call fcn.0042f0fb
pop ecx
push dword [esp + 0x14]
jmp 0x403b3b
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_GetWindowDC]
cmp eax, ebx
mov dword [esp + 0x1c], eax
jne 0x403bb5
xor esi, esi
push edi
call fcn.0042f0fb
pop ecx
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
jmp 0x403b02
push ebx
push ebx
lea ecx, [esp + 0x14]
push ecx
push ebx
lea ecx, [edi + 0xe]
push ecx
push eax
mov dword [esp + 0x24], ebx
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov esi, eax
cmp esi, ebx
je 0x403c02
cmp dword [esp + 0xc], ebx
je 0x403c02
lea eax, [esp + 0x20]
push eax
push 0x18
push esi
call dword [sym.imp.GDI32.dll_GetObjectW]
mov eax, dword [esp + 0x28]
imul eax, dword [esp + 0x2c]
push eax
mov eax, dword [edi + 0xa]
add eax, edi
push eax
push dword [esp + 0x14]
call fcn.0042f100
add esp, 0xc
push dword [esp + 0x1c]
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_ReleaseDC]
jmp 0x403b9d

Function at 0x403c83
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
push edi
xor edi, edi
cmp dword [ebp + 8], edi
jne 0x403c96
xor eax, eax
jmp 0x403cf9
push edi
push 0x80
push 3
push edi
push 3
push connect
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
xor eax, eax
cmp esi, edi
je 0x403cf9
mov dword [ebp - 0xc], edi
lea edi, [ebp - 8]
stosd dword es:[edi], eax
lea eax, [ebp - 8]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
mov dword [ebp - 0xc], eax
jne 0x403ce4
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x403ce4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x403c92
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0xc]
mov dword [ebx], eax
mov eax, dword [ebp - 8]
mov dword [ebx + 4], eax
xor eax, eax
inc eax
pop edi
pop esi
leave
ret
Function at 0x403cfd
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x480
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
cmp eax, esi
push edi
mov dword [ebp - 0x47c], ecx
je 0x403df4
cmp ecx, esi
je 0x403df4
push 0x44da38
push eax
call fcn.0042d580
mov edi, eax
cmp edi, esi
pop ecx
pop ecx
je 0x403df4
push 2
push esi
push edi
call fcn.0042f54a
push edi
call fcn.0042f767
push esi
push esi
push edi
mov dword [ebp - 0x478], eax
call fcn.0042f54a
add esp, 0x1c
lea eax, [ebp - 0x474]
call fcn.004116e1
cmp dword [ebp - 0x478], esi
jbe 0x403dc4
mov ebx, 0x400
cmp dword [ebp - 0x478], ebx
ja 0x403d8b
mov ebx, dword [ebp - 0x478]
push edi
push 1
lea eax, [ebp - 0x41c]
push ebx
push eax
call fcn.0042fa71
add esp, 0x10
cmp eax, 1
jne 0x403ded
test ebx, ebx
jle 0x403dbc
lea eax, [ebp - 0x41c]
push ebx
push eax
lea esi, [ebp - 0x474]
call fcn.00411705
pop ecx
pop ecx
sub dword [ebp - 0x478], ebx
jne 0x403d78
lea ebx, [ebp - 0x18]
lea ecx, [ebp - 0x474]
call fcn.00411791
mov eax, ebx
mov ebx, dword [ebp - 0x47c]
push eax
call fcn.00411891
push edi
call fcn.0042d82b
pop ecx
xor eax, eax
pop ecx
inc eax
jmp 0x403df6
push edi
call fcn.0042d82b
pop ecx
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042d4ab
leave
ret
Function at 0x406e27
Capabilities:
Check if file exists
Create directory

Disassembly:
push 0x24
mov eax, 0x446fb0
call fcn.00431dc6
mov edi, dword [ebp + 8]
push edi
mov dword [ebp - 0x30], ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x406e4c
xor eax, eax
inc eax
jmp 0x406ed8
push 0x5c
push edi
call fcn.0042d23b
pop ecx
mov ebx, eax
xor esi, esi
cmp ebx, esi
pop ecx
push 0x2f
je 0x406e6e
push ebx
call fcn.0042d23b
cmp eax, esi
pop ecx
pop ecx
je 0x406e78
jmp 0x406e76
push edi
call fcn.0042d23b
pop ecx
pop ecx
mov ebx, eax
cmp ebx, esi
je 0x406ec9
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], esi
mov word [ebp - 0x28], si
sub ebx, edi
sar ebx, 1
push edi
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], esi
call fcn.00401cd1
cmp dword [ebp - 0x14], 8
mov eax, dword [ebp - 0x28]
jae 0x406ea6
lea eax, [ebp - 0x28]
mov ecx, dword [ebp - 0x30]
push eax
call fcn.00406e27
test eax, eax
push esi
push 1
lea esi, [ebp - 0x2c]
jne 0x406ec2
call fcn.004022b6
xor eax, eax
jmp 0x406ed8
call fcn.004022b6
xor esi, esi
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
call fcn.00431e49
ret 4

Function at 0x406ee0
Capabilities:
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x390]
sub esp, 0x410
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp + 0x38c], eax
push ebx
mov ebx, dword [ebp + 0x398]
push esi
push edi
xor edi, edi
cmp ecx, edi
mov dword [ebp - 0x80], edx
je 0x406fb6
cmp edx, edi
je 0x406fb6
mov eax, dword [ebx + 0x28]
cmp eax, edi
je 0x406f2e
push 9
push edx
push ecx
call eax
add esp, 0xc
jmp 0x406fb8
push 0x44da38
push ecx
call fcn.0042d580
mov esi, eax
cmp esi, edi
pop ecx
pop ecx
mov dword [ebp - 0x78], esi
je 0x406fb6
push 2
push edi
push esi
call fcn.0042f54a
push esi
call fcn.0042f767
push edi
push edi
push dword [ebp - 0x78]
mov esi, eax
call fcn.0042f54a
add esp, 0x1c
cmp dword [ebx + 0x24], edi
je 0x406fd2
lea eax, [esi + 1]
push eax
call fcn.0042cfe8
mov edi, eax
test edi, edi
pop ecx
je 0x406fb6
push dword [ebp - 0x78]
push esi
push 1
push edi
call fcn.0042fa71
add esp, 0x10
cmp eax, esi
jne 0x406faf
push 9
push dword [ebp - 0x80]
mov byte [edi + esi], 0
push esi
push edi
call dword [ebx + 0x24]
push edi
mov esi, eax
call fcn.0042f0fb
push dword [ebp - 0x78]
call fcn.0042d26b
add esp, 0x18
mov eax, esi
jmp 0x406fb8
push edi
call fcn.0042f0fb
pop ecx
xor eax, eax
mov ecx, dword [ebp + 0x38c]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042d4ab
add ebp, 0x390
leave
ret 4
cmp esi, edi
mov dword [ebp - 0x7c], edi
jbe 0x407011
mov ebx, 0x400
cmp esi, ebx
mov edi, ebx
ja 0x406fe6
mov edi, esi
push dword [ebp - 0x78]
lea eax, [ebp - 0x74]
push 1
push edi
push eax
call fcn.0042fa71
add esp, 0x10
cmp eax, 1
jne 0x407036
mov eax, dword [ebp - 0x7c]
push edi
lea edx, [ebp - 0x74]
call fcn.00410c33
sub esi, edi
pop ecx
mov dword [ebp - 0x7c], eax
jne 0x406fde
push dword [ebp - 0x78]
call fcn.0042d82b
push dword [ebp - 0x7c]
mov esi, dword [ebp - 0x80]
push str._02lX
push esi
call fcn.004318b5
xor eax, eax
add esp, 0x10
mov byte [esi + 8], 0
inc eax
jmp 0x406fb8
push dword [ebp - 0x78]
call fcn.0042d82b
jmp 0x406fb5
Function at 0x407043
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x480
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp - 8], eax
test ecx, ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x47c], edx
je 0x40711d
test edx, edx
je 0x40711d
mov eax, dword [edi + 0x20]
test eax, eax
je 0x407087
push 0x21
push edx
push ecx
call eax
add esp, 0xc
jmp 0x40711f
push 0x44da38
push ecx
call fcn.0042d580
mov esi, eax
test esi, esi
pop ecx
pop ecx
mov dword [ebp - 0x478], esi
je 0x40711d
push 2
push 0
push esi
call fcn.0042f54a
push esi
call fcn.0042f767
push 0
push 0
push esi
mov ebx, eax
call fcn.0042f54a
add esp, 0x1c
cmp dword [edi + 0x1c], 0
je 0x407130
lea eax, [ebx + 1]
push eax
call fcn.0042cfe8
mov esi, eax
test esi, esi
pop ecx
je 0x40711d
push dword [ebp - 0x478]
push ebx
push 1
push esi
call fcn.0042fa71
add esp, 0x10
cmp eax, ebx
jne 0x407116
push 0x21
push dword [ebp - 0x47c]
mov byte [esi + ebx], 0
push ebx
push esi
call dword [edi + 0x1c]
push esi
mov edi, eax
call fcn.0042f0fb
push dword [ebp - 0x478]
call fcn.0042d26b
add esp, 0x18
mov eax, edi
jmp 0x40711f
push esi
call fcn.0042f0fb
pop ecx
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042d4ab
leave
ret 4
lea eax, [ebp - 0x474]
call fcn.004116e1
test ebx, ebx
jbe 0x407185
mov edi, 0x400
cmp ebx, edi
ja 0x40714a
mov edi, ebx
push esi
push 1
lea eax, [ebp - 0x41c]
push edi
push eax
call fcn.0042fa71
add esp, 0x10
cmp eax, 1
jne 0x4071b1
test edi, edi
jle 0x407181
lea eax, [ebp - 0x41c]
push edi
push eax
lea esi, [ebp - 0x474]
call fcn.00411705
mov esi, dword [ebp - 0x478]
pop ecx
pop ecx
sub ebx, edi
jne 0x40713f
lea ebx, [ebp - 0x18]
lea ecx, [ebp - 0x474]
call fcn.00411791
mov eax, ebx
mov ebx, dword [ebp - 0x47c]
push eax
call fcn.00411891
push esi
call fcn.0042d82b
pop ecx
xor eax, eax
pop ecx
inc eax
jmp 0x40711f
push esi
call fcn.0042d82b
jmp 0x40711c

Function at 0x4071bc
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
push edi
xor edi, edi
push edi
push 0x80
push 3
push edi
push 3
push connect
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
xor eax, eax
cmp esi, edi
je 0x40722b
mov dword [ebp - 0xc], edi
lea edi, [ebp - 8]
stosd dword es:[edi], eax
lea eax, [ebp - 8]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
mov dword [ebp - 0xc], eax
jne 0x407216
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x407216
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x40722b
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0xc]
mov dword [ebx], eax
mov eax, dword [ebp - 8]
mov dword [ebx + 4], eax
xor eax, eax
inc eax
pop edi
pop esi
leave
ret 4
Function at 0x40725b
Capabilities:
Create thread
Resolve dns

Disassembly:
push ebp
lea ebp, [esp - 0xa0]
sub esp, 0x120
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp + 0x9c], eax
push esi
mov esi, dword [sym.imp.WS2_32.dll_inet_addr]
push ebx
call esi
cmp eax, 0xffffffff
mov dword [ebp - 0x7c], eax
jne 0x407311
push edi
lea eax, [ebp - 0x78]
push eax
mov dword [ebp - 0x78], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x4072f0
cmp dword [ebp - 0x68], 2
jne 0x4072f0
xor eax, eax
lea ecx, [ebp - 0x80]
push ecx
push eax
push ebx
push 0x407231
push eax
push eax
mov dword [ebp - 0x80], eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, eax
test edi, edi
je 0x4072f0
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x7c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
push edi
je 0x4072ea
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x7c]
jmp 0x407310
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x407300
or eax, 0xffffffff
jmp 0x407310
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
push dword [eax]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
pop edi
mov ecx, dword [ebp + 0x9c]
xor ecx, ebp
pop esi
call fcn.0042d4ab
add ebp, 0xa0
leave
ret
Function at 0x407327
Capabilities:
Check if file exists
Delete file
Move file

Disassembly:
push ebp
lea ebp, [esp - 0x1020]
mov eax, 0x1020
call fcn.0043f800
push 0xffffffffffffffff
push 0x447a42
mov eax, dword fs:[0]
push eax
push ecx
push ecx
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp + 0x101c], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
test ebx, ebx
mov edi, ecx
jne 0x40738c
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp + 0x101c]
xor ecx, ebp
call fcn.0042d4ab
add ebp, 0x1020
leave
ret
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push ebx
call esi
test eax, eax
jne 0x40739e
xor eax, eax
inc eax
jmp 0x40736a
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push ebx
call esi
test eax, eax
je 0x407399
push 0x5c
push ebx
call fcn.0042d23b
test eax, eax
pop ecx
pop ecx
push 0x2f
mov dword [ebp - 0x10], eax
push ebx
je 0x4073cd
call fcn.0042d23b
test eax, eax
pop ecx
pop ecx
je 0x4073d7
jmp 0x4073d4
call fcn.0042d23b
pop ecx
pop ecx
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x407368
add dword [ebp - 0x10], 2
lea eax, [edi + 0x7a4]
lea esi, [ebp]
call fcn.00401c8a
and dword [ebp - 4], 0
push str.delete_
mov eax, esi
push eax
call fcn.00401cb3
cmp dword [ebp + 0x18], 8
mov eax, dword [ebp + 4]
jae 0x40740c
lea eax, [ebp + 4]
push eax
mov ecx, edi
call fcn.00406e27
and dword [ebp - 0x14], 0
mov esi, 0x800
cmp dword [ebp - 0x14], 0
mov eax, dword [ebp + 4]
je 0x40744a
cmp dword [ebp + 0x18], 8
jae 0x40742f
lea eax, [ebp + 4]
push dword [ebp - 0x14]
push dword [ebp - 0x10]
push eax
push str._s_s_d
lea eax, [ebp + 0x1c]
push esi
push eax
call fcn.0042d92a
add esp, 0x18
jmp 0x407469
cmp dword [ebp + 0x18], 8
jae 0x407453
lea eax, [ebp + 4]
push dword [ebp - 0x10]
push eax
push str._s_s
lea eax, [ebp + 0x1c]
push esi
push eax
call fcn.0042d92a
add esp, 0x14
and word [ebp + 0x101a], 0
xor edi, edi
inc edi
push edi
lea eax, [ebp + 0x1c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x407496
inc dword [ebp - 0x14]
cmp dword [ebp - 0x14], 0x64
jl 0x40741d
xor edi, edi
push 0
push 1
lea esi, [ebp]
call fcn.004022b6
mov eax, edi
jmp 0x40736a
Function at 0x40c6fa
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
test ecx, ecx
push esi
mov esi, edx
jne 0x40c705
xor eax, eax
pop esi
ret
cmp eax, 8
push ebx
not esi
mov edx, 0xff
jb 0x40c7b7
push edi
mov edi, eax
shr edi, 3
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
sub eax, 8
dec edi
jne 0x40c71c
pop edi
test eax, eax
je 0x40c7d0
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x452cc0]
inc ecx
dec eax
jne 0x40c7bb
mov eax, esi
pop ebx
not eax
pop esi
ret

Function at 0x40c7d7
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov eax, dword [ecx]
xor edx, eax
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edx*4 + 0x452cc0]
shr eax, 8
xor edx, eax
mov eax, dword [ecx + 8]
mov dword [ecx], edx
movzx edx, dl
add edx, dword [ecx + 4]
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 4], edx
shr edx, 0x18
xor edx, eax
and edx, esi
shr eax, 8
xor eax, dword [edx*4 + 0x452cc0]
pop esi
mov dword [ecx + 8], eax
ret

Function at 0x40cec8
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x40cef8
push 0
lea eax, [ebp + 0x10]
push eax
push edi
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40cef3
mov byte [esi + 8], 1
mov eax, dword [ebp + 0x10]
jmp 0x40cf20
mov ecx, dword [esi + 0x1c]
mov eax, dword [esi + 0x18]
lea edx, [ecx + edi]
cmp edx, eax
jbe 0x40cf09
sub eax, ecx
mov edi, eax
mov eax, dword [esi + 0x14]
push edi
add eax, ecx
push eax
push dword [ebp + 8]
call fcn.0042f100
add esp, 0xc
add dword [esi + 0x1c], edi
mov eax, edi
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop ebp
ret
Function at 0x40db11
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
cmp dword [esi], 0
push edi
jne 0x40db8a
cmp dword [esi + 4], 0xffffffff
jne 0x40db8a
lea edi, [esi + 0x244]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push edi
call fcn.0042de1b
movzx eax, word [esi + eax*2 + 0x242]
cmp ax, 0x5c
pop ecx
je 0x40db5a
cmp ax, 0x2f
je 0x40db5a
push 0x44d8a0
push edi
call fcn.004301c8
pop ecx
pop ecx
lea eax, [ebp + 8]
push eax
push dword [ebp + 8]
call fcn.0040cdbe
test eax, eax
pop ecx
pop ecx
jne 0x40db71
mov eax, dword [ebp + 8]
jmp 0x40db8f
push eax
call fcn.0040d13c
mov dword [esi], eax
neg eax
sbb eax, eax
and eax, 0xfffffe00
pop ecx
add eax, 0x200
jmp 0x40db8f
mov eax, 0x1000000
pop edi
pop ebp
ret 4

Function at 0x40e0ed
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x45b1d4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
test ebx, ebx
push esi
mov esi, dword [ebp + 0xc]
je 0x40e121
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40e121
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx ecx, word [esi]
test cx, cx
je 0x40e1cc
mov eax, esi
mov edx, esi
movzx ecx, cx
cmp cx, 0x2f
je 0x40e140
cmp cx, 0x5c
jne 0x40e142
mov eax, edx
inc edx
inc edx
movzx ecx, word [edx]
test cx, cx
jne 0x40e134
cmp eax, esi
je 0x40e181
sub eax, esi
sar eax, 1
push edi
add eax, eax
mov edi, eax
push edi
lea eax, [ebp - 0x414]
push esi
push eax
call fcn.0042f100
and word [ebp + edi - 0x414], 0
lea eax, [ebp - 0x414]
push eax
push ebx
call fcn.0040e0ed
add esp, 0x14
pop edi
and word [ebp - 0x20c], 0
test ebx, ebx
je 0x40e19c
lea eax, [ebp - 0x20c]
push ebx
push eax
call fcn.004301f2
pop ecx
pop ecx
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.004301c8
pop ecx
pop ecx
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40e1cc
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.0042d4ab
leave
ret