When Governments Hack Opponents Bill Marczak First, Bahraini - - PowerPoint PPT Presentation

when governments hack opponents
SMART_READER_LITE
LIVE PREVIEW

When Governments Hack Opponents Bill Marczak First, Bahraini - - PowerPoint PPT Presentation

When Governments Hack Opponents Bill Marczak First, Bahraini jailers armed with stifg rubber hoses beat the 39-year-old school administrator and human rights activist in a windowless room... Then, they dragged him upstairs for questioning by


slide-1
SLIDE 1

When Governments Hack Opponents

Bill Marczak

slide-2
SLIDE 2
slide-3
SLIDE 3
slide-4
SLIDE 4

First, Bahraini jailers armed with stifg rubber hoses beat the 39-year-old school administrator and human rights activist in a windowless room... Then, they dragged him upstairs for questioning by a uniformed offjcer armed with another kind of weapon: transcripts of his text messages and details from personal mobile phone conversations...

Abdul Ghani al-Khanjar Bahraini Activist

slide-5
SLIDE 5
slide-6
SLIDE 6

Activist communication tools...

slide-7
SLIDE 7
slide-8
SLIDE 8
slide-9
SLIDE 9
slide-10
SLIDE 10

“Cred”

slide-11
SLIDE 11
slide-12
SLIDE 12
slide-13
SLIDE 13

If you get a suspicious email or message, send it to me!

slide-14
SLIDE 14

If you get a suspicious email or message, send it to me! Ahmed Mansoor UAE Activist Hey Bill, I got a weird email!

slide-15
SLIDE 15

The Data

slide-16
SLIDE 16
slide-17
SLIDE 17
slide-18
SLIDE 18

Order to uncover the user of an IP address of @alkawarahnews Mohammed Salah Acting Chief Prosecutor, Capital Region Batelco (residential ISP)

slide-19
SLIDE 19

“It is a secret investigation involving private methods

  • f our department that

cannot be disclosed”

  • Col. Fawaz al-Sumaim

Bahrain Cyber Crime Unit

slide-20
SLIDE 20

Greetings, I am a translator of the revolution. Do you need translation of this? (Arrested activist)

slide-21
SLIDE 21

Greetings, I am a translator of the revolution. Do you need translation of this? (Arrested activist)

slide-22
SLIDE 22

(Arrested activist)

slide-23
SLIDE 23

(Arrested activist)

slide-24
SLIDE 24
slide-25
SLIDE 25
slide-26
SLIDE 26

Sketch: Social Engineering

slide-27
SLIDE 27

Ahmed Mansoor UAE Activist

“New secrets about torture of Emiratis in state prisons”

slide-28
SLIDE 28

Nice Bait, we’ll take it!

slide-29
SLIDE 29

Factory-Reset iPhone (Wi-Fi Only)

Nice Bait, we’ll take it!

slide-30
SLIDE 30

Factory-Reset iPhone (Wi-Fi Only) Wi-Fi Intercept & record Internet traffjc

Nice Bait, we’ll take it!

slide-31
SLIDE 31

Factory-Reset iPhone (Wi-Fi Only) Intercept & record Internet traffjc The Internet Wi-Fi

Nice Bait, we’ll take it!

slide-32
SLIDE 32

Type in the link from Mansoor...

Factory-Reset iPhone (Wi-Fi Only) Intercept & record Internet traffjc The Internet Wi-Fi

Nice Bait, we’ll take it!

slide-33
SLIDE 33

… and what happens next will SHOCK YOU! Safari window closes!

slide-34
SLIDE 34

… and what happens next will SHOCK YOU! Safari window closes! Tring [sic] to download bundle!

slide-35
SLIDE 35

CVE-2016-4657 Visiting a maliciously crafted website may lead to arbitrary code execution CVE-2016-4655 An application may be able to disclose kernel memory CVE-2016-4656 An application may be able to execute arbitrary code with kernel privileges

slide-36
SLIDE 36

CVE-2016-4657 Visiting a maliciously crafted website may lead to arbitrary code execution CVE-2016-4655 An application may be able to disclose kernel memory CVE-2016-4656 An application may be able to execute arbitrary code with kernel privileges

slide-37
SLIDE 37
slide-38
SLIDE 38
slide-39
SLIDE 39
slide-40
SLIDE 40

Attribution

slide-41
SLIDE 41
slide-42
SLIDE 42

When we clicked again, redirect to: https://sms.webadv.co/redirect.aspx

slide-43
SLIDE 43

When we clicked again, redirect to: https://sms.webadv.co/redirect.aspx

<html><head><meta http-equiv='refresh' content='0;url=http://www.google.com' /><meta http-equiv='refresh' content='1;url=http://www.google.com' /><title></title></head><body></body></html>

slide-44
SLIDE 44

When we clicked again, redirect to: https://sms.webadv.co/redirect.aspx

<html><head><meta http-equiv='refresh' content='0;url=http://www.google.com' /><meta http-equiv='refresh' content='1;url=http://www.google.com' /><title></title></head><body></body></html>

Wow, that's weird!

slide-45
SLIDE 45
slide-46
SLIDE 46

plan: 1. Use zmap to Fetch /redirect.aspx from every ipv4 address (232 = 4,294,967,296 ) 2. Check which responses are the same as our fingerprint:

