joyce8/EMBER2024-capa huggingface dataset:
Function at 0x427100
Capabilities:
Encode data using xor
Generate random numbers using the delphi lcg

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp byte [esi + 0x2d], 0
push edi
mov edi, dword [ebp + 0xc]
mov eax, ebx
je 0x4271eb
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x427137
cmp dword [esi + 0x40], edi
jae 0x427137
push eax
call fcn.0042a4d9
add esp, 4
mov dword [esi + 0x3c], 0
cmp dword [esi + 0x3c], 0
jne 0x42714f
lea eax, [edi + edi]
push eax
call fcn.0042b111
add esp, 4
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], edi
mov ecx, dword [esi + 0x3c]
push edi
push ebx
push ecx
call fcn.0042a730
add esp, 0xc
xor ebx, ebx
test edi, edi
je 0x4271e8
mov edx, dword [esi + 0x3c]
mov cl, byte [ebx + edx]
mov edi, dword [esi + 0x30]
mov byte [ebp + 8], cl
movsx ecx, cl
xor ecx, edi
and ecx, 0xff
mov ecx, dword [ecx*4 + 0x448280]
mov dword [ebp - 4], ecx
mov eax, dword [esi + 0x38]
shr edi, 8
xor dword [ebp - 4], edi
mov ecx, dword [ebp - 4]
mov dword [esi + 0x30], ecx
movzx ecx, cl
add ecx, dword [esi + 0x34]
mov edx, eax
imul ecx, ecx, 0x8088405
inc ecx
mov dword [esi + 0x34], ecx
shr ecx, 0x18
xor ecx, eax
shr eax, 8
and ecx, 0xff
xor eax, dword [ecx*4 + 0x448280]
and edx, 0xfffd
mov dword [esi + 0x38], eax
mov ecx, dword [esi + 0x3c]
or edx, 2
mov eax, edx
xor eax, 1
imul eax, edx
shr eax, 8
xor al, byte [ebp + 8]
inc ebx
mov byte [ebx + ecx - 1], al
cmp ebx, dword [ebp + 0xc]
jb 0x427167
mov edi, dword [ebp + 0xc]
mov eax, dword [esi + 0x3c]
mov edx, dword [esi + 0x20]
test edx, edx
je 0x42722a
mov ecx, dword [esi + 0x24]
lea ebx, [ecx + edi]
cmp ebx, dword [esi + 0x28]
jb 0x42720f
pop edi
mov dword [esi + 0x14], 0x30000
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 8
push edi
push eax
add ecx, edx
push ecx
call fcn.0042a730
add esp, 0xc
add dword [esi + 0x24], edi
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x42724c
push 0
lea edx, [ebp + 0xc]
push edx
push edi
push eax
push ecx
call dword [0x462f38]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
pop edi
mov dword [esi + 0x14], 0x1000000
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x4287e0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
xor ebx, ebx
xor edi, edi
mov dword [esi + 0x6af80], 2
cmp dword [esi + 0x6af90], ebx
je 0x4289f5
cmp dword [esi + 0x6af90], 3
jb 0x428857
mov ecx, dword [esi + 0x6af84]
movzx eax, byte [ecx + esi + 0x1af72]
mov edx, dword [esi + 0x6af7c]
shl edx, 5
xor eax, edx
and eax, 0x7fff
mov dword [esi + 0x6af7c], eax
mov ebx, dword [esi + eax*4 + 0x4af70]
and ecx, 0x7fff
mov dword [esi + ecx*4 + 0x2af70], ebx
mov eax, dword [esi + 0x6af7c]
mov ecx, dword [esi + 0x6af84]
mov dword [esi + eax*4 + 0x4af70], ecx
test ebx, ebx
je 0x428897
mov edx, dword [esi + 0x6af84]
sub edx, ebx
cmp edx, 0x7efa
ja 0x428897
mov eax, dword [esi + 0x6af90]
cmp dword [esi + 0x6afa0], eax
jbe 0x42887f
mov dword [esi + 0x6afa0], eax
push ebx
push esi
call fcn.00425f30
mov edi, eax
mov eax, dword [esi + 0x6af90]
add esp, 8
cmp edi, eax
jbe 0x428897
mov edi, eax
mov ecx, dword [esi + 0x6af84]
cmp edi, 3
jb 0x428974
sub ecx, dword [esi + 0x6af88]
lea eax, [edi - 3]
push eax
push ecx
push esi
call fcn.00425a00
sub dword [esi + 0x6af90], edi
add esp, 0xc
mov dword [ebp + 8], eax
mov eax, dword [esi + 0x6af90]
cmp edi, dword [esi + 0x6af98]
ja 0x42893e
cmp eax, 3
jb 0x42893e
mov eax, 1
sub edi, eax
lea ecx, [ecx]
add dword [esi + 0x6af84], eax
mov edx, dword [esi + 0x6af84]
movzx ecx, byte [esi + edx + 0x1af72]
mov ebx, dword [esi + 0x6af7c]
shl ebx, 5
xor ecx, ebx
and ecx, 0x7fff
mov dword [esi + 0x6af7c], ecx
mov ebx, dword [esi + ecx*4 + 0x4af70]
and edx, 0x7fff
sub edi, eax
mov dword [esi + edx*4 + 0x2af70], ebx
mov edx, dword [esi + 0x6af7c]
mov ecx, dword [esi + 0x6af84]
mov dword [esi + edx*4 + 0x4af70], ecx
jne 0x4288e0
add dword [esi + 0x6af84], eax
jmp 0x428997
add dword [esi + 0x6af84], edi
mov edx, dword [esi + 0x6af84]
movzx ecx, byte [edx + esi + 0x1af70]
mov dword [esi + 0x6af7c], ecx
movzx eax, byte [edx + esi + 0x1af71]
shl ecx, 5
xor eax, ecx
xor edi, edi
and eax, 0x7fff
mov dword [esi + 0x6af7c], eax
jmp 0x428997
movzx edx, byte [ecx + esi + 0x1af70]
push edx
push 0
push esi
call fcn.00425a00
dec dword [esi + 0x6af90]
add esp, 0xc
inc dword [esi + 0x6af84]
mov dword [ebp + 8], eax
cmp dword [ebp + 8], 0
je 0x4289d3
mov eax, dword [esi + 0x6af74]
test eax, eax
js 0x4289b0
lea ecx, [eax + esi + 0x1af70]
jmp 0x4289b2
xor ecx, ecx
mov edx, dword [esi + 0x6af84]
push 0
sub edx, eax
push edx
push ecx
push esi
call fcn.00428650
mov eax, dword [esi + 0x6af84]
add esp, 0x10
mov dword [esi + 0x6af74], eax
cmp dword [esi + 0x6af90], 0x106
jae 0x4289e8
push esi
call fcn.00426090
add esp, 4
cmp dword [esi + 0x6af90], 0
jne 0x428803
mov eax, dword [esi + 0x6af74]
test eax, eax
js 0x428a08
lea ecx, [eax + esi + 0x1af70]
jmp 0x428a0a
xor ecx, ecx
mov edx, dword [esi + 0x6af84]
push 1
sub edx, eax
push edx
push ecx
push esi
call fcn.00428650
add esp, 0x10
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x401000
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
je 0x401090
push ebp
mov ebp, dword [esp + 0x14]
push edi
mov edi, dword [esp + 0x10]
push ebx
cmp byte [esi], 0
je 0x40108d
push 0x5c
push esi
call dword [sym.imp.MSVCRT.dll_strchr]
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x40108d
push edi
mov byte [esi], 0
call dword [sym.imp.kernel32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x401066
push 0
push edi
call dword [sym.imp.kernel32.dll_CreateDirectoryA]
test eax, eax
jne 0x40105f
test ebp, ebp
je 0x40105f
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
jmp 0x401066
push edi
push 1
call ebp
pop ecx
pop ecx
test bl, 0x10
jne 0x401087
push 0xb7
call dword [sym.imp.kernel32.dll_SetLastError]
test ebp, ebp
je 0x401087
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
mov byte [esi], 0x5c
inc esi
jne 0x401018
pop ebx
pop edi
pop ebp
xor eax, eax
inc eax
pop esi
ret

Function at 0x40287f
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
pushal
call 0x40288e
pop dword [ebp - 0x48]
mov eax, 0x385f3b83
sub eax, 0x381f12f5
sub dword [ebp - 0x48], eax
mov dword [ebp - 0x58], 0x9b88b6a5
sub dword [ebp - 0x58], 0x4d36715a
mov dword [ebp - 0x54], 0x51018abb
add dword [ebp - 0x54], 0xe131c18a
mov dword [ebp - 0x50], 0xb0e854cf
add dword [ebp - 0x50], 0x9b63ef5f
mov dword [ebp - 0x4c], 0xae00c7fb
sub dword [ebp - 0x4c], 0xae00c7fb
lea eax, [ebp - 0x58]
push eax
mov eax, 0x6949bd34
add eax, 0x96f6b330
add eax, dword [ebp - 0x48]
call dword [eax]
mov dword [ebp - 0x58], 0xc286b9a4
add dword [ebp - 0x58], 0xb1ebafb2
mov dword [ebp - 0x54], 0x545764af
sub dword [ebp - 0x54], 0x12eb033a
mov dword [ebp - 0x50], 0xb4a3c38f
add dword [ebp - 0x50], 0xaecba8dd
mov dword [ebp - 0x4c], 0x6625e9d5
sub dword [ebp - 0x4c], 0x6625e9d5
lea ebx, [ebp - 0x58]
push ebx
push eax
mov eax, 0xa8dea572
add eax, 0x5761cb36
add eax, dword [ebp - 0x48]
call dword [eax]
push 0x40
push 0x1000
push 0x3b816
push 0
call eax
mov ecx, 0x5426394b
sub ecx, 0x5425dda8
xor edx, edx
add edx, eax
mov ebx, 0xb77fc40
add ebx, 0xf4c903c0
add ebx, dword [ebp - 0x48]
mov esi, 0x4cc4d5b
add esi, 0x8428b5e9
add dword [ebp - 0x20], 0x259a0953
mov edi, dword [ebx]
add dword [ebp - 0xc], 0xf129d0c2
add edi, esi
xor dword [ebp - 8], edi
mov dword [edx], edi
sub dword [ebp - 0x40], ebx
add edx, 4
add ebx, 4
loop 0x4029b2
add eax, 0x1615f
mov ebx, eax
add eax, 0xc3ed7ce6
sub eax, 0xc3ed7ce1
mov ecx, 0x62d546a1
sub ecx, 0x629546a1
add ecx, dword [ebp - 0x48]
call ebx
leave
ret
Function at 0x10027420
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
mov eax, dword [esp + 0x10]
push edi
push 0
push 0x20
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x100274b2
mov eax, dword [esp + 0x10]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push esi
mov dword [esp + 0x10], ebx
jle 0x100274a4
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x1002749c
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x10027465
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret
mov dword [esp + 0x10], 0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret

Function at 0x100274c0
Capabilities:
Set file attributes

Disassembly:
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 8]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
ret

