2. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Who are these jerks anyway
ā£ richo
ā£ Computer Jerk
ā£ @rich0H
ā£ Duck Enthusiast
ā£ Ran WrongIslandCon
ā£ mike
ā£ Bluetooth Guy
ā£ @mpeg4codec
ā£ Owner/Operator of
conscience (sometimes)
3. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Why buy an $nK skateboard?
ā£ Lightweight
ā£ (relatively) inexpensive
ā£ .. maybe wanted on the hype train early
4. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Why buy an $nK skateboard?
ā£ Lightweight
ā£ (relatively) inexpensive
ā£ .. maybe wanted on the hype train early
ā£ Maybe to hax it
5. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Why hax a $1k skateboard?
ā£ Because itās there
ā£ Vehicle research is cool
ā£ But not all of us can afford to brick a car
ā£ Figured we might be able to illustrate a point about
the state of security research
11. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Or whatever
Right so like hacking
ā£ Most of these boards use bluetooth
ā£ I know nothing about bluetooth
ā£ I know mike though
ā£ mike knows bluetooth
ā£ How hard can this possibly be?
19. ā¦ many beers later
painstakingly reversed with love
ā£ Simple Duplex protocol
ā£ Controller sends on handle 0x1a
ā£ Reads on handle 0x1c
ā£ Basically a bluetooth -> serial adaptor
20. ā¦ many beers later
Message Direction Meaning
RC0 Remote -> Board Speed control
FUEL Remote -> Board Fetch current battery load
REXP Remote -> Board Set expert mode
RBGN Remote -> Board Set beginner mode
GAUGE[1-5] Board -> Remote Inform current battery load
painstakingly reversed with love
21. but how 2 talking?
We know its language
ā£ Bluetooth comms turn out to be sorta miserable
ā£ Especially for general purpose applications
ā£ x10000 for ad-hoc, general purpose applications
22. The old school
ā£ Ubertooth
ā£ āminimalā
ā£ BlueZ
ā£ Full featured, but heavy
ā£ Not super fond of doing obviously broken things
ā£ (Like fuzzing embedded devices)
23. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Welcome to the new school
PyBT
ā£ Userland bluetooth stack implemented in Python
ā£ Backs onto scapy for actually talking to the wire
ā£ Uses HCI_CHANNEL_USER
ā£ Prototyping++
ā£ https://github.com/mikeryan/PyBT
24. Now what
Neat we can spin the wheels
ā£ Need to be connected to the board to exploit
ā£ Only one thing can be connected at a time
ā£ Thinking back to that intersection
ā£ richo demonstrates again that he has no idea:
ā£ āHow hard can jamming bluetooth be?ā
25. Super hard, it turns out
Jamming bluetooth:
ā£ Naive approach:
ā£ Yell really loud
ā£ Noone can hear anything
ā£ ??????
ā£ Proļ¬tā¦..?
29. Seriously like crazy hard
Jamming Bluetooth
ā£ Itās like they designed the protocol itself to stop us
from doing this exact thing
ā£ By this point richo is no longer allowed to make
suggestions
30. Seriously like crazy hard
Jamming Bluetooth
ā£ Bluetoothās channel hopping stops us from jamming
effectively
ā£ Channel hopping is deterministic
ā£ Need some state- Gotta capture:
ā£ Access address
ā£ Hop interval
ā£ Hop increment
31. Seriously like crazy hard
Jamming Bluetooth
Upstreamed: https://github.com/greatscottgadgets/ubertooth
32. Time to launch some jerks
Demo Time!
ā£ The plan:
ā£ Setup a bunch of jammers
ā£ Conļ¬gure our repl to connect and autoreverse throttle
ā£ Wait for hapless skateboarder
ā£ Jam
ā£ Connect
ā£ Reverse
ā£ ?????
ā£ Launch some jerk
38. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolve
ā£ Says bluetooth on the site
ā£ Spoilers:This is not a True Factā¢
ā£ Better range than boosted
ā£ Janky looking remote
ā£ Made of carbon though?
ā£ So thatās neat I guess
ā£ ĀÆ_( )_/ĀÆ
39. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ It says bluetooth right there on the tin
ā£ Weāre crazy cocky at this point
ā£ āWe oughta have this done by lunchā
40. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Pull out the harness we used on Boosted
41. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ No packets this time :(
ā£ richo is a goddamn hipster and lives in SF
ā£ goddamn hipsters in SF love wiļ¬/bt
ā£ richoās apartment might be the RF noisiest
environment in the whole universe
ā£ The moratorium on richo giving advice has expired
by this point
ā£ āWeāll build a faraday cage!ā
43. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Snowboard bindings box
wrapped in tinfoil
ā£ Works terrifyingly well
ā£ Seriously wtf tho whereās
the bluetooth
44. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ merijn very kindly lent us his skateboard
ā£ We should probably pull it to pieces and look at it
ā£ Unclear if we ever mentioned that we were going to
do this or that we didāØ
ā£ (Hi Merijn btw we pulled apart your skateboard)
45. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Pulled the remote apart
ā£ Looked up the rf part
ā£ er, this is not a bluetooth
chip
ā£ Neither of us have even
heard of this thing
ā£ nRF24LE
49. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Er, ShockBurstā¢
50. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ WTF is this thing?
ā£ Antennae?
ā£ Way too big for 2.4ghz
51. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ No obvious path to glory
ā£ No hackRF at my place
ā£ Canāt ļ¬ddle with its radio today
ā£ Letās just dump trafļ¬c directly
ā£ Hey didnāt I impulse buy a saleae a while ago?
54. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ No dice on the remote
ā£ Letās ļ¬ddle with the board instead!āØ
ā£ (Hi Merijn)
55. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Cramped AF
ā£ Traced most of it out though
ā£ Off the shelf parts
ā£ Explained a bunch of
hilarious bugs
56. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ ShockBurst is simplex
ā£ Hence no data to the remote
ā£ Not especially complex
ā£ Does have a 9 member bitļ¬eld though to make our
lives miserable
ā£ Less tolerant to interference than BT
57. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Demo Time!
ā£ Inject packets into evolve
ā£ ????
ā£ Proļ¬t!
58. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Evolution
ā£ Sadly not much else to do here
ā£ Outside of āAttacker has physical accessā scenarios
thereās not much to attack
60. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Taming a wild ego
ā£ Says bluetooth all over it
ā£ Has a smartphone app
ā£ Has to be bluetooth right?
61. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Taming a wild ego
ā£ Didnāt take a good photo :(
ā£ Sadly it canāt actually drive
an ubertooth (yet?)
ā£ Sniffed a lot of bluetooth
ā£ No packets again
ā£ WTF?
62. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Taming a wild ego
ā£ WTF is this switch on the
side?
ā£ BT|WIFI
ā£ ā¦ no
ā£ ā¦ ā¦ NO
63. @mpeg4codec / Hacking Electric Skateboards / @rich0H
Taming a wild ego
ā£ Yup this damn thing talks bluetooth *and* wiļ¬
ā£ Paired with a phone itās bluetooth
ā£ Paired with the remote itās wiļ¬
66. Persistence
Remote code execution on a skateboard, you say?
ā£ From pulling the board apart we knew it was a pic24f
ā£ Didnāt have much luck initially trying to ļ¬nd debug
ports on the skateboard
ā£ Later discovered that we missed them
ā£ A few months later though, this happens:
70. Persistence
Remote code execution on a skateboard, you say?
ā£ Has a ļ¬rmware update facility
ā£ This oughta be good
ā£ Upgrade one of our boards
ā£ Dump bluetooth trafļ¬c with jailbroken iThing
ā£ Dump https trafļ¬c with burp
ā£ Both sides of the conversation, hopefully we learn
how to upload + format ļ¬rmware
71. Persistence
RCE on a skateboard, you say?
ā£ many hours later weāve stitched a ļ¬rmware blob
together out of the dumps
ā£ Strings are encoded as, eg:
ā£ āFx00Ux00Ex00Lx00ā => āFUELā
ā£ Write a dumb python script to strip nulls, strings(1)
to the rescue
ā£ Learn about a bunch of new commands!
72. ā¦ many many beers later
Message Direction Meaning
RC0 Remote -> Board Speed control
FUEL Remote -> Board Fetch current battery load
REXP Remote -> Board Set expert mode
RBGN Remote -> Board Set beginner mode
GAUGE[1-5] Board -> Remote Inform current battery load
PING Remote -> Board Fetch version information
GIT Remote -> Board Fetch git revision of ļ¬rmware
STAT Remote -> Board Fetch detailed diagnostic info
NUMSKL Remote -> Board Still no idea. Replies āNUMSKL4ā
ODO Remote -> Board Fetch current odometer reading
SOC Remote -> Board Still no idea
painstakingly reversed with love
73. Persistence
RCE on a skateboard, you say?
ā£ With this in hand, richo writes a repl for boosted
boards
ā£ Nico works out how to unbrick a skateboard when
we inevitably screw this up
ā£ https://github.com/richo/skateboard/blob/master/
boosted_repl.py
74. Persistence
RCE on a skateboard, you say?
ā£ Finally, itās time to reverse the transfer protocol
ā£ Winds up like intel .hex over bluetooth
Length
Address
Flags
Data Checksum
76. Persistence
RCE on a skateboard, you say?
ā£ What do you even *do* with code execution on a
skateboard?
ā£ Could deļ¬nitely make the board dangerous to its
rider
ā£ Seemed funnier to make it pretend to be Joshua from
WARGAMES
78. These jerks are alright
Gr33tz and Th4nx
ā£ nico, who showed up at the last second and helped us
hax ļ¬rmware, is an Arduino Uno expert
ā£ merijn for lending us his evolve despite it obviously
being a Bad Idea
ā£ whatever chump bought the e-go at the auction
ā£ Boosted
ā£ Evolve
ā£ Yuneec