Nmap Development mailing list archives

Re: nmap socket bind to the udp port


From: Patrik Karlsson <patrik () cqure net>
Date: Fri, 9 Mar 2012 18:24:36 +0100

On Fri, Mar 9, 2012 at 4:32 PM, idtjoe1 <josephriz () gmail com> wrote:


Hello,

Thank you for the response.

What we want to know is what our local port is, or we want to set that from
the script itself.

so socket.connect is for remote port

We will look at what socket:bind() tells us

By any chance do you have a link to the nmap luadoc?

You help is appreciated. Thanks.





SAI LAKSHMI Bhavana wrote:

In connect() call the port number we use is the port on the remote
host we want to connect to its not local port.

socket:bind()
can be used to bind the socket to the port of your choice.

some of the methods of socket object can be found in the nmap.luadoc
of nselib in the compiled code.
_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


--
View this message in context:
http://old.nabble.com/nmap-socket-bind-to-the-udp-port-tp33467447p33472547.html
Sent from the Nmap - Dev mailing list archive at Nabble.com.

_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


If you want to get information about what local port is used once the
socket is connected, check out get_info:
http://nmap.org/nsedoc/lib/nmap.html#get_info

//Patrik

-- 
Patrik Karlsson
http://www.cqure.net
http://twitter.com/nevdull77
_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


Current thread: