I do not believe the iOS SDK has access to these buttons. As other users have pointed out, screenshot detection is a hacky method of checking if touch interaction is temporarily disabled (which only(?) occurs during a screenshot).
iOS gives no access to these buttons. It looks as though this code just polls the photo library and checks if a new photo was created.
There was a different version going around earlier which checked for touches being disabled, which happens during a screenshot (but this not the only time iOS does this, I know it happens during the standard navigation "push" animation, and wouldn't be surprised if there were quite a few other standard system actions which disable touches)
Yup, it's impossible to prevent or delete screenshots before they're taken (and you could also do something like take a photo of the device with another camera, if you really wanted). Screenshots are always saved to the Camera Roll on iOS, though, and they can't be taken with or redirected to another location immediately.
Apps like Snapchat and Poke use a detection mechanism just for a better UX, to alert other users after a screenshot happens.
I'm not sure it's impossible, but it would take a great amount of timing and probably some luck. If you can detect a screenshot and throw up a new view quick enough, that's what the screenshot would be. But, I haven't tested that theory, and the timing is probably way too tight to actually work. It'd be more like how Netflix throws up the red screen as soon as it leaves foreground, or the WiFi list in Settings disappears.
With apps like Facebook Poke or SnapChat the content you're sending is ephemeral (it won't be around forever).
Developers of these types of apps can't necessarily prevent a screenshot from happening but you they can at least notify the user who sent the content that a screenshot was taken, which in turn lets them know not to trust the receiver.
Its an issue of protecting users who are using apps like these believing their privacy is safeguarded.
Whether this problem can be fixed with a technological solution, rather than a more dramatic social change, is doubtful, but since the can of worms has been opened, its worth trying.
I don't deny there are issues, but they are societal/educational ones. People need to learn that when you send someone something, that's it, it's out of the bag, even if you trust that person. Due to backdoors, security holes and just general warrantless wiretapping, there's almost no way you can guarantee that what you send won't be snooped by a third party, sooner or later. Add to that that people are far too trusting, and society is sick (between treating sex and nakedness as "dirty" and misogynistic predators like the ones mentioned in your link), and yes there will be problems. But things like ShotBlocker won't solve the problem, it will only exacerbate the already tenuous control people have over their property (what right does anyone have telling people they can't make screen caps on their hardware?).
No, it's not worth trying, because a) it won't work, and b) it will have unintended consequences.
Would it not be so much easier to simply show images with some steganographic message ("I was displayed in SnapChat") in it, and just check for this rather than checking for "Screenshot-looking" pics?
I think the (semi) hidden subtext of both of the applications is the sending of naked pictures or "sexting". I read through the reviews of Snapchat in the app store and it's pretty clear. That may clarify the desire for knowing when a screen cap has been grabbed.
This is also useful for the generalized digital-restrictions-management problem, such as sending someone confidential documents and making sure they don't copy it and send it elsewhere. (Well, insofar as anything is actually useful for DRM, but you can do a reasonably good job on a non-jailbroken platform with iOS's security properties.)
If you're trying to block screenshots, AirPlay mirroring is something else you'll likely want to watch for. It's possible to send a separate feed to the AirPlay display; but not an iOS dev myself so I can't speak to how difficult this is to do.
On the Android side there's also DDMS; unsure if this is detectable or not.
It seems like these things would be easy to get around by opening the message, disconnecting from the Internet, snapping a screenshot, and installing the app. Sure, a PITA, but digital is forever.
Just out of curiosity, has anyone tried having a set of rapidly switching masks to prevent screenshots, so that at any single point of time, all the app can make a screenshot of is a few semi-random (but small) portions of the image? Get it up past 60 frames per second, with something like a noise pattern on the masks, and a screenshot may be pretty indistinguishable, while giving the image only slightly less quality for the end user.
Would require quite a bit of tweaking to get just right, but there is clearly a demand
similar, but with better syncing between frames to eliminate the stroboscopic effect that causes the mask to flutter too long randomly. Something has to smooth the mask switching based on delta time so that slowing of the processing doesn't cause overlaps.
But conceptually, yeah, thats what I was talking about. Interesting read, thank you
While this may be nice - it's only a partial solution. Anybody can take a photo of screen from device #1 with camera from device #2. Nothing can prevent that.
32 comments
[ 2.8 ms ] story [ 84.1 ms ] threadThere was a different version going around earlier which checked for touches being disabled, which happens during a screenshot (but this not the only time iOS does this, I know it happens during the standard navigation "push" animation, and wouldn't be surprised if there were quite a few other standard system actions which disable touches)
Since the image on the screen is in video memory on the device, surely it is impossible to prevent screenshots from being taken?
Apps like Snapchat and Poke use a detection mechanism just for a better UX, to alert other users after a screenshot happens.
Developers of these types of apps can't necessarily prevent a screenshot from happening but you they can at least notify the user who sent the content that a screenshot was taken, which in turn lets them know not to trust the receiver.
Which is why I find this stuff sort of funny.
Why, because they are being held accountable for something they said?
http://www.vice.com/en_ca/read/cowards-are-blackmailing-youn...
Its an issue of protecting users who are using apps like these believing their privacy is safeguarded.
Whether this problem can be fixed with a technological solution, rather than a more dramatic social change, is doubtful, but since the can of worms has been opened, its worth trying.
No, it's not worth trying, because a) it won't work, and b) it will have unintended consequences.
My camera says otherwise.
Just sayin'
https://github.com/clayallsopp/ShotBlocker/blob/master/ShotB...
On the Android side there's also DDMS; unsure if this is detectable or not.
Also this all hearkens back to the "How do I prevent right clicking on my website with jQuery?" days.
Would require quite a bit of tweaking to get just right, but there is clearly a demand
https://news.ycombinator.com/item?id=4955639
But conceptually, yeah, thats what I was talking about. Interesting read, thank you