Nmap mongodb-databases NSE Script
This page contains detailed information about how to use the mongodb-databases NSE script. For list of all NSE scripts, visit the Nmap NSE Library.
Script Overview
Script source code: https://github.com/nmap/nmap/tree/master/scripts/mongodb-databases.nse
Script categories: default, discovery, safe
Target service / protocol: mongodb, mongod
Target network port(s): 27017
List of CVEs: -
Script Description
The mongodb-databases.nse script attempts to get a list of tables from a MongoDB database.
Mongodb-databases NSE Script Arguments
This is a full list of arguments supported by the mongodb-databases.nse script:
creds.globalCredentials 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
- - -
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=mongodb-databases --script-args creds.global=value,creds.\[service]=value <target>
Mongodb-databases NSE Script Example Usage
Here's an example of how to use the mongodb-databases.nse script:
nmap -p 27017 --script mongodb-databases <host>
Mongodb-databases NSE Script Example Output
Here's a sample output from the mongodb-databases.nse script:
PORT STATE SERVICE REASON
27017/tcp open unknown syn-ack
| mongodb-databases:
| ok = 1
| databases
| 1
| empty = false
| sizeOnDisk = 83886080
| name = test
| 0
| empty = false
| sizeOnDisk = 83886080
| name = httpstorage
| 3
| empty = true
| sizeOnDisk = 1
| name = local
| 2
| empty = true
| sizeOnDisk = 1
| name = admin
|_ totalSize = 167772160
Mongodb-databases 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
- Martin Holst Swende
References
- https://nmap.org/nsedoc/scripts/mongodb-databases.html
- https://github.com/nmap/nmap/tree/master/scripts/mongodb-databases.nse
See Also
Related NSE scripts to the mongodb-databases.nse script:
Visit Nmap NSE Library for more scripts.
Version
This page has been created based on Nmap version 7.92.