INCIDENT REPLAY · 2017-01-05
Iran TIC censorship route for an adult-site /24 leaks via Omantel
Around 12:00 UTC on 5 January 2017, AS12880 began announcing 99.192.226.0/24, a more-specific of MojoHost's 99.192.128.0/17 that hosts adult sites censored in Iran. The route reached Omantel, which re-advertised it to its peers, so users outside Iran were also blackholed. It persisted about 28 hours, until roughly 16:00 UTC on 6 January, when the legitimate origin announced the same /24 and Omantel stopped propagating the bogus route.
A reconstruction, not the operator's network. Hammerhead's authors rebuilt the change from the public record as a small network of their own. No configuration here is the operator's. What follows is what the tool reported on that reconstruction; it is not a claim that the tool would have prevented the outage.
What happened
Who: TIC / Iran (AS12880, with private AS65050 in the path); propagated by Omantel (AS8529); victim MojoHost (AS27589)
The summary at the top is paraphrased from the sources below. Hammerhead's catalog rates its confidence in this account medium.
Sources
- https://bishopfox.com/blog/2017/01/in-the-news-a-bgp-hijacking-technical-post-mortem
- https://bishopfox.com/blog/bgp-hijacking-technical-post-mortem
- https://en.wikipedia.org/wiki/BGP_hijacking
- https://www.ibtimes.co.uk/iran-blocked-256-porn-websites-has-somehow-stopped-worldwide-users-accessing-them-too-1600119
What the public record says
- Around 12:00 UTC on 5 January 2017, AS12880 began announcing 99.192.226.0/24, a more-specific of MojoHost's 99.192.128.0/17 that hosts adult sites censored in Iran. The route reached Omantel, which re-advertised it to its peers, so users outside Iran were also blackholed. It persisted about 28 hours, until roughly 16:00 UTC on 6 January, when the legitimate origin announced the same /24 and Omantel stopped propagating the bogus route.
- Who: TIC / Iran (AS12880, with private AS65050 in the path); propagated by Omantel (AS8529); victim MojoHost (AS27589)
What the reconstruction assumed
Decided by Hammerhead's authors to build a network that runs. None of it describes the operator's network.
Everything below is ours.
- The family template (
tools/replays/gen_family_misorigination.py): TIC-1 (AS 12880), an upstream OMANTEL-1 (AS 8529) that prefers its customer's routes and filters nothing on that session, the victim, and a third party behind the upstream. TIC-1 null-routes the space it originates, so traffic drawn to it is dropped. - Cisco IOS syntax. No operator here has published configuration, and which vendors they ran is not on the record.
- The upstream's other sessions are filtered and limited, so that the audit's finding is about this session and not the template.
- TIC-1 exports with the ordinary customer policy, an AS-path filter that passes only what it originates (
^$). A mis-originated prefix is locally originated, so it passes. - 99.192.226.0/24 is the prefix in the reports. The covering prefix the host announced is not in what we read; a /22 is assumed so that the block is a more-specific, as the reports describe.
What Hammerhead said
Each run below is pinned by Hammerhead's replay tests at commit 0ee9732: the verdict and the quoted text are checked against the tool's output, and a run that disagrees fails the test. Reason lines are copied verbatim; a pinned line can be part of a longer reason. Every preflight run uses --max-blast-radius 100, so a change is never counted as caught merely because it touched many devices of a small network.
every network in one snapshot
now: failOn the reconstruction, hammerhead preflight on a before and an after snapshot returned fail, for the reasons below.
Reason text pinned (some reason contains each line)
- TIC-1 would start originating 99.192.226.0/24, which is inside 99.192.224.0/22 that it learns from AS 8529, originated by AS 27589
- connected subnet(s) reachable before are not reachable after
First run, before the fixes this batch prompted
first: fail- reachability regression: 1 connected subnet(s) reachable before are not reachable after — 99.192.226.0/24 on HOST-1 (99.192.226.1) from OMANTEL-1, TIC-1, X-1 [icmp echo, tcp/179 bgp, tcp/22 ssh, tcp/80 http, udp/53 dns]
- external advertisements: TIC-1 would start originating 99.192.226.0/24, which is inside 99.192.224.0/22 that it learns from AS 8529, originated by AS 27589. A more-specific of address space you receive from a peer is not yours to announce
Pinned in tests/gauntlet/replays-misorigination.yaml.
TIC-1's own router, nothing declared: a new origination is reported, and only a caveat
now: passOn the reconstruction, hammerhead preflight on a before and an after snapshot returned pass.
Caveats pinned (some caveat contains each line; a caveat never moves the verdict)
- TIC-1 would start announcing 1 prefix(es) to
First run, before the fixes this batch prompted
first: unknownPinned in tests/gauntlet/replays-misorigination.yaml.
TIC-1's own router, with what the upstream sends declared
now: failOn the reconstruction, hammerhead preflight on a before and an after snapshot with --boundary @iran_tic_2017/boundary.yaml returned fail, for the reasons below.
Reason text pinned (some reason contains each line)
- TIC-1 would start announcing 99.192.226.0/24 to
- which is inside 99.192.224.0/22 that
- (AS 8529) advertises to this network (declared by
First run, before the fixes this batch prompted
first: fail- external advertisements: TIC-1 would start announcing 99.192.226.0/24 to 172.16.1.1 (AS 8529), which is inside 99.192.224.0/22 that 172.16.1.1 (AS 8529) advertises to this network (declared by noc@example.net). A more-specific of address space you receive from a peer is not yours to announce
Pinned in tests/gauntlet/replays-misorigination.yaml.
OMANTEL-1's own router, no change: the audit
now: fail (finding)An audit of one snapshot, no change: hammerhead nqe-library --mode run, check nqe.bgp.ebgp_peer_unfiltered_and_unlimited. Pinned status: fail, a finding whose evidence contains the text below.
Evidence pinned (the evidence contains each line)
- OMANTEL-1
- 12880
First run, before the fixes this batch prompted
first: pass (no finding)Pinned in tests/gauntlet/replays-misorigination.yaml.
every network in one snapshot (potential microloop)
now: failOn the reconstruction, hammerhead preflight on a before and an after snapshot returned fail.
This run repeats another pinned run (same snapshots, flags and verdict) to record the potential microloops it finds. A caveat never moves the verdict.
Caveats pinned (some caveat contains each line; a caveat never moves the verdict)
- OMANTEL-1 -> TIC-1 -> OMANTEL-1, if OMANTEL-1 has its new next hop while TIC-1 still has its old one
Pinned in tests/gauntlet/replays-transients.yaml.
What changed in Hammerhead because of it
From the “What was fixed” table in Hammerhead's replay notes, where each fix landed after a failing test. “Found by” is copied as written; a family name means the batch this incident belongs to.
ROA maximum length
Roa::covers_prefix refused to cover a more-specific beyond maxLength, so such a prefix came back NotFound instead of Invalid (RFC 6811).
Found by: Mis-origination family
--roas <FILE> origin-validates new originations
From the originator's own seat a block that escapes is one new prefix, and only a caveat. With a validator's export it is decidable: "the ROA for 104.244.42.0/24 authorises AS 13414".
Found by: Mis-origination family
An announcement that multiplies
The announcement to an external peer goes from a few prefixes to many in one change.
Found by: Mis-origination family, Level 3
Outbound policy runs before the local AS is prepended
The simulator prepended first, so an outbound filter-list with ^$ matched nothing the router originated.
Found by: Mis-origination family
Many foreign originations are one reason
A mass mis-origination of hundreds of prefixes was hundreds of reasons.
Found by: Mis-origination family
Limits
- The configurations are a reconstruction. Where the record is silent, the assumptions above fill the gap; if one is wrong, the replay is wrong in that respect.
- A verdict describes the reconstructed network's converged state. Timing, traffic load, and anything a device does that no configuration states, such as software reacting to a health check or a firmware bug, are outside it.
- A pass is reported as a pass. A fail says a gate fired on the reconstruction, nothing more.
- Why the catalog counts this outage as in scope: A deliberately configured blocking route for a prefix the operator does not own was exported over an external session; an export-scope check on the change would flag a non-owned more-specific leaving the AS.
Not fixed: A single-prefix hijack from the hijacker's own seat, with no ROA and nothing declared
One new origination is what a legitimate new prefix looks like. pass with the caveat naming it; --roas or --boundary decides it.
Recorded against: Mis-origination family (17 of 28)
Not fixed: A forged-origin hijack
Origin validation passes it by construction. ASPA is not modelled.
Recorded against: Mis-origination family
Imported from docs/replays/iran-tic-2017/FACTS.md and the replay manifests in the Hammerhead repository at commit 0ee9732.