Nmap http-domino-enum-passwords NSE Script


This page contains detailed information about how to use the http-domino-enum-passwords NSE script. For list of all NSE scripts, visit the Nmap NSE Library.

Select:
Overview
Error Messages

Script Overview


Script source code: https://github.com/nmap/nmap/tree/master/scripts/http-domino-enum-passwords.nse
Script categories: intrusive, auth
Target service / protocol: http, https
Target network port(s): 80, 443
List of CVEs: -

Script Description


The http-domino-enum-passwords.nse script attempts to enumerate the hashed Domino Internet Passwords that are (by default) accessible by all authenticated users. This script can also download any Domino ID Files attached to the Person document. Passwords are presented in a form suitable for running in John the Ripper.

The passwords may be stored in two forms (http://comments.gmane.org/gmane.comp.security.openwall.john.user/785):

  1. Saltless (legacy support?) Example: 355E98E7C7B59BD810ED845AD0FD2FC4 John's format name: lotus5
  2. Salted (also known as "More Secure Internet Password") Example: (GKjXibCW2Ml6juyQHUoP) John's format name: dominosec

It appears as if form based authentication is enabled, basic authentication still works. Therefore the script should work in both scenarios. Valid credentials can either be supplied directly using the parameters username and password or indirectly from results of http-brute or http-form-brute.

Http-domino-enum-passwords NSE Script Arguments


This is a full list of arguments supported by the http-domino-enum-passwords.nse script:

http-domino-enum-passwords.count

The number of internet hashes and id files to fetch. If a negative value is given, all hashes and id files are retrieved (default: 10)

http-domino-enum-passwords.hostname

Sets the host header in case of virtual hosting. Not needed if target is specified by name.

http-domino-enum-passwords.idpath

The path where downloaded ID files should be saved If not given, the script will only indicate if the ID file is donwloadable or not

http-domino-enum-passwords.password

Password for HTTP auth, if required

http-domino-enum-passwords.path

Points to the path protected by authentication. Default:"/names.nsf/People?OpenView"

http-domino-enum-passwords.username

Username for HTTP auth, if required

creds.global

Credentials to be returned by Credentials.getCredentials regardless of the service.

creds.[service]

Credentials to be returned by Credentials.getCredentials for [service]. E.g. creds.http=admin:password

smbdomain

The domain to log in with. If you aren't in a domain environment, then anything will (should?) be accepted by the server.

smbhash

A password hash to use when logging in. This is given as a single hex string (32 characters) or a pair of hex strings (both 32 characters, optionally separated by a single character). These hashes are the LanMan or NTLM hash of the user's password, and are stored on disk or in memory. They can be retrieved from memory using the fgdump or pwdump tools.

smbnoguest

Use to disable usage of the 'guest' account.

smbpassword

The password to connect with. Be cautious with this, since some servers will lock accounts if the incorrect password is given. Although it's rare that the Administrator account can be locked out, in the off chance that it can, you could get yourself in trouble. To use a blank password, leave this parameter off altogether.

smbtype

The type of SMB authentication to use. These are the possible options:

  • v1: Sends LMv1 and NTLMv1.
  • LMv1: Sends LMv1 only.
  • NTLMv1: Sends NTLMv1 only (default).
  • v2: Sends LMv2 and NTLMv2.
  • LMv2: Sends LMv2 only.
  • NTLMv2: Doesn't exist; the protocol doesn't support NTLMv2 alone. The default, NTLMv1, is a pretty decent compromise between security and compatibility. If you are paranoid, you might want to use v2 or lmv2 for this. (Actually, if you're paranoid, you should be avoiding this protocol altogether!). If you're using an extremely old system, you might need to set this to v1 or lm, which are less secure but more compatible. For information, see smbauth.lua.

smbusername

The SMB username to log in with. The forms "DOMAIN\username" and "username@DOMAIN" are not understood. To set a domain, use the smbdomain argument.

slaxml.debug

Debug level at which default callbacks will print detailed parsing info. Default: 3

http.host

The value to use in the Host header of all requests unless otherwise set. By default, the Host header uses the output of stdnse.get_hostname().

http.max-body-size

Limit the received body to specific number of bytes. An oversized body results in an error unless script argument http.truncated-ok or request option truncated_ok is set to true. The default is 2097152 (2MB). Use value -1 to disable the limit altogether. This argument can be overridden case-by-case with request option max_body_size.

http.max-cache-size

The maximum memory size (in bytes) of the cache.

http.max-pipeline

If set, it represents the number of outstanding HTTP requests that should be sent together in a single burst. Defaults to http.pipeline (if set), or to what function get_pipeline_limit returns.

http.pipeline

If set, it represents the number of HTTP requests that'll be sent on one connection. This can be set low to make debugging easier, or it can be set high to test how a server reacts (its chosen max is ignored).

http.truncated-ok

Do not treat oversized body as error. (Use response object flag truncated to check if the returned body has been truncated.) This argument can be overridden case-by-case with request option truncated_ok.

http.useragent

The value of the User-Agent header field sent with requests. By default it is "Mozilla/5.0 (compatible; Nmap Scripting Engine; https://nmap.org/book/nse.html)". A value of the empty string disables sending the User-Agent header field.

- - -
To use these script arguments, add them to the Nmap command line using the --script-args arg1=value,[arg2=value,..] syntax. For example:

nmap --script=http-domino-enum-passwords --script-args http-domino-enum-passwords.count=value,http-domino-enum-passwords.hostname=value <target>

Http-domino-enum-passwords NSE Script Example Usage


Here's an example of how to use the http-domino-enum-passwords.nse script:

nmap --script http-domino-enum-passwords -p 80 <host> --script-args http-domino-enum-passwords.username='patrik karlsson',http-domino-enum-passwords.password=secret

Http-domino-enum-passwords NSE Script Example Output


Here's a sample output from the http-domino-enum-passwords.nse script:

PORT     STATE SERVICE REASON
80/tcp   open  http    syn-ack
| http-domino-enum-passwords:
|   Information
|     Information retrieved as: "Jim Brass"
|   Internet hashes (salted, jtr: --format=DOMINOSEC)
|      Jim Brass:(GYvlbOz2idzni5peJUdD)
|      Warrick Brown:(GZghNctqAnJgyklUl2ml)
|      Gill Grissom:(GyhsteeXTr75YOSwW8mc)
|      David Hodges:(GZEJRHqJEVc5IZCsNX0U)
|      Ray Langston:(GE18MGVGD/8ftYMFaVlY)
|      Greg Sanders:(GHpdG/7FX7iXXlaoY5sj)
|      Sara Sidle:(GWzgG0kCQ5qmnqARL3cl)
|      Wendy Simms:(G6wooaElHpsvA4TPvSfi)
|      Nick Stokes:(Gdo2TJBRj1Ervrs9lPUp)
|      Catherine Willows:(GlDc3QP5ePFR38d7lQeM)
|   Internet hashes (unsalted, jtr: --format=lotus5)
|      Ada Lovelace:355E98E7C7B59BD810ED845AD0FD2FC4
|      John Smith:655E98E7C7B59BD810ED845AD0FD2FD4
|   ID Files
|      Jim Brass ID File has been downloaded (/tmp/id/Jim Brass.id)
|      Warrick Brown ID File has been downloaded (/tmp/id/Warrick Brown.id)
|      Gill Grissom ID File has been downloaded (/tmp/id/Gill Grissom.id)
|      David Hodges ID File has been downloaded (/tmp/id/David Hodges.id)
|      Ray Langston ID File has been downloaded (/tmp/id/Ray Langston.id)
|      Greg Sanders ID File has been downloaded (/tmp/id/Greg Sanders.id)
|      Sara Sidle ID File has been downloaded (/tmp/id/Sara Sidle.id)
|      Wendy Simms ID File has been downloaded (/tmp/id/Wendy Simms.id)
|      Nick Stokes ID File has been downloaded (/tmp/id/Nick Stokes.id)
|      Catherine Willows ID File has been downloaded (/tmp/id/Catherine Willows.id)
|
|_  Results limited to 10 results (see http-domino-enum-passwords.count)

Http-domino-enum-passwords NSE Script Example XML Output


There is no sample XML output for this module. However, by providing the -oX <file> option, Nmap will produce a XML output and save it in the file.xml file.

Author


  • Patrik Karlsson

References


See Also


Visit Nmap NSE Library for more scripts.

The http-domino-enum-passwords.nse script may fail with the following error messages. Check for the possible causes by using the code snippets highlighted below found in the script source code. This can often times help in identifying the root cause of the problem.

Failed to open file (%s)


Here is a relevant code snippet related to the "Failed to open file (%s)" error message:

197:	-- @return status true on success, false on failure
198:	-- @return err string containing error message if status is false
199:	local function saveIDFile( filename, data )
200:	  local f = io.open( filename, "w")
201:	  if ( not(f) ) then
202:	    return false, ("Failed to open file (%s)"):format(filename)
203:	  end
204:	  if ( not(f:write( data ) ) ) then
205:	    return false, ("Failed to write file (%s)"):format(filename)
206:	  end
207:	  f:close()

Failed to write file (%s)


Here is a relevant code snippet related to the "Failed to write file (%s)" error message:

200:	  local f = io.open( filename, "w")
201:	  if ( not(f) ) then
202:	    return false, ("Failed to open file (%s)"):format(filename)
203:	  end
204:	  if ( not(f:write( data ) ) ) then
205:	    return false, ("Failed to write file (%s)"):format(filename)
206:	  end
207:	  f:close()
208:	
209:	  return true
210:	end

The provided credentials were invalid


Here is a relevant code snippet related to the "The provided credentials were invalid" error message:

227:	  -- authentication required?
228:	  if ( requiresAuth( vhost or host, port, path ) ) then
229:	   -- A user was provided, attempt to authenticate
230:	    if ( user ) then
231:	      if (not(isValidCredential( vhost or host, port, path, user, pass )) ) then
232:	        return fail("The provided credentials were invalid")
233:	      end
234:	    else
235:	      local c = creds.Credentials:new(creds.ALL_DATA, host, port)
236:	      for cred in c:getCredentials(creds.State.VALID) do
237:	        has_creds = true

%s (see http-domino-enum-passwords.username and http-domino-enum-passwords.password)


Here is a relevant code snippet related to the "%s (see http-domino-enum-passwords.username and http-domino-enum-passwords.password)" error message:

241:	          break
242:	        end
243:	      end
244:	      if not pass then
245:	        local msg = has_creds and "No valid credentials were found" or "No credentials supplied"
246:	        return fail(("%s (see http-domino-enum-passwords.username and http-domino-enum-passwords.password)"):format(msg))
247:	      end
248:	    end
249:	  end
250:	
251:	  http_response = http.get( vhost or host, port, path, { auth = { username = user, password = pass }, no_cache = true })

Failed to authenticate


Here is a relevant code snippet related to the "Failed to authenticate" error message:

253:	    pager = getPager( http_response.body )
254:	  end
255:	  if ( not(pager) ) then
256:	    if ( http_response.body and
257:	      http_response.body:match(".*<input type="submit".* value="Sign In">.*" ) ) then
258:	      return fail("Failed to authenticate")
259:	    else
260:	      return fail("Failed to process results")
261:	    end
262:	  end
263:	  pos = 1

Failed to process results


Here is a relevant code snippet related to the "Failed to process results" error message:

255:	  if ( not(pager) ) then
256:	    if ( http_response.body and
257:	      http_response.body:match(".*<input type="submit".* value="Sign In">.*" ) ) then
258:	      return fail("Failed to authenticate")
259:	    else
260:	      return fail("Failed to process results")
261:	    end
262:	  end
263:	  pos = 1
264:	
265:	  -- first collect all links

%s ID File was not saved (error: %s)


Here is a relevant code snippet related to the "%s ID File was not saved (error: %s)" error message:

312:	          local filename = download_path .. "/" .. stringaux.filename_escape(u_details.fullname .. ".id")
313:	          local status, err = saveIDFile( filename, http_response.body )
314:	          if ( status ) then
315:	            table.insert( id_files, ("%s ID File has been downloaded (%s)"):format(u_details.fullname, filename) )
316:	          else
317:	            table.insert( id_files, ("%s ID File was not saved (error: %s)"):format(u_details.fullname, err ) )
318:	          end
319:	        else
320:	          table.insert( id_files, ("%s ID File was not saved (error: unexpected response from server)"):format( u_details.fullname ) )
321:	        end
322:	      else

%s ID File was not saved (error: unexpected response from server)


Here is a relevant code snippet related to the "%s ID File was not saved (error: unexpected response from server)" error message:

315:	            table.insert( id_files, ("%s ID File has been downloaded (%s)"):format(u_details.fullname, filename) )
316:	          else
317:	            table.insert( id_files, ("%s ID File was not saved (error: %s)"):format(u_details.fullname, err ) )
318:	          end
319:	        else
320:	          table.insert( id_files, ("%s ID File was not saved (error: unexpected response from server)"):format( u_details.fullname ) )
321:	        end
322:	      else
323:	        table.insert( id_files, ("%s has ID File available for download"):format(u_details.fullname) )
324:	      end
325:	    end

Version


This page has been created based on Nmap version 7.92.

Go back to menu.