SlideShare a Scribd company logo
1 of 11
Retroscope
History recall
WhatisRetroscope?
It’s a tool for recreation of Android app screens from memory
images.
Tool was presented at 25th USENIX security symposium(15
August 2016).
White-hat hackers showed a video of how this tool may be
used.
Use-cases
Mobile phones are very involved in real-world crime
investigations.
You have the person, you want evidence of his/her actions.
Such things may turn light on someone’s activity.
It turns out that some secure apps are not that secure:
ISIS uses Telegram secure channels to broadcast some information
Telegram can be Retroscoped
Devs that want to help army can go with this tool
Themaindesign
Retroscope works based on that Android drawing logic is
done through single draw() function.
Every View in Android should override this call and draw
using single Canvas API
onDraw() function call should be done very fast to be
able to display robustly with no lags.
Thus, Retroscope is app agnostic - that is not only
Telegram mentioned above is vulnerable but most of apps
Themaindesign
Android saves drawing calls in memory and also some
internal data structures
Screenlimitations
Somenotes
Memory image should be retrieved not long after device is
taken from the suspected person.
Tool for the extraction can be LiME, Linux memory
extractor.
Entry point to restoring one screen is to find draw()
function in the highest view parent. Then it will be
propagated to the whole view hierarchy.
Howtoprotect?
Almost no way to protect yourself.
One way to stop re-execution is to throw an Exception
during onDraw() but that can be fixed after code
analysis.
The way out is that this solution only works on Dalvik VM
and now more and more ART machines are out.
Null out all memory after every draw() - bad but true, or
better after logout.
We usually don’t log out every day.
Somedemo
Sources
Retroscope paper for USENIX Symposium -
https://www.usenix.org/system/files/conference/usenixsecu
rity16/sec16_paper_saltaformaggio.pdf
Linux Memory Extractor -
https://github.com/504ensicsLabs/LiME
JIRA ticket Retroscope Android Threat - it’s privacy
information
Q&A
1. Market share - який відсоток пристроїв підтримує ART, а не Dalvik. - More than 50%
2. Також наскільки принциповим є це обмеження? Чи не може бути аналогічного засобу відновлення екранів для ART? - Future
work for this tool
3. На тому ж слайді 9 є рекомендація "Null out all memory after every draw() - bad but true". має робити кожен розробник зі своїм
застосунком? Чи це мають робити розробники пристроїв чи Android? - Android design should be reworked
4. Також, якщо це можуть зробити самі розробники застосунків - було б цікаво навести приклад, як саме це робити. - createBitmap()
16MB size all black
5. Чому рекомендовано видаляти всю пам'ять? Адже для коректної роботи методу draw() потрібна вся пам'ять - отже, якщо
видалити якусь частину пам'яті, цього вже має бути достатньо, щоб метод не спрацював? - some info may be lost but it seems
that most other UI info can still be recovered
6. На слайді 6 згадано, що кількість екранів, які відтворює RetroScope, досить обмежена. Наскільки ефективним захистом може бути
часте перемальовування екрану застосунку, наприклад, використання якихось анімацій? - OK, but can create lags and over
complex UI
7. Зі слайдів випливає, що вразливість пов'язана з особливостями реалізації Android UI (метод View.onDraw() і т.д.) Наскільки
вразливими будуть застосунки, написані з використанням NDK, наприклад, на С++? - not investigated
8. Наскільки вразливими будуть застосунки, що використовують певний cross-platform framework на зразок Unity? - the same
vulnerable
9. Наскільки вразливими будуть застосунки на основі WebView, коли весь UI фактично створюється у вигляді веб сторінки, а не
специфічних Android Views? - that might help but it’s not a working solution for most apps

More Related Content

Similar to Retroscope

Mka python jr-urok_01_ua_1563258764
Mka python jr-urok_01_ua_1563258764Mka python jr-urok_01_ua_1563258764
Mka python jr-urok_01_ua_1563258764
PavloTsiura
 

Similar to Retroscope (20)

Mka python jr-urok_01_ua_1563258764
Mka python jr-urok_01_ua_1563258764Mka python jr-urok_01_ua_1563258764
Mka python jr-urok_01_ua_1563258764
 
6 клас урок 4
6 клас урок 46 клас урок 4
6 клас урок 4
 
Inf tema 1_urok_4_6_klas
Inf tema 1_urok_4_6_klasInf tema 1_urok_4_6_klas
Inf tema 1_urok_4_6_klas
 
Изучение интерфейсов операционных систем с помощью Embedded System
Изучение интерфейсов операционных систем с помощью Embedded SystemИзучение интерфейсов операционных систем с помощью Embedded System
Изучение интерфейсов операционных систем с помощью Embedded System
 
Yaroslav Nedashkovskyi та Andrii Savula: Evolution of industrial Artificial I...
Yaroslav Nedashkovskyi та Andrii Savula: Evolution of industrial Artificial I...Yaroslav Nedashkovskyi та Andrii Savula: Evolution of industrial Artificial I...
Yaroslav Nedashkovskyi та Andrii Savula: Evolution of industrial Artificial I...
 
7_0711.pptx
7_0711.pptx7_0711.pptx
7_0711.pptx
 
урок 6
урок 6урок 6
урок 6
 
Inf tema 1_urok_4_6_klas
Inf tema 1_urok_4_6_klasInf tema 1_urok_4_6_klas
Inf tema 1_urok_4_6_klas
 
