joyce8/EMBER2024-capa huggingface dataset:
Function at 0x42de56
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb4
call fcn.0040546f
mov dword [ebp - 0x90], eax
cmp dword [ebp - 0x90], 0
je 0x42e08b
mov eax, dword [ebp - 0x90]
mov ecx, dword [eax + 0x14]
mov dword [ebp - 0x8c], ecx
mov edx, dword [ebp - 0x8c]
push edx
push str.CITY_02dMAJOR
lea eax, [ebp - 0xb0]
push eax
call fcn.0046d530
add esp, 0xc
lea ecx, [ebp - 0x84]
push ecx
push 0
lea edx, [ebp - 0xb0]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00455133
add esp, 0x10
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0xffffffff
je 0x42df59
lea ecx, [ebp - 0x84]
push ecx
call fcn.00406a0b
add esp, 4
mov dword [ebp - 0x88], eax
cmp dword [ebp - 0x88], 0
je 0x42def9
mov edx, dword [ebp - 0x90]
mov eax, dword [ebp - 0x88]
mov dword [edx + 0x14], eax
jmp 0x42df57
mov ecx, dword [ebp - 0x90]
cmp dword [ecx + 0x24], 0
jne 0x42df1d
cmp dword [ebp - 0x88], 0
je 0x42df4a
mov edx, dword [ebp - 0x88]
cmp dword [edx + 0x91], 1
je 0x42df4a
mov eax, dword [ebp - 0x90]
add eax, 4
push eax
lea ecx, [ebp - 0x84]
push ecx
push 0x48a6f8
call fcn.00450460
add esp, 0xc
mov edx, dword [ebp - 0x90]
mov dword [edx + 0x14], 0
jmp 0x42df57
mov eax, dword [ebp - 0x90]
mov dword [eax + 0x14], 0
jmp 0x42df83
mov ecx, dword [ebp - 0x90]
cmp dword [ecx + 0x24], 0
je 0x42df83
mov edx, dword [ebp - 0x90]
add edx, 4
push edx
lea eax, [ebp - 0x84]
push eax
push 0x48a714
call fcn.00450460
add esp, 0xc
mov ecx, dword [ebp - 0x8c]
push ecx
push str.CITY_02dWISE
lea edx, [ebp - 0xb0]
push edx
call fcn.0046d530
add esp, 0xc
lea eax, [ebp - 0x84]
push eax
push 0
lea ecx, [ebp - 0xb0]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00455133
add esp, 0x10
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0xffffffff
je 0x42e056
lea eax, [ebp - 0x84]
push eax
call fcn.00406a0b
add esp, 4
mov dword [ebp - 0xb4], eax
cmp dword [ebp - 0xb4], 0
je 0x42dff6
mov ecx, dword [ebp - 0x90]
mov edx, dword [ebp - 0xb4]
mov dword [ecx + 0x18], edx
jmp 0x42e054
mov eax, dword [ebp - 0x90]
cmp dword [eax + 0x24], 0
jne 0x42e01a
cmp dword [ebp - 0xb4], 0
je 0x42e047
mov ecx, dword [ebp - 0xb4]
cmp dword [ecx + 0x91], 1
je 0x42e047
mov edx, dword [ebp - 0x90]
add edx, 4
push edx
lea eax, [ebp - 0x84]
push eax
push 0x48a73c
call fcn.00450460
add esp, 0xc
mov ecx, dword [ebp - 0x90]
mov dword [ecx + 0x18], 0
jmp 0x42e054
mov edx, dword [ebp - 0x90]
mov dword [edx + 0x18], 0
jmp 0x42e074
mov eax, dword [ebp - 0x90]
add eax, 4
push eax
lea ecx, [ebp - 0x84]
push ecx
push 0x48a758
call fcn.00450460
add esp, 0xc
mov edx, dword [ebp - 0x90]
mov eax, dword [edx + 0xa6]
mov dword [ebp - 0x90], eax
jmp 0x42de6a
mov esp, ebp
pop ebp
ret
Function at 0x450460
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x29c
lea eax, [ebp + 0xc]
mov dword [ebp - 0x1fc], eax
mov ecx, dword [ebp - 0x1fc]
push ecx
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x1f8]
push eax
call fcn.0046de00
add esp, 0xc
mov dword [ebp - 0x1fc], 0
lea ecx, [ebp - 0x1f8]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov dword [ebp - 0x29c], 0x94
lea edx, [ebp - 0x29c]
push edx
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x28c], 1
je 0x4504c8
jmp 0x450607
push str.DBWIN_BUFFER_READY
push 0
push 2
call dword [sym.imp.KERNEL32.dll_OpenEventA]
mov dword [ebp - 0x204], eax
cmp dword [ebp - 0x204], 0
jne 0x4504eb
jmp 0x450607
push str.DBWIN_DATA_READY
push 0
push 2
call dword [sym.imp.KERNEL32.dll_OpenEventA]
mov dword [ebp - 0x208], eax
cmp dword [ebp - 0x208], 0
jne 0x45051b
mov eax, dword [ebp - 0x204]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x450607
push str.DBWIN_BUFFER
push 0x1000
push 0
push 4
push 0
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x45055b
mov ecx, dword [ebp - 0x204]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x208]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x450607
push 0x200
push 0
push 0
push 2
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x200], eax
cmp dword [ebp - 0x200], 0
jne 0x45059b
mov ecx, dword [ebp - 0x204]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x208]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x450607
push 0xffffffffffffffff
mov eax, dword [ebp - 0x204]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
call sub.KERNEL32.dll_GetCurrentProcessId
mov ecx, dword [ebp - 0x200]
mov dword [ecx], eax
lea edx, [ebp - 0x1f8]
push edx
push 0x4903cc
mov eax, dword [ebp - 0x200]
add eax, 4
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
mov ecx, dword [ebp - 0x208]
push ecx
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x208]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x204]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esp, ebp
pop ebp
ret

