Nmap Development mailing list archives

Upgrading NSE to Lua 5.3


From: Patrick Donnelly <batrick () batbytes com>
Date: Sat, 24 Jan 2015 21:47:08 -0500

Hi List,

I've just run through NSE upgrading it to Lua 5.3. The current branch is here:

https://svn.nmap.org/nmap-exp/patrick/nse-lua53@33937

Lua 5.3 has a number of attractive features including 64 bit integers,
native bitwise operators, builtin string.pack/string.unpack, a utf8
encoding library,

Here are two interesting changes in this branch for Lua 5.3:

o I have removed the old C compiled bit library (nse_bit.cc). It's
been replaced by a Lua library that wraps the new bitwise operators.
I've marked it as deprecated. So, existing scripts using the "bit"
library will continue to function.

o I've only marked the bin library as deprecated. There are some minor
differences between the old bin library and Lua's new
string.pack/unpack. A wrapper library may be difficult.

I don't consider the branch done yet, I will be looking over the code
in depth again to make sure I didn't miss anything.

I would appreciate any feedback (including: "it builds!").

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


Current thread: