Cache Poisoning: How One Bad Answer Spreads
One false answer is bad enough. Cache poisoning makes it worse by getting a computer to save that answer and keep handing it out.
A cache stores data for reuse, helping systems avoid doing the same work repeatedly. Cache poisoning happens when an attacker gets false or harmful information into that store so later requests receive it.
Two important versions affect different things: DNS cache poisoning corrupts saved address information, while web cache poisoning corrupts saved web responses. Both turn a useful shortcut into a way to spread bad data.
What Happens When You Type a Web Address?
When a name points to the wrong place
The Domain Name System, or DNS, helps turn a name such as a website's domain into an IP address, the numerical address used to reach a computer or service. A resolver looks up DNS answers for you and can save them for reuse.
In a DNS cache poisoning attack, a resolver accepts a false answer and stores it. People using that saved answer may then connect to an address the attacker chose, even if they typed the correct website name.
The internet standard on forged DNS answers describes why resolvers must carefully match replies to requests. Accepting a reply merely because it arrived isn't enough.
- Skip the install: pfSense Plus comes preloaded, so you can start writing rules right away.
- Get a firewall, router and VPN in one silent box that sips power.
- Keep receiving pfSense Plus updates for the life of the product.
Imagine a workplace's shared resolver has saved the wrong address for a supplier's ordering site. Several employees could encounter the same misdirection without anyone sending them a suspicious link.
That doesn't mean the attacker automatically gets a convincing, working copy of the supplier's secure site. Another security check still matters.
HTTPS can catch a DNS detour
HTTPS protects a browser's connection using encryption, which scrambles data for transit, and checks the server's identity through a digital certificate, an electronic credential. That certificate must be valid for the site the browser meant to reach, not merely for whatever server answered.
Pointing a domain at a different computer doesn't, by itself, give that computer a valid certificate for the domain. The standard for verifying a secure service's identity explains the checks that help prevent this impersonation.
That's why you shouldn't click past a certificate warning to finish a login. HTTPS doesn't repair the poisoned DNS entry, but its identity check can stop a wrong destination from quietly passing as the right one.
When the Right Name Leads to the Wrong Place
When the website's saved response is the problem
Web cache poisoning takes a different route. A shared web cache keeps responses, such as pages or redirects, so a site can serve later visitors faster.
It uses a cache key, a label built from selected parts of a request, to decide which saved response matches. Trouble can arise when the website changes its response based on information that this label leaves out.
An attacker may use that mismatch to make the site produce a harmful response that gets stored under a label other visitors will use. Security research firm PortSwigger describes this failure and how it can spread malicious page content or unwanted redirects.
Here, the browser may be talking to the real website over a valid HTTPS connection. Encryption protects the delivery; it doesn't judge whether the saved page is safe.
- Start tonight: the board, case, power supply and memory card are all in the box.
- Run a home lab, an ad blocker or a practice server on one small computer.
- Learn Linux hands-on without risking your main machine.
Fix the source of the bad answer
For DNS operators, DNSSEC, short for Domain Name System Security Extensions, adds digital signatures that a validating resolver can check. These help verify the origin and integrity of signed DNS data, meaning who supplied it and whether it was altered.
The DNSSEC specification also sets limits: it doesn't encrypt lookups, and protection depends on signing and validation being in place. DNS software still needs maintenance and secure configuration.
For website teams, the task is to align caching rules with the inputs that can change a response. OWASP's web cache guidance calls for fixing the vulnerable behavior and removing poisoned entries from every affected caching layer.
Clearing your own browser's cache can't clean a shared resolver or a website's cache. If those still serve the bad answer, your next request can simply bring it back.
How DNS Finds an Answer Without One Giant Directory

Pharming: When the Right Name Leads to the Wrong Server

Man-in-the-Middle Attacks: An Encrypted Login Can Reach the Wrong Site

QUOTE:
"Amateurs hack systems, professionals hack people."

