Function at 0x10057702
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xb8
mov eax, dword [0x10098688]
xor eax, esp
mov dword [esp + 0xb4], eax
mov eax, dword [esp + 0xbc]
push ebx
push ebp
mov ebp, dword [esp + 0xc8]
push esi
mov eax, dword [ebp + eax*4 + 0x1a8]
mov dword [esp + 0x44], eax
xor eax, eax
push edi
mov edi, dword [ebp]
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov eax, dword [edi + 0x51c]
mov ebx, str.rcmd
test eax, eax
cmovne ebx, eax
mov esi, ebx
mov dword [esp + 0x58], ebx
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x10057759
push 0x2f
push ebx
sub esi, ecx
call fcn.1005fe10
pop ecx
pop ecx
test eax, eax
je 0x10057785
push ebx
call dword [0x1009834c]
mov ebx, eax
pop ecx
test ebx, ebx
jne 0x100577dd
push 0x1b
jmp 0x1005823d
mov ecx, dword [ebp + 0xc4]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1005778e
sub ecx, edx
lea eax, [ecx + 2]
add eax, esi
push eax
call dword [0x10098340]
mov ebx, eax
pop ecx
test ebx, ebx
je 0x1005777e
mov edx, dword [ebp + 0xc4]
mov ecx, edx
lea eax, [ecx + 1]
mov dword [esp + 0x5c], eax
mov al, byte [ecx]
inc ecx
test al, al
jne 0x100577b9
sub ecx, dword [esp + 0x5c]
push edx
push dword [esp + 0x5c]
lea eax, [esi + 2]
push str._s__s
add eax, ecx
push eax
push ebx
call fcn.1003edd6
add esp, 0x14
push 2
lea eax, [esp + 0x30]
mov dword [esp + 0x78], eax
xor ecx, ecx
xor edx, edx
lea eax, [esp + 0x1c]
mov dword [esp + 0x84], eax
inc edx
lea eax, [esp + 0xa4]
mov dword [esp + 0x6c], eax
mov dword [esp + 0x74], edx
mov dword [esp + 0x80], edx
pop edx
lea eax, [esp + 0x84]
push eax
lea eax, [esp + 0x44]
push eax
mov eax, dword [0x1009a3b4]
push ecx
push ecx
push ecx
push ecx
push edx
push str.Kerberos
push ecx
mov dword [esp + 0x90], ecx
mov dword [esp + 0x54], 2
mov dword [esp + 0x50], ecx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x9c], ecx
mov dword [esp + 0x40], edx
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x44], ecx
mov dword [esp + 0x88], 3
mov dword [esp + 0x84], ecx
mov dword [esp + 0x64], ecx
mov dword [esp + 0x68], ecx
call dword [eax + 0xc]
push str.AcquireCredentialsHandle
push eax
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
je 0x100578ac
push str.Failed_to_acquire_credentials.
push edi
call fcn.10034609
push ebx
call dword [0x10098344]
add esp, 0xc
lea eax, [esp + 0x40]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x10]
jmp 0x1005823b
mov eax, dword [esp + 0x54]
lea ecx, [esp + 0x84]
push ecx
lea ecx, [esp + 0x54]
push ecx
lea ecx, [esp + 0x80]
push ecx
lea ecx, [esp + 0x44]
push ecx
push 0
lea ecx, [esp + 0x80]
push ecx
push 0x10
push 0
push 0x116
push ebx
push eax
lea eax, [esp + 0x6c]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x18]
cmp dword [esp + 0x34], 0
mov esi, eax
mov dword [esp + 0x54], esi
je 0x10057910
push dword [esp + 0x34]
mov ecx, dword [0x1009a3b4]
call dword [ecx + 0x40]
and dword [esp + 0x34], 0
and dword [esp + 0x2c], 0
push str.InitializeSecurityContext
push esi
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
jne 0x100581f9
cmp dword [esp + 0x18], eax
je 0x100579f5
push dword [esp + 0x18]
inc eax
mov byte [esp + 0x14], al
mov byte [esp + 0x15], al
call dword [sym.imp.WS2_32.dll_htons]
mov esi, dword [esp + 0x48]
mov word [esp + 0x12], ax
lea eax, [esp + 0x24]
push eax
push 4
lea eax, [esp + 0x18]
push eax
push esi
push ebp
call fcn.10034b0f
add esp, 0x14
test eax, eax
jne 0x10057acd
cmp dword [esp + 0x24], 4
jne 0x10057acd
lea eax, [esp + 0x24]
push eax
push dword [esp + 0x1c]
push dword [esp + 0x28]
push esi
push ebp
call fcn.10034b0f
add esp, 0x14
test eax, eax
jne 0x1005799b
mov eax, dword [esp + 0x18]
cmp eax, dword [esp + 0x24]
je 0x100579f9
push str.Failed_to_send_SSPI_authentication_token.
push edi
call fcn.10034609
push ebx
call dword [0x10098344]
add esp, 0xc
cmp dword [esp + 0x20], 0
je 0x100579c3
mov eax, dword [0x1009a3b4]
push dword [esp + 0x20]
call dword [eax + 0x40]
cmp dword [esp + 0x34], 0
je 0x100579d6
push dword [esp + 0x34]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
lea eax, [esp + 0x40]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x10]
lea eax, [esp + 0x38]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x24]
jmp 0x1005823b
mov esi, dword [esp + 0x48]
cmp dword [esp + 0x20], 0
je 0x10057a11
push dword [esp + 0x20]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
and dword [esp + 0x20], 0
and dword [esp + 0x18], 0
cmp dword [esp + 0x34], 0
je 0x10057a2e
push dword [esp + 0x34]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
and dword [esp + 0x34], 0
and dword [esp + 0x2c], 0
cmp dword [esp + 0x54], 0x90312
jne 0x10057b7c
lea eax, [esp + 0x28]
push eax
push 4
lea eax, [esp + 0x18]
push eax
push esi
push ebp
call fcn.10051e97
add esp, 0x14
test eax, eax
jne 0x10057b62
cmp dword [esp + 0x28], 4
jne 0x10057b62
mov al, byte [esp + 0x11]
cmp al, 0xff
je 0x10057b3d
xor ecx, ecx
inc ecx
cmp al, cl
jne 0x10057b08
push dword [esp + 0x12]
call dword [sym.imp.WS2_32.dll_ntohs]
movzx esi, ax
push esi
mov dword [esp + 0x30], esi
call dword [0x10098340]
pop ecx
mov dword [esp + 0x34], eax
test eax, eax
je 0x10057b04
lea ecx, [esp + 0x28]
push ecx
push dword [esp + 0x30]
push eax
mov eax, dword [esp + 0x54]
push eax
push ebp
call fcn.10051e97
add esp, 0x14
test eax, eax
jne 0x10057ad7
cmp dword [esp + 0x28], esi
jne 0x10057ad7
lea eax, [esp + 0x38]
jmp 0x100578b0
push str.Failed_to_send_SSPI_authentication_request.
jmp 0x100579a0
push str.Failed_to_receive_SSPI_authentication_token.
push edi
call fcn.10034609
push ebx
call dword [0x10098344]
add esp, 0xc
cmp dword [esp + 0x34], 0
je 0x10057aff
push dword [esp + 0x34]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push 7
pop esi
jmp 0x10057b2b
push 0x1b
jmp 0x10057b22
movzx eax, al
push eax
movzx eax, byte [esp + 0x14]
push eax
push str.Invalid_SSPI_authentication_response_type___u__u_.
push edi
call fcn.10034609
add esp, 0x10
push 7
pop esi
push ebx
call dword [0x10098344]
pop ecx
lea eax, [esp + 0x40]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x10]
jmp 0x100581e7
movzx eax, byte [esp + 0x10]
push 0xff
push eax
push str.User_was_rejected_by_the_SOCKS5_server___u__u_.
push edi
call fcn.10034609
push ebx
call dword [0x10098344]
add esp, 0x14
jmp 0x100579d6
push str.Failed_to_receive_SSPI_authentication_response.
push edi
call fcn.10034609
push ebx
call dword [0x10098344]
add esp, 0xc
jmp 0x100579d6
push ebx
call dword [0x10098344]
pop ecx
lea eax, [esp + 0x4c]
push eax
xor eax, eax
inc eax
push eax
lea eax, [esp + 0x48]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 8]
mov ecx, dword [0x1009a3b4]
mov esi, eax
lea eax, [esp + 0x40]
push eax
call dword [ecx + 0x10]
push str.QueryCredentialAttributes
push esi
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
je 0x10057be0
lea eax, [esp + 0x38]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x24]
push dword [esp + 0x4c]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push str.Failed_to_determine_user_name.
jmp 0x10058233
push dword [esp + 0x4c]
push str.SOCKS5_server_authencticated_user__s_with_GSS_API._n
push edi
call fcn.100346c5
mov eax, dword [0x1009a3b4]
add esp, 0xc
push dword [esp + 0x4c]
call dword [eax + 0x40]
xor eax, eax
inc eax
test byte [esp + 0x50], 0x10
mov byte [esp + 0x10], al
mov byte [esp + 0x11], 2
je 0x10057c17
mov dl, 2
xor ebx, ebx
jmp 0x10057c28
test dword [esp + 0x50], 0x10000
push 0
pop ebx
movzx edx, bl
cmovne edx, eax
cmp dl, 1
mov eax, str.confidentiality
mov ecx, str.integrity
cmovne ecx, eax
test dl, dl
mov eax, 0x1008b800
cmovne eax, ecx
push eax
push str.SOCKS5_server_supports_GSS_API__s_data_protection._n
push edi
call fcn.100346c5
add esp, 0xc
cmp dword [edi + 0x548], ebx
je 0x10057c62
xor eax, eax
inc eax
push eax
jmp 0x10057eb0
lea eax, [esp + 0x90]
push eax
push ebx
lea eax, [esp + 0x40]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x2c]
push str.QueryContextAttributes
push eax
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
je 0x10057ca2
lea eax, [esp + 0x38]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x24]
push str.Failed_to_query_security_context_attributes.
jmp 0x10058233
mov eax, dword [esp + 0x9c]
push eax
mov dword [esp + 0xa4], eax
mov dword [esp + 0xa8], 2
call dword [0x10098340]
pop ecx
mov dword [esp + 0xa8], eax
test eax, eax
jne 0x10057cd5
push 0x1b
jmp 0x100581e6
xor eax, eax
inc eax
push eax
mov dword [esp + 0xb0], eax
call dword [0x10098340]
pop ecx
mov dword [esp + 0xb4], eax
test eax, eax
jne 0x10057d03
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
jmp 0x10057cce
mov byte [eax], bl
mov eax, dword [esp + 0x98]
push eax
mov dword [esp + 0xc0], 9
mov dword [esp + 0xbc], eax
call dword [0x10098340]
pop ecx
mov dword [esp + 0xc0], eax
test eax, eax
jne 0x10057d49
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xb4]
jmp 0x10057cf9
push ebx
lea eax, [esp + 0x64]
push eax
push reloc.WS2_32.dll_accept
lea eax, [esp + 0x44]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x64]
push str.EncryptMessage
push eax
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
je 0x10057da6
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xb4]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xc0]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
jmp 0x10057c8b
mov eax, dword [esp + 0xb8]
add eax, dword [esp + 0xac]
add eax, dword [esp + 0xa0]
push eax
mov dword [esp + 0x1c], eax
call dword [0x10098340]
pop ecx
mov dword [esp + 0x20], eax
test eax, eax
jne 0x10057df9
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xb4]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xc0]
jmp 0x10057cf9
push dword [esp + 0xa0]
push dword [esp + 0xac]
push eax
call fcn.1005e620
push dword [esp + 0xb8]
mov eax, dword [esp + 0xb0]
push dword [esp + 0xc4]
add eax, dword [esp + 0x34]
push eax
call fcn.1005e620
mov eax, dword [esp + 0xc4]
push dword [esp + 0xd0]
add eax, dword [esp + 0xbc]
push dword [esp + 0xdc]
add eax, dword [esp + 0x40]
push eax
call fcn.1005e620
mov eax, dword [0x1009a3b4]
add esp, 0x24
push dword [esp + 0xa8]
call dword [eax + 0x40]
push dword [esp + 0xb4]
mov eax, dword [0x1009a3b4]
mov dword [esp + 0xac], ebx
mov dword [esp + 0xa4], ebx
call dword [eax + 0x40]
push dword [esp + 0xc0]
mov eax, dword [0x1009a3b4]
mov dword [esp + 0xb8], ebx
mov dword [esp + 0xb0], ebx
call dword [eax + 0x40]
push dword [esp + 0x18]
mov dword [esp + 0xc4], ebx
mov dword [esp + 0xbc], ebx
call dword [sym.imp.WS2_32.dll_htons]
mov ebx, dword [esp + 0x48]
mov word [esp + 0x12], ax
lea eax, [esp + 0x24]
push eax
push 4
pop esi
push esi
lea eax, [esp + 0x18]
push eax
push ebx
push ebp
call fcn.10034b0f
add esp, 0x14
test eax, eax
jne 0x100581c4
cmp dword [esp + 0x24], esi
jne 0x100581c4
cmp dword [edi + 0x548], eax
je 0x10057f2a
mov byte [esp + 0x10], al
lea eax, [esp + 0x24]
push eax
xor eax, eax
inc eax
push eax
lea eax, [esp + 0x18]
push eax
push ebx
push ebp
call fcn.10034b0f
add esp, 0x14
test eax, eax
jne 0x10057f18
inc eax
cmp dword [esp + 0x24], eax
je 0x10057f6a
push str.Failed_to_send_SSPI_encryption_type.
push edi
call fcn.10034609
pop ecx
pop ecx
jmp 0x100581e4
lea eax, [esp + 0x24]
push eax
push dword [esp + 0x1c]
push dword [esp + 0x28]
push ebx
push ebp
call fcn.10034b0f
add esp, 0x14
test eax, eax
jne 0x100581bd
mov eax, dword [esp + 0x18]
cmp eax, dword [esp + 0x24]
jne 0x100581bd
cmp dword [esp + 0x20], 0
je 0x10057f6a
push dword [esp + 0x20]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
lea eax, [esp + 0x28]
push eax
push esi
lea eax, [esp + 0x18]
push eax
push ebx
push ebp
call fcn.10051e97
add esp, 0x14
test eax, eax
jne 0x100581b3
cmp dword [esp + 0x28], esi
jne 0x100581b3
mov al, byte [esp + 0x11]
cmp al, 0xff
jne 0x10057fb7
movzx eax, byte [esp + 0x10]
push 0xff
push eax
push str.User_was_rejected_by_the_SOCKS5_server___u__u_.
push edi
call fcn.10034609
add esp, 0x10
jmp 0x100581e4
cmp al, 2
je 0x10057fcc
movzx eax, al
push eax
movzx eax, byte [esp + 0x14]
push eax
push str.Invalid_SSPI_encryption_response_type___u__u_.
jmp 0x10057fa9
push dword [esp + 0x12]
call dword [sym.imp.WS2_32.dll_ntohs]
movzx esi, ax
push esi
mov dword [esp + 0xa4], esi
call dword [0x10098340]
pop ecx
mov dword [esp + 0xa8], eax
test eax, eax
je 0x10057cce
lea ecx, [esp + 0x28]
push ecx
push dword [esp + 0xa4]
push eax
push ebx
push ebp
call fcn.10051e97
add esp, 0x14
test eax, eax
jne 0x100581a4
cmp dword [esp + 0x28], esi
jne 0x100581a4
xor ebx, ebx
xor ecx, ecx
inc ebx
cmp dword [edi + 0x548], ecx
jne 0x10058130
lea eax, [esp + 0x8c]
push eax
push ecx
lea eax, [esp + 0x68]
push eax
lea eax, [esp + 0x44]
push eax
mov eax, dword [0x1009a3b4]
mov dword [esp + 0x74], 2
mov dword [esp + 0xb4], 0xa
mov dword [esp + 0xc0], ebx
mov dword [esp + 0xbc], ecx
mov dword [esp + 0xc4], ecx
call dword [eax + 0x68]
push str.DecryptMessage
push eax
push ebp
call fcn.10058257
add esp, 0xc
test eax, eax
je 0x100580ba
cmp dword [esp + 0xa8], 0
je 0x100580a0
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
cmp dword [esp + 0xb4], 0
je 0x10057c8b
push dword [esp + 0xb4]
jmp 0x10057d99
cmp dword [esp + 0xac], ebx
je 0x1005810b
push dword [esp + 0xac]
push str.Invalid_SSPI_encryption_response_length___lu_.
push edi
call fcn.10034609
add esp, 0xc
cmp dword [esp + 0xa8], 0
je 0x100580f1
push dword [esp + 0xa8]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
cmp dword [esp + 0xb4], 0
je 0x100581e4
push dword [esp + 0xb4]
jmp 0x100581dc
mov eax, dword [esp + 0xb4]
push dword [esp + 0xa8]
mov al, byte [eax]
mov byte [esp + 0x14], al
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push dword [esp + 0xb4]
jmp 0x10058168
cmp dword [esp + 0xa0], ebx
je 0x1005815a
push dword [esp + 0xa0]
push str.Invalid_SSPI_encryption_response_length___lu_.
push edi
call fcn.10034609
add esp, 0xc
push dword [esp + 0xa8]
jmp 0x100581dc
mov ecx, dword [esp + 0xa8]
push ecx
mov al, byte [ecx]
mov byte [esp + 0x14], al
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
mov al, byte [esp + 0x10]
test al, al
jne 0x1005817f
mov ecx, str.out_GSS_API_data
jmp 0x1005818e
mov ecx, str._GSS_API_integrity
mov edx, str._GSS_API_confidentiality
cmp al, bl
cmovne ecx, edx
push ecx
push str.SOCKS5_access_with_s_protection_granted._n
push edi
call fcn.100346c5
add esp, 0xc
xor eax, eax
jmp 0x1005823e
push str.Failed_to_receive_SSPI_encryption_type.
push edi
call fcn.10034609
pop ecx
pop ecx
jmp 0x1005814e
push str.Failed_to_receive_SSPI_encryption_response.
jmp 0x10057f1d
push str.Failed_to_send_SSPI_encryption_type.
jmp 0x100581c9
push str.Failed_to_send_SSPI_encryption_request.
push edi
call fcn.10034609
cmp dword [esp + 0x28], 0
pop ecx
pop ecx
je 0x100581e4
push dword [esp + 0x20]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push 7
pop esi
mov ecx, dword [0x1009a3b4]
lea eax, [esp + 0x38]
push eax
call dword [ecx + 0x24]
mov eax, esi
jmp 0x1005823e
push ebx
call dword [0x10098344]
pop ecx
lea eax, [esp + 0x40]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x10]
lea eax, [esp + 0x38]
push eax
mov eax, dword [0x1009a3b4]
call dword [eax + 0x24]
cmp dword [esp + 0x34], 0
je 0x1005822e
push dword [esp + 0x34]
mov eax, dword [0x1009a3b4]
call dword [eax + 0x40]
push str.Failed_to_initialise_security_context.
push edi
call fcn.10034609
pop ecx
pop ecx
push 7
pop eax
mov ecx, dword [esp + 0xc4]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.1005c9a6
add esp, 0xb8
ret