Home page logo
/

nmap-dev logo Nmap Development mailing list archives

Re: [NSE] Thread-safety questions
From: Patrick Donnelly <batrick () batbytes com>
Date: Wed, 31 Jul 2013 03:14:43 -0400

On Tue, Jul 30, 2013 at 8:27 PM,  <nnposter () users sourceforge net> wrote:
I would like to ask a few questions about thread safety in NSE:


1. Socket use across threads

Recently I ran into an issue of nmap failing to return from
socket:connect() so I posed a question to the mailing list about
whether sockets can be used across threads. Patrick Donnelly answered
that this is indeed prohibited. Could somebody please point out where
it is documented? (I do try to RTFM but I have somehow missed it and
I wonder if there are other similar constraints.)


2. Behavior of stdnse.new_thread()

Given the collaborative threading model, is a new thread created with
stdnse.new_thread() guaranteed not to start running until the parent
thread explicitly or implicitly yields (through yield(), sleep(),
socket I/Os, mutexes, etc.)? If the answer "Yes, always", could again
somebody please point out the relevant documentation? (Source code does
not count ;-)


Thank you in advance,
nnposter
_______________________________________________
Sent through the dev mailing list
http://nmap.org/mailman/listinfo/dev
Archived at http://seclists.org/nmap-dev/



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


  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]
AlienVault