• Aucun résultat trouvé

Transaction clustering using network traffic analysis for Bitcoin and derived blockchains

N/A
N/A
Protected

Academic year: 2021

Partager "Transaction clustering using network traffic analysis for Bitcoin and derived blockchains"

Copied!
30
0
0

Texte intégral

(1)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 1/30

Transaction clustering using network traffic

analysis for Bitcoin and derived blockchains

Alex Biryukov, Sergei Tikhomirov

SnT, University of Luxembourg

(2)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(3)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 3/30

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(4)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Privacy in cryptocurrencies

I Transactions not linked to ”real-world” identity

I False sense of privacy: blockchain can be analyzed

I Taint analysis, various heuristics

I Countermeasures: mixing, cryptography (Monero,

(5)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 5/30

Our focus: network-level privacy

I How do messages propagate through the network?

I What information does the traffic leak?

(6)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(7)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 7/30

Transaction propagation in Bitcoin

I Alice: INV (I know an object with hash H)

I Bob: GETDATA (I want to get this object)

I Alice: TX (Here it is)

(8)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Broadcast randomization

Privacy issue: well-connected adversary infers the original IP. Countermeasures:

I trickling: send to a subset once a period

(9)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 9/30

Previous work

I Biryukov, Khovratovich, Pustogarov (2014)

-”Deanonymisation of clients in Bitcoin P2P network” proposed a method for linking Bitcoin txs to IPs

I Key idea: nodes connect to 8 random ”entry nodes”,

(10)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(11)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 11/30

Understanding relationships between transactions

I Connect to many nodes

I Log timestamps of received tx announcements

I Intuition: we will hear of new txs from Alice or her

(12)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Parallel connections

I Nodes maintain 8 outgoing and 117 (optional) incoming

connections

I Txs propagate to some neighbors with random delays

I If we connect to a node once, the probability of getting

a new tx quickly is low

(13)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 13/30

Saturating connection slots

I bcclient tool connects to Bitcoin nodes with many

parallel connections

I We occupy all available slots (avg 64 slots / peer on

Bitcoin testnet)

I Nodes don’t distinguish incoming and outgoing

(14)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors

Clustering the correlation matrix Metrics Experimental results Discussion Future work

Weighting timing vectors

I Earlier work only considered the first IP to relay a tx

I We consider the vector of the first 3 – 7 IPs to relay a

tx, and assign them exponentially decreasing weights

I High correlation between vectors indicate the same

(15)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors

Clustering the correlation matrix Metrics Experimental results Discussion Future work 15/30

Weighting formula

IPs pi get decreasing weights; median IP gets weight 0.5:

w (pi) = e−(ti/k)

2

where

(16)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors

Clustering the correlation matrix Metrics Experimental results Discussion Future work

Weighting timing vectors: example

High values indicate higher probability of an IP to be the originator or one of its entry nodes.

(17)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors

Clustering the correlation matrix Metrics Experimental results Discussion Future work 17/30

Clustering of vectors

I For each pair of txs, calculate correlation of weight

vectors

I Hypothesis: correlation matrix has a block-diagonal

structure

I Related transactions form clusters along the main

(18)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Measuring clustering quality

Clustering algorithms decides for each pair of txs whether to put them in one cluster. Rand score reflects the share of right decisions:

R = SS + DD

SS + SD + DS + DD where

I SS: same category, same cluster

I DD: different category, different cluster

I SD: same category, different cluster

(19)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 19/30

Measuring anonymity

Anonymity degree measures the amount of information an attacker gains compared to perfect anonymity :

d = −

PN

i =1pilog2(pi)

log2(N)

I d = 1: each user has an equal probability of being the

originator of a given message

I d = 0: the attacker knows exactly the originators of all

(20)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(21)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 21/30

Putting the pieces together

I Connect to many nodes in parallel, log tx

announcements (use geographically distributed servers for better view of the network)

I Assign weights to vectors of timestamps

I Calculate correlations between pairs of weight vectors

I Apply a spectral clustering algorithm (sklearn)

I Choose best parameters from ”learning set” of txs

(22)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

(23)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 23/30

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(24)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Discussion

I Tx announcement timings reveal relationships between

transactions, even with diffusion

I The technique works on testnet, worse on mainnet

(though we didn’t try to perform a full-scale attack)

I Cryptographic defenses (ZKPs, etc) don’t work: we

(25)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 25/30

Countermeasures

I For users

I Don’t issue many txs in the same session

I Run nodes with increased number of connection

I For cryptocurrency developers

I Implement stronger broadcast randomization

I Periodically drop and re-establish connections randomly

I Increase the default number of connections

(26)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

New propagation mechanism for Bitcoin

I Dandelion: a proposal for new propagation mechanism

for Bitcoin (BIP 156)

I Defeats our attack by distinguishing incoming and

(27)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 27/30

Outline

Introduction

Network-level privacy of Bitcoin and derivatives Our transaction clustering method

Parallel connections

Weighting timestamp vectors Clustering the correlation matrix Metrics

Experimental results Discussion

(28)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work

Alternative cryptocurrencies

I In this work, we only consider Bitcoin.

I Does our technique apply to coins other than Bitcoin?

Some coins are based on Bitcoin’s codebase (Zcash), some are not (Monero).

(29)

Transaction clustering using

network traffic analysis for Bitcoin

and derived blockchains Biryukov, Tikhomirov Introduction Network privacy Our transaction clustering method Parallel connections Weighting timestamp vectors Clustering the correlation matrix Metrics Experimental results Discussion Future work 29/30

Mobile wallets

I In our experiments, txs were issues from a full node.

I Does the technique apply to transactions issued from

mobile wallets?

(30)

Transaction clustering using

network traffic analysis for Bitcoin

Références

Documents relatifs

More precisely, we cluster the data keeping information about location and we have shown that the degener- acy of optimal solutions, which arises from the fact that the

To show the influence of the number of neurons at exit on the number of areas of the segmented image, we had fixed the number of sub-synapses at 14 between two neurons, the step

Recently, spectral clustering methods, which exploit pairwise similarity of data instances, have been shown to be more effective than tradi- tional methods such as k-means,

With conventional graph analysis tools, we successfully identified Hubs and Authorities in the Ethereum transaction network and discovered that they are mainly related to

The following are the two approximation problems that have been studied [2, 7, 1]: Given a complete graph whose edges are labeled positive or negative, find a clustering that

We describe the message propagation mechanics in Bitcoin and propose a novel technique for transaction clustering based on network traffic analysis.. We show that timings of

Deanonymization and linkability of cryptocurrency transactions based on network analysis Biryukov, Tikhomirov Introduction Tx clustering Parallel connections Weighting timestamp

In case of equality, the coefficient α is equal to the ratio of twice the number of edges within the community S divided by the number of edges within the cut of that community. It