Live data from Hacker News

Why can we still crack snapchat photos in 12 lines of Ruby?

security.stackexchange.com

11–20 of 38 posts

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#11
post #9
post #4

Earlier quoted context omitted.

Actually it does attempt to do that - it requires you keep your finger on the screen while viewing so you can't perform whatever the screenshot command is. Which is lame but that's not the point - their selling point is that they do claim the images are transient. I'll wager 90% of their traffic is images people would not want made public, and some of it will be technically illegal.

What's the point of that? I just tried it, and I can take a screenshot fine with one finger on the screen.

The point of it is to reassure unsophisticated users.

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#12
Forgive my ignorance, but why does SnapChat maintain a local cache beyond the 10-sec limit in the first place? Why don't they delete the photo and overwrite the disk space so that the photo is pretty much unrecoverable? Is it simply that this is too cumbersome to implement? Are there any technical restrictions? I tried Googling the issue and just came across the wave of articles that covered the discovery of the fact that photos were locally recoverable, but I don't seem to have found anything that indicates what motivated this design choice in the first place. Would be great if someone can shed light on this.

PS: I'm not a SnapChat user, so I admit that I might also be overlooking some functionality of the app that necessitates the use of a local cache

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#13

This is a bit of a tangent, but I think it get's at the more interesting part of this question. I ended up following a link to another sec.se thread where the idea of secure program obfuscation was discussed.[0] I feel embarrassed for having missed this but it appears that there exists on a theoretical level a manner of solving snapchat's woes. The wired article ([0][0]) seems to suggest that it would be impractical…

While I agree that is amazing, it still wouldn't solve SnapChat's problem. Because once the image is decrypted and displayed to the user, you can easily copy it from memory and store it indefinitely.

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#14
it is a bit disappointing that so many developers dive into making things without making some minimum research effort into what others have done before. its a recurring theme... however i'm torn because its nice that useful software can hit the market so quickly.

the usual piracy arguments are fine, and yes information that can be viewed by the intended recipient is necessarily crackable, but i think we owe it to our industry and community to not ignore the past X years of work in this field and implement embarrassingly naive amateur solutions. however it does require knowledge and effort to exploit this - particularly physical or close access to the device - imo no layers of security are not worth much once an attacker has physical access.

SnapChat is not alone - there are much, much worse offenders. That recent memory optimisation article about Firefox was imo considerably more shocking... browsers in general seem to be littered with amateurish crap. Even things like Office have some serious problems (why is this file locked? have you memory mapped it? do you need to actively stream my 1.2MB of excel file? really?) the Visual Studio devs have classically thrown away and rebuilt lots of good work over the last two iterations, whilst damaging the quality of the compiler - despite adding features. if valid code from popular libraries stops building between releases i wonder what regression tests are being done if any...

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#15
post #4
post #2

I don't totally see the point to these arguments. The inherent nature of the technology we have means that if they can view it once, they can view it as long and as many times as they want. Anything trying to restrict that is just futile -- look at DRM. Snapchat has never given that particular illusion of privacy. As the most common and basic example, it has absolutely no way of stopping people from simply taking a s…

Actually it does attempt to do that - it requires you keep your finger on the screen while viewing so you can't perform whatever the screenshot command is. Which is lame but that's not the point - their selling point is that they do claim the images are transient. I'll wager 90% of their traffic is images people would not want made public, and some of it will be technically illegal.

I would take that wager. It's far less focused on nudes and illegal stuff than you would think. Most of it is just silly dumb photos or those that don't warrant being shared forever.

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#16

Forgive my ignorance, but why does SnapChat maintain a local cache beyond the 10-sec limit in the first place? Why don't they delete the photo and overwrite the disk space so that the photo is pretty much unrecoverable? Is it simply that this is too cumbersome to implement? Are there any technical restrictions? I tried Googling the issue and just came across the wave of articles that covered the discovery of the fact…

I wonder if you'd even have block level access to storage to pull that off through mobile APIs?

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#17
post #9
post #4

Earlier quoted context omitted.

Actually it does attempt to do that - it requires you keep your finger on the screen while viewing so you can't perform whatever the screenshot command is. Which is lame but that's not the point - their selling point is that they do claim the images are transient. I'll wager 90% of their traffic is images people would not want made public, and some of it will be technically illegal.

What's the point of that? I just tried it, and I can take a screenshot fine with one finger on the screen.

It also attempts to notify the sender if the receiver takes a screenshot of the message.

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#18
I don't fully understand this issue.

I understand that you are never going to be able to stop the intended recipient keeping the image - that's trivial just with a screenshot, and anyone even capable / caring enough to run the linked code is going to defeat any further obfuscation you pile on.

What isn't clear to me from the link is: Is this same encryption the only protection applied to "snaps" that are in-flight? If I run my own wireless access point, can I use this code to decode all messages received by Snapchat users connected to my AP?

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#19
post #10

How would one solve this? One solution seems to be to generate key for each user and store the public keys on the server. If there is need to access the images on the server, encrypt them with a server key and then re-encrypt with the recipients' public key. Are there some problems with this approach (like some functionality of snapchat wouldn't work with this)?

> Are there some problems with this approach

More work. Since the users don't care about this breach anyway (which is why it hasn't been solved yet), it's not worth the developers' time.

Re: Why can we still crack snapchat photos in 12 lines of Ruby?

#20

This is a bit of a tangent, but I think it get's at the more interesting part of this question. I ended up following a link to another sec.se thread where the idea of secure program obfuscation was discussed.[0] I feel embarrassed for having missed this but it appears that there exists on a theoretical level a manner of solving snapchat's woes. The wired article ([0][0]) seems to suggest that it would be impractical…

Whitebox crypto, by itself, doesn't protect against this attack. What you end up doing is lifting the decryption code (wholesale, machine code level) from the SnapChat app and run that in your SnapChat decryption app. Your whitebox crypto code must now have anti-tamper defenses like hashing the rest of the SnapChat code to make sure it is there.
Post reply on HN