Back to articles
SecurityTrails Has a Free API — Get DNS History and Subdomains for Any Domain

SecurityTrails Has a Free API — Get DNS History and Subdomains for Any Domain

via Dev.to TutorialAlex Spinov

The Story I was investigating a phishing domain that appeared overnight. I needed to know: when was it registered? What DNS records did it have before? Who else used that IP? SecurityTrails answered all three questions in one API call. What Is SecurityTrails? SecurityTrails is a DNS intelligence platform. They crawl the entire internet's DNS infrastructure and keep historical records. Think of it as the Wayback Machine, but for DNS. Free API Tier 50 API calls per month (free account) Enough for security investigations and research Sign up at securitytrails.com for an API key The API # Get current DNS records curl -s "https://api.securitytrails.com/v1/domain/example.com" \ -H "APIKEY: YOUR_FREE_KEY" # Get subdomains curl -s "https://api.securitytrails.com/v1/domain/example.com/subdomains" \ -H "APIKEY: YOUR_FREE_KEY" # Get DNS history curl -s "https://api.securitytrails.com/v1/history/example.com/dns/a" \ -H "APIKEY: YOUR_FREE_KEY" Practical Example: Domain Investigation import requests

Continue reading on Dev.to Tutorial

Opens in a new tab

Read Full Article
2 views

Related Articles