joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10309eb0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
call sym.tk85.dll_Tk_GetHINSTANCE
mov dword [ebp - 0x10], eax
push 0x14
push 0x103508fc
mov eax, dword [0x103513c8]
mov ecx, dword [eax + 0x4cc]
call ecx
add esp, 8
mov dword [ebp - 0x18], eax
push 2
push str.buttons
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jne 0x10309f06
push str.FindResource___failed_for_buttons_bitmap_resource__resources_in_tk_base.rc_must_be_linked_into_Tk_dll_or_static_executable
mov eax, dword [0x103513c8]
mov ecx, dword [eax + 0x10]
call ecx
add esp, 4
jmp 0x10309f26
mov edx, dword [ebp - 8]
push edx
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edx, dword [ebp - 0x18]
mov dword [edx], eax
mov eax, dword [ebp - 0x18]
cmp dword [eax], 0
je 0x1030a01e
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
and eax, 0x80000003
jns 0x10309f46
dec eax
or eax, 0xfffffffc
inc eax
test eax, eax
jne 0x1030a01e
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx]
mov eax, dword [edx + 8]
and eax, 0x80000001
jns 0x10309f62
dec eax
or eax, 0xfffffffe
inc eax
test eax, eax
jne 0x1030a01e
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx]
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
movzx ecx, word [ecx + 0xe]
mov eax, 1
shl eax, cl
mov ecx, dword [edx]
lea edx, [ecx + eax*4]
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
add edx, dword [ecx + 0x14]
mov dword [ebp - 0xc], edx
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [0x103513c8]
mov ecx, dword [eax + 0x14]
call ecx
add esp, 4
mov dword [ebp - 0x14], eax
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
push ecx
mov edx, dword [ebp - 0x14]
push edx
call sub.MSVCR90.dll_memcpy
add esp, 0xc
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x14]
mov dword [eax], ecx
mov edx, dword [ebp - 0x18]
mov eax, dword [edx]
mov eax, dword [eax + 4]
cdq
and edx, 3
add eax, edx
sar eax, 2
mov ecx, dword [ebp - 0x18]
mov dword [ecx + 0x10], eax
mov edx, dword [ebp - 0x18]
mov eax, dword [edx]
mov eax, dword [eax + 8]
cdq
sub eax, edx
sar eax, 1
mov ecx, dword [ebp - 0x18]
mov dword [ecx + 0xc], eax
mov edx, dword [ebp - 0x18]
mov eax, dword [edx]
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx]
add edx, dword [eax]
mov eax, dword [ebp - 0x18]
mov dword [eax + 4], edx
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx]
movzx ecx, word [edx + 0xe]
mov eax, 1
shl eax, cl
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx + 4]
lea eax, [edx + eax*4]
mov ecx, dword [ebp - 0x18]
mov dword [ecx + 8], eax
jmp 0x1030a027
mov edx, dword [ebp - 0x18]
mov dword [edx], 0
mov esp, ebp
pop ebp
ret
Function at 0x1006c49
Capabilities:
Get session user name