Function at 0x450b62
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 4]
mov dword [ebp - 4], ecx
push str._nGroup
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [ebp - 4], 0
je 0x450b9c
mov edx, dword [ebp - 4]
push edx
push str.___08X
call fcn.00450460
add esp, 8
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 4]
mov dword [ebp - 4], ecx
jmp 0x450b7a
mov esp, ebp
pop ebp
ret
Function at 0x4539fe
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [0x490414]
mov dword [ebp - 0x10], eax
xor ecx, ecx
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp + 8]
mov dword [ebp - 4], edx
jmp 0x453a22
mov eax, dword [ebp - 4]
add eax, 1
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0x1a
jge 0x453a50
mov ecx, dword [ebp - 4]
add ecx, 0x41
mov byte [ebp - 0x10], cl
lea edx, [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 5
jne 0x453a4e
mov eax, dword [ebp - 4]
mov dword [0x490410], eax
jmp 0x453a50
jmp 0x453a19
mov eax, dword [0x490410]
mov esp, ebp
pop ebp
ret

Function at 0x453a59
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [0x490418]
mov dword [ebp - 0x10], eax
xor ecx, ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 4], 0
jmp 0x453a7e
mov edx, dword [ebp - 4]
add edx, 1
mov dword [ebp - 4], edx
cmp dword [ebp - 4], 0x1a
jge 0x453aad
mov eax, dword [ebp - 4]
add eax, 0x41
mov byte [ebp - 0x10], al
lea ecx, [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 5
jne 0x453aab
mov edx, dword [ebp - 4]
mov dword [0x490410], edx
jmp 0x453aad
jmp 0x453a75
mov esp, ebp
pop ebp
ret
Function at 0x457861
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
enter 0x10, 0
push eax
push ebx
push ecx
push edx
push esi
push edi
mov eax, 0xff
imul eax, dword [ebp + 8]
xor edx, edx
idiv dword [ebp + 0xc]
mov dword [ebp - 4], eax
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
mov esi, dword [ebp + 0x10]
mov ebx, 0xff
mov edi, 0xff
mov eax, edi
shr eax, 3
and eax, 0x1c
imul eax, dword [ebp - 8]
xor edx, edx
idiv ebx
and eax, 0xff
shr eax, 2
shl eax, 5
mov dword [ebp - 0x10], eax
mov eax, edi
shl eax, 3
and eax, 0xf8
imul eax, dword [ebp - 0xc]
xor edx, edx
idiv ebx
and eax, 0xff
shr eax, 3
or eax, dword [ebp - 0x10]
mov word [esi + edi*2], ax
mov eax, edi
shl eax, 5
and eax, 0xe0
imul eax, dword [ebp - 8]
xor edx, edx
idiv ebx
and eax, 0xff
shr eax, 2
shl eax, 5
mov dword [ebp - 0x10], eax
mov eax, edi
and eax, 0xf8
imul eax, dword [ebp - 4]
xor edx, edx
idiv ebx
and eax, 0xff
shr eax, 3
shl eax, 0xb
or eax, dword [ebp - 0x10]
mov word [esi + edi*2 + 0x200], ax
dec edi
jns 0x45788f
pop edi
pop esi
pop edx
pop ecx
pop ebx
pop eax
leave
ret

Function at 0x46d890
Capabilities:
Terminate process

Disassembly:
mov eax, dword [0x4a5b6c]
push ebx
push ebp
mov ebp, dword [esp + 0xc]
cmp eax, 1
push esi
jne 0x46d8af
push ebp
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov eax, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
test eax, eax
mov dword [0x4a5b68], 1
mov byte [0x4a5b64], bl
jne 0x46d909
mov ecx, dword [0x4d184c]
test ecx, ecx
je 0x46d8f7
mov esi, dword [0x4d1848]
sub esi, 4
cmp esi, ecx
jb 0x46d8f7
mov eax, dword [esi]
test eax, eax
je 0x46d8f0
call eax
mov ecx, dword [0x4d184c]
sub esi, 4
cmp esi, ecx
jae 0x46d8e2
push 0x47f064
push 0x47f05c
call fcn.0046d940
add esp, 8
push 0x47f070
push 0x47f068
call fcn.0046d940
add esp, 8
test ebx, ebx
jne 0x46d930
push ebp
mov dword [0x4a5b6c], 1
call dword [sym.imp.KERNEL32.dll_ExitProcess]
pop esi
pop ebp
pop ebx
ret
Function at 0x46e7d0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x47d650
push 0x472b88
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffa8
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
xor edx, edx
mov dl, ah
mov dword [0x4a5b3c], edx
mov ecx, eax
and ecx, 0xff
mov dword [0x4a5b38], ecx
shl ecx, 8
add ecx, edx
mov dword [0x4a5b34], ecx
shr eax, 0x10
mov dword [0x4a5b30], eax
call fcn.00472b40
test eax, eax
jne 0x46e83a
push 0x1c
call fcn.0046e9a0
add esp, 4
mov dword [ebp - 4], 0
call fcn.00472940
call fcn.00472930
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x4d1844], eax
call fcn.00472310
mov dword [0x4a5b70], eax
test eax, eax
je 0x46e86d
mov eax, dword [0x4d1844]
test eax, eax
jne 0x46e877
push 0xffffffffffffffff
call fcn.0046d850
add esp, 4
call fcn.00472060
call fcn.00471f70
call fcn.0046d820
mov esi, dword [0x4d1844]
mov dword [ebp - 0x64], esi
cmp byte [esi], 0x22
jne 0x46e956
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
cmp al, 0x22
je 0x46e8be
test al, al
je 0x46e8be
and eax, 0xff
push eax
call fcn.00471f10
add esp, 4
test eax, eax
je 0x46e898
inc esi
mov dword [ebp - 0x64], esi
jmp 0x46e898
cmp byte [esi], 0x22
jne 0x46e8c7
inc esi
mov dword [ebp - 0x64], esi
mov al, byte [esi]
test al, al
je 0x46e8d7
cmp al, 0x20
ja 0x46e8d7
inc esi
mov dword [ebp - 0x64], esi
jmp 0x46e8c7
mov dword [ebp - 0x30], 0
lea eax, [ebp - 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x30], 1
je 0x46e8f8
mov eax, dword [ebp - 0x2c]
and eax, 0xffff
jmp 0x46e8fd
mov eax, 0xa
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
mov dword [ebp - 0x60], eax
push eax
call fcn.0046d850
jmp 0x46e93b
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0x20
jbe 0x46e8c7
inc esi
mov dword [ebp - 0x64], esi
jmp 0x46e956

