Is there a way to add domains into recon-ng from a text file (newline delimited)? I've tried comma delimiting entries but reco-ng takes the comma as part of the domain.
At the moment I am doing:

for line in $(cat domains.txt); do printf "add domains\n%s\n" $line; done

in a shell then pasting the resultant output into recon-ng.
It's a little kludgy but doesn't take too long and it works.
Is there an official way to do this? Thanks.


recon-ng already supports import of external data (by newlines) with the SOURCE variable. SOURCE should be available via most plugins, including the domain ones you are interested in.

Check the wiki -- https://bitbucket.org/LaNMaSteR53/recon-ng/wiki/Usage%20Guide -- which includes information on using the SOURCE variables for data from the local filesystem.

There are also the import/csv_file and import/list modules in recon-ng which will push your data into the recon-ng database.

The method for creating a workspace and using add domains to add domains to that workspace's database can be seen in this blog post -- https://www.stevencampbell.info/2016/10/passive-information-gathering/ -- after which you can see the domains along with IP-address data by way of show hosts. This appears to be the way that you are adding domains, which is one way of doing this.

Once a domain plugin is run, or if a workspace is created and domains are added -- as long as you see your domain via show hosts, then the recon-ng database (usually best performed per workspace) can be modified just like any sqlite3 database. For more information on where recon-ng places these sqlite3 databases on your local filesystem as well as other tips and tricks, see this blog post --https://www.codemetrix.net/practical-osint-recon-ng/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.