Function at 0x10028970
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push ebp
mov ebp, edx
push esi
push edi
mov esi, ebp
xor edi, edi
and esi, 3
mov eax, ecx
jle 0x10028991
mov dl, byte [eax]
inc eax
cmp dl, bl
je 0x100289eb
inc edi
cmp edi, esi
jl 0x10028985
mov edi, ebx
and edi, 0xff
mov esi, edi
shl esi, 8
or esi, edi
shl esi, 8
or esi, edi
shl esi, 8
or esi, edi
lea edi, [ecx + ebp]
cmp eax, edi
jae 0x10028a20
mov edx, dword [eax]
xor edx, esi
lea ebp, [edx - 0x1010101]
not edx
and ebp, edx
test ebp, 0x80808080
je 0x100289da
cmp byte [eax], bl
je 0x100289f5
cmp byte [eax + 1], bl
je 0x100289fe
cmp byte [eax + 2], bl
je 0x10028a08
cmp byte [eax + 3], bl
je 0x10028a14
add eax, 4
cmp eax, edi
jb 0x100289b1
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
ret 4
pop edi
sub eax, ecx
pop esi
pop ebp
dec eax
pop ebx
ret 4
pop edi
pop esi
pop ebp
sub eax, ecx
pop ebx
ret 4
pop edi
sub eax, ecx
pop esi
pop ebp
inc eax
pop ebx
ret 4
pop edi
sub eax, ecx
pop esi
pop ebp
add eax, 2
pop ebx
ret 4
pop edi
sub eax, ecx
pop esi
pop ebp
add eax, 3
pop ebx
ret 4
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
ret 4
Function at 0x10029d70
Capabilities:
Enumerate processes
Terminate process

