joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1012e989
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 0x1012ea26
push ebx
push esi
call fcn.1012ea29
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.10128631
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1012e9d3
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1012ea25
push edi
push eax
call fcn.10128521
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1012e9f3
call fcn.101284e7
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1012ea24
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.10128631
add esp, 0x20
test eax, eax
jne 0x1012ea12
push edi
call fcn.101284e7
jmp 0x1012ea1a
push ebx
call fcn.101284e7
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 0x101302f4
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 + 0x10151978]
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 0x10130334
cmp byte [ebx], 0xa
jne 0x10130334
or byte [edi + eax + 0x28], 4
jmp 0x10130339
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 0x10130438
mov dl, byte [eax]
cmp dl, 0x1a
je 0x1013041b
inc eax
cmp dl, 0xd
je 0x10130365
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x1013038b
cmp eax, ecx
jae 0x10130399
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 0x1013034d
jmp 0x10130438
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 0x10130416
cmp dword [ebp - 0x10], 0
je 0x10130416
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x10151978]
test byte [eax + edi + 0x28], 0x48
je 0x101303f0
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x101303db
mov byte [esi], dl
jmp 0x101303ec
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x10151978]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x10130438
cmp byte [ebp - 1], 0xa
jne 0x101303ff
cmp esi, ebx
jne 0x101303ff
mov byte [esi], 0xa
jmp 0x10130437
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1012dbfb
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x10130438
mov byte [esi], 0xd
jmp 0x10130437
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x10151978]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x10130435
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x10130438
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x10130441
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 + 0x10151978]
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 0x10130487
cmp word [ebx], dx
jne 0x10130487
or byte [eax + edi + 0x28], 4
jmp 0x1013048c
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 0x101305ef
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 0x101305cf
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x101304cd
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x10130503
cmp eax, edx
jae 0x10130511
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 0x101304a8
jmp 0x101305ef
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 0x101305ca
cmp dword [ebp - 0x18], 0
je 0x101305ca
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x10151978]
test byte [eax + edi + 0x28], 0x48
je 0x101305a0
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 0x10130564
mov word [esi], cx
jmp 0x1013059b
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x10151978]
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 + 0x10151978]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x10151978]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x101305ef
pop eax
cmp word [ebp - 4], ax
jne 0x101305b0
cmp esi, ebx
jne 0x101305b0
mov word [esi], ax
jmp 0x101305ec
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.1012dbfb
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x101305ef
push 0xd
pop eax
jmp 0x101305ab
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x10151978]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x101305e9
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x101305ef
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x10133cde
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x1014fe14]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 0x18], eax
call fcn.10128773
add eax, 0x50
lea edi, [ebp - 0x10]
mov dword [ebp - 0x14], eax
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
call fcn.10128773
lea ecx, [ebp - 0x10]
xor edx, edx
mov dword [eax + 0x34c], ecx
lea ecx, [esi + 0x80]
mov eax, dword [ebp - 0x14]
mov dword [eax], esi
lea edi, [eax + 4]
mov dword [edi], ecx
test ecx, ecx
je 0x10133d55
cmp word [ecx], dx
je 0x10133d55
mov eax, dword [0x1013e554]
push edi
dec eax
push eax
push 0x1013e440
call fcn.10133ece
mov eax, dword [ebp - 0x14]
add esp, 0xc
xor edx, edx
mov dword [ebp - 0x10], edx
mov eax, dword [eax]
test eax, eax
je 0x10133dc8
cmp word [eax], dx
je 0x10133dc8
mov eax, dword [edi]
test eax, eax
je 0x10133d79
cmp word [eax], dx
je 0x10133d79
lea eax, [ebp - 0x10]
push eax
call fcn.10133f2f
jmp 0x10133d82
lea eax, [ebp - 0x10]
push eax
call fcn.1013421d
cmp dword [ebp - 0x10], 0
pop ecx
jne 0x10133df2
mov eax, dword [0x1013e43c]
push dword [ebp - 0x14]
dec eax
push eax
push 0x1013e130
call fcn.10133ece
add esp, 0xc
test al, al
je 0x10133df2
mov eax, dword [edi]
xor edi, edi
test eax, eax
je 0x10133dbd
cmp word [eax], di
je 0x10133dbd
lea eax, [ebp - 0x10]
push eax
call fcn.10133f2f
pop ecx
jmp 0x10133df4
lea eax, [ebp - 0x10]
push eax
call fcn.1013421d
jmp 0x10133dba
mov eax, dword [edi]
test eax, eax
je 0x10133ddf
cmp word [eax], dx
je 0x10133ddf
lea eax, [ebp - 0x10]
push eax
call fcn.10134351
pop ecx
jmp 0x10133df2
mov dword [ebp - 0x10], 0x104
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
xor edi, edi
cmp dword [ebp - 0x10], 0
je 0x10133ebd
lea eax, [ebp - 0x10]
push eax
lea eax, [esi + 0x100]
neg esi
sbb esi, esi
and esi, eax
push esi
call fcn.10134443
mov esi, eax
pop ecx
pop ecx
test esi, esi
je 0x10133ebd
movzx ecx, si
push ecx
call dword [sym.imp.KERNEL32.dll_IsValidCodePage]
test eax, eax
je 0x10133ebd
push 1
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_IsValidLocale]
test eax, eax
je 0x10133ebd
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x10133e4a
mov dword [eax], esi
mov eax, dword [ebp - 0x14]
push edi
push 0x55
add eax, 0x250
push eax
push dword [ebp - 0xc]
call fcn.1012a9fe
test ebx, ebx
je 0x10133eb8
push edi
push 0x55
lea eax, [ebx + 0x120]
push eax
push dword [ebp - 0xc]
call fcn.1012a9fe
push 0x40
push ebx
push 0x1001
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x10133ebd
push 0x40
lea eax, [ebx + 0x80]
push eax
push 0x1002
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x10133ebd
push 0xa
push 0x10
lea ecx, [ebx + 0x100]
push ecx
push esi
call fcn.10138296
add esp, 0x10
xor eax, eax
inc eax
jmp 0x10133ebf
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1011e164
leave
ret
Function at 0x10134549
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
call fcn.10128773
mov esi, dword [ebp + 8]
mov edi, eax
push 2
lea eax, [ebp - 4]
mov ecx, esi
push eax
and ecx, 0x3ff
push 0x20000001
or ecx, 0x400
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x101345b8
cmp esi, dword [ebp - 4]
je 0x101345b3
cmp dword [ebp + 0xc], 0
je 0x101345b3
mov esi, dword [edi + 0x50]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x10134590
push dword [edi + 0x50]
sub esi, ecx
sar esi, 1
call fcn.10134612
pop ecx
xor ecx, ecx
cmp eax, esi
setne cl
mov eax, ecx
jmp 0x101345ba
xor eax, eax
inc eax
jmp 0x101345ba
xor eax, eax
pop edi
pop esi
leave
ret
Function at 0x10138b94
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.10138d2b
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10138d03
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10138d03
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x10138cb8
jg 0x10138bf0
test eax, eax
je 0x10138cae
push 1
push 0x1000
call fcn.1012ae8e
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x10138c13
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x10138ca5
push 0x8000
push ebx
call fcn.10138a8e
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x10138c3c
jg 0x10138c37
cmp ecx, 0x1000
jb 0x10138c3c
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.1012edba
add esp, 0x10
cmp eax, 0xffffffff
je 0x10138c81
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x10138c37
jl 0x10138c68
test ecx, ecx
jne 0x10138c29
push dword [ebp - 0xc]
push ebx
call fcn.10138a8e
push esi
call fcn.101284e7
add esp, 0xc
xor ebx, ebx
jmp 0x10138d11
cmp byte [edi + 0x24], 0
je 0x10138c98
cmp dword [edi + 0x20], 5
jne 0x10138c98
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x10138ca3
mov ebx, dword [edi + 0x18]
jmp 0x10138ca5
xor ebx, ebx
push esi
call fcn.101284e7
pop ecx
jmp 0x10138d11
test ecx, ecx
jg 0x10138c7a
jl 0x10138cb8
test eax, eax
jae 0x10138c7a
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1012dbfb
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x10138cd8
cmp byte [edi + 0x1c], 0
je 0x10138c7a
jmp 0x10138d09
push ebx
call fcn.101348f3
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x10138c7a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x10138d11
cmp byte [edi + 0x1c], 0
je 0x10138d0e
mov ebx, dword [edi + 0x18]
jmp 0x10138d11
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.1012dbfb
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x433000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
nop
mov eax, section..text
mov ebx, 0x40de38
nop
nop
mov ecx, 0x6ffd592e
nop
nop
nop
test eax, eax
nop
nop
je 0x43304e
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
jne 0x433024
nop
mov eax, section..data
mov ebx, 0x4304d8
nop
mov ecx, 0x1f363aa0
nop
nop
nop
nop
nop
test eax, eax
nop
nop
nop
je 0x433084
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
nop
add eax, 4
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
jne 0x43306c
nop
nop
nop
popal
nop
nop
nop
jmp 0x431219
Function at 0x401bb0
Capabilities:
Hash data with md5
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4e8
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x4a2608
push eax
mov dword [ebp - 0x4e8], ecx
call dword [sym.imp.MSVCR100.dll_fopen]
mov edi, eax
add esp, 8
test edi, edi
jne 0x401bf8
lea eax, [edi + 1]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret
mov ebx, dword [sym.imp.MSVCR100.dll_fread]
push edi
push 0x400
lea edx, [ebp - 0x40c]
push 1
push edx
mov dword [ebp - 0x4e4], 0
mov dword [ebp - 0x4e0], 0
mov dword [ebp - 0x4dc], 0x67452301
mov dword [ebp - 0x4d8], 0xefcdab89
mov dword [ebp - 0x4d4], 0x98badcfe
mov dword [ebp - 0x4d0], 0x10325476
call ebx
add esp, 0x10
test eax, eax
je 0x401c82
jle 0x401c6a
push eax
lea eax, [ebp - 0x40c]
push eax
lea esi, [ebp - 0x4e4]
call fcn.004019f0
add esp, 8
push edi
push 0x400
lea ecx, [ebp - 0x40c]
push 1
push ecx
call ebx
add esp, 0x10
test eax, eax
jne 0x401c52
mov ebx, dword [ebp - 0x4e8]
lea ecx, [ebp - 0x4e4]
call fcn.00401a90
push edi
call dword [sym.imp.MSVCR100.dll_ferror]
add esp, 4
push edi
test eax, eax
je 0x401cc1
call dword [sym.imp.MSVCR100.dll_fclose]
add esp, 4
mov eax, 2
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret
call dword [sym.imp.MSVCR100.dll_fclose]
mov ecx, dword [ebp - 8]
add esp, 4
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.00449013
mov esp, ebp
pop ebp
ret
Function at 0x404670
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
xor ebx, ebx
push 0xff
lea eax, [ebp - 0x103]
push ebx
push eax
mov dword [ebp - 0x20c], ebx
mov byte [ebp - 0x104], bl
call sub.MSVCR100.dll_memset
push 0x104
lea ecx, [ebp - 0x208]
push ebx
push ecx
call sub.MSVCR100.dll_memset
add esp, 0x18
cmp dword [edi + 4], ebx
je 0x4046f2
xor esi, esi
cmp dword [edi + 8], ebx
jle 0x4046e2
jmp 0x4046d0
mov edx, dword [edi + 4]
lea ecx, [edx + esi*4]
call dword [sym.imp.mfc100.dll_Ordinal_901]
inc esi
cmp esi, dword [edi + 8]
jl 0x4046d0
mov eax, dword [edi + 4]
push eax
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete___void__]
add esp, 4
mov dword [edi + 4], ebx
push 0x104
lea ecx, [ebp - 0x208]
push ecx
mov dword [edi + 0xc], ebx
mov dword [edi + 8], ebx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jne 0x404720
xor eax, eax
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret
push str.driversetchosts
lea edx, [ebp - 0x208]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push 0x4b9d18
lea eax, [ebp - 0x208]
push eax
lea ecx, [ebp - 0x20c]
push ecx
call dword [sym.imp.MSVCR100.dll_fopen_s]
mov esi, dword [ebp - 0x20c]
add esp, 0xc
cmp esi, ebx
je 0x40470e
push pe_nt_image_headers32
lea edx, [ebp - 0x104]
push ebx
push edx
call sub.MSVCR100.dll_memset
mov ebx, dword [sym.imp.MSVCR100.dll_fgets]
push esi
lea eax, [ebp - 0x104]
push pe_nt_image_headers32
push eax
call ebx
add esp, 0x18
test eax, eax
je 0x4047f4
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esp, [esp]
cmp byte [ebp - 0x104], 0x23
je 0x4047d8
lea ecx, [ebp - 0x104]
push ecx
call esi
cmp eax, 2
jb 0x4047d8
cmp byte [ebp + eax - 0x105], 0xa
lea eax, [ebp + eax - 0x105]
jne 0x4047bb
mov byte [eax], 0
push ecx
lea edx, [ebp - 0x104]
mov ecx, esp
mov dword [ebp - 0x210], esp
push edx
call dword [sym.imp.mfc100.dll_Ordinal_310]
mov ecx, edi
call fcn.00404b10
mov eax, dword [ebp - 0x20c]
push eax
lea ecx, [ebp - 0x104]
push pe_nt_image_headers32
push ecx
call ebx
add esp, 0xc
test eax, eax
jne 0x404790
mov edx, dword [ebp - 0x20c]
push edx
call dword [sym.imp.MSVCR100.dll_fclose]
mov ecx, dword [ebp - 4]
add esp, 4
pop esi
xor ecx, ebp
mov eax, 1
pop ebx
call fcn.00449013
mov esp, ebp
pop ebp
ret
Function at 0x405030
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48bab0
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor ebx, ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 0x2c], bl
push 1
push 0x4d0da8
lea edx, [ebp - 0x2c]
mov byte [ebp - 4], 1
call fcn.00405e10
push ebx
lea eax, [ebp + 8]
push eax
or eax, 0xffffffff
lea esi, [ebp - 0x2c]
call fcn.0040a380
mov eax, dword [ebp - 0x2c]
mov esi, 0x10
cmp dword [ebp - 0x18], esi
jae 0x40509f
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x4050e2
cmp dword [ebp - 0x18], esi
jb 0x4050bc
mov ecx, dword [ebp - 0x2c]
push ecx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 0x2c], bl
cmp dword [ebp + 0x1c], esi
jb 0x4050db
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov eax, 1
jmp 0x405115
cmp dword [ebp - 0x18], esi
jb 0x4050f4
mov eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], ebx
mov byte [ebp - 0x2c], bl
cmp dword [ebp + 0x1c], esi
jb 0x405113
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret 0x1c
Function at 0x405140
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
lea eax, [ebp - 0x18]
push eax
push 8
mov dword [ebp - 0xc], 0
mov word [ebp - 8], 0x500
xor edi, edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x405236
push 0x400
call dword [sym.imp.MSVCR100.dll_void____cdecl_operator_new___unsigned_int_]
mov esi, eax
add esp, 4
test esi, esi
je 0x405247
mov edx, dword [ebp - 0x18]
lea ecx, [ebp - 0x1c]
push ecx
push 0x400
push esi
push 2
push edx
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
mov edi, eax
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x405239
lea ecx, [ebp - 0x14]
push ecx
push 0
push 0
push 0
push 0
push 0
push 0
push 0x220
push 0x20
push 2
lea edx, [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x405239
xor edi, edi
mov dword [ebp - 0x10], 0
cmp dword [esi], edi
jbe 0x405227
push ebx
lea ebx, [esi + 4]
mov eax, dword [ebx]
mov ecx, dword [ebp - 0x14]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x40521f
inc edi
add ebx, 8
cmp edi, dword [esi]
jb 0x4051f6
mov edx, dword [ebp - 0x14]
pop ebx
push edx
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov edi, dword [ebp - 0x10]
jmp 0x405239
mov dword [ebp - 0x10], 1
pop ebx
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov edi, dword [ebp - 0x10]
jmp 0x405239
mov esi, dword [ebp - 0x1c]
test esi, esi
je 0x405247
push esi
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
add esp, 4
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
xor ecx, ebp
pop esi
call fcn.00449013
mov esp, ebp
pop ebp
ret
Function at 0x4053b0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor ebx, ebx
push 0x103
lea eax, [ebp - 0x107]
push ebx
push eax
mov dword [ebp - 0x10c], ebx
mov byte [ebp - 0x108], bl
call sub.MSVCR100.dll_memset
mov eax, dword [ebp + 8]
dec eax
add esp, 0xc
mov dword [ebp - 0x114], 0x104
cmp eax, 4
ja case.default.0x405400
jmp dword [eax*4 + 0x405540]
mov eax, SysReAllocString
jmp 0x405428
mov eax, SysReAllocString
jmp 0x405428
mov eax, reloc.OLEAUT32.dll_SysReAllocString
jmp 0x405428
mov eax, SysStringLen
jmp 0x405428
mov eax, SysStringLen
mov ecx, dword [ebp + 0xc]
mov edi, 0x10
cmp dword [ebp + 0x20], edi
jae 0x405438
lea ecx, [ebp + 0xc]
lea edx, [ebp - 0x110]
push edx
push 0x20019
push ebx
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4054cb
mov eax, dword [ebp + 0x28]
cmp dword [ebp + 0x3c], edi
jae 0x40545c
lea eax, [ebp + 0x28]
lea ecx, [ebp - 0x114]
push ecx
lea edx, [ebp - 0x108]
push edx
mov edx, dword [ebp - 0x110]
lea ecx, [ebp - 0x10c]
push ecx
push ebx
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4054cb
mov esi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
cmp dword [ebp + 0x20], edi
jb 0x405498
mov eax, dword [ebp + 0xc]
push eax
call esi
add esp, 4
mov dword [ebp + 0x20], 0xf
mov dword [ebp + 0x1c], ebx
mov byte [ebp + 0xc], bl
cmp dword [ebp + 0x3c], edi
jb 0x4054b3
mov ecx, dword [ebp + 0x28]
push ecx
call esi
add esp, 4
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret 0x3c
mov esi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
cmp dword [ebp + 0x20], edi
jb 0x4054df
mov edx, dword [ebp + 0xc]
push edx
call esi
add esp, 4
mov dword [ebp + 0x20], 0xf
mov dword [ebp + 0x1c], ebx
mov byte [ebp + 0xc], bl
cmp dword [ebp + 0x3c], edi
jb 0x40552b
mov eax, dword [ebp + 0x28]
push eax
jmp 0x405526
mov esi, dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void__]
mov edi, 0x10
cmp dword [ebp + 0x20], edi
jb 0x405510
mov ecx, dword [ebp + 0xc]
push ecx
call esi
add esp, 4
mov dword [ebp + 0x20], 0xf
mov dword [ebp + 0x1c], ebx
mov byte [ebp + 0xc], bl
cmp dword [ebp + 0x3c], edi
jb 0x40552b
mov edx, dword [ebp + 0x28]
push edx
call esi
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.00449013
mov esp, ebp
pop ebp
ret 0x3c