Return to Video

36C3 - All wireless communication stacks are equally broken

  • 0:00 - 0:20
    36C3 preroll music
  • 0:20 - 0:27
    Herald Angel: Our next speaker is jiska.
    jiska is attending this conference since
  • 0:27 - 0:32
    ages like a decade? even more?
    jiska: 20, 22 C3
  • 0:32 - 0:37
    Herald Angel: Long, long time. Sometimes
    she is also doing some talks here. The
  • 0:37 - 0:42
    last one last year was about Bluetooth.
    There she was in depth. This time it will
  • 0:42 - 0:50
    be a more general talk about wireless
    protocols NFC, LTE, Wi-Fi, and, of course,
  • 0:50 - 0:56
    Bluetooth. So she will tell us what is
    broken in all those protocols. So have fun
  • 0:56 - 1:01
    and enjoy the talk "All wireless
    communications stacks are equally broken"
  • 1:01 - 1:03
    by jiska.
  • 1:03 - 1:09
    applause
  • 1:09 - 1:14
    jiska: So welcome to my talk. I thought it
    first to be a foundation talk, but it will
  • 1:14 - 1:19
    also have new topics about everything that
    is kind of fundamentally broken in
  • 1:19 - 1:24
    wireless communication and it will cover
    anything in your smartphone soul like NFC,
  • 1:24 - 1:30
    Bluetooth, Wi-Fi, LTE. You could order
    them like by communication range or by
  • 1:30 - 1:37
    specification length or lines of code. But
    the thing is, so the specification length
  • 1:37 - 1:41
    and line of code also mean increased
    complexity. And if there is increased
  • 1:41 - 1:48
    complexity, you might have issues with
    security in it, in the very end. And then
  • 1:48 - 1:53
    there is something that is even worse than
    LTE, which is vendor specific additions
  • 1:53 - 1:57
    that would be when you open like five
    instances of IDA and like tried to
  • 1:57 - 2:04
    analyze where the wireless message is
    going and what it is doing. So most of
  • 2:04 - 2:09
    this in this talk will be about wireless
    exploitation and the new stuff will be
  • 2:09 - 2:15
    fuzzing techniques and a new escalation
    target. But everything else is more like a
  • 2:15 - 2:21
    general view on wireless exploitation. So
    first, to understand what the wireless
  • 2:21 - 2:27
    exploit does is to separate it in
    different layers. So there is the lowest
  • 2:27 - 2:31
    layer, which is some hybrid chip which
    runs a firmware, let's say bluetooth
  • 2:31 - 2:36
    firmware, which is then attached to a
    driver. Then there's some privileged
  • 2:36 - 2:40
    stuff, it depends a bit on what kind of
    system you're on. And in the end, there
  • 2:40 - 2:45
    will be applications and no matter where
    you exploit is on that layer that you're
  • 2:45 - 2:50
    exploiting, some security measures become
    ineffective. So, for example, if there is
  • 2:50 - 2:57
    encryption and you have an exploit for
    that layer, it would become ineffective.
  • 2:57 - 3:03
    And it depends, so the higher you are, the
    higher also the exploit prices get. So for
  • 3:03 - 3:08
    the Wi-Fi RCE, you would be at 100K, for
    baseband RCE with local privilege
  • 3:08 - 3:13
    escalation, it gets already 200 K, and if
    it's just a messenger or something, then
  • 3:13 - 3:18
    it's like really, really high in the
    price. So the question is like, why is
  • 3:18 - 3:27
    this wireless stuff a bit cheaper? So
    well, you need a certain distance. And so
  • 3:27 - 3:32
    that's probably a thing. And then also,
    maybe they are just too easy to find. I
  • 3:32 - 3:38
    don't know. Like at least, maybe for me, I
    don't know for normal people. Or maybe the
  • 3:38 - 3:43
    market demand is not that high for them.
    Or they are not privileged enough. I don't
  • 3:43 - 3:50
    know. But actually they'd need like only
    like non or less interaction. So. Yeah.
  • 3:50 - 3:56
    Still a thing I would say. So within the
    group I am working at we had a lot of
  • 3:56 - 4:01
    wireless research and also tools that we
    released. And the first one I think that
  • 4:01 - 4:07
    was running on a mobile phone is NFCGate,
    which is currently managed by Max. Then
  • 4:07 - 4:12
    there is nexmon, which is our largest
    project, which is patching of Broadcom
  • 4:12 - 4:17
    Wi-Fi. And Matthias, who did that, reached
    his goal by just saying, like, I now have
  • 4:17 - 4:25
    kind of a software defined radio in a
    commodity like Broadcom Wi-Fi chip. And so
  • 4:25 - 4:29
    he was a bit bored and kicked off two new
    projects before he left, which he then
  • 4:29 - 4:34
    handed over. The first one is Qualcomm LTE
    and the second one was Broadcom Bluetooth,
  • 4:34 - 4:40
    which I ended up with. And then we have
    someone else who is Milan and he is doing
  • 4:40 - 4:45
    stuff that comes more like from the
    application layer. So he implemented an
  • 4:45 - 4:52
    open source solution for Apple Airdrop
    that you can run on your Raspberry Pi. And
  • 4:52 - 4:58
    well hackers gonna hack, so this stuff has
    been used a lot for exploitation, not by
  • 4:58 - 5:02
    us, but by others. So there were three
    groups using nexmon for Wi-Fi
  • 5:02 - 5:06
    exploitation, at least like what is
    publicly known and like the bigger ones,
  • 5:06 - 5:11
    maybe I forget someone, but so there is a
    lot of exploitation going on there. Then
  • 5:11 - 5:16
    internal blue has been used to demonstrate
    an attack against a key negotiation of
  • 5:16 - 5:22
    Bluetooth just this august. And the open
    Airdrop implementation was used for some
  • 5:22 - 5:28
    honeypots at Black Hat and AirDos. And
    like a lot of stuff is going on there. And
  • 5:28 - 5:32
    then you might ask yourself, like, yeah,
    so, if everybody is using it for
  • 5:32 - 5:39
    exploitation why don't we just do it
    ourselves. And we actually did that and we
  • 5:39 - 5:45
    even did that for this very first project,
    this NFC project. And the most important
  • 5:45 - 5:50
    thing you need to know about NFC is that
    the near field is not really a near field.
  • 5:50 - 5:54
    So there's -- it's just communication, but
    it's not near field communication, which
  • 5:54 - 6:00
    means so if you are able to forward the
    communication, so for example, you have
  • 6:00 - 6:04
    like your credit card and then a
    smartphone with NFC, you could forward it
  • 6:04 - 6:10
    over the cloud or some server and then to
    another smartphone and then to the payment
  • 6:10 - 6:15
    terminal. And usually there's no time
    constraint or distance pounding that would
  • 6:15 - 6:19
    prevent this. So you can at least forward
    and relay messages and you might even be
  • 6:19 - 6:26
    able to modify them on the way. And some
    students of us did like some testing in
  • 6:26 - 6:33
    some systems of some third parties who
    then politely asked them to please stop
  • 6:33 - 6:41
    the testing. So it was not really a cool
    thing overall. Like, not not good to
  • 6:41 - 6:46
    publish and so on. And the more happy I am
    about that there's other researchers who
  • 6:46 - 6:53
    actually used some other tooling to look
    into NFC. So just this month there has
  • 6:53 - 6:58
    been a talk at Black Hat, so not by us,
    but by others about the visa credit cards.
  • 6:58 - 7:06
    And it's just all broken and it's cool
    that some people like just did it anyway.
  • 7:06 - 7:10
    Yeah. So this is more about -- the NFC
    stuff is more about forwarding and the
  • 7:10 - 7:16
    actual specification, but something that
    is also cool is -- If you get code
  • 7:16 - 7:22
    execution within a chip and this is very
    different attack scenario. And for
  • 7:22 - 7:27
    Bluetooth, I think it's especially bad
    because of how everything is designed. And
  • 7:27 - 7:34
    the first design issue in Bluetooth is
    that the encryption key is stored in a way
  • 7:34 - 7:38
    that the chip can always ask for
    encryption keys here at the host, or it's
  • 7:38 - 7:44
    even already on the chip. And there is no
    kind of security there. So whenever you
  • 7:44 - 7:48
    have code execution on the chip, it means
    you can get all the encryption keys, not
  • 7:48 - 7:52
    of just the active connection, and then
    break everything that is kind of a trusted
  • 7:52 - 7:57
    connection by this key. And that even
    breaks features like the Android Smart
  • 7:57 - 8:02
    Lock. And Android Smart Lock is a thing
    you can unlock your Android smartphone, if
  • 8:02 - 8:06
    you have a trusted device and if you'd
    like add this, you might do this for your
  • 8:06 - 8:13
    car because it's nice in your car when you
    have like your audio and your navigation
  • 8:13 - 8:17
    and everything without a locked
    smartphone. But the question is like, how
  • 8:17 - 8:21
    secure is the Bluetooth of your car? Would
    you trust that one to unlock your
  • 8:21 - 8:29
    smartphone? I don't know. And the next
    thing is, so if you have code execution on
  • 8:29 - 8:34
    a Bluetooth chip, it also means that you
    might be able to escalate into some other
  • 8:34 - 8:42
    components so that you go up all the
    layers. The next question, is the exploit
  • 8:42 - 8:47
    persistent? So let's say I have something
    that is running on the chip and I don't
  • 8:47 - 8:53
    know, extracting encryption keys or doing
    whatever. You might ask yourself, so how
  • 8:53 - 8:56
    long will it be on the chip? I mean, it's
    just a Bluetooth chip you switch Bluetooth
  • 8:56 - 9:02
    off sometimes and then the specifications.
    So it's just a page like almost 1000. So
  • 9:02 - 9:07
    just like the first third of the
    specification it says not the HCI_Reset
  • 9:07 - 9:12
    command will not necessarily perform a
    hardware reset. This is implementation
  • 9:12 - 9:17
    defined. Then I looked into the Cypress
    and Broadcom chips and saw, yeah, so if
  • 9:17 - 9:22
    you do each day reset, it's obviously not
    a full hardware reset, it's just flashing
  • 9:22 - 9:27
    some queues connection stuff here and
    there. So there is definitely a memory
  • 9:27 - 9:34
    area where you could put your exploit and
    it would be persistent. So then you might
  • 9:34 - 9:39
    say, yeah, OK, so what do I do? I don't
    know. I put my smartphone into flight mode
  • 9:39 - 9:46
    for a hard reset. That usually doesn't
    work. You might also like reboot your
  • 9:46 - 9:50
    phone. In most cases, this works. For some
    other coexistence stuff, I had the
  • 9:50 - 9:54
    impression that sometimes so it's a bit
    strange, it might not necessarily like,
  • 9:54 - 10:03
    reset. Turning off for a while might hard-
    reset the chip I think. Or you just put
  • 10:03 - 10:08
    your smartphone in a blender and then.
    Yeah. So that might turn off the Bluetooth
  • 10:08 - 10:16
    chip finally. Yeah. So the next issue is
    so let's say we have an exploit running
  • 10:16 - 10:21
    there, but we first need an exploit. So
    the very first step is still missing as a
  • 10:21 - 10:26
    building block. And after the talk last
    year, I did some stuff with the unicorn
  • 10:26 - 10:32
    and fuzzing on the chip and it was super
    slow. And then suddenly Jan showed up and
  • 10:32 - 10:39
    Jan said, Hey, I want to build a fully
    emulated chip for superfast fuzzing and
  • 10:39 - 10:43
    attach it to Linux and everything should
    like run on the real -- like as on a real
  • 10:43 - 10:47
    system, just the over the air input will
    be fast. And I was like, you cannot do
  • 10:47 - 10:51
    this for a master thesis. And then he was
    building that thing within three months
  • 10:51 - 10:57
    and the remaining three months he was
    writing a thesis and e-mails to vendors.
  • 10:57 - 11:03
    So here we go. What does Frankenstein do?
    So it's running on an evaluation board of
  • 11:03 - 11:08
    that, yeah, it's just a normal Bluetooth
    Bord that's connected to a Linux host over
  • 11:08 - 11:15
    UART and a modem over the air and then you
    would snapshot that thing and emulate it
  • 11:15 - 11:21
    and give it fast input attached to the
    real host. And that means that if you find
  • 11:21 - 11:25
    some vulnerability, it might be within all
    the components or it might also be under
  • 11:25 - 11:30
    Linux host or it might be something that
    is full stack. So you have something that
  • 11:30 - 11:35
    starts on the chip, gets to the host, the
    host requests further things and then it
  • 11:35 - 11:39
    goes back to the chip. So you could build
    like quite complex stuff. And for this I
  • 11:39 - 11:45
    have a short demo video. So the reason why
    I do this as a video is that it might
  • 11:45 - 11:50
    happen that it finds heap overflows
    otherwise. And then also it's not super
  • 11:50 - 11:55
    stable at the moment. So you can see it's
    scanning for LE devices and then Wireshark
  • 11:55 - 11:58
    most of the time would get malformed
    packets, but sometimes it could also get
  • 11:58 - 12:09
    normal packets and like some mesh stuff,
    whatever. So this is Frankenstein running.
  • 12:09 - 12:16
    Ja, so what Jan focused on is early
    connection states. That means stuff
  • 12:16 - 12:22
    where you don't need a pairing. And then
    he found like heap overflows there in very
  • 12:22 - 12:29
    basic package types. So quite interesting.
    And then the stuff was fixed, I think, or
  • 12:29 - 12:33
    hope, whatever. So at least like in very
    recent devices and then the iPhone 11 came
  • 12:33 - 12:38
    out and in contrast to the specification,
    over the air, the iPhone 11 says, hey, I'm
  • 12:38 - 12:43
    Bluetooth 5.1. I was like, wow, first
    consumer device, Blueotooth 5.1. And I was
  • 12:43 - 12:48
    like, I don't really mind my way of the
    exploitation as long as I can get code
  • 12:48 - 12:53
    execution on chip. So if it is with user
    interaction and a pairing and whatever, I
  • 12:53 - 12:58
    don't care as long as I get code execution
    on it. And then I was like, okay, let's
  • 12:58 - 13:03
    add some fuzz cases to Frankenstein,
    continue fuzzing. And then I found that
  • 13:03 - 13:08
    specific evaluation board that Jan was
    building this for has a problem with the
  • 13:08 - 13:15
    heap configuration for certain packet
    types. And so if you change that, you
  • 13:15 - 13:19
    would hard-brick the device. I mean, I
    bricked two evaluation boards trying to
  • 13:19 - 13:25
    fix stuff. So, yeah, it's just
    bricked. And so that means for me to
  • 13:25 - 13:30
    continue fuzzing to write like to port
    something like 200 handwritten hooks to
  • 13:30 - 13:36
    another evaluation board. It's almost
    running. So there's just some stuff with
  • 13:36 - 13:40
    thread switching that's not super smooth
    yet, but like it's almost on the next
  • 13:40 - 13:46
    board. And further plans are to add more
    hardware. So we're also working on the
  • 13:46 - 13:53
    Samsung Galaxy S 10 and probably a MacBook
    to get it in there. So then it would not
  • 13:53 - 13:57
    just be Linux, but at least macOS, maybe
    Android. I don't know yet. And another
  • 13:57 - 14:01
    thing that would be cool and also we
    didn't build yet, but it might be feasible
  • 14:01 - 14:08
    with some USRP X310 over PCI Express and
    with FPGA and all the fancy stuff to get
  • 14:08 - 14:13
    real over the air input, which then would
    mean that you would have a full queue like
  • 14:13 - 14:20
    from over the air real Bluetooth packets
    going all the way up and then to a host
  • 14:20 - 14:24
    and the way back. And you could also use
    that just to test your new emulation
  • 14:24 - 14:31
    scheme or whatever you want to change. So
    not just security. Ja, so the next thing
  • 14:31 - 14:37
    is, so if you have code execution, what do
    you do with it? And the normal approach is
  • 14:37 - 14:43
    to try to go all the layers up. But there
    might also be some chip level escalation
  • 14:43 - 14:50
    and you might immediately see it on the
    next picture. So this is from a Broadcom
  • 14:50 - 14:56
    chip, but that's something that you would
    also see in many other chips, which is
  • 14:56 - 15:00
    that you have a shared antenna. And you
    could also have two antennas, but they are
  • 15:00 - 15:04
    both on 2.5GHz and it's in the very same
    smartphone super close next to each other
  • 15:04 - 15:08
    and you would get interference. So usually
    you just have the same antenna and do some
  • 15:08 - 15:13
    coordination like when it's Bluetooth
    sending, when it's Wi-Fi sending so that
  • 15:13 - 15:19
    they don't interfere. And this feature is
    called coexistence and there is tons of
  • 15:19 - 15:24
    coexistence interfaces. So this is just
    the one from Broadcom. And when I saw it,
  • 15:24 - 15:29
    I was like, oh, Francesco, let's look into
    this. You know, all the Wi-Fi stuff, I
  • 15:29 - 15:33
    know all the Bluetooth stuff let's do
    something. And he was like, no, it's just
  • 15:33 - 15:37
    it's just a marketing feature so that it
    can like sell one chip for the price of
  • 15:37 - 15:42
    two chips or something. And I was like,
    no, no, no, it must be an exploitation
  • 15:42 - 15:48
    feature. So, and then to end this
    discussion, I went to Italy for eating
  • 15:48 - 15:53
    some ice cream and saw reality somewhere
    in between. It's more like it's hardcoded
  • 15:53 - 15:58
    blacklisting for wireless channels and
    stuff. It's traffic classes for different
  • 15:58 - 16:03
    types of traffic for Bluetooth and Wi-Fi.
    And you can look it up in tons of patents
  • 16:03 - 16:09
    and it's like super, super proprietary.
    And so we let's say we played a game which
  • 16:09 - 16:14
    was like I tried to steal his antenna and
    he tried to steal my antenna. And so it
  • 16:14 - 16:19
    turned out, if you do that, yeah, you can
    turn off Wi-Fi via Bluetooth, Bluetooth
  • 16:19 - 16:25
    via Wi-Fi. And then also like on most
    phones, you need to reboot them and some
  • 16:25 - 16:28
    of them even reboot them themselves. So
    this is just like a speed accelerated
  • 16:28 - 16:34
    thing with an Samsung Galaxy S 8 that is
    not up to date. For iPhones, you would
  • 16:34 - 16:39
    just immediately see a reboot without any
    interaction of things going off and on. So
  • 16:39 - 16:43
    Broadcom is still in the process of fixing
    it. I don't know if they can fix it, but
  • 16:43 - 16:47
    they said they could fix it. But something
    you should definitely fix is like the
  • 16:47 - 16:50
    driver itself so that the smartphone
    reboots and so on. So I don't know. I
  • 16:50 - 16:56
    thought it would be fixed, actually, in
    iOS 13 because it mentions Francesco and
  • 16:56 - 17:01
    me, but still on 13.3 I don't know, it,
    it's still - um - you can
  • 17:01 - 17:04
    still crash the iPhone that way. But
  • 17:04 - 17:08
    it's just some resource blocking so it's
    like not super dangerous thing, I would
  • 17:08 - 17:14
    say. And you still need a Bluetooth RCE
    before you could do it and so on. But
  • 17:14 - 17:21
    still not cool that it's still not fixed.
    Yeah, so what about the other stacks and
  • 17:21 - 17:27
    the escalations? So there is tons of
    different Bluetooth stacks, so it's really
  • 17:27 - 17:33
    a mess. And obviously because of
    Frankenstein, we had this first Linux
  • 17:33 - 17:39
    Bluetooth stack attached and so on. But,
    yeah. So what has been there for a
  • 17:39 - 17:44
    wireless 2017, these BlueBorne attacks,
    you might have heard of them. And they
  • 17:44 - 17:47
    found escalations like on Android,
    Windows, Linux, iOS, whatever. And then
  • 17:47 - 17:53
    you might say, like in security, you often
    say, so someone looked into it. It must be
  • 17:53 - 17:58
    secure now. And then there's so many
    features coming. So there's all these IoT
  • 17:58 - 18:02
    devices. So everybody nowadays has
    wireless headphones and fitness trackers
  • 18:02 - 18:07
    and Bluetooth always on. And in the Apple
    ecosystem, it's really a mess. So if you
  • 18:07 - 18:11
    have more than one Apple device, you would
    have Bluetooth enabled all the time.
  • 18:11 - 18:14
    Otherwise you couldn't use a lot of
    features. And then there is like stuff
  • 18:14 - 18:18
    like Web Bluetooth so Bluetooth LE
    support from within the browser. So it's
  • 18:18 - 18:23
    like a lot of new attack surfaces that
    arised since then. I think -- So that's
  • 18:23 - 18:32
    more my personal estimation is, 2020 might
    be more BlueBorne like attacks. The
  • 18:32 - 18:35
    saddest Bluetooth stack somehow is the
    Linux Bluetooth stack. So I don't want to
  • 18:35 - 18:39
    blame the developers there. I mean, it's
    not their fault, but it's not enough
  • 18:39 - 18:44
    people contributing to that project. And
    if you would try to to analyze something
  • 18:44 - 18:48
    that is going on in the stack and you
    don't really know what is going on, you
  • 18:48 - 18:52
    would do git blame or whatever and you
    would always see the same guy as the
  • 18:52 - 18:57
    commiter. So at least if you're on a
    specific problem, then there's only one
  • 18:57 - 19:02
    person committing there. And so the
    picture down there actually has the same
  • 19:02 - 19:07
    guy thrice. So this is also a bit of a pun
    here intended. We did some fuzzing in
  • 19:07 - 19:12
    there. We still need to evaluate some of
    the results. So yeah, but I also feel like
  • 19:12 - 19:17
    nobody's really using it and it's kind of
    sad. I mean, there's some Linux users, I
  • 19:17 - 19:23
    guess, but ... Yeah. Then there is the
    weirdest stack I would say. So there's the
  • 19:23 - 19:28
    Apple Bluetooth stack and this one is
    actually three. So there is there is the
  • 19:28 - 19:31
    MacOS Bluetooth stack. There's an iOS
    Bluetooth stack. They are definitely
  • 19:31 - 19:35
    different. And then there is a third
    embedded one, for example, for the
  • 19:35 - 19:43
    AirPods. They are all running different
    different things. So, yeah, whatever. And
  • 19:43 - 19:48
    then they also have tons of proprietary
    protocols on top of their Bluetooth stuff
  • 19:48 - 19:52
    that they're also very special. And I had
    like at least two students, just one
  • 19:52 - 19:58
    porting it to iOS one to MacOS. And then
    we also have students working on the other
  • 19:58 - 20:03
    protocols that are on top of Bluetooth.
    And if you look into this, it's like, what
  • 20:03 - 20:07
    the hell? It's really hard to reverse
    engineer because you have like three
  • 20:07 - 20:11
    different implementations and then
    sometimes you're like: "yeah, okay. Maybe
  • 20:11 - 20:16
    it's also just bad code." And in the end,
    so from what I saw so far, I would say
  • 20:16 - 20:24
    that it's kind of both. And then there is
    the stack that I played also lots around
  • 20:24 - 20:29
    with, which is the Android Bluetooth
    Stack. And they did a lot for the security
  • 20:29 - 20:33
    in the recent releases. And it annoys me
    so much that when I want to get internal
  • 20:33 - 20:37
    blue running on it, I just echo to the
    serial port instead so I bypass everything
  • 20:37 - 20:43
    that the operating system does. And so
    something that Android cannot do, which
  • 20:43 - 20:46
    Apple does, is so Apple has all the
    proprietary protocols. And if something
  • 20:46 - 20:50
    goes wrong, they immediately cut the
    connection. But Android doesn't because of
  • 20:50 - 20:55
    compatibility and stuff. So you could just
    send garbage for like two minutes and try
  • 20:55 - 20:58
    and see what happens. And it would
    continue listening and asking and
  • 20:58 - 21:05
    confirming. But that's kind of an
    overall design issue, I think. And yet
  • 21:05 - 21:11
    there's Windows and I couldn't find any
    students to work on Windows. laughter
  • 21:11 - 21:19
    If someone wants to do this, that would be
    great. And so another stack that's kind of
  • 21:19 - 21:26
    missing here is LTE. And I would call this
    like the long term exploitation plan. So
  • 21:26 - 21:31
    it's not. I think if the long term
    evaluation, evolution, whatever, but
  • 21:31 - 21:37
    exploitation I think is the best thing for
    the E. So we have like tons of wireless
  • 21:37 - 21:43
    stuff where we are working on and I mean
    like even PowerPC. And then there is
  • 21:43 - 21:48
    Qualcomm and they have they have this
    Qualcomm hexagon DSP. I hate it so much.
  • 21:48 - 21:53
    So there's even source code leaks for
    their LTE stuff. But it's just such a pain
  • 21:53 - 21:59
    to work on it. So you might have noticed
    is that ARM has this LTE project with
  • 21:59 - 22:05
    Qualcomm, but it's just not fun. But other
    people were doing a lot in this area and
  • 22:05 - 22:12
    they've already presented here today and
    yesterday. So the first thing is the SIM
  • 22:12 - 22:18
    card in the phone. So the SIM cards should
    be a thing like. From from my perspective,
  • 22:18 - 22:24
    that should be secure because it protects
    your key material. And then it runs tons
  • 22:24 - 22:27
    of applications. I don't know. And then
    you can exploit them and get the victim's
  • 22:27 - 22:31
    location, dial premium numbers and launch
    a browser. And then I didn't really
  • 22:31 - 22:39
    understand, like there's just this WIB set
    browser whatever, and then there's launch
  • 22:39 - 22:42
    browser what, is it? And I think it even
    launches a browser then on the smartphone,
  • 22:42 - 22:48
    whatever. It's just crazy. And then I was
    trying to call Deutsche Telekom and I'm a
  • 22:48 - 22:52
    business customer. So it's just like
    three minutes for a call for me. So giving
  • 22:52 - 22:58
    a call there is nice. And then the first thing
    they told me is: "You are secure. We know
  • 22:58 - 23:03
    you have three SIM cards and they are all
    up to date." So I have to say, one of them
  • 23:03 - 23:08
    is more than 10 years old, but maybe it's
    up to date. And my answer is like, what
  • 23:08 - 23:13
    exactly is running on my SIM card? They of
    course not answered. So yeah, something is
  • 23:13 - 23:17
    running there. If you want to know more
    about SIM cards, there has been talk
  • 23:17 - 23:23
    already yesterday evening and it's already
    online. And then there's also a lot of
  • 23:23 - 23:27
    people looking into LTE. And I think the
    most popular one is to work by Yongdae
  • 23:27 - 23:33
    Kim. He did even some LTE fuzzing
    framework that he didn't release publicly
  • 23:33 - 23:39
    so far, because of the findings. So it's
    like, should you publish? Should you not
  • 23:39 - 23:44
    publish? But so the findings are super
    interesting. And he also has students here
  • 23:44 - 23:52
    who just did a talk this morning.
    Responsible disclosure. So that's the
  • 23:52 - 23:58
    thing. When you find stuff you need to do
    is responsible disclosure. And so I said
  • 23:58 - 24:02
    Jan was writing a lot of e-mails. And one
    of the first that he wrote was to ThreadX,
  • 24:02 - 24:08
    because ThreadX is the operating system
    that runs on the Broadcom Bluetooth
  • 24:08 - 24:14
    chip. And so he said, like, your
    heap is a bit broken and does not have any
  • 24:14 - 24:19
    checks. You could implement the following
    checks, which are pretty cheap and it
  • 24:19 - 24:22
    should be cool. And then I could not
    attack it anymore. And then ThreadX was
  • 24:22 - 24:28
    answering, which was a bit unexpected,
    that they already knew about this
  • 24:28 - 24:33
    exploitation technique and that it is up
    to the application to not be vulnerable to
  • 24:33 - 24:38
    memory corruption, so not to cause any
    memory corruption. So it's the programmers
  • 24:38 - 24:42
    fault if they do something and it's not
    the operating system that has to take care
  • 24:42 - 24:52
    of the heap. Okay. Yeah. Next issue. So
    the bin diffing and the testing if a
  • 24:52 - 24:57
    vulnerability is still there. So you might
    not always get feedback from all the
  • 24:57 - 25:01
    vendors. If they fix it, they may just fix
    it at a certain point in time and then you
  • 25:01 - 25:05
    tell them all we tested the next release
    and it's still vulnerable. And then they
  • 25:05 - 25:08
    would say, like for Samsung said, Yeah, we
    cannot send your patches in advance
  • 25:08 - 25:12
    without an NDA because Broadcom, blah,
    blah, blah and so on and so forth. And
  • 25:12 - 25:17
    then Broadcom offered to send us patches
    in advance. And I said, Yeah. Nice. And I
  • 25:17 - 25:22
    also sent them a device list because they
    already knew it from the previous process.
  • 25:22 - 25:25
    So if you tell them the following 10
    devices have an issue, then you would
  • 25:25 - 25:29
    already know that we can test those
    devices anyway. And so and after I sent
  • 25:29 - 25:34
    them the list, they said: "Oh, wait, but
    you need an NDA." So no, I mean, we are
  • 25:34 - 25:41
    doing this for free anyway. And signing an
    NDA, I wouldn't do that. Yeah. So overall,
  • 25:41 - 25:45
    it also did Broadcom Product Security
    Incident Response Team is a bit strange so
  • 25:45 - 25:50
    they wouldn't hand out any CVEs. And what
    I mean what I do is like I first get a CVE
  • 25:50 - 25:53
    and then informed them and the other
    customers because I also don't get any
  • 25:53 - 25:56
    incident number or something. So if I
    wouldn't do this, I wouldn't have any
  • 25:56 - 26:03
    number to refer a vulnerability to. And
    well, at least they are also not doing
  • 26:03 - 26:07
    that much legal trouble. But it's just.
    Yeah, not really something happening
  • 26:07 - 26:14
    there. But some of their customers were
    nice at least to my students, so they paid.
  • 26:14 - 26:18
    So one customer, they don't want to be
    named here, but they payed to fly to DefCon
  • 26:18 - 26:22
    for one of my students and Samsung gave a
    bounty off one thousand dollar. I mean,
  • 26:22 - 26:27
    still I mean we are in the range of of
    very very more expensive exploits if it
  • 26:27 - 26:31
    would be on the black market, but for
    students it's definitely nice. Yeah.
  • 26:31 - 26:35
    Responsible disclosure timelines. So this
    is something that I thought like maybe
  • 26:35 - 26:38
    some of this responsible disclosure
    timeline is just because of how I
  • 26:38 - 26:42
    communicate with the vendor. And sometimes
    I'm writing e-mails like a five year old
  • 26:42 - 26:49
    or something - I don't know. But actually.
    So this is a timeline of Quarkslab, who
  • 26:49 - 26:54
    also found just this year vulnerabilities
    in Broadcom Wi-Fi chips. And so they've
  • 26:54 - 27:01
    also asked about NDA and then also their
    exploit timeline. It's a bit fun because
  • 27:01 - 27:05
    they had similar exploitation strategies
    as the very first exploit that you could
  • 27:05 - 27:11
    see by Google Project Zero and then, yeah,
    more distorted timeline, whatever. And in
  • 27:11 - 27:19
    the end, well. So it's just taking time.
    And again, no CVE id issued and so on and
  • 27:19 - 27:26
    so forth. So it's the very same stuff for
    others, which is pretty sad. And then so
  • 27:26 - 27:31
    for Cyprus, which is partially having
    source code of Broadcom, it also
  • 27:31 - 27:37
    manufactures chips. It's also very slow
    for the response of disclosure. And then I
  • 27:37 - 27:40
    got told by other people, like, yeah, if
    you would disclose something to Qualcomm,
  • 27:40 - 27:46
    it also takes very long. And luckily we
    didn't find something in an Intel CPU. But
  • 27:46 - 27:50
    yeah, there is ... so on the wireless
    market, there still so many other vendors
  • 27:50 - 27:56
    to become friends with. So yeah. So
    practical solutions to end my talk. What
  • 27:56 - 28:01
    could you do to defend yourself if you
    don't have a tinfoil hat? Other things I
  • 28:01 - 28:07
    can recommend is the secure Wi-Fi set up.
    So don't use antennas, just use antenna
  • 28:07 - 28:13
    cables. If you do that in our lap a lot.
    So this is a setup by Felix. And so when I
  • 28:13 - 28:18
    was sending my slides to Francesca in
    advance she just said "cool, I have the
  • 28:18 - 28:24
    same one right now at my desktop". So it's
    a very common setup. Maybe not at your
  • 28:24 - 28:30
    home, but for us it is. Or you'd just go
    to the air-gapped device. So this is my
  • 28:30 - 28:37
    Powerbook 170, that's a really great
    device. Almost impossible to get it online
  • 28:37 - 28:45
    and it has Word and Excel.
    So ask all the questions.
  • 28:45 - 28:54
    Applause
  • 28:54 - 28:58
    Herald Angel: Thank you very much to
    jiska. We still have several minutes left.
  • 28:58 - 29:03
    You will find eight microphones in the
    room. Please line up in behind the
  • 29:03 - 29:08
    microphones to ask a question. And the
    first question goes to the Internet.
  • 29:08 - 29:13
    Signal Angel: So at jiska, the question
    is, are the Bluetooth issues you are
  • 29:13 - 29:18
    talking about also present in Bluetooth
    Low Energy IoT devices.
  • 29:18 - 29:23
    jiska: Yes. So, I mean, there is IoT
    devices, I cannot tell the vendor, but
  • 29:23 - 29:29
    there is also some popular devices that
    have like Cypress Broadcom chips and then
  • 29:29 - 29:33
    it's even worse because they don't have a
    separate stack, but often they have an
  • 29:33 - 29:37
    application running on the same arm core
    and then you don't even need any
  • 29:37 - 29:40
    escalation.
    Herald: All right. We have another
  • 29:40 - 29:43
    question at the microphone number one,
    please.
  • 29:43 - 29:47
    Microphone 1: Thank you for the talk. My
    question is, could you like did you
  • 29:47 - 29:54
    actually when you fuzzed the Bluetooth low
    energy chip, did you when you managed to
  • 29:54 - 29:58
    get code execution, did you actually
    climb up the protocol?
  • 29:58 - 30:01
    Did you like access Bluetooth profiles or
    something like this?
  • 30:01 - 30:07
    jiska: Ah, so we, for example with the
    link key extraction, we were building some
  • 30:07 - 30:15
    proof of concepts. But so it depends. We
    don't currently have like a fully exploit
  • 30:15 - 30:19
    chain in terms of first on the chip and
    then on the host. We have something that
  • 30:19 - 30:26
    goes directly on some hosts, but yeah,
    there's tons of things there to do. Sorry?
  • 30:26 - 30:30
    Microphone 1: Yeah. And when you fuzz the
    ... how did you actually fuzz the chip
  • 30:30 - 30:34
    itself? How did you extract the
    firmware from the chip?
  • 30:34 - 30:37
    jiska: So there is ... so Broadcom and
    Cyprus are very nice because they have a
  • 30:37 - 30:42
    read RAM command so you don't need any
    secure bypass or something. And for the
  • 30:42 - 30:51
    evaluation kits, there is even symbols
    that we found in it. So symbols only means
  • 30:51 - 30:56
    like function names and global variable
    names, that's it. But that's something to
  • 30:56 - 30:59
    work with.
    Herald: Thank you. Another question from
  • 30:59 - 31:03
    the Internet, please.
    Signal: Would you like the return of
  • 31:03 - 31:06
    physical switches for
    the network controller?
  • 31:06 - 31:11
    jiska: Yeah, so that would be nice to like
    physically switch it off. Actually, I
  • 31:11 - 31:15
    don't know where Paul is, but he is
    building ... There is Paul. He is building
  • 31:15 - 31:22
    such a device. When is your talk at 10
    o'clock. Paul is giving a talk about a
  • 31:22 - 31:26
    device where you have a physical
    controller to switch off your wireless
  • 31:26 - 31:29
    stuff.
    Herald: OK. The next question is again
  • 31:29 - 31:34
    microphone number one, please.
    Microphone 1: Yes. Thank you. We just
  • 31:34 - 31:39
    bought a new car and by because
    connecting the Bluetooth of my phone to
  • 31:39 - 31:46
    the car's system was very, very hard. And
    I had to reboot the radio several times.
  • 31:46 - 31:52
    And then I found a message that the radio
    must be directly connected to the CAN-bus
  • 31:52 - 31:57
    of the car. So you have a blueooth stack
    connected directly to a CAN-bus. It was a
  • 31:57 - 32:02
    very cheap car. But if you
    have an idea of what this means then...
  • 32:02 - 32:08
    jiska: Can you can you borrow me that car?
    Microphone 1: It's a Toyota Aygo, you can
  • 32:08 - 32:14
    have it everywhere.
    jiska: Well, that shouldn't be.
  • 32:14 - 32:17
    Herald: Alright, do we have a question at
    microphone number eight, please?
  • 32:17 - 32:22
    Microphone 8: Hi and thank you for the
    talk first of all. Uh well, if I
  • 32:22 - 32:27
    understood correctly, you said that the
    vendors didn't mention if they fixed it or
  • 32:27 - 32:32
    not or they don't know if they fixed it.
    jiska: Umm, yeah. So it depends. I know
  • 32:32 - 32:37
    like so if you look into the Android
    security updates, so for example, August 5
  • 32:37 - 32:41
    has some Broadcom issue that was fixed and
    I know which one that was and so on and so
  • 32:41 - 32:47
    forth. But so then it also means I like to
    get that one onto a Samsung device. I
  • 32:47 - 32:50
    would need ... so they wouldn't build it
    in the August update, but only in the
  • 32:50 - 32:55
    September update and then release it to
    Europe, which is like mid or end of
  • 32:55 - 32:59
    September. And then I could download it to
    my phone and test it over the air if it's
  • 32:59 - 33:07
    like really fixed and so on and so forth.
    So it's ... there is like the first thing
  • 33:07 - 33:10
    is like that is listed publicly that it is
    fixed. And then the next thing is that it
  • 33:10 - 33:15
    is actually fixed and it's really hard.
    And for the communication with Apple, I
  • 33:15 - 33:18
    don't know. So sometimes they fix it
    silently without mentioning us. And then
  • 33:18 - 33:24
    there's this iOS 13 thing where they
    mentioned us but didn't fix it. So, yeah.
  • 33:24 - 33:28
    Microphone 8: Were there any issues like
    that they found and they didn't know if
  • 33:28 - 33:31
    they fixed it or not. And you did like
    patch-diffing or something like that?
  • 33:31 - 33:35
    jiska: Yeah, I did a lot of patch-diffing
    and I currently have a student who is
  • 33:35 - 33:40
    doing nothing else than developing diffing
    tools for the particular issues that I
  • 33:40 - 33:43
    have.
    Microphone 8: And did you find that they
  • 33:43 - 33:46
    fixed it or not?
    jiska: So it's first of all ... so we are
  • 33:46 - 33:51
    ... so first of all, it's currently about
    speed and stuff and I gave him some some
  • 33:51 - 33:54
    iPhone stuff for the next task.
    But yes, it's work in progress. So most of
  • 33:54 - 34:00
    the other stuff I did by hand, so I also
    have a good idea about like what a changed
  • 34:00 - 34:05
    within each kind of chip generation.
    Microphone 8: Okay. Thank you very much.
  • 34:05 - 34:09
    Herald: All right. We had another question
    from the Internet.
  • 34:09 - 34:14
    Signal: Yes. So from Mastodon, how exactly
    was the snapshot of the Samsung Bluetooth
  • 34:14 - 34:18
    stack extracted for the fuzzing process?
    jiska: The Samsung is ... so for Samsung
  • 34:18 - 34:24
    we have snap shotting, but for Samsung, we
    don't have the rest of Frankenstein. The
  • 34:24 - 34:31
    other stuff is running on an evaluation
    board. So the first part is mapping all
  • 34:31 - 34:35
    the hardware registers. So this is the
    first trip that runs and tries to find
  • 34:35 - 34:41
    like all the memory regions. And once that
    is done, there is a snapshotting hook that
  • 34:41 - 34:44
    you set to the function. So let's say you
    want to look into a device scanning so you
  • 34:44 - 34:49
    would set the function into device
    scanning. And once that it's called by the
  • 34:49 - 34:54
    Linux stack, he would freeze the whole chip
    and disable like other interrupt stuff,
  • 34:54 - 34:58
    whatever that would kill it otherwise and
    then copy everything that is in the
  • 34:58 - 35:03
    registers ... so that is kind of the snap
    shotting. And once you have a snapshot,
  • 35:03 - 35:08
    then you can try to find everything that
    kills your emulation like interrupts again
  • 35:08 - 35:13
    and thread switches and so on.
    Herald: All right. We have one more
  • 35:13 - 35:16
    question from microphone, number one,
    please.
  • 35:16 - 35:21
    Microphone 1: OK. So do you think that
    open source, the driver or that open
  • 35:21 - 35:26
    hardware design will improve the
    situation?
  • 35:26 - 35:31
    jiska: So open source? I think it would
    improve the situation. But also one thing.
  • 35:31 - 35:37
    So I had to talk at mrmcd in September
    this year. Another thing which is not
  • 35:37 - 35:41
    about open source is that the patching
    capabilities of the Broadcom bluetooth
  • 35:41 - 35:48
    chips are very limited in terms of how
    much can be fixed. So just open sourcing
  • 35:48 - 35:54
    wouldn't help Broadcom, for example.
    Microphone 1: Like you mean like the
  • 35:54 - 36:00
    firmware is burnt into the chip and it's
    limited to ...
  • 36:00 - 36:01
    jiska: Yeah
    Microphone 1: Yeah, it's limited, right?
  • 36:01 - 36:06
    jiska: Yes, it's in the ROM. And then you
    have patch ROM slots and you have like 128
  • 36:06 - 36:11
    patch ROM slot and each patch ROM slot is
    a four byte override breakpoint thingy
  • 36:11 - 36:15
    that branches then somewhere else into
    RAM. And then RAM is also limited.
  • 36:15 - 36:21
    So you couldn't like branch into large
    chunks of RAM all the time. Yeah.
  • 36:21 - 36:25
    Microphone 1: Thank you.
    Herald: All right. If there are not any
  • 36:25 - 36:28
    more questions?
    jiska: Internet!
  • 36:28 - 36:32
    Herald: Internet? Oh, more Internet
    questions. Then, please go ahead.
  • 36:32 - 36:36
    Signal: Yes. So winfreak on Twitter asks
    what stack was tested when mentioning
  • 36:36 - 36:41
    Android? There are several and Google is
    convinced rewriting it every year is a
  • 36:41 - 36:45
    good idea.
    jiska: Ah, yeah. So this stuff that's like
  • 36:45 - 36:51
    the standard stack that runs on a Samsung
    phone for example. So I think, like for
  • 36:51 - 36:55
    the main entry, there's only one ... I
    know that there's like legacy stacks, but
  • 36:55 - 37:02
    they switch to only one.
    Herald: So Signal Angel, do you have more
  • 37:02 - 37:10
    for us?
    Signal: Yes. What is your hat made of?
  • 37:10 - 37:18
    jiska: My hat? So it's like aluminum foil.
    And then there is the cyber cyber thingy.
  • 37:18 - 37:26
    So that's also important. Yeah. So but as
    I said, it doesn't really help. It would
  • 37:26 - 37:32
    more help to put the smartphone in a
    blender, for example.
  • 37:32 - 37:36
    Herald: Alright. Thank you very much for
    this awesome talk. Give her a huge round
  • 37:36 - 37:38
    of applause to jiska.
  • 37:38 - 37:41
    applause
  • 37:41 - 37:44
    36c3 postroll
  • 37:44 - 38:08
    subtitles created by c3subtitles.de
    in the year 2020. Join, and help us!
Title:
36C3 - All wireless communication stacks are equally broken
Description:

more » « less
Video Language:
English
Duration:
38:08

English subtitles

Revisions