SlideShare una empresa de Scribd logo
1 de 24
Descargar para leer sin conexión
MitM on USB 
Introduction of USBProxy 
   からぼ(kalab1998{e}) 
2014年10月31日 第22回「ネットワークパケットを読む会(仮)」 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 1
Self Introduction 
● An engineer of a software company in Aizuwakamatsu 
(until next Feb., and will not update) 
● I'm looking for a next job very hard. 
● I will found an independent researcher “KA-LAB” 
(It's the second choice if no one employ me). 
● I have no released open source software. 
● I have two projects on github as follows. 
– USBProxy is forked from dominicgs/USBProxy 
– kalas is a BLAS on GPGPU for Huge Matrix  
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 2
Is USB a computer network? 
YES! 
USB is a computer network 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 3
Is USB a computer network? 
Hub 
Hub 
USB is a tree structure 
network in physical. 
Host 
computer 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 4
Is USB a computer network? 
USB is one by one 
connections from the host 
to each device in logical. 
Host 
computer 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 5
How to communicate on USB? 
Case: 
Device to Host 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 6
How to communicate on USB? 
Case: 
Host to Device 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 7
Where is the host computer? 
Now a days, increasing 
such connections. 
Are there 
host computers? 
※Vector Graphics has copyright of 
this navigation icon. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 8
Which devices are the host? 
hhoosstt 
host 
※Vector Graphics has copyright of 
this navigation icon. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 9
We have an important problem. 
How do we investigate vulnerabilities 
of such devices without any laptop? 
● Hack devices such cameras, printers, 
navigators, smartphones and so on. 
⇒It's usually very difficult. 
● Electrical tap on the USB cable. 
⇒Next slides. 
● Develop a USB Man in the Middle device. 
⇒Main theme for this presentation. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 10
Electrical tapping on USB 
http://hackaday.com/2011/03/16/usb-man-in-the-middle-adapter/ 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 11
Electrical tapping on USB 
It's very easy, but it has some big problems. 
● Conflicting signals 
● Not enough electric power on signal lines 
● Very weak against electrical noises 
● Not running on USB2.0 by that specification 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 12
dominicgs/USBProxy 
● The device must have two USB ports. 
– One is for connecting a host. 
– Another is for connecting a device. 
● Software relaying 
● Connectable USB2.0 
● Sniffable / Filterable / Injectable 
● Very cheap, BeagleBone Black is about $60.0 
● https://github.com/dominicgs/USBProxy 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 13
USBProxy Structure 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 14
How to relay? 
● USBProxy makes 6 kinds of threads runninng. 
– Reader for Input EP, 
– Reader for output EP, 
– Writer for Input EP, 
– Writer for Output EP, 
– Injection, 
– Filter 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 15
Connection Reader and Writer 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 16
Relay from device to host 
● Reader for Input EP always requests data to 
the Endpoint on the device. 
● Reader for Input EP send data to Writer for 
Input EP when it got data. 
● Writer for Input EP sends data to the host. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 17
Relay from host to device 
● Reader for Output EP always wait a request 
and data from the host. 
● Reader for Output EP send data to Writer for 
Output EP when it got data. 
● Writer for Output EP sends data to the Endpoint 
on the device. 
That's it. Very rough. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 18
Notification! 
● USBProxy does not simulate the USB line. 
● It just simulates endpoints on only one device. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 19
We have problems yet 
● We want to simulate more devices. 
● In many cases, it fail to simulate a device. 
● It can't handle some complex devices yet. 
● Linux lose endpoints on a device sometimes. 
● It can't notice reset signal from a device. 
● Very slow. 
– Original speed is 30.7MB/s, 
– USBProxy relay speed is 1,9MB/s. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 20
Other solutions 
● If you want to just snif on USB, you can use 
USB protocol analizer such the Beagle USB480 
Power. 
● If you are interesting in deep side, maybe you 
will fall in darkness. 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 21
Beagle USB480 Power 
● Easy to use 
● Very fast, 29.8MB/s 
● Cheap, just $2250.0 
● Another device is 
enable USB3.0, 
just $3600.0 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 22
Do you want to fall in darkness? 
● Kali Linux NetHunter "Bad USB" MITM Attack 
● http://vimeo.com/106065667 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 23
White page 
2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 24

Más contenido relacionado

Similar a MitM on USB -- Introduction of USBProxy --

Similar a MitM on USB -- Introduction of USBProxy -- (20)

Let's begin io t with $10
Let's begin io t with $10Let's begin io t with $10
Let's begin io t with $10
 
Small Electronics for Your Makerspace (CLC Trendspotting - September 2014)
Small Electronics for Your Makerspace (CLC Trendspotting - September 2014)Small Electronics for Your Makerspace (CLC Trendspotting - September 2014)
Small Electronics for Your Makerspace (CLC Trendspotting - September 2014)
 
Dragon board 410c workshop - slideshow
Dragon board 410c workshop - slideshowDragon board 410c workshop - slideshow
Dragon board 410c workshop - slideshow
 
Polstra 44con2012
Polstra 44con2012Polstra 44con2012
Polstra 44con2012
 
Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 2012Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 2012
 
Advanced Video Production with FOSS
Advanced Video Production with FOSSAdvanced Video Production with FOSS
Advanced Video Production with FOSS
 
Getting started pi with android
Getting started pi with androidGetting started pi with android
Getting started pi with android
 
Open-Source Hardware, Tinkering, and Physics Education
Open-Source Hardware, Tinkering, and Physics EducationOpen-Source Hardware, Tinkering, and Physics Education
Open-Source Hardware, Tinkering, and Physics Education
 
digitaldesign-s20-lecture3b-fpga-afterlecture.pdf
digitaldesign-s20-lecture3b-fpga-afterlecture.pdfdigitaldesign-s20-lecture3b-fpga-afterlecture.pdf
digitaldesign-s20-lecture3b-fpga-afterlecture.pdf
 
Ubiquitous Content Symposium 2009
Ubiquitous Content Symposium 2009Ubiquitous Content Symposium 2009
Ubiquitous Content Symposium 2009
 
small electronics for your makerspace (clc trendspotting - february 2014)
small electronics for your makerspace (clc trendspotting - february 2014)small electronics for your makerspace (clc trendspotting - february 2014)
small electronics for your makerspace (clc trendspotting - february 2014)
 
[Dec./2017] My Personal/Professional Journey after Graduate Univ.
[Dec./2017] My Personal/Professional Journey after Graduate Univ.[Dec./2017] My Personal/Professional Journey after Graduate Univ.
[Dec./2017] My Personal/Professional Journey after Graduate Univ.
 
libreCMC : The Libre Embedded GNU/Linux Distro
libreCMC : The Libre Embedded GNU/Linux DistrolibreCMC : The Libre Embedded GNU/Linux Distro
libreCMC : The Libre Embedded GNU/Linux Distro
 
The internet of $h1t
The internet of $h1tThe internet of $h1t
The internet of $h1t
 
The RULE project: efficient computing for all GNU/Linux users
The RULE project: efficient computing for all GNU/Linux usersThe RULE project: efficient computing for all GNU/Linux users
The RULE project: efficient computing for all GNU/Linux users
 
How blink(1) was made – Hackaday 10th anniversary talk
How blink(1) was made –  Hackaday 10th anniversary talkHow blink(1) was made –  Hackaday 10th anniversary talk
How blink(1) was made – Hackaday 10th anniversary talk
 
arduino
 arduino arduino
arduino
 
SFScon 21 - Roberto Innocenti - PPC64 Open Hardware Notebook prototype around...
SFScon 21 - Roberto Innocenti - PPC64 Open Hardware Notebook prototype around...SFScon 21 - Roberto Innocenti - PPC64 Open Hardware Notebook prototype around...
SFScon 21 - Roberto Innocenti - PPC64 Open Hardware Notebook prototype around...
 
Embedded Linux primer
Embedded Linux primerEmbedded Linux primer
Embedded Linux primer
 
BadUSB, and what you should do about it
BadUSB, and what you should do about itBadUSB, and what you should do about it
BadUSB, and what you should do about it
 

Último

➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
amitlee9823
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
amitlee9823
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
amitlee9823
 
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
only4webmaster01
 
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
amitlee9823
 
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
amitlee9823
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
amitlee9823
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
amitlee9823
 
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
amitlee9823
 
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Riyadh +966572737505 get cytotec
 
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
amitlee9823
 
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
amitlee9823
 
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
amitlee9823
 
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
karishmasinghjnh
 
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
gajnagarg
 
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night StandCall Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
amitlee9823
 

Último (20)

➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
 
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 9155563397 👗 Top Class Call Girl Service B...
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
 
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
Junnasandra Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore...
 
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night StandCall Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Bellandur ☎ 7737669865 🥵 Book Your One night Stand
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
 
Detecting Credit Card Fraud: A Machine Learning Approach
Detecting Credit Card Fraud: A Machine Learning ApproachDetecting Credit Card Fraud: A Machine Learning Approach
Detecting Credit Card Fraud: A Machine Learning Approach
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
 
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
 
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
 
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
 
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
 
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
 
Predicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science ProjectPredicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science Project
 
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
 
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
Just Call Vip call girls Bellary Escorts ☎️9352988975 Two shot with one girl ...
 
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
 
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night StandCall Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Hsr Layout ☎ 7737669865 🥵 Book Your One night Stand
 

MitM on USB -- Introduction of USBProxy --

  • 1. MitM on USB Introduction of USBProxy    からぼ(kalab1998{e}) 2014年10月31日 第22回「ネットワークパケットを読む会(仮)」 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 1
  • 2. Self Introduction ● An engineer of a software company in Aizuwakamatsu (until next Feb., and will not update) ● I'm looking for a next job very hard. ● I will found an independent researcher “KA-LAB” (It's the second choice if no one employ me). ● I have no released open source software. ● I have two projects on github as follows. – USBProxy is forked from dominicgs/USBProxy – kalas is a BLAS on GPGPU for Huge Matrix  2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 2
  • 3. Is USB a computer network? YES! USB is a computer network 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 3
  • 4. Is USB a computer network? Hub Hub USB is a tree structure network in physical. Host computer 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 4
  • 5. Is USB a computer network? USB is one by one connections from the host to each device in logical. Host computer 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 5
  • 6. How to communicate on USB? Case: Device to Host 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 6
  • 7. How to communicate on USB? Case: Host to Device 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 7
  • 8. Where is the host computer? Now a days, increasing such connections. Are there host computers? ※Vector Graphics has copyright of this navigation icon. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 8
  • 9. Which devices are the host? hhoosstt host ※Vector Graphics has copyright of this navigation icon. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 9
  • 10. We have an important problem. How do we investigate vulnerabilities of such devices without any laptop? ● Hack devices such cameras, printers, navigators, smartphones and so on. ⇒It's usually very difficult. ● Electrical tap on the USB cable. ⇒Next slides. ● Develop a USB Man in the Middle device. ⇒Main theme for this presentation. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 10
  • 11. Electrical tapping on USB http://hackaday.com/2011/03/16/usb-man-in-the-middle-adapter/ 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 11
  • 12. Electrical tapping on USB It's very easy, but it has some big problems. ● Conflicting signals ● Not enough electric power on signal lines ● Very weak against electrical noises ● Not running on USB2.0 by that specification 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 12
  • 13. dominicgs/USBProxy ● The device must have two USB ports. – One is for connecting a host. – Another is for connecting a device. ● Software relaying ● Connectable USB2.0 ● Sniffable / Filterable / Injectable ● Very cheap, BeagleBone Black is about $60.0 ● https://github.com/dominicgs/USBProxy 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 13
  • 14. USBProxy Structure 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 14
  • 15. How to relay? ● USBProxy makes 6 kinds of threads runninng. – Reader for Input EP, – Reader for output EP, – Writer for Input EP, – Writer for Output EP, – Injection, – Filter 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 15
  • 16. Connection Reader and Writer 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 16
  • 17. Relay from device to host ● Reader for Input EP always requests data to the Endpoint on the device. ● Reader for Input EP send data to Writer for Input EP when it got data. ● Writer for Input EP sends data to the host. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 17
  • 18. Relay from host to device ● Reader for Output EP always wait a request and data from the host. ● Reader for Output EP send data to Writer for Output EP when it got data. ● Writer for Output EP sends data to the Endpoint on the device. That's it. Very rough. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 18
  • 19. Notification! ● USBProxy does not simulate the USB line. ● It just simulates endpoints on only one device. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 19
  • 20. We have problems yet ● We want to simulate more devices. ● In many cases, it fail to simulate a device. ● It can't handle some complex devices yet. ● Linux lose endpoints on a device sometimes. ● It can't notice reset signal from a device. ● Very slow. – Original speed is 30.7MB/s, – USBProxy relay speed is 1,9MB/s. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 20
  • 21. Other solutions ● If you want to just snif on USB, you can use USB protocol analizer such the Beagle USB480 Power. ● If you are interesting in deep side, maybe you will fall in darkness. 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 21
  • 22. Beagle USB480 Power ● Easy to use ● Very fast, 29.8MB/s ● Cheap, just $2250.0 ● Another device is enable USB3.0, just $3600.0 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 22
  • 23. Do you want to fall in darkness? ● Kali Linux NetHunter "Bad USB" MITM Attack ● http://vimeo.com/106065667 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 23
  • 24. White page 2014/10/31 (c) 2014 kiyotaka@ka-lab.jp 24