NARCOS, COUNTERFEITERS & SCAMMERS

46
NARCOS, COUNTERFEITERS & SCAMMERS An Approach to Visualize Illegal Markets using pDNS

Transcript of NARCOS, COUNTERFEITERS & SCAMMERS

Page 1: NARCOS, COUNTERFEITERS & SCAMMERS

NARCOS, COUNTERFEITERS & SCAMMERS

An Approach to

Visualize I l legal Markets using pDNS

Page 2: NARCOS, COUNTERFEITERS & SCAMMERS

Andrew Lewman

• Farsight Security CRO

• Renown cybersecurity and privacy expert

• Tor Project, CEO

Stevan Keraudy

• CybelAngel CTO

• MSc in Machine Learning and Data Mining

Introduction

Page 3: NARCOS, COUNTERFEITERS & SCAMMERS

Threat Landscape is vast and growing

……

..

2005

2016

Page 4: NARCOS, COUNTERFEITERS & SCAMMERS

In the beginning

Nearly every online transaction – good or bad -- begins with a DNS lookup

IPs or domain names provide a starting point

and initial clue to the crime

DNS Server

www.example.net

1.2.3.4

Browser

Page 5: NARCOS, COUNTERFEITERS & SCAMMERS

Classical approach

Zone File Analysis

Lots of Limitations

12 root servers

CCTLDgTLD

com,org,edu…us, de, jp…

example1.com

example2.org

example3.edu

example3.jp

example2.de

example1.us

Page 6: NARCOS, COUNTERFEITERS & SCAMMERS

Pulling back the curtains

Not interested in long-lived domain names

Domains are “free” & short-lived assets; using 100s/day

AND…there's free domain/free subdomain/free domain name redirection services out there...

Page 7: NARCOS, COUNTERFEITERS & SCAMMERS

What is Passive DNS

Recursive

Servers

Authority Servers

FARSIGHT

SECURITY

DNS Cache

Sensors

PII

Browsers

Mobile

IOT

Observations of global Domain to IP address

transaction flows

Visibility into the evolving configurations of

the DNS

Collection of query-answer pairs as detected

on recursive name servers –

NO Personally Identifiable Information(PII)

Is most valuable when collected and

published in real-time

200,000

Observations/sec

ond

13+ Billion

Domains

Real-time

Page 8: NARCOS, COUNTERFEITERS & SCAMMERS

Whis is pDNS useful ?

Discover

associations

among threat

actors in

real-time

Perform risk

assessment of

domain names

& IPs

Reveal IPs

used to

conceal activity

to avoid

takedowns

Accelerate

incident

research

Uncover all

domains using

the same

name servers

Conduct third-

party audits of

DNS

configurations

Page 9: NARCOS, COUNTERFEITERS & SCAMMERS

Passive DNS: unmatched visibility

Farsight Security partner, CybelAngel, will illustrate how

passive DNS is used to expose narcos, counterfeiters and

scammers

Page 10: NARCOS, COUNTERFEITERS & SCAMMERS

Methodology

ThreatsVisualization

pDNS

A process to convert a passive DNS data feedinto a human-readable visualization the threats.

Detection FeatureExtraction

Clustering

Page 11: NARCOS, COUNTERFEITERS & SCAMMERS

Technical stack

Doing magic with Redis

- Key-value store for multi-process-communication

- DIY message broker and load balancer

- Real-time events and statistics

available at redis.io

Page 12: NARCOS, COUNTERFEITERS & SCAMMERS

Passive DNS

Example of a Resource Record set :

