Function at 0x4049f8
Capabilities:
Read file on windows
Write file on windows

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0x58
mov esi, ecx
call fcn.00405e70
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 0
mov word [ebp - 0x26], 0
mov word [ebp - 0x28], 0
mov word [ebp - 0x3a], 0
mov word [ebp - 0x2a], 0
mov word [ebp - 0x2c], 0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x34], 0
call fcn.004028dc
mov dword [esp], 0x10
call fcn.00402fab
mov dword [0x40a044], eax
mov dword [esp], 0x10
call fcn.00402fab
mov dword [0x40a048], eax
mov dword [esp], 0x2000
call fcn.00402fab
mov dword [0x40a148], eax
mov dword [esp], 0x2000
call fcn.00402fab
mov dword [0x40a140], eax
mov dword [esp], 0x104
call fcn.00402fab
mov dword [0x40a14c], eax
mov dword [esp], 0x104
call fcn.00402fab
mov dword [0x40a154], eax
mov dword [esp], 0x4a
call fcn.00402fab
mov dword [0x40a054], eax
mov dword [esp], 1
call sub.msvcrt.dll_malloc
mov dword [0x40a150], eax
mov eax, dword [0x40a150]
mov byte [eax], 1
call sub.msvcrt.dll__errno
mov dword [eax], 0
mov dword [0x407020], 4
jmp 0x404b0b
nop
jmp 0x404b0b
nop
cmp dword [esi], 1
jne 0x404fb7
mov eax, dword [esi + 4]
mov ebx, dword [eax]
mov dword [esp], 0x200
call fcn.00402fab
mov dword [esi + 4], eax
mov eax, dword [esi + 4]
mov dword [eax], ebx
mov dword [esp], 0x2000
call fcn.00402fab
mov ebx, eax
mov eax, dword [esi + 4]
add eax, 4
mov dword [eax], ebx
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0xa
mov dword [esp + 4], 1
mov dword [esp], str.Cmd_line:
call sub.msvcrt.dll_fwrite
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp + 8], 0x2000
mov dword [esp + 4], ebx
mov dword [esp], 0
call sub.msvcrt.dll__read
mov dword [0x40a030], eax
mov eax, dword [0x40a030]
test eax, eax
jne 0x404bad
mov dword [esp], str.wrong
call fcn.00402e92
mov eax, dword [0x40a030]
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.00403005
mov edi, eax
test edi, edi
je 0x404bd7
mov edx, dword [0x40a030]
mov eax, edi
mov ecx, edx
sub ecx, eax
mov eax, ecx
mov dword [0x40a030], eax
mov eax, dword [0x40a030]
test eax, eax
je 0x404c00
mov edx, dword [0x40a030]
mov eax, edi
lea ecx, [ebx + eax]
mov eax, dword [0x40a148]
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
mov dword [esp], eax
call sub.msvcrt.dll_memcpy
mov eax, dword [esi + 4]
add eax, 4
mov eax, dword [eax]
mov dword [esp + 4], 0xa
mov dword [esp], eax
call sub.msvcrt.dll_strchr
mov ebx, eax
test ebx, ebx
je 0x404c21
mov byte [ebx], 0
mov eax, dword [esi + 4]
add eax, 4
mov eax, dword [eax]
mov dword [esp + 4], 0xd
mov dword [esp], eax
call sub.msvcrt.dll_strchr
mov ebx, eax
test ebx, ebx
je 0x404c42
mov byte [ebx], 0
mov eax, dword [esi + 4]
add eax, 4
mov ebx, dword [eax]
add ebx, 1
mov edi, 2
jmp 0x404c7a
movzx eax, byte [ebx]
cmp al, 0x20
jne 0x404c60
mov byte [ebx], 0
jmp 0x404c77
lea eax, [ebx - 1]
movzx eax, byte [eax]
test al, al
jne 0x404c77
mov eax, edi
shl eax, 2
add eax, dword [esi + 4]
mov dword [eax], ebx
add edi, 1
add ebx, 1
movzx eax, byte [ebx]
test al, al
jne 0x404c54
mov dword [esi], edi
jmp 0x404fb7
lea eax, [edi - 0x47]
cmp eax, 0x33
ja case.0x404c9b.72
mov eax, dword [eax*4 + 0x408af8]
jmp eax
mov dword [esp], str.all_A_records_NIY
call fcn.00402e92
movzx eax, word [0x40a05c]
add eax, 1
mov word [0x40a05c], ax
jmp 0x404fb7
mov eax, dword [0x40a008]
mov dword [0x40a078], eax
jmp 0x404fb7
movzx eax, word [0x40a064]
add eax, 1
mov word [0x40a064], ax
mov dword [ebp - 0x34], 1
jmp 0x404fb7
call sub.KERNEL32.dll_FreeConsole
jmp 0x404fb7
mov eax, dword [0x40a008]
mov dword [esp], eax
call sub.msvcrt.dll_atoi
mov edi, eax
test edi, edi
je 0x404d1a
mov eax, edi
and eax, 0x1c
cmp eax, edi
jne 0x404d1a
mov dword [0x407020], edi
jmp 0x404fb7
mov dword [esp + 4], edi
mov dword [esp], str.invalid_hop_pointer__d__must_be_multiple_of_4___28
call fcn.00402e92
jmp 0x404fb7
mov eax, dword [0x40a02c]
cmp eax, 8
jle 0x404d45
mov dword [esp], str.too_many__g_hops
call fcn.00402e92
mov eax, dword [0x40a04c]
test eax, eax
jne 0x404d5f
mov dword [esp], 0x28
call fcn.00402fab
mov dword [0x40a04c], eax
movzx eax, word [0x40a066]
movzx edx, ax
mov eax, dword [0x40a008]
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.004030aa
mov dword [ebp - 0x40], eax
cmp dword [ebp - 0x40], 0
je 0x404d99
mov eax, dword [0x40a04c]
mov edx, dword [0x40a02c]
shl edx, 2
lea edx, [eax + edx]
mov eax, dword [ebp - 0x40]
mov dword [edx], eax
mov eax, dword [0x40a02c]
add eax, 1
mov dword [0x40a02c], eax
jmp 0x404fb7
call sub.msvcrt.dll__errno
mov dword [eax], 0
call 0x4055f1
mov eax, dword [0x40a008]
mov dword [esp], eax
call sub.msvcrt.dll_atoi
and eax, 0xffff
mov dword [0x40a060], eax
mov eax, dword [0x40a060]
imul eax, eax, 0x3e8
mov dword [0x40a060], eax
mov eax, dword [0x40a060]
test eax, eax
jne 0x404fb3
mov eax, dword [0x40a008]
mov dword [esp + 4], eax
mov dword [esp], str.invalid_interval_time__s
call fcn.00402e92
jmp 0x404fb7
movzx eax, word [0x40a064]
add eax, 1
mov word [0x40a064], ax
jmp 0x404fb7
movzx eax, word [0x40a066]
add eax, 1
mov word [0x40a066], ax
jmp 0x404fb7
mov eax, dword [0x40a008]
mov dword [0x40a058], eax
movzx eax, word [0x40a068]
add eax, 1
mov word [0x40a068], ax
jmp 0x404fb7
mov eax, dword [0x40a008]
mov dword [esp + 4], 0
mov dword [esp], eax
call fcn.004033ee
mov word [ebp - 0x26], ax
cmp word [ebp - 0x26], 0
jne 0x404fb6
mov eax, dword [0x40a008]
mov dword [esp + 4], eax
mov dword [esp], str.invalid_local_port__s
call fcn.00402e92
jmp 0x404fb7
movzx eax, word [0x40a06a]
add eax, 1
mov word [0x40a06a], ax
jmp 0x404fb7
movzx eax, word [0x40a066]
movzx edx, ax
mov eax, dword [0x40a008]
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.004030aa
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x38]
add eax, 0x1c0
mov dword [ebp - 0x20], eax
jmp 0x404fb7
movzx eax, word [0x40a07c]
add eax, 1
mov word [0x40a07c], ax
jmp 0x404fb7
movzx eax, word [0x40a076]
add eax, 1
mov word [0x40a076], ax
jmp 0x404fb7
movzx eax, word [0x40a06c]
add eax, 1
mov word [0x40a06c], ax
jmp 0x404fb7
movzx eax, word [0x40a06e]
add eax, 1
mov word [0x40a06e], ax
jmp 0x404fb7
mov eax, dword [0x40a008]
mov dword [esp], eax
call sub.msvcrt.dll_atoi
mov dword [0x40a070], eax
mov eax, dword [0x40a070]
test eax, eax
jne 0x404f57
mov eax, dword [0x40a008]
mov dword [esp + 4], eax
mov dword [esp], str.invalid_wait_time__s
call fcn.00402e92
mov dword [esp], 8
call fcn.00402fab
mov dword [0x40a03c], eax
mov dword [esp], 8
call fcn.00402fab
mov dword [0x40a040], eax
mov eax, dword [0x40a03c]
mov edx, dword [0x40a070]
mov dword [eax], edx
jmp 0x404fb7
movzx eax, word [0x40a074]
add eax, 1
mov word [0x40a074], ax
jmp 0x404fb7
call sub.msvcrt.dll__errno
mov dword [eax], 0
mov dword [esp], str.nc__h_for_help
call fcn.00402e92
jmp 0x404fb7
nop
jmp 0x404fb7
nop
mov dword [esp + 8], str.ade:g:G:hi:lLno:p:rs:tcuvw:z
mov eax, dword [esi + 4]
mov dword [esp + 4], eax
mov eax, dword [esi]
mov dword [esp], eax
call fcn.00401e48
mov edi, eax
cmp edi, 0xffffffff
jne 0x404c88
movzx eax, word [0x40a06a]
test ax, ax
je 0x40500a
mov dword [esp], 0
call sub.msvcrt.dll_time
mov dword [esp], eax
call sub.msvcrt.dll_srand
mov dword [esp], 0x10000
call fcn.00402fab
mov dword [ebp - 0x30], eax
mov eax, dword [0x40a078]
test eax, eax
je 0x405032
mov dword [esp], 0
call sub.msvcrt.dll__close
mov word [0x40a068], 0
mov dword [0x40a028], 0
movzx eax, word [0x40a068]
test ax, ax
je 0x40508f
mov eax, dword [0x40a058]
mov dword [esp + 8], 0x1b4
mov dword [esp + 4], 0x301
mov dword [esp], eax
call sub.msvcrt.dll__open
mov dword [0x40a028], eax
mov eax, dword [0x40a028]
test eax, eax
jg 0x40507e
mov eax, dword [0x40a058]
mov dword [esp + 4], eax
mov dword [esp], str.cant_open__s
call fcn.00402e92
mov dword [esp], 0x64
call fcn.00402fab
mov dword [0x40a058], eax
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
test eax, eax
je 0x4050c6
movzx eax, word [0x40a066]
movzx edx, ax
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.004030aa
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
je 0x4050e3
mov eax, dword [ebp - 0x1c]
add eax, 0x1c0
test eax, eax
je 0x4050e3
mov eax, dword [ebp - 0x1c]
add eax, 0x1c0
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
je 0x4050f6
mov eax, dword [0x40a00c]
add eax, 1
mov dword [0x40a00c], eax
call sub.msvcrt.dll__errno
mov dword [eax], 0
movzx eax, word [0x40a064]
test ax, ax
je 0x405215
mov word [ebp - 0x2c], 0
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
test eax, eax
je 0x40516d
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], 0
mov dword [esp], eax
call fcn.004033ee
mov word [ebp - 0x2c], ax
cmp word [ebp - 0x2c], 0
jne 0x40516d
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], eax
mov dword [esp], str.invalid_port__s
call fcn.00402e92
movzx edx, word [ebp - 0x26]
movzx eax, word [ebp - 0x2c]
mov dword [esp + 0xc], edx
mov edx, dword [ebp - 0x20]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call fcn.00403a39
mov dword [0x407008], eax
mov eax, dword [0x407008]
test eax, eax
jle 0x405209
mov eax, dword [0x40a078]
test eax, eax
je 0x4051b3
mov eax, dword [0x407008]
mov dword [esp], eax
call fcn.004020f2
mov eax, dword [0x40a078]
test eax, eax
jne 0x4051cb
mov eax, dword [0x407008]
mov dword [esp], eax
call fcn.004042f1
mov edi, eax
movzx eax, word [0x40a06e]
cmp ax, 1
jbe 0x4051f7
mov edx, dword [0x40a034]
mov eax, dword [0x40a038]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str._sent__d__rcvd__d
call fcn.00402ddc
cmp dword [ebp - 0x34], 1
je 0x404b07
mov dword [esp], edi
call sub.msvcrt.dll_exit
mov dword [esp], str.no_connection
call fcn.00402e92
cmp dword [ebp - 0x24], 0
jne 0x405227
mov dword [esp], str.no_destination
call fcn.00402e92
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
test eax, eax
jne 0x405244
mov dword [esp], str.no_port_s__to_connect_to
call fcn.00402e92
mov eax, dword [0x40a00c]
add eax, 1
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
test eax, eax
je 0x405261
mov word [0x407024], 0
movzx eax, word [ebp - 0x26]
mov word [ebp - 0x28], ax
jmp 0x405576
mov word [ebp - 0x3a], 0
movzx eax, word [ebp - 0x3a]
mov word [ebp - 0x2a], ax
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], 0x2d
mov dword [esp], eax
call sub.msvcrt.dll_strchr
mov ebx, eax
test ebx, ebx
je 0x4052d0
mov byte [ebx], 0
add ebx, 1
mov dword [esp + 4], 0
mov dword [esp], ebx
call fcn.004033ee
mov word [ebp - 0x2a], ax
cmp word [ebp - 0x2a], 0
jne 0x4052d0
mov dword [esp + 4], ebx
mov dword [esp], str.invalid_port__s
call fcn.00402e92
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], 0
mov dword [esp], eax
call fcn.004033ee
mov word [ebp - 0x3a], ax
cmp word [ebp - 0x3a], 0
jne 0x405315
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
mov dword [esp + 4], eax
mov dword [esp], str.invalid_port__s
call fcn.00402e92
movzx eax, word [ebp - 0x2a]
cmp ax, word [ebp - 0x3a]
jbe 0x40536f
mov word [0x407024], 0
movzx eax, word [ebp - 0x2a]
mov word [ebp - 0x2c], ax
movzx eax, word [0x40a06a]
test ax, ax
je 0x40555b
movzx edx, word [ebp - 0x2a]
movzx eax, word [ebp - 0x3a]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x30]
mov dword [esp], eax
call fcn.00403655
mov eax, dword [ebp - 0x30]
mov dword [esp], eax
call fcn.004035e2
mov word [ebp - 0x2c], ax
jmp 0x40555b
movzx eax, word [ebp - 0x3a]
mov word [ebp - 0x2c], ax
jmp 0x40555b
cmp word [ebp - 0x26], 0
jne 0x4053a6
movzx eax, word [0x40a06a]
test ax, ax
je 0x4053a6
call sub.msvcrt.dll_rand
mov word [ebp - 0x28], ax
cmp word [ebp - 0x28], 0x1fff
ja 0x4053a6
add word [ebp - 0x28], 0x2000
movzx eax, word [ebp - 0x2c]
mov dword [esp + 4], eax
mov dword [esp], 0
call fcn.004033ee
mov word [ebp - 0x2c], ax
movzx edx, word [ebp - 0x28]
movzx eax, word [ebp - 0x2c]
mov dword [esp + 0xc], edx
mov edx, dword [ebp - 0x20]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call fcn.004036ca
mov dword [0x407008], eax
mov eax, dword [0x407008]
test eax, eax
jle 0x40541f
movzx eax, word [0x40a074]
test ax, ax
je 0x40541f
movzx eax, word [0x40a06c]
test ax, ax
je 0x40541f
mov eax, dword [0x407008]
mov edx, dword [ebp - 0x24]
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.00403f2d
mov dword [0x407008], eax
mov eax, dword [0x407008]
test eax, eax
jle 0x40549d
mov edi, 0
mov eax, dword [0x40a054]
mov ebx, eax
movzx ecx, word [ebp - 0x2c]
mov eax, dword [ebp - 0x1c]
add eax, 0x100
mov edx, eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str._s___s___d___s__open
call fcn.00402ddc
mov eax, dword [0x40a078]
test eax, eax
je 0x405477
mov eax, dword [0x407008]
mov dword [esp], eax
call fcn.004020f2
movzx eax, word [0x40a074]
test ax, ax
jne 0x4054fb
mov eax, dword [0x40a078]
test eax, eax
jne 0x4054fb
mov eax, dword [0x407008]
mov dword [esp], eax
call fcn.004042f1
mov edi, eax
jmp 0x4054fb
mov edi, 1
movzx eax, word [0x407024]
test ax, ax
jne 0x4054c7
movzx eax, word [0x40a06e]
cmp ax, 1
ja 0x4054c7
call sub.WSOCK32.DLL_WSAGetLastError
cmp eax, 0x274d
je 0x4054fb
mov eax, dword [0x40a054]
mov ebx, eax
movzx ecx, word [ebp - 0x2c]
mov eax, dword [ebp - 0x1c]
add eax, 0x100
mov edx, eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str._s___s___d___s_
call fcn.00402ddc
mov eax, dword [0x407008]
mov dword [esp + 4], 2
mov dword [esp], eax
call sub.WSOCK32.DLL_shutdown
sub esp, 8
mov eax, dword [0x407008]
mov dword [esp], eax
call sub.WSOCK32.DLL_closesocket
sub esp, 4
mov eax, dword [0x40a060]
test eax, eax
je 0x405539
mov eax, dword [0x40a060]
mov dword [esp], eax
call sub.msvcrt.dll__sleep
movzx eax, word [0x40a06a]
test ax, ax
je 0x405556
mov eax, dword [ebp - 0x30]
mov dword [esp], eax
call fcn.004035e2
mov word [ebp - 0x2c], ax
jmp 0x40555b
sub word [ebp - 0x2c], 1
movzx eax, word [ebp - 0x3a]
cmp ax, word [ebp - 0x2c]
jbe 0x40537c
mov eax, dword [0x40a00c]
add eax, 1
mov dword [0x40a00c], eax
mov eax, dword [0x40a00c]
shl eax, 2
add eax, dword [esi + 4]
mov eax, dword [eax]
test eax, eax
jne 0x40526e
call sub.msvcrt.dll__errno
mov dword [eax], 0
movzx eax, word [0x40a06e]
cmp ax, 1
jbe 0x4055c2
mov edx, dword [0x40a034]
mov eax, dword [0x40a038]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str.sent__d__rcvd__d
call fcn.00402ddc
call sub.WSOCK32.DLL_WSACleanup
cmp dword [ebp - 0x34], 1
je 0x404b0a
movzx eax, word [0x407024]
test ax, ax
je 0x4055e5
mov dword [esp], edi
call sub.msvcrt.dll_exit
mov dword [esp], 0
call sub.msvcrt.dll_exit
push ebp
mov ebp, esp
sub esp, 0x18
mov word [0x40a06e], 1
mov dword [esp], str._v1.12_NT_http:__eternallybored.org_misc_netcat___nconnect_to_somewhere:_tnc___options__hostname_port_s___ports__...__nlisten_for_inbound:_tnc__l__p_port__options___hostname___port__noptions:
call fcn.00402ddc
mov dword [esp], str._t_d_t_tdetach_from_console__background_mode_n
call fcn.00402ddc
mov dword [esp], str._t_e_prog_t_tinbound_program_to_exec__dangerous___
call fcn.00402ddc
mov dword [esp], str._t_g_gateway_tsource_routing_hop_point_s___up_to_8_n_t_G_num_t_tsource_routing_pointer:_4__8__12__..._n_t_h_t_tthis_cruft_n_t_i_secs_t_tdelay_interval_for_lines_sent__ports_scanned_n_t_l_t_tlisten_mode__for_inbound_connects_n_t_L_t_tlisten_harder__re_listen_on_socket_close_n_t_n_t_tnumeric_only_IP_addresses__no_DNS_n_t_o_file_t_thex_dump_of_traffic_n_t_p_port_t_tlocal_port_number_n_t_r_t_trandomize_local_and_remote_ports_n_t_s_addr_t_tlocal_source_address
call fcn.00402ddc
mov dword [esp], str._t_t_t_tanswer_TELNET_negotiation
call fcn.00402ddc
mov dword [esp], str._t_c_t_tsend_CRLF_instead_of_just_LF_n_t_u_t_tUDP_mode_n_t_v_t_tverbose__use_twice_to_be_more_verbose__n_t_w_secs_t_ttimeout_for_connects_and_final_net_reads_n_t_z_t_tzero_I_O_mode__used_for_scanning_
call fcn.00402ddc
mov dword [esp], str.port_numbers_can_be_individual_or_ranges:_m_n__inclusive_
call fcn.00402e92
mov eax, 0
leave
ret