Disassembly:
push 0xffffffffffffffff
push 0x10043f2b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x130
push esi
mov esi, dword [esp + 0x144]
push esi
lea ecx, [esp + 8]
mov dword [esp + 0xc], 0
call fcn.1003c10e
mov eax, dword [esp + 0x148]
test eax, eax
jne 0x10029e42
mov eax, dword [esp + 4]
mov ecx, dword [eax - 8]
test ecx, ecx
jne 0x10029dda
lea ecx, [esp + 4]
mov dword [esp + 0x13c], 0xffffffff
call fcn.1003c0a0
xor eax, eax
jmp 0x10029e92
push esi
push 0
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
je 0x10029df5
lea ecx, [esp + 8]
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
jmp 0x10029e46
push 0
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
lea edx, [esp + 0xc]
mov esi, eax
push edx
push esi
mov dword [esp + 0x14], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x10029e46
mov ecx, dword [esp + 4]
lea eax, [esp + 0x30]
push eax
push ecx
call fcn.1002edaf
add esp, 8
test eax, eax
je 0x10029e3e
lea edx, [esp + 0xc]
push edx
push esi
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x10029e17
jmp 0x10029e46
mov eax, dword [esp + 0x14]
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
test eax, eax
jne 0x10029e66
lea ecx, [esp + 4]
mov dword [esp + 0x13c], 0xffffffff
call fcn.1003c0a0
xor eax, eax
jmp 0x10029e92
push eax
push 0
push 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
lea ecx, [esp + 4]
mov esi, eax
mov dword [esp + 0x13c], 0xffffffff
call fcn.1003c0a0
mov eax, esi
mov ecx, dword [esp + 0x134]
pop esi
mov dword fs:[0], ecx
add esp, 0x13c
ret 8

