attacking mobile broadband modems like a criminal would · attacking mobile broadband modems like a...

44
Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014

Upload: others

Post on 27-Mar-2020

5 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Attacking Mobile Broadband Modems Like A Criminal

Would Andreas Lindh, @addelindh, IT-SeCX 2014

Page 2: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

whoami

•  Security Analyst with I Secure Sweden

•  Technical generalist

•  Not really an expert on anything

•  I like web

Page 3: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Agenda

•  Introduction

•  Target overview

•  Attacks + demos

•  Summary

Page 4: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Introduction

Page 5: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

What’s it about?

Source: http://www.smbc-comics.com

Page 6: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Some words about attackers...

“If  the  cost  of  a,ack  is  less  than  the  value  of  your  informa6on  to  the  a,acker,  you  will  be  a,acked.”    -­‐  Dino  Dai  Zovi,  2011  

Page 7: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Meanwhile in the real world...

Source: http://www.xkcd.com

Page 8: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

This is what it’s about

•  Practical attacks

•  Likely to happen

•  Easy to execute

•  Great potential for paying off

Page 9: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Why USB modems?

•  Very popular – ~130 million devices shipped in 2013

•  Few vendors – Not that many models – Shared code between models

Page 10: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Target overview

Page 11: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Previous research

•  Nikita Tarakanov & Oleg Kupreev – From China With Love (Black Hat EU 2013)

•  Rahul Sasi – SMS to Meterpreter – Fuzzing USB Modems

(Nullcon Goa 2013)

•  These guys are way smarter than me...

Page 12: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Scope

•  Devices from the two biggest vendors* – Huawei – ZTE

•  Focus on one device from each – Huawei E3276 – ZTE MF821D

•  Identify common attack surface

*Combined market share of more than 80% in 2011 (www.strategyanalytics.com)

Page 13: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

In a nutshell

•  Runs embedded Linux

•  Mobile capabilities – GSM, 3G, 4G, SMS

•  Web interface – Part of carrier branding

•  No authentication – Single-user device

Page 14: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Network topology

192.168.x.0/24

Public IP

192.168.x.x

192.168.x.1

WWW

Page 15: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Attacks or

“What would Robert Hackerman do?"

Page 16: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Ground rules

•  Objectives 1.  Make money 2.  Steal information 3.  Gain persistence

•  Pre-requisites 1.  Remote attacks

only 2.  See #1

Page 17: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Out of scope (but possible)

•  Disconnect the device

•  Lock out PIN and PUK

•  Permanently break the application

•  Permanently brick the device

Page 18: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Attacking configuration

Page 19: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

about:config

Page 20: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

DNS poisoning

Page 21: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

DNS poisoning

Page 22: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

DNS poisoning

•  Set static DNS servers

•  Set as default profile

•  Set as read only

Page 23: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

DNS poisoning

•  Serve the user – Adverts – Spoofed websites – Malware

•  Not that sexy, but pretty powerful

Page 24: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

DNS poisoning - bonus attack

•  Trigger firmware update

•  Spoof update server – Downloads are over HTTP – No code signing

•  Potentially get user to install backdoored firmware...

Page 25: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

SMS MitM

Page 26: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

SMS MitM

•  Replace the Service Center Address

•  Set up rogue SMSC

•  MitM all outgoing text messages

Page 27: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Abusing functionality

Page 28: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

About functionality

Page 29: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

CSRF to SMS

•  CSRF to make the modem send SMS – Easy attack: send to premium rate number

Page 30: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

CSRF to SMS

•  Potentially identify the user – Look up phone number – Twin cards

•  Useful in targeted phishing attacks

Page 31: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •
Page 32: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting persistent

Page 33: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •
Page 34: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting persistent

•  Multiple XSS vulnerabilities

•  Configuration parameters

•  Configuration is persistent...

Page 35: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting persistent

•  The web interface is where you go to connect to the Internet – Huawei Hilink opens main page

automatically – ZTE creates a desktop shortcut

•  The main page sets everything up – Loads an iframe for user interaction –  It also loads the chosen language

Page 36: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting persistent

•  Language is a configuration parameter loaded by the main page

•  It is injectable...

Page 37: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting persistent

•  Execute code every time the user connects to the Internet

•  Interact with injected code

•  Command channel – Poll remote server (BeEF style) – Out of band over SMS

Page 38: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •
Page 39: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Summary

Page 40: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

What to expect

•  Attacks on configuration – Network – Mobile

•  Abuse of functionality – Outbound & inbound SMS

•  Injection attacks – Getting persistent – Stealing information

Page 41: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Getting it fixed

•  ZTE is “working on it” –  I have no details – ZTE does not seem to have a product

security team K

•  Huawei is fixing their entire product line – Nice++ – Huawei has a product security team J

•  Sounds pretty good though, right?

Page 42: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

The update model is broken

•  Vendors cannot push fixes directly to end-users – Branding complicates things

•  Vendor -> Carrier -> User – Carriers might not make the fix available – Users might not install the fix

•  Most existing devices will probably never get patched

Page 43: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Don’t forget...

Page 44: Attacking Mobile Broadband Modems Like A Criminal Would · Attacking Mobile Broadband Modems Like A Criminal Would Andreas Lindh, @addelindh, IT-SeCX 2014 . whoami ... – ZTE •

Thank you for listening! Andreas Lindh, @addelindh, IT-SeCX 2014