{count: 1, time_first: 1398714180, time_last: 1398714182, rrname: “cybelangel.com.",rrtype: "A", rdata: ["91.xxx.xxx.xxx"]}

{count: 1, time_first: 1349432137, time_last: 1349432143, rrname: “cybelangel.com.",rrtype: "A", rdata: ["94.xxx.xxx.xxx"]}

5,000 RRset/sFiltered RRsetpDNS

Detection

Page 13: NARCOS, COUNTERFEITERS & SCAMMERS

Brand-specific filtering

Narcos Counterfeiters Scammers

Page 14: NARCOS, COUNTERFEITERS & SCAMMERS

Generic keyword filtering

cheap replica watches swiss brand

cheap replica designer luxury handbags

cheap marijuana

cheap cialis online

Page 15: NARCOS, COUNTERFEITERS & SCAMMERS

Filtering Passive DNS

Perfect Matching (quick & easy)secure.cybelangelcom.cyberthreatintelfeed.biz

Fuzzy matching (time-consuming & difficult)sybelangel.org.me cybellangel.ir mycybe1angel.ua

200µs to match a RRset

Page 16: NARCOS, COUNTERFEITERS & SCAMMERS

Solving the fuzzy matching problem

Pre-generate DNS variations

and run a perfect match

Awesome project by

Addition cybelangell.comBitsquatting cybelangen.comHomoglyph cybe1angel.comInsertion cybelangwel.comOmission cybelanel.comRepetition cybellangel.comReplacement cybelangrl.comSubdomain cy.belangel.comTransposition cybelanegl.comVarious wwwcybelangel.comVarious cybelangelcom.com

DNSTwists ofcybelangel.com

elceef/dnstwist

50 filtered RRsets/s (99.0% reduction)

5,000 RRset/s

Detection

Page 17: NARCOS, COUNTERFEITERS & SCAMMERS

In-depth analysis pipe50 filtered RRset/s (type A)

Keyword Matching

GET /

WHOIS

Email

Tel numbers

Analytics ID

Banking ID

Geolocation

Feature Extraction

Website ID card

Page 18: NARCOS, COUNTERFEITERS & SCAMMERS

Feature extraction

Page 19: NARCOS, COUNTERFEITERS & SCAMMERS

Feature extraction

Page 20: NARCOS, COUNTERFEITERS & SCAMMERS

Clustering – Why ?

Problem

Taking down 1000s of websites one-by-one is costly and inefficient

Solution

• Clustering websites belonging to the same actor

• Ranking them using traffic estimation

Clustering

Page 21: NARCOS, COUNTERFEITERS & SCAMMERS

Clustering – How?

Use the extracted features for clustering

Hypothesis :

This looks like an Unsupervised Machine Learningproblem.

The more features two website share,the more likely they belong to the same

actor.

Page 22: NARCOS, COUNTERFEITERS & SCAMMERS

Clustering – The unsupervised learning approach

We tried several algorithms :

• K-Means

• Hierarchical Clustering

Problems:

• Unknown number of clusters

• Definition of a distance

→ Find a representation that is :

• Human Readable

• Machine Readable

Page 23: NARCOS, COUNTERFEITERS & SCAMMERS

Clustering – The graph approach

We tried another approach :

Advantages

• No vectorization needed

• A natural representation of linked websites

• Human readable visualization

Graphs

Page 24: NARCOS, COUNTERFEITERS & SCAMMERS

Gephi

Gephi is a visualization and exploration software for graphs.It is open source (GPLv3) and available at gephi.org.

Page 25: NARCOS, COUNTERFEITERS & SCAMMERS

Network spatialization with Force Atlas 2

Page 26: NARCOS, COUNTERFEITERS & SCAMMERS

Network spatialization with Force Atlas 2

Page 27: NARCOS, COUNTERFEITERS & SCAMMERS

Network spatialization with Force Atlas 2

Page 28: NARCOS, COUNTERFEITERS & SCAMMERS

Network spatialization with Force Atlas 2

Page 29: NARCOS, COUNTERFEITERS & SCAMMERS

Naive graph construction

• Node = website

• Edge = common feature shared by 2 websites

• Edge weight = Number of features in common

Page 30: NARCOS, COUNTERFEITERS & SCAMMERS

Naive graph construction

Pros

• Nodes represents homogeneous data (every node is a website)

• Clusters tend to be dense, so easily spotted by computing modularity classes

Cons

• Cluster density leads to heavy graphs (worst-case: O(n²) edges)

• Difficult to see the relationship behind edges

Page 31: NARCOS, COUNTERFEITERS & SCAMMERS

A more appropriate representation

• Node = website OR feature

• Edge = feature's presence in the website

• Unweighted edges

• Average: O(n) number of edges

Page 32: NARCOS, COUNTERFEITERS & SCAMMERS

Clusters overview

Page 33: NARCOS, COUNTERFEITERS & SCAMMERS

Ranking threats

Once the clusters are built, it is easy to rank them by number of websites/aggregated traffic. This is a precious information for takedowns.

Page 34: NARCOS, COUNTERFEITERS & SCAMMERS

Looking for a counterfeit luxury watch

We will see how this methodology helped us map the websites selling counterfeit watches of a famous luxury brand.

Page 35: NARCOS, COUNTERFEITERS & SCAMMERS

Filtering pDNS

50,000websites

Page 36: NARCOS, COUNTERFEITERS & SCAMMERS

In-depth analysis

Page 37: NARCOS, COUNTERFEITERS & SCAMMERS

Keyword matching in page content

Page 38: NARCOS, COUNTERFEITERS & SCAMMERS

Feature extraction

Analytics ID

Telephone number

Page 39: NARCOS, COUNTERFEITERS & SCAMMERS

Graph representation

50,000websites

Our guy

Page 40: NARCOS, COUNTERFEITERS & SCAMMERS

Hunting in the graph

Still our guy

Page 41: NARCOS, COUNTERFEITERS & SCAMMERS

Our well-connected guy

Page 42: NARCOS, COUNTERFEITERS & SCAMMERS

It also works with narcotics

Page 43: NARCOS, COUNTERFEITERS & SCAMMERS

A representation of the marijuana business

Page 44: NARCOS, COUNTERFEITERS & SCAMMERS

CybelAngel-Farsight Report: Pick A Side, Pick A Site

Check it outhttp://blog.cybelangel.com/clinton-vs-trump-art-website-war/

https://www.farsightsecurity.com/Blog/20160921-farsight-cybelangel-2016campaign/

Page 45: NARCOS, COUNTERFEITERS & SCAMMERS

Key Takeaways

•Counterfeiting is a significant and growing online

threat

•Current solutions based on zonefiles lack efficiency

•pDNS + Feature Extraction + Graphs can be used to

optimize takedown efforts

•This research could be derived to address other

problems...

Page 46: NARCOS, COUNTERFEITERS & SCAMMERS

Q&A

Special thanks for research assistance to:

Thomas Garnier & Paul Petit

Thank you for your attention.

Free DNSDB Test Drive for Black Hat attendees

Farsightsecurity.com/BHEU