Nmap Development mailing list archives
[NSE] SSL support
From: Patrik Karlsson <patrik () cqure net>
Date: Sun, 5 Aug 2012 10:43:22 +0200
All,
Given the recent bug report on a scripts failing when compiled without
openssl I did a few quick tests.
I recompiled without ssl support and ran --script-updatedb as I seem to
remember, based on previous experience, that this was a good test to find
problems.
I noticed/fixed a few things;
* A few libraries have "require openssl" before the silent_require call. I
may have contributed to this by doing my fix-up runs based on the result of
nse_check_globals. Patrick, would it be possible to get nse_check_globals
to understand the silent_require calls and even the
pcall(require("openssl"))?
* Some scripts requiring a library, which in turn had a silent_requires,
returned "attempt to yield across metamethod/C-call boundary" during the
--script-updatedb.
I solved this by adding a silent_require for that library in those scripts.
Not sure whether this is the best way, but I some some traces of that in a
few scripts and it works.
* nse_main.lua didn't seem to handle scripts having a silent_require very
well, as the scripts would fail to load, returning nil which wasn't caught
when attempting to sort the categories and write it to the scripts.db. I
think the attached patch may solve this appropriately as well.
* moved things around in the sasl library to be "protected" by the require
ssl pcall
I don't have access to a lot of test systems at the moment to validate
these patches, so help in this area would be appreciated.
I'm attaching the patch.
//Patrik
--
Patrik Karlsson
http://www.cqure.net
http://twitter.com/nevdull77
Attachment:
ssl-fixes.patch
Description:
_______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev Archived at http://seclists.org/nmap-dev/
Current thread:
- [NSE] SSL support Patrik Karlsson (Aug 05)
- Re: [NSE] SSL support Patrick Donnelly (Aug 05)
- Re: [NSE] SSL support Patrik Karlsson (Aug 05)
- Re: [NSE] SSL support Patrik Karlsson (Aug 05)
- Re: [NSE] SSL support Patrick Donnelly (Aug 05)
- Re: [NSE] SSL support Patrik Karlsson (Aug 05)
- Re: [NSE] SSL support Patrik Karlsson (Aug 05)
- Re: [NSE] SSL support Patrick Donnelly (Aug 05)
- Re: [NSE] SSL support Patrick Donnelly (Aug 05)
