Function at 0x1005919
Capabilities:
Get domain controller name

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x4c
xor eax, eax
push ebx
push edi
lea edi, [ebp - 0x2c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor eax, eax
lea edi, [ebp - 0x3c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor eax, eax
lea edi, [ebp - 0x4c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
stosd dword es:[edi], eax
push 0x29
push 0x11
stosd dword es:[edi], eax
mov edi, dword [ebp + 8]
mov dword [ebp - 0x10], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], ebx
push 0x14
je 0x1005979
push 0x19
push 0x18
push 0xd
push 0xc
push 0xb
push 0xa
push 0xf
push 0xe
push ebx
push edi
call fcn.0100426a
add esp, 0x34
jmp 0x100598f
push 0xd
push 0xc
push 0xb
push 0xa
push 0xf
push 0xe
push ebx
push edi
call fcn.0100426a
add esp, 0x2c
cmp eax, ebx
jne 0x100599d
mov eax, dword [edi + 0x18]
cmp eax, ebx
mov dword [ebp + 8], eax
jne 0x10059b6
xor eax, eax
cmp dword [ebp + 0xc], ebx
setne al
add eax, 4
push eax
call fcn.0100386e
push 0x57
pop eax
jmp 0x1005e3d
push esi
lea eax, [ebp - 4]
push eax
push ebx
push ebx
push edi
call fcn.0100440e
mov esi, eax
cmp esi, ebx
jne 0x1005e00
push 0xc
push edi
call fcn.01003cfb
test al, al
je 0x10059f2
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 4]
push 0xc
push edi
call fcn.01004483
mov esi, eax
cmp esi, ebx
jne 0x1005e00
push 0xa
push edi
call fcn.01003cfb
test al, al
je 0x1005a6b
lea eax, [ebp - 0x3c]
push eax
push dword [ebp + 8]
push 0xa
push edi
call fcn.01004483
mov esi, eax
cmp esi, ebx
jne 0x1005e00
cmp dword [0x1012ca8], ebx
je 0x1005a2e
push dword [ebp + 8]
push 0x2ee4
call fcn.0100371a
pop ecx
pop ecx
push 1
push dword [ebp - 0x38]
push dword [ebp - 0x3c]
push dword [ebp + 8]
call fcn.0100d0d6
mov esi, eax
cmp esi, ebx
je 0x1005a64
cmp dword [0x1012ca8], ebx
je 0x1005e00
push dword [ebp + 8]
push 0x2eee
call fcn.0100371a
pop ecx
pop ecx
jmp 0x1005e00
mov dword [ebp - 0x18], 1
cmp dword [ebp + 0xc], ebx
je 0x1005b18
lea eax, [ebp - 8]
push eax
push 1
push dword [ebp + 8]
push ebx
call fcn.0100440e
mov esi, eax
cmp esi, 0x57
jne 0x1005aad
cmp dword [0x1012ca8], ebx
je 0x1005aa5
push dword [ebp - 4]
push dword [ebp + 8]
push 0x2f0e
call fcn.0100371a
add esp, 0xc
mov dword [ebp - 8], ebx
mov dword [ebp + 0xc], ebx
jmp 0x1005b18
cmp esi, ebx
je 0x1005ac8
cmp dword [0x1012ca8], ebx
je 0x1005dd4
push esi
call fcn.010037c9
jmp 0x1005dd4
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
jne 0x1005af3
push dword [ebp - 4]
push 0x1fa5
call fcn.0100371a
pop ecx
pop ecx
mov esi, 0x2018
jmp 0x1005dd4
push 0x18
push edi
call fcn.01003cfb
test al, al
je 0x1005b18
lea eax, [ebp - 0x4c]
push eax
push dword [ebp - 8]
push 0x18
push edi
call fcn.01004483
mov esi, eax
cmp esi, ebx
jne 0x1005dd4
push 0x14
push edi
call fcn.01003f89
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x14]
push eax
push 0xf
push edi
call fcn.01003f2b
mov esi, eax
cmp esi, ebx
jne 0x1005dd4
cmp dword [ebp + 0xc], ebx
push 3
pop esi
je 0x1005b44
push 0x23
pop esi
cmp dword [0x1012ca8], ebx
je 0x1005b5b
push dword [ebp - 4]
push 0x2eed
call fcn.0100371a
pop ecx
pop ecx
push esi
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
push dword [ebp - 4]
push dword [ebp + 8]
call sub.NETAPI32.dll_NetJoinDomain
mov esi, eax
cmp esi, 0x6d1
jne 0x1005c64
cmp dword [0x1012ca8], ebx
mov dword [ebp - 0xc], ebx
je 0x1005b98
push dword [ebp - 4]
push 0x2ee1
call fcn.0100371a
pop ecx
pop ecx
lea eax, [ebp - 0xc]
push eax
push 0x1020
push ebx
push ebx
push dword [ebp - 4]
push ebx
call dword [sym.imp.NETAPI32.dll_DsGetDcNameW]
mov esi, eax
cmp esi, ebx
jne 0x1005c57
cmp dword [0x1012ca8], ebx
je 0x1005bd0
mov eax, dword [ebp - 0xc]
push dword [eax]
push 0x2ee4
call fcn.0100371a
pop ecx
pop ecx
mov eax, dword [ebp - 0xc]
push 1
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [eax]
call fcn.0100d0d6
mov esi, eax
cmp esi, ebx
jne 0x1005c30
push dword [ebp + 0xc]
mov eax, dword [ebp - 0xc]
push dword [eax + 0x24]
push dword [eax]
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp + 8]
call fcn.010056ee
cmp dword [0x1012ca8], ebx
mov esi, eax
je 0x1005c1c
mov eax, dword [ebp - 0xc]
push dword [eax]
push 0x2ee5
call fcn.0100371a
pop ecx
pop ecx
mov eax, dword [ebp - 0xc]
push 2
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [eax]
call fcn.0100d0d6
jmp 0x1005c57
cmp dword [0x1012ca8], ebx
je 0x1005c57
mov eax, dword [ebp - 0xc]
push dword [eax]
push 0x2eee
call fcn.0100371a
cmp dword [0x1012ca8], ebx
pop ecx
pop ecx
je 0x1005c57
push esi
call fcn.010037c9
push dword [ebp - 0xc]
call sub.NETAPI32.dll_NetApiBufferFree
jmp 0x1005dbe
cmp esi, ebx
je 0x1005c86
cmp dword [0x1012ca8], ebx
je 0x1005dd4
push esi
push 0x2f11
call fcn.0100371a
pop ecx
pop ecx
jmp 0x1005dd4
cmp dword [ebp + 0xc], ebx
je 0x1005db9
cmp dword [ebp - 8], ebx
je 0x1005db9
cmp dword [0x1012ca8], ebx
mov dword [ebp + 0xc], ebx
je 0x1005cb2
push dword [ebp - 8]
push 0x2f0f
call fcn.0100371a
pop ecx
pop ecx
lea eax, [ebp + 0xc]
push eax
push 0x1000
push ebx
push ebx
push dword [ebp - 8]
push ebx
call dword [sym.imp.NETAPI32.dll_DsGetDcNameW]
mov esi, eax
cmp esi, ebx
jne 0x1005db9
cmp dword [0x1012ca8], ebx
je 0x1005cea
mov eax, dword [ebp + 0xc]
push dword [eax]
push 0x2ee4
call fcn.0100371a
pop ecx
pop ecx
mov eax, dword [ebp + 0xc]
push 1
push dword [ebp - 0x48]
push dword [ebp - 0x4c]
push dword [eax]
call fcn.0100d0d6
mov esi, eax
cmp esi, ebx
jne 0x1005db1
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
lea eax, [eax + eax + 4]
push eax
call sub.NETAPI32.dll_NetApiBufferAllocate
mov esi, eax
cmp esi, ebx
jne 0x1005d86
push dword [ebp + 8]
push dword [ebp - 0xc]
call dword [sym.imp.msvcrt.dll_wcscpy]
push 0x1001490
push dword [ebp - 0xc]
call dword [sym.imp.msvcrt.dll_wcscat]
add esp, 0x10
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp + 0xc]
push 1
push dword [ebp - 0xc]
push dword [eax]
call sub.NETAPI32.dll_NetUserGetInfo
mov esi, eax
cmp esi, ebx
jne 0x1005d7e
mov eax, dword [ebp - 0x10]
or dword [eax + 0x18], 2
mov eax, dword [ebp + 0xc]
push ebx
push dword [ebp - 0x10]
push 1
push dword [ebp - 0xc]
push dword [eax]
call sub.NETAPI32.dll_NetUserSetInfo
push dword [ebp - 0x10]
mov esi, eax
call sub.NETAPI32.dll_NetApiBufferFree
push dword [ebp - 0xc]
call sub.NETAPI32.dll_NetApiBufferFree
cmp dword [0x1012ca8], ebx
je 0x1005d9f
mov eax, dword [ebp + 0xc]
push dword [eax]
push 0x2ee5
call fcn.0100371a
pop ecx
pop ecx
mov eax, dword [ebp + 0xc]
push 2
push dword [ebp - 0x48]
push dword [ebp - 0x4c]
push dword [eax]
call fcn.0100d0d6
push dword [ebp + 0xc]
call sub.NETAPI32.dll_NetApiBufferFree
cmp dword [ebp - 0x1c], ebx
je 0x1005dd4
cmp esi, ebx
jne 0x1005dd4
push 0x1f58
push ebx
push dword [ebp - 0x3c]
push dword [ebp + 8]
push edi
call fcn.0100475f
cmp dword [ebp - 0x18], ebx
je 0x1005e00
cmp dword [0x1012ca8], ebx
je 0x1005df0
push dword [ebp + 8]
push 0x2ee5
call fcn.0100371a
pop ecx
pop ecx
push 2
push dword [ebp - 0x38]
push dword [ebp - 0x3c]
push dword [ebp + 8]
call fcn.0100d0d6
push dword [ebp - 4]
call sub.NETAPI32.dll_NetApiBufferFree
lea eax, [ebp - 0x2c]
push eax
call fcn.01004377
lea eax, [ebp - 0x4c]
push eax
call fcn.01004377
lea eax, [ebp - 0x3c]
push eax
call fcn.01004377
cmp dword [ebp - 8], ebx
je 0x1005e30
push dword [ebp - 8]
call sub.NETAPI32.dll_NetApiBufferFree
cmp esi, ebx
je 0x1005e3a
push esi
call fcn.010037c9
mov eax, esi
pop esi
pop edi
pop ebx
leave
ret 8