«Досвід розробки мобільних ігор на AndEngine, libGDX і Unity: переваги і недо...
«Досвід розробки мобільних ігор на AndEngine, libGDX і Unity: переваги і недо...«Досвід розробки мобільних ігор на AndEngine, libGDX і Unity: переваги і недо...
«Досвід розробки мобільних ігор на AndEngine, libGDX і Unity: переваги і недо...
 
урок 4 6 клас
урок 4 6 класурок 4 6 клас
урок 4 6 клас
 
04
0404
04
 
презентація поняття події
презентація   поняття подіїпрезентація   поняття події
презентація поняття події
 
Tdd, ти де?
Tdd, ти де?Tdd, ти де?
Tdd, ти де?
 
Про програму Scratch
Про програму ScratchПро програму Scratch
Про програму Scratch
 
урок 6
урок 6урок 6
урок 6
 
Microsoft Robotics Developer Studio 4
Microsoft Robotics Developer Studio 4Microsoft Robotics Developer Studio 4
Microsoft Robotics Developer Studio 4
 
3 клас урок 27 як працювати в середовищі програмування скретч
3 клас урок 27 як працювати в середовищі програмування скретч3 клас урок 27 як працювати в середовищі програмування скретч
3 клас урок 27 як працювати в середовищі програмування скретч
 
Automation as a Way to Do Routine Work Quickly and Effortlessly
Automation as a Way to Do Routine Work Quickly and EffortlesslyAutomation as a Way to Do Routine Work Quickly and Effortlessly
Automation as a Way to Do Routine Work Quickly and Effortlessly
 
23
2323
23
 
Android Platform Architecture
Android Platform ArchitectureAndroid Platform Architecture
Android Platform Architecture
 

Retroscope

  • 2. WhatisRetroscope? It’s a tool for recreation of Android app screens from memory images. Tool was presented at 25th USENIX security symposium(15 August 2016). White-hat hackers showed a video of how this tool may be used.
  • 3. Use-cases Mobile phones are very involved in real-world crime investigations. You have the person, you want evidence of his/her actions. Such things may turn light on someone’s activity. It turns out that some secure apps are not that secure: ISIS uses Telegram secure channels to broadcast some information Telegram can be Retroscoped Devs that want to help army can go with this tool
  • 4. Themaindesign Retroscope works based on that Android drawing logic is done through single draw() function. Every View in Android should override this call and draw using single Canvas API onDraw() function call should be done very fast to be able to display robustly with no lags. Thus, Retroscope is app agnostic - that is not only Telegram mentioned above is vulnerable but most of apps
  • 5. Themaindesign Android saves drawing calls in memory and also some internal data structures
  • 7. Somenotes Memory image should be retrieved not long after device is taken from the suspected person. Tool for the extraction can be LiME, Linux memory extractor. Entry point to restoring one screen is to find draw() function in the highest view parent. Then it will be propagated to the whole view hierarchy.
  • 8. Howtoprotect? Almost no way to protect yourself. One way to stop re-execution is to throw an Exception during onDraw() but that can be fixed after code analysis. The way out is that this solution only works on Dalvik VM and now more and more ART machines are out. Null out all memory after every draw() - bad but true, or better after logout. We usually don’t log out every day.
  • 10. Sources Retroscope paper for USENIX Symposium - https://www.usenix.org/system/files/conference/usenixsecu rity16/sec16_paper_saltaformaggio.pdf Linux Memory Extractor - https://github.com/504ensicsLabs/LiME JIRA ticket Retroscope Android Threat - it’s privacy information
  • 11. Q&A 1. Market share - який відсоток пристроїв підтримує ART, а не Dalvik. - More than 50% 2. Також наскільки принциповим є це обмеження? Чи не може бути аналогічного засобу відновлення екранів для ART? - Future work for this tool 3. На тому ж слайді 9 є рекомендація "Null out all memory after every draw() - bad but true". має робити кожен розробник зі своїм застосунком? Чи це мають робити розробники пристроїв чи Android? - Android design should be reworked 4. Також, якщо це можуть зробити самі розробники застосунків - було б цікаво навести приклад, як саме це робити. - createBitmap() 16MB size all black 5. Чому рекомендовано видаляти всю пам'ять? Адже для коректної роботи методу draw() потрібна вся пам'ять - отже, якщо видалити якусь частину пам'яті, цього вже має бути достатньо, щоб метод не спрацював? - some info may be lost but it seems that most other UI info can still be recovered 6. На слайді 6 згадано, що кількість екранів, які відтворює RetroScope, досить обмежена. Наскільки ефективним захистом може бути часте перемальовування екрану застосунку, наприклад, використання якихось анімацій? - OK, but can create lags and over complex UI 7. Зі слайдів випливає, що вразливість пов'язана з особливостями реалізації Android UI (метод View.onDraw() і т.д.) Наскільки вразливими будуть застосунки, написані з використанням NDK, наприклад, на С++? - not investigated 8. Наскільки вразливими будуть застосунки, що використовують певний cross-platform framework на зразок Unity? - the same vulnerable 9. Наскільки вразливими будуть застосунки на основі WebView, коли весь UI фактично створюється у вигляді веб сторінки, а не специфічних Android Views? - that might help but it’s not a working solution for most apps