-
Notifications
You must be signed in to change notification settings - Fork 0
API Keys
This page explains how ReconSR uses API keys for third-party services and how to configure them locally.
ReconSR stores API credentials in configs/keys.txt under the [Keys] section. Environment variables can also be used with the RECONSR_<SERVICE> format and have priority over values from the file.
Warning
ReconSR does not provide, manage, or validate third-party subscriptions, account limits, or API quotas. Obtain keys directly from the relevant service provider and review the limits in your own account before enabling API-backed modules.
ReconSR checks for the API key configuration file during startup:
- If
configs/keys.txtexists, ReconSR loads the existing settings. - If
configs/keys.txtis missing, ReconSR creates a default file with empty key values. - If the file already exists, ReconSR reads it and does not overwrite it with defaults.
This behavior protects existing local credentials from being replaced by an automatically generated file.
The API key configuration file is located at:
configs/keys.txt
Default file content:
[Keys]
AbuseIPDB=
HackerTarget=
Shodan=
VirusTotal=
Hunterio=
HaveIBeenPwned=
Circl=Leave a value empty when you do not want to configure that service through the file.
ReconSR gives priority to system environment variables over values stored in configs/keys.txt.
Environment variables use the following format:
RECONSR_<SERVICE>
Replace <SERVICE> with the service name. Each service section below lists its own environment variable.
If configs/keys.txt contains one key and the environment variable contains another key, ReconSR uses the value from the environment variable.
Export a key into the current shell session:
export RECONSR_SHODAN=aaaRun ReconSR with environment variables set only for one command:
RECONSR_SHODAN=aaa RECONSR_VIRUSTOTAL=bbb ./ReconSR example.comExample priority behavior:
[Keys]
Shodan=file-key-valueexport RECONSR_SHODAN=environment-key-valueIn this case, ReconSR uses environment-key-value.
For services that require a personal API key, ReconSR exposes the related functions only when the corresponding key is configured.
This applies to:
AbuseIPDBVirusTotalHunterioHaveIBeenPwned
If a required key is missing, the related functions are not returned to the dispatcher and are not scheduled for execution.
Circl, HackerTarget and Shodan have special behavior and are described separately below.
Supported API-backed modules can run in demo mode by setting the service key to demo-api-key.
In demo mode, ReconSR returns bundled sample data instead of querying the external API. Demo mode must be enabled separately for each supported service.
Example:
[Keys]
AbuseIPDB=demo-api-key
HackerTarget=
Shodan=demo-api-key
VirusTotal=demo-api-key
Hunterio=demo-api-key
HaveIBeenPwned=demo-api-key
Circl=HackerTarget is shown as empty because it does not use demo mode.
Note
Demo mode is intended for testing integrations and observing output structure without using a real third-party API account.
AbuseIPDB requires an API key. If AbuseIPDB is empty, AbuseIPDB-backed functions are not returned to the dispatcher and are not scheduled for execution.
Official website: https://www.abuseipdb.com/
Configuration example:
[Keys]
AbuseIPDB=your-abuseipdb-keyEnvironment variable:
RECONSR_ABUSEIPDB
Demo mode example:
[Keys]
AbuseIPDB=demo-api-keyHackerTarget can be used without an API key. When HackerTarget is empty, service limits are applied by source IP address.
Official website: https://hackertarget.com/
Configuration without a key:
[Keys]
HackerTarget=Configuration with a key:
[Keys]
HackerTarget=your-hackertarget-keyEnvironment variable:
RECONSR_HACKERTARGET
Shodan supports two capability modes.
When Shodan is empty, ReconSR uses only the public InternetDB function with reduced host exposure data.
When a Shodan API key is configured, the public InternetDB function is replaced by API-backed IP and domain functions with richer results.
Official website: https://shodan.io/
Configuration without a key:
[Keys]
Shodan=Configuration with a key:
[Keys]
Shodan=your-shodan-keyEnvironment variable:
RECONSR_SHODAN
Demo mode example:
[Keys]
Shodan=demo-api-keyNote
Shodan API-backed domain lookups can consume query credits. Review your Shodan account limits before enabling broader Shodan options in Network Configuration.
VirusTotal requires an API key. If VirusTotal is empty, VirusTotal-backed functions are not returned to the dispatcher and are not scheduled for execution.
Official website: https://www.virustotal.com
Configuration example:
[Keys]
VirusTotal=your-virustotal-keyEnvironment variable:
RECONSR_VIRUSTOTAL
Demo mode example:
[Keys]
VirusTotal=demo-api-keyHunter.io requires an API key. If Hunterio is empty, Hunter.io-backed functions are not returned to the dispatcher and are not scheduled for execution.
Official website: https://hunter.io/
Configuration example:
[Keys]
Hunterio=your-hunterio-keyEnvironment variable:
RECONSR_HUNTERIO
Demo mode example:
[Keys]
Hunterio=demo-api-keyHave I Been Pwned email-lookup requests require a paid subscription. If HaveIBeenPwned is empty, Have I Been Pwned-backed functions are not returned to the dispatcher and are not scheduled for execution.
Official website: https://haveibeenpwned.com/
Configuration example:
[Keys]
HaveIBeenPwned=your-haveibeenpwned-keyEnvironment variable:
RECONSR_HAVEIBEENPWNED
Demo mode example:
[Keys]
HaveIBeenPwned=demo-api-keyCircl can be used without an API key. When Circl is empty, the vuln_lookup module operates using standard public access.
Official website: https://vulnerability.circl.lu
Configuration without a key:
[Keys]
Circl=Configuration with a key:
[Keys]
Circl=your-circl-keyEnvironment variable:
RECONSR_CIRCL
The following example shows the default API key configuration.
[Keys]
AbuseIPDB=
HackerTarget=
Shodan=
VirusTotal=
Hunterio=
HaveIBeenPwned=
Circl=