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

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
test esi, esi
push edi
jne 0x4eb3f9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push esi
call fcn.004edd70
add esp, 4
test eax, eax
jne 0x4eb40e
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov eax, dword [esi]
xor edi, edi
cmp eax, 1
jne 0x4eb54e
mov edi, dword [esi + 4]
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push eax
push 0
push 0
push edi
mov dword [esp + 0x24], edi
call esi
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x4eb44c
push 2
push 0
push 0
push edi
call esi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push 0x1000
xor ebp, ebp
call fcn.00529d1a
add esp, 4
mov ebx, eax
lea eax, [esp + 0x20]
mov esi, ebx
push ebp
push eax
push 0x1000
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4eb52e
mov edx, dword [esp + 0x20]
xor ecx, ecx
test edx, edx
jbe 0x4eb494
mov al, byte [esi]
cmp al, 0xd
je 0x4eb4d6
cmp al, 0xa
je 0x4eb4d6
inc ecx
inc esi
cmp ecx, edx
jb 0x4eb484
add ebp, edx
cmp edx, 0x1000
jb 0x4eb4d8
push 0x1000
push ebx
call fcn.005299eb
mov ebx, eax
mov eax, dword [esp + 0x28]
add esp, 8
cmp eax, 0x1000
jne 0x4eb4d8
lea ecx, [esp + 0x20]
push 0
lea esi, [ebx + ebp]
push ecx
push 0x1000
push esi
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4eb52e
jmp 0x4eb47a
add ebp, ecx
lea edx, [ebp + 1]
push edx
call fcn.004e61b0
mov ecx, dword [esp + 0x14]
mov edi, eax
mov al, byte [esi]
add esp, 4
add ecx, ebp
cmp al, 0xd
je 0x4eb4f6
cmp al, 0xa
jne 0x4eb4ff
mov al, byte [esi + 1]
inc ecx
cmp al, 0xa
jne 0x4eb4ff
inc ecx
mov eax, dword [esp + 0x14]
push 0
push 0
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebp
push ebx
push edi
call fcn.00528d30
push ebx
mov byte [edi + ebp], 0
call fcn.00529902
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
push 2
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
call fcn.00529902
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x4eb5dc
mov esi, dword [esi + 4]
mov ecx, esi
mov edx, dword [esi]
call dword [edx + 0x14]
lea ecx, [esp + 0x10]
lea edx, [esp + 0x20]
push ecx
mov dword [esp + 0x18], eax
mov eax, dword [esi]
push edx
push 0xffffffffffffffff
push 0
mov ecx, esi
call dword [eax + 0x30]
mov ebp, dword [esp + 0x20]
xor ebx, ebx
test eax, eax
jbe 0x4eb597
mov cl, byte [ebp]
cmp cl, 0xd
je 0x4eb597
cmp cl, 0xa
je 0x4eb597
inc ebx
inc ebp
cmp ebx, eax
jb 0x4eb584
lea eax, [ebx + 1]
push eax
call fcn.004e61b0
mov ecx, dword [esp + 0x18]
mov edi, eax
mov al, byte [ebp]
add esp, 4
add ecx, ebx
cmp al, 0xd
je 0x4eb5b6
cmp al, 0xa
jne 0x4eb5bf
mov al, byte [ebp + 1]
inc ecx
cmp al, 0xa
jne 0x4eb5bf
inc ecx
mov edx, dword [esi]
push 0
push ecx
mov ecx, esi
call dword [edx + 0x18]
mov eax, dword [esp + 0x20]
push ebx
push eax
push edi
call fcn.00528d30
add esp, 0xc
mov byte [ebx + edi], 0
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x4eb660
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 4]
mov eax, dword [esp + 8]
cmp edx, 1
jle 0x4eb67e
push esi
lea ecx, [esp + 0x18]
dec edx
mov esi, dword [ecx]
add ecx, 0xc
xor eax, esi
dec edx
jne 0x4eb673
pop esi
ret
Function at 0x4ebe00
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
test esi, esi
push edi
jne 0x4ebe19
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push esi
call fcn.004edd70
add esp, 4
test eax, eax
jne 0x4ebe2e
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ebp, dword [esp + 0x2c]
test ebp, ebp
jg 0x4ebe40
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esi]
mov dword [esp + 0x20], 0
cmp eax, 1
jne 0x4ebf1e
mov edi, dword [esi + 4]
push eax
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x10], ebx
jne 0x4ebe77
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push 0
push edi
mov dword [esp + 0x28], 1
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
sub esi, ebp
sub esi, ebx
test esi, esi
jle 0x4ebf0b
push esi
call fcn.00536725
add esp, 4
mov ebx, eax
push 1
push 0
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
call ebp
lea eax, [esp + 0x14]
push 0
push eax
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4ebed2
push ebx
call fcn.0053674e
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ecx, dword [esp + 0x10]
push 0
push 0
push ecx
push edi
call ebp
lea edx, [esp + 0x14]
push 0
push edx
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4ebef6
mov dword [esp + 0x20], eax
push ebx
call fcn.0053674e
mov eax, dword [esp + 0x24]
add esp, 4
test eax, eax
je 0x4ebf93
push edi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x4ebf93
mov esi, dword [esi + 4]
mov ecx, esi
mov eax, dword [esi]
call dword [eax + 0x14]
mov ecx, esi
mov ebx, eax
call fcn.004edd60
mov edi, eax
mov dword [esp + 0x20], 1
sub edi, ebp
sub edi, ebx
test edi, edi
jle 0x4ebf8b
mov edx, dword [esi]
push 1
push ebp
mov ecx, esi
call dword [edx + 0x18]
push edi
call fcn.00536725
add esp, 4
mov ebp, eax
mov eax, dword [esi]
mov ecx, esi
push edi
push ebp
call dword [eax + 0x20]
mov edx, dword [esi]
push 0
push ebx
mov ecx, esi
call dword [edx + 0x18]
mov eax, dword [esi]
push edi
push ebp
mov ecx, esi
call dword [eax + 0x24]
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x14]
push ebp
mov ebx, eax
call fcn.0053674e
add esp, 4
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax + 0x1c]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x4ebff0
Capabilities:
Check if file exists
Get common file path

