External recon
# Sets the USER-AGENT sent by recon-ng (by default "Recon-ng/vX") for a more OPSEC friendly approach.
options set USER-AGENT "<USER_AGENT_STRING>"
--------------------------------------------------------------------------------
# Workspaces: projects that will hold the related domains, hosts, ports, etc..
# Each workspace will be stored as a SQLite database on the filesystem.
# Creates a "workspace".
workspaces create <WORKSPACE_NAME>
# List the existing workspaces.
workspaces list
# Switches to the specified workspace.
workspaces load <WORKSPACE_NAME>
# Removes the specified workspace.
workspaces remove <WORKSPACE_NAME>
--------------------------------------------------------------------------------
# API keys operations.
# Each module lists the API key(s) it requires.
# Adds the specified key.
# Key names examples: bing_api, github_api, google_api, ipinfodb_api, shodan_api, spyse_api virustotal_api, whoxy_api, etc.
keys add <KEY_NAME> <KEY_VALUE>
# Removes the specified key.
keys remove <KEY_NAME>
# List the configured keys.
keys list
--------------------------------------------------------------------------------
# Database operations (adding / removing targets, listing current results, etc.).
# Supported tables (as of recon-ng v5.1.2): companies, contacts, credentials domains, hosts, leaks, locations, netblocks, ports, profiles, pushpins, repositories, and vulnerabilities.
# "companies" table: name of the companies to target (for Whois / ASN research for instance).
# "domains" table: domains to be targeted.
# "hosts" table: hosts enumerated (hostname and IP address information notably).
# "ports" table: ports enumerated, including information on the host, the protocol / service, etc.
# Displays the schema of the current's workspace database.
db schema
# Lists the values stored in the specified table (including their rowid, needed for various operations).
show <domains | hosts | ports | TABLE_NAME>
db query SELECT rowid, * FROM <domains | hosts | ports | TABLE_NAME>;
# Adds the specified entry in the given table.
db insert companies <COMPANY_NAME>~ ~
db insert domains <DOMAIN>~
db insert netblocks <CIDR>~
[...]
# Removes the specified domain from the "domains" table.
db delete domains <ROWID>
# Removes all entries from the specified table.
db query DELETE FROM <TABLE>;
--------------------------------------------------------------------------------
# The modules of the recon-ng framework are not provisioned / installed by default but are made available from the "Recon-ng Marketplace" (https://github.com/lanmaster53/recon-ng-marketplace).
# Lists all the modules available.
marketplace search
# Searches among the available modules for the specified keyword(s).
marketplace search <KEYWORD(S)>
# Retrieves information about all or the specified module(s) (description, last update date, required API keys and dependencies, etc.).
marketplace info <all | MODULE_PATH>
# Install all or the specified module.
marketplace install <all | MODULE_PATH>
--------------------------------------------------------------------------------
# The modules will usually require a <SOURCE> input.
# By default the source will be all the data from a recon-ng's table, but can be specified to be a single element, a file, or an SQL query to extract specific data.
# Lists the modules currently installed.
modules search
# Searches among the installed modules for the specified keyword(s).
modules search <KEYWORD(S)>
# Loads the specified module.
modules load <MODULE_PATH>
# Displays the help of the current module.
[recon-ng][<WORKSPACE>][<MODULE>] > info
# If required, set the <SOURCE> input for the current module.
[recon-ng][<WORKSPACE>][<MODULE>] > options set SOURCE <SINGLE_ELEMENT | FILE | SQL_QUERY>
# Execute the current module.
[recon-ng][<WORKSPACE>][<MODULE>] > run
--------------------------------------------------------------------------------
# Specific modules are designed for the importing / exporting of results.
# Input modules: import/csv_file, import/list, import/masscan, and import/nmap.
# Notable exporting modules: reporting/csv, reporting/list, reporting/json, reporting/html, and reporting/xlsx.
# Import the data in the file in the specified table's column.
# For example, to import subdomains: <TABLE> = hosts & <COLUMN> = host.
modules load import/list
[recon-ng][<WORKSPACE>][list] > options set FILENAME <FILENAME>
[recon-ng][<WORKSPACE>][list] > options set TABLE <TABLE>
[recon-ng][<WORKSPACE>][list] > options set COLUMN <COLUMN>
[recon-ng][<WORKSPACE>][list] > runDomain enumeration
- ServiceURLDescription
Service
URL
Description
Service
URL
Description
Subdomains enumeration
Service
URL / query
Description
Tool
Description
IPs and services exposure
Code repository enumeration and research
Employees contacts gathering
Leaked credentials
Username enumeration and password bruteforce / spraying
References
Last updated