<html><head><meta http-equiv='refresh' content='0;url=http://www.google.com' /><meta http-equiv='refresh' content='1;url=http://www.google.com' /><title></title></head><body></body></html>

slide-47
SLIDE 47

Result: 149 ip addresses New plan: look at historical internet scanning data for the 149 ip addresses

https://shodan.io/ https://censys.io/ https://opendata.rapid7.com/

slide-48
SLIDE 48

Result: 19 ip addresses returned in response to a fetch for /

\xef\xbb\xbf<HTML><HEAD><META HTTP-EQUIV="refresh" CONTENT="0;URL=http://www.google.com/"> <TITLE></TITLE></HEAD><BODY> </BODY></HTML>

slide-49
SLIDE 49

Result: 19 ip addresses returned in response to a fetch for /

\xef\xbb\xbf<HTML><HEAD><META HTTP-EQUIV="refresh" CONTENT="0;URL=http://www.google.com/"> <TITLE></TITLE></HEAD><BODY> </BODY></HTML>

New plan: what else returned this?

slide-50
SLIDE 50

Result: 19 ip addresses returned in response to a fetch for /

\xef\xbb\xbf<HTML><HEAD><META HTTP-EQUIV="refresh" CONTENT="0;URL=http://www.google.com/"> <TITLE></TITLE></HEAD><BODY> </BODY></HTML>

New plan: what else returned this? Result: 89 IP addresses including:

Admin Organization: Nso Group Admin Street: P.O Box 4166 Admin City: Hertzelia Admin Country: IL Admin Email: IT@nsogroup.com

slide-51
SLIDE 51

"NSO Group is a leader in the field of Cyber warfare."

“… a powerful and unique monitoring tool, called Pegasus, which allows remote and stealth monitoring and full data extraction from remote targets devices via untraceable commands."

"...exclusively for the use of Government, Law Enforcement and Intelligence Agencies."

slide-52
SLIDE 52

Fingerprint #1

19 IPs

Fingerprint #2 2013-2014

Ahmed Mansoor

2016

slide-53
SLIDE 53
slide-54
SLIDE 54

Why do NSO servers return Google redirects?

<html><head><meta http-equiv='refresh' content='0;url=http://www.google.com' /><meta http-equiv='refresh' content='1;url=http://www.google.com' /><title></title></head><body></body></html> \xef\xbb\xbf<HTML><HEAD><META HTTP-EQUIV="refresh" CONTENT="0;URL=http://www.google.com/"> <TITLE></TITLE></HEAD><BODY> </BODY></HTML>

slide-55
SLIDE 55

Why do NSO servers return Google redirects?

<html><head><meta http-equiv='refresh' content='0;url=http://www.google.com' /><meta http-equiv='refresh' content='1;url=http://www.google.com' /><title></title></head><body></body></html> \xef\xbb\xbf<HTML><HEAD><META HTTP-EQUIV="refresh" CONTENT="0;URL=http://www.google.com/"> <TITLE></TITLE></HEAD><BODY> </BODY></HTML>

Decoy Page: “redirect or customize undesired remote … landing on the server”

slide-56
SLIDE 56

Fake Apache Decoy Pages (Hacking Team)

slide-57
SLIDE 57

Fake Apache Decoy Pages (Hacking Team)

Apache Hacking Team

HTTP/1.1 404 Not Found Date: $DATE Server: $SERVER Content-Length: $LENGTH Connection:close Content-Type: text/html; charset=$CHARSET HTTP/1.1 404 NotFound Connection: close Content-Type: text/html Content-length: $LENGTH Server: Apache/2.4.4 (Unix) OpenSSL/1.0.0g

slide-58
SLIDE 58

Apache FinFisher

HTTP/1.1 403 Forbidden Date: $DATE GMT Server: Apache Vary: Accept-Encoding Content-Length: 321 Content-Type: text/html; charset=iso-8859-1 HTTP/1.1 403 Forbidden Date: $DATE UTC Server: Apache Vary: Accept-Encoding Content-Length: 321 Content-Type: text/html; charset=iso-8859-1

Fake Apache Decoy Pages (FinFisher)

slide-59
SLIDE 59

Apache FinFisher

<html><body><h1>It works!</h1></body></html> <!DOCTYPE HTML PUBLIC ``-//IETF//DTD HTML 2.0//EN''> <html><head> <title>200 OK</title> </head><body> <h1>It works!</h1> </body></html>

Fake Apache Decoy Pages (FinFisher)

slide-60
SLIDE 60

Spyware Command-and-Control

slide-61
SLIDE 61

Victim Victim

Command and Control

slide-62
SLIDE 62

Proxy Proxy Proxy Victim

"The Cloud"

Victim

Command and Control

slide-63
SLIDE 63

Gateway / Firewall

Government Agency Premises

Proxy Proxy Proxy C&C Server Victim

"The Cloud"

Victim

Command and Control

Monitoring Center

slide-64
SLIDE 64

Gateway / Firewall

Government Agency Premises

Proxy Proxy Proxy C&C Server Victim

"The Cloud"

Victim

Command and Control

Monitoring Center Scanning finds these...

slide-65
SLIDE 65

… but not these

Government Agency Premises

Gateway / Firewall Proxy Proxy Proxy C&C Server Victim

"The Cloud"

Victim

Command and Control

Monitoring Center Scanning finds these...