Function at 0x46e9a0
Capabilities:
Terminate process

Disassembly:
cmp dword [0x4a5b78], 1
jne 0x46e9ae
call fcn.00472c60
mov eax, dword [esp + 4]
push eax
call fcn.00472ca0
add esp, 4
push 0xff
call dword [sym.imp.KERNEL32.dll_ExitProcess]
Function at 0x472310
Capabilities:
Query environment variable

Disassembly:
mov eax, dword [0x4a5ce8]
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
push esi
xor esi, esi
xor ebx, ebx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
test eax, eax
jne 0x472352
call edi
mov esi, eax
test esi, esi
je 0x47233c
mov eax, 1
jmp 0x47234d
call ebp
mov ebx, eax
test ebx, ebx
je 0x47245f
mov eax, 2
mov dword [0x4a5ce8], eax
cmp eax, 1
jne 0x4723f2
test esi, esi
jne 0x47236b
call edi
mov esi, eax
test esi, esi
je 0x47245f
cmp word [esi], 0
mov eax, esi
je 0x472385
add eax, 2
cmp word [eax], 0
jne 0x472373
add eax, 2
cmp word [eax], 0
jne 0x472373
sub eax, esi
push 0
sar eax, 1
inc eax
push 0
mov ebp, eax
push 0
push 0
push ebp
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov edi, eax
test edi, edi
je 0x4723e4
push edi
call fcn.0046e9d0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x4723e4
push 0
push 0
push edi
push ebx
push ebp
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x4723d6
push ebx
call fcn.0046ea80
add esp, 4
xor ebx, ebx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop esi
pop ebp
pop ebx
ret
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
cmp eax, 2
jne 0x47245f
test ebx, ebx
jne 0x472403
call ebp
mov ebx, eax
test ebx, ebx
je 0x47245f
mov cl, byte [ebx]
mov eax, ebx
test cl, cl
je 0x47241b
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x47240b
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x47240b
sub eax, ebx
inc eax
mov esi, eax
push esi
call fcn.0046e9d0
mov ebp, eax
add esp, 4
test ebp, ebp
jne 0x47243d
push ebx
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov ecx, esi
mov esi, ebx
mov eax, ecx
mov edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
mov eax, ebp
pop edi
pop esi
pop ebp
pop ebx
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
Function at 0x472ca0
Capabilities:
Write file on windows