Disassembly:
push 0x11c
mov eax, 0x1020027
call fcn.01017758
mov esi, dword [ebp + 8]
and dword [ebp - 0x114], 0
mov dword [ebp - 4], 1
xor eax, eax
mov word [ebp - 0x124], ax
lea edi, [ebp - 0x122]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x124]
push eax
call dword [sym.imp.API_MS_Win_Core_SysInfo_L1_1_0.dll_GetLocalTime]
lea eax, [ebp - 0x128]
push eax
lea eax, [ebp - 0x110]
mov edi, 0x80
push eax
mov dword [ebp - 0x128], edi
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
test eax, eax
je 0x1006d39
mov eax, dword [esi]
mov ecx, dword [eax]
lea edx, [ebp - 0x114]
push edx
push eax
call dword [ecx + 0x1c]
mov esi, eax
test esi, esi
jl 0x1006d41
mov eax, dword [ebp - 0x114]
mov ecx, dword [eax]
lea edx, [ebp - 0x110]
push edx
push eax
call dword [ecx + 0x28]
mov esi, eax
test esi, esi
jl 0x1006d41
movzx eax, word [ebp - 0x118]
push eax
movzx eax, word [ebp - 0x11a]
push eax
movzx eax, word [ebp - 0x11c]
push eax
movzx eax, word [ebp - 0x11e]
push eax
movzx eax, word [ebp - 0x122]
push eax
movzx eax, word [ebp - 0x124]
push eax
push 0x10016d0
lea eax, [ebp - 0x110]
push edi
push eax
call fcn.01003f97
mov eax, dword [ebp - 0x114]
mov ecx, dword [eax]
add esp, 0x24
lea edx, [ebp - 0x110]
push edx
push eax
call dword [ecx + 0x38]
jmp 0x1006d3f
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
mov esi, eax
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x114]
call fcn.0100637a
mov eax, esi
call fcn.010177ac
ret 4
Function at 0x1008ebe
Capabilities:
Get file size
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push edi
xor eax, eax
xor ebx, ebx
mov dword [ebp - 0x14], ebx
lea edi, [ebp - 0x10]
stosd dword es:[edi], eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp + 8]
call dword [sym.imp.API_MS_Win_Core_File_L1_1_0.dll_GetFileSizeEx]
test eax, eax
jne 0x1008f01
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
cmp eax, ebx
jle 0x100905a
and eax, 0xffff
or eax, 0x80070000
jmp 0x100905a
cmp dword [ebp - 0x10], ebx
je 0x1008f10
mov eax, 0x8007000e
jmp 0x100905a
cmp dword [ebp - 0x14], ebx
jne 0x1008f1f
mov eax, 0x80070057
jmp 0x100905a
push esi
xor esi, esi
inc esi
test byte [ebp - 0x14], 1
mov dword [ebp - 4], ebx
je 0x1008f2e
xor esi, esi
mov edi, dword [sym.imp.API_MS_Win_Core_File_L1_1_0.dll_ReadFile]
push ebx
lea eax, [ebp - 4]
push eax
push 2
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
mov dword [ebp - 0xc], ebx
call edi
test eax, eax
je 0x1008fdd
cmp dword [ebp - 4], 2
jne 0x1008f60
mov eax, 0xfeff
cmp word [ebp - 0xc], ax
je 0x1008f62
xor esi, esi
cmp esi, ebx
je 0x1008fcc
mov esi, dword [ebp - 0x14]
shr esi, 1
xor ecx, ecx
push 2
pop edx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.010172c7
pop ecx
mov dword [ebp - 8], eax
cmp eax, ebx
je 0x1008ff8
push 0
lea ecx, [ebp - 4]
push ecx
lea ebx, [esi + esi]
push ebx
push eax
push dword [ebp + 8]
call edi
test eax, eax
jne 0x1008fa2
push dword [ebp - 8]
jmp 0x1009011
lea eax, [esi + esi - 2]
cmp dword [ebp - 4], eax
je 0x1008fb3
push dword [ebp - 8]
jmp 0x1009035
mov esi, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
xor eax, eax
push esi
mov word [ebx + esi - 2], ax
call fcn.010069eb
push esi
jmp 0x100904f
push ebx
push ebx
push ebx
push dword [ebp + 8]
call dword [sym.imp.API_MS_Win_Core_File_L1_1_0.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x1008fe7
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
cmp eax, ebx
jmp 0x100901f
mov esi, dword [ebp - 0x14]
inc esi
push esi
call fcn.010172c7
mov ebx, eax
pop ecx
test ebx, ebx
jne 0x1008fff
mov eax, 0x8007000e
jmp 0x1009059
push 0
lea eax, [ebp - 4]
push eax
push esi
push ebx
push dword [ebp + 8]
call edi
push ebx
test eax, eax
jne 0x100902d
call fcn.010172d7
pop ecx
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
test eax, eax
jle 0x1009059
and eax, 0xffff
or eax, 0x80070000
jmp 0x1009059
lea eax, [esi - 1]
cmp dword [ebp - 4], eax
je 0x1009041
call fcn.010172d7
mov eax, 0x80004005
jmp 0x1009058
mov ecx, dword [ebp + 0xc]
mov byte [ebx + esi - 1], 0
call fcn.01008175
push ebx
mov edi, eax
call fcn.010172d7
mov eax, edi
pop ecx
pop esi
pop edi
pop ebx
leave
ret 8
Function at 0x100b118
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x104
mov eax, dword [0x1029c7c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push 0x80
lea eax, [ebp - 0x104]
push eax
push 0x21
push 0x400
call dword [sym.imp.API_MS_Win_Core_Localization_L1_1_0.dll_GetLocaleInfoW]
test eax, eax
je 0x100b174
movzx eax, word [ebp - 0x104]
sub eax, 0x30
je 0x100b16f
dec eax
je 0x100b16a
dec eax
je 0x100b165
xor eax, eax
inc eax
jmp 0x100b176
push 2
pop eax
jmp 0x100b171
xor eax, eax
inc eax
jmp 0x100b171
xor eax, eax
mov word [esi], ax
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.01017692
leave
ret 4
Function at 0x100e2f9
Capabilities:
Query service status
Start service

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x420
mov eax, dword [0x1029c7c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
xor eax, eax
push 0x3f6
push eax
mov dword [ebp - 0x400], eax
mov dword [ebp - 0x404], eax
lea eax, [ebp - 0x3fa]
xor ecx, ecx
push eax
mov word [ebp - 0x3fc], cx
call sub.msvcrt.dll_memset
add esp, 0xc
push edi
call fcn.0101c4a4
test eax, eax
jne 0x100e3bd
mov ebx, 0x1fc
push ebx
push 0x1001b78
lea eax, [ebp - 0x3fc]
push eax
call fcn.01018bdf
test edi, edi
je 0x100e3bd
movzx eax, word [edi]
mov ecx, edi
test ax, ax
je 0x100e3af
movzx eax, ax
cmp ax, 0x5c
jne 0x100e38b
inc ecx
inc ecx
movzx eax, word [ecx]
inc dword [ebp - 0x400]
test ax, ax
jne 0x100e375
cmp word [ebp - 0x400], 2
jne 0x100e3a5
push ebx
push edi
lea eax, [ebp - 0x3fc]
push eax
call fcn.01018bdf
jmp 0x100e3bd
cmp word [ebp - 0x400], 0
jne 0x100e3bd
push ebx
push edi
lea eax, [ebp - 0x3fc]
push eax
call fcn.01018c22
xor edi, edi
inc edi
push edi
push 0
lea eax, [ebp - 0x3fc]
push eax
call dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_OpenSCManagerW]
mov dword [ebp - 0x400], eax
test eax, eax
jne 0x100e3e3
mov dword [esi], edi
xor eax, eax
jmp 0x100e4c1
push 0x14
push 0x1001b64
push eax
call dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_OpenServiceW]
mov ebx, eax
test ebx, ebx
jne 0x100e407
push dword [ebp - 0x400]
mov dword [esi], edi
call dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_CloseServiceHandle]
jmp 0x100e3dc
lea eax, [ebp - 0x420]
push eax
push ebx
call dword [sym.imp.API_MS_WIN_Service_winsvc_L1_1_0.dll_QueryServiceStatus]
test eax, eax
jne 0x100e42e
mov dword [esi], edi
push dword [ebp - 0x400]
mov esi, dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_CloseServiceHandle]
call esi
push ebx
call esi
jmp 0x100e3dc
cmp dword [ebp - 0x41c], 4
je 0x100e4ac
cmp dword [ebp + 0x10], 0
je 0x100e4ae
push 0xce
call fcn.01019fbd
push eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x20
push eax
call fcn.01018c65
lea eax, [ebp - 0x404]
push eax
call fcn.01007c43
cmp eax, edi
jne 0x100e46e
mov dword [esi], 2
jmp 0x100e41b
xor eax, eax
cmp dword [ebp - 0x404], eax
je 0x100e480
mov dword [esi], 3
jmp 0x100e41b
push eax
push eax
push ebx
call dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_StartServiceW]
test eax, eax
je 0x100e419
lea eax, [ebp - 0x420]
push eax
push ebx
call dword [sym.imp.API_MS_WIN_Service_winsvc_L1_1_0.dll_QueryServiceStatus]
test eax, eax
je 0x100e4aa
cmp dword [ebp - 0x41c], 4
jne 0x100e48d
jmp 0x100e4ae
mov dword [esi], edi
xor edi, edi
push dword [ebp - 0x400]
mov esi, dword [sym.imp.API_MS_WIN_Service_Management_L1_1_0.dll_CloseServiceHandle]
call esi
push ebx
call esi
mov eax, edi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.01017692
leave
ret 0xc
Function at 0x10132dd
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push esi
mov esi, dword [sym.imp.API_MS_Win_Core_LocalRegistry_L1_1_0.dll_RegQueryValueExW]
push edi
xor edi, edi
lea eax, [ebp - 4]
push eax
push edi
push edi
push edi
push dword [ebp + 0xc]
mov dword [ebp - 4], edi
push dword [ebp + 8]
mov dword [ebp - 8], edi
mov dword [ebp - 0xc], edi
call esi
mov eax, dword [ebp - 4]
add eax, 0xa
push eax
call fcn.01018520
mov dword [ebp - 8], eax
cmp eax, edi
jne 0x1013326
push 0xe
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
xor eax, eax
jmp 0x101334e
lea ecx, [ebp - 4]
push ecx
push eax
lea eax, [ebp - 0xc]
push eax
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call esi
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
lea eax, [ebp - 8]
push eax
call fcn.01018819
xor eax, eax
inc eax
pop edi
pop esi
leave
ret 0xc
Function at 0x1017683
Capabilities:
Terminate process

