4

I'm trying to improve security of data in my Android app and I wonder if there is any tool or something for this problem. I can't find any solution for this on internet. I disable screen capture but users still can take photo of device display. Maybe changing resolution or combining some of colors can help this situation but I really don't have any idea.

kagkar
  • 469
  • 5
  • 15
  • Even if you find a way to do this, what stops the user from taking a photo of the screen with a camera? –  Dec 14 '15 at 12:19
  • I don't have a problem with taking photo, I just want to give users a broken, useless view when they try to capture with camera:) – kagkar Dec 14 '15 at 12:34

3 Answers3

3

In short - you can't, not when your legitimate user is identical with your adversary. If the users are capable of seeing it, they are also capable of taking a picture. It's the quintessential Red Queen situation: the "anti-protection" technology reacts at the same speed as your "protection" technology evolves: if you invent unpolarized displays, users would take pictures through polarizing filters; the only thing that actually changes are the side effects.

See this for a longer version: Is it possible to protect from downloading a video from a site

(What you could try is enforcing the security through legal means instead of technologically: "I hereby agree that I can use the app only if I don't take pictures of it, in a secure room and all by myself; otherwise I lose access and I'll have to pay a $zillion fine." It does sound unenforceable, but it's still easier to implement and more effective - mainly because of FUD - than blocking the users technologically. IANAL. ;))

Community
  • 1
  • 1
Piskvor left the building
  • 91,498
  • 46
  • 177
  • 222
  • @kagkar: Let us turn to the root of the problem: What is the *risk* that you're trying to avoid? Is that a matter of sensitive data escaping? Or a third party connecting the data with the user? Or something else entirely? – Piskvor left the building Dec 14 '15 at 14:58
  • It's all about data security. User should be able to read data but should be banned for any copy operations except writing on a paper:). In fact, user behaivour is not under my control but I think I can make it more difficult at least. Only I need is that a way to cheat the view of camera/video recorder by using some visual tricks. – kagkar Dec 14 '15 at 15:20
  • @kagkar: Writing on paper is okay? Hmm...how is that different from taking a picture, in your specific case? – Piskvor left the building Dec 14 '15 at 15:21
  • It's very long and complex document:) I cannot prevent user to write on paper or memory but there should be something to modify the display of device(brightness, color, resolution etc.) against camera. – kagkar Dec 14 '15 at 15:30
  • 1
    You could make the screen darker or colored, like Twilight does ( https://play.google.com/store/apps/details?id=com.urbandroid.lux ) - but I'm afraid that will be more problematic for live users than to cameras. – Piskvor left the building Dec 14 '15 at 15:33
  • 1
    Thank you for your time, I should skip this step for now:) – kagkar Dec 14 '15 at 15:40
1

Well, You can't restrict any user from taking screenshots of the screen! I'm sorry about that. BTW, What's the issue of people taking screenshots of your application? If you could share more information on it, Maybe I can help you then..

Best.

Ninja Boy
  • 1,112
  • 3
  • 14
  • 28
0

Try FLAG_SECURE:

 public class FlagSecureTestActivity extends Activity {
 @Override
 public void onCreate(Bundle savedInstanceState) {
 super.onCreate(savedInstanceState);

 getWindow().setFlags(LayoutParams.FLAG_SECURE,
                     LayoutParams.FLAG_SECURE);

 setContentView(R.layout.main);
}
}
johnrao07
  • 6,690
  • 4
  • 32
  • 55