What Is DNS Hijacking?
The Domain Name System (DNS) is the phonebook of the internet. It translates human-readable domain names like shop.de into IP addresses like 93.184.1.10 that computers use to communicate with each other. In DNS hijacking, this translation process is manipulated: instead of your server's correct IP address, the visitor's browser receives the IP address of an attacker's server.
The attack can occur at various points in the DNS resolution chain: at the domain registrar, at the DNS provider, on the victim's local router or through manipulation of DNS responses between resolver and authoritative nameserver. Depending on the attack point, different protective measures are required.
The Four Main Types of DNS Hijacking
Registrar Hijacking
In registrar hijacking, attackers gain access to the account at the domain registrar and change DNS settings directly. This can happen through phishing, social engineering or exploitation of weak passwords. Registrar hijacking is particularly dangerous because the attacker gains full control over the domain and the changes take effect across the entire internet. The attack on Brazilian major bank Banco do Brasil in 2017, in which all online banking traffic was redirected to fake servers, is a well-known example (Kaspersky Lab).
DNS Cache Poisoning
In cache poisoning, a DNS resolver's cache is poisoned with fake entries. The resolver stores the manipulated data and delivers it to all subsequent requests until the cache entry expires. Unlike registrar hijacking, the authoritative DNS records are not changed here, only the cached copies at one or more resolvers.
Man-in-the-Middle Attacks on DNS
In this attack type, the attacker intercepts DNS queries between the client and DNS resolver and responds with a fake IP address. This is particularly a risk in public Wi-Fi networks where the attacker can control network traffic. DNSSEC (DNS Security Extensions) provides protection against this type of attack.
Rogue DNS Servers
Malware on the user's computer or router can change DNS settings so that all DNS queries are directed to a server controlled by the attacker. This attack type affects individual users or networks and is frequently used for phishing or redirection to advertising pages. From the website operator's perspective, this type is the most difficult to detect since the actual DNS records remain unchanged.
What Risks Does DNS Hijacking Pose to Businesses?
The consequences of a successful DNS hijacking attack can be devastating:
- Data loss and theft: When visitors enter their login credentials, credit card information or other sensitive data on a fake website, this information goes directly into the attacker's hands.
- Email compromise: By changing MX records, all email traffic for a domain can be intercepted. Confidential business communications, invoices and password reset links are redirected.
- Reputation damage: When phishing pages or malware are distributed through your domain, customer trust suffers lasting damage. Search engines and browser security filters can blacklist your domain.
- SEO losses: When the domain points to a different server, you typically lose your search engine rankings. Recovery after DNS hijacking can take weeks to months.
- Legal consequences: When customer data is stolen through a DNS hijacking attack, GDPR fines and liability claims threaten. The notification obligation under Art. 33 GDPR requires notifying the supervisory authority within 72 hours.
How to Detect DNS Hijacking
The greatest challenge with DNS hijacking is detection. The attack can be technically invisible if the attacker carefully designs the fake website. However, there are several indicators and methods that point to an attack:
Automated DNS Record Monitoring
The most reliable method for detecting DNS hijacking is continuous monitoring of all DNS records. DNS monitoring from XICTRAQ checks your A, AAAA, MX, NS, CNAME, TXT and SPF records at regular intervals and compares them with expected values. Any deviation triggers an immediate alert. This way, you detect unauthorised changes within minutes, not days or weeks later.
SSL Certificate Anomalies
When an attacker redirects traffic to their server, they typically cannot present a valid SSL certificate for your domain unless they also have access to your certificate management. Browsers then display a certificate warning. Automated SSL monitoring detects when the certificate issuer, serial number or other parameters change unexpectedly.
Traffic Anomalies
A sudden drop in website traffic may indicate DNS hijacking if the traffic is instead flowing to an attacker's server. Cookieless analytics from XICTRAQ shows traffic trends in real time and makes unusual drops immediately visible.
Protective Measures Against DNS Hijacking
Enable DNSSEC
DNS Security Extensions (DNSSEC) cryptographically sign DNS responses so that manipulations can be detected. Resolvers that validate DNSSEC reject fake responses. According to APNIC, however, only approximately 30% of all domains worldwide are secured with DNSSEC (APNIC). Activation is possible with most domain registrars and should be performed for all business-critical domains.
Strengthen Registrar Security
Access to your domain registrar account is a primary attack target. Protect it with strong, unique passwords and two-factor authentication (2FA). Additionally activate a registrar lock function that prevents transfers and DNS changes without explicit confirmation. For particularly valuable domains, some registrars offer a "Registry Lock" that requires additional manual verification steps.
Configure Email Authentication
SPF, DKIM and DMARC records protect against email-based abuse of your domain. When an attacker changes MX records but SPF and DMARC are correctly configured, emails from unauthorised servers are typically flagged as suspicious or rejected by recipient systems. XICTRAQ also monitors these email-relevant DNS records as part of DNS monitoring.
Certificate Authority Authorization (CAA)
CAA records in your DNS specify which certificate authorities are permitted to issue SSL certificates for your domain. When an attacker tries to request a certificate from an unauthorised CA, the request is rejected. Combined with Certificate Transparency monitoring, which XICTRAQ offers as part of the security scan, every unauthorised certificate issuance is detected.
DNS Monitoring in Practice
Effective DNS monitoring watches not only the DNS records themselves but also the context: are the nameservers reachable? Do the WHOIS data still match? Are the domain and SSL certificate expiring at the same time? XICTRAQ offers a comprehensive DNS monitoring module that continuously checks the following aspects:
- All DNS record types: A, AAAA, CNAME, MX, NS, TXT, SPF, DMARC, DKIM, CAA and SRV records are checked at configurable intervals.
- Nameserver availability: Verification that all configured nameservers respond and deliver consistent results.
- DNSSEC validation: Checking that the DNSSEC signature is valid and the chain of trust remains intact.
- Domain expiry: Warning before domain registration expires to prevent accidental loss.
- Change history: Logging of all DNS changes in a visual changelog showing when which record was changed.
What to Do During a DNS Hijacking Incident
When XICTRAQ reports an unauthorised DNS change, swift action is critical. Follow this emergency plan:
- Verify immediately: Verify the DNS change through multiple independent DNS lookup tools. Determine whether the change was authorised (e.g. by a colleague or a planned server switch).
- Secure registrar account: Change your registrar account password and enable 2FA if not already done. Check the access history for unauthorised logins.
- Correct DNS records: Reset the DNS records to the correct values. Enable the registrar lock to prevent further changes.
- Check SSL certificate: Ensure your SSL certificate is still valid and has not been replaced by a fraudulent certificate. Revoke compromised certificates if necessary.
- Notify affected parties: If user data may have been compromised, inform those affected and report the incident according to Art. 33 GDPR to the relevant supervisory authority.
- Forensic analysis: Document the incident for later analysis. Which records were changed? When did the change occur? Where was the traffic redirected?
DNS Hijacking Prevention as Part of an Overall Strategy
DNS security should not be viewed in isolation but as an integral part of a comprehensive website security strategy. XICTRAQ connects DNS monitoring with uptime monitoring, security scans, SSL monitoring and GDPR compliance in one integrated platform. When a DNS change coincides with an uptime drop or an SSL anomaly, XICTRAQ recognises the correlation and delivers a contextual alert indicating a possible hijacking attack.
Start DNS monitoring today and close one of the most critical security gaps in your infrastructure. Registration takes just minutes. Alternatively, you can request a demo to see the features in detail.
How common are DNS hijacking attacks?
Does DNSSEC fully protect against DNS hijacking?
How quickly does XICTRAQ detect a DNS change?
Which DNS records should be monitored?
What is the difference between DNS hijacking and DNS spoofing?
Can DNS hijacking also affect emails?
This article is based on data from: (APNIC), Global DNS Threat Report (IDC), Threat Report (Kaspersky).