19
Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck GmbH Köln Büro: Bonnerstr. 108. 53757 Sankt Augustin www. softScheck.com

Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

Internet of (dangerous) Things

Tobias Esser, Prof. Dr. Hartmut Pohl

softScheck GmbH Köln

Büro: Bonnerstr. 108. 53757 Sankt Augustin www. softScheck.com

Page 2: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

reactive

… Security Information Event Management (SIEM)

Reactive Strategy

Page 3: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

proactive

reactive

… Security Information Event Management (SIEM)

ISO 27034 Application Security

Reactive - Proactive Strategy

Explorative Testing

Manual Auditing

Penetration Testing

Static Source

Code Analysis Conformance

Testing

Dynamic Analysis

Fuzzing Architecture Analysis

Threat Model

Attack Paths, Surface

SSQUARE

Page 4: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Products Tested

Page 5: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Application Security Management SASM

ISO 27034 conform Development

Application Security Audit Security Requirements

Product Design Implementation Release Verification Requirements

Targeted Level of Trust

Explorative Testing

Manual Auditing

Penetration Testing

Risk Analysis

SSQUARE Static Source

Code Analysis

Application Security Controls

Conformity Testing

Architecture Analysis

Threat Model

Attack Paths, Surface

ASC 01 ASC 06 Dynamic Analysis

Fuzzing

Page 6: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Internet of Things

Page 7: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Internet of (dangerous) Things Reverse Engineering einer WiFi-Steckdose

TP-Link HS110 WiFi Smartplug

Steuerbar mit "Kasa for Mobile" Smartphone-App

(iOS, Android)

TP-Link Cloud-Anbindung

Page 8: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

SmartPlug startet Access Point (AP) "TP-LINK_Smart Plug_XXXX"

Kasa App verbindet Smartphone mit dem AP

App kommuniziert lokal verschlüsselt über TCP Port 9999

Passwort des Heim-WLANs wird von App an SmartPlug geschickt

SmartPlug schaltet AP aus und verbindet sich mit Heim-WLAN

SmartPlug Setup

Page 9: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Web-Server ist ein Fake!

Offene Ports

Page 10: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Jedes Byte XOR mit vorigem Plaintext-Byte

Erstes Byte XOR -85 (Schlüssel)

Ver- und Entschlüsselung gleich

Reverse Engineering der Verschlüsselung

Page 11: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Wireshark Dissector

Page 12: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

JSON-basiert

Beispiel-Befehle:

TP-Link SmartHome Protokoll

{"system":{"get_sysinfo":{}}} Systeminfos

{"system":{"reboot":{"delay":1}}} Neustart

{"system":{"set_relay_state":{"state":1}}} Steckdose anschalten

{"netif":{"get_scaninfo":{"refresh":1}}} Nach WLANs scannen

{"netif":{"set_stainfo":{"ssid":"WiFi","password":"secret", "key_type":3}}}

Mit WLAN verbinden

{"cnCloud":{"bind":{"username":"[email protected]","password":"secret"}}} In Cloud registrieren

{"cnCloud":{"unbind":null}} Registrierung aufheben

Page 13: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

time

emeter (energy meter)

schedule (scheduled on/off)

count_down (countdown on/off)

anti_theft (random scheduled on/off)

TP-Link SmartHome Protokoll

Page 14: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

SmartPlug agiert nur als HTTPS-Client

Regelmäßige TLS-Verbindung zum Cloud-Server

App schickt JSON-Befehle verpackt mit "method:passthrough"

Cloud-Server leitet Befehle an SmartPlug weiter

Cloud-Kommunikation

POST /?token=<sessionid> HTTP/1.1 Content-Type: application/json Host: eu-wap.tplinkcloud.com {"method":"passthrough", "params": {"deviceId":"<deviceID>, "requestData":"{\"system\":{\"get_sysinfo\":null}}"}}

Page 15: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Offene Ports

Page 16: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

TP-Link Device Debug Protocol TDDP Patent

Page 17: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

DES Key = md5(username + password)[:16]

TDDP Crypto

Page 18: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Demo

Page 19: Internet of (dangerous) Thingsrat.admin.lv/wp-content/.../05pohlsoftscheckinternetofdangerousthin… · Internet of (dangerous) Things Tobias Esser, Prof. Dr. Hartmut Pohl softScheck

© softScheck

Internet of (dangerous) Things (IodT)

Fork us on GitHub: https://github.com/softScheck/tplink-smartplug

softScheck GmbH Köln

Büro: Bonnerstr. 108. 53757 Sankt Augustin www. softScheck.com +49 (2241) 255 43 – 12

Prof. Dr. Hartmut Pohl

[email protected]

Tobias Esser

Tobias. [email protected]