50
1 Weaponizing Unicode: Homographs Beyond IDNs

Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

1

Weaponizing Unicode: Homographs Beyond IDNs

Page 2: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

2

Who Am I

The Tarquin (aka Aaron M Brown)Senior Security Engineer

Amazon.com

@TheTarquin

Page 3: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

3

Disclaimers

Page 4: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

4

Page 5: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

5

WTF, Why?

“The human race will begin solving its problems on the day that it ceases taking itself so seriously.” - Malaclypse the Younger

Page 6: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

6

Scope, Context, and Prior Art

http://www.xn--exmple-qxe.com/

Page 7: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

7

Page 8: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

8

The Dark Corners of Unicode

ꓮvs vs ᴀ vs � �

Page 9: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

9

Scope of the Problem

Α

Uppercase Greek Alpha u+0391

Page 10: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

10

Scope of the Problem

ı̇

Latin Small Letter Dotless I (u+0131) + Combining Dot Above (u+0307)

Page 11: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

11

Scope of the Problem

Mathematical MonoSpace Capital Z u+1D689

Page 12: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

12

Scope of the Problem

Rupee Sign, u+20A8

Page 13: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

13

Not to be Confused With

Indian Rupee Sign, u+20B9

Page 14: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

14

Oh come on, Unicode

Ogham letter Beith u+1681

Page 15: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

15

Let’s Hack Shit

Page 16: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

16

Search and Indexing

Page 17: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

17

Do you want to play a game‽

Page 18: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

18

Defeating Plagiarism Detection

Page 19: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

19

Defeating Plagiarism Detection

Page 20: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

20

Lol text analysis

Page 21: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

21

Lol text analysis

Page 22: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

22

Lol spellcheck

Page 23: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

23

Lesson 1: Unicode support usually just means “passed my unit tests”.

Page 24: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

24

Defeating ML Systems

“Explanations exist; they have existed for all time; there is always a well-

known solution to every human problem [which is] neat, plausible, and

wrong.” - H. L. Mencken

Page 25: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

25

Default Data Set

Page 26: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

26

Homographs, in MY Training Set?

Page 27: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

27

100% Homographs in Neg Training

Page 28: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

28

10% Homographs in Neg Training

Page 29: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

29

Sabotaging a Cinematic Masterwork

Page 30: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

30

Sabotaging a Cinematic Masterwork

Page 31: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

31

Sabotaging a Cinematic Masterwork

Page 32: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

32

Lesson 2: ML overindexes on human-invisible patterns. If a human

could see them, we wouldn’t be using ML.

Page 33: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

33

Page 34: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

34

But emojis aren’t the real problem

Page 35: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

35

Demo

Page 36: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

36

Lesson 3: Homographs work because people don’t see the the text; they see whatever it

represents.

Page 37: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

37

Canary Traps, And Repudiation

Canary Traps: when you want to know who’s “singing”

Page 38: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

38

Canary Traps, And Repudiation

Page 39: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

39

Homographs, Canary Traps, And Repudiation

Page 40: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

40

Homograph Bombs

Go ́ód ñ̃evvs, h cke ₨�⇥ ⇤

Page 41: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

41

And now, for the world’s most boring demo...

Page 42: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

42

Tool Intro: samesame

Because small, sharp tools are the best.

Page 43: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

43

Tool Intro: samesame

Page 44: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

44

Defense

“Every man takes the limits of his own field of vision for the limits of the world.” - Arthur Schopenhauer

Page 45: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

45

Demo Time!

Page 46: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

46

OCR Defense

Why do this instead of $alternative?

Page 47: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

47

Lesson 4: Defenses work best when they directly exploit attacker

incentives

Page 48: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

48

Conclusions!

Phenomenology is king.

Hacking computer is fun; hacking people is more effective

Unicode is a delightfully absurd monstrosity and I love it.

Page 49: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

49

GreetzAmazon colleagues especially David Gabler and Nikki Parekh

The Additional Payphones Crew: cibyr, cobells, giskard, dirac, and turbo

All the DefCon organizers, goons, and other crew

Page 50: Weaponizing Unicode: Homographs Beyond IDNs CON 26/DEF CON 26...5 WTF, Why? “The human race will begin solving its problems on the day that it ceases taking itself so seriously.”

50

�ƀ� ө ᶌ &Αɨ��� ⲅ � ��Ꭵԁ