Disassembly:
mov ecx, dword [esp + 4]
sub esp, 0x1a8
mov eax, 0x4a12f0
push ebx
push ebp
push esi
push edi
xor ebp, ebp
cmp ecx, dword [eax]
je 0x472cc4
add eax, 8
inc ebp
cmp eax, 0x4a1380
jb 0x472cb5
cmp ecx, dword [ebp*8 + 0x4a12f0]
jne 0x472e6b
mov eax, dword [0x4a5b78]
cmp eax, 1
je 0x472e2d
test eax, eax
jne 0x472cf0
cmp dword [0x4a0e98], 1
je 0x472e2d
cmp ecx, 0xfc
je 0x472e6b
lea eax, [esp + 0xb4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x472d2b
mov ecx, 5
mov esi, str._program_name_unknown_
lea edi, [esp + 0xb4]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
lea edi, [esp + 0xb4]
or ecx, 0xffffffff
xor eax, eax
lea ebx, [esp + 0xb4]
repne scasb al, byte es:[edi]
not ecx
cmp ecx, 0x3c
jbe 0x472d74
lea edi, [esp + 0xb4]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 3
mov ebx, ecx
lea ecx, [esp + 0xb8]
sub ecx, 0x3b
push 0x47dafc
add ebx, ecx
push ebx
call fcn.004755c0
add esp, 0xc
mov ecx, 6
mov esi, str.Runtime_Error__n_nProgram:
lea edi, [esp + 0x14]
xor eax, eax
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
or ecx, 0xffffffff
mov edi, ebx
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x14]
mov ebx, ecx
mov esi, edi
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x14]
and ecx, 3
push 0x12010
rep movsb byte es:[edi], byte [esi]
mov edi, 0x47dadc
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push str.Microsoft_Visual_C_Runtime_Library
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x1c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebp*8 + 0x4a12f4]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x1c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call fcn.004756e0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1a8
ret
mov eax, dword [0x4d1740]
test eax, eax
je 0x472e3e
mov esi, dword [eax + 0x10]
cmp esi, 0xffffffff
jne 0x472e48
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, eax
mov edx, dword [ebp*8 + 0x4a12f4]
lea ecx, [esp + 0x10]
push 0
push ecx
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1a8
ret
Function at 0x474740
Capabilities:
Write file on windows

