From the course: iOS Development: Security
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Obscuring the snapshot before moving to the background - iOS Tutorial
From the course: iOS Development: Security
Obscuring the snapshot before moving to the background
- [Instructor] We can prevent the leakage of sensitive data also by powering Snapshot view with the generic screen. The benefit of this solution is that we don't have to remove the content of our views. Besides, we can implement the required logic in the app delegate. Instead of adding the notification-based solution to all the affected view controllers. So I start by removing the notification-related code. Let's get rid of the, you will disappear, and also let's remove the addObserver code. Now let's switch to the AppDelegate. We'll need a view that's based on top of the current view before the app moves to the background. So first, I create the lazy variable, lazy var, and then called splashView. It's of type UIImageView, and now let's initialize it. We'll keep it simple for this demo, so I create the UIImageView that covers the entire window. I create a constant, let imageView equals UIImageView I create a constant, let imageView equals UIImageView and I'm going to initialize it…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
Purpose strings2m 7s
-
Request authorization for system features4m 7s
-
Adding the missing purpose string1m 34s
-
Exposing sensitive data through copying and pasting2m 16s
-
The pasteboard spy app2m 24s
-
Prevent pasteboard leakage without coding1m 11s
-
Prevent pasteboard leakage with coding2m 11s
-
Using an app-specific pasteboard5m 33s
-
Data leakage through app screenshots2m 16s
-
Clearing data before moving to the background3m 7s
-
Obscuring the snapshot before moving to the background3m 30s
-
Hacking the UserDefaults4m 40s
-
-
-
-
-
-