Function at 0x1002a090
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0xa0
push ebx
push ebp
mov ebp, dword [esp + 0xac]
push esi
push edi
push ebp
call sub.RASAPI32.dll_RasHangUpA
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x28
xor eax, eax
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], 0xa0
call esi
mov edi, eax
call esi
sub eax, edi
cmp eax, 0xbb8
jae 0x1002a0f6
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [esp + 0x10]
push eax
push ebp
call sub.RASAPI32.dll_RasGetConnectStatusA
cmp eax, 6
je 0x1002a0f6
push 0
call ebx
call esi
sub eax, edi
cmp eax, 0xbb8
jb 0x1002a0d7
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret

Function at 0x1002a480
Capabilities:
Create http request

Disassembly:
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x1002a4b8
mov edx, dword [esi + 4]
xor eax, eax
push 0
push 0
mov ecx, dword [edx - 8]
test ecx, ecx
setne al
mov ecx, eax
neg ecx
sbb ecx, ecx
and ecx, edx
neg eax
sbb eax, eax
push ecx
and eax, 2
inc eax
push eax
push str.Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.0_
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [esi], eax
mov ecx, dword [esi]
xor eax, eax
test ecx, ecx
setne al
pop esi
ret
Function at 0x1002b0f0
Capabilities:
Get socket status

Disassembly:
sub esp, 0x10c
mov eax, dword [ecx]
lea ecx, [esp]
push ecx
push 0
lea edx, [esp + 0x10]
push 0
push edx
push 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 1
call sub.WS2_32.dll_select
cmp eax, 0xffffffff
jne 0x1002b139
xor eax, eax
add esp, 0x10c
ret 4
mov edx, dword [esp + 0x110]
xor ecx, ecx
test eax, eax
setne cl
mov dword [edx], ecx
mov eax, 1
add esp, 0x10c
ret 4

Function at 0x1002b5b0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x10044170
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
lea ecx, [esp + 4]
call fcn.1002b160
lea eax, [esp + 4]
lea ecx, [esi + 4]
push eax
mov dword [esp + 0x18], 0
call fcn.1002b1e0
lea ecx, [esp + 4]
push ecx
lea ecx, [esi + 0x14]
call fcn.1002b1e0
lea ecx, [esi + 0xc]
call fcn.1003c02b
lea ecx, [esi + 0x10]
call fcn.1003c02b
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x1c]
call fcn.1002c770
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x30]
call fcn.1002c770
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x44]
call fcn.1002c770
lea ecx, [esp + 8]
mov dword [esp + 0x14], 1
call fcn.1003c0a0
lea ecx, [esp + 4]
mov dword [esp + 0x14], 0xffffffff
call fcn.1003c0a0
mov ecx, dword [esp + 0xc]
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x1003f5df
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x1003f621
call fcn.10042357
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x1003f621
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x1003f618
xor eax, eax
jmp 0x1003f629
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.1003f62f
pop edi
pop esi
pop ebx
ret 4
Function at 0x403be7
Capabilities:
Get common file path

Disassembly:
mov eax, 0x4082e8
call fcn.00407ca0
sub esp, 0x34
and dword [ebp - 0x40], 0
push 0x4e20
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x1c], eax
push dword [ebp - 0x1c]
push 0x2710
call dword [sym.imp.KERNEL32.DLL_GetTempPathW]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x403c48
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x28], eax
push dword [ebp - 0x28]
call fcn.00407c65
pop ecx
lea ecx, [ebp - 0x38]
call fcn.00404cb2
push 0x40d238
lea eax, [ebp - 0x38]
push eax
call sub.MSVCRT.dll__CxxThrowException
push dword [ebp - 0x1c]
lea ecx, [ebp - 0x18]
call fcn.004031fa
mov dword [ebp - 4], 1
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x3c], eax
push dword [ebp - 0x3c]
call fcn.00407c65
pop ecx
lea eax, [ebp - 0x18]
push eax
mov ecx, dword [ebp + 8]
call fcn.004032ba
mov eax, dword [ebp - 0x40]
or al, 1
mov dword [ebp - 0x40], eax
and byte [ebp - 4], 0
lea ecx, [ebp - 0x18]
call fcn.004035e9
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret

Function at 0x404084
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x40838d
call fcn.00407ca0
sub esp, 0x2c
mov dword [ebp - 0x38], ecx
and dword [ebp - 0x10], 0
mov eax, dword [ebp - 0x38]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x34], eax
push 0
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.DLL_ReadFile]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jne 0x4040ed
push 0x41aed8
lea ecx, [ebp - 0x30]
call fcn.00403224
and dword [ebp - 4], 0
lea eax, [ebp - 0x30]
push eax
push dword [ebp - 0x38]
lea ecx, [ebp - 0x24]
call fcn.00404671
push 0x40d400
lea eax, [ebp - 0x24]
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret 8

Function at 0x404178
Capabilities:
Write file on windows

Disassembly:
mov eax, 0x4083b5
call fcn.00407ca0
sub esp, 0x2c
mov dword [ebp - 0x38], ecx
and dword [ebp - 0x10], 0
mov eax, dword [ebp - 0x38]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x34], eax
push 0
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.DLL_WriteFile]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jne 0x4041e1
push 0x41aed8
lea ecx, [ebp - 0x30]
call fcn.00403224
and dword [ebp - 4], 0
lea eax, [ebp - 0x30]
push eax
push dword [ebp - 0x38]
lea ecx, [ebp - 0x24]
call fcn.00404671
push 0x40d400
lea eax, [ebp - 0x24]
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret 8
Function at 0x404225
Capabilities:
Get file size

