Function at 0x101f6e70
Capabilities:
Check os version

Disassembly:
sub esp, 0x29c
push ebx
push esi
lea eax, [esp + 0x10]
push edi
xor ebx, ebx
push eax
mov dword [esp + 0x10], ebx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov eax, dword [esp + 0x24]
cmp eax, 1
jne 0x101f6f93
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
lea ecx, [esp + 0x10]
lea edx, [esp + 0xc]
push ecx
push edx
push ebx
push ebx
push 2
push ebx
push 1
call sub.WINSPOOL.DRV_EnumPrintersA
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x101f7081
mov eax, dword [esp + 0xc]
cmp eax, ebx
je 0x101f7081
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
cmp esi, ebx
jne 0x101f6ef8
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
mov edx, dword [esp + 0xc]
lea eax, [esp + 0x10]
lea ecx, [esp + 0xc]
push eax
push ecx
push edx
push esi
push 2
push ebx
push 1
call sub.WINSPOOL.DRV_EnumPrintersA
test eax, eax
jne 0x101f6f2b
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
mov eax, dword [esi + 4]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
call edi
mov ebx, dword [esp + 0x2b0]
cmp eax, dword [ebx]
jb 0x101f6f60
mov ecx, dword [esi + 4]
push ecx
call edi
inc eax
push esi
mov dword [ebx], eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
mov edx, dword [esi + 4]
mov eax, dword [esp + 0x2ac]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov ecx, dword [esi + 4]
push ecx
call edi
inc eax
push esi
mov dword [ebx], eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x29c
ret 8
cmp eax, 2
jne 0x101f6f82
cmp dword [esp + 0x18], 5
jb 0x101f7010
push str.winspool.drv
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
cmp esi, ebx
jne 0x101f6fbe
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
push str.GetDefaultPrinterA
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
jne 0x101f6fe3
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
mov edx, dword [esp + 0x2b0]
mov ecx, dword [esp + 0x2ac]
push edx
push ecx
call eax
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp edi, ebx
jne 0x101f6f82
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
lea edx, [esp + 0xa8]
push 0x200
push edx
push 0x103f51d0
push str.device
push str.windows
call dword [sym.imp.KERNEL32.dll_GetProfileStringA]
test eax, eax
ja 0x101f7044
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
lea eax, [esp + 0xa8]
push 0x103f51bc
push eax
call fcn.10276c6e
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
add esp, 8
lea ecx, [esp + 0xa8]
push ecx
call esi
mov edi, dword [esp + 0x2b0]
cmp eax, dword [edi]
jb 0x101f708f
lea edx, [esp + 0xa8]
push edx
call esi
inc eax
mov dword [edi], eax
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x29c
ret 8
mov ecx, dword [esp + 0x2ac]
lea eax, [esp + 0xa8]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea edx, [esp + 0xa8]
push edx
call esi
inc eax
mov dword [edi], eax
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x29c
ret 8