SlideShare a Scribd company logo
1 of 104
Download to read offline
Detecting BGP hijacks in 2014
Guillaume Valadon & Nicolas Vivet
Agence nationale de la sécurité des systèmes d’information
http://www.ssi.gouv.fr/en
NSC - November 21th, 2014
ANSSI - Detecting BGP hijacks in 2014 1/52
BGP Hijacking for Cryptocurrency Profit
Reported by Dell SecureWorks on August 7 2014
« From February to May 2014, an hijacker redirected
cryptocurrency miners to his own mining pool, earning an
estimated $83,000. »
Attack Requirements
• no authentication between a miner and its bitcoin pool
• traffic redirection using BGP prefixes hijacks
ANSSI - Detecting BGP hijacks in 2014 2/52
BGP 101
What is BGP (Border Gateway Protocol) ?
It is the routing protocol used by all Internet operators.
Some BGP facts
• it runs on 179/TCP
• it informs that an operator is in charge of IP prefixes
• there is no guarantee that an operator is lying
ANSSI - Detecting BGP hijacks in 2014 4/52
What is BGP (Border Gateway Protocol) ?
It is the routing protocol used by all Internet operators.
Some BGP facts
• it runs on 179/TCP
• it informs that an operator is in charge of IP prefixes
• there is no guarantee that an operator is lying
• it interconnects all Internet operators
ANSSI - Detecting BGP hijacks in 2014 4/52
What is BGP (Border Gateway Protocol) ?
It is the routing protocol used by all Internet operators.
Some BGP facts
• it runs on 179/TCP
• it informs that an operator is in charge of IP prefixes
• there is no guarantee that an operator is lying
• it interconnects all Internet operators
ANSSI - Detecting BGP hijacks in 2014 4/52
What is BGP (Border Gateway Protocol) ?
It is the routing protocol used by all Internet operators.
Some BGP facts
• it runs on 179/TCP
• it informs that an operator is in charge of IP prefixes
• there is no guarantee that an operator is lying
• it interconnects all Internet operators
ANSSI - Detecting BGP hijacks in 2014 4/52
What Do You Need to Use BGP ?
• a network
AS42
ANSSI - Detecting BGP hijacks in 2014 5/52
What Do You Need to Use BGP ?
• a network
• an AS number that identifies your network
• an IP prefix
AS42AS42
2.0.0.0/16
ANSSI - Detecting BGP hijacks in 2014 5/52
What Do You Need to Use BGP ?
• a network
• an AS number that identifies your network
• an IP prefix
• a BGP router
AS42AS42
2.0.0.0/16
ANSSI - Detecting BGP hijacks in 2014 5/52
What Do You Need to Use BGP ?
• a network
• an AS number that identifies your network
• an IP prefix
• a BGP router
• a BGP interconnection
AS transit
ISP providing BGP
InternetAS42AS42
2.0.0.0/16
ANSSI - Detecting BGP hijacks in 2014 5/52
Internet Resources Allocation
AS & prefixes are allocated by Regional Internet Registry:
Europe
Asia
Africa
North America
Latin America & Caribbean
In Europe, per year, an ASN costs 50€ and a /22 50€.
ANSSI - Detecting BGP hijacks in 2014 6/52
Access to Internet Resources Allocation
The WHOIS protocol
$ whois AS4713
aut-num: AS4713
as-name: OCN
descr: NTT Communications Corporation
[..]
country: JP
admin-c: AY1361JP
tech-c: TT10660JP
tech-c: TT15086JP
changed: apnic-ftp@nic.ad.jp 19960911
changed: apnic-ftp@nic.ad.jp 20091113
source: JPNIC
ANSSI - Detecting BGP hijacks in 2014 7/52
Access to Internet Resources Allocation
https://stat.ripe.net
ANSSI - Detecting BGP hijacks in 2014 8/52
AS Announces & Removes Prefixes
With BGP, an operator uses:
InternetAS43515 AS4713
AS3215
208.117.252.0/22 61.28.192.0/24
2.0.0.0/16
ANSSI - Detecting BGP hijacks in 2014 9/52
AS Announces & Removes Prefixes
With BGP, an operator uses:
• UPDATE messages to announce its IP prefixes
InternetAS43515 AS4713
AS3215
208.117.252.0/22 61.28.192.0/24
2.0.0.0/16
208.117.252.0/22 61.28.192.0/24
2.0.0.0/16
ANSSI - Detecting BGP hijacks in 2014 9/52
AS Announces & Removes Prefixes
With BGP, an operator uses:
• UPDATE messages to announce its IP prefixes
• WITHDRAW messages to remove its IP prefixes
InternetAS43515 AS4713
AS3215
208.117.252.0/22 61.28.192.0/24
2.0.0.0/16
208.117.252.0/22 61.28.192.0/24
2.0.0.0/16208.117.252.0/22
208.117.252.0/22
ANSSI - Detecting BGP hijacks in 2014 9/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2 AS3 Internet
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2 AS3 Internet
192.0.2.0/24
192.0.2.0/24 AS1
BGP
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2 AS3 Internet
192.0.2.0/24 192.0.2.0/24
192.0.2.0/24 AS1
BGP
192.0.2.0/24 AS1 AS2
BGP
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4 Internet
192.0.2.0/24 AS1
192.0.2.0/24 AS1 AS3
BGP
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4 Internet
192.0.2.0/24 AS1
192.0.2.0/24 AS1 AS3
BGP
192.0.2.0/24 AS1
192.0.2.0/24 AS1 AS3
BGP
192.0.2.0/24 AS1 AS2
BGP
192.0.2.0/24
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4
Internet
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4
Internet
192.0.0.0/16
192.0.2.0/24
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4
Internet
192.0.0.0/16
192.0.2.0/24
192.0.0.0/16 AS4 AS1
192.0.2.0/24 AS3 AS1
BGP
ANSSI - Detecting BGP hijacks in 2014 10/52
Three Simple BGP Rules
1. messages are forwarded to neighbors, after adding the ASN
2. only the shortest AS path is forwarded
3. packets are sent to the most specific prefix
AS1 AS2
AS3
AS4
Internet
192.0.0.0/16
192.0.2.0/24
192.0.0.0/16 AS4 AS1
192.0.2.0/24 AS3 AS1
BGP
192.0.0.0/16 AS4 AS1
192.0.2.0/24 AS3 AS1
BGP
192.0.2.42
ANSSI - Detecting BGP hijacks in 2014 10/52
Hijacks 101
What is a Prefix Hijack?
BGP rule #2 in action
An hijack is a conflicting BGP announcement.
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23 AS1 AS0
BGP
ANSSI - Detecting BGP hijacks in 2014 12/52
What is a Prefix Hijack?
BGP rule #2 in action
An hijack is a conflicting BGP announcement.
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
BGP
ANSSI - Detecting BGP hijacks in 2014 12/52
What is a Prefix Hijack?
BGP rule #2 in action
An hijack is a conflicting BGP announcement.
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
BGP
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
BGP
Rule #2 applies: traffic is redirected to AS3 !
ANSSI - Detecting BGP hijacks in 2014 12/52
Active Countermeasure
Use BGP rule #3 !
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
BGP
The origin AS announces more specific prefixes.
ANSSI - Detecting BGP hijacks in 2014 13/52
Active Countermeasure
Use BGP rule #3 !
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23
192.0.2.0/24
192.0.3.0/24
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
192.0.2.0/24 AS1 AS0
192.0.3.0/24 AS1 AS0
BGP
The origin AS announces more specific prefixes.
ANSSI - Detecting BGP hijacks in 2014 13/52
Active Countermeasure
Use BGP rule #3 !
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23
192.0.2.0/24
192.0.3.0/24
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
192.0.3.0/24 AS1 AS0
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
192.0.2.0/24 AS1 AS0
192.0.3.0/24 AS1 AS0
BGP
The origin AS announces more specific prefixes.
ANSSI - Detecting BGP hijacks in 2014 13/52
Active Countermeasure
Use BGP rule #3 !
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23
192.0.2.0/24
192.0.3.0/24
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
192.0.3.0/24 AS1 AS0
192.0.2.0/23 AS1 AS0
192.0.2.0/23 AS3
192.0.2.0/24 AS1 AS0
192.0.3.0/24 AS1 AS0
BGP
The origin AS announces more specific prefixes.
Rule #3 applies: traffic is sent to AS0 !
ANSSI - Detecting BGP hijacks in 2014 13/52
A Recent Example on October 16
Hijack against a French AS
x
ANSSI - Detecting BGP hijacks in 2014 14/52
A Recent Example on October 16
Hijack against a French AS
ANSSI - Detecting BGP hijacks in 2014 14/52
Passive Countermeasure
Strict filter on an interconnection
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23 64501 64500
BGP
• a BGP router can filter prefix in UPDATE messages
• useful filtering can only be done by the upstream provider
ANSSI - Detecting BGP hijacks in 2014 15/52
Passive Countermeasure
Strict filter on an interconnection
AS0 AS1 AS2
AS3
192.0.2.0/23
192.0.2.0/23192.0.2.0/23 64501 64500
BGP
• a BGP router can filter prefix in UPDATE messages
• useful filtering can only be done by the upstream provider
ANSSI - Detecting BGP hijacks in 2014 15/52
Passive Countermeasure
Automate filter maintenance
A route object:
• is declared by the AS in charge of an IP prefix
• tells who can announce the prefix with BGP
• the operator, its DDoS mitigation provider, its clients, …
$ whois -T route 185.50.64.0/22
route: 185.50.64.0/22
descr: Observatory IPv4 prefix.
origin: AS202214
mnt-by: ASOBS-MNT
source: RIPE # Filtered
ANSSI - Detecting BGP hijacks in 2014 16/52
Offline Hijack Detection
BGP messages
ANSSI - Detecting BGP hijacks in 2014 18/52
Collecting BGP Archives
https://www.ris.ripe.net
AS1 AS2 AS3
AS4
AS5
AS6 AS666
192.168.0.0/16 192.168.0.0/24
BGP collector
Routing Information Service (RIS)
• 13 BGP collectors all over the world
• 263 BGP peers
• BGP messages dumped into binary files
• 550 GB per year
ANSSI - Detecting BGP hijacks in 2014 19/52
Parsing BGP Archives
https://github.com/ANSSI-FR/parsifal
Raw BGP BGP parser
Need for a dedicated BGP parser
• fast & trusted parser
• written in OCaml
• convert BGP messages to JSON
• human readable / writable format
ANSSI - Detecting BGP hijacks in 2014 20/52
Parsing BGP Archives
https://github.com/ANSSI-FR/parsifal
{ "timestamp":1409750436, "collector": "rrc07",
"as_path":"25152 6939 17922 7862 4761 9957 7500 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
{ "timestamp":1409782437, "collector": "rrc07",
"as_path":"25152 6939 667 666 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
Need for a dedicated BGP parser
• fast & trusted parser
• written in OCaml
• convert BGP messages to JSON
• human readable / writable format
ANSSI - Detecting BGP hijacks in 2014 20/52
Parsing BGP Archives
https://github.com/ANSSI-FR/parsifal
{ "timestamp":1409750436, "collector": "rrc07",
"as_path":"25152 6939 17922 7862 4761 9957 7500 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
{ "timestamp":1409782437, "collector": "rrc07",
"as_path":"25152 6939 667 666 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
Need for a dedicated BGP parser
• fast & trusted parser
• written in OCaml
• convert BGP messages to JSON
• human readable / writable format
ANSSI - Detecting BGP hijacks in 2014 20/52
Parsing BGP Archives
https://github.com/ANSSI-FR/parsifal
{ "timestamp":1409750436, "collector": "rrc07",
"as_path":"25152 6939 17922 7862 4761 9957 7500 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
{ "timestamp":1409782437, "collector": "rrc07",
"as_path":"25152 6939 667 666 ",
"announce":[" 192.50.44.0/24 "], "withdraw":[] }
Need for a dedicated BGP parser
• fast & trusted parser
• written in OCaml
• convert BGP messages to JSON
• human readable / writable format
ANSSI - Detecting BGP hijacks in 2014 20/52
Emulating a BGP Router
https://code.google.com/p/py-radix/
192.0.0.0/8 AS1
192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5
192.160.0.0/11 AS7 192.168.128.0/22 AS42
Build the routing table
• fast IP lookup library
• similar to a router & the Linux kernel
• the tree is updated with each BGP messages
• duplicated entries are conflicts
ANSSI - Detecting BGP hijacks in 2014 21/52
Emulating a BGP Router
https://code.google.com/p/py-radix/
192.0.0.0/8 AS1
192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5
192.160.0.0/11 AS7 192.168.128.0/22 AS42
Processing an UPDATE message
{ "timestamp":1409750436, "peer_as":25152,
"as_path":"1234 666 ",
"announce":[" 192.168.128.0/24 "], "withdraw":[] }
ANSSI - Detecting BGP hijacks in 2014 21/52
Emulating a BGP Router
https://code.google.com/p/py-radix/
192.0.0.0/8 AS1
192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5
192.160.0.0/11 AS7 192.168.128.0/22 AS42
Processing an UPDATE message
{ "timestamp":1409750436, "peer_as":25152,
"as_path":"1234 666 ",
"announce":[" 192.168.128.0/24 "], "withdraw":[] }
ANSSI - Detecting BGP hijacks in 2014 21/52
Emulating a BGP Router
https://code.google.com/p/py-radix/
192.0.0.0/8 AS1
192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5
192.160.0.0/11 AS7 192.168.128.0/22 AS42
Processing an UPDATE message
{ "timestamp":1409750436, "peer_as":25152,
"as_path":"1234 666 ",
"announce":[" 192.168.128.0/24 "], "withdraw":[] }
ANSSI - Detecting BGP hijacks in 2014 21/52
Putting Everything Together
Raw BGP BGP parser Emulate BGP
{ }
JSON
Processing 50k ASes
• emulated routers handle different AS
• with 8 cores, a month is processed in 10 hours
With 13 collectors, 156 months must be processed per year !
ANSSI - Detecting BGP hijacks in 2014 22/52
Faster Conflicts Detection
Scaling by adding cores
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Conflicts detection
• completes in one week with 120 cores on 5 servers
• generates 130 GB per year
• 11 536 345 959 conflicts
• from January to October 2014
ANSSI - Detecting BGP hijacks in 2014 23/52
Faster Conflicts Detection
Scaling by adding cores
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Raw BGP BGP parser Emulate BGP
{ }
JSON
Conflict example
{ "timestamp":1409782437, "collector": "rrc07",
"announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 ,
"as_path": "25152 6939 667 666"},
"conflict_with": {"prefix": " 192.50.44.0/24 ", "asn": 7500 }}
ANSSI - Detecting BGP hijacks in 2014 23/52
Accessing The Data
http://discoproject.org
Disco?
• automatic data distribution & replication
• like HDFS
• MapReduce framework in Python
• like Hadoop
ANSSI - Detecting BGP hijacks in 2014 24/52
Accessing The Data
http://discoproject.org
From BIG DATA to small data
• one hour to extract conflicts targeting 1000 ASes
• close to the number of French & Japanese ASes
• 70 millions conflicts per country
• 200MB
ANSSI - Detecting BGP hijacks in 2014 24/52
Classifying Conflicts - 1/3
Using route objects
Validating a single conflict
{ "timestamp": 1409782437, "collector": "rrc07",
"announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 ,
"as_path": "25152 6939 667 666"},
"conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}}
ANSSI - Detecting BGP hijacks in 2014 25/52
Classifying Conflicts - 1/3
Using route objects
Validating a single conflict
{ "timestamp": 1409782437, "collector": "rrc07",
"announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 ,
"as_path": "25152 6939 667 666"},
"conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}}
$ whois -T route 192.50.44.0/24
route: 192.50.44.0/24
descr: Example prefix
origin: AS666
mnt-by: AS666-MNT
ANSSI - Detecting BGP hijacks in 2014 25/52
Classifying Conflicts - 1/3
Using route objects
Validating a single conflict
{ "timestamp": 1409782437, "collector": "rrc07",
"announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 ,
"as_path": "25152 6939 667 666"},
"conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}}
$ whois -T route 192.50.44.0/24
route: 192.50.44.0/24
descr: Example prefix
origin: AS666
mnt-by: AS666-MNT
ANSSI - Detecting BGP hijacks in 2014 25/52
Classifying Conflicts - 1/3
Using route objects
Validating 70 millions conflicts
• all of them must be verified
• online queries are too slow
• WHOIS databases are loaded daily into PostgreSQL
• the ip4r type is used for fast prefix lookups
>>> client = Client("ripe")
>>> client.check("210.158.206.0/24", 17676, "2014/07/28")
True
0.01% conflicts removed
32% conflicts removed
ANSSI - Detecting BGP hijacks in 2014 25/52
Classifying Conflicts - 2/3
Using relations between AS objects
$ whois AS15557
aut-num: AS15557
as-name: LDCOMNET
descr: SFR
org: ORG-LA7-RIPE
admin-c: LD699-RIPE
tech-c: LDC76-RIPE
status: ASSIGNED
mnt-by: LDCOM-MNT
mnt-routes: FMCF-MNT
mnt-routes: LDCOM-MNT
source: RIPE
$ whois AS41272
aut-num: AS41272
as-name: MOSELLE-TELE-AS
descr: MOSELLE TELECOM
org: ORG-MT18-RIPE
admin-c: LD699-RIPE
tech-c: LDC76-RIPE
status: ASSIGNED
mnt-by: MOSELLE-TELE-MNT
mnt-routes: MOSELLE-TELE-MNT
source: RIPE
2% conflicts removed
54% conflicts removed
ANSSI - Detecting BGP hijacks in 2014 26/52
Classifying Conflicts - 3/3
Using client/provider connectivity
{ "timestamp": 1409750436,
"announce": { "prefix": "192.0.2.0/24", "asn": 666,
"as_path": "... 1000 666" },
"conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } }
ANSSI - Detecting BGP hijacks in 2014 27/52
Classifying Conflicts - 3/3
Using client/provider connectivity
{ "timestamp": 1409750436,
"announce": { "prefix": "192.0.2.0/24", "asn": 666,
"as_path": "... 1000 666" },
"conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } }
Internet AS1000 AS666
192.0.0.0/16 1000
192.0.2.0/24 1000 666
BGP
ANSSI - Detecting BGP hijacks in 2014 27/52
Classifying Conflicts - 3/3
Using client/provider connectivity
{ "timestamp": 1409750436,
"announce": { "prefix": "192.0.2.0/24", "asn": 666,
"as_path": "... 1000 666" },
"conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } }
Client/Provider relation
Internet AS1000 AS666
192.0.0.0/16 1000
192.0.2.0/24 1000 666
BGP
5% conflicts removed
3% conflicts removed
ANSSI - Detecting BGP hijacks in 2014 27/52
Classifying conflicts
Summary
Validated Related Connected Abnormal
0 %
30 %
60 %
90 %
32
54
3
11
0 2 5
93
Percentageofconflicts
France Japan
42 millions abnormal conflicts
8 millions abnormal conflicts
ANSSI - Detecting BGP hijacks in 2014 28/52
Computing durations
From conflicts to events
Time
| | | | | | | | | | | |
Before aggregation
{ "timestamp": 20141111.0, "collector": "rrc99" ,
"type": "RELATION",
"announce": { "prefix": "1.6.28.0/24", "asn": 666 }
"conflict_with": {"prefix": "1.6.0.0/18", "asn": 1000 } }
{ "timestamp": 20141231.0, "collector": "rrc66" ,
type": "RELATION",
"announce": { "prefix": "1.6.28.0/24", "asn": 666 }
"conflict_with": {"prefix": "1.6.0.0/18", "asn": 1000 } }
ANSSI - Detecting BGP hijacks in 2014 29/52
Computing durations
From conflicts to events
Time
| | | | | | | | | | | |
After aggregation
{ "conflict_with" : { "prefix" : "1.6.0.0/18", "asn" : 1000 },
"origin" : { "prefix" : "1.6.28.0/24", "asn" : 666 },
"begin": 20141111.0, "end" : 20141231.0,
"peers" : [ "rrc99", "rrc66" ],
"type" : "RELATION" }
74 084 events
73 902 events
ANSSI - Detecting BGP hijacks in 2014 29/52
Events Visualization
A French AS
10/28/2014 localhost:2807/timeslots/AS3215
2014 February March April May June July August September October No
ANSSI - Detecting BGP hijacks in 2014 30/52
Reducing The Number of Events
Automatically
Simple rules
• remove events that change categories
• remove events if ASes belongs to the same country
• remove events longer than 6 months
• remove associated events
From 2154 prefixes in conflict to 557
From 4519 prefixes in conflict to 289
ANSSI - Detecting BGP hijacks in 2014 31/52
Looking For Hijacks
ANSSI - Detecting BGP hijacks in 2014 32/52
Reducing The Number of Events
Manually
Interesting results
• similar AS names
• PACNET-MY Pacnet MY and PACNET Pacnet Global Ltd
• AS under DDoS protection
• the DDoS mitigation companies announces /24
• typos in AS numbers
• 2208 and 208
• hijacks that were used to steal bitcoins
• AS18863 was at the origin of some of these hijacks
• some events were never detected by operators
• ...
ANSSI - Detecting BGP hijacks in 2014 33/52
Closing Remarks
Since January 2014, there are:
69 suspicious events
102 suspicious events
Around 10 hijacks per year target French operators
ANSSI - Detecting BGP hijacks in 2014 34/52
Real-time BGP Hijack Detection
Targeted Internet Traffic Misdirection
Reported by Renesys on November, 2013
ANSSI - Detecting BGP hijacks in 2014 36/52
Real-time Detection Goals
BGP messages Hijacks
Alerts
Measurements
ANSSI - Detecting BGP hijacks in 2014 37/52
Detection Requirements
https://github.com/spotify/luigi
Fetching Tasks
• Internet registries
• raw BGP data
ANSSI - Detecting BGP hijacks in 2014 38/52
Detection Requirements
https://github.com/spotify/luigi
{ }
Fetching Tasks
• Internet registries
• raw BGP data
Processing Tasks
• synchronise whois databases
• parse BGP data to JSON
• create IP prefix to origin AS mapping
ANSSI - Detecting BGP hijacks in 2014 38/52
BGP Hijack Reporting
What must be reported
• only suspicious BGP hijacks
• about 50 events per week
ANSSI - Detecting BGP hijacks in 2014 39/52
BGP Hijack Reporting
IRC is so 2014
What must be reported
• only suspicious BGP hijacks
• about 50 events per week
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
ANSSI - Detecting BGP hijacks in 2014 39/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
ANSSI - Detecting BGP hijacks in 2014 40/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
$ whois 2a04:8000::/29
inet6num: 2a04:8000::/29
netname: UA-UAHOSTING
descr: Hosting Ukraine
country: UA
org: ORG-HUL6-RIPE
ANSSI - Detecting BGP hijacks in 2014 40/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
$ whois 2a04:8000::/29
inet6num: 2a04:8000::/29
netname: UA-UAHOSTING
descr: Hosting Ukraine
country: UA
org: ORG-HUL6-RIPE
$ whois -i org ORG-HUL6-RIPE
ANSSI - Detecting BGP hijacks in 2014 40/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
$ whois 2a04:8000::/29
inet6num: 2a04:8000::/29
netname: UA-UAHOSTING
descr: Hosting Ukraine
country: UA
org: ORG-HUL6-RIPE
$ whois -i org ORG-HUL6-RIPE
aut-num: AS200000
as-name: Ukraine-AS
descr: Hosting Ukraine
org: ORG-HUL6-RIPE
ANSSI - Detecting BGP hijacks in 2014 40/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
$ whois 2a04:8000::/29
inet6num: 2a04:8000::/29
netname: UA-UAHOSTING
descr: Hosting Ukraine
country: UA
org: ORG-HUL6-RIPE
$ whois -i org ORG-HUL6-RIPE
aut-num: AS200000
as-name: Ukraine-AS
descr: Hosting Ukraine
org: ORG-HUL6-RIPE
ANSSI - Detecting BGP hijacks in 2014 40/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
Analysis Result
• 2a04:8000::/29 belongs to the Ukrainian operator
ANSSI - Detecting BGP hijacks in 2014 41/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
Analysis Result
• 2a04:8000::/29 belongs to the Ukrainian operator
• 2a04:0800::/29 belongs to the French operator
• French operator made a mistake in its BGP configuration
ANSSI - Detecting BGP hijacks in 2014 41/52
BGP Hijack Troubleshooting
< hadron> 2a04:8000::/29 is announced from multiple origins:
< hadron> SFR-BUSINESS-TEAM (AS12566)
< hadron> Ukraine-AS (AS200000)
< hadron> First originated from SFR-BUSINESS-TEAM (AS12566)
Analysis Result
• 2a04:8000::/29 belongs to the Ukrainian operator
• 2a04:0800::/29 belongs to the French operator
• French operator made a mistake in its BGP configuration
It was a false positive, the route6 object was created a few days
later by the Ukrainian operator.
ANSSI - Detecting BGP hijacks in 2014 41/52
Malicious BGP Hijack
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
ANSSI - Detecting BGP hijacks in 2014 42/52
https://stat.ripe.net/AS198596
Announces from September to October 2014
ANSSI - Detecting BGP hijacks in 2014 43/52
Malicious BGP Hijack
Infected AS_PATH
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
ANSSI - Detecting BGP hijacks in 2014 44/52
Malicious BGP Hijack
Infected AS_PATH
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
Definition
• infected ASes accepted the hijacking BGP update
• traffic to the hijacked prefix go to the hijacker’s network
ANSSI - Detecting BGP hijacks in 2014 44/52
Malicious BGP Hijack
Infected AS_PATH
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
Definition
• infected ASes accepted the hijacking BGP update
• traffic to the hijacked prefix go to the hijacker’s network
How do we launch active measurements from these ASes?
ANSSI - Detecting BGP hijacks in 2014 44/52
RIPE Atlas Measurement Project
https://atlas.ripe.net/
• 7100 probes in around 2000 ASes
• probes hosted by the community
• user-defined measurements
• ping, traceroute, HTTP, TLS and DNS
• public API
ANSSI - Detecting BGP hijacks in 2014 45/52
ANSSI - Detecting BGP hijacks in 2014 46/52
Atlas Meets Our Needs
We always found a probe to launch our measurements!
• 250 possible hijacks from september to november 2014
• AS_PATH are from the London based RIPE collector
ANSSI - Detecting BGP hijacks in 2014 47/52
Atlas Meets Our Needs
We always found a probe to launch our measurements!
• 250 possible hijacks from september to november 2014
• AS_PATH are from the London based RIPE collector
Number of probes found in infected ASes:
2 4 6 8 10 12 14
0 %
5 %
10 %
15 %
20 %
Num of probes
Hijacks
ANSSI - Detecting BGP hijacks in 2014 47/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
ANSSI - Detecting BGP hijacks in 2014 48/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
ANSSI - Detecting BGP hijacks in 2014 48/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
Traceroute to
185.73.204.1
ANSSI - Detecting BGP hijacks in 2014 48/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
Traceroute to
185.73.204.1
ANSSI - Detecting BGP hijacks in 2014 48/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
1. 10.10.10.1
2. 82.118.96.1
3. 188.124.228.1
4. 95.215.3.78
5. * * *
ANSSI - Detecting BGP hijacks in 2014 48/52
Traceroute Example
< hadron> 185.73.204.0/22 is announced from multiple origins:
< hadron> ALPHALINK-AS (AS25540)
< hadron> TEHNOGRUP (AS198596)
< hadron> AS_PATH: 8607 39792 44050 131788 198596
Closing Remarks
• traceroute stops at AS44050 (PIN-AS)
• AS131788 and AS198596 are most certainly placeholders
• AS44050 (PIN-AS) is already known for previous hijacks
ANSSI - Detecting BGP hijacks in 2014 49/52
Conclusion
Conclusion
• wide scale BGP hijacks automatic detection
• only a few real hijacks per year regarding France and Japan
• early detection and reporting
• on-going work to identify traffic redirection
Take away messages
1. packets can be redirected on the Internet
2. traffic must be encrypted and authenticated
3. monitor prefixes and be ready to send more specific ones
4. networking Best Current Practices must be enforced
ANSSI - Detecting BGP hijacks in 2014 51/52
Questions?
A question == A Japanese Kit Kat
Related publication
• BGP configuration best practices (English & French)
ANSSI - Detecting BGP hijacks in 2014 52/52

More Related Content

What's hot

Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkom
Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkomGpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkom
Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkomWahyu Nasution
 
All about routers
All about routersAll about routers
All about routersagwanna
 
Chapter 19 : single-area ospf
Chapter 19 : single-area ospfChapter 19 : single-area ospf
Chapter 19 : single-area ospfteknetir
 
CCNAv5 - S2: Chapter 6 Static Routing
CCNAv5 - S2: Chapter 6 Static RoutingCCNAv5 - S2: Chapter 6 Static Routing
CCNAv5 - S2: Chapter 6 Static RoutingVuz Dở Hơi
 
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...Using packet-tracer, capture and other Cisco ASA tools for network troublesho...
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...Cisco Russia
 
012 2 ccna sv2-instructor_ppt_ch9
012 2 ccna sv2-instructor_ppt_ch9012 2 ccna sv2-instructor_ppt_ch9
012 2 ccna sv2-instructor_ppt_ch9Babaa Naya
 
Community tools to fight against DDoS, SANOG 27
Community tools to fight against DDoS, SANOG 27Community tools to fight against DDoS, SANOG 27
Community tools to fight against DDoS, SANOG 27APNIC
 
Where are we with Securing the Routing System?
Where are we with Securing the Routing System?Where are we with Securing the Routing System?
Where are we with Securing the Routing System?APNIC
 
Updated about cisco isr g2 sec and hsec licensing faq
Updated about cisco isr g2 sec and hsec licensing faqUpdated about cisco isr g2 sec and hsec licensing faq
Updated about cisco isr g2 sec and hsec licensing faqIT Tech
 
How to Configure NetFlow v5 & v9 on Cisco Routers
How to Configure NetFlow v5 & v9 on Cisco RoutersHow to Configure NetFlow v5 & v9 on Cisco Routers
How to Configure NetFlow v5 & v9 on Cisco RoutersSolarWinds
 
04 ccna sv2 instructor_ppt_ch5
04 ccna sv2 instructor_ppt_ch504 ccna sv2 instructor_ppt_ch5
04 ccna sv2 instructor_ppt_ch5Babaa Naya
 
How to prevent ssh-tunneling using Palo Alto Networks NGFW
How to prevent ssh-tunneling using Palo Alto Networks NGFWHow to prevent ssh-tunneling using Palo Alto Networks NGFW
How to prevent ssh-tunneling using Palo Alto Networks NGFWYudi Arijanto
 
MikroTik newsletters from #60 to #67
MikroTik newsletters from #60 to #67MikroTik newsletters from #60 to #67
MikroTik newsletters from #60 to #67Dobri Boyadzhiev
 

What's hot (20)

Multicast IP addresses Part 1
Multicast IP addresses Part 1Multicast IP addresses Part 1
Multicast IP addresses Part 1
 
Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkom
Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkomGpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkom
Gpon omci v2__voice_configuration_introduction_omciv2_v2_pt_telkom
 
520scg basic
520scg basic520scg basic
520scg basic
 
Icnd210 s07l02
Icnd210 s07l02Icnd210 s07l02
Icnd210 s07l02
 
All about routers
All about routersAll about routers
All about routers
 
Chapter 19 : single-area ospf
Chapter 19 : single-area ospfChapter 19 : single-area ospf
Chapter 19 : single-area ospf
 
CCNAv5 - S2: Chapter 6 Static Routing
CCNAv5 - S2: Chapter 6 Static RoutingCCNAv5 - S2: Chapter 6 Static Routing
CCNAv5 - S2: Chapter 6 Static Routing
 
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...Using packet-tracer, capture and other Cisco ASA tools for network troublesho...
Using packet-tracer, capture and other Cisco ASA tools for network troublesho...
 
012 2 ccna sv2-instructor_ppt_ch9
012 2 ccna sv2-instructor_ppt_ch9012 2 ccna sv2-instructor_ppt_ch9
012 2 ccna sv2-instructor_ppt_ch9
 
Community tools to fight against DDoS, SANOG 27
Community tools to fight against DDoS, SANOG 27Community tools to fight against DDoS, SANOG 27
Community tools to fight against DDoS, SANOG 27
 
Where are we with Securing the Routing System?
Where are we with Securing the Routing System?Where are we with Securing the Routing System?
Where are we with Securing the Routing System?
 
R1
R1R1
R1
 
Updated about cisco isr g2 sec and hsec licensing faq
Updated about cisco isr g2 sec and hsec licensing faqUpdated about cisco isr g2 sec and hsec licensing faq
Updated about cisco isr g2 sec and hsec licensing faq
 
How to Configure NetFlow v5 & v9 on Cisco Routers
How to Configure NetFlow v5 & v9 on Cisco RoutersHow to Configure NetFlow v5 & v9 on Cisco Routers
How to Configure NetFlow v5 & v9 on Cisco Routers
 
Tech f42
Tech f42Tech f42
Tech f42
 
AF-23- IPv6 Security_Final
AF-23- IPv6 Security_FinalAF-23- IPv6 Security_Final
AF-23- IPv6 Security_Final
 
QSpiders - Upper layer-protocols
QSpiders - Upper layer-protocolsQSpiders - Upper layer-protocols
QSpiders - Upper layer-protocols
 
04 ccna sv2 instructor_ppt_ch5
04 ccna sv2 instructor_ppt_ch504 ccna sv2 instructor_ppt_ch5
04 ccna sv2 instructor_ppt_ch5
 
How to prevent ssh-tunneling using Palo Alto Networks NGFW
How to prevent ssh-tunneling using Palo Alto Networks NGFWHow to prevent ssh-tunneling using Palo Alto Networks NGFW
How to prevent ssh-tunneling using Palo Alto Networks NGFW
 
MikroTik newsletters from #60 to #67
MikroTik newsletters from #60 to #67MikroTik newsletters from #60 to #67
MikroTik newsletters from #60 to #67
 

Viewers also liked

NSC #2 - Challenge Solution
NSC #2 - Challenge SolutionNSC #2 - Challenge Solution
NSC #2 - Challenge SolutionNoSuchCon
 
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLC
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLCNSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLC
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLCNoSuchCon
 
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch Protections
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch ProtectionsNSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch Protections
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch ProtectionsNoSuchCon
 
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic Backdooring
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic BackdooringNSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic Backdooring
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic BackdooringNoSuchCon
 
NSC #2 - Challenge Introduction
NSC #2 - Challenge IntroductionNSC #2 - Challenge Introduction
NSC #2 - Challenge IntroductionNoSuchCon
 
NSC #2 - D2 05 - Andrea Barisani - Forging the USB Armory
NSC #2 - D2 05 - Andrea Barisani - Forging the USB ArmoryNSC #2 - D2 05 - Andrea Barisani - Forging the USB Armory
NSC #2 - D2 05 - Andrea Barisani - Forging the USB ArmoryNoSuchCon
 
NSC #2 - D1 02 - Georgi Geshev - Your Q is my Q
NSC #2 - D1 02 - Georgi Geshev - Your Q is my QNSC #2 - D1 02 - Georgi Geshev - Your Q is my Q
NSC #2 - D1 02 - Georgi Geshev - Your Q is my QNoSuchCon
 
NSC #2 - D3 02 - Peter Hlavaty - Attack on the Core
NSC #2 - D3 02 - Peter Hlavaty - Attack on the CoreNSC #2 - D3 02 - Peter Hlavaty - Attack on the Core
NSC #2 - D3 02 - Peter Hlavaty - Attack on the CoreNoSuchCon
 
NSC #2 - D2 06 - Richard Johnson - SAGEly Advice
NSC #2 - D2 06 - Richard Johnson - SAGEly AdviceNSC #2 - D2 06 - Richard Johnson - SAGEly Advice
NSC #2 - D2 06 - Richard Johnson - SAGEly AdviceNoSuchCon
 
NSC #2 - D2 02 - Benjamin Delpy - Mimikatz
NSC #2 - D2 02 - Benjamin Delpy - MimikatzNSC #2 - D2 02 - Benjamin Delpy - Mimikatz
NSC #2 - D2 02 - Benjamin Delpy - MimikatzNoSuchCon
 
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected Processes
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected ProcessesNSC #2 - D3 05 - Alex Ionescu- Breaking Protected Processes
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected ProcessesNoSuchCon
 
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based device
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based deviceNSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based device
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based deviceNoSuchCon
 
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineering
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineeringNSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineering
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineeringNoSuchCon
 
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine Security
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine SecurityNSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine Security
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine SecurityNoSuchCon
 
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database Attacks
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database AttacksNSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database Attacks
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database AttacksNoSuchCon
 
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practice
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practiceNSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practice
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practiceNoSuchCon
 

Viewers also liked (16)

NSC #2 - Challenge Solution
NSC #2 - Challenge SolutionNSC #2 - Challenge Solution
NSC #2 - Challenge Solution
 
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLC
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLCNSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLC
NSC #2 - D1 03 - Sébastien Dudek - HomePlugAV PLC
 
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch Protections
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch ProtectionsNSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch Protections
NSC #2 - D2 01 - Andrea Allievi - Windows 8.1 Patch Protections
 
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic Backdooring
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic BackdooringNSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic Backdooring
NSC #2 - D3 03 - Jean-Philippe Aumasson - Cryptographic Backdooring
 
NSC #2 - Challenge Introduction
NSC #2 - Challenge IntroductionNSC #2 - Challenge Introduction
NSC #2 - Challenge Introduction
 
NSC #2 - D2 05 - Andrea Barisani - Forging the USB Armory
NSC #2 - D2 05 - Andrea Barisani - Forging the USB ArmoryNSC #2 - D2 05 - Andrea Barisani - Forging the USB Armory
NSC #2 - D2 05 - Andrea Barisani - Forging the USB Armory
 
NSC #2 - D1 02 - Georgi Geshev - Your Q is my Q
NSC #2 - D1 02 - Georgi Geshev - Your Q is my QNSC #2 - D1 02 - Georgi Geshev - Your Q is my Q
NSC #2 - D1 02 - Georgi Geshev - Your Q is my Q
 
NSC #2 - D3 02 - Peter Hlavaty - Attack on the Core
NSC #2 - D3 02 - Peter Hlavaty - Attack on the CoreNSC #2 - D3 02 - Peter Hlavaty - Attack on the Core
NSC #2 - D3 02 - Peter Hlavaty - Attack on the Core
 
NSC #2 - D2 06 - Richard Johnson - SAGEly Advice
NSC #2 - D2 06 - Richard Johnson - SAGEly AdviceNSC #2 - D2 06 - Richard Johnson - SAGEly Advice
NSC #2 - D2 06 - Richard Johnson - SAGEly Advice
 
NSC #2 - D2 02 - Benjamin Delpy - Mimikatz
NSC #2 - D2 02 - Benjamin Delpy - MimikatzNSC #2 - D2 02 - Benjamin Delpy - Mimikatz
NSC #2 - D2 02 - Benjamin Delpy - Mimikatz
 
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected Processes
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected ProcessesNSC #2 - D3 05 - Alex Ionescu- Breaking Protected Processes
NSC #2 - D3 05 - Alex Ionescu- Breaking Protected Processes
 
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based device
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based deviceNSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based device
NSC #2 - D3 01 - Thomas Braden - Exploitation of hardened MSP430-based device
 
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineering
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineeringNSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineering
NSC #2 - D1 01 - Rolf Rolles - Program synthesis in reverse engineering
 
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine Security
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine SecurityNSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine Security
NSC #2 - D2 03 - Nicolas Collignon - Google Apps Engine Security
 
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database Attacks
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database AttacksNSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database Attacks
NSC #2 - D2 04 - Ezequiel Gutesman - Blended Web and Database Attacks
 
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practice
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practiceNSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practice
NSC #2 - D1 05 - Renaud Lifchitz - Quantum computing in practice
 

Similar to NSC #2 - D3 04 - Guillaume Valadon & Nicolas Vivet - Detecting BGP hijacks

Interautonomous System PLS VPN Advanced Concepts
Interautonomous System PLS VPN Advanced ConceptsInterautonomous System PLS VPN Advanced Concepts
Interautonomous System PLS VPN Advanced ConceptsBrozaa
 
Cloud Traffic Engineer – Google Espresso Project by Shaowen Ma
Cloud Traffic Engineer – Google Espresso Project  by Shaowen MaCloud Traffic Engineer – Google Espresso Project  by Shaowen Ma
Cloud Traffic Engineer – Google Espresso Project by Shaowen MaMyNOG
 
Routing Security in 2017 – We can do better!
Routing Security in 2017 – We can do better!Routing Security in 2017 – We can do better!
Routing Security in 2017 – We can do better!APNIC
 
T4 Handout3
T4 Handout3T4 Handout3
T4 Handout3gobed
 
Computer network (14)
Computer network (14)Computer network (14)
Computer network (14)NYversity
 
ISP Border Definition
ISP Border DefinitionISP Border Definition
ISP Border DefinitionQrator Labs
 
Dynamische Routingprotokolle Aufzucht und Pflege - BGP
Dynamische Routingprotokolle Aufzucht und Pflege - BGPDynamische Routingprotokolle Aufzucht und Pflege - BGP
Dynamische Routingprotokolle Aufzucht und Pflege - BGPMaximilan Wilhelm
 
Operationalizing BGP in the SDDC
Operationalizing BGP in the SDDCOperationalizing BGP in the SDDC
Operationalizing BGP in the SDDCCumulus Networks
 
Rapid Detection of BGP Anomalies
Rapid Detection of BGP AnomaliesRapid Detection of BGP Anomalies
Rapid Detection of BGP AnomaliesAPNIC
 
CCNAS :Multi Area OSPF
CCNAS :Multi Area OSPFCCNAS :Multi Area OSPF
CCNAS :Multi Area OSPFrooree29
 
Bgp 1232073634451868-3
Bgp 1232073634451868-3Bgp 1232073634451868-3
Bgp 1232073634451868-3afzel
 
Securing Routing Protocol BGP
Securing Routing Protocol BGPSecuring Routing Protocol BGP
Securing Routing Protocol BGPIRJET Journal
 
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS Poisoning
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS PoisoningMonitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS Poisoning
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS PoisoningThousandEyes
 

Similar to NSC #2 - D3 04 - Guillaume Valadon & Nicolas Vivet - Detecting BGP hijacks (20)

Bgp tutorial for ISP
Bgp tutorial for ISPBgp tutorial for ISP
Bgp tutorial for ISP
 
bgp.ppt
bgp.pptbgp.ppt
bgp.ppt
 
Bigbgp
BigbgpBigbgp
Bigbgp
 
Bgp (1)
Bgp (1)Bgp (1)
Bgp (1)
 
Interautonomous System PLS VPN Advanced Concepts
Interautonomous System PLS VPN Advanced ConceptsInterautonomous System PLS VPN Advanced Concepts
Interautonomous System PLS VPN Advanced Concepts
 
Cloud Traffic Engineer – Google Espresso Project by Shaowen Ma
Cloud Traffic Engineer – Google Espresso Project  by Shaowen MaCloud Traffic Engineer – Google Espresso Project  by Shaowen Ma
Cloud Traffic Engineer – Google Espresso Project by Shaowen Ma
 
Routing Security in 2017 – We can do better!
Routing Security in 2017 – We can do better!Routing Security in 2017 – We can do better!
Routing Security in 2017 – We can do better!
 
T4 Handout3
T4 Handout3T4 Handout3
T4 Handout3
 
MANRS for Network Operators
MANRS for Network OperatorsMANRS for Network Operators
MANRS for Network Operators
 
Computer network (14)
Computer network (14)Computer network (14)
Computer network (14)
 
ISP Border Definition
ISP Border DefinitionISP Border Definition
ISP Border Definition
 
Dynamische Routingprotokolle Aufzucht und Pflege - BGP
Dynamische Routingprotokolle Aufzucht und Pflege - BGPDynamische Routingprotokolle Aufzucht und Pflege - BGP
Dynamische Routingprotokolle Aufzucht und Pflege - BGP
 
Operationalizing BGP in the SDDC
Operationalizing BGP in the SDDCOperationalizing BGP in the SDDC
Operationalizing BGP in the SDDC
 
Rapid Detection of BGP Anomalies
Rapid Detection of BGP AnomaliesRapid Detection of BGP Anomalies
Rapid Detection of BGP Anomalies
 
CCNAS :Multi Area OSPF
CCNAS :Multi Area OSPFCCNAS :Multi Area OSPF
CCNAS :Multi Area OSPF
 
Bgp 1232073634451868-3
Bgp 1232073634451868-3Bgp 1232073634451868-3
Bgp 1232073634451868-3
 
Securing Routing Protocol BGP
Securing Routing Protocol BGPSecuring Routing Protocol BGP
Securing Routing Protocol BGP
 
BGP
BGPBGP
BGP
 
IPv6 Security Overview by QS Tahmeed, APNIC RCT
IPv6 Security Overview by QS Tahmeed, APNIC RCTIPv6 Security Overview by QS Tahmeed, APNIC RCT
IPv6 Security Overview by QS Tahmeed, APNIC RCT
 
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS Poisoning
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS PoisoningMonitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS Poisoning
Monitoring for Network Security: BGP Hijacks, DDoS Attacks and DNS Poisoning
 

Recently uploaded

Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfngoud9212
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdf
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 

NSC #2 - D3 04 - Guillaume Valadon & Nicolas Vivet - Detecting BGP hijacks

  • 1. Detecting BGP hijacks in 2014 Guillaume Valadon & Nicolas Vivet Agence nationale de la sécurité des systèmes d’information http://www.ssi.gouv.fr/en NSC - November 21th, 2014 ANSSI - Detecting BGP hijacks in 2014 1/52
  • 2. BGP Hijacking for Cryptocurrency Profit Reported by Dell SecureWorks on August 7 2014 « From February to May 2014, an hijacker redirected cryptocurrency miners to his own mining pool, earning an estimated $83,000. » Attack Requirements • no authentication between a miner and its bitcoin pool • traffic redirection using BGP prefixes hijacks ANSSI - Detecting BGP hijacks in 2014 2/52
  • 4. What is BGP (Border Gateway Protocol) ? It is the routing protocol used by all Internet operators. Some BGP facts • it runs on 179/TCP • it informs that an operator is in charge of IP prefixes • there is no guarantee that an operator is lying ANSSI - Detecting BGP hijacks in 2014 4/52
  • 5. What is BGP (Border Gateway Protocol) ? It is the routing protocol used by all Internet operators. Some BGP facts • it runs on 179/TCP • it informs that an operator is in charge of IP prefixes • there is no guarantee that an operator is lying • it interconnects all Internet operators ANSSI - Detecting BGP hijacks in 2014 4/52
  • 6. What is BGP (Border Gateway Protocol) ? It is the routing protocol used by all Internet operators. Some BGP facts • it runs on 179/TCP • it informs that an operator is in charge of IP prefixes • there is no guarantee that an operator is lying • it interconnects all Internet operators ANSSI - Detecting BGP hijacks in 2014 4/52
  • 7. What is BGP (Border Gateway Protocol) ? It is the routing protocol used by all Internet operators. Some BGP facts • it runs on 179/TCP • it informs that an operator is in charge of IP prefixes • there is no guarantee that an operator is lying • it interconnects all Internet operators ANSSI - Detecting BGP hijacks in 2014 4/52
  • 8. What Do You Need to Use BGP ? • a network AS42 ANSSI - Detecting BGP hijacks in 2014 5/52
  • 9. What Do You Need to Use BGP ? • a network • an AS number that identifies your network • an IP prefix AS42AS42 2.0.0.0/16 ANSSI - Detecting BGP hijacks in 2014 5/52
  • 10. What Do You Need to Use BGP ? • a network • an AS number that identifies your network • an IP prefix • a BGP router AS42AS42 2.0.0.0/16 ANSSI - Detecting BGP hijacks in 2014 5/52
  • 11. What Do You Need to Use BGP ? • a network • an AS number that identifies your network • an IP prefix • a BGP router • a BGP interconnection AS transit ISP providing BGP InternetAS42AS42 2.0.0.0/16 ANSSI - Detecting BGP hijacks in 2014 5/52
  • 12. Internet Resources Allocation AS & prefixes are allocated by Regional Internet Registry: Europe Asia Africa North America Latin America & Caribbean In Europe, per year, an ASN costs 50€ and a /22 50€. ANSSI - Detecting BGP hijacks in 2014 6/52
  • 13. Access to Internet Resources Allocation The WHOIS protocol $ whois AS4713 aut-num: AS4713 as-name: OCN descr: NTT Communications Corporation [..] country: JP admin-c: AY1361JP tech-c: TT10660JP tech-c: TT15086JP changed: apnic-ftp@nic.ad.jp 19960911 changed: apnic-ftp@nic.ad.jp 20091113 source: JPNIC ANSSI - Detecting BGP hijacks in 2014 7/52
  • 14. Access to Internet Resources Allocation https://stat.ripe.net ANSSI - Detecting BGP hijacks in 2014 8/52
  • 15. AS Announces & Removes Prefixes With BGP, an operator uses: InternetAS43515 AS4713 AS3215 208.117.252.0/22 61.28.192.0/24 2.0.0.0/16 ANSSI - Detecting BGP hijacks in 2014 9/52
  • 16. AS Announces & Removes Prefixes With BGP, an operator uses: • UPDATE messages to announce its IP prefixes InternetAS43515 AS4713 AS3215 208.117.252.0/22 61.28.192.0/24 2.0.0.0/16 208.117.252.0/22 61.28.192.0/24 2.0.0.0/16 ANSSI - Detecting BGP hijacks in 2014 9/52
  • 17. AS Announces & Removes Prefixes With BGP, an operator uses: • UPDATE messages to announce its IP prefixes • WITHDRAW messages to remove its IP prefixes InternetAS43515 AS4713 AS3215 208.117.252.0/22 61.28.192.0/24 2.0.0.0/16 208.117.252.0/22 61.28.192.0/24 2.0.0.0/16208.117.252.0/22 208.117.252.0/22 ANSSI - Detecting BGP hijacks in 2014 9/52
  • 18. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 Internet ANSSI - Detecting BGP hijacks in 2014 10/52
  • 19. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 Internet 192.0.2.0/24 192.0.2.0/24 AS1 BGP ANSSI - Detecting BGP hijacks in 2014 10/52
  • 20. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 Internet 192.0.2.0/24 192.0.2.0/24 192.0.2.0/24 AS1 BGP 192.0.2.0/24 AS1 AS2 BGP ANSSI - Detecting BGP hijacks in 2014 10/52
  • 21. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet 192.0.2.0/24 AS1 192.0.2.0/24 AS1 AS3 BGP ANSSI - Detecting BGP hijacks in 2014 10/52
  • 22. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet 192.0.2.0/24 AS1 192.0.2.0/24 AS1 AS3 BGP 192.0.2.0/24 AS1 192.0.2.0/24 AS1 AS3 BGP 192.0.2.0/24 AS1 AS2 BGP 192.0.2.0/24 ANSSI - Detecting BGP hijacks in 2014 10/52
  • 23. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet ANSSI - Detecting BGP hijacks in 2014 10/52
  • 24. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet 192.0.0.0/16 192.0.2.0/24 ANSSI - Detecting BGP hijacks in 2014 10/52
  • 25. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet 192.0.0.0/16 192.0.2.0/24 192.0.0.0/16 AS4 AS1 192.0.2.0/24 AS3 AS1 BGP ANSSI - Detecting BGP hijacks in 2014 10/52
  • 26. Three Simple BGP Rules 1. messages are forwarded to neighbors, after adding the ASN 2. only the shortest AS path is forwarded 3. packets are sent to the most specific prefix AS1 AS2 AS3 AS4 Internet 192.0.0.0/16 192.0.2.0/24 192.0.0.0/16 AS4 AS1 192.0.2.0/24 AS3 AS1 BGP 192.0.0.0/16 AS4 AS1 192.0.2.0/24 AS3 AS1 BGP 192.0.2.42 ANSSI - Detecting BGP hijacks in 2014 10/52
  • 28. What is a Prefix Hijack? BGP rule #2 in action An hijack is a conflicting BGP announcement. AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 AS1 AS0 BGP ANSSI - Detecting BGP hijacks in 2014 12/52
  • 29. What is a Prefix Hijack? BGP rule #2 in action An hijack is a conflicting BGP announcement. AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 BGP ANSSI - Detecting BGP hijacks in 2014 12/52
  • 30. What is a Prefix Hijack? BGP rule #2 in action An hijack is a conflicting BGP announcement. AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 BGP 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 BGP Rule #2 applies: traffic is redirected to AS3 ! ANSSI - Detecting BGP hijacks in 2014 12/52
  • 31. Active Countermeasure Use BGP rule #3 ! AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 BGP The origin AS announces more specific prefixes. ANSSI - Detecting BGP hijacks in 2014 13/52
  • 32. Active Countermeasure Use BGP rule #3 ! AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 192.0.2.0/24 192.0.3.0/24 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 192.0.2.0/24 AS1 AS0 192.0.3.0/24 AS1 AS0 BGP The origin AS announces more specific prefixes. ANSSI - Detecting BGP hijacks in 2014 13/52
  • 33. Active Countermeasure Use BGP rule #3 ! AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 192.0.2.0/24 192.0.3.0/24 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 192.0.3.0/24 AS1 AS0 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 192.0.2.0/24 AS1 AS0 192.0.3.0/24 AS1 AS0 BGP The origin AS announces more specific prefixes. ANSSI - Detecting BGP hijacks in 2014 13/52
  • 34. Active Countermeasure Use BGP rule #3 ! AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 192.0.2.0/24 192.0.3.0/24 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 192.0.3.0/24 AS1 AS0 192.0.2.0/23 AS1 AS0 192.0.2.0/23 AS3 192.0.2.0/24 AS1 AS0 192.0.3.0/24 AS1 AS0 BGP The origin AS announces more specific prefixes. Rule #3 applies: traffic is sent to AS0 ! ANSSI - Detecting BGP hijacks in 2014 13/52
  • 35. A Recent Example on October 16 Hijack against a French AS x ANSSI - Detecting BGP hijacks in 2014 14/52
  • 36. A Recent Example on October 16 Hijack against a French AS ANSSI - Detecting BGP hijacks in 2014 14/52
  • 37. Passive Countermeasure Strict filter on an interconnection AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23 64501 64500 BGP • a BGP router can filter prefix in UPDATE messages • useful filtering can only be done by the upstream provider ANSSI - Detecting BGP hijacks in 2014 15/52
  • 38. Passive Countermeasure Strict filter on an interconnection AS0 AS1 AS2 AS3 192.0.2.0/23 192.0.2.0/23192.0.2.0/23 64501 64500 BGP • a BGP router can filter prefix in UPDATE messages • useful filtering can only be done by the upstream provider ANSSI - Detecting BGP hijacks in 2014 15/52
  • 39. Passive Countermeasure Automate filter maintenance A route object: • is declared by the AS in charge of an IP prefix • tells who can announce the prefix with BGP • the operator, its DDoS mitigation provider, its clients, … $ whois -T route 185.50.64.0/22 route: 185.50.64.0/22 descr: Observatory IPv4 prefix. origin: AS202214 mnt-by: ASOBS-MNT source: RIPE # Filtered ANSSI - Detecting BGP hijacks in 2014 16/52
  • 41. BGP messages ANSSI - Detecting BGP hijacks in 2014 18/52
  • 42. Collecting BGP Archives https://www.ris.ripe.net AS1 AS2 AS3 AS4 AS5 AS6 AS666 192.168.0.0/16 192.168.0.0/24 BGP collector Routing Information Service (RIS) • 13 BGP collectors all over the world • 263 BGP peers • BGP messages dumped into binary files • 550 GB per year ANSSI - Detecting BGP hijacks in 2014 19/52
  • 43. Parsing BGP Archives https://github.com/ANSSI-FR/parsifal Raw BGP BGP parser Need for a dedicated BGP parser • fast & trusted parser • written in OCaml • convert BGP messages to JSON • human readable / writable format ANSSI - Detecting BGP hijacks in 2014 20/52
  • 44. Parsing BGP Archives https://github.com/ANSSI-FR/parsifal { "timestamp":1409750436, "collector": "rrc07", "as_path":"25152 6939 17922 7862 4761 9957 7500 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } { "timestamp":1409782437, "collector": "rrc07", "as_path":"25152 6939 667 666 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } Need for a dedicated BGP parser • fast & trusted parser • written in OCaml • convert BGP messages to JSON • human readable / writable format ANSSI - Detecting BGP hijacks in 2014 20/52
  • 45. Parsing BGP Archives https://github.com/ANSSI-FR/parsifal { "timestamp":1409750436, "collector": "rrc07", "as_path":"25152 6939 17922 7862 4761 9957 7500 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } { "timestamp":1409782437, "collector": "rrc07", "as_path":"25152 6939 667 666 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } Need for a dedicated BGP parser • fast & trusted parser • written in OCaml • convert BGP messages to JSON • human readable / writable format ANSSI - Detecting BGP hijacks in 2014 20/52
  • 46. Parsing BGP Archives https://github.com/ANSSI-FR/parsifal { "timestamp":1409750436, "collector": "rrc07", "as_path":"25152 6939 17922 7862 4761 9957 7500 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } { "timestamp":1409782437, "collector": "rrc07", "as_path":"25152 6939 667 666 ", "announce":[" 192.50.44.0/24 "], "withdraw":[] } Need for a dedicated BGP parser • fast & trusted parser • written in OCaml • convert BGP messages to JSON • human readable / writable format ANSSI - Detecting BGP hijacks in 2014 20/52
  • 47. Emulating a BGP Router https://code.google.com/p/py-radix/ 192.0.0.0/8 AS1 192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5 192.160.0.0/11 AS7 192.168.128.0/22 AS42 Build the routing table • fast IP lookup library • similar to a router & the Linux kernel • the tree is updated with each BGP messages • duplicated entries are conflicts ANSSI - Detecting BGP hijacks in 2014 21/52
  • 48. Emulating a BGP Router https://code.google.com/p/py-radix/ 192.0.0.0/8 AS1 192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5 192.160.0.0/11 AS7 192.168.128.0/22 AS42 Processing an UPDATE message { "timestamp":1409750436, "peer_as":25152, "as_path":"1234 666 ", "announce":[" 192.168.128.0/24 "], "withdraw":[] } ANSSI - Detecting BGP hijacks in 2014 21/52
  • 49. Emulating a BGP Router https://code.google.com/p/py-radix/ 192.0.0.0/8 AS1 192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5 192.160.0.0/11 AS7 192.168.128.0/22 AS42 Processing an UPDATE message { "timestamp":1409750436, "peer_as":25152, "as_path":"1234 666 ", "announce":[" 192.168.128.0/24 "], "withdraw":[] } ANSSI - Detecting BGP hijacks in 2014 21/52
  • 50. Emulating a BGP Router https://code.google.com/p/py-radix/ 192.0.0.0/8 AS1 192.28.0.0/22 AS2 AS3 192.128.0.0/10 AS4 AS5 192.160.0.0/11 AS7 192.168.128.0/22 AS42 Processing an UPDATE message { "timestamp":1409750436, "peer_as":25152, "as_path":"1234 666 ", "announce":[" 192.168.128.0/24 "], "withdraw":[] } ANSSI - Detecting BGP hijacks in 2014 21/52
  • 51. Putting Everything Together Raw BGP BGP parser Emulate BGP { } JSON Processing 50k ASes • emulated routers handle different AS • with 8 cores, a month is processed in 10 hours With 13 collectors, 156 months must be processed per year ! ANSSI - Detecting BGP hijacks in 2014 22/52
  • 52. Faster Conflicts Detection Scaling by adding cores Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Conflicts detection • completes in one week with 120 cores on 5 servers • generates 130 GB per year • 11 536 345 959 conflicts • from January to October 2014 ANSSI - Detecting BGP hijacks in 2014 23/52
  • 53. Faster Conflicts Detection Scaling by adding cores Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Raw BGP BGP parser Emulate BGP { } JSON Conflict example { "timestamp":1409782437, "collector": "rrc07", "announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 , "as_path": "25152 6939 667 666"}, "conflict_with": {"prefix": " 192.50.44.0/24 ", "asn": 7500 }} ANSSI - Detecting BGP hijacks in 2014 23/52
  • 54. Accessing The Data http://discoproject.org Disco? • automatic data distribution & replication • like HDFS • MapReduce framework in Python • like Hadoop ANSSI - Detecting BGP hijacks in 2014 24/52
  • 55. Accessing The Data http://discoproject.org From BIG DATA to small data • one hour to extract conflicts targeting 1000 ASes • close to the number of French & Japanese ASes • 70 millions conflicts per country • 200MB ANSSI - Detecting BGP hijacks in 2014 24/52
  • 56. Classifying Conflicts - 1/3 Using route objects Validating a single conflict { "timestamp": 1409782437, "collector": "rrc07", "announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 , "as_path": "25152 6939 667 666"}, "conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}} ANSSI - Detecting BGP hijacks in 2014 25/52
  • 57. Classifying Conflicts - 1/3 Using route objects Validating a single conflict { "timestamp": 1409782437, "collector": "rrc07", "announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 , "as_path": "25152 6939 667 666"}, "conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}} $ whois -T route 192.50.44.0/24 route: 192.50.44.0/24 descr: Example prefix origin: AS666 mnt-by: AS666-MNT ANSSI - Detecting BGP hijacks in 2014 25/52
  • 58. Classifying Conflicts - 1/3 Using route objects Validating a single conflict { "timestamp": 1409782437, "collector": "rrc07", "announce": { "prefix": " 192.50.44.0/24 ", "asn": 666 , "as_path": "25152 6939 667 666"}, "conflict_with": {"prefix": "192.50.44.0/24", "asn": 7500}} $ whois -T route 192.50.44.0/24 route: 192.50.44.0/24 descr: Example prefix origin: AS666 mnt-by: AS666-MNT ANSSI - Detecting BGP hijacks in 2014 25/52
  • 59. Classifying Conflicts - 1/3 Using route objects Validating 70 millions conflicts • all of them must be verified • online queries are too slow • WHOIS databases are loaded daily into PostgreSQL • the ip4r type is used for fast prefix lookups >>> client = Client("ripe") >>> client.check("210.158.206.0/24", 17676, "2014/07/28") True 0.01% conflicts removed 32% conflicts removed ANSSI - Detecting BGP hijacks in 2014 25/52
  • 60. Classifying Conflicts - 2/3 Using relations between AS objects $ whois AS15557 aut-num: AS15557 as-name: LDCOMNET descr: SFR org: ORG-LA7-RIPE admin-c: LD699-RIPE tech-c: LDC76-RIPE status: ASSIGNED mnt-by: LDCOM-MNT mnt-routes: FMCF-MNT mnt-routes: LDCOM-MNT source: RIPE $ whois AS41272 aut-num: AS41272 as-name: MOSELLE-TELE-AS descr: MOSELLE TELECOM org: ORG-MT18-RIPE admin-c: LD699-RIPE tech-c: LDC76-RIPE status: ASSIGNED mnt-by: MOSELLE-TELE-MNT mnt-routes: MOSELLE-TELE-MNT source: RIPE 2% conflicts removed 54% conflicts removed ANSSI - Detecting BGP hijacks in 2014 26/52
  • 61. Classifying Conflicts - 3/3 Using client/provider connectivity { "timestamp": 1409750436, "announce": { "prefix": "192.0.2.0/24", "asn": 666, "as_path": "... 1000 666" }, "conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } } ANSSI - Detecting BGP hijacks in 2014 27/52
  • 62. Classifying Conflicts - 3/3 Using client/provider connectivity { "timestamp": 1409750436, "announce": { "prefix": "192.0.2.0/24", "asn": 666, "as_path": "... 1000 666" }, "conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } } Internet AS1000 AS666 192.0.0.0/16 1000 192.0.2.0/24 1000 666 BGP ANSSI - Detecting BGP hijacks in 2014 27/52
  • 63. Classifying Conflicts - 3/3 Using client/provider connectivity { "timestamp": 1409750436, "announce": { "prefix": "192.0.2.0/24", "asn": 666, "as_path": "... 1000 666" }, "conflict_with": {"prefix": "192.0.0.0/16", "asn": 1000 } } Client/Provider relation Internet AS1000 AS666 192.0.0.0/16 1000 192.0.2.0/24 1000 666 BGP 5% conflicts removed 3% conflicts removed ANSSI - Detecting BGP hijacks in 2014 27/52
  • 64. Classifying conflicts Summary Validated Related Connected Abnormal 0 % 30 % 60 % 90 % 32 54 3 11 0 2 5 93 Percentageofconflicts France Japan 42 millions abnormal conflicts 8 millions abnormal conflicts ANSSI - Detecting BGP hijacks in 2014 28/52
  • 65. Computing durations From conflicts to events Time | | | | | | | | | | | | Before aggregation { "timestamp": 20141111.0, "collector": "rrc99" , "type": "RELATION", "announce": { "prefix": "1.6.28.0/24", "asn": 666 } "conflict_with": {"prefix": "1.6.0.0/18", "asn": 1000 } } { "timestamp": 20141231.0, "collector": "rrc66" , type": "RELATION", "announce": { "prefix": "1.6.28.0/24", "asn": 666 } "conflict_with": {"prefix": "1.6.0.0/18", "asn": 1000 } } ANSSI - Detecting BGP hijacks in 2014 29/52
  • 66. Computing durations From conflicts to events Time | | | | | | | | | | | | After aggregation { "conflict_with" : { "prefix" : "1.6.0.0/18", "asn" : 1000 }, "origin" : { "prefix" : "1.6.28.0/24", "asn" : 666 }, "begin": 20141111.0, "end" : 20141231.0, "peers" : [ "rrc99", "rrc66" ], "type" : "RELATION" } 74 084 events 73 902 events ANSSI - Detecting BGP hijacks in 2014 29/52
  • 67. Events Visualization A French AS 10/28/2014 localhost:2807/timeslots/AS3215 2014 February March April May June July August September October No ANSSI - Detecting BGP hijacks in 2014 30/52
  • 68. Reducing The Number of Events Automatically Simple rules • remove events that change categories • remove events if ASes belongs to the same country • remove events longer than 6 months • remove associated events From 2154 prefixes in conflict to 557 From 4519 prefixes in conflict to 289 ANSSI - Detecting BGP hijacks in 2014 31/52
  • 69. Looking For Hijacks ANSSI - Detecting BGP hijacks in 2014 32/52
  • 70. Reducing The Number of Events Manually Interesting results • similar AS names • PACNET-MY Pacnet MY and PACNET Pacnet Global Ltd • AS under DDoS protection • the DDoS mitigation companies announces /24 • typos in AS numbers • 2208 and 208 • hijacks that were used to steal bitcoins • AS18863 was at the origin of some of these hijacks • some events were never detected by operators • ... ANSSI - Detecting BGP hijacks in 2014 33/52
  • 71. Closing Remarks Since January 2014, there are: 69 suspicious events 102 suspicious events Around 10 hijacks per year target French operators ANSSI - Detecting BGP hijacks in 2014 34/52
  • 72. Real-time BGP Hijack Detection
  • 73. Targeted Internet Traffic Misdirection Reported by Renesys on November, 2013 ANSSI - Detecting BGP hijacks in 2014 36/52
  • 74. Real-time Detection Goals BGP messages Hijacks Alerts Measurements ANSSI - Detecting BGP hijacks in 2014 37/52
  • 75. Detection Requirements https://github.com/spotify/luigi Fetching Tasks • Internet registries • raw BGP data ANSSI - Detecting BGP hijacks in 2014 38/52
  • 76. Detection Requirements https://github.com/spotify/luigi { } Fetching Tasks • Internet registries • raw BGP data Processing Tasks • synchronise whois databases • parse BGP data to JSON • create IP prefix to origin AS mapping ANSSI - Detecting BGP hijacks in 2014 38/52
  • 77. BGP Hijack Reporting What must be reported • only suspicious BGP hijacks • about 50 events per week ANSSI - Detecting BGP hijacks in 2014 39/52
  • 78. BGP Hijack Reporting IRC is so 2014 What must be reported • only suspicious BGP hijacks • about 50 events per week < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) ANSSI - Detecting BGP hijacks in 2014 39/52
  • 79. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) ANSSI - Detecting BGP hijacks in 2014 40/52
  • 80. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) $ whois 2a04:8000::/29 inet6num: 2a04:8000::/29 netname: UA-UAHOSTING descr: Hosting Ukraine country: UA org: ORG-HUL6-RIPE ANSSI - Detecting BGP hijacks in 2014 40/52
  • 81. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) $ whois 2a04:8000::/29 inet6num: 2a04:8000::/29 netname: UA-UAHOSTING descr: Hosting Ukraine country: UA org: ORG-HUL6-RIPE $ whois -i org ORG-HUL6-RIPE ANSSI - Detecting BGP hijacks in 2014 40/52
  • 82. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) $ whois 2a04:8000::/29 inet6num: 2a04:8000::/29 netname: UA-UAHOSTING descr: Hosting Ukraine country: UA org: ORG-HUL6-RIPE $ whois -i org ORG-HUL6-RIPE aut-num: AS200000 as-name: Ukraine-AS descr: Hosting Ukraine org: ORG-HUL6-RIPE ANSSI - Detecting BGP hijacks in 2014 40/52
  • 83. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) $ whois 2a04:8000::/29 inet6num: 2a04:8000::/29 netname: UA-UAHOSTING descr: Hosting Ukraine country: UA org: ORG-HUL6-RIPE $ whois -i org ORG-HUL6-RIPE aut-num: AS200000 as-name: Ukraine-AS descr: Hosting Ukraine org: ORG-HUL6-RIPE ANSSI - Detecting BGP hijacks in 2014 40/52
  • 84. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) Analysis Result • 2a04:8000::/29 belongs to the Ukrainian operator ANSSI - Detecting BGP hijacks in 2014 41/52
  • 85. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) Analysis Result • 2a04:8000::/29 belongs to the Ukrainian operator • 2a04:0800::/29 belongs to the French operator • French operator made a mistake in its BGP configuration ANSSI - Detecting BGP hijacks in 2014 41/52
  • 86. BGP Hijack Troubleshooting < hadron> 2a04:8000::/29 is announced from multiple origins: < hadron> SFR-BUSINESS-TEAM (AS12566) < hadron> Ukraine-AS (AS200000) < hadron> First originated from SFR-BUSINESS-TEAM (AS12566) Analysis Result • 2a04:8000::/29 belongs to the Ukrainian operator • 2a04:0800::/29 belongs to the French operator • French operator made a mistake in its BGP configuration It was a false positive, the route6 object was created a few days later by the Ukrainian operator. ANSSI - Detecting BGP hijacks in 2014 41/52
  • 87. Malicious BGP Hijack < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) ANSSI - Detecting BGP hijacks in 2014 42/52
  • 88. https://stat.ripe.net/AS198596 Announces from September to October 2014 ANSSI - Detecting BGP hijacks in 2014 43/52
  • 89. Malicious BGP Hijack Infected AS_PATH < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 ANSSI - Detecting BGP hijacks in 2014 44/52
  • 90. Malicious BGP Hijack Infected AS_PATH < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 Definition • infected ASes accepted the hijacking BGP update • traffic to the hijacked prefix go to the hijacker’s network ANSSI - Detecting BGP hijacks in 2014 44/52
  • 91. Malicious BGP Hijack Infected AS_PATH < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 Definition • infected ASes accepted the hijacking BGP update • traffic to the hijacked prefix go to the hijacker’s network How do we launch active measurements from these ASes? ANSSI - Detecting BGP hijacks in 2014 44/52
  • 92. RIPE Atlas Measurement Project https://atlas.ripe.net/ • 7100 probes in around 2000 ASes • probes hosted by the community • user-defined measurements • ping, traceroute, HTTP, TLS and DNS • public API ANSSI - Detecting BGP hijacks in 2014 45/52
  • 93. ANSSI - Detecting BGP hijacks in 2014 46/52
  • 94. Atlas Meets Our Needs We always found a probe to launch our measurements! • 250 possible hijacks from september to november 2014 • AS_PATH are from the London based RIPE collector ANSSI - Detecting BGP hijacks in 2014 47/52
  • 95. Atlas Meets Our Needs We always found a probe to launch our measurements! • 250 possible hijacks from september to november 2014 • AS_PATH are from the London based RIPE collector Number of probes found in infected ASes: 2 4 6 8 10 12 14 0 % 5 % 10 % 15 % 20 % Num of probes Hijacks ANSSI - Detecting BGP hijacks in 2014 47/52
  • 96. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 ANSSI - Detecting BGP hijacks in 2014 48/52
  • 97. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 ANSSI - Detecting BGP hijacks in 2014 48/52
  • 98. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 Traceroute to 185.73.204.1 ANSSI - Detecting BGP hijacks in 2014 48/52
  • 99. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 Traceroute to 185.73.204.1 ANSSI - Detecting BGP hijacks in 2014 48/52
  • 100. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 1. 10.10.10.1 2. 82.118.96.1 3. 188.124.228.1 4. 95.215.3.78 5. * * * ANSSI - Detecting BGP hijacks in 2014 48/52
  • 101. Traceroute Example < hadron> 185.73.204.0/22 is announced from multiple origins: < hadron> ALPHALINK-AS (AS25540) < hadron> TEHNOGRUP (AS198596) < hadron> AS_PATH: 8607 39792 44050 131788 198596 Closing Remarks • traceroute stops at AS44050 (PIN-AS) • AS131788 and AS198596 are most certainly placeholders • AS44050 (PIN-AS) is already known for previous hijacks ANSSI - Detecting BGP hijacks in 2014 49/52
  • 103. Conclusion • wide scale BGP hijacks automatic detection • only a few real hijacks per year regarding France and Japan • early detection and reporting • on-going work to identify traffic redirection Take away messages 1. packets can be redirected on the Internet 2. traffic must be encrypted and authenticated 3. monitor prefixes and be ready to send more specific ones 4. networking Best Current Practices must be enforced ANSSI - Detecting BGP hijacks in 2014 51/52
  • 104. Questions? A question == A Japanese Kit Kat Related publication • BGP configuration best practices (English & French) ANSSI - Detecting BGP hijacks in 2014 52/52