okay it's a good morning everyone I hope
you enjoyed the conference so far and
thanks for joining today's session so
I'm Yael meat and CTO and co-founder of
sky Keough which got acquired roughly a
year ago by Symantec and ever since I
serve as vice president of modern OS
security which is natural what we do is
research and also develop security
solutions for modern OS such as iOS and
Android hey I'm a voyeur Yankee and I
have more than 10 years of experience in
the security industry I joined the Ale
as part of the first Europa task IQ
about six years ago and since then I was
working at schedule today I'm leading
the little steam off had a modern life
and division at Symantec ok so today we
are here to talk about iOS trust
checking and I must say that the one of
the things I find pretty interesting
about that research is that it's
actually we're going to discuss a
variety of features and design decisions
in iOS that each of them look by itself
is totally legitimate and benign but as
well so today in the presentation when
you combine all of those together you
come you come into concerning and
certainly unexpected attacks against iOS
devices so what we plan to do today in a
nutshell is first of all you know give
you the background for how we got to
this research as well as discuss some
technical details that are the
foundation of a lot of the features
we'll be discussing today a lot of the
attacks then will we discuss what iOS
rush trust jacking is and then come and
give you a bunch of demonstrations that
show real world potential attacks
against iOS devices will conclude with
you know summary and some
recommendations for individuals for
organizations and for developers to
mitigate the problems as well as this
car
some of the changes Apple has done
following our responsible and
coordinated disclosure process around
this issue so let's start with the story
of a how which started looking on this
kind of a feature for one day I was
working at the office with several
devices connected to my computer and I
wanted to view the system logs of one of
the devices so it was a very cool
library called the Lib I mobile device
which lets you do a lot of stuff with
iOS devices and will see it in the
continuum of the presentation and and I
just use a command lets me view the log
so I used it and started think some logs
roll into my console and and when I
started playing with the device I
suddenly said the logs weren't correlate
with what I didn't device which was a
bit well so I started looking deeply
into it and they found out the logs are
not the lots of the device at all if it
is connected to my computer but other
lots of another device which one of my
team leader in front of my team members
that was in another woman
of it and so this got me thinking a sigh
and try to a look and start to look on
what happened then and this getting gets
into this ethers because we want to see
what happened there and what an attacker
can do with such an access to a device
so started a quick background on what
happened behind the scene when a device
connected to a new computer or computer
all of the arrows so there are several
demons that kick into action right when
you connect your device to computer the
first demon if the USB daemon which
basically look for the Devon you a
device on the other side it will start
charging port of and start the initial
communication between the computer and
the device and just out all the fan
sessions the youth B MOOC is a very very
important demon here which allows
multiplexing a lot of different
connections above the same USB
connection lockdown demon if another
demon that allows running services on
the remote on the remote device and also
is taking a very significant part in the
authentication mechanism and of the
demon that that in charge of the
authentication of the device and
creating this relation between the iOS
device and the computer so let's let's
start by discussing some previous
attacks around you know connected
devices so the first one is actually a
serious of different publications that
took place at the beginning of that
decades those publications talked about
the notion especially in the early days
of iOS devices that you know the USB
cable that is obviously used for
charging our devices is also a very
important vehicle that has a data
channel right so in those cases one
would create a malicious charger okay
and then when a user of a new iPhone
iPad etc would connect his device to the
charger the chowder
could have no soul data changed data
side of the malicious app etc and one
things up in up indeed I think iOS 7 is
the following dialogue what can you
please read us what is showing up in the
dialogue yeah so we said tractive
computer your settings and data will be
accessible from this computer when
connected and you have a choice whether
you want to trust or don't trust and the
control so also the bath looks like a
way to make us a well that if we connect
to something that we don't trust
maybe we shouldn't trust it if we want
we can trust it so how many of you are
OS users by the way well quite a lot how
many of you have seen that dialogue ok
everyone how many of you have ever in
anything
click on the trust button awesome I see
almost everyone raising the head and the
ones that don't I suspect your input but
thank you okay so so let's continue and
talk about another another issue that
has rised over the years and this is
video jacking in natural it's another
incarnation of the notion of connected
devices so if you think about the
Lightning connection in iOS devices
it obviously charges your device it has
a data channel right but it is also
supporting video output capabilities
like the HDMI interface so this is not
surprising at all if you go and with
your device connected to a some charger
in the airport
technically wise as long as your device
is connected to the charger the charger
could actually watch everything you have
in your stream that's why it's called
video checking but honestly if we think
about those problems those two problems
the common characteristics of those is
that they are temporal and that a
suspicious user might not fall for it
right if I'm in the airport by the way I
would never
click on trust maybe in the airplane if
a trust there you know in the airplane
sometimes you have those dialogues so I
see a lot of people trusting it but this
is the common characteristics and we are
here to talk with you about a new breed
of attacks that we believe in based on
the feedback we got our applicable to
virtually every iOS users and I think
the first step we're gonna do is is talk
about how do we move from attacks that
rely on physical connection between a
bad actor and a device to work to a
network based attack to a Wi-Fi attack
and one things we did is is look at a
feature that again by itself it's a very
welcomed feature into this a few years
ago by Apple and that is the iTunes
Wi-Fi sync
it's a feature that allows us when we
are at home for example we have our
computer we have
mobile device it allows for a Wi-Fi
synchronisation of the device that's
awesome right but if we look behind the
scenes there are two elements that are
important to understand that mechanism
of tzimmes synchronization relies on
that trust dialog that we discussed just
earlier because when you click on the
trust dialog what actually happens is
that a key pair is generated so that the
device trusts that specific host that
specific computer and the surprising
part that we will discuss throughout
this presentation is that the decision
Apple has made was to actually take all
of those capabilities possible using a
USB connection and have them possible
using a network layer so USB mocks is
actually obstructed through a network
interface so let's discuss and see why
is that so interesting and also so
concerning this is concerning and those
flows of attacks we are going to show
you we call them iOS rough checking and
the common characteristics of everything
you're going to see okay is the
following flow first of all the attacker
has to get the user to click on a trust
button to make a one-time mistake
right but as well so as we'll show at
the rest of the presentation while the
previous attacks I mentioned might not
have everyone fault for them will show
later on why that one time mistake is
actually not really a mistake and it is
applicable virtually to any iOS user we
will discuss this a bit later later but
the common characteristic so everything
will see is the moment we made that
one-time mistake could have happened a
few months ago from that moment an
attacker may be able to do a variety of
actions but all of those actions will be
conducted on the attacker side on the
computer side and the user itself has no
effect on it he has no visibility of it
and that's the problem so so let's start
with the simple demonstration and go
from there cool so whoever named iOS
device it is not connected to my
computer in any
way and what we can do is first of all
we can verify the division device
connected to the computer is a very
simple command which is part of the
Levi's mobile device and labelling and
they considered there is one one device
connected to my computer if you look we
consider that a lot of other commands
that we can initiate and now that we
have a connected device so one of them
is a I device info we just let us say v
and properties of the device the Wi-Fi
MAC address the device name we can feel
its version and a lot a lot of a
metadata info and the other command is
very iDevice v log which is the original
command that I wanted to teach and this
just show me a lot a lot of logs
streaming and the just call it - a lot
of things that happen on the device one
thing interesting point here is that
sometimes app developers tend to use the
analog interface in order to log some
some things that happened on the app for
the backing purposes and when we listen
up they usually tend to leave it over
there so by looking at this
this very spammy a syslog and filtering
it for a specific art you sometimes can
see use occurred and shelves and other
very very sensitive stuff but he's just
not filtered from this a lot and usually
isn't accessible by anyone the last
command that I'll show you if I divide
diagnostic which I will not run but
allows you to do a lot of things such as
a shutdown without the device and can't
be useful for a favor Allah doth attack
thanks thanks for Union and I think that
one of those capabilities are very nice
to have and it's nice to have you know
to be able to do it remotely we want to
dive into this problem more deeply and
talk about a few much more surprising
capabilities that we can do so one of
the notions that I want to mention is
something called the Velo clear image so
think about you know as a developer you
you have your your Xcode your IDE and
you connect your testing device and
obviously when you connect it to the
computer you can do a lot of stuff right
you can analyze it you can debug it you
can install your tested apps etc and one
of the things that are are possible
because of that perfect porting to the
network is to remotely install the
developer image that capability that is
installed by Xcode to the device
physically usually and that allows a
bunch of capabilities so one things that
capability allows is just to take
snapshots screenshots from the device
and one of the things we've done is
create the script that tries to
repeatedly and remotely take a look at
the device so this is my device here and
as I'm using it we can actually see what
I'm doing okay so just a moment I think
the network here is a bit slow
okay
so I think there is a lot a lot a lot of
networking so there is a latency just a
moment
okay okay so it's working again and as
you can see while I'm typing you can
practically see Mike my keystrokes so
you see we can see let's see if you can
see my password to my banking app not a
red one
you can see virtually everything I'm I'm
seeing so it can be take financials to
the bank it can be a bunch of things so
in this case just got an SMS from young
king
and as you can see practically all of my
activity as a victim is being monitored
by the attacker okay so so this is a
demonstration which as we look back into
what we discussed just five minutes ago
we just spotted the ability to
temporarily see and hijack the screen
when you connect it to USB to something
that can be conducted 24/7 by a remote
attacker on the network okay okay so
think another another topic want to
discuss is the backup in the store yeah
so let's start by initiating backup
command to the device this is a standard
command it can be found in the Levi's
mobile device with slight modifications
that we did in order for it in order to
enable it to walk over a wife and not
only one at a table
okay so this start of the back up I will
hope that the network will be fast
enough but let's talk about about what
we'll be able to see in a few moments
and so as we are backing backing up the
device they've won a variant I feature
which if you can encrypt your iOS device
this thing that we we think that
everyone should do but very interesting
thing is that the decision whether the
backup is included or not is being
initiated by the computer you do not
have any anyway on your mobile device to
choose whether the backup will be
encrypted or not once
the computer shows this decision if you
chose to include the backup
later back up who will be encrypted with
the same password and this will be
enforced by the mobile device so the
first decision is done by the computer
but later on it's enforced by the mobile
device and the only way to disable it is
by connecting your device to a computer
and choose to disable the encryption you
sure you have to know the password in
order for it to work if a victim did not
choose at back of the device it creates
a very funny situation in which the
attacker can actually choose to encrypt
the victims device backup so every
backup in the future will be encrypted
the attacker will be able to detect it
of course but the victim want to be able
to decrypt it so it will be basically
locked out from his device therefore the
device backup and won't be able to even
change the password or the movie in
order to a home that's a key it's some
kind of bug and some attack in
some way yeah so this is another reason
for why where we think everyone should
encrypt their own device and should how
powerful because if you want do it
attacker can use both for fare
techniques you know to try and their
video password but it makes it harder
anyway and let's see how the back of
okay so we'll be able to see several
files in the backup directory and the
first three file for the finished file
which contains information about the
device and backup so we'll see the
info.plist file which contains
information about the device and all the
installed apps on the device the
manifest P list which contains a lot of
information about the backup and other
information about the installed app that
was believed is a very very small
finished file which contains basically
information about this specific backup
if it encrypted or not if it's a full or
partial backup and the very the most
interesting file here will be the
manifestly B which is an SQLite 3 file
contains all the files that were backed
up by path and some other a metadata
such as a new name that they got in the
back up all the file path and converted
to a sha-1 file names and are placed in
a directory which is the first two
hexadecimal digit of specific a cache so
let's take a look at the backup we just
did and as when we all mentioned this is
this is practically a full backup it
looks for rather generic so we we need a
way to understand what that backup
contains and hopefully get some cool
stuff out of the back up so so let's
let's do it and let's go to the manifest
DB this is the SQLite database and we'll
start by you know
just looking at other tables look at the
screamer we wanna understand how does
the file's table look like and for that
moment let's let's just look for all the
images all the media files in the backup
that we just did so it's it's classical
SQL query we're looking for the media
directory and we'll be solving this
obviously by by by the file path to look
for the latest images in this case the
first thing we want to show you is what
we mentioned we see from each record we
see something that looks like an hash
it's a sha-1 hash as well as some more
metadata and what we is now doing is
showing you that by looking at the
original path in the Bekaa we can deduce
and see that this is exactly you know
the first like oh this is the sha-1 hash
over of that of that path so we have the
domain or the type of the file and then
we have the full path and we'll just
hash it so difficult we got here and it
should match the hash here so you don't
need to add to do it all the time
because you can just a look at the
manufactory but if you know specific
file you can also you can always get to
it by just one so let's take a look at
the image let's see what we actually got
some interesting stuff here yeah this is
a picture we just took before the
presentation so so I think the next
thing we want to show you is some more
juicy stuff out of the backup we just
did and and what we're going to do is to
look for the SMS for the messages
database again a very very simple query
we will look for where is the SQLite
database that contains the messaging
information out of the device and
again we got it now we'll open that that
database and we'll look for some of the
content inside it okay again looking for
the tables a bunch of tables here I
think we'll start with looking at the
chats look which ads do we have on the
device and and also look at the messages
to try to extract the actual messages
that are stored on the device so this is
look you know it looks very very dirty
obviously it's how to with it that's one
of the things we've done is we've
created a script that automates all of
what we've done and just demonstrating a
pretty print everything all of those
checks that we have them device awesome
so as you can see this is exactly the
correspondence we had on stage and again
we're very excited and happy to have you
here and present ok so I think that the
next thing we want to discuss is is the
notion of of being able to do some more
interesting things on the device in this
case again I want to remind you what
we're able to do is to repeat and create
an environment that is as we are just
physically debugging the device why this
is not our device and we don't have
physical access to it anymore so we
discuss data on a bunch of nuances
around this but the first thing I want
to do is to actually show you the device
and give you I think a pretty nice
demonstration for the kind of things we
can do okay so that's the neck thing
okay so awesome so can you see my screen
first thing I want to show you is that
Facebook app in here we can see what is
Facebook account we'll get into is a
personal page I recommend you to be his
friends as well so so
the Facebook up and the interesting
thing we want to show you is that now or
as the attacker is able to first of all
list all installed apps on the device
and specifically here we see the
Facebook app as well as its package name
and what we actually want to demonstrate
now is the problem of the packaged apps
okay one of the most powerful attacks
are available in general in mobility is
to be able to create a fake version of a
given app can be Facebook what it can
also be you know Salesforce or box or
whatever you do for business and if you
are able to create a repetitive version
of those applications you might be able
to do some awesome stuff
so what we are going to do now is to
actually create a leap a caged version
on Facebook okay and then we're going to
do a bunch of actions that will be very
fast so I want you to be focused this is
well Facebook resides like the real one
we are going to practically upload the
repackaged version on Facebook to a
temporal directory on that device and
then in a fraction of a second we will
remove the beginning app and we
installed the repackage lab are you
ready
look carefully let's do it okay for
those of you that didn't notice we have
that app still here let's do it again do
it again yeah this is in a room packed
with Wi-Fi devices under the one second
did this happened okay and the big point
here is that when I opened that favorte
up it's actually no longer develop right
this is a very fake version so guys I
want you to think what about what that
practically means that means that if
we're able to do this remotely we might
replace some very important applications
this can be your banking activity but it
can also be your business applications
okay and one of the things that are
important to understand is that this is
a site loaded app meaning what we put
back on the device is an app that was
never monitored by anyone not by app and
not by anyone meaning we can use
some private API its API that cannot be
allowed in the App Store to do some
nasty stuff you know wondered process in
the background recalled you if needed as
well as you know use those capabilities
to maybe exploit a security issue on
your device escalate escalate
permissions and from there do a bunch of
very very very nasty stuff
cool so let's talk about several tak
vectors we can say so the first and most
basic way to get infected with this kind
of is that if just connecting your own
device to a malicious charger or maybe a
malicious USB connection on an airport
or something yeah I didn't from some
reason choosing to trust it some people
may think that they need to choose a
trusted in order to charge the device
this is not to but but many people do
and then they just toss the device again
it it looks like it was it should the
fact you only when the device is
connected but even when you disconnect
it it still can happen and affect your
device and so this is something that I
hope that most of you I hope that all of
you didn't do you didn't have the
malicious a charger but they had a very
very interesting scenario in which you
trust your own computer or maybe another
computer of one of your very colleagues
one of your family members that you left
there's no reason to not trust your own
computer want to backup your device you
want to do other action with it so it
lasted if your device is infected with
Marvel this model can now have an access
to your mobile device it can see all the
things that you are doing that it can
backup your device and still a lot a lot
of information maybe family place all
your app without
you ever knowing and without you doing
any longer stuff you trusted your own
device your own computer so this is a
very interesting approach because it
allows an attacker to extend the control
from only yoga computer to all of your
mobile devices another very interesting
attack if they post trust attack it
means that you trust your computer or
other trusted the computer and
everything was fine the computer was not
infected with any kind of Marvel later
on after al maybe more this computer got
infected with malware unless you did
some active actions in order to delete a
different translation the isolation will
continue to be the meaning that now the
same alwa can can get
information form your device and even
though it can steal all the trust
relations that were created between this
computer and other devices and just use
it anywhere else it doesn't need to be
the in the moment when the trust is
being created but later on it's also
okayed can just and I'll skip all the
translations that you ever created with
this computer so not only the recent one
you know connecting to area and the
presentation what we actually see is
that practically as you know I think
virtually all of you have raised your
hands that you ever trusted any device
even if it's your most trusted device
technically wise you still might be
affected at that very moment by all that
we have just showed if a malware just
got at some point to your own computers
another scenario which is which we were
very concerned that might be applicable
here if the leader of the pack and what
this means is having temporal access to
a computer before the trust relation was
created fortunately Apple did a great
job here and mitigate this kind of a
attacks by generating in you and keeper
every time you choose to trust a device
so there is no one keeper that is used
for all of the devices but and you
generated every time to touch the device
so when you open the Marvel if they're
being found on a computer it can only
see what happens before what happening
now it cannot do it for future devices
if nutri will be created after this
malware was remote from the computer
also what about us be obstructed mode so
I guess that most of you heard about a
new very very important feature that FLE
other than a the latest iOS version on a
iOS 11.4 dot one which is called use
very straight about it we restricted
mode basically tries to block
access to your device physical access to
your device via the USB a data
connection after one hour of the device
being blocked it will force you to him
to enter your passcode again before you
can do anything with the device
connected to your computer this was
created in order to a time mitigate some
a touch performed by some organizations
that allow you to take a device that you
do not know its passcode or any
credential connected to their own device
and then dump it all system bypassing
security mechanisms so by disabling the
USB connection port after one hour you
can just restrict this kind of attacks
and solve it very efficiently so we will
concerned hell interested if this
affects path checking and what we found
out that it does not affect us jacking
it or because traffic jacking
does not rely on a physical USB
connection so this screenshot actually
was taken with traffic jacking with a
similar pose what we saw on the video
checking get what if was this device it
was connected to another computer and
you can fit if a nice a notification
here said you need to unlock your iPhone
in order to access to use accessories to
use the USB accessories and other than
taking screenshots backups and all of
the other actions that we just saw in
this presentation and other walking
remotely as well without any issue and
this screenshot and this test was
performed in air I was 12 better and -
it was the last version last week when
we have verified it but I don't believe
that
anything got changed and a better phone
cool
so other than affection that you you
probably think about it if that this
attack restricted to being connected to
the same London same Wi-Fi which means
the attacker needs to be in proximity to
his victim which also will limit
feasibility extent is beyond the
physical connection but still limit the
attacker in many different ways so we
think whether this is a real affliction
and what we saw with some very cool
stuff so when Apple I decided to port
USB mocks to walk over the network
connection they actually need a to solve
several problems so the first problem
we'll just porting the USB connections
to TCP connection and the second problem
was the discovery issue so when you're
connecting a device to a computer there
is the physical action the device knows
that a newer computer just connected and
it can initiate a lot of a lot of a
processes when you're connected to the
same network there is no this there's no
physical connection so the way that
Apple to talk to a solve it is by using
mdns over Bonjour and for discovery so
when the device connection your
networking even I periodically it just
sends a broadcast a message to everyone
hey I'm I'm here I'm running family
services and you can connect to the usb
a MOOC support this service is available
so what we saw that can very easily
performed is by using a VPN tunnel you
can create a virtual LAN and no matter
where the device is found in the world
it can be connected to a 3G network can
be in another country but you're
connecting a virtual
network by using this network you can
access the device in order to solve the
discovery option you have to of self
you can either configure your VPN tunnel
to replicate and then a packet which
usually don't happen by default and the
second one which we actually use the
very very simple you can replicate or
create your own fake mdns a packet and
then click your own computer in order to
think that hey a new device connected to
a specific IP from now on USB moves and
and your computer will do the rest of
your work it will just walk you can't
really attack a custom version of us be
moved but you really don't need to
because then you can solve it very very
evenly without taking your own a
computer to get this thing to get to
this access you can utilize a very cool
and if for that whip published which is
called the malicious profile which
allows the attacker to to redirect and
decrypt all the traffic is a kind of
virtual Allah and they have access to
the mobile device without needing to be
in the same network over location
usually you get the user to install the
to install it by having some some
technique for taking it to think that he
needs to do it from a social engineering
but very very easy to do and can extend
this way beyond the need to be
physically close to the device so you're
welcome to edit offline of course our
slides will be available on the website
of RSA Conference okay so let's let's
try to to summarize and discuss some
concrete mitigations
that we can do to mitigate the problems
we've discussed so first of all as
mentioned I think that there is a
concrete concern about do we really
trust all of those devices that we've
ever trusted in the past to not be
utilized in order to attack us so one
thing that can be done is to user and
clear the trusted computer settings from
your device you can go to Settings
General reset reset location or privacy
and it's important to understand what
would be the ramifications so one thing
it will be one thing it will do is to
just delete all the keepers all the
trust levels that has been created in
the past between your own device and any
computer around you so that you will
have to rethink the next time you
connect to new devices the second thing
it will do is it will reset all the
privacy settings you have on your device
with different apps meaning that you
will be able to rethink all the
permissions that you have gave to the
different applications on your device so
it's an it's in house
change but it allows you to really
rethink your whole strategy around using
your mobile device this is actually
Apple suggestion in order to to clear
the traffic computer set yep
another thing you can do is obviously
enable encryption and shows your own
password for the encryption as we
mentioned earlier it's better for you to
choose it then for the attacker to
choose it for yourself the third one is
obviously think very carefully about
what you do and the trust you provide to
other hosts and the last element again
as always make sure you update your your
iOS device and Android devices I don't
know if you know the graphs of publicly
known security issues like of CBS but
the graphs over the past few years look
like this the number of security issues
being identified
meaning it's imperative that you
continuously upgrade your operating
systems from an organization perspective
I would say two things first of all from
an IT perspective
very important to consider and point
security solutions mobile first defense
solutions for your mobile fleet it can
convert a lot of problems across the
threat landscape including some of the
items we discussed today such as side
loading of malicious apps such as
malicious profiles etc the second
element for developers obviously think
very carefully about what you are
picking up right because when you bake
up stuff from your application it might
be leaked so it can be logs it can be
data that is backed up by an attacker as
mentioned regarding Apple as always
we've followed responsible and
coordinated disclosure and one of the
thing things they've done in iOS 11 is
to make one of the security threats we
discussed a bit harder because today
when you trust when it trusts a new
computer you need to type in the
passcode this is very valuable for a
case that was possible before for just
an attacker that is nearby you take your
device and Trust the device for you but
it does not solve the problem of
trusting your own computer and having
your computer infected in attack you
back right interestingly enough when you
look at the dialogue it still states
that the list that you are taking when
you're trusting the device is only
applicable as long as you are physically
connected to the computer which as we
have shown today is not correct other
things to take in mind I think I they
were very clear from the presentation is
to rethink the notion of what is
possible even using Wi-Fi or using VPN
and also make the end-user more involved
in the process of you know when backups
are being created of of being even able
to know what are the computers that are
trusted by that device all of that
information is today not visible so I
think to summarize what we've seen today
we've seen progress from a physical set
of attacks into Wi-Fi base
that's the end attacks that can be
conducted from anywhere the implications
are obviously long lasting in some cases
permanent and I hope I hope you found
the presentation valuable and
interesting and I welcome you to follow
us and also read the research in more
details in our blog thank you so much
thank you so we've got a few moments for
questions any questions yeah
as as far as we know this is not
possible because the trust dialogue is
actually very critical there are many
many accessories that you are using that
needs that trust dialogue because they
have some you know data transfer
interaction with your device okay thank
you so much have a great day