Nmap Development mailing list archives

Re: [NSE] Large recode for nse_main (test please)


From: jah <jah () zadkiel plus com>
Date: Sun, 08 Jun 2008 13:01:20 +0100

On 08/06/2008 05:31, Patrick Donnelly wrote:
On Sat, Jun 7, 2008 at 8:57 PM, jah <jah () zadkiel plus com> wrote:
  
On 03/06/2008 09:33, Patrick Donnelly wrote:
    
2) Each thread for a script has it's own action closure and environment
      
Hi Patrick,

Quick question.  Does 2) above mean that with the changes in your
branch, the only way to share variable values between threads of the
same script is using nmap.registry and not by declaring the variables
outside of action() (as is currently possible)?
This is certainly the behaviour I observe in your branch and I'm just
checking that this is expected.
    

Yes, please see: http://seclists.org/nmap-dev/2008/q2/0549.html

It is also technically possible to share results through the true
global environment (_G), but it is strongly recommended against.
  
Thanks for that.  With this in mind then, if I want to lock an object
other than "id" using nmap.mutex (allowing threads to run until they
reach a point where they need to use that object) then that object will
need to be one which is shared by all threads and thus available in
either nmap.registry or _G.  Is that correct?

Cheers,

jah

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


Current thread: