dmiller
cd6ddce888
Throw error on MSRPC unmarshall problems
nmap multiplatform autobuilds / build (arm64, gcc, ubuntu-latest-gcc-arm64, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, freebsd-15-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-15-clang, macos-15) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-26-clang, macos-26) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, netbsd-10-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, openbsd-7-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, solaris-11-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, ubuntu-latest-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (egcc, openbsd-7-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, freebsd-15-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, netbsd-10-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, solaris-11-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, ubuntu-latest-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (msvc, windows-latest-msvc, windows-latest) (push) Waiting to run
2026-09-14 17:42:08 +00:00
dmiller
b47e7f07ef
Change explicit X==true to X
nmap multiplatform autobuilds / build (arm64, gcc, ubuntu-latest-gcc-arm64, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, freebsd-15-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-15-clang, macos-15) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-26-clang, macos-26) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, netbsd-10-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, openbsd-7-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, solaris-11-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, ubuntu-latest-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (egcc, openbsd-7-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, freebsd-15-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, netbsd-10-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, solaris-11-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, ubuntu-latest-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (msvc, windows-latest-msvc, windows-latest) (push) Waiting to run
2026-07-08 00:42:18 +00:00
dmiller
ce2b1e6d39
Change explicit X==false to not X
nmap multiplatform autobuilds / build (arm64, gcc, ubuntu-latest-gcc-arm64, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, freebsd-15-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-15-clang, macos-15) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, macos-26-clang, macos-26) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, netbsd-10-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, openbsd-7-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, solaris-11-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (clang, ubuntu-latest-clang, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (egcc, openbsd-7-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, freebsd-15-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, netbsd-10-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, solaris-11-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (gcc, ubuntu-latest-gcc, ubuntu-latest) (push) Waiting to run
nmap multiplatform autobuilds / build (msvc, windows-latest-msvc, windows-latest) (push) Waiting to run
2026-07-07 14:50:05 +00:00
dmiller
7c29b558d1
Fix some nonstandard NSEdoc
2025-05-16 19:28:10 +00:00
nnposter
3bb6062ede
Use a more accurate variable name
2019-09-07 22:43:47 +00:00
nnposter
ef2825b3bc
Populate ID Authority with the correct value. See #1720
2019-09-01 03:53:04 +00:00
nnposter
729260e2d1
Account for a possibly nil argument
2019-09-01 03:09:49 +00:00
nnposter
e5c4f4886b
Make sure that argument pos is always defined. See #1720
2019-09-01 02:57:34 +00:00
dmiller
0500811f5a
Move string utility functions to stringaux.lua
2018-10-18 01:08:19 +00:00
dmiller
7819453af5
Fix some incorrect conversions from bin to string unpacking
2018-09-20 02:19:53 +00:00
dmiller
00ec940ead
Replace bin.lua packing in msrpc libraries
2018-09-19 21:43:44 +00:00
dmiller
d84ddbe3fd
Remove bit library from a few more libs
2018-08-28 03:52:55 +00:00
dmiller
14f439a29e
Use integer division for timestamps. Fixes #1255
2018-06-29 02:53:40 +00:00
rewanth
8e717e1694
Adds NSE script for smb-enum-services and its support functions. Closes #987 .
2017-09-05 18:19:11 +00:00
rewanth
62810c3dbf
Reverting back to older logic by removing offset param.
2017-09-02 15:33:28 +00:00
rewanth
a64d85c73d
Adds optional offset parameter to msrpctypes.lua
2017-09-01 20:17:07 +00:00
rewanth
005167d25b
Adds unmarshall_lptstr function to msrpctypes.lua. Closes #991 .
2017-09-01 04:45:43 +00:00
dmiller
edfc5e3835
Remove useless bin.pack('A') calls (equivalent to tostring)
2017-03-14 02:51:06 +00:00
dmiller
ea58c6bebb
Replace chained concatenation reassignment with simple concatenation
...
Example:
x = y
x = x .. z
Fixed:
x = y
.. z
This simple fix would save 1 string creation/deletion. Most changes
involve many more than this.
2015-03-02 13:47:42 +00:00
dmiller
4f0518bd93
Replace concat-loop padding with string.rep
2015-02-27 14:55:42 +00:00
dmiller
2692746c42
NSEdoc cleanup
...
Mostly splitting function summaries (the first paragraph of NSEdoc) from
the body of the description to make the summary indexes shorter and
easier to scan.
Also fixed some unbalanced code tags like <code>foo</table>
2014-09-02 18:23:06 +00:00
batrick
ee6622aea4
nselib stdnse.print_debug -> stdnse.debug
...
$ f() { find -name \*.lua -exec /bin/echo sed -i "$1" {} \; ; }
$ f 's/stdnse.print_debug( *\([0-9]*\) *, */stdnse.debug\1(/'
$ f 's/stdnse.print_debug( *"\(.*\))/stdnse.debug1("\1)/'
2014-08-03 00:56:45 +00:00
dmiller
17c3e9755e
NSEdoc cleanup.
...
1. The first paragraph of a function's NSEdoc is used as a short
summary. Some of these were very long, so I split off a shorter summary.
2. Use asterisks (*) to denote bulletted lists, not 'o'
3. Wrap lines at 80 columns
4. a couple other spelling and formatting fixes
2014-03-10 19:01:19 +00:00
dmiller
6e3980733e
Use unicode library for msrpc/smb
2014-02-19 22:14:16 +00:00
dmiller
1b71f75aad
Spelling fixes for Lua files
...
Mostly in documentation/comments, but a couple code bugs were caught,
including a call to stdnse.pirnt_debug and a mis-declared variable.
2014-02-19 04:15:46 +00:00
dmiller
a084340b6d
Remove useless calls to string.format
...
stdnse.print_debug accepts a format string and arguments, making
string.format redundant in calls of this form:
stdnse.print_debug(1, string.format("%s: error", SCRIPT_NAME))
stdnse.print_debug(("length %d"):format(#tab))
These can be rewritten as:
stdnse.print_debug(1, "%s: error", SCRIPT_NAME)
stdnse.print_debug("length %d", #tab)
2014-02-13 15:47:41 +00:00
dmiller
69e343f0aa
Reindent the last of the NSE libraries.
...
https://secwiki.org/w/Nmap/Code_Standards
2014-02-04 19:47:26 +00:00
dmiller
620f9fdb34
Remove trailing whitespace in lua files
...
Whitespace is not significant, so this should not be a problem.
https://secwiki.org/w/Nmap/Code_Standards
2014-01-23 21:51:58 +00:00
dmiller
771a6a0793
Fix more Lua patterns with '-', see r32566
2013-12-19 20:34:46 +00:00
batrick
000f6dc4d9
Lua 5.2 upgrade [1] for NSE.
...
[1] http://seclists.org/nmap-dev/2012/q2/34
2012-05-27 08:53:32 +00:00
batrick
4444071f03
use # length operator instead of string.len (canonicalize)
...
Used this perl command:
$ # perl -pi -e 's/string\.len\((.*?)\)/#\1/g' *.lua
Also fixed one instance where the above command didn't correctly
translate the intended code (string.len(a .. b .. c)).
2011-05-11 15:08:55 +00:00
david
7d0c08a097
Brief copyediting of NSEDoc for modules.
2010-07-12 19:42:43 +00:00
ron
08da8db7f0
Importing changes from my branch. There are two major updates:
...
1) I wrote a function that formats output from scripts in a consistent way. Although we haven't really come to a concensus on how it should look yet, it's easy to change when we do.
2) New script: smb-enum-groups.nse. Enumerate the local groups on a system and their membership.
2009-11-20 16:05:06 +00:00
ron
7d67b08e66
Merged in my changes from nmap-smb. The primary changes are:
...
* Updated the way authentication works on smb -- it's significantly cleaner now
* smb-enum-shares.nse gives significantly better output now (it checks if shares are writable)
* Added a script that checks if smbv2 is enabled on a server
* Added smb-psexec, a script for executing commands on a remote Windows server. I also included some default scripts, a compiled .exe to run everything, and a ton of documentation (in the form of NSEDoc)
* Added 'override' parameters to some of the functions in smb.lua, which lets the programmer override any field in an outgoing SMB packet without modifying smb.lua.
* Lots of random code cleanups in the smb-* scripts/libraries
2009-11-08 21:31:06 +00:00
jah
dcfa102a1b
Fix the indexing of Globals - found with the help of strict.lua and Patrick's
...
check_globals script.
Commented-out two functions which are currently unused:
svcctl_Type_tostr() and svcctl_State_tostr()
and which call currently unavailable functions:
svcctl_Type_str() and svcctl_State_str()
(see http://seclists.org/nmap-dev/2009/q3/0194.html )
2009-07-17 22:38:26 +00:00
ron
1b2392f73d
Fixed an undeclared variable bug in a currently-unused codepath.
2009-07-17 21:56:11 +00:00
batrick
90a712ae2b
Patch to libraries that were inappropriately using globals.
...
Often two (or more) scripts using the same library would
overwrite the globals each was using. This would result
in (at best) an error or (at worst) a deadlock.
The patch changes the global accesses to local.
2009-07-07 00:20:52 +00:00
ron
ab59b09c03
Miscellaneous code cleanups in my smb-* libraries/scripts (removed unused includes, old debug code, etc.)
2009-06-10 23:13:15 +00:00
ron
fa9a63bf0a
Another typo fix
2009-03-12 18:27:52 +00:00
ron
9c6860615f
Fixed a typo
2009-03-12 14:20:32 +00:00
ron
45744eddc3
Merge in changes from my private branch, primarily smb-brute.nse and smb-pwdump.nse, among other smaller changes.
2009-03-05 02:03:29 +00:00
david
9323b53c68
Fix NSEDoc in msrpctypes.lua. A <code> was unterminated, and bullet lists can't
...
have newlines within each entry.
2009-02-20 18:46:26 +00:00
david
1d6011edbe
Fix a couple of NSEDoc errors.
2009-01-13 15:30:05 +00:00
david
b504fb78fa
Fix some NSEDoc errors.
2009-01-13 00:18:46 +00:00
ron
773000b65a
Merging changes from my experimental branch; the new versions of this scripts, which have significant changes to their core functionality, managed to hold their own against Brandon's network. More testing would be very helpful, though, especially with credentials (most of Brandon's scans were anonymous).
2008-12-24 00:53:01 +00:00
ron
da4a8ef302
Fixed a bug where int8 arrays wouldn't align properly (I hadn't noticed it before because the only place it's used is in registry functions, and all following variables were either ignored or set to the proper value by luck
2008-12-07 19:10:17 +00:00
ron
ea42f39faa
Merged in significant changes to Microsoft RPC calls
2008-12-07 16:16:11 +00:00