Disassembly:
mov eax, dword [esp + 0x10]
sub esp, 0x208
test eax, eax
push ebx
push esi
push edi
jne 0x4ec01b
lea eax, [esp + 0xc]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
jne 0x4ec043
mov byte [esp + 0xc], al
jmp 0x4ec043
mov edi, dword [esp + 0x21c]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xc]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0xc]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea eax, [esp + ecx + 0xc]
mov cl, byte [esp + ecx + 0xb]
cmp cl, 0x5c
je 0x4ec061
mov byte [eax], 0x5c
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
mov edi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
call edi
lea ecx, [esp + 0xc]
push eax
push ecx
lea edx, [esp + 0x118]
push str._s_x.tmp
push edx
call esi
add esp, 0x10
lea eax, [esp + 0x110]
push eax
call ebx
test eax, eax
jne 0x4ec073
lea edi, [esp + 0x110]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
push ecx
call fcn.004e61b0
mov edx, eax
lea edi, [esp + 0x114]
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebx
add esp, 0x208
ret

Function at 0x4f6664
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
push dword [ebp + 0x10]
call fcn.004f191d
mov dword [ebp - 4], eax
push 0x80000301
push 0
push 0xff
push 1
mov ebx, 0x184
call fcn.004fc440
add esp, 0x10
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
push eax
mov ebx, dword [ebp - 8]
test ebx, ebx
je 0x4f66bb
push ebx
call fcn.004fbb8a
add esp, 4
pop eax
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], esp
push 0
push dword [ebp - 4]
push dword [ebp - 8]
push 0
call dword [sym.imp.shell32.dll_SHGetSpecialFolderPathA_1]
nop
nop
nop
nop
cmp dword [ebp - 0xc], esp
je 0x4f66ee
push 6
call fcn.004fbb9c
add esp, 4
mov dword [ebp - 0xc], 0
push 0
push dword [ebp - 0xc]
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
call fcn.004f1e1b
mov ebx, dword [ebp - 8]
test ebx, ebx
je 0x4f6716
push ebx
call fcn.004fbb8a
add esp, 4
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4fc560
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 4]
mov eax, dword [esp + 8]
cmp edx, 1
jle 0x4fc57e
push esi
lea ecx, [esp + 0x18]
dec edx
mov esi, dword [ecx]
add ecx, 0xc
xor eax, esi
dec edx
jne 0x4fc573
pop esi
ret
Function at 0x4fcca0
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
test ebx, ebx
push edi
jne 0x4fccb3
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
push ebx
call fcn.004feda0
add esp, 4
test eax, eax
jne 0x4fccc5
pop edi
pop esi
pop ebp
pop ebx
ret
mov edi, dword [esp + 0x24]
test edi, edi
jg 0x4fccd4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
mov eax, dword [ebx]
xor esi, esi
cmp eax, 1
jne 0x4fcd2b
mov ebx, dword [ebx + 4]
push edi
call fcn.005124ec
add esp, 4
mov ebp, eax
lea eax, [esp + 0x18]
push esi
push eax
push edi
push ebp
push ebx
call dword [sym.imp.kernel32.dll_ReadFile_1]
test eax, eax
jne 0x4fcd0e
push ebp
call fcn.00512515
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov ecx, dword [esp + 0x18]
push ecx
push ebp
call fcn.004fe480
push ebp
mov esi, eax
call fcn.00512515
add esp, 0xc
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret
cmp eax, 2
jne 0x4fcd6d
mov ebx, dword [ebx + 4]
lea edx, [edi + 8]
push edx
call fcn.004fbdf0
mov esi, eax
add esp, 4
lea ecx, [esi + 8]
mov dword [esi], 1
mov dword [esi + 4], edi
mov eax, dword [ebx]
push edi
push ecx
mov ecx, ebx
call dword [eax + 0x20]
test eax, eax
jne 0x4fcd6a
push esi
call fcn.004fbe80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov dword [esi + 4], eax
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x4fd240
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
push esi
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x4fd253
xor eax, eax
pop esi
add esp, 8
ret
push esi
call fcn.004feda0
add esp, 4
test eax, eax
jne 0x4fd265
pop esi
add esp, 8
ret
mov eax, dword [esi]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push edi
mov dword [esp + 0x10], 0
jne 0x4fd2dc
mov eax, dword [esp + 0x1c]
mov edi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4fd30e
mov ebp, dword [sym.imp.kernel32.dll_WriteFile_1]
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 0x4fd2c8
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x4fd298
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret
pop edi
mov dword [esp + 0xc], 0
mov eax, dword [esp + 0xc]
pop ebp
pop ebx
pop esi
add esp, 8
ret
cmp eax, 2
jne 0x4fd30e
mov eax, dword [esp + 0x1c]
mov esi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4fd30e
lea edi, [esp + 0x2c]
lea ebx, [eax - 1]
mov eax, dword [edi]
mov edx, dword [esi]
mov ecx, dword [eax + 4]
add eax, 8
push ecx
push eax
mov ecx, esi
call dword [edx + 0x24]
add edi, 0xc
dec ebx
jne 0x4fd2f7
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret
Function at 0x4fd600
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x1c]
test esi, esi
push edi
jne 0x4fd619
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push esi
call fcn.004feda0
add esp, 4
test eax, eax
jne 0x4fd62e
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ebp, dword [esp + 0x2c]
test ebp, ebp
jg 0x4fd640
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esi]
mov dword [esp + 0x20], 0
cmp eax, 1
jne 0x4fd71e
mov edi, dword [esi + 4]
push eax
push 0
push 0
push edi
call dword [sym.imp.kernel32.dll_SetFilePointer_1]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x10], ebx
jne 0x4fd677
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push 0
push edi
mov dword [esp + 0x28], 1
call dword [sym.imp.kernel32.dll_GetFileSize_1]
mov esi, eax
sub esi, ebp
sub esi, ebx
test esi, esi
jle 0x4fd70b
push esi
call fcn.005124ec
add esp, 4
mov ebx, eax
push 1
push 0
push ebp
mov ebp, dword [sym.imp.kernel32.dll_SetFilePointer_1]
push edi
call ebp
lea eax, [esp + 0x14]
push 0
push eax
push esi
push ebx
push edi
call dword [sym.imp.kernel32.dll_ReadFile_1]
test eax, eax
jne 0x4fd6d2
push ebx
call fcn.00512515
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ecx, dword [esp + 0x10]
push 0
push 0
push ecx
push edi
call ebp
lea edx, [esp + 0x14]
push 0
push edx
push esi
push ebx
push edi
call dword [sym.imp.kernel32.dll_WriteFile_1]
test eax, eax
jne 0x4fd6f6
mov dword [esp + 0x20], eax
push ebx
call fcn.00512515
mov eax, dword [esp + 0x24]
add esp, 4
test eax, eax
je 0x4fd793
push edi
call dword [sym.imp.kernel32.dll_SetEndOfFile_1]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x4fd793
mov esi, dword [esi + 4]
mov ecx, esi
mov eax, dword [esi]
call dword [eax + 0x14]
mov ecx, esi
mov ebx, eax
call fcn.004fee40
mov edi, eax
mov dword [esp + 0x20], 1
sub edi, ebp
sub edi, ebx
test edi, edi
jle 0x4fd78b
mov edx, dword [esi]
push 1
push ebp
mov ecx, esi
call dword [edx + 0x18]
push edi
call fcn.005124ec
add esp, 4
mov ebp, eax
mov eax, dword [esi]
mov ecx, esi
push edi
push ebp
call dword [eax + 0x20]
mov edx, dword [esi]
push 0
push ebx
mov ecx, esi
call dword [edx + 0x18]
mov eax, dword [esi]
push edi
push ebp
mov ecx, esi
call dword [eax + 0x24]
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x14]
push ebp
mov ebx, eax
call fcn.00512515
add esp, 4
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax + 0x1c]
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret

Function at 0x4fd7a0
Capabilities:
Get file size

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x4fd7ae
or eax, 0xffffffff
pop esi
ret
push esi
call fcn.004feda0
add esp, 4
test eax, eax
jne 0x4fd7c0
or eax, 0xffffffff
pop esi
ret
mov ecx, dword [esi]
or eax, 0xffffffff
cmp ecx, 1
jne 0x4fd7db
mov esi, dword [esi + 4]
lea eax, [esp + 0xc]
push eax
push esi
call dword [sym.imp.kernel32.dll_GetFileSize_1]
pop esi
ret
cmp ecx, 2
jne 0x4fd7e8
mov ecx, dword [esi + 4]
call fcn.004fee40
pop esi
ret
Function at 0x4fdb30
Capabilities:
Enumerate files on windows

Disassembly:
sub esp, 0x144
push ebx
mov ebx, dword [esp + 0x14c]
push ebp
mov ebp, dword [esp + 0x15c]
push esi
push edi
mov esi, dword [ebp]
mov dword [esp + 0x10], 0
test ebx, ebx
je 0x4fdbbb
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x4fdbbb
test esi, esi
je 0x4fdb75
cmp esi, 0xffffffff
je 0x4fdb75
push esi
call dword [sym.imp.kernel32.dll_FindClose_1]
lea eax, [esp + 0x14]
push eax
push ebx
call dword [sym.imp.kernel32.dll_FindFirstFileA_1]
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp], esi
je 0x4fdc01
mov eax, dword [esp + 0x160]
test eax, eax
je 0x4fdba4
mov ecx, dword [esp + 0x14]
and ecx, 0x10
cmp cl, 0x10
je 0x4fdbbb
jmp 0x4fdbb3
mov edx, dword [esp + 0x15c]
mov eax, dword [esp + 0x14]
test edx, eax
je 0x4fdbbb
mov dword [esp + 0x10], 1
test esi, esi
je 0x4fdc01
cmp esi, 0xffffffff
je 0x4fdc01
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x4fdc38
mov eax, dword [esp + 0x160]
mov edi, dword [sym.imp.kernel32.dll_FindNextFileA_1]
test eax, eax
lea eax, [esp + 0x14]
push eax
push esi
je 0x4fdc0e
call edi
test eax, eax
je 0x4fdc01
mov ecx, dword [esp + 0x14]
and ecx, 0x10
cmp cl, 0x10
jne 0x4fdc38
lea edx, [esp + 0x14]
push edx
push esi
call edi
test eax, eax
jne 0x4fdbe9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x144
ret
call edi
test eax, eax
je 0x4fdc01
mov ebx, dword [esp + 0x15c]
test dword [esp + 0x14], ebx
jne 0x4fdc38
lea ecx, [esp + 0x14]
push ecx
push esi
call edi
test eax, eax
jne 0x4fdc1b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret
lea edi, [esp + 0x40]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
push ecx
call fcn.004fbdf0
mov edx, eax
lea edi, [esp + 0x44]
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret

Function at 0x4fdca0
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_1]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x4fdd32
mov eax, dword [esp + 0x10]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push esi
mov dword [esp + 0x10], ebx
jle 0x4fdd24
mov ebp, dword [sym.imp.kernel32.dll_WriteFile_1]
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 0x4fdd1c
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x4fdce5
push edi
call dword [sym.imp.kernel32.dll_CloseHandle_1]
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_1]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret
Function at 0x4fdd40
Capabilities:
Create directory

Disassembly:
sub esp, 0xc
mov ecx, dword [esp + 0x14]
xor eax, eax
mov dword [esp + 4], eax
mov dword [esp + 8], eax
lea eax, [esp]
mov dword [esp], 0xc
push eax
push ecx
call dword [sym.imp.kernel32.dll_CreateDirectoryA_1]
add esp, 0xc
ret

Function at 0x502190
Capabilities:
Encrypt data using des

Disassembly:
sub esp, 0xf4
xor ecx, ecx
push ebx
push ebp
push esi
mov esi, dword [esp + 0x104]
push edi
xor eax, eax
mov al, byte [ecx + 0x574b76]
mov edx, eax
and eax, 7
sar edx, 3
mov bl, byte [eax*2 + 0x574b06]
mov dl, byte [edx + esi]
test bl, dl
setne al
mov byte [esp + ecx + 0x4c], al
inc ecx
cmp ecx, 0x38
jl 0x5021a3
mov eax, 0x1e
xor edx, edx
mov dword [esp + 0x10], eax
cmp dword [esp + 0x10c], 1
je 0x5021e4
lea eax, [edx + edx]
lea edi, [esp + eax*4 + 0x88]
lea ebp, [esp + eax*4 + 0x84]
xor eax, eax
xor ecx, ecx
mov cl, byte [edx + 0x574bae]
mov dword [edi], 0
mov dword [ebp], 0
mov esi, ecx
cmp ecx, 0x1c
jge 0x502216
mov bl, byte [esp + ecx + 0x4c]
jmp 0x50221a
mov bl, byte [esp + ecx + 0x30]
mov byte [esp + eax + 0x14], bl
inc eax
inc ecx
cmp eax, 0x1c
jl 0x50220b
mov eax, 0x1c
lea ecx, [esi + 0x1c]
cmp ecx, 0x38
jge 0x502238
mov bl, byte [esp + ecx + 0x4c]
jmp 0x50223c
mov bl, byte [esp + ecx + 0x30]
mov byte [esp + eax + 0x14], bl
inc eax
inc ecx
cmp eax, 0x38
jl 0x50222d
xor ecx, ecx
mov eax, 0x574b16
xor ebx, ebx
mov bl, byte [ecx + 0x574bbe]
cmp byte [esp + ebx + 0x14], 0
je 0x502267
mov esi, dword [eax]
mov ebx, dword [ebp]
or ebx, esi
mov dword [ebp], ebx
xor ebx, ebx
mov bl, byte [ecx + 0x574bd6]
cmp byte [esp + ebx + 0x14], 0
je 0x50227e
mov esi, dword [eax]
mov ebx, dword [edi]
or ebx, esi
mov dword [edi], ebx
add eax, 4
inc ecx
cmp eax, 0x574b76
jl 0x50224e
mov eax, dword [esp + 0x10]
inc edx
sub eax, 2
cmp eax, 0xfffffffe
mov dword [esp + 0x10], eax
jg 0x5021d7
lea edx, [esp + 0x84]
push edx
call fcn.005022c0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xf4
ret
Function at 0x5182f0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov al, cl
ret
Function at 0x51a420
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 8]
test ecx, ecx
jne 0x51a42b
xor eax, eax
ret
mov eax, dword [esp + 4]
push ebx
push esi
mov esi, dword [esp + 0x14]
cmp esi, 8
not eax
jb 0x51a52e
push edi
mov edi, esi
shr edi, 3
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
mov ebx, eax
shr ebx, 8
mov eax, dword [edx*4 + 0x545e9c]
sub esi, 8
xor eax, ebx
inc ecx
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x545e9c]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x545e9c]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x545e9c]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x545e9c]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x545e9c]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x545e9c]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x545e9c]
xor eax, edx
inc ecx
dec edi
jne 0x51a446
pop edi
test esi, esi
je 0x51a550
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x545e9c]
xor eax, edx
inc ecx
dec esi
jne 0x51a532
pop esi
pop ebx
not eax
ret

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

Disassembly:
mov ecx, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
mov edx, dword [ecx]
and esi, 0xff
mov eax, edx
and eax, 0xff
xor eax, esi
shr edx, 8
mov eax, dword [eax*4 + 0x545e9c]
xor eax, edx
mov edx, dword [ecx + 4]
mov dword [ecx], eax
and eax, 0xff
add eax, edx
mov edx, dword [ecx + 8]
imul eax, eax, 0x8088405
inc eax
mov esi, edx
mov dword [ecx + 4], eax
and esi, 0xff
shr eax, 0x18
xor eax, esi
pop esi
shr edx, 8
mov eax, dword [eax*4 + 0x545e9c]
xor eax, edx
mov dword [ecx + 8], eax
ret
Function at 0x51ae30
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0x14]
push ebp
mov ebp, dword [esp + 0x10]
mov cl, byte [ebx]
mov eax, ebp
imul eax, dword [esp + 0x14]
test cl, cl
je 0x51ae71
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0xc]
push 0
push ecx
push eax
mov eax, dword [ebx + 4]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x51ae66
mov byte [ebx + 8], 1
mov eax, dword [esp + 0xc]
xor edx, edx
div ebp
pop ebp
pop ebx
ret
mov edx, dword [ebx + 0x1c]
mov ecx, dword [ebx + 0x18]
push esi
push edi
lea esi, [edx + eax]
cmp esi, ecx
jbe 0x51ae84
sub ecx, edx
mov eax, ecx
mov esi, dword [ebx + 0x14]
mov edi, dword [esp + 0x14]
mov ecx, eax
add esi, edx
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
xor edx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebx + 0x1c]
pop edi
add ecx, eax
pop esi
div ebp
mov dword [ebx + 0x1c], ecx
pop ebp
pop ebx
ret