Disassembly:
mov eax, 0x4083c9
call fcn.00407ca0
sub esp, 0x28
mov dword [ebp - 0x34], ecx
mov eax, dword [ebp - 0x34]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x30], eax
push 0
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.DLL_GetFileSize]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
jne 0x404280
push 0x41aed8
lea ecx, [ebp - 0x2c]
call fcn.00403224
and dword [ebp - 4], 0
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0x34]
lea ecx, [ebp - 0x20]
call fcn.00404671
push 0x40d400
lea eax, [ebp - 0x20]
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret

Function at 0x40428f
Capabilities:
Check if file exists
Set file attributes

Disassembly:
mov eax, 0x4083dd
call fcn.00407ca0
sub esp, 0x20
mov ecx, dword [ebp + 8]
call fcn.004035c7
neg eax
sbb eax, eax
inc eax
movzx eax, al
test eax, eax
je 0x4042b2
jmp 0x40430c
push 0x80
mov ecx, dword [ebp + 8]
call fcn.004034b1
push eax
call dword [sym.imp.KERNEL32.DLL_SetFileAttributesW]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x40430c
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 2
je 0x40430c
push 0x41aed8
lea ecx, [ebp - 0x2c]
call fcn.00403224
and dword [ebp - 4], 0
lea eax, [ebp - 0x2c]
push eax
push dword [ebp + 8]
lea ecx, [ebp - 0x20]
call fcn.00404671
push 0x40d400
lea eax, [ebp - 0x20]
push eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret

Function at 0x40452f
Capabilities:
Delete file

Disassembly:
mov eax, 0x408483
call fcn.00407ca0
sub esp, 0x3c
mov ecx, dword [ebp + 8]
call fcn.004034b1
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileW]
test eax, eax
jne 0x4045ae
push 0x41aed8
lea ecx, [ebp - 0x28]
call fcn.00403224
and dword [ebp - 4], 0
push str.deleting
lea ecx, [ebp - 0x34]
call fcn.00403224
mov byte [ebp - 4], 1
lea eax, [ebp - 0x28]
push eax
push dword [ebp + 8]
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x40]
push eax
call fcn.0040366f
add esp, 0xc
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x44]
mov dword [ebp - 0x48], eax
mov byte [ebp - 4], 2
push dword [ebp - 0x48]
lea ecx, [ebp - 0x1c]
call fcn.00404671
push 0x40d400
lea eax, [ebp - 0x1c]
push eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret
Function at 0x4045ec
Capabilities:
Timestomp file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov dword [ebp - 0x20], ecx
cmp dword [ebp + 8], 0
je 0x404608
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.DLL_SystemTimeToFileTime]
cmp dword [ebp + 0x10], 0
je 0x40461b
lea eax, [ebp - 0x18]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.DLL_SystemTimeToFileTime]
cmp dword [ebp + 0xc], 0
je 0x40462e
lea eax, [ebp - 8]
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.DLL_SystemTimeToFileTime]
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0x10]
neg eax
sbb eax, eax
lea ecx, [ebp - 0x18]
and eax, ecx
push eax
mov eax, dword [ebp + 0xc]
neg eax
sbb eax, eax
lea ecx, [ebp - 8]
and eax, ecx
push eax
mov eax, dword [ebp + 8]
neg eax
sbb eax, eax
lea ecx, [ebp - 0x10]
and eax, ecx
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.DLL_SetFileTime]
neg eax
sbb eax, eax
neg eax
leave
ret 0xc
Function at 0x406b90
Capabilities:
Hash data with md5

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
and dword [eax + 4], 0
mov eax, dword [ebp + 8]
and dword [eax], 0
mov eax, dword [ebp + 8]
mov dword [eax + 8], 0x67452301
mov eax, dword [ebp + 8]
mov dword [eax + 0xc], 0xefcdab89
mov eax, dword [ebp + 8]
mov dword [eax + 0x10], 0x98badcfe
mov eax, dword [ebp + 8]
mov dword [eax + 0x14], 0x10325476
pop ebp
ret