Nmap dict-info NSE Script


This page contains detailed information about how to use the dict-info 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/dict-info.nse
Script categories: discovery, safe
Target service / protocol: dict, tcp
Target network port(s): 2628
List of CVEs: -

Script Description


The dict-info.nse script connects to a dictionary server using the DICT protocol, runs the SHOW SERVER command, and displays the result. The DICT protocol is defined in RFC 2229 and is a protocol which allows a client to query a dictionary server for definitions from a set of natural language dictionary databases.

The SHOW server command must be implemented and depending on access will show server information and accessible databases. If authentication is required, the list of databases will not be shown.

Dict-info NSE Script Arguments


The dict-info.nse script does not have any arguments.

Dict-info NSE Script Example Usage


Here's an example of how to use the dict-info.nse script:

nmap -p 2628 <ip> --script dict-info

Dict-info NSE Script Example Output


Here's a sample output from the dict-info.nse script:

PORT     STATE SERVICE
2628/tcp open  dict
| dict-info:
|   dictd 1.12.0/rf on Linux 3.0.0-12-generic
|   On ubu1110: up 15.000, 4 forks (960.0/hour)
|
|   Database      Headwords         Index          Data  Uncompressed
|   bouvier          6797        128 kB       2338 kB       6185 kB
|_  fd-eng-swe       5489         76 kB         77 kB        204 kB

Dict-info 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 dict-info.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 connect to dictd server


Here is a relevant code snippet related to the "Failed to connect to dictd server" error message:

41:	local function fail(err) return stdnse.format_output(false, err) end
42:	
43:	action = function(host, port)
44:	  local socket = nmap.new_socket()
45:	  if ( not(socket:connect(host, port)) ) then
46:	    return fail("Failed to connect to dictd server")
47:	  end
48:	
49:	  local probes = {
50:	    'client "dict 1.12.0/rf on Linux 3.0.0-12-generic"',
51:	    'show server',

Failed to send request to server


Here is a relevant code snippet related to the "Failed to send request to server" error message:

51:	    'show server',
52:	    'quit',
53:	  }
54:	
55:	  if ( not(socket:send(table.concat(probes, "\r\n") .. "\r\n")) ) then
56:	    return fail("Failed to send request to server")
57:	  end
58:	
59:	  local srvinfo
60:	
61:	  repeat

Failed to read response from server


Here is a relevant code snippet related to the "Failed to read response from server" error message:

59:	  local srvinfo
60:	
61:	  repeat
62:	    local status, data = socket:receive_buf(match.pattern_limit("\r\n", 2048), false)
63:	    if ( not(status) ) then
64:	      return fail("Failed to read response from server")
65:	    elseif ( data:match("^5") ) then
66:	      return fail(data)
67:	    elseif ( data:match("^114") ) then
68:	      srvinfo = {}
69:	    elseif ( srvinfo and not(data:match("^%.$")) ) then

Version


This page has been created based on Nmap version 7.92.

Go back to menu.