Disassembly:
push 0x10
push 0x1021e60
call fcn.01017a04
xor ebx, ebx
mov dword [ebp - 4], ebx
mov eax, dword fs:[0x18]
mov esi, dword [eax + 4]
mov dword [ebp - 0x1c], ebx
mov edi, 0x102a370
push ebx
push esi
push edi
call dword [sym.imp.API_MS_Win_Core_Interlocked_L1_1_0.dll_InterlockedCompareExchange]
cmp eax, ebx
je 0x1017498
cmp eax, esi
jne 0x101748b
xor esi, esi
inc esi
mov dword [ebp - 0x1c], esi
jmp 0x101749b
push 0x3e8
call dword [sym.imp.API_MS_Win_Core_Misc_L1_1_0.dll_Sleep]
jmp 0x1017472
xor esi, esi
inc esi
mov eax, dword [0x102a36c]
cmp eax, esi
jne 0x10174ae
push 0x1f
call sub.msvcrt.dll__amsg_exit
pop ecx
jmp 0x10174e9
mov eax, dword [0x102a36c]
test eax, eax
jne 0x10174e3
mov dword [0x102a36c], esi
push 0x1001354
push 0x1001348
call fcn.010173ef
pop ecx
pop ecx
test eax, eax
je 0x10174e9
mov dword [ebp - 4], 0xfffffffe
mov eax, 0xff
jmp 0x10175b3
mov dword [0x1029e88], esi
mov eax, dword [0x102a36c]
cmp eax, esi
jne 0x101750d
push 0x1001344
push 0x1001310
call sub.msvcrt.dll__initterm
pop ecx
pop ecx
mov dword [0x102a36c], 2
cmp dword [ebp - 0x1c], ebx
jne 0x101751a
push ebx
push edi
call dword [sym.imp.API_MS_Win_Core_Interlocked_L1_1_0.dll_InterlockedExchange]
cmp dword [0x102a374], ebx
je 0x101753b
push 0x102a374
call fcn.01017979
pop ecx
test eax, eax
je 0x101753b
push ebx
push 2
push ebx
call dword [0x102a374]
push dword [0x1029e70]
push dword [0x1029e74]
push dword [0x1029e6c]
call fcn.01013c5d
add esp, 0xc
mov dword [0x1029e84], eax
cmp dword [0x1029e78], ebx
jne 0x1017599
push eax
call dword [sym.imp.msvcrt.dll_exit]
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
mov ecx, dword [ecx]
mov dword [ebp - 0x20], ecx
push eax
push ecx
call sub.msvcrt.dll__XcptFilter
pop ecx
pop ecx
ret
cmp dword [0x1029e88], ebx
jne 0x10175a7
call dword [sym.imp.msvcrt.dll__cexit]
mov dword [ebp - 4], 0xfffffffe
mov eax, dword [0x1029e84]
call fcn.01017a49
ret
call fcn.01017bef
jmp 0x1017450
Function at 0x101c12b
Capabilities:
Initialize winsock library
Resolve dns

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xa08
mov eax, dword [0x1029c7c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
push edi
xor esi, esi
mov dword [ebp - 0x9e4], eax
push 7
xor eax, eax
pop ecx
lea edi, [ebp - 0xa04]
mov dword [ebp - 0xa08], esi
mov dword [ebp - 0x9e8], edx
mov dword [ebp - 0x9e0], esi
mov dword [ebp - 0x9dc], esi
rep stosd dword es:[edi], eax
mov word [ebp - 0x46], ax
cmp dword [ebp - 0x9e4], esi
je 0x101c2af
cmp ebx, esi
je 0x101c2af
mov eax, dword [ebx]
cmp eax, esi
je 0x101c1a8
cmp eax, 2
jb 0x101c2af
cmp edx, esi
je 0x101c2af
cmp dword [0x102a1d4], esi
jne 0x101c1dc
lea eax, [ebp - 0x9d8]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x101c1d2
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
jmp 0x101c2bb
mov dword [0x102a1d4], 1
lea eax, [ebp - 0x9dc]
push eax
lea eax, [ebp - 0xa08]
push eax
push esi
push dword [ebp - 0x9e4]
call dword [sym.imp.WS2_32.dll_GetAddrInfoW]
test eax, eax
jne 0x101c2c1
mov esi, dword [ebp - 0x9dc]
xor edi, edi
jmp 0x101c249
push 4
xor eax, eax
mov word [ebp - 0x848], ax
push 0x20
lea eax, [ebp - 0x44]
push eax
push 0x401
lea eax, [ebp - 0x848]
push eax
push dword [esi + 0x10]
push dword [esi + 0x18]
call dword [sym.imp.WS2_32.dll_GetNameInfoW]
cmp eax, edi
je 0x101c24f
cmp eax, 0x2afc
jne 0x101c246
cmp word [ebp - 0x848], di
jne 0x101c24f
mov esi, dword [esi + 0x1c]
cmp esi, edi
jne 0x101c209
jmp 0x101c29b
lea esi, [ebp - 0x848]
cmp dword [ebp + 0x14], edi
jne 0x101c26c
mov eax, esi
push 0x1001fd0
push eax
call dword [sym.imp.msvcrt.dll_wcstok]
pop ecx
pop ecx
mov esi, eax
push edi
push esi
call fcn.010182b0
mov ecx, dword [ebx]
inc eax
cmp ecx, eax
jae 0x101c288
mov dword [ebx], eax
mov dword [ebp - 0x9e0], 1
jmp 0x101c29b
push ecx
push esi
push dword [ebp - 0x9e8]
call fcn.01018bdf
mov dword [ebp - 0x9e0], eax
push dword [ebp - 0x9dc]
call dword [sym.imp.WS2_32.dll_FreeAddrInfoW]
mov eax, dword [ebp - 0x9e0]
jmp 0x101c2c3
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
test eax, eax
jne 0x101c2c1
push 0x57
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.01017692
leave
ret 0x10
Function at 0x101c6dd
Capabilities:
Connect network resource

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
cmp esi, ebx
je 0x101c838
push esi
call fcn.0101c4a4
cmp eax, 1
je 0x101c838
push esi
mov dword [ebp + 8], esi
call fcn.0101c032
cmp eax, 1
jne 0x101c717
add esi, 4
mov dword [ebp + 8], esi
push dword [ebp + 8]
call fcn.0101c60b
test eax, eax
jne 0x101c733
call fcn.01018081
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
jmp 0x101c86c
cmp dword [ebp + 0x14], ebx
je 0x101c75c
push dword [ebp + 0x14]
call dword [sym.imp.API_MS_Win_Core_Misc_L1_1_0.dll_lstrlenW]
test eax, eax
je 0x101c75c
push dword [ebp + 0x14]
push dword [ebp + 8]
push 0x1001ff0
push 2
call fcn.0101942a
add esp, 0x10
jmp 0x101c76e
push dword [ebp + 8]
push 0x1001fd4
push 1
call fcn.0101942a
add esp, 0xc
test eax, eax
jne 0x101c791
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
test eax, eax
jne 0x101c784
push 8
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
call fcn.01018081
push 8
pop eax
jmp 0x101c86c
call fcn.01017fee
cmp eax, ebx
jne 0x101c7a3
push 0x12
call fcn.01017f7d
jmp 0x101c7ad
push ebx
push ebx
push eax
push 0x12
call fcn.01019139
mov edx, eax
cmp edx, ebx
je 0x101c772
push edi
push 8
pop ecx
push ebx
push dword [ebp + 0xc]
xor eax, eax
push dword [ebp + 0x10]
lea edi, [ebp - 0x20]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], edx
call sub.MPR.dll_WNetAddConnection2W
mov esi, eax
pop edi
cmp esi, ebx
je 0x101c7fe
cmp esi, 0x4b8
je 0x101c7f7
push esi
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
call fcn.01018081
jmp 0x101c866
call fcn.010194bc
jmp 0x101c866
push ebx
xor esi, esi
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
push dword [ebp + 8]
call fcn.0101c2d9
push eax
call fcn.010181c9
test eax, eax
jne 0x101c866
push dword [ebp + 8]
call fcn.0101c6c0
push 0x1580
call fcn.01019fbd
push eax
call fcn.0101801a
mov esi, 0x4b8
jmp 0x101c866
cmp dword [ebp + 0xc], ebx
je 0x101c86a
push dword [ebp + 0xc]
call dword [sym.imp.API_MS_Win_Core_Misc_L1_1_0.dll_lstrlenW]
test eax, eax
je 0x101c86a
push 0x157e
call fcn.01019fbd
push eax
call fcn.0101801a
mov esi, 0xa0010001
push esi
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
mov eax, esi
jmp 0x101c86c
xor eax, eax
pop esi
pop ebx
leave
ret 0x10
Function at 0x101c898
Capabilities:
Get session user name

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
mov ebx, dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_SetLastError]
push esi
push edi
push 0
call ebx
mov edi, dword [ebp + 8]
test edi, edi
je 0x101ca22
push 0
push edi
call fcn.010182b0
test eax, eax
je 0x101ca22
xor esi, esi
inc esi
cmp dword [ebp + 0x1c], esi
jne 0x101c901
cmp dword [ebp + 0xc], 0
je 0x101c8e7
cmp dword [ebp + 0x10], 2
jb 0x101c8e7
cmp dword [ebp + 0x14], 0
je 0x101c8e7
cmp dword [ebp + 0x18], 2
jae 0x101c901
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
test eax, eax
jne 0x101c8f5
push 0x57
call ebx
call fcn.01018081
xor eax, eax
jmp 0x101ca25
push edi
mov dword [ebp - 4], edi
call fcn.0101c032
cmp eax, esi
jne 0x101c914
lea eax, [edi + 4]
mov dword [ebp - 4], eax
cmp dword [ebp + 0x1c], esi
jne 0x101c945
cmp dword [ebp + 0x14], 0
je 0x101c945
push 0
push esi
push 0x10014f4
push dword [ebp + 0x14]
call fcn.010182d1
test eax, eax
jne 0x101c945
push dword [ebp - 4]
call fcn.0101c60b
test eax, eax
jne 0x101ca39
jmp 0x101c8f5
push dword [ebp - 4]
and dword [ebp - 8], 0
call fcn.0101c60b
test eax, eax
je 0x101c8f5
cmp dword [ebp + 0xc], 0
je 0x101c98a
push dword [ebp + 0xc]
call dword [sym.imp.API_MS_Win_Core_Misc_L1_1_0.dll_lstrlenW]
test eax, eax
je 0x101c98a
mov eax, dword [ebp + 0x1c]
neg eax
sbb eax, eax
not eax
and eax, dword [ebp + 0x14]
push eax
push dword [ebp + 0xc]
push edi
call fcn.0101c877
mov edi, eax
cmp dword [ebp + 0x1c], esi
jne 0x101c999
mov dword [ebp - 8], esi
jmp 0x101c999
push 0
push 0
push edi
mov dword [ebp - 8], esi
call fcn.0101c877
mov edi, eax
cmp edi, 0x55
jne 0x101c9a9
push 0x50010001
call ebx
mov eax, esi
jmp 0x101ca25
test edi, edi
jne 0x101c9b5
cmp dword [ebp - 8], esi
je 0x101c99e
push edi
jmp 0x101c9a3
mov eax, 0x4c3
cmp edi, eax
ja 0x101c9e2
je 0x101c9df
cmp edi, 0x34
je 0x101cad1
cmp edi, 0x56
je 0x101ca2c
cmp edi, 0x4be
je 0x101cad1
jmp 0x101c8f5
push eax
jmp 0x101c9a3
cmp edi, 0x4cf
jb 0x101c8f5
cmp edi, 0x4d1
jbe 0x101cad1
cmp edi, 0x52e
je 0x101ca2c
mov esi, 0xa0010001
cmp edi, esi
jne 0x101c8f5
push 0x157e
call fcn.01019fbd
push eax
call fcn.0101801a
push esi
call ebx
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0x18
cmp dword [ebp + 0x1c], 0
je 0x101c8fa
mov edi, dword [ebp + 8]
push dword [ebp + 0xc]
call dword [sym.imp.API_MS_Win_Core_Misc_L1_1_0.dll_lstrlenW]
test eax, eax
jne 0x101ca5c
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0xc]
push 2
call sub.SspiCli.dll_GetUserNameExW
test al, al
je 0x101c8f5
push dword [ebp + 0xc]
push 0x157d
call fcn.01019fbd
push eax
push esi
push esi
call dword [sym.imp.msvcrt.dll___iob_func]
add eax, 0x20
push eax
call fcn.01019e6a
add esp, 0x14
push dword [ebp + 0x18]
push dword [ebp + 0x14]
call fcn.01018eca
push dword [ebp + 0x14]
push dword [ebp + 0xc]
push edi
call fcn.0101c877
mov edi, eax
test edi, edi
je 0x101c9a5
cmp edi, 0x34
je 0x101cad1
cmp edi, 0x4be
je 0x101cad1
mov eax, 0x4c3
cmp edi, eax
je 0x101c9df
cmp edi, 0x4ce
jbe 0x101c8f5
cmp edi, 0x4d1
ja 0x101ca02
push 0x4c6
call ebx
call fcn.01018081
push edi
call ebx
jmp 0x101c8fa
Function at 0x101dfa6
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
push edi
mov edi, 0x20a
push edi
mov esi, ecx
call fcn.010172c7
pop ecx
push eax
mov ecx, esi
call fcn.0101dd32
push edi
push 0
push dword [esi]
call sub.msvcrt.dll_memset
mov esi, dword [esi]
add esp, 0xc
push 0x105
push esi
push 0x1002440
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
pop edi
pop esi
test eax, eax
jne 0x101dffb
call dword [sym.imp.API_MS_Win_Core_ErrorHandling_L1_1_0.dll_GetLastError]
test eax, eax
jle 0x101dffd
and eax, 0xffff
or eax, 0x80070000
ret
xor eax, eax
ret