Disassembly:
mov eax, dword [esp + 4]
mov ecx, dword [0x4d1840]
sub esp, 0x41c
cmp eax, ecx
push ebx
push ebp
push esi
push edi
jae 0x4748ed
mov ecx, eax
mov esi, eax
sar ecx, 5
and esi, 0x1f
mov edx, dword [ecx*4 + 0x4d1740]
lea edi, [ecx*4 + 0x4d1740]
shl esi, 3
mov dword [esp + 0x24], edi
mov dword [esp + 0x14], esi
mov cl, byte [esi + edx + 4]
test cl, 1
je 0x4748ed
mov ebx, dword [esp + 0x438]
xor ebp, ebp
cmp ebx, ebp
mov dword [esp + 0x10], ebp
mov dword [esp + 0x20], ebp
jne 0x4747ae
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret
test cl, 0x20
je 0x4747bf
push 2
push ebp
push eax
call fcn.00474680
add esp, 0xc
mov eax, dword [edi]
add eax, esi
test byte [eax + 4], 0x80
je 0x47491e
mov ebp, dword [esp + 0x434]
mov dword [esp + 0x18], 0
test ebx, ebx
mov edi, ebp
jbe 0x474869
lea eax, [esp + 0x28]
mov ecx, edi
sub ecx, ebp
cmp ecx, ebx
jae 0x47481a
mov cl, byte [edi]
inc edi
cmp cl, 0xa
jne 0x474807
mov esi, dword [esp + 0x20]
mov byte [eax], 0xd
inc esi
inc eax
mov dword [esp + 0x20], esi
mov byte [eax], cl
inc eax
mov edx, eax
lea ecx, [esp + 0x28]
sub edx, ecx
cmp edx, 0x400
jl 0x4747ea
mov esi, eax
lea edx, [esp + 0x28]
lea eax, [esp + 0x1c]
sub esi, edx
mov edx, dword [esp + 0x24]
push 0
push eax
lea ecx, [esp + 0x30]
mov eax, dword [edx]
push esi
push ecx
mov ecx, dword [esp + 0x24]
mov edx, dword [ecx + eax]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x47490f
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x10]
add edx, eax
cmp eax, esi
mov dword [esp + 0x10], edx
jl 0x474865
mov eax, edi
sub eax, ebp
cmp eax, ebx
jb 0x4747e6
mov esi, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x4748de
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4748b2
cmp eax, 5
jne 0x47489b
mov dword [0x4a5b28], eax
mov dword [0x4a5b24], 9
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret
push eax
call fcn.00476cf0
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret
mov ecx, dword [esp + 0x24]
mov edx, dword [ecx]
test byte [esi + edx + 4], 0x40
je 0x4748d2
cmp byte [ebp], 0x1a
jne 0x4748d2
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret
mov dword [0x4a5b24], 0x1c
jmp 0x4748f7
sub eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret
mov dword [0x4a5b24], 9
pop edi
pop esi
pop ebp
mov dword [0x4a5b28], 0
or eax, 0xffffffff
pop ebx
add esp, 0x41c
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x18], eax
jmp 0x474865
mov edx, dword [eax]
lea ecx, [esp + 0x1c]
push ebp
mov ebp, dword [esp + 0x438]
push ecx
push ebx
push ebp
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x47494f
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x18], 0
mov dword [esp + 0x10], eax
jmp 0x474869
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x18], eax
jmp 0x474869
Function at 0x47c2f0
Capabilities:
Set environment variable

Disassembly:
push ecx
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x18]
test edi, edi
je 0x47c4ae
push 0x3d
push edi
call fcn.0047c5f0
mov esi, eax
add esp, 8
test esi, esi
je 0x47c4ae
cmp edi, esi
je 0x47c4ae
mov dl, byte [esi + 1]
mov ecx, dword [0x4a5b50]
xor eax, eax
test dl, dl
sete al
mov ebp, eax
mov eax, dword [0x4a5b4c]
cmp eax, ecx
jne 0x47c347
push eax
call fcn.0047c580
add esp, 4
mov dword [0x4a5b4c], eax
test eax, eax
jne 0x47c3c2
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x47c36e
mov eax, dword [0x4a5b54]
test eax, eax
je 0x47c36e
call fcn.0047bfa0
test eax, eax
je 0x47c3bd
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
test ebp, ebp
je 0x47c37a
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
push 4
call fcn.0046e9d0
add esp, 4
mov dword [0x4a5b4c], eax
test eax, eax
je 0x47c4ae
mov dword [eax], 0
mov eax, dword [0x4a5b54]
test eax, eax
jne 0x47c3bd
push 4
call fcn.0046e9d0
add esp, 4
mov dword [0x4a5b54], eax
test eax, eax
je 0x47c4ae
mov dword [eax], 0
mov eax, dword [0x4a5b4c]
mov ebx, eax
mov eax, esi
sub eax, edi
push eax
push edi
mov dword [esp + 0x18], eax
call fcn.0047c500
mov esi, eax
add esp, 8
test esi, esi
jl 0x47c4bf
cmp dword [ebx], 0
je 0x47c4bf
test ebp, ebp
je 0x47c4b7
mov ecx, dword [ebx + esi*4]
lea edi, [ebx + esi*4]
push ecx
call fcn.0046ea80
mov eax, dword [edi]
add esp, 4
test eax, eax
je 0x47c419
mov eax, edi
mov edx, dword [eax + 4]
add eax, 4
mov dword [edi], edx
inc esi
mov ecx, dword [eax]
mov edi, eax
test ecx, ecx
jne 0x47c408
lea eax, [esi*4]
push eax
push ebx
call fcn.0046ead0
add esp, 8
test eax, eax
je 0x47c433
mov dword [0x4a5b4c], eax
mov edi, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x47c4a6
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
inc ecx
push ecx
call fcn.0046e9d0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x47c4a6
mov edi, dword [esp + 0x18]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, dword [esp + 0x10]
mov edx, ecx
mov esi, edi
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
neg ebp
rep movsb byte es:[edi], byte [esi]
sbb ebp, ebp
mov byte [ebx + eax], 0
lea eax, [ebx + eax + 1]
not ebp
and ebp, eax
push ebp
push ebx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
push ebx
call fcn.0046ea80
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
pop ecx
ret
mov dword [ebx + esi*4], edi
jmp 0x47c437
test ebp, ebp
jne 0x47c4a6
test esi, esi
jge 0x47c4c9
neg esi
lea ecx, [esi*4 + 8]
push ecx
push ebx
call fcn.0046ead0
add esp, 8
test eax, eax
je 0x47c4ae
mov dword [eax + esi*4], edi
mov dword [eax + esi*4 + 4], 0
mov dword [0x4a5b4c], eax
jmp 0x47c437